Skip to content

armgit / peach

Public Imported from GitHub
0

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

feat(downloads): 云下载「检查」按推送发现填回 115 目标目录与 PikPak 根

longmeidao06be96897dbd
diff --git a/docs/CLOUDDRIVE.md b/docs/CLOUDDRIVE.md
index c78d69bb2..91d907f8c 100644
--- a/docs/CLOUDDRIVE.md
+++ b/docs/CLOUDDRIVE.md
@@ -120,6 +120,7 @@ Peach 不实时监视网盘目录,因为每列一次目录都是一次网络
- **115**:经 CloudDrive2 的 gRPC 接口提交。在 CloudDrive2「设置 → API 令牌」里生成一个令牌,至少勾「提交离线任务」「查看离线任务与配额」,要在 Peach 里取消任务再勾「取消离线任务」。填好令牌后点「检查」:它报出缺哪项权限、目标目录能不能离线下载、本月还剩几条配额,只读,不提交任务。CloudDrive2 跑在这台电脑上时地址可以留空,「检查」会依次试 `http://127.0.0.1:19798`(独立版默认)和 `http://127.0.0.1:29798`(Windows 桌面版常见),用不需要令牌的 `GetSystemInfo` 看谁应答,把先应答的地址填回表单;点「保存配置」后才记下来。两个都不应答时报错并列出试过的两个地址,这时确认 CloudDrive2 已启动,或者把它的实际地址填进去。
- **PikPak**:PikPak 没有开放接口,Peach 照网页端的协议直连。用账号密码登录一次换取登录令牌;勾「保存密码」时登录过期会自动重新登录,不勾就要回到这张卡重新登录。登录触发人机验证时,卡上会给出验证页链接,在浏览器里完成后回来再点一次「登录」,Peach 不替你过验证。
- **目标目录**:115 填 CloudDrive2 挂载树里的路径,这个目录要落在推送发现某个「云端路径前缀」下面;PikPak 填网盘里已经存在的目录,再选 PikPak 根目录对应哪个媒体文件夹。
+- **留空时按推送发现填**:115 目标目录留空时,「检查」对推送发现的每条前缀调 `FindFileByPath`,CloudDrive2 报这条前缀在 115 网盘上(云盘类型 `115open` 或 `115`,看的是 CloudDrive2 自报的类型,不看前缀名字),就建议 `<前缀>/云下载`;有几条时优先对应媒体文件夹声明为 115 来源的那条。这个目录存在就填回表单,接着报它能不能离线、还剩几条配额;不存在时同样填回、输入框标红,并给一颗「新建这个目录」,只有点了才调 `CreateFolder` 在 CloudDrive2 里建,令牌要有「新建文件夹」权限。推送发现里没有 115 那条前缀时,「检查」会提示先去那张卡登记 115 的挂载根。PikPak 根目录对应的媒体文件夹留空时同理:前缀就是 PikPak 云盘根、对应的本机根是已声明的 PikPak 来源,就选上它。填回的值都要点「保存配置」才记下来。
- **等待上限**:远端超过这么久还没下完就标为「停滞」,多半是没有人做种。
令牌、refresh token 和保存的密码只存在这台电脑的凭据文件里,不进设置文件,不随设置同步,也不写进日志和账本。
diff --git a/frontend/src/react/bundle.d.ts b/frontend/src/react/bundle.d.ts
index 150742a83..34d7c5271 100644
--- a/frontend/src/react/bundle.d.ts
+++ b/frontend/src/react/bundle.d.ts
@@ -141,6 +141,10 @@ export interface DownloadCheckReport {
root: string;
folder: { path: string; can_offline: boolean; cloud: string } | null;
quota: { total: number; used: number; left: number } | null;
+ /** 115 目标目录留空时按推送发现推的目录;`exists` 为假时 CloudDrive2 里还没有它。 */
+ suggested_target: { path: string; exists: boolean } | null;
+ /** PikPak 根目录对应的媒体文件夹留空时按推送发现推的声明根,推不出时为空串。 */
+ suggested_pikpak_root: string;
problems: string[];
}
diff --git a/frontend/src/react/settings/download-settings.tsx b/frontend/src/react/settings/download-settings.tsx
index e4fbc88e1..31c5e6068 100644
--- a/frontend/src/react/settings/download-settings.tsx
+++ b/frontend/src/react/settings/download-settings.tsx
@@ -2,7 +2,9 @@
*
* 两张卡。第一张是地址、令牌、目标目录与等待上限:115 走 CloudDrive2 的 gRPC,令牌在
* CloudDrive2「设置 → API 令牌」里生成;「检查」按此刻填的值去问 CloudDrive2 有没有离线权限、
- * 目标目录能不能离线、115 还剩几条配额,只读,不提交。第二张是 PikPak 账号的登录与登出。
+ * 目标目录能不能离线、115 还剩几条配额,只读,不提交。地址、115 目标目录与 PikPak 根留空时,
+ * 「检查」把探测到的、按推送发现推出的值填回表单,点「保存配置」才落盘;推出的目录不存在时
+ * 给一颗「新建这个目录」,只有点了才在 CloudDrive2 里建。第二张是 PikPak 账号的登录与登出。
*
* 令牌与密码只往本机凭据文件写,读接口只回「存没存过」,所以令牌框保存后清空、提示改成
* 「已保存,留空不改」。PikPak 要人机验证时服务端回一个验证页地址,这里给出链接让用户在浏览器
@@ -24,6 +26,7 @@ import { busyProps, useAction } from './use-action';
export const DOWNLOADS_URL = '/api/configuration/downloads';
const CHECK_URL = '/api/configuration/downloads/check';
+const FOLDER_URL = '/api/configuration/downloads/folder';
const LOGIN_URL = '/api/configuration/downloads/pikpak/login';
const LOGOUT_URL = '/api/configuration/downloads/pikpak/logout';
@@ -52,6 +55,7 @@ function DownloadForm({ state, settle, receipt }: CardProps) {
const [hours, setHours] = useState(String(state.config.wait_hours));
const [report, setReport] = useState<DownloadCheckReport | null>(null);
const [detected, setDetected] = useState('');
+ const [suggested, setSuggested] = useState<Suggestions>({ target: null, root: '' });
const [failure, setFailure] = useState('');
const action = useAction();
const target = (key: '115' | 'pikpak') => config.targets[key] ?? '';
@@ -72,19 +76,44 @@ function DownloadForm({ state, settle, receipt }: CardProps) {
}, (cause) => setFailure(errorMessage(cause)));
};
- // 地址留空时服务端探测本机端口,探测到的地址填回表单;用户点「保存配置」才落盘。
+ // 地址、115 目标目录与 PikPak 根留空时,服务端探测本机端口、按推送发现推建议值,这里填回表单;
+ // 用户点「保存配置」才落盘。用户自己填过的字段不覆盖。
const check = () => {
const blank = !config.clouddrive_address.trim();
- const body = { clouddrive_address: config.clouddrive_address, token, target: target('115') };
+ const blankTarget = !target('115').trim();
+ const blankRoot = !config.pikpak_root;
+ const body = { clouddrive_address: config.clouddrive_address, token, target: target('115'),
+ pikpak_root: config.pikpak_root };
void action.run('check', (signal) => apiSend<DownloadCheckReport>(CHECK_URL, body, 'POST', signal),
(next) => {
- if (blank && next.address) setConfig((current) => ({ ...current, clouddrive_address: next.address }));
+ const folder = blankTarget ? next.suggested_target : null;
+ const root = blankRoot ? next.suggested_pikpak_root : '';
+ setConfig((current) => ({
+ ...current,
+ clouddrive_address: blank && next.address ? next.address : current.clouddrive_address,
+ targets: folder ? { ...current.targets, '115': folder.path } : current.targets,
+ pikpak_root: root || current.pikpak_root,
+ }));
setReport(next);
setDetected(blank ? next.address : '');
+ setSuggested({ target: folder, root });
setFailure('');
}, (cause) => setFailure(errorMessage(cause)));
};
+ // 只在用户点了「新建这个目录」时调 CloudDrive2 建目录,建好后服务端按这个目录再检查一遍。
+ const create = (path: string) => {
+ const body = { clouddrive_address: config.clouddrive_address, token, path, pikpak_root: config.pikpak_root };
+ void action.run('folder', (signal) => apiSend<DownloadCheckReport>(FOLDER_URL, body, 'POST', signal),
+ (next) => {
+ setReport(next);
+ setSuggested((current) => ({ ...current, target: { path, exists: true } }));
+ setFailure('');
+ receipt('已新建目录');
+ }, (cause) => setFailure(errorMessage(cause)));
+ };
+ const missing = suggested.target && !suggested.target.exists && target('115') === suggested.target.path;
+
return (
<Section title="云下载" onSubmit={submit}>
<Stack>
@@ -97,8 +126,9 @@ function DownloadForm({ state, settle, receipt }: CardProps) {
placeholder={state.token_set ? '已保存,留空不改' : '在 CloudDrive2「设置 → API 令牌」中生成'}
hint="令牌需要「提交离线任务」「查看离线任务与配额」两项权限;要在 Peach 里取消任务,再勾上「取消离线任务」。"
value={token} isDisabled={!state.available} onChange={setToken} />
- <Input label="115 目标目录" placeholder="/115/云下载" autoComplete="off" maxLength={300}
- hint="CloudDrive2 挂载树里的路径。这个目录要落在「推送发现」的某个云端路径前缀下面,下载完才找得到。"
+ <Input label="115 目标目录" placeholder="检查时按推送发现自动填写" autoComplete="off" maxLength={300}
+ validationBehavior="aria" isInvalid={Boolean(missing)}
+ hint={missing ? 'CloudDrive2 里还没有这个目录。' : 'CloudDrive2 挂载树里的路径,要落在「推送发现」的某个云端路径前缀下面,下载完才找得到。留空时点「检查」,按推送发现里 115 那条前缀填上「前缀/云下载」。'}
value={target('115')} isDisabled={!state.available} onChange={(value) => setTarget('115', value)} />
<Input label="PikPak 目标目录" placeholder="/云下载" autoComplete="off" maxLength={300}
hint="PikPak 网盘里的路径,目录要已经存在。"
@@ -107,7 +137,7 @@ function DownloadForm({ state, settle, receipt }: CardProps) {
<FieldLabel>PikPak 根目录对应的媒体文件夹</FieldLabel>
{state.pikpak_roots.length ? (
<Select aria-label="PikPak 根目录对应的媒体文件夹" selectedKey={config.pikpak_root || null}
- isDisabled={!state.available} placeholder="选择媒体文件夹"
+ isDisabled={!state.available} placeholder="选择媒体文件夹,或点检查按推送发现选"
onSelectionChange={(key) => setConfig({ ...config, pikpak_root: key === null ? '' : String(key) })}>
{state.pikpak_roots.map((root) => <SelectItem key={root} id={root}>{root}</SelectItem>)}
</Select>
@@ -119,7 +149,10 @@ function DownloadForm({ state, settle, receipt }: CardProps) {
hint={`远端超过这么久还没下完就标为停滞,多半是没有人做种。1 到 ${state.max_wait_hours} 小时。`}
value={hours} isDisabled={!state.available} onChange={setHours} />
</Stack>
- {report ? <CheckReport report={report} detected={detected} /> : null}
+ {report ? (
+ <CheckReport report={report} detected={detected} suggested={suggested}
+ create={state.available ? create : undefined} creating={action.busy === 'folder'} />
+ ) : null}
{failure || action.error ? <Stack divided><ErrorText>{failure || action.error}</ErrorText></Stack> : null}
<Footer status={state.available ? undefined : '云下载只在账本写入端可用。'}>
<Button onClick={check} disabled={!state.available} {...busyProps(action.busy === 'check')}>检查</Button>
@@ -129,11 +162,32 @@ function DownloadForm({ state, settle, receipt }: CardProps) {
);
}
-function CheckReport({ report, detected }: { report: DownloadCheckReport; detected: string }) {
+/** 这一次「检查」填回表单的建议值。目标目录不存在时也填回去,表单把它标成无效。 */
+interface Suggestions {
+ target: DownloadCheckReport['suggested_target'];
+ root: string;
+}
+
+function CheckReport({ report, detected, suggested, create, creating }: {
+ report: DownloadCheckReport;
+ detected: string;
+ suggested: Suggestions;
+ create?: (path: string) => void;
+ creating: boolean;
+}) {
+ const folder = suggested.target;
return (
<Stack divided>
<FactList>
{detected ? <Fact term="CloudDrive2 地址">{`探测到 ${detected},保存配置后生效`}</Fact> : null}
+ {folder?.exists ? <Fact term="115 目标目录">{`按推送发现填入 ${folder.path},保存配置后生效`}</Fact> : null}
+ {folder && !folder.exists ? (
+ <Fact term="115 目标目录">
+ {`${folder.path} 不存在`}
+ {create ? <Button size="small" onClick={() => create(folder.path)} {...busyProps(creating)}>新建这个目录</Button> : null}
+ </Fact>
+ ) : null}
+ {suggested.root ? <Fact term="PikPak 根目录">{`按推送发现填入 ${suggested.root},保存配置后生效`}</Fact> : null}
{report.permissions.length ? (
<Fact term="离线权限">
{report.missing.length ? `缺少:${report.missing.join('、')}` : '齐全'}
diff --git a/frontend/test/react/download-settings.test.tsx b/frontend/test/react/download-settings.test.tsx
index f78856325..fb001f4b7 100644
--- a/frontend/test/react/download-settings.test.tsx
+++ b/frontend/test/react/download-settings.test.tsx
@@ -1,8 +1,8 @@
import { expect, it, vi } from 'vitest';
import { DownloadSettings } from '../../src/react/settings/download-settings';
-import type { DownloadSettingsState } from '../../src/react/bundle';
-import { buttonNamed, click, fetchMock, mount, section, sentBody, settle, submit, type } from './render';
+import type { DownloadCheckReport, DownloadSettingsState } from '../../src/react/bundle';
+import { buttonNamed, click, fetchMock, mount, pending, section, sentBody, settle, submit, type } from './render';
const state = (patch: Partial<DownloadSettingsState> = {}): DownloadSettingsState => ({
available: true,
@@ -16,6 +16,16 @@ const state = (patch: Partial<DownloadSettingsState> = {}): DownloadSettingsStat
...patch,
});
+const report = (patch: Partial<DownloadCheckReport> = {}): DownloadCheckReport => ({
+ ok: true, address: 'http://127.0.0.1:19798', permissions: [], missing: [], root: '/', folder: null,
+ quota: null, suggested_target: null, suggested_pikpak_root: '', problems: [], ...patch,
+});
+
+const unfilled = () => state({
+ config: { clouddrive_address: 'http://127.0.0.1:19798', targets: {}, pikpak_root: '', wait_hours: 168 },
+ pikpak_roots: ['A:\\'],
+});
+
const field = (host: HTMLElement, label: string) =>
[...host.querySelectorAll('label')].find((node) => node.textContent?.trim() === label)
?.closest('[data-input-size]')?.querySelector('input') ?? null;
@@ -81,6 +91,68 @@ it('地址留空时检查把探测到的本机地址填回表单,保存配置
expect(sentBody(fetcher, 1)).toMatchObject({ clouddrive_address: 'http://127.0.0.1:29798' });
});
+it('目标目录与 PikPak 根留空时检查按推送发现填回,保存配置才带上它们', async () => {
+ const fetcher = fetchMock(200, report({
+ suggested_target: { path: '/115open/云下载', exists: true }, suggested_pikpak_root: 'A:\\',
+ folder: { path: '/115open/云下载', can_offline: true, cloud: '115open' },
+ }));
+ vi.stubGlobal('fetch', fetcher);
+ const host = await mount(<DownloadSettings initial={unfilled()} receipt={vi.fn()} />);
+ expect(field(host, '115 目标目录')?.placeholder).toBe('检查时按推送发现自动填写');
+ await click(buttonNamed('检查', host));
+ await settle();
+ expect(sentBody(fetcher)).toMatchObject({ target: '', pikpak_root: '' });
+ expect(field(host, '115 目标目录')?.value).toBe('/115open/云下载');
+ expect(host.textContent).toContain('按推送发现填入 /115open/云下载,保存配置后生效');
+ expect(host.textContent).toContain('按推送发现填入 A:\\,保存配置后生效');
+ expect(fetcher).toHaveBeenCalledTimes(1);
+ fetcher.mockImplementation(async () => ({ ok: true, status: 200, json: async () => unfilled() }));
+ await submit(section(host, '云下载'));
+ await settle();
+ expect(fetcher.mock.calls[1]?.[0]).toBe('/api/configuration/downloads');
+ expect(sentBody(fetcher, 1)).toMatchObject({ targets: { '115': '/115open/云下载' }, pikpak_root: 'A:\\' });
+});
+
+it('用户填过的目标目录不被建议值覆盖', async () => {
+ vi.stubGlobal('fetch', fetchMock(200, report({ suggested_target: { path: '/115open/云下载', exists: true } })));
+ const host = await mount(<DownloadSettings initial={state()} receipt={vi.fn()} />);
+ await click(buttonNamed('检查', host));
+ await settle();
+ expect(field(host, '115 目标目录')?.value).toBe('/115/云下载');
+ expect(host.textContent).not.toContain('按推送发现填入');
+});
+
+it('推出的目录不存在时标成无效,点了「新建这个目录」才去建,建好后解除', async () => {
+ const fetcher = fetchMock(200, report({ suggested_target: { path: '/115open/云下载', exists: false } }));
+ vi.stubGlobal('fetch', fetcher);
+ const receipt = vi.fn();
+ const host = await mount(<DownloadSettings initial={unfilled()} receipt={receipt} />);
+ await click(buttonNamed('检查', host));
+ await settle();
+ const input = field(host, '115 目标目录');
+ expect(input?.value).toBe('/115open/云下载');
+ expect(input?.getAttribute('aria-invalid')).toBe('true');
+ expect(host.textContent).toContain('CloudDrive2 里还没有这个目录');
+ expect(host.textContent).toContain('/115open/云下载 不存在');
+ expect(fetcher).toHaveBeenCalledTimes(1);
+
+ const hold = pending<unknown>();
+ fetcher.mockImplementation(() => hold.answer);
+ await click(buttonNamed('新建这个目录', host));
+ expect(fetcher.mock.calls[1]?.[0]).toBe('/api/configuration/downloads/folder');
+ expect(sentBody(fetcher, 1)).toMatchObject({ path: '/115open/云下载', clouddrive_address: 'http://127.0.0.1:19798' });
+ expect(buttonNamed('新建这个目录', host)?.getAttribute('aria-busy')).toBe('true');
+ expect(receipt).not.toHaveBeenCalled();
+ await hold.release({ ok: true, status: 200, json: async () => report({
+ folder: { path: '/115open/云下载', can_offline: true, cloud: '115open' } }) });
+ await settle();
+ expect(receipt).toHaveBeenCalledWith('已新建目录');
+ expect(buttonNamed('新建这个目录', host)).toBeNull();
+ expect(field(host, '115 目标目录')?.getAttribute('aria-invalid')).not.toBe('true');
+ expect(host.textContent).toContain('/115open/云下载 可以离线下载');
+ expect(host.textContent).toContain('按推送发现填入 /115open/云下载,保存配置后生效');
+});
+
it('两个本机端口都不应答时原样报出服务端列的地址,表单仍留空', async () => {
const blank = state({ config: { clouddrive_address: '', targets: {}, pikpak_root: '', wait_hours: 168 } });
const problem = '没有填 CloudDrive2 地址,本机 http://127.0.0.1:19798、http://127.0.0.1:29798 都没有应答。';
diff --git a/src/peach/downloads.py b/src/peach/downloads.py
index a7b2e40a4..eb4c7b6f8 100644
--- a/src/peach/downloads.py
+++ b/src/peach/downloads.py
@@ -403,7 +403,7 @@ def normalise_target(raw: str) -> str:
"""网盘里的目标目录统一成 `/a/b`。CloudDrive2 与 PikPak 都是 POSIX 口径。"""
text = normalise_prefix(raw)
if text == "/" or any(part in {".", ".."} for part in text.split("/")):
- raise ValueError("目标目录要写成网盘里的一个具体文件夹,例如 /115/云下载")
+ raise ValueError("目标目录要写成网盘里的一个具体文件夹,不能是网盘根目录")
return text
diff --git a/src/peach/downloads_clouddrive.proto b/src/peach/downloads_clouddrive.proto
index 4c2b77a95..62e0f7578 100644
--- a/src/peach/downloads_clouddrive.proto
+++ b/src/peach/downloads_clouddrive.proto
@@ -1,4 +1,4 @@
-// CloudDrive2 gRPC 接口的子集:只留云下载用到的七个方法和它们的消息。
+// CloudDrive2 gRPC 接口的子集:只留云下载用到的八个方法和它们的消息。
//
// 字段号、类型与名字逐个照抄官方 https://www.clouddrive2.com/api/clouddrive.proto
// (option version = "1.1.0")。删掉的是用不到的字段,proto3 解码会跳过未知字段,
@@ -16,6 +16,7 @@ service CloudDriveFileSrv {
rpc GetSystemInfo(google.protobuf.Empty) returns (CloudDriveSystemInfo) {}
rpc GetApiTokenInfo(StringValue) returns (TokenInfo) {}
rpc FindFileByPath(FindFileByPathRequest) returns (CloudDriveFile) {}
+ rpc CreateFolder(CreateFolderRequest) returns (CreateFolderResult) {}
rpc AddOfflineFiles(AddOfflineFileRequest) returns (FileOperationResult) {}
rpc RemoveOfflineFiles(RemoveOfflineFilesRequest) returns (FileOperationResult) {}
rpc ListOfflineFilesByPath(FileRequest) returns (OfflineFileListResult) {}
@@ -64,10 +65,21 @@ message CloudDriveFile {
int64 size = 4;
CloudAPI CloudAPI = 9;
bool isDirectory = 30;
+ bool isCloudRoot = 32;
bool canOfflineDownload = 66;
bool supportOfflineDownloadManagement = 75;
}
+message CreateFolderRequest {
+ string parentPath = 1;
+ string folderName = 2;
+}
+
+message CreateFolderResult {
+ CloudDriveFile folderCreated = 1;
+ FileOperationResult result = 2;
+}
+
message AddOfflineFileRequest {
string urls = 1;
string toFolder = 2;
diff --git a/src/peach/downloads_clouddrive.py b/src/peach/downloads_clouddrive.py
index 5eb301e02..892bf464d 100644
--- a/src/peach/downloads_clouddrive.py
+++ b/src/peach/downloads_clouddrive.py
@@ -4,18 +4,24 @@ Peach 不另申请 115 应用,复用 CloudDrive2 已有的 115open 授权:
会顶掉第一次。CloudDrive2 的 API 令牌由用户在设置页填一次,存本机 `CredentialStore`,
只放进 gRPC 的 `authorization` 元数据,不进 URL、日志与 ledger。
-用到的七个方法见 `downloads_clouddrive.proto`。流程参照 JavBoss
+用到的八个方法见 `downloads_clouddrive.proto`。流程参照 JavBoss
`internal/clouddrive/client.go` 与 `internal/service/download.go`:提交前确认目标目录
`canOfflineDownload` 并查配额,提交时让 CloudDrive2 10 秒后自己看一眼目录,之后按 infohash
在目录的离线列表里对账;列表里找不到时看目录里有没有那个文件。
每个任务扣一条 115 离线配额(年费会员每月 1500 条、月费 200 条,月底清零)。提交前先查
目录里是否已有同一 infohash 的离线任务,有就接管,不再扣。
+
+115 目标目录留空时,「检查」从推送发现的云端路径前缀里推一个:对每条前缀调
+`FindFileByPath`,CloudDrive2 回的 `CloudAPI.name` 是 115 那一类的才算 115 前缀,候选是
+`<前缀>/云下载`。判据取 CloudDrive2 自报的云盘类型,不看前缀名字;`FindFileByPath` 只要
+「列目录」权限,查目标目录本来就要它,不另要挂载点或云盘列表的权限。PikPak 根目录对应的
+媒体文件夹同理:前缀是 PikPak 云盘根、对应的本机根是已声明的 PikPak 来源,就推它。
"""
from __future__ import annotations
import posixpath
-from dataclasses import dataclass
+from dataclasses import dataclass, field
from urllib.parse import urlsplit
import grpc
@@ -26,6 +32,7 @@ from .downloads import (
DONE, ERROR, MISSING, RUNNING, DownloadError, DownloadTask, Magnet, RemoteStatus,
classify_remote_message, magnet_info_hash,
)
+from .push_discovery import CloudPrefix, normalise_prefix
SERVICE = "/clouddrive.CloudDriveFileSrv/"
#: 单次调用的上限。离线列表要强制刷新,115 那一侧偶尔要几秒。
@@ -44,10 +51,18 @@ OFFLINE_PERMISSIONS = {
"allow_modify_offline_downloads": "取消离线任务",
}
+#: CloudDrive2 自报的云盘类型(`CloudDriveFile.CloudAPI.name`),比对不分大小写。115 开放平台
+#: 授权是 `115open`,cookie 或扫码登录的是 `115`。
+CLOUDS_115 = frozenset({"115", "115open"})
+CLOUDS_PIKPAK = frozenset({"pikpak"})
+#: 115 目标目录留空时,在 115 前缀下建议的文件夹名。
+SUGGESTED_FOLDER = "云下载"
+
_METHODS = {
"GetSystemInfo": (empty_pb2.Empty, pb.CloudDriveSystemInfo),
"GetApiTokenInfo": (pb.StringValue, pb.TokenInfo),
"FindFileByPath": (pb.FindFileByPathRequest, pb.CloudDriveFile),
+ "CreateFolder": (pb.CreateFolderRequest, pb.CreateFolderResult),
"AddOfflineFiles": (pb.AddOfflineFileRequest, pb.FileOperationResult),
"RemoveOfflineFiles": (pb.RemoveOfflineFilesRequest, pb.FileOperationResult),
"ListOfflineFilesByPath": (pb.FileRequest, pb.OfflineFileListResult),
@@ -127,7 +142,7 @@ class Folder:
class CloudDriveClient:
- """要令牌的那六个方法的薄封装。"""
+ """要令牌的那七个方法的薄封装。"""
def __init__(self, address: str, token: str, *, timeout: float = CALL_TIMEOUT):
if not token:
@@ -191,6 +206,16 @@ class CloudDriveClient:
# -- 写
+ def create_folder(self, path: str) -> None:
+ """在父目录下建一层。父目录要已经存在;令牌要有「新建文件夹」权限。"""
+ parent, name = split_remote(path)
+ created = self.call("CreateFolder", pb.CreateFolderRequest(parentPath=parent, folderName=name),
+ "新建目录")
+ if created.result.success or created.folderCreated.fullPathName or created.folderCreated.name:
+ return
+ reason = created.result.errorMessage or "没有给出原因"
+ raise DownloadError("rejected", f"CloudDrive2 没有新建 {path}:{reason}")
+
def add(self, magnet: str, path: str) -> None:
result = self.call("AddOfflineFiles", pb.AddOfflineFileRequest(
urls=magnet, toFolder=path, checkFolderAfterSecs=CHECK_FOLDER_AFTER_SECS),
@@ -280,25 +305,49 @@ class CloudDriveProvider:
client.remove(client.folder(task.target), task.info_hash or "")
-def check(address: str, token: str, target: str, *,
+@dataclass(frozen=True)
+class Hints:
+ """「检查」推建议值用的本机配置:推送发现的前缀表、已声明的媒体根、表单上的 PikPak 根。"""
+ prefixes: tuple[CloudPrefix, ...] = ()
+ declared_roots: dict = field(default_factory=dict)
+ pikpak_root: str = ""
+
+
+def empty_report(address: str, problems: list[str] | None = None) -> dict:
+ """「检查」报告的形状。每一项各自报,一项失败不挡住其余几项。"""
+ return {"ok": not problems, "address": address, "permissions": [], "missing": [], "root": "",
+ "folder": None, "quota": None, "suggested_target": None, "suggested_pikpak_root": "",
+ "problems": list(problems or ())}
+
+
+def check(address: str, token: str, target: str, *, hints: Hints = Hints(),
local_addresses: tuple[str, ...] = LOCAL_ADDRESSES) -> dict:
"""设置页的「检查」:令牌有没有离线权限、目标目录能不能离线、115 还剩多少配额。
地址留空时先按 `local_addresses` 的顺序探测,报告的 `address` 是实际查的那个,页面把它
- 填回表单,用户保存后才落盘。只读:不提交、不取消。令牌一关过不去时 `ok` 为假;之后的
- 目录与配额各自报进 `problems`。
+ 填回表单,用户保存后才落盘。目标目录与 PikPak 根留空时同样只给建议值(`suggested_*`),
+ 由页面填回。只读:不提交、不取消、不建目录。令牌一关过不去时 `ok` 为假;之后的目录与
+ 配额各自报进 `problems`。
"""
- report: dict = {"ok": True, "address": address or discover(local_addresses), "permissions": [],
- "missing": [], "root": "", "folder": None, "quota": None, "problems": []}
+ report = empty_report(address or discover(local_addresses))
try:
- _inspect(report, CloudDriveClient(report["address"], token), target)
+ _inspect(report, CloudDriveClient(report["address"], token), target, hints)
except DownloadError as error:
report["ok"] = False
report["problems"].append(error.detail)
return report
-def _inspect(report: dict, client: CloudDriveClient, target: str) -> None:
+def create_folder(address: str, token: str, path: str, *, hints: Hints = Hints(),
+ local_addresses: tuple[str, ...] = LOCAL_ADDRESSES) -> dict:
+ """用户点「新建这个目录」时才调。建好之后按这个目录再检查一遍,报告交给页面。"""
+ address = address or discover(local_addresses)
+ with CloudDriveClient(address, token) as client:
+ client.create_folder(path)
+ return check(address, token, path, hints=hints, local_addresses=local_addresses)
+
+
+def _inspect(report: dict, client: CloudDriveClient, target: str, hints: Hints) -> None:
with client:
info = client.token_info()
permissions = info.permissions
@@ -308,19 +357,97 @@ def _inspect(report: dict, client: CloudDriveClient, target: str) -> None:
report["permissions"].append({"name": name, "label": label, "granted": granted})
if not granted:
report["missing"].append(label)
+ probe = _PrefixProbe(client, hints.prefixes)
+ _inspect_target(report, client, probe, target, hints)
+ if not hints.pikpak_root:
+ try:
+ _suggest_pikpak_root(report, probe, hints)
+ except DownloadError as error:
+ report["problems"].append(error.detail)
+
+
+def _inspect_target(report: dict, client: CloudDriveClient, probe: "_PrefixProbe", target: str,
+ hints: Hints) -> None:
+ try:
if not target:
- report["problems"].append("还没有填 115 目标目录")
- return
- try:
- folder = client.folder(target)
- except DownloadError as error:
- report["problems"].append(error.detail)
- return
- report["folder"] = {"path": folder.path, "can_offline": folder.can_offline,
- "cloud": folder.cloud_name}
- try:
- quota = client.quota(folder)
- except DownloadError as error:
- report["problems"].append(error.detail)
+ target = _suggest_target(report, client, probe, hints)
+ if not target:
+ return
+ folder = client.folder(target)
+ except DownloadError as error:
+ report["problems"].append(error.detail)
+ return
+ report["folder"] = {"path": folder.path, "can_offline": folder.can_offline,
+ "cloud": folder.cloud_name}
+ try:
+ quota = client.quota(folder)
+ except DownloadError as error:
+ report["problems"].append(error.detail)
+ return
+ report["quota"] = {"total": quota.total, "used": quota.used, "left": quota.left}
+
+
+class _PrefixProbe:
+ """每条推送前缀在 CloudDrive2 里是什么,一次检查里只问一遍。"""
+
+ def __init__(self, client: CloudDriveClient, prefixes: tuple[CloudPrefix, ...]):
+ self.client = client
+ self.prefixes = tuple(CloudPrefix(normalise_prefix(entry.prefix), entry.root)
+ for entry in prefixes)
+ self.found: dict[str, pb.CloudDriveFile | None] = {}
+
+ def lookup(self, prefix: str) -> pb.CloudDriveFile | None:
+ if prefix not in self.found:
+ self.found[prefix] = self.client.find(prefix, "查推送发现的云端路径前缀")
+ return self.found[prefix]
+
+ def of_cloud(self, clouds: frozenset[str]) -> list[tuple[CloudPrefix, pb.CloudDriveFile]]:
+ hits = []
+ for entry in self.prefixes:
+ found = self.lookup(entry.prefix)
+ if found is not None and found.isDirectory \
+ and (found.CloudAPI.name or "").strip().casefold() in clouds:
+ hits.append((entry, found))
+ return hits
+
+
+def _roots(hints: Hints, location: str) -> dict[str, str]:
+ return {str(root).casefold(): str(root) for root in hints.declared_roots.get(location, ())}
+
+
+def _suggest_target(report: dict, client: CloudDriveClient, probe: _PrefixProbe,
+ hints: Hints) -> str:
+ """推一个 115 目标目录。目录存在才返回它,接着查离线与配额;不存在只报建议值。"""
+ declared = _roots(hints, "115")
+ hits = sorted(probe.of_cloud(CLOUDS_115),
+ key=lambda hit: (hit[0].root.casefold() not in declared, len(hit[0].prefix)))
+ if not hits:
+ known = "、".join(entry.prefix for entry in probe.prefixes)
+ report["problems"].append(
+ f"还没有填 115 目标目录,「推送发现」登记的前缀({known})里也没有 115 网盘上的。"
+ "在「推送发现」卡里加上 CloudDrive2 里 115 的挂载根,再点检查;也可以直接填目标目录"
+ if known else
+ "还没有填 115 目标目录,「推送发现」里也没有登记云端路径前缀。在「推送发现」卡里登记 "
+ "CloudDrive2 里 115 的挂载根和它对应的媒体文件夹,再点检查;也可以直接填目标目录")
+ return ""
+ candidate = f"{hits[0][0].prefix}/{SUGGESTED_FOLDER}"
+ found = client.find(candidate)
+ exists = found is not None and found.isDirectory
+ report["suggested_target"] = {"path": candidate, "exists": exists}
+ return candidate if exists else ""
+
+
+def _suggest_pikpak_root(report: dict, probe: _PrefixProbe, hints: Hints) -> None:
+ """PikPak 根目录对应的媒体文件夹:前缀必须就是 PikPak 云盘根,子目录前缀对不上根。"""
+ declared = _roots(hints, "pikpak")
+ if not declared:
+ return
+ for entry, found in probe.of_cloud(CLOUDS_PIKPAK):
+ cloud_path = found.CloudAPI.path if found.CloudAPI.HasField("path") else ""
+ at_root = found.isCloudRoot or (bool(cloud_path) and normalise_prefix(cloud_path) == entry.prefix)
+ if at_root and entry.root.casefold() in declared:
+ report["suggested_pikpak_root"] = declared[entry.root.casefold()]
return
- report["quota"] = {"total": quota.total, "used": quota.used, "left": quota.left}
+ report["problems"].append(
+ "还没有选 PikPak 根目录对应的媒体文件夹,「推送发现」里也没有 PikPak 云盘根那条前缀可以推。"
+ "在下拉框里直接选,或在「推送发现」卡里登记 PikPak 的挂载根")
diff --git a/src/peach/downloads_clouddrive_pb2.py b/src/peach/downloads_clouddrive_pb2.py
index 8446c9465..bd5affb0e 100644
--- a/src/peach/downloads_clouddrive_pb2.py
+++ b/src/peach/downloads_clouddrive_pb2.py
@@ -25,15 +25,15 @@ _sym_db = _symbol_database.Default()
from google.protobuf import empty_pb2 as google_dot_protobuf_dot_empty__pb2
-DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1a\x64ownloads_clouddrive.proto\x12\nclouddrive\x1a\x1bgoogle/protobuf/empty.proto\"N\n\x14\x43loudDriveSystemInfo\x12\x0f\n\x07IsLogin\x18\x01 \x01(\x08\x12\x10\n\x08UserName\x18\x02 \x01(\t\x12\x13\n\x0bSystemReady\x18\x03 \x01(\x08\"\x1c\n\x0bStringValue\x12\r\n\x05value\x18\x01 \x01(\t\"\x9d\x01\n\tTokenInfo\x12\r\n\x05token\x18\x01 \x01(\t\x12\x0f\n\x07rootDir\x18\x02 \x01(\t\x12\x31\n\x0bpermissions\x18\x03 \x01(\x0b\x32\x1c.clouddrive.TokenPermissions\x12\x17\n\nexpires_in\x18\x04 \x01(\x04H\x00\x88\x01\x01\x12\x15\n\rfriendly_name\x18\x05 \x01(\tB\r\n\x0b_expires_in\"\x98\x01\n\x10TokenPermissions\x12\x12\n\nallow_list\x18\x01 \x01(\x08\x12\"\n\x1a\x61llow_add_offline_download\x18\x10 \x01(\x08\x12$\n\x1c\x61llow_list_offline_downloads\x18\x11 \x01(\x08\x12&\n\x1e\x61llow_modify_offline_downloads\x18\x12 \x01(\x08\"9\n\x15\x46indFileByPathRequest\x12\x12\n\nparentPath\x18\x01 \x01(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\"X\n\x08\x43loudAPI\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x10\n\x08userName\x18\x02 \x01(\t\x12\x10\n\x08nickName\x18\x03 \x01(\t\x12\x11\n\x04path\x18\n \x01(\tH\x00\x88\x01\x01\x42\x07\n\x05_path\"\xd1\x01\n\x0e\x43loudDriveFile\x12\n\n\x02id\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x14\n\x0c\x66ullPathName\x18\x03 \x01(\t\x12\x0c\n\x04size\x18\x04 \x01(\x03\x12&\n\x08\x43loudAPI\x18\t \x01(\x0b\x32\x14.clouddrive.CloudAPI\x12\x13\n\x0bisDirectory\x18\x1e \x01(\x08\x12\x1a\n\x12\x63\x61nOfflineDownload\x18\x42 \x01(\x08\x12(\n supportOfflineDownloadManagement\x18K \x01(\x08\"s\n\x15\x41\x64\x64OfflineFileRequest\x12\x0c\n\x04urls\x18\x01 \x01(\t\x12\x10\n\x08toFolder\x18\x02 \x01(\t\x12!\n\x14\x63heckFolderAfterSecs\x18\x03 \x01(\x04H\x00\x88\x01\x01\x42\x17\n\x15_checkFolderAfterSecs\"U\n\x13\x46ileOperationResult\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x14\n\x0c\x65rrorMessage\x18\x02 \x01(\t\x12\x17\n\x0fresultFilePaths\x18\x03 \x03(\t\"\x8b\x01\n\x19RemoveOfflineFilesRequest\x12\x11\n\tcloudName\x18\x01 \x01(\t\x12\x16\n\x0e\x63loudAccountId\x18\x02 \x01(\t\x12\x13\n\x0b\x64\x65leteFiles\x18\x03 \x01(\x08\x12\x12\n\ninfoHashes\x18\x04 \x03(\t\x12\x11\n\x04path\x18\x05 \x01(\tH\x00\x88\x01\x01\x42\x07\n\x05_path\"G\n\x0b\x46ileRequest\x12\x0c\n\x04path\x18\x01 \x01(\t\x12\x19\n\x0c\x66orceRefresh\x18\x02 \x01(\x08H\x00\x88\x01\x01\x42\x0f\n\r_forceRefresh\"\xcf\x01\n\x0bOfflineFile\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x0c\n\x04size\x18\x02 \x01(\x04\x12\x0b\n\x03url\x18\x03 \x01(\t\x12-\n\x06status\x18\x04 \x01(\x0e\x32\x1d.clouddrive.OfflineFileStatus\x12\x10\n\x08infoHash\x18\x05 \x01(\t\x12\x0e\n\x06\x66ileId\x18\x06 \x01(\t\x12\x10\n\x08\x61\x64\x64_time\x18\x07 \x01(\x04\x12\x10\n\x08parentId\x18\x08 \x01(\t\x12\x13\n\x0bpercendDone\x18\t \x01(\x01\x12\r\n\x05peers\x18\n \x01(\x04\"-\n\rOfflineStatus\x12\r\n\x05quota\x18\x01 \x01(\r\x12\r\n\x05total\x18\x02 \x01(\r\"q\n\x15OfflineFileListResult\x12-\n\x0cofflineFiles\x18\x01 \x03(\x0b\x32\x17.clouddrive.OfflineFile\x12)\n\x06status\x18\x02 \x01(\x0b\x32\x19.clouddrive.OfflineStatus\"\\\n\x13OfflineQuotaRequest\x12\x11\n\tcloudName\x18\x01 \x01(\t\x12\x16\n\x0e\x63loudAccountId\x18\x02 \x01(\t\x12\x11\n\x04path\x18\x03 \x01(\tH\x00\x88\x01\x01\x42\x07\n\x05_path\"=\n\x10OfflineQuotaInfo\x12\r\n\x05total\x18\x01 \x01(\x05\x12\x0c\n\x04used\x18\x02 \x01(\x05\x12\x0c\n\x04left\x18\x03 \x01(\x05*|\n\x11OfflineFileStatus\x12\x10\n\x0cOFFLINE_INIT\x10\x00\x12\x17\n\x13OFFLINE_DOWNLOADING\x10\x01\x12\x14\n\x10OFFLINE_FINISHED\x10\x02\x12\x11\n\rOFFLINE_ERROR\x10\x03\x12\x13\n\x0fOFFLINE_UNKNOWN\x10\x04\x32\xe1\x04\n\x11\x43loudDriveFileSrv\x12K\n\rGetSystemInfo\x12\x16.google.protobuf.Empty\x1a .clouddrive.CloudDriveSystemInfo\"\x00\x12\x43\n\x0fGetApiTokenInfo\x12\x17.clouddrive.StringValue\x1a\x15.clouddrive.TokenInfo\"\x00\x12Q\n\x0e\x46indFileByPath\x12!.clouddrive.FindFileByPathRequest\x1a\x1a.clouddrive.CloudDriveFile\"\x00\x12W\n\x0f\x41\x64\x64OfflineFiles\x12!.clouddrive.AddOfflineFileRequest\x1a\x1f.clouddrive.FileOperationResult\"\x00\x12^\n\x12RemoveOfflineFiles\x12%.clouddrive.RemoveOfflineFilesRequest\x1a\x1f.clouddrive.FileOperationResult\"\x00\x12V\n\x16ListOfflineFilesByPath\x12\x17.clouddrive.FileRequest\x1a!.clouddrive.OfflineFileListResult\"\x00\x12V\n\x13GetOfflineQuotaInfo\x12\x1f.clouddrive.OfflineQuotaRequest\x1a\x1c.clouddrive.OfflineQuotaInfo\"\x00\x62\x06proto3')
+DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1a\x64ownloads_clouddrive.proto\x12\nclouddrive\x1a\x1bgoogle/protobuf/empty.proto\"N\n\x14\x43loudDriveSystemInfo\x12\x0f\n\x07IsLogin\x18\x01 \x01(\x08\x12\x10\n\x08UserName\x18\x02 \x01(\t\x12\x13\n\x0bSystemReady\x18\x03 \x01(\x08\"\x1c\n\x0bStringValue\x12\r\n\x05value\x18\x01 \x01(\t\"\x9d\x01\n\tTokenInfo\x12\r\n\x05token\x18\x01 \x01(\t\x12\x0f\n\x07rootDir\x18\x02 \x01(\t\x12\x31\n\x0bpermissions\x18\x03 \x01(\x0b\x32\x1c.clouddrive.TokenPermissions\x12\x17\n\nexpires_in\x18\x04 \x01(\x04H\x00\x88\x01\x01\x12\x15\n\rfriendly_name\x18\x05 \x01(\tB\r\n\x0b_expires_in\"\x98\x01\n\x10TokenPermissions\x12\x12\n\nallow_list\x18\x01 \x01(\x08\x12\"\n\x1a\x61llow_add_offline_download\x18\x10 \x01(\x08\x12$\n\x1c\x61llow_list_offline_downloads\x18\x11 \x01(\x08\x12&\n\x1e\x61llow_modify_offline_downloads\x18\x12 \x01(\x08\"9\n\x15\x46indFileByPathRequest\x12\x12\n\nparentPath\x18\x01 \x01(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\"X\n\x08\x43loudAPI\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x10\n\x08userName\x18\x02 \x01(\t\x12\x10\n\x08nickName\x18\x03 \x01(\t\x12\x11\n\x04path\x18\n \x01(\tH\x00\x88\x01\x01\x42\x07\n\x05_path\"\xe6\x01\n\x0e\x43loudDriveFile\x12\n\n\x02id\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x14\n\x0c\x66ullPathName\x18\x03 \x01(\t\x12\x0c\n\x04size\x18\x04 \x01(\x03\x12&\n\x08\x43loudAPI\x18\t \x01(\x0b\x32\x14.clouddrive.CloudAPI\x12\x13\n\x0bisDirectory\x18\x1e \x01(\x08\x12\x13\n\x0bisCloudRoot\x18 \x01(\x08\x12\x1a\n\x12\x63\x61nOfflineDownload\x18\x42 \x01(\x08\x12(\n supportOfflineDownloadManagement\x18K \x01(\x08\"=\n\x13\x43reateFolderRequest\x12\x12\n\nparentPath\x18\x01 \x01(\t\x12\x12\n\nfolderName\x18\x02 \x01(\t\"x\n\x12\x43reateFolderResult\x12\x31\n\rfolderCreated\x18\x01 \x01(\x0b\x32\x1a.clouddrive.CloudDriveFile\x12/\n\x06result\x18\x02 \x01(\x0b\x32\x1f.clouddrive.FileOperationResult\"s\n\x15\x41\x64\x64OfflineFileRequest\x12\x0c\n\x04urls\x18\x01 \x01(\t\x12\x10\n\x08toFolder\x18\x02 \x01(\t\x12!\n\x14\x63heckFolderAfterSecs\x18\x03 \x01(\x04H\x00\x88\x01\x01\x42\x17\n\x15_checkFolderAfterSecs\"U\n\x13\x46ileOperationResult\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x14\n\x0c\x65rrorMessage\x18\x02 \x01(\t\x12\x17\n\x0fresultFilePaths\x18\x03 \x03(\t\"\x8b\x01\n\x19RemoveOfflineFilesRequest\x12\x11\n\tcloudName\x18\x01 \x01(\t\x12\x16\n\x0e\x63loudAccountId\x18\x02 \x01(\t\x12\x13\n\x0b\x64\x65leteFiles\x18\x03 \x01(\x08\x12\x12\n\ninfoHashes\x18\x04 \x03(\t\x12\x11\n\x04path\x18\x05 \x01(\tH\x00\x88\x01\x01\x42\x07\n\x05_path\"G\n\x0b\x46ileRequest\x12\x0c\n\x04path\x18\x01 \x01(\t\x12\x19\n\x0c\x66orceRefresh\x18\x02 \x01(\x08H\x00\x88\x01\x01\x42\x0f\n\r_forceRefresh\"\xcf\x01\n\x0bOfflineFile\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x0c\n\x04size\x18\x02 \x01(\x04\x12\x0b\n\x03url\x18\x03 \x01(\t\x12-\n\x06status\x18\x04 \x01(\x0e\x32\x1d.clouddrive.OfflineFileStatus\x12\x10\n\x08infoHash\x18\x05 \x01(\t\x12\x0e\n\x06\x66ileId\x18\x06 \x01(\t\x12\x10\n\x08\x61\x64\x64_time\x18\x07 \x01(\x04\x12\x10\n\x08parentId\x18\x08 \x01(\t\x12\x13\n\x0bpercendDone\x18\t \x01(\x01\x12\r\n\x05peers\x18\n \x01(\x04\"-\n\rOfflineStatus\x12\r\n\x05quota\x18\x01 \x01(\r\x12\r\n\x05total\x18\x02 \x01(\r\"q\n\x15OfflineFileListResult\x12-\n\x0cofflineFiles\x18\x01 \x03(\x0b\x32\x17.clouddrive.OfflineFile\x12)\n\x06status\x18\x02 \x01(\x0b\x32\x19.clouddrive.OfflineStatus\"\\\n\x13OfflineQuotaRequest\x12\x11\n\tcloudName\x18\x01 \x01(\t\x12\x16\n\x0e\x63loudAccountId\x18\x02 \x01(\t\x12\x11\n\x04path\x18\x03 \x01(\tH\x00\x88\x01\x01\x42\x07\n\x05_path\"=\n\x10OfflineQuotaInfo\x12\r\n\x05total\x18\x01 \x01(\x05\x12\x0c\n\x04used\x18\x02 \x01(\x05\x12\x0c\n\x04left\x18\x03 \x01(\x05*|\n\x11OfflineFileStatus\x12\x10\n\x0cOFFLINE_INIT\x10\x00\x12\x17\n\x13OFFLINE_DOWNLOADING\x10\x01\x12\x14\n\x10OFFLINE_FINISHED\x10\x02\x12\x11\n\rOFFLINE_ERROR\x10\x03\x12\x13\n\x0fOFFLINE_UNKNOWN\x10\x04\x32\xb4\x05\n\x11\x43loudDriveFileSrv\x12K\n\rGetSystemInfo\x12\x16.google.protobuf.Empty\x1a .clouddrive.CloudDriveSystemInfo\"\x00\x12\x43\n\x0fGetApiTokenInfo\x12\x17.clouddrive.StringValue\x1a\x15.clouddrive.TokenInfo\"\x00\x12Q\n\x0e\x46indFileByPath\x12!.clouddrive.FindFileByPathRequest\x1a\x1a.clouddrive.CloudDriveFile\"\x00\x12Q\n\x0c\x43reateFolder\x12\x1f.clouddrive.CreateFolderRequest\x1a\x1e.clouddrive.CreateFolderResult\"\x00\x12W\n\x0f\x41\x64\x64OfflineFiles\x12!.clouddrive.AddOfflineFileRequest\x1a\x1f.clouddrive.FileOperationResult\"\x00\x12^\n\x12RemoveOfflineFiles\x12%.clouddrive.RemoveOfflineFilesRequest\x1a\x1f.clouddrive.FileOperationResult\"\x00\x12V\n\x16ListOfflineFilesByPath\x12\x17.clouddrive.FileRequest\x1a!.clouddrive.OfflineFileListResult\"\x00\x12V\n\x13GetOfflineQuotaInfo\x12\x1f.clouddrive.OfflineQuotaRequest\x1a\x1c.clouddrive.OfflineQuotaInfo\"\x00\x62\x06proto3')
_globals = globals()
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'downloads_clouddrive_pb2', _globals)
if not _descriptor._USE_C_DESCRIPTORS:
DESCRIPTOR._loaded_options = None
- _globals['_OFFLINEFILESTATUS']._serialized_start=1805
- _globals['_OFFLINEFILESTATUS']._serialized_end=1929
+ _globals['_OFFLINEFILESTATUS']._serialized_start=2011
+ _globals['_OFFLINEFILESTATUS']._serialized_end=2135
_globals['_CLOUDDRIVESYSTEMINFO']._serialized_start=71
_globals['_CLOUDDRIVESYSTEMINFO']._serialized_end=149
_globals['_STRINGVALUE']._serialized_start=151
@@ -47,25 +47,29 @@ if not _descriptor._USE_C_DESCRIPTORS:
_globals['_CLOUDAPI']._serialized_start=555
_globals['_CLOUDAPI']._serialized_end=643
_globals['_CLOUDDRIVEFILE']._serialized_start=646
- _globals['_CLOUDDRIVEFILE']._serialized_end=855
- _globals['_ADDOFFLINEFILEREQUEST']._serialized_start=857
- _globals['_ADDOFFLINEFILEREQUEST']._serialized_end=972
- _globals['_FILEOPERATIONRESULT']._serialized_start=974
- _globals['_FILEOPERATIONRESULT']._serialized_end=1059
- _globals['_REMOVEOFFLINEFILESREQUEST']._serialized_start=1062
- _globals['_REMOVEOFFLINEFILESREQUEST']._serialized_end=1201
- _globals['_FILEREQUEST']._serialized_start=1203
- _globals['_FILEREQUEST']._serialized_end=1274
- _globals['_OFFLINEFILE']._serialized_start=1277
- _globals['_OFFLINEFILE']._serialized_end=1484
- _globals['_OFFLINESTATUS']._serialized_start=1486
- _globals['_OFFLINESTATUS']._serialized_end=1531
- _globals['_OFFLINEFILELISTRESULT']._serialized_start=1533
- _globals['_OFFLINEFILELISTRESULT']._serialized_end=1646
- _globals['_OFFLINEQUOTAREQUEST']._serialized_start=1648
- _globals['_OFFLINEQUOTAREQUEST']._serialized_end=1740
- _globals['_OFFLINEQUOTAINFO']._serialized_start=1742
- _globals['_OFFLINEQUOTAINFO']._serialized_end=1803
- _globals['_CLOUDDRIVEFILESRV']._serialized_start=1932
- _globals['_CLOUDDRIVEFILESRV']._serialized_end=2541
+ _globals['_CLOUDDRIVEFILE']._serialized_end=876
+ _globals['_CREATEFOLDERREQUEST']._serialized_start=878
+ _globals['_CREATEFOLDERREQUEST']._serialized_end=939
+ _globals['_CREATEFOLDERRESULT']._serialized_start=941
+ _globals['_CREATEFOLDERRESULT']._serialized_end=1061
+ _globals['_ADDOFFLINEFILEREQUEST']._serialized_start=1063
+ _globals['_ADDOFFLINEFILEREQUEST']._serialized_end=1178
+ _globals['_FILEOPERATIONRESULT']._serialized_start=1180
+ _globals['_FILEOPERATIONRESULT']._serialized_end=1265
+ _globals['_REMOVEOFFLINEFILESREQUEST']._serialized_start=1268
+ _globals['_REMOVEOFFLINEFILESREQUEST']._serialized_end=1407
+ _globals['_FILEREQUEST']._serialized_start=1409
+ _globals['_FILEREQUEST']._serialized_end=1480
+ _globals['_OFFLINEFILE']._serialized_start=1483
+ _globals['_OFFLINEFILE']._serialized_end=1690
+ _globals['_OFFLINESTATUS']._serialized_start=1692
+ _globals['_OFFLINESTATUS']._serialized_end=1737
+ _globals['_OFFLINEFILELISTRESULT']._serialized_start=1739
+ _globals['_OFFLINEFILELISTRESULT']._serialized_end=1852
+ _globals['_OFFLINEQUOTAREQUEST']._serialized_start=1854
+ _globals['_OFFLINEQUOTAREQUEST']._serialized_end=1946
+ _globals['_OFFLINEQUOTAINFO']._serialized_start=1948
+ _globals['_OFFLINEQUOTAINFO']._serialized_end=2009
+ _globals['_CLOUDDRIVEFILESRV']._serialized_start=2138
+ _globals['_CLOUDDRIVEFILESRV']._serialized_end=2830
# @@protoc_insertion_point(module_scope)
diff --git a/src/peach/routes_configuration.py b/src/peach/routes_configuration.py
index 3250791ef..68e9bcff2 100644
--- a/src/peach/routes_configuration.py
+++ b/src/peach/routes_configuration.py
@@ -269,7 +269,8 @@ def save_downloads(request: Request, body: dict = Body(...), _args=Depends(requi
@router.post("/api/configuration/downloads/check")
def check_downloads(request: Request, body: dict = Body(default={}), _args=Depends(require_auth)):
- """调 CloudDrive2 的 `GetApiTokenInfo` 等只读接口:离线权限、目标目录、115 剩余配额。"""
+ """调 CloudDrive2 的 `GetApiTokenInfo` 等只读接口:离线权限、目标目录、115 剩余配额,
+ 目标目录与 PikPak 根留空时按推送发现推建议值。"""
local_only(request)
same_origin(request)
service, _roots = _downloads(request)
@@ -279,6 +280,18 @@ def check_downloads(request: Request, body: dict = Body(default={}), _args=Depen
raise HTTPException(400, str(exc)) from exc
[email protected]("/api/configuration/downloads/folder")
+def create_download_folder(request: Request, body: dict = Body(...), _args=Depends(require_auth)):
+ """调 CloudDrive2 的 `CreateFolder` 建 115 目标目录。只在用户点「新建这个目录」时发。"""
+ local_only(request)
+ same_origin(request)
+ service, _roots = _downloads(request)
+ try:
+ return web_downloads.create_clouddrive_folder(service, body)
+ except ValueError as exc:
+ raise HTTPException(400, str(exc)) from exc
+
+
@router.post("/api/configuration/downloads/pikpak/login")
def login_pikpak(request: Request, body: dict = Body(...), _args=Depends(require_auth)):
local_only(request)
diff --git a/src/peach/web_downloads.py b/src/peach/web_downloads.py
index bb733bf41..e45d0ac46 100644
--- a/src/peach/web_downloads.py
+++ b/src/peach/web_downloads.py
@@ -118,24 +118,52 @@ def save_settings(service: DownloadService, body: dict, declared_roots) -> dict:
return settings_payload(service, declared_roots)
-def check_clouddrive(service: DownloadService, body: dict) -> dict:
- """「检查」按页面上此刻填的值查,没带的字段取已保存的。只读,不提交也不取消。
-
- 页面带来的地址是空串时探测本机端口;报告里的 `address` 由页面填回表单,不在这里保存。
- """
- from .downloads_clouddrive import check
+def _check_inputs(service: DownloadService, body) -> tuple[dict, str, str]:
body = body if isinstance(body, dict) else {}
address = clean_address(body["clouddrive_address"] if "clouddrive_address" in body
else service.config.clouddrive_address)
token = str(body.get("token") or "").strip() or _values(
service.credentials, CLOUDDRIVE_CREDENTIAL).get("token", "")
- raw_target = str(body.get("target") or service.config.targets.get("115", "")).strip()
+ return body, address, token
+
+
+def _hints(service: DownloadService, body: dict):
+ """推建议值用的前缀表与声明根取推送发现那份,和落地换算同一个口径。"""
+ from .downloads_clouddrive import Hints
+ landing = service.landing
+ push = getattr(landing, "push_discovery", None)
+ prefixes = tuple(getattr(getattr(push, "config", None), "prefixes", ()) or ())
+ pikpak_root = str(body["pikpak_root"] if "pikpak_root" in body else service.config.pikpak_root)
+ return Hints(prefixes=prefixes, declared_roots=dict(landing.declared_roots or {}),
+ pikpak_root=pikpak_root.strip())
+
+
+def check_clouddrive(service: DownloadService, body: dict) -> dict:
+ """「检查」按页面上此刻填的值查,没带的字段取已保存的。只读,不提交、不取消、不建目录。
+
+ 页面带来的地址是空串时探测本机端口;目标目录或 PikPak 根是空串时按推送发现推建议值。
+ 报告里的 `address` 与 `suggested_*` 由页面填回表单,不在这里保存。
+ """
+ from .downloads_clouddrive import check, empty_report
+ body, address, token = _check_inputs(service, body)
+ raw_target = str(body.get("target") if "target" in body
+ else service.config.targets.get("115", "")).strip()
target = normalise_target(raw_target) if raw_target else ""
try:
- return check(address, token, target)
+ return check(address, token, target, hints=_hints(service, body))
except DownloadError as error:
- return {"ok": False, "address": address, "permissions": [], "missing": [], "root": "",
- "folder": None, "quota": None, "problems": [error.detail]}
+ return empty_report(address, [error.detail])
+
+
+def create_clouddrive_folder(service: DownloadService, body: dict) -> dict:
+ """「新建这个目录」:用户点了才在 CloudDrive2 里建,建好后回对这个目录的检查报告。"""
+ from .downloads_clouddrive import create_folder
+ body, address, token = _check_inputs(service, body)
+ path = normalise_target(str(body.get("path") or ""))
+ try:
+ return create_folder(address, token, path, hints=_hints(service, body))
+ except DownloadError as error:
+ raise ValueError(error.detail) from None
def pikpak_login(service: DownloadService, body: dict, declared_roots, *, transport=None) -> dict:
diff --git a/tests/test_downloads_clouddrive.py b/tests/test_downloads_clouddrive.py
index 87d5f54c7..5c8a67752 100644
--- a/tests/test_downloads_clouddrive.py
+++ b/tests/test_downloads_clouddrive.py
@@ -1,8 +1,9 @@
"""115 云下载经 CloudDrive2 gRPC:起一个进程内的假服务端,走真实的序列化与元数据。
-假服务端只实现那七个方法,状态放在内存里。断言落在「Peach 发出去的是什么」上:令牌只在
+假服务端只实现那八个方法,状态放在内存里。断言落在「Peach 发出去的是什么」上:令牌只在
`authorization` 元数据里,提交前先查目录与配额,已有同一 infohash 的任务就不再提交,
-地址留空时只用不带令牌的 `GetSystemInfo` 探测。
+地址留空时只用不带令牌的 `GetSystemInfo` 探测,目标目录留空时按 CloudDrive2 报的云盘类型
+从推送前缀里推,只有用户点了才建目录。
"""
from __future__ import annotations
@@ -15,6 +16,7 @@ import grpc
from peach import downloads as dl
from peach import downloads_clouddrive as cd
from peach import downloads_clouddrive_pb2 as pb
+from peach.push_discovery import CloudPrefix
HASH = "c9e15763f722f23e98a29decdfae341b98d53056"
MAGNET = dl.parse_magnet(f"magnet:?xt=urn:btih:{HASH}&dn=ABC-123")
@@ -26,6 +28,9 @@ class FakeCloudDrive:
def __init__(self):
self.calls: list[tuple[str, object, str]] = []
self.folders = {TARGET: True}
+ #: 挂载树里的云盘根 → CloudDrive2 报的云盘类型。没登记的目录都算在 115 上。
+ self.clouds = {"/115": "115open"}
+ self.create_error = ""
self.offline: list[pb.OfflineFile] = []
self.quota = pb.OfflineQuotaInfo(total=1500, used=3, left=1497)
self.add_error = ""
@@ -51,13 +56,27 @@ class FakeCloudDrive:
self._auth("FindFileByPath", request, context)
full = f"{request.parentPath.rstrip('/')}/{request.path}"
if full in self.folders:
+ root = max((root for root in self.clouds if full == root or full.startswith(root + "/")),
+ key=len, default="/115")
return pb.CloudDriveFile(name=request.path, fullPathName=full, isDirectory=True,
- canOfflineDownload=self.folders[full],
- CloudAPI=pb.CloudAPI(name="115open", userName="u1"))
+ isCloudRoot=full == root, canOfflineDownload=self.folders[full],
+ CloudAPI=pb.CloudAPI(name=self.clouds.get(root, "115open"),
+ userName="u1", path=root))
if full in self.files:
return pb.CloudDriveFile(name=request.path, fullPathName=full)
context.abort(grpc.StatusCode.NOT_FOUND, "no such file")
+ def CreateFolder(self, request, context):
+ self._auth("CreateFolder", request, context)
+ if self.create_error:
+ return pb.CreateFolderResult(result=pb.FileOperationResult(
+ success=False, errorMessage=self.create_error))
+ full = f"{request.parentPath.rstrip('/')}/{request.folderName}"
+ self.folders[full] = True
+ return pb.CreateFolderResult(
+ folderCreated=pb.CloudDriveFile(name=request.folderName, fullPathName=full, isDirectory=True),
+ result=pb.FileOperationResult(success=True))
+
def AddOfflineFiles(self, request, context):
self._auth("AddOfflineFiles", request, context)
if self.add_error:
@@ -249,5 +268,83 @@ class CheckTests(_Server):
self.assertEqual(cd.split_remote("/115/云下载/"), ("/115", "云下载"))
+class SuggestionTests(_Server):
+ """前缀名字故意和云盘对不上:`/甲` 是 115 的挂载根,`/115假` 是 PikPak 的。"""
+
+ def setUp(self):
+ super().setUp()
+ self.fake.clouds.update({"/甲": "115open", "/115假": "PikPak"})
+ self.fake.folders.update({"/甲": True, "/115假": False})
+ self.prefixes = (CloudPrefix("/115假", "A:\\"), CloudPrefix("/甲", "B:\\"))
+ self.roots = {"115": ("B:\\",), "pikpak": ("A:\\",), "local": ("C:\\媒体",)}
+
+ def hints(self, *, prefixes=None, roots=None, pikpak_root="") -> cd.Hints:
+ return cd.Hints(self.prefixes if prefixes is None else prefixes,
+ self.roots if roots is None else roots, pikpak_root)
+
+ def finds(self) -> list[str]:
+ return [f"{request.parentPath.rstrip('/')}/{request.path}"
+ for name, request, _ in self.fake.calls if name == "FindFileByPath"]
+
+ def test_a_blank_target_takes_the_folder_under_the_prefix_clouddrive_reports_as_115(self):
+ self.fake.folders["/甲/云下载"] = True
+ report = cd.check(self.address, TOKEN, "", hints=self.hints())
+ self.assertEqual(report["suggested_target"], {"path": "/甲/云下载", "exists": True})
+ self.assertEqual(report["folder"], {"path": "/甲/云下载", "can_offline": True, "cloud": "115open"})
+ self.assertEqual(report["quota"], {"total": 1500, "used": 3, "left": 1497})
+ self.assertEqual(report["suggested_pikpak_root"], "A:\\")
+ self.assertEqual(report["problems"], [])
+
+ def test_a_missing_suggested_folder_is_reported_and_never_created(self):
+ report = cd.check(self.address, TOKEN, "", hints=self.hints(pikpak_root="A:\\"))
+ self.assertEqual(report["suggested_target"], {"path": "/甲/云下载", "exists": False})
+ self.assertEqual((report["folder"], report["quota"], report["problems"]), (None, None, []))
+ self.assertNotIn("CreateFolder", self.methods())
+ self.assertNotIn("GetOfflineQuotaInfo", self.methods())
+
+ def test_a_declared_115_root_wins_over_another_115_prefix(self):
+ self.fake.clouds["/乙"] = "115"
+ self.fake.folders.update({"/乙": True, "/乙/云下载": True, "/甲/云下载": True})
+ prefixes = (CloudPrefix("/乙", "C:\\媒体"), CloudPrefix("/甲/深一层", "B:\\"))
+ self.fake.folders["/甲/深一层"] = True
+ report = cd.check(self.address, TOKEN, "", hints=self.hints(prefixes=prefixes, pikpak_root="A:\\"))
+ self.assertEqual(report["suggested_target"]["path"], "/甲/深一层/云下载")
+
+ def test_without_a_115_prefix_the_problem_points_at_push_discovery(self):
+ only_pikpak = (CloudPrefix("/115假", "A:\\"),)
+ report = cd.check(self.address, TOKEN, "", hints=self.hints(prefixes=only_pikpak, pikpak_root="A:\\"))
+ self.assertIsNone(report["suggested_target"])
+ self.assertEqual(len(report["problems"]), 1)
+ self.assertIn("「推送发现」", report["problems"][0])
+ self.assertIn("/115假", report["problems"][0])
+ report = cd.check(self.address, TOKEN, "", hints=self.hints(prefixes=(), pikpak_root="A:\\"))
+ self.assertIn("没有登记云端路径前缀", report["problems"][0])
+
+ def test_a_pikpak_prefix_below_the_cloud_root_is_not_the_pikpak_root(self):
+ self.fake.folders["/115假/影视"] = False
+ roots = {"115": ("B:\\",), "pikpak": ("A:\\影视",)}
+ prefixes = (CloudPrefix("/115假/影视", "A:\\影视"), CloudPrefix("/甲", "B:\\"))
+ report = cd.check(self.address, TOKEN, "/115/云下载", hints=self.hints(prefixes=prefixes, roots=roots))
+ self.assertEqual(report["suggested_pikpak_root"], "")
+ self.assertEqual(len(report["problems"]), 1)
+ self.assertIn("PikPak 根目录对应的媒体文件夹", report["problems"][0])
+
+ def test_filled_fields_ask_nothing_about_the_prefixes(self):
+ report = cd.check(self.address, TOKEN, TARGET, hints=self.hints(pikpak_root="A:\\"))
+ self.assertEqual(self.finds(), [TARGET])
+ self.assertEqual((report["suggested_target"], report["suggested_pikpak_root"]), (None, ""))
+
+ def test_creating_the_folder_happens_only_on_request_and_checks_it_again(self):
+ report = cd.create_folder(self.address, TOKEN, "/甲/云下载", hints=self.hints(pikpak_root="A:\\"))
+ created = [request for name, request, _ in self.fake.calls if name == "CreateFolder"]
+ self.assertEqual([(request.parentPath, request.folderName) for request in created],
+ [("/甲", "云下载")])
+ self.assertEqual(report["folder"], {"path": "/甲/云下载", "can_offline": True, "cloud": "115open"})
+ self.fake.create_error = "没有新建文件夹的权限"
+ with self.assertRaises(dl.DownloadError) as caught:
+ cd.create_folder(self.address, TOKEN, "/甲/另一个", hints=self.hints())
+ self.assertIn("没有新建文件夹的权限", caught.exception.detail)
+
+
if __name__ == "__main__":
unittest.main()
diff --git a/tests/test_web_downloads.py b/tests/test_web_downloads.py
index 0e4a471f1..385627cfb 100644
--- a/tests/test_web_downloads.py
+++ b/tests/test_web_downloads.py
@@ -8,14 +8,16 @@ import json
import tempfile
import unittest
from pathlib import Path
+from unittest import mock
import httpx
from fastapi.testclient import TestClient
from peach import downloads as dl
-from peach import web_downloads
+from peach import downloads_clouddrive, web_downloads
from peach.api import create_app
from peach.config import PeachSettings
+from peach.push_discovery import CloudPrefix, PushDiscoveryConfig
from support.ledger import fresh_ledger
HASH = "c9e15763f722f23e98a29decdfae341b98d53056"
@@ -114,6 +116,35 @@ class SettingsBlockTests(_App):
report = web_downloads.check_clouddrive(self.service, {"clouddrive_address": "127.0.0.1:1"})
self.assertFalse(report["ok"])
self.assertIn("API 令牌", report["problems"][0])
+ self.assertEqual((report["suggested_target"], report["suggested_pikpak_root"]), (None, ""))
+
+ def test_the_check_takes_the_push_prefixes_and_the_blanks_on_the_form(self):
+ web_downloads.save_settings(self.service, {"targets": {"115": "/115open/已保存"}}, self.roots())
+ prefixes = (CloudPrefix("/115open", "B:\\"),)
+ self.service.landing.push_discovery.config = PushDiscoveryConfig(prefixes=prefixes)
+ seen = {}
+
+ def check(address, token, target, *, hints):
+ seen.update(target=target, hints=hints)
+ return downloads_clouddrive.empty_report(address)
+
+ with mock.patch.object(downloads_clouddrive, "check", check):
+ web_downloads.check_clouddrive(self.service, {
+ "clouddrive_address": "127.0.0.1:19798", "token": "t", "target": "", "pikpak_root": ""})
+ self.assertEqual((seen["target"], seen["hints"].prefixes, seen["hints"].pikpak_root),
+ ("", prefixes, ""))
+ web_downloads.check_clouddrive(self.service, {"clouddrive_address": "127.0.0.1:19798"})
+ self.assertEqual(seen["target"], "/115open/已保存")
+
+ def test_creating_a_folder_needs_a_token_and_a_real_folder(self):
+ with self.assertRaises(ValueError) as caught:
+ web_downloads.create_clouddrive_folder(self.service, {
+ "clouddrive_address": "127.0.0.1:1", "path": "/115open/云下载"})
+ self.assertIn("API 令牌", str(caught.exception))
+ with self.assertRaises(ValueError) as caught:
+ web_downloads.create_clouddrive_folder(self.service, {
+ "clouddrive_address": "127.0.0.1:1", "token": "t", "path": "/"})
+ self.assertIn("根目录", str(caught.exception))
def test_a_pikpak_captcha_comes_back_as_a_page_to_open(self):
def handler(request: httpx.Request) -> httpx.Response:
diff --git a/web/dist/peach-react.js b/web/dist/peach-react.js
index fe028a017..cae9b084e 100644
--- a/web/dist/peach-react.js
+++ b/web/dist/peach-react.js
@@ -20123,7 +20123,7 @@ function Ih(e, t, n) {
//#region node_modules/react-aria-components/dist/private/Popover.mjs
var Lh = /*#__PURE__*/ (0, R.createContext)(null), Rh = /*#__PURE__*/ (0, R.createContext)(null), zh = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
[e, t] = La(e, t, Lh);
- let n = (0, R.useContext)(Pg), r = Nh(e), i = e.isOpen != null || e.defaultOpen != null || !n ? r : n, a = Fh(t, i.isOpen), o = e.isExiting || !e.shouldSkipAnimation && a || !1, s = Gc(), { direction: c } = Bs();
+ let n = (0, R.useContext)(Fg), r = Nh(e), i = e.isOpen != null || e.defaultOpen != null || !n ? r : n, a = Fh(t, i.isOpen), o = e.isExiting || !e.shouldSkipAnimation && a || !1, s = Gc(), { direction: c } = Bs();
if (s) {
let t = e.children;
return typeof t == "function" && (t = t({
@@ -20583,7 +20583,7 @@ function ree(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/menu/useMenuItem.mjs
-function iee(e, t, n) {
+function Tg(e, t, n) {
let { id: r, key: i, closeOnSelect: a, shouldCloseOnSelect: o, isVirtualized: s, "aria-haspopup": c, onPressStart: l, onPressUp: u, onPress: d, onPressChange: f, onPressEnd: p, onClick: m, onHoverStart: h, onHoverChange: g, onHoverEnd: _, onKeyDown: v, onKeyUp: y, onFocus: b, onFocusChange: x, onBlur: S, selectionManager: C = t.selectionManager } = e, w = !!c, T = w && e["aria-expanded"] === "true", E = e.isDisabled ?? C.isDisabled(i), D = e.isSelected ?? C.isSelected(i), O = wg.get(t), k = t.collection.getItem(i), A = e.onClose || O.onClose, j = Go(), M = () => {
if (!w && (k?.props?.onAction ? k.props.onAction() : e.onAction && e.onAction(i), O.onAction)) {
let e = O.onAction;
@@ -20696,7 +20696,7 @@ function iee(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/menu/useMenuSection.mjs
-function aee(e) {
+function iee(e) {
let { heading: t, "aria-label": n } = e, r = Ta();
return {
itemProps: { role: "presentation" },
@@ -20713,7 +20713,7 @@ function aee(e) {
}
//#endregion
//#region node_modules/react-stately/dist/private/menu/useMenuTriggerState.mjs
-function Tg(e) {
+function Eg(e) {
let t = Nh(e), [n, r] = (0, R.useState)(null), [i, a] = (0, R.useState)([]), o = () => {
a([]), t.close();
}, s = (e, t) => {
@@ -20740,7 +20740,7 @@ function Tg(e) {
}
//#endregion
//#region node_modules/react-stately/dist/private/tree/TreeCollection.mjs
-var oee = class {
+var aee = class {
constructor(e, { expandedKeys: t } = {}) {
this.keyMap = /* @__PURE__ */ new Map(), this.firstKey = null, this.lastKey = null, this.iterable = e, t ||= /* @__PURE__ */ new Set();
let n = (e) => {
@@ -20784,8 +20784,8 @@ var oee = class {
};
//#endregion
//#region node_modules/react-stately/dist/private/tree/useTreeState.mjs
-function see(e) {
- let { onExpandedChange: t } = e, [n, r] = nc(e.expandedKeys ? new Set(e.expandedKeys) : void 0, e.defaultExpandedKeys ? new Set(e.defaultExpandedKeys) : /* @__PURE__ */ new Set(), t), i = wp(e), a = (0, R.useMemo)(() => e.disabledKeys ? new Set(e.disabledKeys) : /* @__PURE__ */ new Set(), [e.disabledKeys]), o = jp(e, (0, R.useCallback)((e) => new oee(e, { expandedKeys: n }), [n]), null);
+function oee(e) {
+ let { onExpandedChange: t } = e, [n, r] = nc(e.expandedKeys ? new Set(e.expandedKeys) : void 0, e.defaultExpandedKeys ? new Set(e.defaultExpandedKeys) : /* @__PURE__ */ new Set(), t), i = wp(e), a = (0, R.useMemo)(() => e.disabledKeys ? new Set(e.disabledKeys) : /* @__PURE__ */ new Set(), [e.disabledKeys]), o = jp(e, (0, R.useCallback)((e) => new aee(e, { expandedKeys: n }), [n]), null);
return (0, R.useEffect)(() => {
i.focusedKey != null && !o.getItem(i.focusedKey) && i.setFocusedKey(null);
}, [o, i.focusedKey]), {
@@ -20793,31 +20793,31 @@ function see(e) {
expandedKeys: n,
disabledKeys: a,
toggleKey: (e) => {
- r(cee(n, e));
+ r(see(n, e));
},
setExpandedKeys: r,
selectionManager: new Ep(o, i)
};
}
-function cee(e, t) {
+function see(e, t) {
let n = new Set(e);
return n.has(t) ? n.delete(t) : n.add(t), n;
}
//#endregion
//#region node_modules/react-aria-components/dist/private/Menu.mjs
-var Eg = /*#__PURE__*/ (0, R.createContext)(null), Dg = /*#__PURE__*/ (0, R.createContext)(null), Og = /*#__PURE__*/ (0, R.createContext)(null), kg = /*#__PURE__*/ (0, R.createContext)(null);
-function lee(e) {
- let t = Tg(e), n = (0, R.useRef)(null), { menuTriggerProps: r, menuProps: i } = Cg({
+var Dg = /*#__PURE__*/ (0, R.createContext)(null), Og = /*#__PURE__*/ (0, R.createContext)(null), kg = /*#__PURE__*/ (0, R.createContext)(null), Ag = /*#__PURE__*/ (0, R.createContext)(null);
+function cee(e) {
+ let t = Eg(e), n = (0, R.useRef)(null), { menuTriggerProps: r, menuProps: i } = Cg({
...e,
type: "menu"
}, t, n), a = (0, R.useRef)(null);
return Gc() ? null : /*#__PURE__*/ R.createElement(Pa, { values: [
- [Eg, {
+ [Dg, {
...i,
ref: a
}],
- [Pg, t],
- [Og, t],
+ [Fg, t],
+ [kg, t],
[Lh, {
trigger: "MenuTrigger",
triggerRef: n,
@@ -20832,7 +20832,7 @@ function lee(e) {
isPressed: t.isOpen
}, e.children));
}
-var uee = /*#__PURE__*/ (0, R.createContext)(null);
+var lee = /*#__PURE__*/ (0, R.createContext)(null);
(class extends ac {
static {
this.type = "submenutrigger";
@@ -20846,20 +20846,20 @@ var uee = /*#__PURE__*/ (0, R.createContext)(null);
return null;
}
});
-var dee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- return [e, t] = La(e, t, Eg), /*#__PURE__*/ R.createElement(Zc, { content: /*#__PURE__*/ R.createElement(ll, e) }, (n) => /*#__PURE__*/ R.createElement(fee, {
+var uee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ return [e, t] = La(e, t, Dg), /*#__PURE__*/ R.createElement(Zc, { content: /*#__PURE__*/ R.createElement(ll, e) }, (n) => /*#__PURE__*/ R.createElement(dee, {
props: e,
collection: n,
menuRef: t
}));
});
-function fee({ props: e, collection: t, menuRef: n }) {
+function dee({ props: e, collection: t, menuRef: n }) {
[e, n] = La(e, n, rc);
- let { filter: r, ...i } = e, a = (0, R.useMemo)(() => r ? t.filter(r) : t, [t, r]), o = see({
+ let { filter: r, ...i } = e, a = (0, R.useMemo)(() => r ? t.filter(r) : t, [t, r]), o = oee({
...e,
collection: a,
children: void 0
- }), s = (0, R.useContext)(Og), { isVirtualized: c, CollectionRoot: l } = (0, R.useContext)(hl), { menuProps: u } = ree({
+ }), s = (0, R.useContext)(kg), { isVirtualized: c, CollectionRoot: l } = (0, R.useContext)(hl), { menuProps: u } = ree({
...e,
isVirtualized: c,
onClose: e.onClose || s?.close
@@ -20881,28 +20881,28 @@ function fee({ props: e, collection: t, menuRef: n }) {
"data-empty": o.collection.size === 0 || void 0,
onScroll: e.onScroll
}, /*#__PURE__*/ R.createElement(Pa, { values: [
- [Dg, o],
+ [Og, o],
[lf, { elementType: "div" }],
[dl, {
name: "MenuSection",
- render: Ag
+ render: jg
}],
- [uee, {
+ [lee, {
parentMenuRef: n,
shouldUseVirtualFocus: i?.shouldUseVirtualFocus
}],
- [Mg, { shouldCloseOnSelect: e.shouldCloseOnSelect }],
+ [Ng, { shouldCloseOnSelect: e.shouldCloseOnSelect }],
[rc, null],
[ic, null],
- [kg, o.selectionManager],
- [Og, s ?? Tg({})]
+ [Ag, o.selectionManager],
+ [kg, s ?? Eg({})]
] }, /*#__PURE__*/ R.createElement(of, null, /*#__PURE__*/ R.createElement(l, {
collection: o.collection,
persistedKeys: gl(o.selectionManager.focusedKey),
scrollRef: n
}))), f));
}
-var pee = class extends Ep {
+var fee = class extends Ep {
constructor(e, t) {
super(e.collection, t), this.parent = e;
}
@@ -20922,8 +20922,8 @@ var pee = class extends Ep {
return this.parent.childFocusStrategy;
}
};
-function Ag(e, t, n, r = "react-aria-MenuSection") {
- let i = (0, R.useContext)(Dg), { CollectionBranch: a } = (0, R.useContext)(hl), [o, s] = Ra(), { headingProps: c, groupProps: l } = aee({
+function jg(e, t, n, r = "react-aria-MenuSection") {
+ let i = (0, R.useContext)(Og), { CollectionBranch: a } = (0, R.useContext)(hl), [o, s] = Ra(), { headingProps: c, groupProps: l } = iee({
heading: s,
"aria-label": n.props["aria-label"] ?? void 0
}), u = Fa({
@@ -20934,7 +20934,7 @@ function Ag(e, t, n, r = "react-aria-MenuSection") {
className: n.props?.className,
style: n.props?.style,
values: void 0
- }), d = (0, R.useContext)(kg), f = wp(e), p = e.selectionMode == null ? d : new pee(d, f), m = Ia(Mg)?.shouldCloseOnSelect, h = Cl(e, { global: !0 });
+ }), d = (0, R.useContext)(Ag), f = wp(e), p = e.selectionMode == null ? d : new fee(d, f), m = Ia(Ng)?.shouldCloseOnSelect, h = Cl(e, { global: !0 });
return delete h.id, /*#__PURE__*/ R.createElement(Ha.section, {
...J(h, u, l),
ref: t
@@ -20943,16 +20943,16 @@ function Ag(e, t, n, r = "react-aria-MenuSection") {
...c,
ref: o
}],
- [kg, p],
- [Mg, { shouldCloseOnSelect: e.shouldCloseOnSelect ?? m }]
+ [Ag, p],
+ [Ng, { shouldCloseOnSelect: e.shouldCloseOnSelect ?? m }]
] }, /*#__PURE__*/ R.createElement(a, {
collection: i.collection,
parent: n
})));
}
-var jg = /*#__PURE__*/ ol(lc, Ag), Mg = /*#__PURE__*/ (0, R.createContext)(null), Ng = /*#__PURE__*/ al(cc, function(e, t, n) {
- [e, t] = La(e, t, Mg);
- let r = Ia(Mg)?.id, i = (0, R.useContext)(Dg), a = Ma(t), o = (0, R.useContext)(kg), { isVirtualized: s } = (0, R.useContext)(hl), { menuItemProps: c, labelProps: l, descriptionProps: u, keyboardShortcutProps: d, ...f } = iee({
+var Mg = /*#__PURE__*/ ol(lc, jg), Ng = /*#__PURE__*/ (0, R.createContext)(null), Pg = /*#__PURE__*/ al(cc, function(e, t, n) {
+ [e, t] = La(e, t, Ng);
+ let r = Ia(Ng)?.id, i = (0, R.useContext)(Og), a = Ma(t), o = (0, R.useContext)(Ag), { isVirtualized: s } = (0, R.useContext)(hl), { menuItemProps: c, labelProps: l, descriptionProps: u, keyboardShortcutProps: d, ...f } = Tg({
...e,
id: r,
key: n.key,
@@ -20996,7 +20996,7 @@ var jg = /*#__PURE__*/ ol(lc, Ag), Mg = /*#__PURE__*/ (0, R.createContext)(null)
] }, h.children));
});
al(sc, function(e, t, n) {
- let r = (0, R.useContext)(Dg), { isLoading: i, onLoadMore: a, scrollOffset: o, ...s } = e, c = (0, R.useRef)(null);
+ let r = (0, R.useContext)(Og), { isLoading: i, onLoadMore: a, scrollOffset: o, ...s } = e, c = (0, R.useRef)(null);
Fp((0, R.useMemo)(() => ({
onLoadMore: a,
collection: r?.collection,
@@ -21038,7 +21038,7 @@ al(sc, function(e, t, n) {
});
//#endregion
//#region node_modules/react-aria/dist/private/dialog/useDialog.mjs
-function mee(e, t) {
+function pee(e, t) {
let { role: n = "dialog" } = e, r = Da();
r = e["aria-label"] ? void 0 : r;
let i = Da();
@@ -21073,13 +21073,13 @@ function mee(e, t) {
}
//#endregion
//#region node_modules/react-aria-components/dist/private/Dialog.mjs
-var hee = /*#__PURE__*/ (0, R.createContext)(null), Pg = /*#__PURE__*/ (0, R.createContext)(null), Fg = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+var mee = /*#__PURE__*/ (0, R.createContext)(null), Fg = /*#__PURE__*/ (0, R.createContext)(null), Ig = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let n = e["aria-labelledby"];
- [e, t] = La(e, t, hee);
- let { dialogProps: r, titleProps: i, contentProps: a } = mee({
+ [e, t] = La(e, t, mee);
+ let { dialogProps: r, titleProps: i, contentProps: a } = pee({
...e,
"aria-labelledby": n
- }, t), o = (0, R.useContext)(Pg);
+ }, t), o = (0, R.useContext)(Fg);
!r["aria-label"] && !r["aria-labelledby"] && e["aria-labelledby"] && (r["aria-labelledby"] = e["aria-labelledby"]);
let s = Fa({
defaultClassName: "react-aria-Dialog",
@@ -21113,14 +21113,14 @@ var hee = /*#__PURE__*/ (0, R.createContext)(null), Pg = /*#__PURE__*/ (0, R.cre
});
//#endregion
//#region node_modules/react-aria/dist/private/i18n/useListFormatter.mjs
-function gee(e = {}) {
+function hee(e = {}) {
let { locale: t } = Bs();
return (0, R.useMemo)(() => new Intl.ListFormat(t, e), [t, e]);
}
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/ar-AE.mjs
-var Ig = {};
-Ig = {
+var Lg = {};
+Lg = {
deselectedItem: (e) => `${e.item} \u{63A}\u{64A}\u{631} \u{627}\u{644}\u{645}\u{62D}\u{62F}\u{62F}`,
longPressToSelect: "اضغط مطولًا للدخول إلى وضع التحديد.",
select: "تحديد",
@@ -21134,8 +21134,8 @@ Ig = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/bg-BG.mjs
-var Lg = {};
-Lg = {
+var Rg = {};
+Rg = {
deselectedItem: (e) => `${e.item} \u{43D}\u{435} \u{435} \u{438}\u{437}\u{431}\u{440}\u{430}\u{43D}.`,
longPressToSelect: "Натиснете и задръжте за да влезете в избирателен режим.",
select: "Изберете",
@@ -21149,8 +21149,8 @@ Lg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/cs-CZ.mjs
-var Rg = {};
-Rg = {
+var zg = {};
+zg = {
deselectedItem: (e) => `Polo\u{17E}ka ${e.item} nen\xed vybr\xe1na.`,
longPressToSelect: "Dlouhým stisknutím přejdete do režimu výběru.",
select: "Vybrat",
@@ -21164,8 +21164,8 @@ Rg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/da-DK.mjs
-var zg = {};
-zg = {
+var Bg = {};
+Bg = {
deselectedItem: (e) => `${e.item} ikke valgt.`,
longPressToSelect: "Lav et langt tryk for at aktivere valgtilstand.",
select: "Vælg",
@@ -21179,8 +21179,8 @@ zg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/de-DE.mjs
-var Bg = {};
-Bg = {
+var Vg = {};
+Vg = {
deselectedItem: (e) => `${e.item} nicht ausgew\xe4hlt.`,
longPressToSelect: "Gedrückt halten, um Auswahlmodus zu öffnen.",
select: "Auswählen",
@@ -21194,8 +21194,8 @@ Bg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/el-GR.mjs
-var Vg = {};
-Vg = {
+var Hg = {};
+Hg = {
deselectedItem: (e) => `\u{394}\u{3B5}\u{3BD} \u{3B5}\u{3C0}\u{3B9}\u{3BB}\u{3AD}\u{3C7}\u{3B8}\u{3B7}\u{3BA}\u{3B5} \u{3C4}\u{3BF} \u{3C3}\u{3C4}\u{3BF}\u{3B9}\u{3C7}\u{3B5}\u{3AF}\u{3BF} ${e.item}.`,
longPressToSelect: "Πατήστε παρατεταμένα για να μπείτε σε λειτουργία επιλογής.",
select: "Επιλογή",
@@ -21209,8 +21209,8 @@ Vg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/en-US.mjs
-var Hg = {};
-Hg = {
+var Ug = {};
+Ug = {
deselectedItem: (e) => `${e.item} not selected.`,
select: "Select",
selectedCount: (e, t) => `${t.plural(e.count, {
@@ -21224,8 +21224,8 @@ Hg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/es-ES.mjs
-var Ug = {};
-Ug = {
+var Wg = {};
+Wg = {
deselectedItem: (e) => `${e.item} no seleccionado.`,
longPressToSelect: "Mantenga pulsado para abrir el modo de selección.",
select: "Seleccionar",
@@ -21239,8 +21239,8 @@ Ug = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/et-EE.mjs
-var Wg = {};
-Wg = {
+var Gg = {};
+Gg = {
deselectedItem: (e) => `${e.item} pole valitud.`,
longPressToSelect: "Valikurežiimi sisenemiseks vajutage pikalt.",
select: "Vali",
@@ -21254,8 +21254,8 @@ Wg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/fi-FI.mjs
-var Gg = {};
-Gg = {
+var Kg = {};
+Kg = {
deselectedItem: (e) => `Kohdetta ${e.item} ei valittu.`,
longPressToSelect: "Siirry valintatilaan painamalla pitkään.",
select: "Valitse",
@@ -21269,8 +21269,8 @@ Gg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/fr-FR.mjs
-var Kg = {};
-Kg = {
+var qg = {};
+qg = {
deselectedItem: (e) => `${e.item} non s\xe9lectionn\xe9.`,
longPressToSelect: "Appuyez de manière prolongée pour passer en mode de sélection.",
select: "Sélectionner",
@@ -21284,8 +21284,8 @@ Kg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/he-IL.mjs
-var qg = {};
-qg = {
+var Jg = {};
+Jg = {
deselectedItem: (e) => `${e.item} \u{5DC}\u{5D0} \u{5E0}\u{5D1}\u{5D7}\u{5E8}.`,
longPressToSelect: "הקשה ארוכה לכניסה למצב בחירה.",
select: "בחר",
@@ -21299,8 +21299,8 @@ qg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/hr-HR.mjs
-var Jg = {};
-Jg = {
+var Yg = {};
+Yg = {
deselectedItem: (e) => `Stavka ${e.item} nije odabrana.`,
longPressToSelect: "Dugo pritisnite za ulazak u način odabira.",
select: "Odaberite",
@@ -21314,8 +21314,8 @@ Jg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/hu-HU.mjs
-var Yg = {};
-Yg = {
+var Xg = {};
+Xg = {
deselectedItem: (e) => `${e.item} nincs kijel\xf6lve.`,
longPressToSelect: "Nyomja hosszan a kijelöléshez.",
select: "Kijelölés",
@@ -21329,8 +21329,8 @@ Yg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/it-IT.mjs
-var Xg = {};
-Xg = {
+var Zg = {};
+Zg = {
deselectedItem: (e) => `${e.item} non selezionato.`,
longPressToSelect: "Premi a lungo per passare alla modalità di selezione.",
select: "Seleziona",
@@ -21344,8 +21344,8 @@ Xg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/ja-JP.mjs
-var Zg = {};
-Zg = {
+var Qg = {};
+Qg = {
deselectedItem: (e) => `${e.item} \u{304C}\u{9078}\u{629E}\u{3055}\u{308C}\u{3066}\u{3044}\u{307E}\u{305B}\u{3093}\u{3002}`,
longPressToSelect: "長押しして選択モードを開きます。",
select: "選択",
@@ -21359,8 +21359,8 @@ Zg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/ko-KR.mjs
-var Qg = {};
-Qg = {
+var $g = {};
+$g = {
deselectedItem: (e) => `${e.item}\u{C774}(\u{AC00}) \u{C120}\u{D0DD}\u{B418}\u{C9C0} \u{C54A}\u{C558}\u{C2B5}\u{B2C8}\u{B2E4}.`,
longPressToSelect: "선택 모드로 들어가려면 길게 누르십시오.",
select: "선택",
@@ -21374,8 +21374,8 @@ Qg = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/lt-LT.mjs
-var $g = {};
-$g = {
+var e_ = {};
+e_ = {
deselectedItem: (e) => `${e.item} nepasirinkta.`,
longPressToSelect: "Norėdami įjungti pasirinkimo režimą, paspauskite ir palaikykite.",
select: "Pasirinkti",
@@ -21389,8 +21389,8 @@ $g = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/lv-LV.mjs
-var e_ = {};
-e_ = {
+var t_ = {};
+t_ = {
deselectedItem: (e) => `Vienums ${e.item} nav atlas\u{12B}ts.`,
longPressToSelect: "Ilgi turiet nospiestu. lai ieslēgtu atlases režīmu.",
select: "Atlasīt",
@@ -21404,8 +21404,8 @@ e_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/nb-NO.mjs
-var t_ = {};
-t_ = {
+var n_ = {};
+n_ = {
deselectedItem: (e) => `${e.item} er ikke valgt.`,
longPressToSelect: "Bruk et langt trykk for å gå inn i valgmodus.",
select: "Velg",
@@ -21419,8 +21419,8 @@ t_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/nl-NL.mjs
-var n_ = {};
-n_ = {
+var r_ = {};
+r_ = {
deselectedItem: (e) => `${e.item} niet geselecteerd.`,
longPressToSelect: "Druk lang om de selectiemodus te openen.",
select: "Selecteren",
@@ -21434,8 +21434,8 @@ n_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/pl-PL.mjs
-var r_ = {};
-r_ = {
+var i_ = {};
+i_ = {
deselectedItem: (e) => `Nie zaznaczono ${e.item}.`,
longPressToSelect: "Naciśnij i przytrzymaj, aby wejść do trybu wyboru.",
select: "Zaznacz",
@@ -21449,8 +21449,8 @@ r_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/pt-BR.mjs
-var i_ = {};
-i_ = {
+var a_ = {};
+a_ = {
deselectedItem: (e) => `${e.item} n\xe3o selecionado.`,
longPressToSelect: "Mantenha pressionado para entrar no modo de seleção.",
select: "Selecionar",
@@ -21464,8 +21464,8 @@ i_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/pt-PT.mjs
-var a_ = {};
-a_ = {
+var o_ = {};
+o_ = {
deselectedItem: (e) => `${e.item} n\xe3o selecionado.`,
longPressToSelect: "Prima continuamente para entrar no modo de seleção.",
select: "Selecionar",
@@ -21479,8 +21479,8 @@ a_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/ro-RO.mjs
-var o_ = {};
-o_ = {
+var s_ = {};
+s_ = {
deselectedItem: (e) => `${e.item} neselectat.`,
longPressToSelect: "Apăsați lung pentru a intra în modul de selectare.",
select: "Selectare",
@@ -21494,8 +21494,8 @@ o_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/ru-RU.mjs
-var s_ = {};
-s_ = {
+var c_ = {};
+c_ = {
deselectedItem: (e) => `${e.item} \u{43D}\u{435} \u{432}\u{44B}\u{431}\u{440}\u{430}\u{43D}\u{43E}.`,
longPressToSelect: "Нажмите и удерживайте для входа в режим выбора.",
select: "Выбрать",
@@ -21509,8 +21509,8 @@ s_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/sk-SK.mjs
-var c_ = {};
-c_ = {
+var l_ = {};
+l_ = {
deselectedItem: (e) => `Nevybrat\xe9 polo\u{17E}ky: ${e.item}.`,
longPressToSelect: "Dlhším stlačením prejdite do režimu výberu.",
select: "Vybrať",
@@ -21524,8 +21524,8 @@ c_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/sl-SI.mjs
-var l_ = {};
-l_ = {
+var u_ = {};
+u_ = {
deselectedItem: (e) => `Element ${e.item} ni izbran.`,
longPressToSelect: "Za izbirni način pritisnite in dlje časa držite.",
select: "Izberite",
@@ -21539,8 +21539,8 @@ l_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/sr-SP.mjs
-var u_ = {};
-u_ = {
+var d_ = {};
+d_ = {
deselectedItem: (e) => `${e.item} nije izabrano.`,
longPressToSelect: "Dugo pritisnite za ulazak u režim biranja.",
select: "Izaberite",
@@ -21554,8 +21554,8 @@ u_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/sv-SE.mjs
-var d_ = {};
-d_ = {
+var f_ = {};
+f_ = {
deselectedItem: (e) => `${e.item} ej markerat.`,
longPressToSelect: "Tryck länge när du vill öppna väljarläge.",
select: "Markera",
@@ -21569,8 +21569,8 @@ d_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/tr-TR.mjs
-var f_ = {};
-f_ = {
+var p_ = {};
+p_ = {
deselectedItem: (e) => `${e.item} se\xe7ilmedi.`,
longPressToSelect: "Seçim moduna girmek için uzun basın.",
select: "Seç",
@@ -21584,8 +21584,8 @@ f_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/uk-UA.mjs
-var p_ = {};
-p_ = {
+var m_ = {};
+m_ = {
deselectedItem: (e) => `${e.item} \u{43D}\u{435} \u{432}\u{438}\u{431}\u{440}\u{430}\u{43D}\u{43E}.`,
longPressToSelect: "Виконайте довге натиснення, щоб перейти в режим вибору.",
select: "Вибрати",
@@ -21599,8 +21599,8 @@ p_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/zh-CN.mjs
-var m_ = {};
-m_ = {
+var h_ = {};
+h_ = {
deselectedItem: (e) => `\u{672A}\u{9009}\u{62E9} ${e.item}\u{3002}`,
longPressToSelect: "长按以进入选择模式。",
select: "选择",
@@ -21614,8 +21614,8 @@ m_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/grid/zh-TW.mjs
-var h_ = {};
-h_ = {
+var g_ = {};
+g_ = {
deselectedItem: (e) => `\u{672A}\u{9078}\u{53D6}\u{300C}${e.item}\u{300D}\u{3002}`,
longPressToSelect: "長按以進入選擇模式。",
select: "選取",
@@ -21629,55 +21629,55 @@ h_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/grid/intlStrings.mjs
-var g_ = {};
-g_ = {
- "ar-AE": Ig,
- "bg-BG": Lg,
- "cs-CZ": Rg,
- "da-DK": zg,
- "de-DE": Bg,
- "el-GR": Vg,
- "en-US": Hg,
- "es-ES": Ug,
- "et-EE": Wg,
- "fi-FI": Gg,
- "fr-FR": Kg,
- "he-IL": qg,
- "hr-HR": Jg,
- "hu-HU": Yg,
- "it-IT": Xg,
- "ja-JP": Zg,
- "ko-KR": Qg,
- "lt-LT": $g,
- "lv-LV": e_,
- "nb-NO": t_,
- "nl-NL": n_,
- "pl-PL": r_,
- "pt-BR": i_,
- "pt-PT": a_,
- "ro-RO": o_,
- "ru-RU": s_,
- "sk-SK": c_,
- "sl-SI": l_,
- "sr-SP": u_,
- "sv-SE": d_,
- "tr-TR": f_,
- "uk-UA": p_,
- "zh-CN": m_,
- "zh-TW": h_
+var __ = {};
+__ = {
+ "ar-AE": Lg,
+ "bg-BG": Rg,
+ "cs-CZ": zg,
+ "da-DK": Bg,
+ "de-DE": Vg,
+ "el-GR": Hg,
+ "en-US": Ug,
+ "es-ES": Wg,
+ "et-EE": Gg,
+ "fi-FI": Kg,
+ "fr-FR": qg,
+ "he-IL": Jg,
+ "hr-HR": Yg,
+ "hu-HU": Xg,
+ "it-IT": Zg,
+ "ja-JP": Qg,
+ "ko-KR": $g,
+ "lt-LT": e_,
+ "lv-LV": t_,
+ "nb-NO": n_,
+ "nl-NL": r_,
+ "pl-PL": i_,
+ "pt-BR": a_,
+ "pt-PT": o_,
+ "ro-RO": s_,
+ "ru-RU": c_,
+ "sk-SK": l_,
+ "sl-SI": u_,
+ "sr-SP": d_,
+ "sv-SE": f_,
+ "tr-TR": p_,
+ "uk-UA": m_,
+ "zh-CN": h_,
+ "zh-TW": g_
};
//#endregion
//#region node_modules/react-aria/dist/private/grid/useGridSelectionAnnouncement.mjs
-function _ee(e) {
+function gee(e) {
return e && e.__esModule ? e.default : e;
}
-function vee(e, t) {
- let { getRowText: n = (e) => t.collection.getTextValue?.(e) ?? t.collection.getItem(e)?.textValue } = e, r = ec(_ee(g_), "@react-aria/grid"), i = t.selectionManager.rawSelection, a = (0, R.useRef)(i), o = (0, R.useCallback)(() => {
+function _ee(e, t) {
+ let { getRowText: n = (e) => t.collection.getTextValue?.(e) ?? t.collection.getItem(e)?.textValue } = e, r = ec(gee(__), "@react-aria/grid"), i = t.selectionManager.rawSelection, a = (0, R.useRef)(i), o = (0, R.useCallback)(() => {
if (!t.selectionManager.isFocused || i === a.current) {
a.current = i;
return;
}
- let e = __(i, a.current), o = __(a.current, i), s = t.selectionManager.selectionBehavior === "replace", c = [];
+ let e = v_(i, a.current), o = v_(a.current, i), s = t.selectionManager.selectionBehavior === "replace", c = [];
if (t.selectionManager.selectedKeys.size === 1 && s) {
let e = t.selectionManager.selectedKeys.keys().next().value;
if (e != null && t.collection.getItem(e)) {
@@ -21716,7 +21716,7 @@ function vee(e, t) {
}
}, [i, t.selectionManager.isFocused]);
}
-function __(e, t) {
+function v_(e, t) {
let n = /* @__PURE__ */ new Set();
if (e === "all" || t === "all") return n;
for (let r of e.keys()) t.has(r) || n.add(r);
@@ -21724,7 +21724,7 @@ function __(e, t) {
}
//#endregion
//#region node_modules/react-aria/dist/private/focus/useHasTabbableChild.mjs
-function v_(e, t) {
+function y_(e, t) {
let n = t?.isDisabled, [r, i] = (0, R.useState)(!1);
return sa(() => {
if (e?.current && !n) {
@@ -21749,11 +21749,11 @@ function v_(e, t) {
}
//#endregion
//#region node_modules/react-aria/dist/private/grid/useHighlightSelectionDescription.mjs
-function yee(e) {
+function vee(e) {
return e && e.__esModule ? e.default : e;
}
-function bee(e) {
- let t = ec(yee(g_), "@react-aria/grid"), n = vs(), r = (n === "pointer" || n === "virtual" || n == null) && typeof window < "u" && "ontouchstart" in window;
+function yee(e) {
+ let t = ec(vee(__), "@react-aria/grid"), n = vs(), r = (n === "pointer" || n === "virtual" || n == null) && typeof window < "u" && "ontouchstart" in window;
return Ou((0, R.useMemo)(() => {
let n = e.selectionManager.selectionMode, i = e.selectionManager.selectionBehavior, a;
return r && (a = t.format("longPressToSelect")), i === "replace" && n !== "none" && e.hasItemActions ? a : void 0;
@@ -21767,14 +21767,14 @@ function bee(e) {
}
//#endregion
//#region node_modules/react-aria/dist/private/grid/useGridSelectionCheckbox.mjs
-function xee(e) {
+function bee(e) {
return e && e.__esModule ? e.default : e;
}
-function See(e, t) {
+function xee(e, t) {
let { key: n } = e, r = t.selectionManager, i = Ta(), a = !t.selectionManager.canSelectItem(n), o = t.selectionManager.isSelected(n);
return { checkboxProps: {
id: i,
- "aria-label": ec(xee(g_), "@react-aria/grid").format("select"),
+ "aria-label": ec(bee(__), "@react-aria/grid").format("select"),
isSelected: o,
isDisabled: a,
onChange: () => r.toggleSelection(n)
@@ -21782,7 +21782,7 @@ function See(e, t) {
}
//#endregion
//#region node_modules/react-aria/dist/private/overlays/useModalOverlay.mjs
-function Cee(e, t, n) {
+function See(e, t, n) {
let { overlayProps: r, underlayProps: i } = Mm({
...e,
isOpen: t.isOpen,
@@ -21797,19 +21797,19 @@ function Cee(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/utils/useViewportSize.mjs
-var y_ = typeof document < "u" && window.visualViewport;
-function wee() {
+var b_ = typeof document < "u" && window.visualViewport;
+function Cee() {
let e = ya(), [t, n] = (0, R.useState)(() => e ? {
width: 0,
height: 0
- } : b_());
+ } : x_());
return (0, R.useEffect)(() => {
let e = (e) => {
n((t) => e.width === t.width && e.height === t.height ? t : e);
}, t = () => {
- y_ && y_.scale > 1 || e(b_());
+ b_ && b_.scale > 1 || e(x_());
}, r, i = (t) => {
- y_ && y_.scale > 1 || Ts(Y(t)) && (r = requestAnimationFrame(() => {
+ b_ && b_.scale > 1 || Ts(Y(t)) && (r = requestAnimationFrame(() => {
let t = no();
(!t || !Ts(t)) && e({
width: document.documentElement.clientWidth,
@@ -21817,26 +21817,26 @@ function wee() {
});
}));
};
- return e(b_()), Io() && Ro() && window.addEventListener("blur", i, !0), y_ ? y_.addEventListener("resize", t) : window.addEventListener("resize", t), () => {
- cancelAnimationFrame(r), Io() && Ro() && window.removeEventListener("blur", i, !0), y_ ? y_.removeEventListener("resize", t) : window.removeEventListener("resize", t);
+ return e(x_()), Io() && Ro() && window.addEventListener("blur", i, !0), b_ ? b_.addEventListener("resize", t) : window.addEventListener("resize", t), () => {
+ cancelAnimationFrame(r), Io() && Ro() && window.removeEventListener("blur", i, !0), b_ ? b_.removeEventListener("resize", t) : window.removeEventListener("resize", t);
};
}, []), t;
}
-function b_() {
+function x_() {
return {
- width: y_ ? Math.min(y_.width * y_.scale, document.documentElement.clientWidth) : document.documentElement.clientWidth,
- height: y_ ? y_.height * y_.scale : document.documentElement.clientHeight
+ width: b_ ? Math.min(b_.width * b_.scale, document.documentElement.clientWidth) : document.documentElement.clientWidth,
+ height: b_ ? b_.height * b_.scale : document.documentElement.clientHeight
};
}
//#endregion
//#region node_modules/react-aria-components/dist/private/Modal.mjs
-var Tee = /*#__PURE__*/ (0, R.createContext)(null), x_ = /*#__PURE__*/ (0, R.createContext)(null), Eee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- if ((0, R.useContext)(x_)) return /*#__PURE__*/ R.createElement(C_, {
+var wee = /*#__PURE__*/ (0, R.createContext)(null), S_ = /*#__PURE__*/ (0, R.createContext)(null), Tee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ if ((0, R.useContext)(S_)) return /*#__PURE__*/ R.createElement(w_, {
...e,
modalRef: t
}, e.children);
let { isDismissable: n, isKeyboardDismissDisabled: r, isOpen: i, defaultOpen: a, onOpenChange: o, children: s, isEntering: c, isExiting: l, UNSTABLE_portalContainer: u, shouldCloseOnInteractOutside: d, ...f } = e;
- return /*#__PURE__*/ R.createElement(S_, {
+ return /*#__PURE__*/ R.createElement(C_, {
isDismissable: n,
isKeyboardDismissDisabled: r,
isOpen: i,
@@ -21846,15 +21846,15 @@ var Tee = /*#__PURE__*/ (0, R.createContext)(null), x_ = /*#__PURE__*/ (0, R.cre
isExiting: l,
UNSTABLE_portalContainer: u,
shouldCloseOnInteractOutside: d
- }, /*#__PURE__*/ R.createElement(C_, {
+ }, /*#__PURE__*/ R.createElement(w_, {
...f,
modalRef: t
}, s));
});
-function Dee(e, t) {
- [e, t] = La(e, t, Tee);
- let n = (0, R.useContext)(Pg), r = Nh(e), i = e.isOpen != null || e.defaultOpen != null || !n ? r : n, a = Ma(t), o = (0, R.useRef)(null), s = Fh(a, i.isOpen), c = Fh(o, i.isOpen), l = s || c || e.isExiting || !1, u = ya();
- return !i.isOpen && !l || u ? null : /*#__PURE__*/ R.createElement(Oee, {
+function Eee(e, t) {
+ [e, t] = La(e, t, wee);
+ let n = (0, R.useContext)(Fg), r = Nh(e), i = e.isOpen != null || e.defaultOpen != null || !n ? r : n, a = Ma(t), o = (0, R.useRef)(null), s = Fh(a, i.isOpen), c = Fh(o, i.isOpen), l = s || c || e.isExiting || !1, u = ya();
+ return !i.isOpen && !l || u ? null : /*#__PURE__*/ R.createElement(Dee, {
...e,
state: i,
isExiting: l,
@@ -21862,9 +21862,9 @@ function Dee(e, t) {
modalRef: o
});
}
-var S_ = /*#__PURE__*/ (0, R.forwardRef)(Dee);
-function Oee({ UNSTABLE_portalContainer: e, ...t }) {
- let n = t.modalRef, { state: r } = t, { modalProps: i, underlayProps: a } = Cee(t, r, n), o = Ph(t.overlayRef) || t.isEntering || !1, s = Fa({
+var C_ = /*#__PURE__*/ (0, R.forwardRef)(Eee);
+function Dee({ UNSTABLE_portalContainer: e, ...t }) {
+ let n = t.modalRef, { state: r } = t, { modalProps: i, underlayProps: a } = See(t, r, n), o = Ph(t.overlayRef) || t.isEntering || !1, s = Fa({
...t,
defaultClassName: "react-aria-ModalOverlay",
values: {
@@ -21872,7 +21872,7 @@ function Oee({ UNSTABLE_portalContainer: e, ...t }) {
isExiting: t.isExiting,
state: r
}
- }), c = wee(), l, u;
+ }), c = Cee(), l, u;
if (typeof document < "u") {
let e = bu(document.body) ? document.body : document.scrollingElement || document.documentElement, t = e.getBoundingClientRect().width % 1, n = e.getBoundingClientRect().height % 1;
l = e.scrollWidth - t, u = e.scrollHeight - n;
@@ -21894,15 +21894,15 @@ function Oee({ UNSTABLE_portalContainer: e, ...t }) {
ref: t.overlayRef,
"data-entering": o || void 0,
"data-exiting": t.isExiting || void 0
- }, /*#__PURE__*/ R.createElement(Pa, { values: [[x_, {
+ }, /*#__PURE__*/ R.createElement(Pa, { values: [[S_, {
modalProps: i,
modalRef: n,
isExiting: t.isExiting,
isDismissable: t.isDismissable
- }], [Pg, r]] }, s.children)));
+ }], [Fg, r]] }, s.children)));
}
-function C_(e) {
- let { modalProps: t, modalRef: n, isExiting: r, isDismissable: i } = (0, R.useContext)(x_), a = (0, R.useContext)(Pg), o = Ma((0, R.useMemo)(() => Oa(e.modalRef, n), [e.modalRef, n])), s = Ph(o), c = Fa({
+function w_(e) {
+ let { modalProps: t, modalRef: n, isExiting: r, isDismissable: i } = (0, R.useContext)(S_), a = (0, R.useContext)(Fg), o = Ma((0, R.useMemo)(() => Oa(e.modalRef, n), [e.modalRef, n])), s = Ph(o), c = Fa({
...e,
defaultClassName: "react-aria-Modal",
values: {
@@ -21921,10 +21921,10 @@ function C_(e) {
}
//#endregion
//#region node_modules/react-aria/dist/private/radio/utils.mjs
-var w_ = /* @__PURE__ */ new WeakMap();
+var T_ = /* @__PURE__ */ new WeakMap();
//#endregion
//#region node_modules/react-aria/dist/private/radio/useRadio.mjs
-function kee(e, t, n) {
+function Oee(e, t, n) {
let { value: r, children: i, "aria-label": a, "aria-labelledby": o, onPressStart: s, onPressEnd: c, onPressChange: l, onPress: u, onPressUp: d, onClick: f } = e, p = e.isDisabled || t.isDisabled, m = t.selectedValue === r, h = (e) => {
e.stopPropagation(), t.setSelectedValue(r);
}, { pressProps: g, isPressed: _ } = zl({
@@ -21947,7 +21947,7 @@ function kee(e, t, n) {
}
}), { focusableProps: b } = Vc(J(e, { onFocus: () => t.setLastFocusedValue(r) }), n), x = J(g, b), S = Cl(e, { labelable: !0 }), C = -1;
t.selectedValue == null ? (t.lastFocusedValue === r || t.lastFocusedValue == null) && (C = 0) : t.selectedValue === r && (C = 0), p && (C = void 0);
- let { name: w, form: T, descriptionId: E, errorMessageId: D, validationBehavior: O } = w_.get(t);
+ let { name: w, form: T, descriptionId: E, errorMessageId: D, validationBehavior: O } = T_.get(t);
qu(n, t.defaultSelectedValue, t.setSelectedValue), Ju({ validationBehavior: O }, t, n);
let k = $u();
return {
@@ -21981,7 +21981,7 @@ function kee(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/radio/useRadioGroup.mjs
-function Aee(e, t) {
+function kee(e, t) {
let { name: n, form: r, isReadOnly: i, isRequired: a, isDisabled: o, orientation: s = "vertical", validationBehavior: c = "aria" } = e, { direction: l } = Bs(), { isInvalid: u, validationErrors: d, validationDetails: f } = t.displayValidation, { labelProps: p, fieldProps: m, descriptionProps: h, errorMessageProps: g } = Ku({
...e,
labelElementType: "span",
@@ -22010,7 +22010,7 @@ function Aee(e, t) {
},
allowRepeats: !0
}), x = Ta(n);
- return w_.set(t, {
+ return T_.set(t, {
name: x,
form: r,
descriptionId: h.id,
@@ -22039,9 +22039,9 @@ function Aee(e, t) {
}
//#endregion
//#region node_modules/react-stately/dist/private/radio/useRadioGroupState.mjs
-var jee = Math.round(Math.random() * 1e10), Mee = 0;
-function Nee(e) {
- let t = (0, R.useMemo)(() => e.name || `radio-group-${jee}-${++Mee}`, [e.name]), [n, r] = nc(e.value, e.defaultValue ?? null, e.onChange), [i] = (0, R.useState)(n), [a, o] = (0, R.useState)(null), s = Ru({
+var Aee = Math.round(Math.random() * 1e10), jee = 0;
+function Mee(e) {
+ let t = (0, R.useMemo)(() => e.name || `radio-group-${Aee}-${++jee}`, [e.name]), [n, r] = nc(e.value, e.defaultValue ?? null, e.onChange), [i] = (0, R.useState)(n), [a, o] = (0, R.useState)(null), s = Ru({
...e,
value: n
}), c = (t) => {
@@ -22064,12 +22064,12 @@ function Nee(e) {
}
//#endregion
//#region node_modules/react-aria-components/dist/private/RadioGroup.mjs
-var Pee = /*#__PURE__*/ (0, R.createContext)(null), Fee = /*#__PURE__*/ (0, R.createContext)(null), T_ = /*#__PURE__*/ (0, R.createContext)(null), E_ = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- [e, t] = La(e, t, Pee);
- let { validationBehavior: n } = Ia(Wu) || {}, r = e.validationBehavior ?? n ?? "native", i = Nee({
+var Nee = /*#__PURE__*/ (0, R.createContext)(null), Pee = /*#__PURE__*/ (0, R.createContext)(null), E_ = /*#__PURE__*/ (0, R.createContext)(null), D_ = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ [e, t] = La(e, t, Nee);
+ let { validationBehavior: n } = Ia(Wu) || {}, r = e.validationBehavior ?? n ?? "native", i = Mee({
...e,
validationBehavior: r
- }), [a, o] = Ra(!e["aria-label"] && !e["aria-labelledby"]), { radioGroupProps: s, labelProps: c, descriptionProps: l, errorMessageProps: u, ...d } = Aee({
+ }), [a, o] = Ra(!e["aria-label"] && !e["aria-labelledby"]), { radioGroupProps: s, labelProps: c, descriptionProps: l, errorMessageProps: u, ...d } = kee({
...e,
label: o,
validationBehavior: r
@@ -22095,7 +22095,7 @@ var Pee = /*#__PURE__*/ (0, R.createContext)(null), Fee = /*#__PURE__*/ (0, R.cr
"data-readonly": i.isReadOnly || void 0,
"data-required": i.isRequired || void 0
}, /*#__PURE__*/ R.createElement(Pa, { values: [
- [T_, i],
+ [E_, i],
[tu, {
...c,
ref: a,
@@ -22107,23 +22107,23 @@ var Pee = /*#__PURE__*/ (0, R.createContext)(null), Fee = /*#__PURE__*/ (0, R.cr
} }],
[Mu, d]
] }, /*#__PURE__*/ R.createElement(of, null, f.children)));
-}), D_ = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+}), O_ = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { inputRef: n = null, ...r } = e;
- [e, t] = La(r, t, Fee);
- let i = R.useContext(T_), a = Ma((0, R.useMemo)(() => Oa(n, e.inputRef === void 0 ? null : e.inputRef), [n, e.inputRef])), o = kee({
+ [e, t] = La(r, t, Pee);
+ let i = R.useContext(E_), a = Ma((0, R.useMemo)(() => Oa(n, e.inputRef === void 0 ? null : e.inputRef), [n, e.inputRef])), o = Oee({
...za(e),
children: typeof e.children == "function" || e.children
}, i, a);
- return /*#__PURE__*/ R.createElement(O_.Provider, { value: {
+ return /*#__PURE__*/ R.createElement(k_.Provider, { value: {
...o,
inputRef: a,
defaultClassName: "react-aria-Radio"
- } }, /*#__PURE__*/ R.createElement(Iee, {
+ } }, /*#__PURE__*/ R.createElement(Fee, {
...e,
ref: t
}));
-}), O_ = /*#__PURE__*/ (0, R.createContext)(null), Iee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- let { labelProps: n, inputProps: r, isSelected: i, isDisabled: a, isPressed: o, defaultClassName: s, inputRef: c } = (0, R.useContext)(O_), l = R.useContext(T_), { isFocused: u, isFocusVisible: d, focusProps: f } = Jl(), p = a || l.isReadOnly, { hoverProps: m, isHovered: h } = eu({
+}), k_ = /*#__PURE__*/ (0, R.createContext)(null), Fee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ let { labelProps: n, inputProps: r, isSelected: i, isDisabled: a, isPressed: o, defaultClassName: s, inputRef: c } = (0, R.useContext)(k_), l = R.useContext(E_), { isFocused: u, isFocusVisible: d, focusProps: f } = Jl(), p = a || l.isReadOnly, { hoverProps: m, isHovered: h } = eu({
...e,
isDisabled: p
}), g = Fa({
@@ -22157,8 +22157,8 @@ var Pee = /*#__PURE__*/ (0, R.createContext)(null), Fee = /*#__PURE__*/ (0, R.cr
...J(r, f),
ref: c
})), g.children);
-}), k_ = /* @__PURE__ */ new WeakMap();
-function Lee(e, t, n) {
+}), A_ = /* @__PURE__ */ new WeakMap();
+function Iee(e, t, n) {
let { keyboardDelegate: r, isDisabled: i, isRequired: a, name: o, form: s, validationBehavior: c = "aria" } = e, l = np({
usage: "search",
sensitivity: "base"
@@ -22201,7 +22201,7 @@ function Lee(e, t, n) {
});
t.selectionManager.selectionMode === "multiple" && (m = {});
let S = Cl(e, { labelable: !0 }), C = J(m, d, y), w = Ta();
- return k_.set(t, {
+ return A_.set(t, {
isDisabled: i,
isRequired: a,
name: o,
@@ -22262,8 +22262,8 @@ function Lee(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/select/HiddenSelect.mjs
-function Ree(e, t, n) {
- let r = k_.get(t) || {}, { autoComplete: i, name: a = r.name, form: o = r.form, isDisabled: s = r.isDisabled } = e, { validationBehavior: c, isRequired: l } = r, { visuallyHiddenProps: u } = Au({ style: {
+function Lee(e, t, n) {
+ let r = A_.get(t) || {}, { autoComplete: i, name: a = r.name, form: o = r.form, isDisabled: s = r.isDisabled } = e, { validationBehavior: c, isRequired: l } = r, { visuallyHiddenProps: u } = Au({ style: {
position: "fixed",
top: 0,
left: 0
@@ -22298,8 +22298,8 @@ function Ree(e, t, n) {
}
};
}
-function zee(e) {
- let { state: t, triggerRef: n, label: r, name: i, form: a, isDisabled: o } = e, s = (0, R.useRef)(null), c = (0, R.useRef)(null), { containerProps: l, selectProps: u } = Ree({
+function Ree(e) {
+ let { state: t, triggerRef: n, label: r, name: i, form: a, isDisabled: o } = e, s = (0, R.useRef)(null), c = (0, R.useRef)(null), { containerProps: l, selectProps: u } = Lee({
...e,
selectRef: t.collection.size <= 300 ? s : c
}, t, n), d = Array.isArray(t.value) ? t.value : [t.value];
@@ -22323,7 +22323,7 @@ function zee(e) {
value: e ?? ""
})))));
if (i) {
- let { validationBehavior: e } = k_.get(t) || {};
+ let { validationBehavior: e } = A_.get(t) || {};
d.length === 0 && (d = [null]);
let n = d.map((t, n) => {
let r = {
@@ -22354,7 +22354,7 @@ function zee(e) {
}
//#endregion
//#region node_modules/react-stately/dist/private/select/useSelectState.mjs
-function Bee(e) {
+function zee(e) {
let { selectionMode: t = "single", shouldCloseOnSelect: n = t === "single" } = e, r = Nh(e), [i, a] = (0, R.useState)(null), o = (0, R.useMemo)(() => e.defaultValue === void 0 ? t === "single" ? e.defaultSelectedKey ?? null : [] : e.defaultValue, [
e.defaultValue,
e.defaultSelectedKey,
@@ -22376,7 +22376,7 @@ function Bee(e) {
selectionMode: t,
disallowEmptySelection: t === "single",
allowDuplicateSelectionEvents: !0,
- selectedKeys: (0, R.useMemo)(() => Vee(l), [l]),
+ selectedKeys: (0, R.useMemo)(() => Bee(l), [l]),
onSelectionChange: (e) => {
if (e !== "all") {
if (t === "single") {
@@ -22413,16 +22413,16 @@ function Bee(e) {
setFocused: g
};
}
-function Vee(e) {
+function Bee(e) {
if (e !== void 0) return e === null ? [] : Array.isArray(e) ? e : [e];
}
//#endregion
//#region node_modules/react-aria-components/dist/private/Select.mjs
-function Hee(e) {
+function Vee(e) {
return e && e.__esModule ? e.default : e;
}
-var A_ = /*#__PURE__*/ (0, R.createContext)(null), j_ = /*#__PURE__*/ (0, R.createContext)(null), Uee = /*#__PURE__*/ Wc(function(e, t) {
- [e, t] = La(e, t, A_);
+var j_ = /*#__PURE__*/ (0, R.createContext)(null), M_ = /*#__PURE__*/ (0, R.createContext)(null), Hee = /*#__PURE__*/ Wc(function(e, t) {
+ [e, t] = La(e, t, j_);
let { children: n, isDisabled: r = !1, isInvalid: i = !1, isRequired: a = !1 } = e, o = (0, R.useMemo)(() => typeof n == "function" ? n({
isOpen: !1,
isDisabled: r,
@@ -22437,23 +22437,23 @@ var A_ = /*#__PURE__*/ (0, R.createContext)(null), j_ = /*#__PURE__*/ (0, R.crea
i,
a
]);
- return /*#__PURE__*/ R.createElement(Zc, { content: o }, (n) => /*#__PURE__*/ R.createElement(Gee, {
+ return /*#__PURE__*/ R.createElement(Zc, { content: o }, (n) => /*#__PURE__*/ R.createElement(Wee, {
props: e,
collection: n,
selectRef: t
}));
-}), Wee = [
+}), Uee = [
tu,
du,
_u
];
-function Gee({ props: e, selectRef: t, collection: n }) {
- let { validationBehavior: r } = Ia(Wu) || {}, i = e.validationBehavior ?? r ?? "native", a = Bee({
+function Wee({ props: e, selectRef: t, collection: n }) {
+ let { validationBehavior: r } = Ia(Wu) || {}, i = e.validationBehavior ?? r ?? "native", a = zee({
...e,
collection: n,
children: void 0,
validationBehavior: i
- }), { isFocusVisible: o, focusProps: s } = Jl({ within: !0 }), c = (0, R.useRef)(null), [l, u] = Ra(!e["aria-label"] && !e["aria-labelledby"]), { labelProps: d, triggerProps: f, valueProps: p, menuProps: m, descriptionProps: h, errorMessageProps: g, hiddenSelectProps: _, ...v } = Lee({
+ }), { isFocusVisible: o, focusProps: s } = Jl({ within: !0 }), c = (0, R.useRef)(null), [l, u] = Ra(!e["aria-label"] && !e["aria-labelledby"]), { labelProps: d, triggerProps: f, valueProps: p, menuProps: m, descriptionProps: h, errorMessageProps: g, hiddenSelectProps: _, ...v } = Iee({
...za(e),
label: u,
validationBehavior: i
@@ -22479,9 +22479,9 @@ function Gee({ props: e, selectRef: t, collection: n }) {
delete x.id;
let S = (0, R.useRef)(null);
return /*#__PURE__*/ R.createElement(Pa, { values: [
- [A_, e],
- [j_, a],
- [M_, p],
+ [j_, e],
+ [M_, a],
+ [N_, p],
[tu, {
...d,
ref: l,
@@ -22493,14 +22493,14 @@ function Gee({ props: e, selectRef: t, collection: n }) {
isPressed: a.isOpen,
autoFocus: e.autoFocus
}],
- [Pg, a],
+ [Fg, a],
[Lh, {
trigger: "Select",
triggerRef: c,
scrollRef: S,
placement: "bottom start",
"aria-labelledby": m["aria-labelledby"],
- clearContexts: Wee
+ clearContexts: Uee
}],
[Ip, {
...m,
@@ -22522,14 +22522,14 @@ function Gee({ props: e, selectRef: t, collection: n }) {
"data-disabled": e.isDisabled || void 0,
"data-invalid": v.isInvalid || void 0,
"data-required": e.isRequired || void 0
- }, b.children, /*#__PURE__*/ R.createElement(zee, {
+ }, b.children, /*#__PURE__*/ R.createElement(Ree, {
..._,
autoComplete: e.autoComplete
})));
}
-var M_ = /*#__PURE__*/ (0, R.createContext)(null), Kee = /*#__PURE__*/ Wc(function(e, t) {
- [e, t] = La(e, t, M_);
- let n = (0, R.useContext)(j_), { placeholder: r } = Ia(A_), i = n.selectedItems.map((e) => {
+var N_ = /*#__PURE__*/ (0, R.createContext)(null), Gee = /*#__PURE__*/ Wc(function(e, t) {
+ [e, t] = La(e, t, N_);
+ let n = (0, R.useContext)(M_), { placeholder: r } = Ia(j_), i = n.selectedItems.map((e) => {
let t = e.props?.children;
return typeof t == "function" && (t = t({
isHovered: !1,
@@ -22541,7 +22541,7 @@ var M_ = /*#__PURE__*/ (0, R.createContext)(null), Kee = /*#__PURE__*/ Wc(functi
selectionMode: "single",
selectionBehavior: "toggle"
})), t;
- }), a = gee(), o = (0, R.useMemo)(() => n.selectedItems.map((e) => e?.textValue), [n.selectedItems]), s = n.selectionManager.selectionMode, c = (0, R.useMemo)(() => s === "single" ? o[0] ?? "" : a.format(o), [
+ }), a = hee(), o = (0, R.useMemo)(() => n.selectedItems.map((e) => e?.textValue), [n.selectedItems]), s = n.selectionManager.selectionMode, c = (0, R.useMemo)(() => s === "single" ? o[0] ?? "" : a.format(o), [
s,
a,
o
@@ -22556,7 +22556,7 @@ var M_ = /*#__PURE__*/ (0, R.createContext)(null), Kee = /*#__PURE__*/ Wc(functi
a,
o,
i
- ]), u = ec(Hee(Zd), "react-aria-components"), d = Fa({
+ ]), u = ec(Vee(Zd), "react-aria-components"), d = Fa({
...e,
defaultChildren: l ?? r ?? u.format("selectPlaceholder"),
defaultClassName: "react-aria-SelectValue",
@@ -22577,7 +22577,7 @@ var M_ = /*#__PURE__*/ (0, R.createContext)(null), Kee = /*#__PURE__*/ Wc(functi
});
//#endregion
//#region node_modules/react-aria/dist/private/switch/useSwitch.mjs
-function qee(e, t, n) {
+function Kee(e, t, n) {
let { labelProps: r, inputProps: i, isSelected: a, ...o } = ed(e, t, n);
return {
labelProps: r,
@@ -22590,23 +22590,23 @@ function qee(e, t, n) {
...o
};
}
-for (var Jee = /*#__PURE__*/ (0, R.createContext)(null), N_ = /*#__PURE__*/ (0, R.createContext)(null), Yee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+for (var qee = /*#__PURE__*/ (0, R.createContext)(null), P_ = /*#__PURE__*/ (0, R.createContext)(null), Jee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { inputRef: n = null, ...r } = e;
- [e, t] = La(r, t, Jee);
- let i = Ma((0, R.useMemo)(() => Oa(n, e.inputRef === void 0 ? null : e.inputRef), [n, e.inputRef])), a = nd(e), o = qee({
+ [e, t] = La(r, t, qee);
+ let i = Ma((0, R.useMemo)(() => Oa(n, e.inputRef === void 0 ? null : e.inputRef), [n, e.inputRef])), a = nd(e), o = Kee({
...za(e),
children: typeof e.children == "function" || e.children
}, a, i);
- return /*#__PURE__*/ R.createElement(Pa, { values: [[N_, a], [P_, {
+ return /*#__PURE__*/ R.createElement(Pa, { values: [[P_, a], [F_, {
...o,
inputRef: i,
defaultClassName: "react-aria-Switch"
- }]] }, /*#__PURE__*/ R.createElement(Xee, {
+ }]] }, /*#__PURE__*/ R.createElement(Yee, {
...e,
ref: t
}));
-}), P_ = /*#__PURE__*/ (0, R.createContext)(null), Xee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- let { labelProps: n, inputProps: r, isSelected: i, isDisabled: a, isReadOnly: o, isPressed: s, isInvalid: c, inputRef: l, defaultClassName: u, isRequired: d } = (0, R.useContext)(P_), { isFocused: f, isFocusVisible: p, focusProps: m } = Jl(), h = a || o, g = (0, R.useContext)(N_), { hoverProps: _, isHovered: v } = eu({
+}), F_ = /*#__PURE__*/ (0, R.createContext)(null), Yee = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ let { labelProps: n, inputProps: r, isSelected: i, isDisabled: a, isReadOnly: o, isPressed: s, isInvalid: c, inputRef: l, defaultClassName: u, isRequired: d } = (0, R.useContext)(F_), { isFocused: f, isFocusVisible: p, focusProps: m } = Jl(), h = a || o, g = (0, R.useContext)(P_), { hoverProps: _, isHovered: v } = eu({
...e,
isDisabled: h
}), y = Fa({
@@ -22642,7 +22642,7 @@ for (var Jee = /*#__PURE__*/ (0, R.createContext)(null), N_ = /*#__PURE__*/ (0,
...J(r, m),
ref: l
})), y.children);
-}), F_ = 10, I_ = 5, Zee = class {
+}), I_ = 10, L_ = 5, R_ = class {
setup(e, t, n) {
this.delegate = e, this.state = t, this.direction = n;
}
@@ -22652,7 +22652,7 @@ for (var Jee = /*#__PURE__*/ (0, R.createContext)(null), N_ = /*#__PURE__*/ (0,
}
resolveDropTarget(e, t, n, r) {
let i = this.pointerTracking, a = n - i.lastY, o = t - i.lastX, s = i.yDirection, c = i.xDirection;
- if (Math.abs(a) > I_ && (s = a > 0 ? "down" : "up", i.yDirection = s, i.lastY = n), Math.abs(o) > F_ && (c = o > 0 ? "right" : "left", i.xDirection = c, i.lastX = t), e.dropPosition === "before") {
+ if (Math.abs(a) > L_ && (s = a > 0 ? "down" : "up", i.yDirection = s, i.lastY = n), Math.abs(o) > I_ && (c = o > 0 ? "right" : "left", i.xDirection = c, i.lastX = t), e.dropPosition === "before") {
let t = this.state.collection.getKeyBefore(e.key);
for (; t != null;) {
let e = this.state.collection.getItem(t);
@@ -22731,11 +22731,11 @@ for (var Jee = /*#__PURE__*/ (0, R.createContext)(null), N_ = /*#__PURE__*/ (0,
lastSwitchX: n
});
let c = o.boundaryContext, l = Math.abs(n - c.lastSwitchX);
- if (Math.abs(r - c.lastSwitchY) > I_ && i) {
+ if (Math.abs(r - c.lastSwitchY) > L_ && i) {
let t = c.preferredTargetIndex || 0;
i === "down" && t === 0 ? c.preferredTargetIndex = e.length - 1 : i === "up" && t === e.length - 1 && (c.preferredTargetIndex = 0), o.xDirection = null;
}
- if (l > F_ && a) {
+ if (l > I_ && a) {
let t = c.preferredTargetIndex || 0;
a === "left" ? this.direction === "ltr" ? t < e.length - 1 && (c.preferredTargetIndex = t + 1, c.lastSwitchX = n) : t > 0 && (c.preferredTargetIndex = t - 1, c.lastSwitchX = n) : a === "right" && (this.direction === "ltr" ? t > 0 && (c.preferredTargetIndex = t - 1, c.lastSwitchX = n) : t < e.length - 1 && (c.preferredTargetIndex = t + 1, c.lastSwitchX = n)), o.yDirection = null;
}
@@ -22750,7 +22750,7 @@ for (var Jee = /*#__PURE__*/ (0, R.createContext)(null), N_ = /*#__PURE__*/ (0,
boundaryContext: null
};
}
-}, Qee = class {
+}, z_ = class {
constructor(e) {
this.keyMap = /* @__PURE__ */ new Map(), this.keyMap = /* @__PURE__ */ new Map(), this.columnCount = e?.columnCount, this.rows = [];
let t = (r) => {
@@ -22820,8 +22820,8 @@ for (var Jee = /*#__PURE__*/ (0, R.createContext)(null), N_ = /*#__PURE__*/ (0,
getChildren(e) {
return this.keyMap.get(e)?.childNodes || [];
}
-}, L_ = "row-header-column-" + Math.random().toString(36).slice(2), R_ = "row-header-column-" + Math.random().toString(36).slice(2); L_ === R_;) R_ = "row-header-column-" + Math.random().toString(36).slice(2);
-function z_(e, t) {
+}, B_ = "row-header-column-" + Math.random().toString(36).slice(2), V_ = "row-header-column-" + Math.random().toString(36).slice(2); B_ === V_;) V_ = "row-header-column-" + Math.random().toString(36).slice(2);
+function H_(e, t) {
if (t.length === 0) return [];
let n = [], r = /* @__PURE__ */ new Map();
for (let i of t) {
@@ -22905,13 +22905,13 @@ function z_(e, t) {
textValue: ""
}));
}
-var $ee = class extends Qee {
+var Xee = class extends z_ {
constructor(e, t, n) {
let r = /* @__PURE__ */ new Set(), i = null, a = [];
if (n?.showSelectionCheckboxes) {
let e = {
type: "column",
- key: L_,
+ key: B_,
value: null,
textValue: "",
level: 0,
@@ -22926,7 +22926,7 @@ var $ee = class extends Qee {
if (n?.showDragButtons) {
let e = {
type: "column",
- key: R_,
+ key: V_,
value: null,
textValue: "",
level: 0,
@@ -22953,7 +22953,7 @@ var $ee = class extends Qee {
for (let t of e.childNodes) c(t);
};
for (let t of e) c(t);
- let l = z_(s, a);
+ let l = H_(s, a);
if (l.forEach((e, t) => o.splice(t, 0, e)), super({
columnCount: a.length,
items: o,
@@ -23014,7 +23014,7 @@ var $ee = class extends Qee {
};
//#endregion
//#region node_modules/react-stately/dist/private/grid/useGridState.mjs
-function ete(e) {
+function Zee(e) {
let { collection: t, focusMode: n } = e, r = e.UNSAFE_selectionState || wp(e), i = (0, R.useMemo)(() => e.disabledKeys ? new Set(e.disabledKeys) : /* @__PURE__ */ new Set(), [e.disabledKeys]), a = r.setFocusedKey;
r.setFocusedKey = (e, r) => {
if (n === "cell" && e != null) {
@@ -23065,11 +23065,11 @@ function ete(e) {
}
//#endregion
//#region node_modules/react-stately/dist/private/table/useTableState.mjs
-var tte = {
+var Qee = {
ascending: "descending",
descending: "ascending"
};
-function nte(e) {
+function $ee(e) {
let [t, n] = (0, R.useState)(!1), { selectionMode: r = "none", showSelectionCheckboxes: i, showDragButtons: a, treeColumn: o = null } = e, s = (0, R.useMemo)(() => ({
showSelectionCheckboxes: i && r !== "none",
showDragButtons: a,
@@ -23080,7 +23080,7 @@ function nte(e) {
i,
r,
a
- ]), c = jp(e, (0, R.useCallback)((e) => new $ee(e, null, s), [s]), s), { disabledKeys: l, selectionManager: u } = ete({
+ ]), c = jp(e, (0, R.useCallback)((e) => new Xee(e, null, s), [s]), s), { disabledKeys: l, selectionManager: u } = Zee({
...e,
collection: c,
disabledBehavior: e.disabledBehavior || "selection"
@@ -23096,7 +23096,7 @@ function nte(e) {
sort(t, n) {
e.onSortChange?.({
column: t,
- direction: n ?? (e.sortDescriptor?.column === t ? tte[e.sortDescriptor.direction] : "ascending")
+ direction: n ?? (e.sortDescriptor?.column === t ? Qee[e.sortDescriptor.direction] : "ascending")
});
},
expandedKeys: d,
@@ -23109,7 +23109,7 @@ function nte(e) {
treeColumn: o
};
}
-function rte(e, t) {
+function ete(e, t) {
let n = (0, R.useMemo)(() => t ? e.collection.filter(t) : e.collection, [e.collection, t]), r = e.selectionManager.withCollection(n);
return {
...e,
@@ -23119,10 +23119,10 @@ function rte(e, t) {
}
//#endregion
//#region node_modules/react-aria/dist/private/grid/GridKeyboardDelegate.mjs
-var B_ = class {
+var U_ = class {
constructor(e) {
if (this.collection = e.collection, this.disabledKeys = e.disabledKeys, this.disabledBehavior = e.disabledBehavior || "all", this.direction = e.direction, this.collator = e.collator, !e.layout && !e.ref) throw Error("Either a layout or a ref must be specified.");
- this.layoutDelegate = e.layoutDelegate || (e.layout ? new ite(e.layout) : new $f(e.ref)), this.focusMode = e.focusMode ?? "row";
+ this.layoutDelegate = e.layoutDelegate || (e.layout ? new tte(e.layout) : new $f(e.ref)), this.focusMode = e.focusMode ?? "row";
}
isCell(e) {
return e.type === "cell";
@@ -23288,7 +23288,7 @@ var B_ = class {
}
return null;
}
-}, ite = class {
+}, tte = class {
constructor(e) {
this.layout = e;
}
@@ -23301,16 +23301,16 @@ var B_ = class {
getVisibleRect() {
return this.layout.virtualizer.visibleRect;
}
-}, V_ = /* @__PURE__ */ new WeakMap();
+}, W_ = /* @__PURE__ */ new WeakMap();
//#endregion
//#region node_modules/react-aria/dist/private/grid/useGrid.mjs
-function ate(e, t, n) {
+function nte(e, t, n) {
let { isVirtualized: r, disallowTypeAhead: i, keyboardDelegate: a, focusMode: o, scrollRef: s, getRowText: c, onRowAction: l, onCellAction: u, escapeKeyBehavior: d = "clearSelection", shouldSelectOnPressUp: f, keyboardNavigationBehavior: p = "arrow" } = e, { selectionManager: m } = t;
!e["aria-label"] && !e["aria-labelledby"] && console.warn("An aria-label or aria-labelledby prop is required for accessibility.");
let h = np({
usage: "search",
sensitivity: "base"
- }), { direction: g } = Bs(), _ = t.selectionManager.disabledBehavior, v = (0, R.useMemo)(() => a || new B_({
+ }), { direction: g } = Bs(), _ = t.selectionManager.disabledBehavior, v = (0, R.useMemo)(() => a || new U_({
collection: t.collection,
disabledKeys: t.disabledKeys,
disabledBehavior: _,
@@ -23336,7 +23336,7 @@ function ate(e, t, n) {
disallowTypeAhead: i,
escapeKeyBehavior: d
}), b = Ta(e.id);
- V_.set(t, {
+ W_.set(t, {
keyboardDelegate: v,
actions: {
onRowAction: l,
@@ -23345,7 +23345,7 @@ function ate(e, t, n) {
shouldSelectOnPressUp: f,
keyboardNavigationBehavior: p
});
- let x = bee({
+ let x = yee({
selectionManager: m,
hasItemActions: !!(l || u)
}), S = Cl(e, { labelable: !0 }), C = (0, R.useCallback)((e) => {
@@ -23357,36 +23357,36 @@ function ate(e, t, n) {
}, [m]), w = (0, R.useMemo)(() => ({
onBlur: y.onBlur,
onFocus: C
- }), [C, y.onBlur]), T = v_(n, { isDisabled: t.collection.size !== 0 }), E = J(S, {
+ }), [C, y.onBlur]), T = y_(n, { isDisabled: t.collection.size !== 0 }), E = J(S, {
role: "grid",
id: b,
"aria-multiselectable": m.selectionMode === "multiple" ? "true" : void 0
}, t.isKeyboardNavigationDisabled ? w : y, t.collection.size === 0 && { tabIndex: T ? -1 : 0 } || void 0, x);
- return r && (E["aria-rowcount"] = t.collection.size, E["aria-colcount"] = t.collection.columnCount), vee({ getRowText: c }, t), { gridProps: E };
+ return r && (E["aria-rowcount"] = t.collection.size, E["aria-colcount"] = t.collection.columnCount), _ee({ getRowText: c }, t), { gridProps: E };
}
//#endregion
//#region node_modules/react-aria/dist/private/table/utils.mjs
-var H_ = /* @__PURE__ */ new WeakMap();
-function U_(e) {
+var G_ = /* @__PURE__ */ new WeakMap();
+function K_(e) {
return typeof e == "string" ? e.replace(/\s*/g, "") : "" + e;
}
-function ote(e, t) {
- let n = H_.get(e);
+function rte(e, t) {
+ let n = G_.get(e);
if (!n) throw Error("Unknown grid");
- return `${n}-${U_(t)}`;
+ return `${n}-${K_(t)}`;
}
-function W_(e, t, n) {
- let r = H_.get(e);
+function q_(e, t, n) {
+ let r = G_.get(e);
if (!r) throw Error("Unknown grid");
- return `${r}-${U_(t)}-${U_(n)}`;
+ return `${r}-${K_(t)}-${K_(n)}`;
}
-function G_(e, t) {
- return [...e.collection.rowHeaderColumnKeys].map((n) => W_(e, t, n)).join(" ");
+function J_(e, t) {
+ return [...e.collection.rowHeaderColumnKeys].map((n) => q_(e, t, n)).join(" ");
}
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/ar-AE.mjs
-var K_ = {};
-K_ = {
+var Y_ = {};
+Y_ = {
ascending: "تصاعدي",
ascendingSort: (e) => `\u{62A}\u{631}\u{62A}\u{64A}\u{628} \u{62D}\u{633}\u{628} \u{627}\u{644}\u{639}\u{645}\u{648}\u{62F} ${e.columnName} \u{628}\u{62A}\u{631}\u{62A}\u{64A}\u{628} \u{62A}\u{635}\u{627}\u{639}\u{62F}\u{64A}`,
collapse: "طي",
@@ -23401,8 +23401,8 @@ K_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/bg-BG.mjs
-var q_ = {};
-q_ = {
+var X_ = {};
+X_ = {
ascending: "възходящ",
ascendingSort: (e) => `\u{441}\u{43E}\u{440}\u{442}\u{438}\u{440}\u{430}\u{43D}\u{43E} \u{43F}\u{43E} \u{43A}\u{43E}\u{43B}\u{43E}\u{43D}\u{430} ${e.columnName} \u{432}\u{44A}\u{432} \u{432}\u{44A}\u{437}\u{445}\u{43E}\u{434}\u{44F}\u{449} \u{440}\u{435}\u{434}`,
collapse: "Свиване",
@@ -23417,8 +23417,8 @@ q_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/cs-CZ.mjs
-var J_ = {};
-J_ = {
+var Z_ = {};
+Z_ = {
ascending: "vzestupně",
ascendingSort: (e) => `\u{159}azeno vzestupn\u{11B} podle sloupce ${e.columnName}`,
collapse: "Sbalit",
@@ -23433,8 +23433,8 @@ J_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/da-DK.mjs
-var Y_ = {};
-Y_ = {
+var Q_ = {};
+Q_ = {
ascending: "stigende",
ascendingSort: (e) => `sorteret efter kolonne ${e.columnName} i stigende r\xe6kkef\xf8lge`,
collapse: "Skjul",
@@ -23449,8 +23449,8 @@ Y_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/de-DE.mjs
-var X_ = {};
-X_ = {
+var $_ = {};
+$_ = {
ascending: "aufsteigend",
ascendingSort: (e) => `sortiert nach Spalte ${e.columnName} in aufsteigender Reihenfolge`,
collapse: "Reduzieren",
@@ -23465,8 +23465,8 @@ X_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/el-GR.mjs
-var Z_ = {};
-Z_ = {
+var ev = {};
+ev = {
ascending: "αύξουσα",
ascendingSort: (e) => `\u{3B4}\u{3B9}\u{3B1}\u{3BB}\u{3BF}\u{3B3}\u{3AE} \u{3B1}\u{3BD}\u{3AC} \u{3C3}\u{3C4}\u{3AE}\u{3BB}\u{3B7} ${e.columnName} \u{3C3}\u{3B5} \u{3B1}\u{3CD}\u{3BE}\u{3BF}\u{3C5}\u{3C3}\u{3B1} \u{3C3}\u{3B5}\u{3B9}\u{3C1}\u{3AC}`,
collapse: "Σύμπτυξη",
@@ -23481,8 +23481,8 @@ Z_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/en-US.mjs
-var Q_ = {};
-Q_ = {
+var tv = {};
+tv = {
select: "Select",
selectAll: "Select All",
sortable: "sortable column",
@@ -23497,8 +23497,8 @@ Q_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/es-ES.mjs
-var $_ = {};
-$_ = {
+var nv = {};
+nv = {
ascending: "ascendente",
ascendingSort: (e) => `ordenado por columna ${e.columnName} en sentido ascendente`,
collapse: "Contraer",
@@ -23513,8 +23513,8 @@ $_ = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/et-EE.mjs
-var ev = {};
-ev = {
+var rv = {};
+rv = {
ascending: "tõusev järjestus",
ascendingSort: (e) => `sorditud veeru j\xe4rgi ${e.columnName} t\xf5usvas j\xe4rjestuses`,
collapse: "Ahenda",
@@ -23529,8 +23529,8 @@ ev = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/fi-FI.mjs
-var tv = {};
-tv = {
+var iv = {};
+iv = {
ascending: "nouseva",
ascendingSort: (e) => `lajiteltu sarakkeen ${e.columnName} mukaan nousevassa j\xe4rjestyksess\xe4`,
collapse: "Pienennä",
@@ -23545,8 +23545,8 @@ tv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/fr-FR.mjs
-var nv = {};
-nv = {
+var av = {};
+av = {
ascending: "croissant",
ascendingSort: (e) => `tri\xe9 en fonction de la colonne\xa0${e.columnName} par ordre croissant`,
collapse: "Réduire",
@@ -23561,8 +23561,8 @@ nv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/he-IL.mjs
-var rv = {};
-rv = {
+var ov = {};
+ov = {
ascending: "עולה",
ascendingSort: (e) => `\u{5DE}\u{5D5}\u{5D9}\u{5DF} \u{5DC}\u{5E4}\u{5D9} \u{5E2}\u{5DE}\u{5D5}\u{5D3}\u{5D4} ${e.columnName} \u{5D1}\u{5E1}\u{5D3}\u{5E8} \u{5E2}\u{5D5}\u{5DC}\u{5D4}`,
collapse: "כווץ",
@@ -23577,8 +23577,8 @@ rv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/hr-HR.mjs
-var iv = {};
-iv = {
+var sv = {};
+sv = {
ascending: "rastući",
ascendingSort: (e) => `razvrstano po stupcima ${e.columnName} rastu\u{107}em redoslijedom`,
collapse: "Sažmi",
@@ -23593,8 +23593,8 @@ iv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/hu-HU.mjs
-var av = {};
-av = {
+var cv = {};
+cv = {
ascending: "növekvő",
ascendingSort: (e) => `rendezve a(z) ${e.columnName} oszlop szerint, n\xf6vekv\u{151} sorrendben`,
collapse: "Összecsukás",
@@ -23609,8 +23609,8 @@ av = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/it-IT.mjs
-var ov = {};
-ov = {
+var lv = {};
+lv = {
ascending: "crescente",
ascendingSort: (e) => `in ordine crescente in base alla colonna ${e.columnName}`,
collapse: "Comprimi",
@@ -23625,8 +23625,8 @@ ov = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/ja-JP.mjs
-var sv = {};
-sv = {
+var uv = {};
+uv = {
ascending: "昇順",
ascendingSort: (e) => `\u{5217} ${e.columnName} \u{3092}\u{6607}\u{9806}\u{3067}\u{4E26}\u{3079}\u{66FF}\u{3048}`,
collapse: "折りたたむ",
@@ -23641,8 +23641,8 @@ sv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/ko-KR.mjs
-var cv = {};
-cv = {
+var dv = {};
+dv = {
ascending: "오름차순",
ascendingSort: (e) => `${e.columnName} \u{C5F4}\u{C744} \u{AE30}\u{C900}\u{C73C}\u{B85C} \u{C624}\u{B984}\u{CC28}\u{C21C}\u{C73C}\u{B85C} \u{C815}\u{B82C}\u{B428}`,
collapse: "접기",
@@ -23657,8 +23657,8 @@ cv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/lt-LT.mjs
-var lv = {};
-lv = {
+var fv = {};
+fv = {
ascending: "didėjančia tvarka",
ascendingSort: (e) => `surikiuota pagal stulpel\u{12F} ${e.columnName} did\u{117}jan\u{10D}ia tvarka`,
collapse: "Sutraukti",
@@ -23673,8 +23673,8 @@ lv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/lv-LV.mjs
-var uv = {};
-uv = {
+var pv = {};
+pv = {
ascending: "augošā secībā",
ascendingSort: (e) => `k\u{101}rtots p\u{113}c kolonnas ${e.columnName} augo\u{161}\u{101} sec\u{12B}b\u{101}`,
collapse: "Sakļaut",
@@ -23689,8 +23689,8 @@ uv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/nb-NO.mjs
-var dv = {};
-dv = {
+var mv = {};
+mv = {
ascending: "stigende",
ascendingSort: (e) => `sortert etter kolonne ${e.columnName} i stigende rekkef\xf8lge`,
collapse: "Skjul",
@@ -23705,8 +23705,8 @@ dv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/nl-NL.mjs
-var fv = {};
-fv = {
+var hv = {};
+hv = {
ascending: "oplopend",
ascendingSort: (e) => `gesorteerd in oplopende volgorde in kolom ${e.columnName}`,
collapse: "Samenvouwen",
@@ -23721,8 +23721,8 @@ fv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/pl-PL.mjs
-var pv = {};
-pv = {
+var gv = {};
+gv = {
ascending: "rosnąco",
ascendingSort: (e) => `posortowano wed\u{142}ug kolumny ${e.columnName} w porz\u{105}dku rosn\u{105}cym`,
collapse: "Zwiń",
@@ -23737,8 +23737,8 @@ pv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/pt-BR.mjs
-var mv = {};
-mv = {
+var _v = {};
+_v = {
ascending: "crescente",
ascendingSort: (e) => `classificado pela coluna ${e.columnName} em ordem crescente`,
collapse: "Recolher",
@@ -23753,8 +23753,8 @@ mv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/pt-PT.mjs
-var hv = {};
-hv = {
+var vv = {};
+vv = {
ascending: "ascendente",
ascendingSort: (e) => `Ordenar por coluna ${e.columnName} em ordem ascendente`,
collapse: "Colapsar",
@@ -23769,8 +23769,8 @@ hv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/ro-RO.mjs
-var gv = {};
-gv = {
+var yv = {};
+yv = {
ascending: "crescătoare",
ascendingSort: (e) => `sortate dup\u{103} coloana ${e.columnName} \xeen ordine cresc\u{103}toare`,
collapse: "Restrângeți",
@@ -23785,8 +23785,8 @@ gv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/ru-RU.mjs
-var _v = {};
-_v = {
+var bv = {};
+bv = {
ascending: "возрастание",
ascendingSort: (e) => `\u{441}\u{43E}\u{440}\u{442}\u{438}\u{440}\u{43E}\u{432}\u{430}\u{442}\u{44C} \u{441}\u{442}\u{43E}\u{43B}\u{431}\u{435}\u{446} ${e.columnName} \u{432} \u{43F}\u{43E}\u{440}\u{44F}\u{434}\u{43A}\u{435} \u{432}\u{43E}\u{437}\u{440}\u{430}\u{441}\u{442}\u{430}\u{43D}\u{438}\u{44F}`,
collapse: "Свернуть",
@@ -23801,8 +23801,8 @@ _v = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/sk-SK.mjs
-var vv = {};
-vv = {
+var xv = {};
+xv = {
ascending: "vzostupne",
ascendingSort: (e) => `zoraden\xe9 zostupne pod\u{13E}a st\u{13A}pca ${e.columnName}`,
collapse: "Zbaliť",
@@ -23817,8 +23817,8 @@ vv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/sl-SI.mjs
-var yv = {};
-yv = {
+var Sv = {};
+Sv = {
ascending: "naraščajoče",
ascendingSort: (e) => `razvr\u{161}\u{10D}eno po stolpcu ${e.columnName} v nara\u{161}\u{10D}ajo\u{10D}em vrstnem redu`,
collapse: "Strni",
@@ -23833,8 +23833,8 @@ yv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/sr-SP.mjs
-var bv = {};
-bv = {
+var Cv = {};
+Cv = {
ascending: "rastući",
ascendingSort: (e) => `sortirano po kolonama ${e.columnName} rastu\u{107}im redosledom`,
collapse: "Skupi",
@@ -23849,8 +23849,8 @@ bv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/sv-SE.mjs
-var xv = {};
-xv = {
+var wv = {};
+wv = {
ascending: "stigande",
ascendingSort: (e) => `sorterat p\xe5 kolumn ${e.columnName} i stigande ordning`,
collapse: "Dölj",
@@ -23865,8 +23865,8 @@ xv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/tr-TR.mjs
-var Sv = {};
-Sv = {
+var Tv = {};
+Tv = {
ascending: "artan sırada",
ascendingSort: (e) => `${e.columnName} s\xfctuna g\xf6re artan d\xfczende s\u{131}rala`,
collapse: "Daralt",
@@ -23881,8 +23881,8 @@ Sv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/uk-UA.mjs
-var Cv = {};
-Cv = {
+var Ev = {};
+Ev = {
ascending: "висхідний",
ascendingSort: (e) => `\u{432}\u{456}\u{434}\u{441}\u{43E}\u{440}\u{442}\u{43E}\u{432}\u{430}\u{43D}\u{43E} \u{437}\u{430} \u{441}\u{442}\u{43E}\u{432}\u{43F}\u{446}\u{435}\u{43C} ${e.columnName} \u{443} \u{432}\u{438}\u{441}\u{445}\u{456}\u{434}\u{43D}\u{43E}\u{43C}\u{443} \u{43F}\u{43E}\u{440}\u{44F}\u{434}\u{43A}\u{443}`,
collapse: "Згорнути",
@@ -23897,8 +23897,8 @@ Cv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/zh-CN.mjs
-var wv = {};
-wv = {
+var Dv = {};
+Dv = {
ascending: "升序",
ascendingSort: (e) => `\u{6309}\u{5217} ${e.columnName} \u{5347}\u{5E8F}\u{6392}\u{5E8F}`,
collapse: "折叠",
@@ -23913,8 +23913,8 @@ wv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/intl/table/zh-TW.mjs
-var Tv = {};
-Tv = {
+var Ov = {};
+Ov = {
ascending: "遞增",
ascendingSort: (e) => `\u{5DF2}\u{4F9D}\u{64DA}\u{300C}${e.columnName}\u{300D}\u{6B04}\u{905E}\u{589E}\u{6392}\u{5E8F}`,
collapse: "收合",
@@ -23929,46 +23929,46 @@ Tv = {
};
//#endregion
//#region node_modules/react-aria/dist/private/table/intlStrings.mjs
-var Ev = {};
-Ev = {
- "ar-AE": K_,
- "bg-BG": q_,
- "cs-CZ": J_,
- "da-DK": Y_,
- "de-DE": X_,
- "el-GR": Z_,
- "en-US": Q_,
- "es-ES": $_,
- "et-EE": ev,
- "fi-FI": tv,
- "fr-FR": nv,
- "he-IL": rv,
- "hr-HR": iv,
- "hu-HU": av,
- "it-IT": ov,
- "ja-JP": sv,
- "ko-KR": cv,
- "lt-LT": lv,
- "lv-LV": uv,
- "nb-NO": dv,
- "nl-NL": fv,
- "pl-PL": pv,
- "pt-BR": mv,
- "pt-PT": hv,
- "ro-RO": gv,
- "ru-RU": _v,
- "sk-SK": vv,
- "sl-SI": yv,
- "sr-SP": bv,
- "sv-SE": xv,
- "tr-TR": Sv,
- "uk-UA": Cv,
- "zh-CN": wv,
- "zh-TW": Tv
+var kv = {};
+kv = {
+ "ar-AE": Y_,
+ "bg-BG": X_,
+ "cs-CZ": Z_,
+ "da-DK": Q_,
+ "de-DE": $_,
+ "el-GR": ev,
+ "en-US": tv,
+ "es-ES": nv,
+ "et-EE": rv,
+ "fi-FI": iv,
+ "fr-FR": av,
+ "he-IL": ov,
+ "hr-HR": sv,
+ "hu-HU": cv,
+ "it-IT": lv,
+ "ja-JP": uv,
+ "ko-KR": dv,
+ "lt-LT": fv,
+ "lv-LV": pv,
+ "nb-NO": mv,
+ "nl-NL": hv,
+ "pl-PL": gv,
+ "pt-BR": _v,
+ "pt-PT": vv,
+ "ro-RO": yv,
+ "ru-RU": bv,
+ "sk-SK": xv,
+ "sl-SI": Sv,
+ "sr-SP": Cv,
+ "sv-SE": wv,
+ "tr-TR": Tv,
+ "uk-UA": Ev,
+ "zh-CN": Dv,
+ "zh-TW": Ov
};
//#endregion
//#region node_modules/react-aria/dist/private/table/TableKeyboardDelegate.mjs
-var ste = class extends B_ {
+var ite = class extends U_ {
isCell(e) {
return e.type === "cell" || e.type === "rowheader" || e.type === "column";
}
@@ -24046,14 +24046,14 @@ var ste = class extends B_ {
};
//#endregion
//#region node_modules/react-aria/dist/private/table/useTable.mjs
-function cte(e) {
+function ate(e) {
return e && e.__esModule ? e.default : e;
}
-function lte(e, t, n) {
+function ote(e, t, n) {
let { keyboardDelegate: r, isVirtualized: i, layoutDelegate: a, layout: o } = e, s = np({
usage: "search",
sensitivity: "base"
- }), { direction: c } = Bs(), l = t.selectionManager.disabledBehavior, u = (0, R.useMemo)(() => r || new ste({
+ }), { direction: c } = Bs(), l = t.selectionManager.disabledBehavior, u = (0, R.useMemo)(() => r || new ite({
collection: t.collection,
disabledKeys: t.disabledKeys,
disabledBehavior: l,
@@ -24073,14 +24073,14 @@ function lte(e, t, n) {
a,
o
]), d = Ta(e.id);
- H_.set(t, d);
- let { gridProps: f } = ate({
+ G_.set(t, d);
+ let { gridProps: f } = nte({
...e,
id: d,
keyboardDelegate: u
}, t, n);
i && (f["aria-rowcount"] = t.collection.size + t.collection.headerRows.length), t.treeColumn != null && (f.role = "treegrid");
- let { column: p, direction: m } = t.sortDescriptor || {}, h = ec(cte(Ev), "@react-aria/table"), g = (0, R.useMemo)(() => {
+ let { column: p, direction: m } = t.sortDescriptor || {}, h = ec(ate(kv), "@react-aria/table"), g = (0, R.useMemo)(() => {
let e = t.collection.columns.find((e) => e.key === p)?.textValue ?? "";
return m && p ? h.format(`${m}Sort`, { columnName: e }) : void 0;
}, [
@@ -24094,13 +24094,13 @@ function lte(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/grid/useGridCell.mjs
-function Dv(e, t, n) {
- let { node: r, isVirtualized: i, focusMode: a, allowsArrowNavigation: o, shouldSelectOnPressUp: s, onAction: c } = e, { direction: l } = Bs(), { keyboardDelegate: u, actions: { onCellAction: d }, keyboardNavigationBehavior: f } = V_.get(t), p = a ?? (f === "tab" ? "cell" : "child"), m = (0, R.useRef)(null), h = () => {
+function Av(e, t, n) {
+ let { node: r, isVirtualized: i, focusMode: a, allowsArrowNavigation: o, shouldSelectOnPressUp: s, onAction: c } = e, { direction: l } = Bs(), { keyboardDelegate: u, actions: { onCellAction: d }, keyboardNavigationBehavior: f } = W_.get(t), p = a ?? (f === "tab" ? "cell" : "child"), m = (0, R.useRef)(null), h = () => {
if (n.current) {
let e = zf(n.current);
if (p === "child") {
if (io(n.current) && n.current !== no(Ga(n.current))) return;
- let r = t.selectionManager.childFocusStrategy === "last" ? Ov(e) : e.firstChild();
+ let r = t.selectionManager.childFocusStrategy === "last" ? jv(e) : e.firstChild();
if (r) {
Sc(r);
return;
@@ -24132,7 +24132,7 @@ function Dv(e, t, n) {
n.current.parentElement?.dispatchEvent(new KeyboardEvent(e.nativeEvent.type, e.nativeEvent));
break;
}
- p === "cell" && l === "rtl" ? (Sc(n.current), Tu(n.current, { containingElement: xu(n.current) })) : (a.currentNode = n.current, t = l === "rtl" ? a.firstChild() : Ov(a), t && (Sc(t), Tu(t, { containingElement: xu(n.current) })));
+ p === "cell" && l === "rtl" ? (Sc(n.current), Tu(n.current, { containingElement: xu(n.current) })) : (a.currentNode = n.current, t = l === "rtl" ? a.firstChild() : jv(a), t && (Sc(t), Tu(t, { containingElement: xu(n.current) })));
}
break;
}
@@ -24144,7 +24144,7 @@ function Dv(e, t, n) {
n.current.parentElement?.dispatchEvent(new KeyboardEvent(e.nativeEvent.type, e.nativeEvent));
break;
}
- p === "cell" && l === "ltr" ? (Sc(n.current), Tu(n.current, { containingElement: xu(n.current) })) : (a.currentNode = n.current, t = l === "rtl" ? Ov(a) : a.firstChild(), t && (Sc(t), Tu(t, { containingElement: xu(n.current) })));
+ p === "cell" && l === "ltr" ? (Sc(n.current), Tu(n.current, { containingElement: xu(n.current) })) : (a.currentNode = n.current, t = l === "rtl" ? jv(a) : a.firstChild(), t && (Sc(t), Tu(t, { containingElement: xu(n.current) })));
}
break;
}
@@ -24189,7 +24189,7 @@ function Dv(e, t, n) {
isPressed: _
};
}
-function Ov(e) {
+function jv(e) {
let t = null, n = null;
do
n = e.lastChild(), n && (t = n);
@@ -24198,11 +24198,11 @@ function Ov(e) {
}
//#endregion
//#region node_modules/react-aria/dist/private/table/useTableColumnHeader.mjs
-function ute(e) {
+function ste(e) {
return e && e.__esModule ? e.default : e;
}
-function dte(e, t, n) {
- let { node: r } = e, i = r.props.allowsSorting, { gridCellProps: a } = Dv({
+function cte(e, t, n) {
+ let { node: r } = e, i = r.props.allowsSorting, { gridCellProps: a } = Av({
focusMode: "child",
...e
}, t, n), o = r.props.isSelectionCell && t.selectionManager.selectionMode === "single", { pressProps: s, isPressed: c } = zl({
@@ -24213,7 +24213,7 @@ function dte(e, t, n) {
ref: n
}), { focusableProps: l } = Vc({}, n), u, d = t.sortDescriptor?.column === r.key, f = t.sortDescriptor?.direction;
r.props.allowsSorting && !Bo() && (u = d ? f : "none");
- let p = ec(ute(Ev), "@react-aria/table"), m;
+ let p = ec(ste(kv), "@react-aria/table"), m;
i && (m = `${p.format("sortable")}`, d && f && Bo() && (m = `${m}, ${p.format(f)}`));
let h = Ou(m), g = t.collection.size === 0;
return (0, R.useEffect)(() => {
@@ -24226,7 +24226,7 @@ function dte(e, t, n) {
columnHeaderProps: {
...J(l, a, s, h, g ? { tabIndex: -1 } : null),
role: "columnheader",
- id: ote(t, r.key),
+ id: rte(t, r.key),
"aria-colspan": r.colSpan && r.colSpan > 1 ? r.colSpan : void 0,
"aria-sort": u
},
@@ -24235,8 +24235,8 @@ function dte(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/grid/useGridRow.mjs
-function fte(e, t, n) {
- let { node: r, isVirtualized: i, shouldSelectOnPressUp: a, onAction: o } = e, { actions: s, shouldSelectOnPressUp: c } = V_.get(t), l = s.onRowAction ? () => s.onRowAction?.(r.key) : o, { itemProps: u, ...d } = sp({
+function lte(e, t, n) {
+ let { node: r, isVirtualized: i, shouldSelectOnPressUp: a, onAction: o } = e, { actions: s, shouldSelectOnPressUp: c } = W_.get(t), l = s.onRowAction ? () => s.onRowAction?.(r.key) : o, { itemProps: u, ...d } = sp({
selectionManager: t.selectionManager,
key: r.key,
ref: n,
@@ -24257,10 +24257,10 @@ function fte(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/table/useTableRow.mjs
-function pte(e) {
+function ute(e) {
return e && e.__esModule ? e.default : e;
}
-var kv = {
+var Mv = {
expand: {
ltr: "ArrowRight",
rtl: "ArrowLeft"
@@ -24270,21 +24270,21 @@ var kv = {
rtl: "ArrowRight"
}
};
-function mte(e, t, n) {
- let { node: r, isVirtualized: i } = e, { rowProps: a, ...o } = fte(e, t, n), { direction: s } = Bs();
+function dte(e, t, n) {
+ let { node: r, isVirtualized: i } = e, { rowProps: a, ...o } = lte(e, t, n), { direction: s } = Bs();
i && t.treeColumn == null ? a["aria-rowindex"] = r.index + 1 + t.collection.headerRows.length : delete a["aria-rowindex"];
- let c = t.treeColumn != null && (t.expandedKeys === "all" || t.expandedKeys.has(r.key)), l = ec(pte(Ev), "@react-aria/table"), u = ks({
+ let c = t.treeColumn != null && (t.expandedKeys === "all" || t.expandedKeys.has(r.key)), l = ec(ute(kv), "@react-aria/table"), u = ks({
"aria-label": c ? l.format("collapse") : l.format("expand"),
- "aria-labelledby": G_(t, r.key)
+ "aria-labelledby": J_(t, r.key)
}), d = {}, f = {};
if (t.treeColumn != null) {
let e = t.collection.getItem(r.key);
if (e != null) {
- let n = Av(t.collection, r), i = e.props?.hasChildRows || e.props?.UNSTABLE_childItems || n?.type !== "cell", a = t.collection.getItem(r.parentKey), c = a.type === "tablebody" || a.type === "body", l = Av(t.collection, a);
+ let n = Nv(t.collection, r), i = e.props?.hasChildRows || e.props?.UNSTABLE_childItems || n?.type !== "cell", a = t.collection.getItem(r.parentKey), c = a.type === "tablebody" || a.type === "body", l = Nv(t.collection, a);
for (; l && l.type !== "item" && l.prevKey != null;) l = t.collection.getItem(l.prevKey);
d = {
onKeyDown: (n) => {
- n.key === kv.expand[s] && t.selectionManager.focusedKey === e.key && i && t.expandedKeys !== "all" && !t.expandedKeys.has(e.key) ? (t.toggleKey(e.key), n.stopPropagation()) : n.key === kv.collapse[s] && t.selectionManager.focusedKey === e.key && (t.expandedKeys === "all" ? t.expandedKeys === "all" && (t.toggleKey(e.key), n.stopPropagation()) : i && t.expandedKeys.has(e.key) ? (t.toggleKey(e.key), n.stopPropagation()) : !t.expandedKeys.has(e.key) && e.parentKey != null && e.level > 0 && (t.selectionManager.setFocusedKey(e.parentKey), n.stopPropagation()));
+ n.key === Mv.expand[s] && t.selectionManager.focusedKey === e.key && i && t.expandedKeys !== "all" && !t.expandedKeys.has(e.key) ? (t.toggleKey(e.key), n.stopPropagation()) : n.key === Mv.collapse[s] && t.selectionManager.focusedKey === e.key && (t.expandedKeys === "all" ? t.expandedKeys === "all" && (t.toggleKey(e.key), n.stopPropagation()) : i && t.expandedKeys.has(e.key) ? (t.toggleKey(e.key), n.stopPropagation()) : !t.expandedKeys.has(e.key) && e.parentKey != null && e.level > 0 && (t.selectionManager.setFocusedKey(e.parentKey), n.stopPropagation()));
},
"aria-expanded": i ? t.expandedKeys === "all" || t.expandedKeys.has(r.key) : void 0,
"aria-level": e.level + 1,
@@ -24306,46 +24306,46 @@ function mte(e, t, n) {
return {
rowProps: {
...J(a, d, m),
- "aria-labelledby": G_(t, r.key)
+ "aria-labelledby": J_(t, r.key)
},
expandButtonProps: f,
...o
};
}
-function Av(e, t) {
+function Nv(e, t) {
return "lastChildKey" in t ? t.lastChildKey == null ? null : e.getItem(t.lastChildKey) : Array.from(t.childNodes).findLast((e) => e.parentKey === t.key);
}
//#endregion
//#region node_modules/react-aria/dist/private/table/useTableHeaderRow.mjs
-function hte(e, t, n) {
+function fte(e, t, n) {
let { node: r, isVirtualized: i } = e, a = { role: "row" };
return i && t.treeColumn == null && (a["aria-rowindex"] = r.index + 1), { rowProps: a };
}
//#endregion
//#region node_modules/react-aria/dist/private/table/useTableCell.mjs
-function gte(e, t, n) {
- let { gridCellProps: r, isPressed: i } = Dv(e, t, n), a = e.node.column?.key;
- return a != null && t.collection.rowHeaderColumnKeys.has(a) && (r.role = "rowheader", r.id = W_(t, e.node.parentKey, a)), {
+function pte(e, t, n) {
+ let { gridCellProps: r, isPressed: i } = Av(e, t, n), a = e.node.column?.key;
+ return a != null && t.collection.rowHeaderColumnKeys.has(a) && (r.role = "rowheader", r.id = q_(t, e.node.parentKey, a)), {
gridCellProps: r,
isPressed: i
};
}
//#endregion
//#region node_modules/react-aria/dist/private/table/useTableSelectionCheckbox.mjs
-function _te(e) {
+function mte(e) {
return e && e.__esModule ? e.default : e;
}
-function vte(e, t) {
- let { key: n } = e, { checkboxProps: r } = See(e, t);
+function hte(e, t) {
+ let { key: n } = e, { checkboxProps: r } = xee(e, t);
return { checkboxProps: {
...r,
- "aria-labelledby": `${r.id} ${G_(t, n)}`
+ "aria-labelledby": `${r.id} ${J_(t, n)}`
} };
}
-function yte(e) {
+function gte(e) {
let { isEmpty: t, isSelectAll: n, selectionMode: r } = e.selectionManager;
return { checkboxProps: {
- "aria-label": ec(_te(Ev), "@react-aria/table").format(r === "single" ? "select" : "selectAll"),
+ "aria-label": ec(mte(kv), "@react-aria/table").format(r === "single" ? "select" : "selectAll"),
isSelected: n,
isDisabled: r !== "multiple" || e.collection.size === 0 || e.collection.rows.length === 1 && e.collection.rows[0].type === "loader",
isIndeterminate: !t && !n,
@@ -24354,17 +24354,17 @@ function yte(e) {
}
//#endregion
//#region node_modules/react-aria/dist/private/grid/useGridRowGroup.mjs
-function bte() {
+function _te() {
return { rowGroupProps: { role: "rowgroup" } };
}
//#endregion
//#region node_modules/react-aria/dist/private/table/useTableRowGroup.mjs
-function jv() {
- return bte();
+function Pv() {
+ return _te();
}
//#endregion
//#region node_modules/react-aria-components/dist/private/Table.mjs
-var xte = class extends uc {
+var vte = class extends uc {
withExpandedKeys(e) {
let t = this.clone();
return t.expandedKeys = e, t.frozen = this.frozen, t.rows = Array.from(t.getRows()), t;
@@ -24379,7 +24379,7 @@ var xte = class extends uc {
}
get body() {
for (let e of this) if (e.type === "tablebody") return e;
- return new Bv(-2);
+ return new qv(-2);
}
commit(e, t, n = !1) {
this.updateColumns(n), this.firstKey = e, this.lastKey = t, this.rows = [];
@@ -24405,7 +24405,7 @@ var xte = class extends uc {
for (let t of this.getChildren(e.key)) n(t);
};
for (let e of this.getChildren(this.head.key)) n(e);
- if (this.headerRows = z_(t, this.columns), this.columnsDirty = !1, this.rowHeaderColumnKeys.size === 0 && this.columns.length > 0 && !e) throw Error("A table must have at least one Column with the isRowHeader prop set to true");
+ if (this.headerRows = H_(t, this.columns), this.columnsDirty = !1, this.rowHeaderColumnKeys.size === 0 && this.columns.length > 0 && !e) throw Error("A table must have at least one Column with the isRowHeader prop set to true");
}
get columnCount() {
return this.columns.length;
@@ -24486,10 +24486,10 @@ var xte = class extends uc {
return r.join(" ");
}
constructor(...e) {
- super(...e), this.headerRows = [], this.columns = [], this.rows = [], this.rowHeaderColumnKeys = /* @__PURE__ */ new Set(), this.head = new Fv(-1), this.columnsDirty = !0, this.expandedKeys = /* @__PURE__ */ new Set();
+ super(...e), this.headerRows = [], this.columns = [], this.rows = [], this.rowHeaderColumnKeys = /* @__PURE__ */ new Set(), this.head = new Hv(-1), this.columnsDirty = !0, this.expandedKeys = /* @__PURE__ */ new Set();
}
-}, Ste = /*#__PURE__*/ (0, R.createContext)(null), Cte = /*#__PURE__*/ (0, R.createContext)(null), Mv = /*#__PURE__*/ (0, R.createContext)(null), Nv = /*#__PURE__*/ (0, R.createContext)(null), wte = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- [e, t] = La(e, t, Cte);
+}, yte = /*#__PURE__*/ (0, R.createContext)(null), bte = /*#__PURE__*/ (0, R.createContext)(null), Fv = /*#__PURE__*/ (0, R.createContext)(null), Iv = /*#__PURE__*/ (0, R.createContext)(null), Lv = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ [e, t] = La(e, t, bte);
let n = wp(e), { selectionBehavior: r, selectionMode: i, disallowEmptySelection: a } = n, o = !!e.dragAndDropHooks?.useDraggableCollectionState, s = (0, R.useMemo)(() => ({
selectionBehavior: i === "none" ? null : r,
selectionMode: i,
@@ -24500,17 +24500,17 @@ var xte = class extends uc {
i,
a,
o
- ]), c = /*#__PURE__*/ R.createElement(Dte.Provider, { value: s }, /*#__PURE__*/ R.createElement(ll, e));
+ ]), c = /*#__PURE__*/ R.createElement(Vv.Provider, { value: s }, /*#__PURE__*/ R.createElement(ll, e));
return /*#__PURE__*/ R.createElement(Zc, {
content: c,
- createCollection: () => new xte()
- }, (r) => /*#__PURE__*/ R.createElement(Ete, {
+ createCollection: () => new vte()
+ }, (r) => /*#__PURE__*/ R.createElement(Bv, {
props: e,
forwardedRef: t,
selectionState: n,
collection: r
}));
-}), Tte = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+}), Rv = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { isVirtualized: n } = (0, R.useContext)(hl);
return n ? /*#__PURE__*/ R.createElement(Ha.div, {
...e,
@@ -24519,7 +24519,7 @@ var xte = class extends uc {
...e,
ref: t
});
-}), Pv = {
+}), zv = {
expand: {
ltr: "ArrowRight",
rtl: "ArrowLeft"
@@ -24529,26 +24529,26 @@ var xte = class extends uc {
rtl: "ArrowRight"
}
};
-function Ete({ props: e, forwardedRef: t, selectionState: n, collection: r }) {
+function Bv({ props: e, forwardedRef: t, selectionState: n, collection: r }) {
[e, t] = La(e, t, rc);
- let { shouldUseVirtualFocus: i, disallowTypeAhead: a, filter: o, ...s } = e, c = (0, R.useContext)(Ste);
+ let { shouldUseVirtualFocus: i, disallowTypeAhead: a, filter: o, ...s } = e, c = (0, R.useContext)(yte);
t = Ma((0, R.useMemo)(() => Oa(t, c?.tableRef), [t, c?.tableRef]));
let [l, u] = nc(e.expandedKeys ? new Set(e.expandedKeys) : void 0, e.defaultExpandedKeys ? new Set(e.defaultExpandedKeys) : /* @__PURE__ */ new Set(), e.onExpandedChange);
r = (0, R.useMemo)(() => r.withExpandedKeys(l), [r, l]);
- let d = nte({
+ let d = $ee({
...s,
collection: r,
children: void 0,
UNSAFE_selectionState: n,
expandedKeys: l,
onExpandedChange: u
- }), f = rte(d, o), { isVirtualized: p, layoutDelegate: m, dropTargetDelegate: h, CollectionRoot: g } = (0, R.useContext)(hl), { dragAndDropHooks: _ } = e, { gridProps: v } = lte({
+ }), f = ete(d, o), { isVirtualized: p, layoutDelegate: m, dropTargetDelegate: h, CollectionRoot: g } = (0, R.useContext)(hl), { dragAndDropHooks: _ } = e, { gridProps: v } = ote({
...s,
layoutDelegate: m,
isVirtualized: p
}, f, t), y = f.selectionManager, b = !!_?.useDraggableCollectionState, x = !!_?.useDroppableCollectionState;
(0, R.useRef)(b), (0, R.useRef)(x), (0, R.useEffect)(() => {}, [b, x]);
- let S, C, w, T = !1, E = null, D = (0, R.useRef)(null), { direction: O } = Bs(), [k] = (0, R.useState)(() => new Zee());
+ let S, C, w, T = !1, E = null, D = (0, R.useRef)(null), { direction: O } = Bs(), [k] = (0, R.useState)(() => new R_());
if (b && _) {
S = _.useDraggableCollectionState({
collection: f.collection,
@@ -24583,7 +24583,7 @@ function Ete({ props: e, forwardedRef: t, selectionState: n, collection: r }) {
let t = C?.target;
if (t && t.type === "item" && t.dropPosition === "on") {
let n = d.collection.getItem(t.key);
- (e.key === Pv.expand[O] && n?.hasChildNodes && !d.expandedKeys.has(t.key) || e.key === Pv.collapse[O] && n?.hasChildNodes && d.expandedKeys.has(t.key)) && d.toggleKey(t.key);
+ (e.key === zv.expand[O] && n?.hasChildNodes && !d.expandedKeys.has(t.key) || e.key === zv.collapse[O] && n?.hasChildNodes && d.expandedKeys.has(t.key)) && d.toggleKey(t.key);
}
}
}, C, t), T = C.isDropTarget({ type: "root" });
@@ -24606,17 +24606,17 @@ function Ete({ props: e, forwardedRef: t, selectionState: n, collection: r }) {
}));
let I = Cl(e, { global: !0 });
return /*#__PURE__*/ R.createElement(Pa, { values: [
- [Mv, f],
- [Nv, F],
+ [Fv, f],
+ [Iv, F],
[Qd, {
dragAndDropHooks: _,
dragState: S,
dropState: C
}],
- [$d, { render: Pte }],
+ [$d, { render: Ote }],
[rc, null],
[ic, null]
- ] }, /*#__PURE__*/ R.createElement(yf, null, /*#__PURE__*/ R.createElement(Tte, {
+ ] }, /*#__PURE__*/ R.createElement(yf, null, /*#__PURE__*/ R.createElement(Rv, {
...J(I, N, v, A, w?.collectionProps),
style: ee,
ref: t,
@@ -24632,11 +24632,11 @@ function Ete({ props: e, forwardedRef: t, selectionState: n, collection: r }) {
persistedKeys: nf(y, _, C)
})))), E);
}
-var Dte = /*#__PURE__*/ (0, R.createContext)(null), Fv = class extends ac {
+var Vv = /*#__PURE__*/ (0, R.createContext)(null), Hv = class extends ac {
static {
this.type = "tableheader";
}
-}, Ote = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+}, Uv = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { isVirtualized: n } = (0, R.useContext)(hl);
return n ? /*#__PURE__*/ R.createElement(Ha.div, {
...e,
@@ -24645,16 +24645,16 @@ var Dte = /*#__PURE__*/ (0, R.createContext)(null), Fv = class extends ac {
...e,
ref: t
});
-}), Iv = /*#__PURE__*/ ol(Fv, (e, t) => {
- let n = (0, R.useContext)(Mv).collection, r = hc({
+}), Wv = /*#__PURE__*/ ol(Hv, (e, t) => {
+ let n = (0, R.useContext)(Fv).collection, r = hc({
items: n.headerRows,
children: (0, R.useCallback)((e) => {
switch (e.type) {
- case "headerrow": return /*#__PURE__*/ R.createElement(Rv, { item: e });
+ case "headerrow": return /*#__PURE__*/ R.createElement(xte, { item: e });
default: throw Error("Unsupported node type in TableHeader: " + e.type);
}
}, [])
- }), { rowGroupProps: i } = jv(), { hoverProps: a, isHovered: o } = eu({
+ }), { rowGroupProps: i } = Pv(), { hoverProps: a, isHovered: o } = eu({
onHoverStart: e.onHoverStart,
onHoverChange: e.onHoverChange,
onHoverEnd: e.onHoverEnd
@@ -24664,7 +24664,7 @@ var Dte = /*#__PURE__*/ (0, R.createContext)(null), Fv = class extends ac {
defaultClassName: "react-aria-TableHeader",
values: { isHovered: o }
});
- return /*#__PURE__*/ R.createElement(Ote, {
+ return /*#__PURE__*/ R.createElement(Uv, {
...J(Cl(e, { global: !0 }), i, a),
...s,
ref: t,
@@ -24673,7 +24673,7 @@ var Dte = /*#__PURE__*/ (0, R.createContext)(null), Fv = class extends ac {
}, (e) => /*#__PURE__*/ R.createElement(ll, {
dependencies: e.dependencies,
items: e.columns
-}, e.children)), Lv = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+}, e.children)), Gv = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { isVirtualized: n } = (0, R.useContext)(hl);
return n ? /*#__PURE__*/ R.createElement("div", {
...e,
@@ -24683,12 +24683,12 @@ var Dte = /*#__PURE__*/ (0, R.createContext)(null), Fv = class extends ac {
ref: t
});
});
-function Rv({ item: e }) {
- let t = (0, R.useRef)(null), n = (0, R.useContext)(Mv), { isVirtualized: r, CollectionBranch: i } = (0, R.useContext)(hl), { rowProps: a } = hte({
+function xte({ item: e }) {
+ let t = (0, R.useRef)(null), n = (0, R.useContext)(Fv), { isVirtualized: r, CollectionBranch: i } = (0, R.useContext)(hl), { rowProps: a } = fte({
node: e,
isVirtualized: r
- }, n, t), { checkboxProps: o } = yte(n);
- return /*#__PURE__*/ R.createElement(Lv, {
+ }, n, t), { checkboxProps: o } = gte(n);
+ return /*#__PURE__*/ R.createElement(Gv, {
...a,
ref: t
}, /*#__PURE__*/ R.createElement(Pa, { values: [[id, { slots: { selection: o } }], [ad, { slots: { selection: o } }]] }, /*#__PURE__*/ R.createElement(i, {
@@ -24696,11 +24696,11 @@ function Rv({ item: e }) {
parent: e
})));
}
-var kte = class extends ac {
+var Ste = class extends ac {
static {
this.type = "column";
}
-}, Ate = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+}, Cte = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { isVirtualized: n } = (0, R.useContext)(hl);
return n ? /*#__PURE__*/ R.createElement(Ha.div, {
...e,
@@ -24709,13 +24709,13 @@ var kte = class extends ac {
...e,
ref: t
});
-}), zv = /*#__PURE__*/ al(kte, (e, t, n) => {
- let r = Ma(t), i = (0, R.useContext)(Mv), { isVirtualized: a } = (0, R.useContext)(hl), { columnHeaderProps: o, isPressed: s } = dte({
+}), Kv = /*#__PURE__*/ al(Ste, (e, t, n) => {
+ let r = Ma(t), i = (0, R.useContext)(Fv), { isVirtualized: a } = (0, R.useContext)(hl), { columnHeaderProps: o, isPressed: s } = cte({
node: n,
isVirtualized: a,
focusMode: e.focusMode,
allowsArrowNavigation: e.allowsArrowNavigation
- }, i, r), { isFocused: c, isFocusVisible: l, focusProps: u } = Jl(), d = (0, R.useContext)(Nv), f = !1;
+ }, i, r), { isFocused: c, isFocusVisible: l, focusProps: u } = Jl(), d = (0, R.useContext)(Iv), f = !1;
d && (f = d.resizingColumn === n.key);
let { hoverProps: p, isHovered: m } = eu({ isDisabled: !e.allowsSorting }), h = Fa({
...e,
@@ -24744,7 +24744,7 @@ var kte = class extends ac {
width: d.getColumnWidth(n.key)
});
let _ = Cl(e, { global: !0 });
- return delete _.id, /*#__PURE__*/ R.createElement(Ate, {
+ return delete _.id, /*#__PURE__*/ R.createElement(Cte, {
...J(_, o, u, p),
...h,
style: g,
@@ -24756,15 +24756,15 @@ var kte = class extends ac {
"data-resizing": f || void 0,
"data-allows-sorting": n.props.allowsSorting || void 0,
"data-sort-direction": i.sortDescriptor?.column === n.key ? i.sortDescriptor.direction : void 0
- }, /*#__PURE__*/ R.createElement(Pa, { values: [[jte, {
+ }, /*#__PURE__*/ R.createElement(Pa, { values: [[wte, {
column: n,
triggerRef: r
}], [hl, fl]] }, h.children));
-}), jte = /*#__PURE__*/ (0, R.createContext)(null), Bv = class extends oc {
+}), wte = /*#__PURE__*/ (0, R.createContext)(null), qv = class extends oc {
static {
this.type = "tablebody";
}
-}, Mte = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+}, Tte = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { isVirtualized: n } = (0, R.useContext)(hl);
return n ? /*#__PURE__*/ R.createElement(Ha.div, {
...e,
@@ -24773,8 +24773,8 @@ var kte = class extends ac {
...e,
ref: t
});
-}), Vv = /*#__PURE__*/ ol(Bv, (e, t, n) => {
- let r = (0, R.useContext)(Mv), { isVirtualized: i } = (0, R.useContext)(hl), a = r.collection, { CollectionBranch: o } = (0, R.useContext)(hl), { dragAndDropHooks: s, dropState: c } = (0, R.useContext)(Qd), l = !!s?.useDroppableCollectionState && !c?.isDisabled, u = l && !!c && (c.isDropTarget({ type: "root" }) ?? !1), d = a.size === 0, f = {
+}), Jv = /*#__PURE__*/ ol(qv, (e, t, n) => {
+ let r = (0, R.useContext)(Fv), { isVirtualized: i } = (0, R.useContext)(hl), a = r.collection, { CollectionBranch: o } = (0, R.useContext)(hl), { dragAndDropHooks: s, dropState: c } = (0, R.useContext)(Qd), l = !!s?.useDroppableCollectionState && !c?.isDisabled, u = l && !!c && (c.isDropTarget({ type: "root" }) ?? !1), d = a.size === 0, f = {
isDropTarget: u,
isEmpty: d
}, p = Fa({
@@ -24786,22 +24786,22 @@ var kte = class extends ac {
}), m, h = a.columnCount;
if (d && e.renderEmptyState && r) {
let t = {}, n = {}, r = {};
- i ? (n["aria-colspan"] = h, r = { display: "contents" }) : n.colSpan = h, m = /*#__PURE__*/ R.createElement(Uv, {
+ i ? (n["aria-colspan"] = h, r = { display: "contents" }) : n.colSpan = h, m = /*#__PURE__*/ R.createElement(Xv, {
role: "row",
...t,
style: r
- }, /*#__PURE__*/ R.createElement(Kv, {
+ }, /*#__PURE__*/ R.createElement(Qv, {
role: "rowheader",
...n,
style: r
}, e.renderEmptyState(f)));
}
- let { rowGroupProps: g } = jv(), _ = Cl(e, { global: !0 });
- return /*#__PURE__*/ R.createElement(Mte, {
+ let { rowGroupProps: g } = Pv(), _ = Cl(e, { global: !0 });
+ return /*#__PURE__*/ R.createElement(Tte, {
...J(_, p, g),
ref: t,
"data-empty": d || void 0
- }, l && /*#__PURE__*/ R.createElement(zte, null), /*#__PURE__*/ R.createElement(o, {
+ }, l && /*#__PURE__*/ R.createElement(Nte, null), /*#__PURE__*/ R.createElement(o, {
collection: a,
parent: n,
renderDropIndicator: tf(s, c)
@@ -24812,7 +24812,7 @@ var kte = class extends ac {
this.type = "tablefooter";
}
});
-var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nte = class extends ac {
+var Yv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Ete = class extends ac {
static {
this.type = "item";
}
@@ -24824,7 +24824,7 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
}
return null;
}
-}, Uv = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+}, Xv = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { isVirtualized: n } = (0, R.useContext)(hl);
return n ? /*#__PURE__*/ R.createElement(Ha.div, {
...e,
@@ -24833,8 +24833,8 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
...e,
ref: t
});
-}), Wv = /*#__PURE__*/ ol(Nte, (e, t, n) => {
- let r = Ma(t), i = (0, R.useContext)(Mv), { dragAndDropHooks: a, dragState: o, dropState: s } = (0, R.useContext)(Qd), { isVirtualized: c, CollectionBranch: l } = (0, R.useContext)(hl), u = o && !(o.isDisabled || o.selectionManager.isDisabled(n.key)), { rowProps: d, expandButtonProps: f, ...p } = mte({
+}), Zv = /*#__PURE__*/ ol(Ete, (e, t, n) => {
+ let r = Ma(t), i = (0, R.useContext)(Fv), { dragAndDropHooks: a, dragState: o, dropState: s } = (0, R.useContext)(Qd), { isVirtualized: c, CollectionBranch: l } = (0, R.useContext)(hl), u = o && !(o.isDisabled || o.selectionManager.isDisabled(n.key)), { rowProps: d, expandButtonProps: f, ...p } = dte({
node: n,
shouldSelectOnPressUp: !!o,
isVirtualized: c
@@ -24843,7 +24843,7 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
onHoverStart: e.onHoverStart,
onHoverChange: e.onHoverChange,
onHoverEnd: e.onHoverEnd
- }), { checkboxProps: x } = vte({ key: n.key }, i), S;
+ }), { checkboxProps: x } = hte({ key: n.key }, i), S;
o && a && (S = a.useDraggableItem({
key: n.key,
hasDragButton: !0
@@ -24880,10 +24880,10 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
level: n.level + 1
}
}), N = Cl(e, { global: !0 });
- return delete N.id, delete N.onClick, /*#__PURE__*/ R.createElement(R.Fragment, null, C && !C.isHidden && /*#__PURE__*/ R.createElement(Uv, {
+ return delete N.id, delete N.onClick, /*#__PURE__*/ R.createElement(R.Fragment, null, C && !C.isHidden && /*#__PURE__*/ R.createElement(Xv, {
role: "row",
style: { height: 0 }
- }, /*#__PURE__*/ R.createElement(Kv, {
+ }, /*#__PURE__*/ R.createElement(Qv, {
role: "gridcell",
colSpan: i.collection.columnCount,
style: { padding: 0 }
@@ -24892,7 +24892,7 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
...T,
...C.dropIndicatorProps,
ref: w
- }))), /*#__PURE__*/ R.createElement(Uv, {
+ }))), /*#__PURE__*/ R.createElement(Xv, {
...J(N, M, d, g, y, S?.dragProps, v),
ref: r,
"data-disabled": p.isDisabled || void 0,
@@ -24927,7 +24927,7 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
}
} }],
[sf, { isSelected: p.isSelected }],
- [Hv, { isFocusVisibleWithinRow: _ }]
+ [Yv, { isFocusVisibleWithinRow: _ }]
] }, /*#__PURE__*/ R.createElement(l, {
collection: i.collection,
parent: n
@@ -24940,11 +24940,11 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
items: e.columns,
idScope: e.id
}, e.children);
-}), Gv = class extends ac {
+}), Dte = class extends ac {
static {
this.type = "cell";
}
-}, Kv = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+}, Qv = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { isVirtualized: n } = (0, R.useContext)(hl);
return n ? /*#__PURE__*/ R.createElement(Ha.div, {
...e,
@@ -24953,16 +24953,16 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
...e,
ref: t
});
-}), qv = /*#__PURE__*/ al(Gv, (e, t, n) => {
- let r = Ma(t), i = (0, R.useContext)(Mv), { dragState: a } = (0, R.useContext)(Qd), { isVirtualized: o } = (0, R.useContext)(hl);
+}), $v = /*#__PURE__*/ al(Dte, (e, t, n) => {
+ let r = Ma(t), i = (0, R.useContext)(Fv), { dragState: a } = (0, R.useContext)(Qd), { isVirtualized: o } = (0, R.useContext)(hl);
n.column = i.collection.columns[n.index];
- let { gridCellProps: s, isPressed: c } = gte({
+ let { gridCellProps: s, isPressed: c } = pte({
node: n,
shouldSelectOnPressUp: !!a,
isVirtualized: o,
focusMode: e.focusMode,
allowsArrowNavigation: e.allowsArrowNavigation
- }, i, r), { isFocused: l, isFocusVisible: u, focusProps: d } = Jl(), { hoverProps: f, isHovered: p } = eu({}), { isFocusVisibleWithinRow: m } = (0, R.useContext)(Hv), h = n.parentKey != null && i.selectionManager.isSelected(n.parentKey), g = n.colIndex || n.index, _ = i.collection.getItem(n.parentKey), v = _.props.hasChildItems || i.collection.getItem(_.lastChildKey)?.type !== "cell", y = v && i.expandedKeys.has(n.parentKey), b = i.selectionManager.isDisabled(n.parentKey), x = Fa({
+ }, i, r), { isFocused: l, isFocusVisible: u, focusProps: d } = Jl(), { hoverProps: f, isHovered: p } = eu({}), { isFocusVisibleWithinRow: m } = (0, R.useContext)(Yv), h = n.parentKey != null && i.selectionManager.isSelected(n.parentKey), g = n.colIndex || n.index, _ = i.collection.getItem(n.parentKey), v = _.props.hasChildItems || i.collection.getItem(_.lastChildKey)?.type !== "cell", y = v && i.expandedKeys.has(n.parentKey), b = i.selectionManager.isDisabled(n.parentKey), x = Fa({
...e,
id: void 0,
defaultClassName: "react-aria-Cell",
@@ -24982,7 +24982,7 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
isTreeColumn: n.column.key === i.treeColumn
}
}), S = Cl(e, { global: !0 });
- return delete S.id, /*#__PURE__*/ R.createElement(Kv, {
+ return delete S.id, /*#__PURE__*/ R.createElement(Qv, {
...J(S, x, s, d, f),
ref: r,
"data-focused": l || void 0,
@@ -24998,12 +24998,12 @@ var Hv = /*#__PURE__*/ (0, R.createContext)({ isFocusVisibleWithinRow: !1 }), Nt
"data-disabled": b || void 0
}, /*#__PURE__*/ R.createElement(hl.Provider, { value: fl }, x.children));
});
-function Pte(e, t) {
+function Ote(e, t) {
t = Ma(t);
let { dragAndDropHooks: n, dropState: r } = (0, R.useContext)(Qd), i = (0, R.useRef)(null), { dropIndicatorProps: a, isHidden: o, isDropTarget: s } = n.useDropIndicator(e, r, i);
if (o) return null;
let c = r && e.target.type === "item" ? (r.collection.getItem(e.target.key)?.level || 0) + 1 : 1;
- return /*#__PURE__*/ R.createElement(Rte, {
+ return /*#__PURE__*/ R.createElement(Mte, {
...e,
dropIndicatorProps: a,
isDropTarget: s,
@@ -25012,7 +25012,7 @@ function Pte(e, t) {
ref: t
});
}
-var Fte = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+var kte = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { isVirtualized: n } = (0, R.useContext)(hl);
return n ? /*#__PURE__*/ R.createElement(Ha.div, {
...e,
@@ -25021,7 +25021,7 @@ var Fte = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
...e,
ref: t
});
-}), Ite = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+}), Ate = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
let { isVirtualized: n } = (0, R.useContext)(hl);
return n ? /*#__PURE__*/ R.createElement(Ha.div, {
...e,
@@ -25031,21 +25031,21 @@ var Fte = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
ref: t
});
});
-function Lte(e, t) {
- let { dropIndicatorProps: n, isDropTarget: r, buttonRef: i, level: a, ...o } = e, s = (0, R.useContext)(Mv), { visuallyHiddenProps: c } = Au(), l = Fa({
+function jte(e, t) {
+ let { dropIndicatorProps: n, isDropTarget: r, buttonRef: i, level: a, ...o } = e, s = (0, R.useContext)(Fv), { visuallyHiddenProps: c } = Au(), l = Fa({
...o,
defaultClassName: "react-aria-DropIndicator",
defaultStyle: { "--table-row-level": a + 1 },
values: { isDropTarget: r }
});
- return /*#__PURE__*/ R.createElement(Fte, {
+ return /*#__PURE__*/ R.createElement(kte, {
...Cl(e, { global: !0 }),
...l,
role: "row",
ref: t,
"data-drop-target": r || void 0,
"aria-level": a
- }, /*#__PURE__*/ R.createElement(Ite, {
+ }, /*#__PURE__*/ R.createElement(Ate, {
role: "gridcell",
colSpan: s.collection.columnCount,
style: { padding: 0 }
@@ -25056,14 +25056,14 @@ function Lte(e, t) {
ref: i
}), l.children));
}
-var Rte = /*#__PURE__*/ (0, R.forwardRef)(Lte);
-function zte() {
- let e = (0, R.useContext)(Mv), { dragAndDropHooks: t, dropState: n } = (0, R.useContext)(Qd), r = (0, R.useRef)(null), { dropIndicatorProps: i } = t.useDropIndicator({ target: { type: "root" } }, n, r), a = n.isDropTarget({ type: "root" }), { visuallyHiddenProps: o } = Au();
- return !a && i["aria-hidden"] ? null : /*#__PURE__*/ R.createElement(Uv, {
+var Mte = /*#__PURE__*/ (0, R.forwardRef)(jte);
+function Nte() {
+ let e = (0, R.useContext)(Fv), { dragAndDropHooks: t, dropState: n } = (0, R.useContext)(Qd), r = (0, R.useRef)(null), { dropIndicatorProps: i } = t.useDropIndicator({ target: { type: "root" } }, n, r), a = n.isDropTarget({ type: "root" }), { visuallyHiddenProps: o } = Au();
+ return !a && i["aria-hidden"] ? null : /*#__PURE__*/ R.createElement(Xv, {
role: "row",
"aria-hidden": i["aria-hidden"],
style: { height: 0 }
- }, /*#__PURE__*/ R.createElement(Kv, {
+ }, /*#__PURE__*/ R.createElement(Qv, {
role: "gridcell",
colSpan: e.collection.columnCount,
style: { padding: 0 }
@@ -25075,7 +25075,7 @@ function zte() {
})));
}
al(sc, function(e, t, n) {
- let r = (0, R.useContext)(Mv), { isVirtualized: i } = (0, R.useContext)(hl), { isLoading: a, onLoadMore: o, scrollOffset: s, ...c } = e, l = r.collection.columns.length, u = (0, R.useRef)(null);
+ let r = (0, R.useContext)(Fv), { isVirtualized: i } = (0, R.useContext)(hl), { isLoading: a, onLoadMore: o, scrollOffset: s, ...c } = e, l = r.collection.columns.length, u = (0, R.useRef)(null);
Fp((0, R.useMemo)(() => ({
onLoadMore: o,
collection: r?.collection,
@@ -25094,10 +25094,10 @@ al(sc, function(e, t, n) {
defaultStyle: { "--table-row-level": n.level + 1 },
values: void 0
}), f = {}, p = {}, m = {};
- return i ? (p["aria-colspan"] = l, m = { display: "contents" }) : p.colSpan = l, /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(Uv, {
+ return i ? (p["aria-colspan"] = l, m = { display: "contents" }) : p.colSpan = l, /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(Xv, {
style: { height: 0 },
inert: bp(!0)
- }, /*#__PURE__*/ R.createElement(Kv, { style: {
+ }, /*#__PURE__*/ R.createElement(Qv, { style: {
padding: 0,
border: 0
} }, /*#__PURE__*/ R.createElement("div", {
@@ -25108,14 +25108,14 @@ al(sc, function(e, t, n) {
height: 1,
width: 1
}
- }))), a && d.children && /*#__PURE__*/ R.createElement(Uv, {
+ }))), a && d.children && /*#__PURE__*/ R.createElement(Xv, {
...J(Cl(e, { global: !0 }), f),
...d,
role: "row",
ref: t,
"aria-level": n.level + 1,
"data-level": n.level + 1
- }, /*#__PURE__*/ R.createElement(Kv, {
+ }, /*#__PURE__*/ R.createElement(Qv, {
role: "rowheader",
...p,
style: m
@@ -25123,13 +25123,13 @@ al(sc, function(e, t, n) {
});
//#endregion
//#region node_modules/react-aria/dist/private/tabs/utils.mjs
-var Jv = /* @__PURE__ */ new WeakMap();
-function Yv(e, t, n) {
- return e ? (typeof t == "string" && (t = t.replace(/\s+/g, "")), `${Jv.get(e)}-${n}-${t}`) : "";
+var ey = /* @__PURE__ */ new WeakMap();
+function ty(e, t, n) {
+ return e ? (typeof t == "string" && (t = t.replace(/\s+/g, "")), `${ey.get(e)}-${n}-${t}`) : "";
}
//#endregion
//#region node_modules/react-aria/dist/private/tabs/useTab.mjs
-function Bte(e, t, n) {
+function Pte(e, t, n) {
let { key: r, isDisabled: i, shouldSelectOnPressUp: a } = e, { selectionManager: o, selectedKey: s } = t, c = r === s, l = i || t.isDisabled || t.selectionManager.isDisabled(r), u = t.collection.getItem(r), { itemProps: d, isPressed: f } = sp({
selectionManager: o,
key: r,
@@ -25137,7 +25137,7 @@ function Bte(e, t, n) {
isDisabled: l,
shouldSelectOnPressUp: a ?? u?.props.href != null,
linkBehavior: "selection"
- }), p = Yv(t, r, "tab"), m = Yv(t, r, "tabpanel"), { tabIndex: h } = d, g = Cl(u?.props, { labelable: !0 });
+ }), p = ty(t, r, "tab"), m = ty(t, r, "tabpanel"), { tabIndex: h } = d, g = Cl(u?.props, { labelable: !0 });
delete g.id;
let _ = Zo(u?.props), { focusableProps: v } = Vc({
...u?.props,
@@ -25159,12 +25159,12 @@ function Bte(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/tabs/useTabPanel.mjs
-function Vte(e, t, n) {
- let r = v_(n) ? void 0 : 0, i = Yv(t, e.id ?? t?.selectedKey, "tabpanel");
+function Fte(e, t, n) {
+ let r = y_(n) ? void 0 : 0, i = ty(t, e.id ?? t?.selectedKey, "tabpanel");
return { tabPanelProps: J(ks({
...e,
id: i,
- "aria-labelledby": Yv(t, t?.selectedKey, "tab")
+ "aria-labelledby": ty(t, t?.selectedKey, "tab")
}), {
tabIndex: r,
role: "tabpanel",
@@ -25174,7 +25174,7 @@ function Vte(e, t, n) {
}
//#endregion
//#region node_modules/react-aria/dist/private/tabs/TabsKeyboardDelegate.mjs
-var Hte = class {
+var Ite = class {
constructor(e, t, n, r = /* @__PURE__ */ new Set()) {
this.collection = e, this.flipDirection = t === "rtl", this.disabledKeys = r, this.tabDirection = n === "horizontal";
}
@@ -25218,11 +25218,11 @@ var Hte = class {
};
//#endregion
//#region node_modules/react-aria/dist/private/tabs/useTabList.mjs
-function Ute(e, t, n) {
+function Lte(e, t, n) {
let { orientation: r = "horizontal", keyboardActivation: i = "automatic" } = e, { collection: a, selectionManager: o, disabledKeys: s } = t, { direction: c } = Bs(), { collectionProps: l } = Qf({
ref: n,
selectionManager: o,
- keyboardDelegate: (0, R.useMemo)(() => new Hte(a, c, r, s), [
+ keyboardDelegate: (0, R.useMemo)(() => new Ite(a, c, r, s), [
a,
s,
r,
@@ -25233,7 +25233,7 @@ function Ute(e, t, n) {
scrollRef: n,
linkBehavior: "selection"
}), u = Ta();
- return Jv.set(t, u), { tabListProps: {
+ return ey.set(t, u), { tabListProps: {
...J(l, ks({
...e,
id: u
@@ -25245,7 +25245,7 @@ function Ute(e, t, n) {
}
//#endregion
//#region node_modules/react-stately/dist/private/list/useSingleSelectListState.mjs
-function Wte(e) {
+function Rte(e) {
let [t, n] = nc(e.selectedKey, e.defaultSelectedKey ?? null, e.onSelectionChange), r = (0, R.useMemo)(() => t == null ? [] : [t], [t]), { collection: i, disabledKeys: a, selectionManager: o } = Mp({
...e,
selectionMode: "single",
@@ -25269,24 +25269,24 @@ function Wte(e) {
}
//#endregion
//#region node_modules/react-stately/dist/private/tabs/useTabListState.mjs
-function Gte(e) {
- let t = Wte({
+function zte(e) {
+ let t = Rte({
...e,
onSelectionChange: e.onSelectionChange ? (t) => {
t != null && e.onSelectionChange?.(t);
} : void 0,
suppressTextValueWarning: !0,
- defaultSelectedKey: e.defaultSelectedKey ?? Xv(e.collection, e.disabledKeys ? new Set(e.disabledKeys) : /* @__PURE__ */ new Set()) ?? void 0
+ defaultSelectedKey: e.defaultSelectedKey ?? ny(e.collection, e.disabledKeys ? new Set(e.disabledKeys) : /* @__PURE__ */ new Set()) ?? void 0
}), { selectionManager: n, collection: r, selectedKey: i } = t, a = (0, R.useRef)(i);
return (0, R.useEffect)(() => {
let o = i;
- e.selectedKey == null && (n.isEmpty || o == null || !r.getItem(o)) && (o = Xv(r, t.disabledKeys), o != null && n.setSelectedKeys([o])), (o != null && n.focusedKey == null || !n.isFocused && o !== a.current) && n.setFocusedKey(o), a.current = o;
+ e.selectedKey == null && (n.isEmpty || o == null || !r.getItem(o)) && (o = ny(r, t.disabledKeys), o != null && n.setSelectedKeys([o])), (o != null && n.focusedKey == null || !n.isFocused && o !== a.current) && n.setFocusedKey(o), a.current = o;
}), {
...t,
isDisabled: e.isDisabled || !1
};
}
-function Xv(e, t) {
+function ny(e, t) {
let n = null;
if (e) {
for (n = e.getFirstKey(); n != null && (t.has(n) || e.getItem(n)?.props?.isDisabled) && n !== e.getLastKey();) n = e.getKeyAfter(n);
@@ -25296,20 +25296,20 @@ function Xv(e, t) {
}
//#endregion
//#region node_modules/react-aria-components/dist/private/Tabs.mjs
-var Zv = /*#__PURE__*/ (0, R.createContext)(null), Qv = /*#__PURE__*/ (0, R.createContext)(null), $v = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- [e, t] = La(e, t, Zv);
+var ry = /*#__PURE__*/ (0, R.createContext)(null), iy = /*#__PURE__*/ (0, R.createContext)(null), ay = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ [e, t] = La(e, t, ry);
let { children: n, orientation: r = "horizontal" } = e;
return n = (0, R.useMemo)(() => typeof n == "function" ? n({
orientation: r,
defaultChildren: null
- }) : n, [n, r]), /*#__PURE__*/ R.createElement(Zc, { content: n }, (n) => /*#__PURE__*/ R.createElement(ey, {
+ }) : n, [n, r]), /*#__PURE__*/ R.createElement(Zc, { content: n }, (n) => /*#__PURE__*/ R.createElement(Bte, {
props: e,
collection: n,
tabsRef: t
}));
});
-function ey({ props: e, tabsRef: t, collection: n }) {
- let { orientation: r = "horizontal" } = e, i = Gte({
+function Bte({ props: e, tabsRef: t, collection: n }) {
+ let { orientation: r = "horizontal" } = e, i = zte({
...e,
collection: n,
children: void 0
@@ -25334,16 +25334,16 @@ function ey({ props: e, tabsRef: t, collection: n }) {
"data-orientation": r,
"data-focus-visible": s || void 0,
"data-disabled": i.isDisabled || void 0
- }, /*#__PURE__*/ R.createElement(Pa, { values: [[Zv, e], [Qv, i]] }, l.children));
+ }, /*#__PURE__*/ R.createElement(Pa, { values: [[ry, e], [iy, i]] }, l.children));
}
-var ty = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- return (0, R.useContext)(Qv) ? /*#__PURE__*/ R.createElement(Kte, {
+var oy = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ return (0, R.useContext)(iy) ? /*#__PURE__*/ R.createElement(Vte, {
props: e,
forwardedRef: t
}) : /*#__PURE__*/ R.createElement(ll, e);
});
-function Kte({ props: e, forwardedRef: t }) {
- let n = (0, R.useContext)(Qv), { CollectionRoot: r } = (0, R.useContext)(hl), { orientation: i = "horizontal", keyboardActivation: a = "automatic" } = Ia(Zv), o = Ma(t), { tabListProps: s } = Ute({
+function Vte({ props: e, forwardedRef: t }) {
+ let n = (0, R.useContext)(iy), { CollectionRoot: r } = (0, R.useContext)(hl), { orientation: i = "horizontal", keyboardActivation: a = "automatic" } = Ia(ry), o = Ma(t), { tabListProps: s } = Lte({
...e,
orientation: i,
keyboardActivation: a
@@ -25365,12 +25365,12 @@ function Kte({ props: e, forwardedRef: t }) {
persistedKeys: gl(n.selectionManager.focusedKey)
})));
}
-var ny = /*#__PURE__*/ al(class extends ac {
+var sy = /*#__PURE__*/ al(class extends ac {
static {
this.type = "item";
}
}, (e, t, n) => {
- let r = (0, R.useContext)(Qv), i = Ma(t), { tabProps: a, isSelected: o, isDisabled: s, isPressed: c } = Bte({
+ let r = (0, R.useContext)(iy), i = Ma(t), { tabProps: a, isSelected: o, isDisabled: s, isPressed: c } = Pte({
key: n.key,
...e
}, r, i), { focusProps: l, isFocused: u, isFocusVisible: d } = Jl(), { hoverProps: f, isHovered: p } = eu({
@@ -25402,19 +25402,19 @@ var ny = /*#__PURE__*/ al(class extends ac {
"data-pressed": c || void 0,
"data-hovered": p || void 0
}, /*#__PURE__*/ R.createElement(sf.Provider, { value: { isSelected: o } }, m.children));
-}), ry = /*#__PURE__*/ Wc(function(e, t) {
- let n = (0, R.useContext)(Qv), r = Ma(t), i = n.selectedKey === e.id, [a, o] = (0, R.useState)(n.selectedKey == null ? null : i);
+}), cy = /*#__PURE__*/ Wc(function(e, t) {
+ let n = (0, R.useContext)(iy), r = Ma(t), i = n.selectedKey === e.id, [a, o] = (0, R.useState)(n.selectedKey == null ? null : i);
a == null && n.selectedKey != null ? o(i) : !i && a && o(!1);
let s = Fh(r, i);
- return !i && !e.shouldForceMount && !s ? null : /*#__PURE__*/ R.createElement(qte, {
+ return !i && !e.shouldForceMount && !s ? null : /*#__PURE__*/ R.createElement(Hte, {
...e,
tabPanelRef: r,
isInitiallySelected: a || !1,
isExiting: s
});
});
-function qte(e) {
- let t = (0, R.useContext)(Qv), { id: n, tabPanelRef: r, isInitiallySelected: i, isExiting: a, ...o } = e, { tabPanelProps: s } = Vte(e, t, r), { focusProps: c, isFocused: l, isFocusVisible: u } = Jl(), d = t.selectedKey === e.id, f = Ph(r) && !i, p = Fa({
+function Hte(e) {
+ let t = (0, R.useContext)(iy), { id: n, tabPanelRef: r, isInitiallySelected: i, isExiting: a, ...o } = e, { tabPanelProps: s } = Fte(e, t, r), { focusProps: c, isFocused: l, isFocusVisible: u } = Jl(), d = t.selectedKey === e.id, f = Ph(r) && !i, p = Fa({
...e,
defaultClassName: "react-aria-TabPanel",
values: {
@@ -25437,12 +25437,12 @@ function qte(e) {
"data-inert": d ? void 0 : "true",
"data-entering": f || void 0,
"data-exiting": a || void 0
- }, /*#__PURE__*/ R.createElement(Pa, { values: [[Zv, null], [Qv, null]] }, /*#__PURE__*/ R.createElement(hl.Provider, { value: fl }, p.children)));
+ }, /*#__PURE__*/ R.createElement(Pa, { values: [[ry, null], [iy, null]] }, /*#__PURE__*/ R.createElement(hl.Provider, { value: fl }, p.children)));
}
//#endregion
//#region node_modules/react-aria-components/dist/private/TextArea.mjs
-var Jte = /*#__PURE__*/ (0, R.createContext)({}), Yte = /*#__PURE__*/ (0, R.createContext)(null), Xte = /*#__PURE__*/ Wc(function(e, t) {
- [e, t] = La(e, t, Yte);
+var Ute = /*#__PURE__*/ (0, R.createContext)({}), Wte = /*#__PURE__*/ (0, R.createContext)(null), Gte = /*#__PURE__*/ Wc(function(e, t) {
+ [e, t] = La(e, t, Wte);
let { validationBehavior: n } = Ia(Wu) || {}, r = e.validationBehavior ?? n ?? "native", i = (0, R.useRef)(null);
[e, i] = La(e, i, ic);
let [a, o] = Ra(!e["aria-label"] && !e["aria-labelledby"]), [s, c] = (0, R.useState)("input"), { labelProps: l, inputProps: u, descriptionProps: d, errorMessageProps: f, ...p } = gd({
@@ -25480,7 +25480,7 @@ var Jte = /*#__PURE__*/ (0, R.createContext)({}), Yte = /*#__PURE__*/ (0, R.crea
...u,
ref: m
}],
- [Jte, {
+ [Ute, {
...u,
ref: m
}],
@@ -25498,7 +25498,7 @@ var Jte = /*#__PURE__*/ (0, R.createContext)({}), Yte = /*#__PURE__*/ (0, R.crea
});
//#endregion
//#region src/react/boardui/components/base/input/label.tsx
-function Zte({ isRequired: e = !1, isInvalid: t, tooltip: n, className: r, children: i, ...a }) {
+function Kte({ isRequired: e = !1, isInvalid: t, tooltip: n, className: r, children: i, ...a }) {
return /* @__PURE__ */ (0, z.jsxs)(nu, {
"data-label": "true",
...a,
@@ -25519,7 +25519,7 @@ function Zte({ isRequired: e = !1, isInvalid: t, tooltip: n, className: r, child
}
//#endregion
//#region src/react/boardui/components/base/input/hint-text.tsx
-function Qte({ isInvalid: e = !1, className: t, ...n }) {
+function qte({ isInvalid: e = !1, className: t, ...n }) {
return /* @__PURE__ */ (0, z.jsx)(vu, {
slot: e ? "errorMessage" : "description",
...n,
@@ -25528,15 +25528,15 @@ function Qte({ isInvalid: e = !1, className: t, ...n }) {
}
//#endregion
//#region src/react/boardui/components/base/input/input.tsx
-var iy = (0, R.createContext)({});
-function ay({ size: e = "medium", fieldClassName: t, inputClassName: n, className: r, children: i, ...a }) {
- return /* @__PURE__ */ (0, z.jsx)(iy.Provider, {
+var ly = (0, R.createContext)({});
+function uy({ size: e = "medium", fieldClassName: t, inputClassName: n, className: r, children: i, ...a }) {
+ return /* @__PURE__ */ (0, z.jsx)(ly.Provider, {
value: {
size: e,
fieldClassName: t,
inputClassName: n
},
- children: /* @__PURE__ */ (0, z.jsx)(Xte, {
+ children: /* @__PURE__ */ (0, z.jsx)(Gte, {
...a,
"data-input-size": e,
className: Ii("group flex h-max w-full flex-col items-start gap-1", r),
@@ -25544,8 +25544,8 @@ function ay({ size: e = "medium", fieldClassName: t, inputClassName: n, classNam
})
});
}
-ay.displayName = "TextField";
-var oy = Li({
+uy.displayName = "TextField";
+var dy = Li({
field: [
"relative flex w-full items-center",
"rounded-2lg",
@@ -25574,44 +25574,44 @@ var oy = Li({
].join(" "),
icon: "size-5 shrink-0"
});
-function sy({ size: e, leadingIcon: t, trailingIcon: n, leadingAddon: r, fieldClassName: i, className: a, ref: o, groupRef: s, ...c }) {
- let l = (0, R.useContext)(iy), u = e ?? l.size ?? "medium", d = r != null;
+function fy({ size: e, leadingIcon: t, trailingIcon: n, leadingAddon: r, fieldClassName: i, className: a, ref: o, groupRef: s, ...c }) {
+ let l = (0, R.useContext)(ly), u = e ?? l.size ?? "medium", d = r != null;
return /* @__PURE__ */ (0, z.jsx)(fd, {
ref: s,
- className: ({ isFocusWithin: e, isHovered: t, isDisabled: n, isInvalid: r }) => Ii(oy.field, d ? oy.fieldWithAddonSize[u] : oy.fieldSize[u], t && !e && !n && !r && "ring-border-button-hover", e && !n && !r && "ring-border-button-active", n && "bg-input-disabled-background text-input-disabled-foreground", r && "bg-background-tertiary-error text-foreground-icon-error", l.fieldClassName, i),
+ className: ({ isFocusWithin: e, isHovered: t, isDisabled: n, isInvalid: r }) => Ii(dy.field, d ? dy.fieldWithAddonSize[u] : dy.fieldSize[u], t && !e && !n && !r && "ring-border-button-hover", e && !n && !r && "ring-border-button-active", n && "bg-input-disabled-background text-input-disabled-foreground", r && "bg-background-tertiary-error text-foreground-icon-error", l.fieldClassName, i),
children: /* @__PURE__ */ (0, z.jsxs)("div", {
- className: oy.content,
+ className: dy.content,
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
- className: oy.leftSection,
+ className: dy.leftSection,
children: [d ? r : t ? /* @__PURE__ */ (0, z.jsx)(t, {
- className: oy.icon,
+ className: dy.icon,
"aria-hidden": !0
}) : null, /* @__PURE__ */ (0, z.jsx)(hd, {
ref: o,
...c,
- className: Ii(oy.input, l.inputClassName, a)
+ className: Ii(dy.input, l.inputClassName, a)
})]
}), n ? /* @__PURE__ */ (0, z.jsx)(n, {
- className: oy.icon,
+ className: dy.icon,
"aria-hidden": !0
}) : null]
})
});
}
-sy.displayName = "InputBase";
-function cy({ label: e, hint: t, tooltip: n, placeholder: r, leadingIcon: i, trailingIcon: a, leadingAddon: o, fieldClassName: s, ref: c, groupRef: l, className: u, ...d }) {
- return /* @__PURE__ */ (0, z.jsx)(ay, {
+fy.displayName = "InputBase";
+function py({ label: e, hint: t, tooltip: n, placeholder: r, leadingIcon: i, trailingIcon: a, leadingAddon: o, fieldClassName: s, ref: c, groupRef: l, className: u, ...d }) {
+ return /* @__PURE__ */ (0, z.jsx)(uy, {
...d,
className: u,
"aria-label": d["aria-label"] ?? (!e && typeof r == "string" ? r : void 0),
children: ({ isRequired: u, isInvalid: d }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
- e && /* @__PURE__ */ (0, z.jsx)(Zte, {
+ e && /* @__PURE__ */ (0, z.jsx)(Kte, {
isRequired: u,
isInvalid: d,
tooltip: n,
children: e
}),
- /* @__PURE__ */ (0, z.jsx)(sy, {
+ /* @__PURE__ */ (0, z.jsx)(fy, {
ref: c,
groupRef: l,
placeholder: r,
@@ -25620,17 +25620,17 @@ function cy({ label: e, hint: t, tooltip: n, placeholder: r, leadingIcon: i, tra
leadingAddon: o,
fieldClassName: s
}),
- t && /* @__PURE__ */ (0, z.jsx)(Qte, {
+ t && /* @__PURE__ */ (0, z.jsx)(qte, {
isInvalid: d,
children: t
})
] })
});
}
-cy.displayName = "Input";
+py.displayName = "Input";
//#endregion
//#region src/react/boardui/components/base/dropdown/menu-styles.ts
-var ly = [
+var my = [
"max-w-[calc(100vw-32px)] overflow-y-auto",
"rounded-2xl border border-border-button-default bg-background-primary-default p-2.5 shadow-dropdown",
"transition duration-150 ease-out",
@@ -25638,10 +25638,10 @@ var ly = [
"data-[exiting]:opacity-0 data-[exiting]:scale-95 data-[exiting]:blur-[2px]",
"data-[placement=bottom]:origin-top-left data-[placement=top]:origin-bottom-left",
"data-[placement=left]:origin-right data-[placement=right]:origin-left"
-].join(" "), $te = "w-[266px]", ene = "flex w-full flex-col gap-1 outline-none", uy = ["flex w-full cursor-pointer items-center gap-2 rounded-2lg p-2 text-left", "text-text-primary outline-none transition-colors"].join(" "), dy = "hover:bg-dropdown-item-hover-background focus-visible:bg-dropdown-item-hover-background";
+].join(" "), Jte = "w-[266px]", Yte = "flex w-full flex-col gap-1 outline-none", hy = ["flex w-full cursor-pointer items-center gap-2 rounded-2lg p-2 text-left", "text-text-primary outline-none transition-colors"].join(" "), gy = "hover:bg-dropdown-item-hover-background focus-visible:bg-dropdown-item-hover-background";
//#endregion
//#region src/react/boardui/components/foundations/icons/chevrons.tsx
-function tne(e) {
+function Xte(e) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 16 16",
fill: "none",
@@ -25655,7 +25655,7 @@ function tne(e) {
})
});
}
-function nne(e) {
+function Zte(e) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
fill: "none",
@@ -25669,7 +25669,7 @@ function nne(e) {
}
//#endregion
//#region src/react/boardui/utils/use-dismiss-on-outside-press.ts
-function rne(e, t, n) {
+function Qte(e, t, n) {
(0, R.useEffect)(() => {
if (!e) return;
let r = (e) => {
@@ -25683,7 +25683,7 @@ function rne(e, t, n) {
n
]);
}
-function ine(e, t) {
+function $te(e, t) {
let n = (0, R.useRef)(!1);
return (0, R.useEffect)(() => {
if (!e) return;
@@ -25697,12 +25697,12 @@ function ine(e, t) {
}
//#endregion
//#region src/react/boardui/components/base/select/select.tsx
-var fy = (0, R.createContext)("md");
-function py({ className: e, triggerClassName: t, popoverClassName: n, size: r = "md", children: i, items: a, renderValue: o, ref: s, ...c }) {
+var _y = (0, R.createContext)("md");
+function vy({ className: e, triggerClassName: t, popoverClassName: n, size: r = "md", children: i, items: a, renderValue: o, ref: s, ...c }) {
let l = (0, R.useRef)(null), u = (0, R.useRef)(null), [d, f] = (0, R.useState)(!1);
- rne(d, () => f(!1), [l, u]);
- let p = ine(d, l);
- return /* @__PURE__ */ (0, z.jsx)(Uee, {
+ Qte(d, () => f(!1), [l, u]);
+ let p = $te(d, l);
+ return /* @__PURE__ */ (0, z.jsx)(Hee, {
ref: s,
...c,
isOpen: d,
@@ -25711,19 +25711,19 @@ function py({ className: e, triggerClassName: t, popoverClassName: n, size: r =
children: ({ isOpen: e }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsxs)(fu, {
ref: l,
className: Ii("flex w-full cursor-pointer items-center justify-between rounded-2lg", "border border-border-button-default bg-background-primary-default shadow-xs", "text-text-primary", "transition-[background-color,border-color,box-shadow,padding,font-size] duration-200 ease", "hover:bg-background-primary-hover hover:border-border-button-hover", "outline-none focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:ring-border-focus-ring", "disabled:cursor-not-allowed disabled:bg-background-primary-disabled disabled:text-text-tertiary disabled:shadow-none", r === "sm" ? "gap-1 px-[7px] py-1 text-body-2-medium" : "gap-1.5 px-2.5 py-2 text-body-medium", t),
- children: [/* @__PURE__ */ (0, z.jsx)(Kee, {
+ children: [/* @__PURE__ */ (0, z.jsx)(Gee, {
className: Ii("flex min-w-0 items-center truncate", r === "sm" ? "gap-1" : "gap-[5px]"),
children: o
- }), /* @__PURE__ */ (0, z.jsx)(tne, { className: Ii("shrink-0 text-text-secondary transition-transform duration-200 ease", r === "sm" ? "size-3.5" : "size-4", e && "rotate-180") })]
+ }), /* @__PURE__ */ (0, z.jsx)(Xte, { className: Ii("shrink-0 text-text-secondary transition-transform duration-200 ease", r === "sm" ? "size-3.5" : "size-4", e && "rotate-180") })]
}), /* @__PURE__ */ (0, z.jsx)(zh, {
ref: u,
isNonModal: !0,
offset: 4,
- className: Ii($te, ly, "p-2", n),
+ className: Ii(Jte, my, "p-2", n),
children: /* @__PURE__ */ (0, z.jsx)(Rp, {
items: a,
- className: Ii(ene, "max-h-[240px] overflow-auto"),
- children: /* @__PURE__ */ (0, z.jsx)(fy.Provider, {
+ className: Ii(Yte, "max-h-[240px] overflow-auto"),
+ children: /* @__PURE__ */ (0, z.jsx)(_y.Provider, {
value: r,
children: i
})
@@ -25731,29 +25731,29 @@ function py({ className: e, triggerClassName: t, popoverClassName: n, size: r =
})] })
});
}
-function my({ className: e, children: t, ...n }) {
- let r = (0, R.useContext)(fy);
+function yy({ className: e, children: t, ...n }) {
+ let r = (0, R.useContext)(_y);
return /* @__PURE__ */ (0, z.jsx)(Hp, {
...n,
- className: (t) => Ii(uy, r === "sm" ? "px-2 py-1.5 text-body-2-medium" : "text-body-medium", (t.isFocused || t.isSelected) && "bg-dropdown-item-hover-background", t.isDisabled && "cursor-not-allowed text-text-disabled", typeof e == "function" ? e(t) : e),
+ className: (t) => Ii(hy, r === "sm" ? "px-2 py-1.5 text-body-2-medium" : "text-body-medium", (t.isFocused || t.isSelected) && "bg-dropdown-item-hover-background", t.isDisabled && "cursor-not-allowed text-text-disabled", typeof e == "function" ? e(t) : e),
children: t
});
}
//#endregion
//#region src/react/boardui/components/application/settings/settings-rows.tsx
-function hy({ className: e, children: t }) {
+function by({ className: e, children: t }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
className: Ii("flex w-full flex-col rounded-2xl bg-background-secondary-default pl-3", e),
children: t
});
}
-function gy({ className: e, children: t }) {
+function xy({ className: e, children: t }) {
return /* @__PURE__ */ (0, z.jsx)("p", {
className: Ii("w-full px-3 text-body-2-medium text-text-secondary", e),
children: t
});
}
-function _y({ label: e, description: t, children: n }) {
+function Sy({ label: e, description: t, children: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: Ii("flex min-h-[52px] w-full items-center justify-between gap-4 py-2.5 pr-2.5", "border-b border-separator-border last:border-b-0"),
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
@@ -25770,7 +25770,7 @@ function _y({ label: e, description: t, children: n }) {
}
//#endregion
//#region src/react/boardui/components/base/buttons/link-button.tsx
-var vy = Li({
+var Cy = Li({
base: [
"inline-flex items-center justify-center gap-1 whitespace-nowrap",
"font-sans select-none cursor-pointer rounded-sm",
@@ -25794,15 +25794,15 @@ var vy = Li({
secondary: ["text-text-secondary active:text-text-primary", "disabled:text-text-tertiary aria-disabled:text-text-tertiary"].join(" ")
}
});
-function yy({ variant: e = "primary", size: t = "medium", leadingIcon: n, trailingIcon: r, children: i, className: a, disabled: o = !1, ...s }) {
- let c = Ii(vy.base, vy.size[t], vy.variant[e], a), l = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
+function wy({ variant: e = "primary", size: t = "medium", leadingIcon: n, trailingIcon: r, children: i, className: a, disabled: o = !1, ...s }) {
+ let c = Ii(Cy.base, Cy.size[t], Cy.variant[e], a), l = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
n ? /* @__PURE__ */ (0, z.jsx)(n, {
- className: vy.icon[t],
+ className: Cy.icon[t],
"aria-hidden": !0
}) : null,
i != null && /* @__PURE__ */ (0, z.jsx)("span", { children: i }),
r ? /* @__PURE__ */ (0, z.jsx)(r, {
- className: vy.icon[t],
+ className: Cy.icon[t],
"aria-hidden": !0
}) : null
] });
@@ -25829,14 +25829,14 @@ function yy({ variant: e = "primary", size: t = "medium", leadingIcon: n, traili
}
//#endregion
//#region src/react/settings/section.tsx
-function by({ title: e, id: t, aside: n, onSubmit: r, children: i }) {
+function Ty({ title: e, id: t, aside: n, onSubmit: r, children: i }) {
let a = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [n ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex w-full flex-wrap items-center justify-between gap-2",
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "min-w-0 flex-1",
- children: /* @__PURE__ */ (0, z.jsx)(gy, { children: e })
+ children: /* @__PURE__ */ (0, z.jsx)(xy, { children: e })
}), n]
- }) : /* @__PURE__ */ (0, z.jsx)(gy, { children: e }), /* @__PURE__ */ (0, z.jsx)(hy, { children: i })] });
+ }) : /* @__PURE__ */ (0, z.jsx)(xy, { children: e }), /* @__PURE__ */ (0, z.jsx)(by, { children: i })] });
return r ? /* @__PURE__ */ (0, z.jsx)("form", {
id: t,
"aria-label": e,
@@ -25851,13 +25851,13 @@ function by({ title: e, id: t, aside: n, onSubmit: r, children: i }) {
children: a
});
}
-function xy({ children: e }) {
+function Ey({ children: e }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
className: "flex flex-col",
children: e
});
}
-function Sy({ divided: e = !1, children: t }) {
+function Dy({ divided: e = !1, children: t }) {
return e ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "flex flex-col gap-4 border-t border-separator-border py-4 pr-3",
children: t
@@ -25866,7 +25866,7 @@ function Sy({ divided: e = !1, children: t }) {
children: t
});
}
-function Cy({ status: e, children: t }) {
+function Oy({ status: e, children: t }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "-ml-3 flex flex-wrap items-center justify-end gap-3 rounded-b-2xl border-t border-separator-border bg-card-footer px-3 py-3",
children: [e ? /* @__PURE__ */ (0, z.jsx)("div", {
@@ -25875,28 +25875,28 @@ function Cy({ status: e, children: t }) {
}) : null, t]
});
}
-function wy({ role: e, children: t }) {
+function ky({ role: e, children: t }) {
return /* @__PURE__ */ (0, z.jsx)("p", {
role: e,
className: "text-body-2-regular text-text-secondary",
children: t
});
}
-function Ty({ children: e }) {
+function Ay({ children: e }) {
return /* @__PURE__ */ (0, z.jsx)("p", {
role: "alert",
className: "text-body-2-regular text-text-error-primary",
children: e
});
}
-function Ey({ children: e }) {
+function jy({ children: e }) {
return /* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-medium text-text-primary",
children: e
});
}
-function Dy({ href: e, children: t, leadingIcon: n }) {
- return /* @__PURE__ */ (0, z.jsx)(yy, {
+function My({ href: e, children: t, leadingIcon: n }) {
+ return /* @__PURE__ */ (0, z.jsx)(wy, {
href: e,
target: "_blank",
rel: "noopener noreferrer",
@@ -25910,13 +25910,13 @@ function Dy({ href: e, children: t, leadingIcon: n }) {
})
});
}
-function Oy({ children: e }) {
+function Ny({ children: e }) {
return /* @__PURE__ */ (0, z.jsx)("dl", {
className: "flex flex-col",
children: e
});
}
-function ky({ term: e, children: t }) {
+function Py({ term: e, children: t }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-h-11 items-center justify-between gap-4 border-b border-separator-border py-2.5 pr-3 last:border-b-0",
children: [/* @__PURE__ */ (0, z.jsx)("dt", {
@@ -25928,7 +25928,7 @@ function ky({ term: e, children: t }) {
})]
});
}
-function Ay({ summary: e, defaultOpen: t = !1, children: n }) {
+function Fy({ summary: e, defaultOpen: t = !1, children: n }) {
let r = (0, R.useId)(), i = (0, R.useRef)(null), a = (0, R.useRef)(null), o = (0, R.useRef)(!1), [s, c] = (0, R.useState)(t);
return /* @__PURE__ */ (0, z.jsxs)("details", {
ref: (e) => {
@@ -25956,7 +25956,7 @@ function Ay({ summary: e, defaultOpen: t = !1, children: n }) {
})]
});
}
-function ane({ name: e }) {
+function ene({ name: e }) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
"aria-hidden": !0,
viewBox: "0 0 24 24",
@@ -25965,14 +25965,14 @@ function ane({ name: e }) {
children: /* @__PURE__ */ (0, z.jsx)("use", { href: `#i-${e}` })
});
}
-function jy({ mark: e }) {
+function Iy({ mark: e }) {
return e.startsWith("data:image/png;base64,") ? /* @__PURE__ */ (0, z.jsx)("img", {
src: e,
alt: "",
width: 16,
height: 16,
className: "size-4 shrink-0"
- }) : /* @__PURE__ */ (0, z.jsx)(ane, { name: e });
+ }) : /* @__PURE__ */ (0, z.jsx)(ene, { name: e });
}
//#endregion
//#region src/react/query.ts
@@ -25982,11 +25982,11 @@ var X = new Bn({ defaultOptions: { queries: {
refetchOnWindowFocus: !1,
refetchOnMount: !1,
retryOnMount: !1
-} } }), My = "/api/tasks", Ny = ["tasks"], one = (e, t) => W(`${My}?${new URLSearchParams({
+} } }), Ly = "/api/tasks", Ry = ["tasks"], tne = (e, t) => W(`${Ly}?${new URLSearchParams({
before_finished_at: e.finished_at || "",
before_id: String(e.id)
})}`, t);
-function Py(...e) {
+function zy(...e) {
let t = /* @__PURE__ */ new Map();
for (let n of e) for (let e of n) t.has(e.id) || t.set(e.id, e);
return [...t.values()].sort((e, t) => {
@@ -25994,26 +25994,26 @@ function Py(...e) {
return n === r ? t.id - e.id : n < r ? 1 : -1;
});
}
-var Fy = 2e3, Iy = 1e4, Ly = (e) => e?.running.length ? Fy : Iy, Ry = (e) => W(My, e);
-async function zy(e) {
+var nne = 2e3, rne = 1e4, ine = (e) => e?.running.length ? nne : rne, By = (e) => W(Ly, e);
+async function ane(e) {
await X.fetchQuery({
- queryKey: Ny,
- queryFn: () => Ry(e)
+ queryKey: Ry,
+ queryFn: () => By(e)
});
}
-var By = {
+var Vy = {
manual: "手动",
scheduled: "定时",
startup: "启动",
cli: "命令行"
-}, Vy = {
+}, one = {
pending: "排队中",
running: "进行中",
succeeded: "已完成",
failed: "失败",
cancelled: "已取消",
interrupted: "被打断"
-}, Hy = (e) => Vy[e] || e, Uy = {
+}, sne = (e) => one[e] || e, cne = {
checked: "已检查",
total: "总数",
scanned: "已扫描",
@@ -26043,7 +26043,7 @@ var By = {
source: "来源",
cover_network: "封面连不上图片主机"
};
-function Wy(e) {
+function lne(e) {
let t = /* @__PURE__ */ new Map();
for (let n of e) {
if (!n.followup_key || n.parent_run_id == null) continue;
@@ -26052,7 +26052,7 @@ function Wy(e) {
}
return t;
}
-function Gy(e, t) {
+function une(e, t) {
let n = [], r = /* @__PURE__ */ new Map();
for (let i of e) {
if (!t(i)) {
@@ -26074,19 +26074,19 @@ function Gy(e, t) {
}
return n;
}
-var Ky = (e) => e.trigger === "scheduled" && e.status === "succeeded" && !e.error && !(Number(e.result_summary?.added) > 0) && !(Number(e.result_summary?.followups) > 0), qy = (e) => e.status === "pending" || e.status === "running";
-function Jy(e) {
+var dne = (e) => e.trigger === "scheduled" && e.status === "succeeded" && !e.error && !(Number(e.result_summary?.added) > 0) && !(Number(e.result_summary?.followups) > 0), Hy = (e) => e.status === "pending" || e.status === "running";
+function fne(e) {
let t = `${e.task_label}:`, n = e.progress_label || "", r = n.startsWith(t) ? n.slice(t.length) : n === e.task_label ? "" : n, i = e.progress_total || 0;
- return [r, e.error || Qy(e.result_summary) || (qy(e) && i > 0 ? `${e.progress_current || 0} / ${i} 项` : "")].filter(Boolean).join(" · ");
+ return [r, e.error || Gy(e.result_summary) || (Hy(e) && i > 0 ? `${e.progress_current || 0} / ${i} 项` : "")].filter(Boolean).join(" · ");
}
-function Yy(e) {
+function Uy(e) {
if (typeof e != "number" || !Number.isFinite(e) || e < 0) return "";
let t = Math.floor(e);
if (t < 60) return `${t} 秒`;
let n = Math.floor(t / 60);
return n < 60 ? `${n} 分 ${t % 60} 秒` : `${Math.floor(n / 60)} 小时 ${n % 60} 分`;
}
-function Xy(e) {
+function Wy(e) {
if (!e) return "";
let t = new Date(e);
return Number.isNaN(t.getTime()) ? "" : t.toLocaleString(void 0, {
@@ -26096,7 +26096,7 @@ function Xy(e) {
minute: "2-digit"
});
}
-var Zy = /* @__PURE__ */ new Set([
+var pne = /* @__PURE__ */ new Set([
"blocked_by",
"status",
"run_id",
@@ -26105,28 +26105,28 @@ var Zy = /* @__PURE__ */ new Set([
"completed_at",
"finished_at"
]);
-function Qy(e) {
- return Object.entries(e || {}).filter(([e, t]) => !Zy.has(e) && (typeof t == "number" || typeof t == "string") && String(t) !== "").map(([e, t]) => `${Uy[e] || e} ${t}`).join(" · ");
+function Gy(e) {
+ return Object.entries(e || {}).filter(([e, t]) => !pne.has(e) && (typeof t == "number" || typeof t == "string") && String(t) !== "").map(([e, t]) => `${cne[e] || e} ${t}`).join(" · ");
}
//#endregion
//#region src/react/activity/downloads-panel.tsx
-var $y = "/api/downloads", eb = ["downloads"], tb = "/api/downloads/cancel", nb = (e) => e?.tasks.some((e) => e.cancellable) ? 5e3 : 3e4, rb = {
+var Ky = "/api/downloads", qy = ["downloads"], mne = "/api/downloads/cancel", hne = (e) => e?.tasks.some((e) => e.cancellable) ? 5e3 : 3e4, gne = {
ingested: "lime",
failed: "rose",
cancelled: "yellow",
stalled: "yellow"
-}, ib = {
+}, _ne = {
submitted: "已提交,远端开始下载后这里会显示进度。",
adopted: "这个磁力已经有任务了,接着跟进那一条,没有重复提交。",
adopted_remote: "远端已经有同一个任务,已接管,没有再扣配额。",
refused: "这个资源被判为违规,不再提交。",
failed: "提交没有成功。"
-}, sne = (e) => e.title || e.display_name || e.remote_name || e.code || `磁力 ${e.info_hash?.slice(0, 8) ?? e.id}`, ab = (e) => e.failure_label ? [e.failure_label, e.failure_detail].filter(Boolean).join(":") : "";
-function cne({ prefill: e }) {
+}, vne = (e) => e.title || e.display_name || e.remote_name || e.code || `磁力 ${e.info_hash?.slice(0, 8) ?? e.id}`, Jy = (e) => e.failure_label ? [e.failure_label, e.failure_detail].filter(Boolean).join(":") : "";
+function yne({ prefill: e }) {
let t = $n({
- queryKey: eb,
- queryFn: ({ signal: e }) => W(`${$y}?limit=50`, e),
- refetchInterval: (e) => nb(e.state.data)
+ queryKey: qy,
+ queryFn: ({ signal: e }) => W(`${Ky}?limit=50`, e),
+ refetchInterval: (e) => hne(e.state.data)
}), n = t.data;
if (!n) return t.error ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
@@ -26138,7 +26138,7 @@ function cne({ prefill: e }) {
tone: "error",
children: U(t.error)
}) : null,
- n.available ? r.length ? /* @__PURE__ */ (0, z.jsx)(lne, {
+ n.available ? r.length ? /* @__PURE__ */ (0, z.jsx)(bne, {
snapshot: n,
prefill: e
}) : /* @__PURE__ */ (0, z.jsx)(K, {
@@ -26151,14 +26151,14 @@ function cne({ prefill: e }) {
n.tasks.length ? /* @__PURE__ */ (0, z.jsx)("ul", {
"aria-live": "polite",
className: "flex min-w-0 flex-col gap-3",
- children: n.tasks.map((e) => /* @__PURE__ */ (0, z.jsx)(dne, {
+ children: n.tasks.map((e) => /* @__PURE__ */ (0, z.jsx)(Sne, {
task: e,
writable: n.available
}, e.id))
}) : null
] });
}
-function lne({ snapshot: e, prefill: t }) {
+function bne({ snapshot: e, prefill: t }) {
let n = Dt(), r = e.providers.filter((e) => e.configured), [i, a] = (0, R.useState)(r[0].key), [o, s] = (0, R.useState)(""), [c, l] = (0, R.useState)(t?.code ?? ""), [u, d] = (0, R.useState)(r[0].target), [f, p] = (0, R.useState)(null), m = aa(), h = (0, R.useRef)(null);
(0, R.useEffect)(() => {
t && h.current?.focus();
@@ -26179,14 +26179,14 @@ function lne({ snapshot: e, prefill: t }) {
title: t?.title,
origin: t?.origin
};
- p(null), m.run("submit", (e) => G($y, r, "POST", e), (e) => {
- p(e), e.ok && s(""), n.invalidateQueries({ queryKey: eb });
+ p(null), m.run("submit", (e) => G(Ky, r, "POST", e), (e) => {
+ p(e), e.ok && s(""), n.invalidateQueries({ queryKey: qy });
});
},
- children: /* @__PURE__ */ (0, z.jsxs)(hy, { children: [
- /* @__PURE__ */ (0, z.jsxs)(Sy, { children: [
- t?.title ? /* @__PURE__ */ (0, z.jsx)(wy, { children: `给「${t.title}」找来的资源,下载完由推送发现登记入库。` }) : null,
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ children: /* @__PURE__ */ (0, z.jsxs)(by, { children: [
+ /* @__PURE__ */ (0, z.jsxs)(Dy, { children: [
+ t?.title ? /* @__PURE__ */ (0, z.jsx)(ky, { children: `给「${t.title}」找来的资源,下载完由推送发现登记入库。` }) : null,
+ /* @__PURE__ */ (0, z.jsx)(py, {
ref: h,
label: "磁力链接",
placeholder: "magnet:?xt=urn:btih:…",
@@ -26197,19 +26197,19 @@ function lne({ snapshot: e, prefill: t }) {
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-1",
- children: [/* @__PURE__ */ (0, z.jsx)(Ey, { children: "下载到" }), /* @__PURE__ */ (0, z.jsx)(py, {
+ children: [/* @__PURE__ */ (0, z.jsx)(jy, { children: "下载到" }), /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "下载到",
selectedKey: i,
onSelectionChange: (e) => {
e !== null && _(String(e));
},
- children: r.map((e) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: r.map((e) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e.key,
children: e.label
}, e.key))
})]
}),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "目标目录",
placeholder: g.target || "/云下载",
autoComplete: "off",
@@ -26218,7 +26218,7 @@ function lne({ snapshot: e, prefill: t }) {
value: u,
onChange: d
}),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "番号",
placeholder: "可不填",
autoComplete: "off",
@@ -26227,15 +26227,15 @@ function lne({ snapshot: e, prefill: t }) {
onChange: l
})
] }),
- f ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ f ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
- children: /* @__PURE__ */ (0, z.jsx)(une, { result: f })
+ children: /* @__PURE__ */ (0, z.jsx)(xne, { result: f })
}) : null,
- m.error ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ m.error ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
- children: /* @__PURE__ */ (0, z.jsx)(Ty, { children: m.error })
+ children: /* @__PURE__ */ (0, z.jsx)(Ay, { children: m.error })
}) : null,
- /* @__PURE__ */ (0, z.jsx)(Cy, {
+ /* @__PURE__ */ (0, z.jsx)(Oy, {
status: i === "115" ? "115 每提交一次扣一条离线配额,重新提交也算。" : void 0,
children: /* @__PURE__ */ (0, z.jsx)(H, {
type: "submit",
@@ -26247,23 +26247,23 @@ function lne({ snapshot: e, prefill: t }) {
] })
});
}
-function une({ result: e }) {
- let t = ab(e.task), n = ib[e.outcome];
- return e.outcome === "failed" ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: t ? `${n}${t}` : n }) : e.outcome === "refused" ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: n }) : /* @__PURE__ */ (0, z.jsx)(wy, {
+function xne({ result: e }) {
+ let t = Jy(e.task), n = _ne[e.outcome];
+ return e.outcome === "failed" ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: t ? `${n}${t}` : n }) : e.outcome === "refused" ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: n }) : /* @__PURE__ */ (0, z.jsx)(ky, {
role: "status",
children: n
});
}
-function dne({ task: e, writable: t }) {
- let n = Dt(), r = aa(), [i, a] = (0, R.useState)(!1), o = ab(e), s = e.state === "failed", c = [
+function Sne({ task: e, writable: t }) {
+ let n = Dt(), r = aa(), [i, a] = (0, R.useState)(!1), o = Jy(e), s = e.state === "failed", c = [
e.provider_label,
e.code,
e.target,
- Xy(e.submitted_at)
+ Wy(e.submitted_at)
].filter(Boolean).join(" · "), l = () => {
- n.invalidateQueries({ queryKey: eb });
+ n.invalidateQueries({ queryKey: qy });
}, u = () => {
- r.run("cancel", (t) => G(tb, { id: e.id }, "POST", t), l);
+ r.run("cancel", (t) => G(mne, { id: e.id }, "POST", t), l);
}, d = () => {
let t = {
magnet: e.source_uri,
@@ -26273,7 +26273,7 @@ function dne({ task: e, writable: t }) {
title: e.title,
origin: e.origin
};
- r.run("resubmit", (e) => G($y, t, "POST", e), l);
+ r.run("resubmit", (e) => G(Ky, t, "POST", e), l);
}, f = () => {
navigator.clipboard.writeText(e.source_uri).then(() => a(!0), () => a(!1));
};
@@ -26292,9 +26292,9 @@ function dne({ task: e, writable: t }) {
className: "flex flex-wrap items-center gap-2",
children: [/* @__PURE__ */ (0, z.jsx)("strong", {
className: "min-w-0 break-words text-title-1-medium text-text-primary",
- children: sne(e)
+ children: vne(e)
}), /* @__PURE__ */ (0, z.jsx)(zi, {
- color: rb[e.state] ?? "neutral",
+ color: gne[e.state] ?? "neutral",
children: e.state_label
})]
}),
@@ -26311,7 +26311,7 @@ function dne({ task: e, writable: t }) {
className: "min-w-0 break-all text-caption-1-regular text-text-secondary",
children: e.ledger_path
}) : null,
- r.error ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: r.error }) : null,
+ r.error ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: r.error }) : null,
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center gap-2 pt-1",
children: [
@@ -26349,23 +26349,23 @@ function dne({ task: e, writable: t }) {
}
//#endregion
//#region src/react/activity/activity-page.tsx
-var fne = {
+var Cne = {
succeeded: "lime",
failed: "rose",
cancelled: "yellow",
interrupted: "yellow"
};
-function ob({ status: e }) {
+function Yy({ status: e }) {
return /* @__PURE__ */ (0, z.jsx)(zi, {
- color: fne[e] ?? "neutral",
- children: Hy(e)
+ color: Cne[e] ?? "neutral",
+ children: sne(e)
});
}
-function pne({ rows: e }) {
+function wne({ rows: e }) {
return /* @__PURE__ */ (0, z.jsx)("ul", {
className: "flex min-w-0 flex-col",
children: e.map((e) => {
- let t = Jy(e);
+ let t = fne(e);
return /* @__PURE__ */ (0, z.jsxs)("li", {
"data-status": e.status,
"data-followup-key": e.followup_key,
@@ -26375,7 +26375,7 @@ function pne({ rows: e }) {
className: "min-w-0 break-words text-caption-1-regular text-text-primary",
children: e.task_label
}),
- /* @__PURE__ */ (0, z.jsx)(ob, { status: e.status }),
+ /* @__PURE__ */ (0, z.jsx)(Yy, { status: e.status }),
t ? /* @__PURE__ */ (0, z.jsx)("span", {
className: "min-w-0 break-words text-caption-1-regular text-text-secondary",
children: t
@@ -26385,7 +26385,7 @@ function pne({ rows: e }) {
})
});
}
-function sb({ run: e, meta: t, children: n, footer: r, followups: i }) {
+function Xy({ run: e, meta: t, children: n, footer: r, followups: i }) {
return /* @__PURE__ */ (0, z.jsxs)("li", {
"data-status": e.status,
"data-task-key": e.task_key,
@@ -26404,7 +26404,7 @@ function sb({ run: e, meta: t, children: n, footer: r, followups: i }) {
children: [/* @__PURE__ */ (0, z.jsx)("strong", {
className: "min-w-0 break-words text-title-1-medium text-text-primary",
children: e.task_label
- }), /* @__PURE__ */ (0, z.jsx)(ob, { status: e.status })]
+ }), /* @__PURE__ */ (0, z.jsx)(Yy, { status: e.status })]
}),
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-caption-1-regular text-text-secondary",
@@ -26413,7 +26413,7 @@ function sb({ run: e, meta: t, children: n, footer: r, followups: i }) {
n
]
}),
- i?.length ? /* @__PURE__ */ (0, z.jsx)(pne, { rows: i }) : null,
+ i?.length ? /* @__PURE__ */ (0, z.jsx)(wne, { rows: i }) : null,
r ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "flex min-h-14 flex-col justify-center rounded-b-2xl border-t border-separator-border bg-card-footer px-5 py-3",
children: /* @__PURE__ */ (0, z.jsx)("p", {
@@ -26424,9 +26424,9 @@ function sb({ run: e, meta: t, children: n, footer: r, followups: i }) {
]
});
}
-function mne({ run: e, followups: t }) {
- let n = e.progress_total || 0, r = e.progress_current || 0, i = e.progress_label || "正在进行", a = Yy(e.elapsed_seconds), o = [By[e.trigger] || e.trigger, a && `已跑 ${a}`].filter(Boolean).join(" · ");
- return /* @__PURE__ */ (0, z.jsx)(sb, {
+function Tne({ run: e, followups: t }) {
+ let n = e.progress_total || 0, r = e.progress_current || 0, i = e.progress_label || "正在进行", a = Uy(e.elapsed_seconds), o = [Vy[e.trigger] || e.trigger, a && `已跑 ${a}`].filter(Boolean).join(" · ");
+ return /* @__PURE__ */ (0, z.jsx)(Xy, {
run: e,
meta: o,
followups: t,
@@ -26450,17 +26450,17 @@ function mne({ run: e, followups: t }) {
}) : /* @__PURE__ */ (0, z.jsx)(ea, { label: i })
});
}
-function cb({ run: e, followups: t, runs: n }) {
- let r = Qy(e.result_summary), i = Yy(e.elapsed_seconds), a = n && n.length > 1 ? n[n.length - 1] : void 0, o = (a ? [
- By[e.trigger] || e.trigger,
+function Zy({ run: e, followups: t, runs: n }) {
+ let r = Gy(e.result_summary), i = Uy(e.elapsed_seconds), a = n && n.length > 1 ? n[n.length - 1] : void 0, o = (a ? [
+ Vy[e.trigger] || e.trigger,
`近 ${n.length} 轮`,
- `${Xy(a.finished_at)} – ${Xy(e.finished_at)}`
+ `${Wy(a.finished_at)} – ${Wy(e.finished_at)}`
] : [
- By[e.trigger] || e.trigger,
- Xy(e.finished_at),
+ Vy[e.trigger] || e.trigger,
+ Wy(e.finished_at),
i && `用时 ${i}`
]).filter(Boolean).join(" · ");
- return /* @__PURE__ */ (0, z.jsx)(sb, {
+ return /* @__PURE__ */ (0, z.jsx)(Xy, {
run: e,
meta: o,
footer: e.error,
@@ -26471,7 +26471,7 @@ function cb({ run: e, followups: t, runs: n }) {
}) : null
});
}
-function lb({ title: e, children: t }) {
+function Qy({ title: e, children: t }) {
let n = (0, R.useId)();
return /* @__PURE__ */ (0, z.jsxs)("section", {
"aria-labelledby": n,
@@ -26483,40 +26483,40 @@ function lb({ title: e, children: t }) {
}), t]
});
}
-function ub({ live: e = !1, children: t }) {
+function $y({ live: e = !1, children: t }) {
return /* @__PURE__ */ (0, z.jsx)("ul", {
"aria-live": e ? "polite" : void 0,
className: "flex min-w-0 flex-col gap-3",
children: t
});
}
-function hne({ prefill: e }) {
+function Ene({ prefill: e }) {
let t = $n({
- queryKey: Ny,
- queryFn: ({ signal: e }) => Ry(e),
- refetchInterval: (e) => Ly(e.state.data)
+ queryKey: Ry,
+ queryFn: ({ signal: e }) => By(e),
+ refetchInterval: (e) => ine(e.state.data)
}), n = t.data, r = n?.finished, [i, a] = (0, R.useState)([]), [o, s] = (0, R.useState)(!1), [c, l] = (0, R.useState)(r);
- r !== c && (l(r), i.length && c && a(Py(i, c)));
+ r !== c && (l(r), i.length && c && a(zy(i, c)));
let u = er({
- mutationFn: ({ oldest: e }) => one(e),
+ mutationFn: ({ oldest: e }) => tne(e),
onSuccess: (e, { shown: t }) => {
- a((n) => Py(n, t, e.finished || [])), s(!!e.finished_has_more);
+ a((n) => zy(n, t, e.finished || [])), s(!!e.finished_has_more);
}
}), d = t.error ? U(t.error) : "";
if (!n) return /* @__PURE__ */ (0, z.jsx)(ta, { children: /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
children: d || "读取任务中心失败"
}) });
- let f = Py(n.finished || [], i), p = [
+ let f = zy(n.finished || [], i), p = [
...n.running || [],
...n.skipped || [],
...f
- ], m = Wy(p), h = new Set(p.map((e) => e.id)), g = (e) => e.filter((e) => !(e.followup_key && e.parent_run_id != null && h.has(e.parent_run_id))), _ = g(f), v = _[_.length - 1], y = !!v && (i.length ? o : !!n.finished_has_more), b = () => {
+ ], m = lne(p), h = new Set(p.map((e) => e.id)), g = (e) => e.filter((e) => !(e.followup_key && e.parent_run_id != null && h.has(e.parent_run_id))), _ = g(f), v = _[_.length - 1], y = !!v && (i.length ? o : !!n.finished_has_more), b = () => {
!u.isPending && v && u.mutate({
oldest: v,
shown: f
});
- }, x = _.filter((e) => m.get(e.id)?.some(qy)), S = g(n.running || []), C = g(n.skipped || []), w = _.filter((e) => !x.includes(e) && !C.some((t) => t.id === e.id)), T = Gy(w, (e) => Ky(e) && !m.get(e.id)?.length), E = !S.length && !x.length && !C.length && !w.length;
+ }, x = _.filter((e) => m.get(e.id)?.some(Hy)), S = g(n.running || []), C = g(n.skipped || []), w = _.filter((e) => !x.includes(e) && !C.some((t) => t.id === e.id)), T = une(w, (e) => dne(e) && !m.get(e.id)?.length), E = !S.length && !x.length && !C.length && !w.length;
return /* @__PURE__ */ (0, z.jsxs)(ta, { children: [
d ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
@@ -26532,14 +26532,14 @@ function hne({ prefill: e }) {
title: "还没有任务记录",
children: "扫描、追更检查、批量操作和命令行批处理跑起来之后,这里会显示它们的进度与结果。"
}) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
- /* @__PURE__ */ (0, z.jsx)(lb, {
+ /* @__PURE__ */ (0, z.jsx)(Qy, {
title: "正在进行",
- children: S.length || x.length ? /* @__PURE__ */ (0, z.jsxs)(ub, {
+ children: S.length || x.length ? /* @__PURE__ */ (0, z.jsxs)($y, {
live: !0,
- children: [S.map((e) => /* @__PURE__ */ (0, z.jsx)(mne, {
+ children: [S.map((e) => /* @__PURE__ */ (0, z.jsx)(Tne, {
run: e,
followups: m.get(e.id)
- }, e.id)), x.map((e) => /* @__PURE__ */ (0, z.jsx)(cb, {
+ }, e.id)), x.map((e) => /* @__PURE__ */ (0, z.jsx)(Zy, {
run: e,
followups: m.get(e.id)
}, e.id))]
@@ -26548,17 +26548,17 @@ function hne({ prefill: e }) {
children: "没有任务在跑。"
})
}),
- C.length ? /* @__PURE__ */ (0, z.jsx)(lb, {
+ C.length ? /* @__PURE__ */ (0, z.jsx)(Qy, {
title: "被挡下的",
- children: /* @__PURE__ */ (0, z.jsx)(ub, { children: C.map((e) => /* @__PURE__ */ (0, z.jsx)(cb, {
+ children: /* @__PURE__ */ (0, z.jsx)($y, { children: C.map((e) => /* @__PURE__ */ (0, z.jsx)(Zy, {
run: e,
followups: m.get(e.id)
}, e.id)) })
}) : null,
- w.length || y ? /* @__PURE__ */ (0, z.jsxs)(lb, {
+ w.length || y ? /* @__PURE__ */ (0, z.jsxs)(Qy, {
title: "最近完成",
children: [
- w.length ? /* @__PURE__ */ (0, z.jsx)(ub, { children: T.map(({ run: e, runs: t }) => /* @__PURE__ */ (0, z.jsx)(cb, {
+ w.length ? /* @__PURE__ */ (0, z.jsx)($y, { children: T.map(({ run: e, runs: t }) => /* @__PURE__ */ (0, z.jsx)(Zy, {
run: e,
runs: t,
followups: m.get(e.id)
@@ -26579,36 +26579,36 @@ function hne({ prefill: e }) {
]
}) : null
] }),
- /* @__PURE__ */ (0, z.jsx)(lb, {
+ /* @__PURE__ */ (0, z.jsx)(Qy, {
title: "云下载",
- children: /* @__PURE__ */ (0, z.jsx)(cne, { prefill: e })
+ children: /* @__PURE__ */ (0, z.jsx)(yne, { prefill: e })
})
] });
}
//#endregion
//#region src/jav-artwork.ts
-function db(e) {
+function eb(e) {
return e === "thumbnail" ? "thumbnail" : "cover";
}
-function fb(e, t) {
- return e.is_jav && e.code && e.has_cover && (db(t) === "cover" || !e.has_thumb) ? "cover" : e.has_thumb ? "thumbnail" : "";
+function tb(e, t) {
+ return e.is_jav && e.code && e.has_cover && (eb(t) === "cover" || !e.has_thumb) ? "cover" : e.has_thumb ? "thumbnail" : "";
}
-function pb(e, t) {
+function nb(e, t) {
let n = new URLSearchParams(Object.entries(e).filter(([, e]) => e));
return t && n.set("exclude_vertical", "1"), n.toString();
}
-var gne = (e, t) => [
+var Dne = (e, t) => [
"catalog-grid",
"catalog",
e,
t
-], _ne = (e, t) => [
+], One = (e, t) => [
"catalog-grid",
"entity",
e,
t
];
-async function vne(e, t, n, r, i) {
+async function kne(e, t, n, r, i) {
let a = new URLSearchParams(e);
a.set("limit", String(n)), a.set("offset", String(t)), t && a.set("count", "0");
let o = await W(`/api/items?${a}`, i), s = {
@@ -26618,25 +26618,25 @@ async function vne(e, t, n, r, i) {
};
return !t && !s.items.length && !r && (s.libraryEmpty = (await W("/api/items?limit=1&thumb=0", i)).total === 0), s;
}
-var yne = (e) => (t) => (t.offset === 0 ? t.items.length < (t.total || 0) : t.has_more) ? t.offset + e : void 0, bne = (e, t) => {
+var Ane = (e) => (t) => (t.offset === 0 ? t.items.length < (t.total || 0) : t.has_more) ? t.offset + e : void 0, jne = (e, t) => {
let n = t.reduce((e, t) => e + t.items.length, 0);
return (e.has_more == null ? n < (e.total || 0) : e.has_more) ? n : void 0;
};
-function mb(e) {
- let t = pb(e.filters || {}, !!e.excludeVertical), n = e.batchSize || 60, r = e.filters?.state === "trash";
+function rb(e) {
+ let t = nb(e.filters || {}, !!e.excludeVertical), n = e.batchSize || 60, r = e.filters?.state === "trash";
return {
- queryKey: gne(t, e.revision || 0),
+ queryKey: Dne(t, e.revision || 0),
queryFn: async ({ pageParam: i, signal: a }) => {
- let o = await vne(t, i, n, r, a);
+ let o = await kne(t, i, n, r, a);
return e.cache(o.items), o;
},
initialPageParam: 0,
- getNextPageParam: yne(n)
+ getNextPageParam: Ane(n)
};
}
-function xne(e) {
+function Mne(e) {
return {
- queryKey: _ne(e.entityKey || "", e.revision || 0),
+ queryKey: One(e.entityKey || "", e.revision || 0),
queryFn: async ({ pageParam: t, signal: n }) => {
if (!e.fetchPage) return {
items: [],
@@ -26651,12 +26651,12 @@ function xne(e) {
};
},
initialPageParam: 0,
- getNextPageParam: bne
+ getNextPageParam: jne
};
}
-async function Sne(e, t) {
+async function Nne(e, t) {
if (e.mode !== "catalog") return;
- let n = mb(e);
+ let n = rb(e);
await X.fetchInfiniteQuery({
...n,
queryFn: ({ pageParam: e }) => n.queryFn({
@@ -26665,7 +26665,7 @@ async function Sne(e, t) {
})
});
}
-function Cne(e, t, n) {
+function Pne(e, t, n) {
return n ? e.filter((e) => {
let n = e.part_group?.key;
if (n) {
@@ -26680,28 +26680,28 @@ function Cne(e, t, n) {
return !0;
}) : [...e];
}
-var hb = (e, t) => !!e && !!fb(e, t);
-function wne(e, t) {
+var ib = (e, t) => !!e && !!tb(e, t);
+function Fne(e, t) {
let n = (e.performers || [])[0];
return (e.is_jav && n ? n : e.creator) || n || e.studio || e.code || t((e.tags || [])[0] || "") || "为你推荐";
}
-function Tne(e, t) {
- let n = (e) => hb(e, t) && !!(e.creator || (e.performers || []).length || e.studio);
- return e.slice(15).find(n) || e.slice(8).find(n) || e.slice(8).find((e) => hb(e, t)) || e[e.length - 1];
+function Ine(e, t) {
+ let n = (e) => ib(e, t) && !!(e.creator || (e.performers || []).length || e.studio);
+ return e.slice(15).find(n) || e.slice(8).find(n) || e.slice(8).find((e) => ib(e, t)) || e[e.length - 1];
}
-function Ene(e, { collapse: t, mix: n, javImage: r }) {
+function Lne(e, { collapse: t, mix: n, javImage: r }) {
let i = {
parts: /* @__PURE__ */ new Set(),
editions: /* @__PURE__ */ new Set()
}, a = /* @__PURE__ */ new Set(), o = [], s = [];
for (let c of e) {
s.push(o.length);
- let e = Cne(c.items.filter((e) => !a.has(e.id) && !!a.add(e.id)), i, t), l = e.map((e) => ({
+ let e = Pne(c.items.filter((e) => !a.has(e.id) && !!a.add(e.id)), i, t), l = e.map((e) => ({
kind: "card",
item: e
}));
if (n && e.length >= 8) {
- let t = Tne(e, r);
+ let t = Ine(e, r);
t && l.splice(7, 0, {
kind: "mix",
seed: t
@@ -26714,16 +26714,16 @@ function Ene(e, { collapse: t, mix: n, javImage: r }) {
pageStarts: s
};
}
-function Dne(e, t, n) {
+function Rne(e, t, n) {
let r = Math.max(1, n), i = [];
for (let n = Math.max(r, Math.ceil(Math.max(0, t) / r) * r); n < e; n += r) i.push(n);
return i;
}
-function One(e, t) {
+function zne(e, t) {
let n = new URLSearchParams(Object.entries(e).filter(([, e]) => e));
return n.set("orient", "竖屏"), n.set("limit", "18"), n.set("offset", String(t)), n.toString();
}
-function kne(e, t) {
+function Bne(e, t) {
let n = [...t].sort((e, t) => e.at - t.at), r = [], i = 0;
for (let t of n) r.push({
start: i,
@@ -26736,7 +26736,7 @@ function kne(e, t) {
strip: null
}), r;
}
-function gb(e, t) {
+function ab(e, t) {
X.setQueriesData({
queryKey: ["catalog-grid"],
predicate: (e) => Array.isArray(e.state.data?.pages)
@@ -26753,7 +26753,7 @@ function gb(e, t) {
}
//#endregion
//#region src/react/components/grid-reveal.tsx
-function _b(e, t) {
+function ob(e, t) {
let [n, r] = (0, R.useState)(e ? "skeleton" : "none"), [i] = (0, R.useState)(() => e ? t() : ""), a = (0, R.useRef)(null);
return (0, R.useLayoutEffect)(() => {
a.current && w(a.current);
@@ -26779,7 +26779,7 @@ function _b(e, t) {
fading: n === "fade"
};
}
-function vb({ message: e, onRetry: t }) {
+function sb({ message: e, onRetry: t }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-media-error": "",
onClick: (e) => {
@@ -26793,21 +26793,21 @@ function vb({ message: e, onRetry: t }) {
}
//#endregion
//#region src/react/catalog-grid/artwork.ts
-var yb = {
+var cb = {
kind: "",
html: ""
};
-function bb(e, t, n, r, a) {
- let o = fb(e, r);
- if (!o) return yb;
+function lb(e, t, n, r, a) {
+ let o = tb(e, r);
+ if (!o) return cb;
let s = e.has_cover && e.code ? `/cover?code=${encodeURIComponent(e.code)}&thumb=1` : "", c = e.has_thumb || e.has_local_poster ? `/poster?id=${e.id}&c=4` : "", l = a(e, t, n), u = (l.match(/ data-(?:c[xy]|posterbox)="[^"]*"/g) || []).join(""), d = o === "cover" ? l : `<img class="poster" src="${c}" alt="" loading="${n ? "eager" : "lazy"}"${u}>`;
return {
kind: o === "cover" ? "cover" : "thumb",
html: d.replace("<img ", `<img data-jav-image="${e.id}" data-jav-cover="${i(s)}" data-jav-thumb="${i(c)}" data-jav-image-layout="${t}" `)
};
}
-function xb(e, t, n, r, a) {
- if (e.is_jav) return bb(e, t, n, r, a);
+function ub(e, t, n, r, a) {
+ if (e.is_jav) return lb(e, t, n, r, a);
let o = n ? "eager" : "lazy";
return e.follow_thumb_url ? {
kind: "thumb",
@@ -26815,11 +26815,11 @@ function xb(e, t, n, r, a) {
} : e.has_thumb || e.has_local_poster ? {
kind: "thumb",
html: `<img class="poster" src="/poster?id=${e.id}&c=4" alt="" loading="${o}">`
- } : yb;
+ } : cb;
}
//#endregion
//#region src/react/components/art-slot.tsx
-function Sb({ artwork: e, identity: t = e.html, relayout: n }) {
+function db({ artwork: e, identity: t = e.html, relayout: n }) {
let [r, i] = (0, R.useState)({
identity: t,
artwork: e
@@ -26839,25 +26839,25 @@ function Sb({ artwork: e, identity: t = e.html, relayout: n }) {
}
//#endregion
//#region src/react/components/media-card.tsx
-var Ane = .75, jne = 9 / 16;
-function Cb({ name: e }) {
+var fb = .75, pb = 9 / 16;
+function mb({ name: e }) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
"aria-hidden": "true",
children: /* @__PURE__ */ (0, z.jsx)("use", { href: `#i-${e}` })
});
}
-var Mne = {
+var hb = {
image: "图片",
audio: "音频",
archive: "压缩包",
other: "其它文件"
-}, Nne = (e) => e.is_jav ? "女优" : "艺人";
-function wb(e, t, n) {
- return t === "short" || n.portrait ? jne : n.active && n.size === "big" ? Ane : 16 / 9;
+}, gb = (e) => e.is_jav ? "女优" : "艺人";
+function _b(e, t, n) {
+ return t === "short" || n.portrait ? pb : n.active && n.size === "big" ? fb : 16 / 9;
}
-function Pne(e, t) {
- let n = e.performers || [], r = e.performer_entities || [], i = n[0] || "", a = e.is_jav && i ? "" : e.creator || "", o = a ? "creator" : i ? "performer" : "", s = a || i || "未归属", c = n.length > 1 && !a, l = Nne(e);
+function vb(e, t) {
+ let n = e.performers || [], r = e.performer_entities || [], i = n[0] || "", a = e.is_jav && i ? "" : e.creator || "", o = a ? "creator" : i ? "performer" : "", s = a || i || "未归属", c = n.length > 1 && !a, l = gb(e);
return {
avatar: c ? /* @__PURE__ */ (0, z.jsx)("div", {
"data-media-avatars": "",
@@ -26903,7 +26903,7 @@ function Pne(e, t) {
})
};
}
-function Fne() {
+function yb() {
return /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
"data-media-preview": "",
@@ -26922,7 +26922,7 @@ function Fne() {
})]
});
}
-function Ine({ item: e, actions: t }) {
+function bb({ item: e, actions: t }) {
let [n, r] = (0, R.useState)(null), [i, a] = (0, R.useState)(!1), o = n?.id === e.id ? n.on : !!e.watch_later;
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-media-later": "",
@@ -26940,15 +26940,15 @@ function Ine({ item: e, actions: t }) {
},
"aria-busy": i || void 0,
"aria-disabled": i || void 0,
- children: /* @__PURE__ */ (0, z.jsx)(Cb, { name: o ? "check" : "bookmark-plus" })
+ children: /* @__PURE__ */ (0, z.jsx)(mb, { name: o ? "check" : "bookmark-plus" })
})
});
}
-function Tb(e, t) {
+function xb(e, t) {
let n = e?.querySelector("video.hv");
!n || !Number.isFinite(n.duration) || (n._hop &&= (clearInterval(n._hop), null), n.currentTime = Math.max(0, Math.min(n.duration, n.currentTime + t)));
}
-function Lne({ item: e, variant: t, layout: n, selected: r, selectMode: i, seekSeconds: a, helpers: c, actions: l, onOpen: u }) {
+function Sb({ item: e, variant: t, layout: n, selected: r, selectMode: i, seekSeconds: a, helpers: c, actions: l, onOpen: u }) {
let d = (0, R.useRef)(null), f = (0, R.useRef)({
item: e,
helpers: c
@@ -26960,7 +26960,7 @@ function Lne({ item: e, variant: t, layout: n, selected: r, selectMode: i, seekS
let p = (0, R.useCallback)((e) => {
let { item: t, helpers: n } = f.current;
d.current && d.current !== e && n.releaseHover(d.current), d.current = e, e && (!t.medium || t.medium === "video") && n.wireHover(e, t);
- }, []), m = e.part_group || null, h = e.edition_group || null, g = !!(m || h), _ = n.active && e.is_jav ? n.size : "small", v = xb(e, _, !1, n.javImage, c.coverHtml), y = _ === "small" ? v.html : xb(e, "small", !1, n.javImage, c.coverHtml).html, b = m?.title || e.name || "", x = c.displayName(e, b), S = m?.total_size ?? e.size, C = m?.total_duration ?? e.duration, w = !m && Number(e.play_seconds) > 0 && Number(e.duration) > 0 ? Math.min(Number(e.play_seconds) / Number(e.duration), 1) : 0, { avatar: T, who: E } = Pne(e, c), D = (e.follow_tags || e.tags || []).slice(0, 3), O = [
+ }, []), m = e.part_group || null, h = e.edition_group || null, g = !!(m || h), _ = n.active && e.is_jav ? n.size : "small", v = ub(e, _, !1, n.javImage, c.coverHtml), y = _ === "small" ? v.html : ub(e, "small", !1, n.javImage, c.coverHtml).html, b = m?.title || e.name || "", x = c.displayName(e, b), S = m?.total_size ?? e.size, C = m?.total_duration ?? e.duration, w = !m && Number(e.play_seconds) > 0 && Number(e.duration) > 0 ? Math.min(Number(e.play_seconds) / Number(e.duration), 1) : 0, { avatar: T, who: E } = vb(e, c), D = (e.follow_tags || e.tags || []).slice(0, 3), O = [
e.feedback === "dislike" && "dislike",
e.feedback === "seen" && "seen",
e.disposal === "trash" && "dispose",
@@ -26994,9 +26994,9 @@ function Lne({ item: e, variant: t, layout: n, selected: r, selectMode: i, seekS
u(e, r);
}, A = /* @__PURE__ */ (0, z.jsxs)("div", {
"data-media-pic": "",
- style: { "--card-ratio": String(wb(e, t, n)) },
+ style: { "--card-ratio": String(_b(e, t, n)) },
children: [
- v.html ? /* @__PURE__ */ (0, z.jsx)(Sb, {
+ v.html ? /* @__PURE__ */ (0, z.jsx)(db, {
artwork: v,
identity: y,
relayout: (e) => c.relayoutArt(e, _)
@@ -27010,11 +27010,11 @@ function Lne({ item: e, variant: t, layout: n, selected: r, selectMode: i, seekS
}),
/* @__PURE__ */ (0, z.jsx)("span", {
"data-media-check": "",
- children: /* @__PURE__ */ (0, z.jsx)(Cb, { name: "check" })
+ children: /* @__PURE__ */ (0, z.jsx)(mb, { name: "check" })
}),
/* @__PURE__ */ (0, z.jsxs)("span", {
"data-media-trash-mark": "",
- children: [/* @__PURE__ */ (0, z.jsx)(Cb, { name: "trash" }), /* @__PURE__ */ (0, z.jsx)("b", { children: "回收站" })]
+ children: [/* @__PURE__ */ (0, z.jsx)(mb, { name: "trash" }), /* @__PURE__ */ (0, z.jsx)("b", { children: "回收站" })]
}),
m ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-media-group": "",
@@ -27041,8 +27041,8 @@ function Lne({ item: e, variant: t, layout: n, selected: r, selectMode: i, seekS
"data-media-scrub": "",
children: /* @__PURE__ */ (0, z.jsx)("i", { style: { "--media-fill": `${Math.round(e.leave_ratio * 100)}%` } })
}),
- /* @__PURE__ */ (0, z.jsx)(Fne, {}),
- /* @__PURE__ */ (0, z.jsx)(Ine, {
+ /* @__PURE__ */ (0, z.jsx)(yb, {}),
+ /* @__PURE__ */ (0, z.jsx)(bb, {
item: e,
actions: l
}),
@@ -27052,27 +27052,27 @@ function Lne({ item: e, variant: t, layout: n, selected: r, selectMode: i, seekS
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
onClick: (e) => {
- e.stopPropagation(), Tb(d.current, -a);
+ e.stopPropagation(), xb(d.current, -a);
},
title: `后退 ${a} 秒`,
"aria-label": `后退 ${a} 秒`,
- children: /* @__PURE__ */ (0, z.jsx)(Cb, { name: "rotate-ccw" })
+ children: /* @__PURE__ */ (0, z.jsx)(mb, { name: "rotate-ccw" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
onClick: (e) => {
- e.stopPropagation(), Tb(d.current, a);
+ e.stopPropagation(), xb(d.current, a);
},
title: `前进 ${a} 秒`,
"aria-label": `前进 ${a} 秒`,
- children: /* @__PURE__ */ (0, z.jsx)(Cb, { name: "rotate-cw" })
+ children: /* @__PURE__ */ (0, z.jsx)(mb, { name: "rotate-cw" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-open": "",
title: "打开详情",
"aria-label": "打开详情",
- children: /* @__PURE__ */ (0, z.jsx)(Cb, { name: "expand" })
+ children: /* @__PURE__ */ (0, z.jsx)(mb, { name: "expand" })
})
]
})
@@ -27148,8 +27148,8 @@ function Lne({ item: e, variant: t, layout: n, selected: r, selectMode: i, seekS
]
});
}
-function Rne({ item: e, selected: t, selectMode: n, helpers: r, actions: a, onOpen: o }) {
- let c = (0, R.useRef)(null), [l, u] = (0, R.useState)(!1), d = e.medium === "image" && e.location !== "online", f = String(e.name || ""), p = f.toLowerCase().endsWith(".url") ? "网址快捷方式" : Mne[e.medium || ""] || "其它文件", m = d ? "pics" : p === "网址快捷方式" ? "globe" : "hard-drive", h = e.disposal === "trash" ? "restore" : "dispose", g = h === "restore" ? "还原" : "移入回收站", _ = (t) => {
+function Cb({ item: e, selected: t, selectMode: n, helpers: r, actions: a, onOpen: o }) {
+ let c = (0, R.useRef)(null), [l, u] = (0, R.useState)(!1), d = e.medium === "image" && e.location !== "online", f = String(e.name || ""), p = f.toLowerCase().endsWith(".url") ? "网址快捷方式" : hb[e.medium || ""] || "其它文件", m = d ? "pics" : p === "网址快捷方式" ? "globe" : "hard-drive", h = e.disposal === "trash" ? "restore" : "dispose", g = h === "restore" ? "还原" : "移入回收站", _ = (t) => {
t.preventDefault(), t.stopPropagation(), !l && (u(!0), a.resourceOperation(e, h).catch(() => {}).finally(() => u(!1)));
}, v = (t) => {
if (c.current) {
@@ -27175,7 +27175,7 @@ function Rne({ item: e, selected: t, selectMode: n, helpers: r, actions: a, onOp
children: [
/* @__PURE__ */ (0, z.jsxs)("span", {
"data-media-glyph": "",
- children: [/* @__PURE__ */ (0, z.jsx)(Cb, { name: m }), /* @__PURE__ */ (0, z.jsx)("b", { children: p })]
+ children: [/* @__PURE__ */ (0, z.jsx)(mb, { name: m }), /* @__PURE__ */ (0, z.jsx)("b", { children: p })]
}),
d ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-media-art": "thumb",
@@ -27187,11 +27187,11 @@ function Rne({ item: e, selected: t, selectMode: n, helpers: r, actions: a, onOp
}),
/* @__PURE__ */ (0, z.jsx)("span", {
"data-media-check": "",
- children: /* @__PURE__ */ (0, z.jsx)(Cb, { name: "check" })
+ children: /* @__PURE__ */ (0, z.jsx)(mb, { name: "check" })
}),
/* @__PURE__ */ (0, z.jsxs)("span", {
"data-media-trash-mark": "",
- children: [/* @__PURE__ */ (0, z.jsx)(Cb, { name: "trash" }), /* @__PURE__ */ (0, z.jsx)("b", { children: "回收站" })]
+ children: [/* @__PURE__ */ (0, z.jsx)(mb, { name: "trash" }), /* @__PURE__ */ (0, z.jsx)("b", { children: "回收站" })]
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -27201,7 +27201,7 @@ function Rne({ item: e, selected: t, selectMode: n, helpers: r, actions: a, onOp
onClick: _,
"aria-busy": l || void 0,
"aria-disabled": l || void 0,
- children: l ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("span", { dangerouslySetInnerHTML: { __html: ie(h === "restore" ? "正在还原" : "正在移入回收站") } }), /* @__PURE__ */ (0, z.jsx)("span", { children: y })] }) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(Cb, { name: h === "restore" ? "rotate-ccw" : "trash" }), /* @__PURE__ */ (0, z.jsx)("span", { children: g })] })
+ children: l ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("span", { dangerouslySetInnerHTML: { __html: ie(h === "restore" ? "正在还原" : "正在移入回收站") } }), /* @__PURE__ */ (0, z.jsx)("span", { children: y })] }) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(mb, { name: h === "restore" ? "rotate-ccw" : "trash" }), /* @__PURE__ */ (0, z.jsx)("span", { children: g })] })
})
]
}), /* @__PURE__ */ (0, z.jsxs)("div", {
@@ -27210,7 +27210,7 @@ function Rne({ item: e, selected: t, selectMode: n, helpers: r, actions: a, onOp
"data-media-avatar": "",
"data-media-kind-glyph": "",
"aria-hidden": "true",
- children: /* @__PURE__ */ (0, z.jsx)(Cb, { name: m })
+ children: /* @__PURE__ */ (0, z.jsx)(mb, { name: m })
}), /* @__PURE__ */ (0, z.jsxs)("div", {
"data-media-text": "",
children: [/* @__PURE__ */ (0, z.jsx)("span", {
@@ -27239,14 +27239,14 @@ function Rne({ item: e, selected: t, selectMode: n, helpers: r, actions: a, onOp
})]
});
}
-function zne(e) {
- return e.variant === "resource" ? /* @__PURE__ */ (0, z.jsx)(Rne, { ...e }) : /* @__PURE__ */ (0, z.jsx)(Lne, { ...e });
+function wb(e) {
+ return e.variant === "resource" ? /* @__PURE__ */ (0, z.jsx)(Cb, { ...e }) : /* @__PURE__ */ (0, z.jsx)(Sb, { ...e });
}
-var Eb = (0, R.memo)(zne), Bne = { "text-aa": 1.435 }, Db = /* @__PURE__ */ new Map();
+var Tb = (0, R.memo)(wb), Eb = { "text-aa": 1.435 }, Db = /* @__PURE__ */ new Map();
function Ob(e) {
let t = Db.get(e);
if (t) return t;
- let n = Bne[e], r = n ? ({ className: t }) => /* @__PURE__ */ (0, z.jsx)("svg", {
+ let n = Eb[e], r = n ? ({ className: t }) => /* @__PURE__ */ (0, z.jsx)("svg", {
"aria-hidden": !0,
viewBox: `0 0 ${(24 * n).toFixed(2)} 24`,
className: `shrink-0 fill-current ${t ?? "h-4 w-auto"}`,
@@ -27264,14 +27264,14 @@ function Ob(e) {
}
//#endregion
//#region src/react/components/use-stack-flip.ts
-var Vne = 1100, Hne = 340, Une = 5e3;
-function Wne(e, t, n) {
+var kb = 1100, Ab = 340, jb = 5e3;
+function Mb(e, t, n) {
return new Promise((r) => {
let i = new Image();
n && (i.referrerPolicy = n);
let a = !1, o = (e) => {
a || (a = !0, clearTimeout(c), i.onload = null, i.onerror = null, t.cancels.delete(s), r(e));
- }, s = () => o(!1), c = setTimeout(s, Une);
+ }, s = () => o(!1), c = setTimeout(s, jb);
t.cancels.add(s), i.onerror = s, i.onload = () => {
if (!i.naturalWidth) {
o(!1);
@@ -27281,7 +27281,7 @@ function Wne(e, t, n) {
}, i.src = e;
});
}
-function kb({ load: e, canFlip: t, referrerPolicy: n }) {
+function Nb({ load: e, canFlip: t, referrerPolicy: n }) {
let [r, i] = (0, R.useState)([]), [a, o] = (0, R.useState)(0), [s, c] = (0, R.useState)(null), l = (0, R.useRef)({
live: !1,
generation: 0,
@@ -27323,11 +27323,11 @@ function kb({ load: e, canFlip: t, referrerPolicy: n }) {
return;
}
if (!r() || !u.current.canFlip() || a.length < 2) return;
- let s = await Promise.all(a.map((t) => Wne(t, e, n)));
+ let s = await Promise.all(a.map((t) => Mb(t, e, n)));
if (!r() || !u.current.canFlip()) return;
let d = a.filter((e, t) => s[t]);
d.length < 2 || (e.count = d.length, e.at = 0, i(d), o(0), c(null), f(420, () => {
- p(), e.cycle = setInterval(p, Vne);
+ p(), e.cycle = setInterval(p, kb);
}));
};
return (0, R.useEffect)(() => d, [d]), {
@@ -27336,7 +27336,7 @@ function kb({ load: e, canFlip: t, referrerPolicy: n }) {
leaving: s,
onPointerEnter: () => {
let e = l.current;
- e.armed !== null && (clearTimeout(e.armed), e.timers.delete(e.armed)), e.armed = f(Hne, () => {
+ e.armed !== null && (clearTimeout(e.armed), e.timers.delete(e.armed)), e.armed = f(Ab, () => {
e.armed = null, m();
});
},
@@ -27347,8 +27347,8 @@ function kb({ load: e, canFlip: t, referrerPolicy: n }) {
}
//#endregion
//#region src/react/components/mix-card.tsx
-var Ab = Ob("play");
-function Gne({ src: e }) {
+var Pb = Ob("play");
+function Fb({ src: e }) {
let [t, n] = (0, R.useState)(!1);
return t ? null : /* @__PURE__ */ (0, z.jsx)("img", {
"data-mix-poster": "",
@@ -27359,8 +27359,8 @@ function Gne({ src: e }) {
className: "absolute inset-0 block size-full object-contain"
});
}
-var jb = "relative inline-grid size-9.5 flex-none place-items-center overflow-hidden rounded-full bg-background-secondary-default text-body-2-regular text-text-secondary [&_img]:absolute [&_img]:inset-0 [&_img]:block [&_img]:size-full [&_img]:object-cover";
-function Kne({ faces: e, fallback: t, faceAvatar: n, onOpenEntity: r }) {
+var Ib = "relative inline-grid size-9.5 flex-none place-items-center overflow-hidden rounded-full bg-background-secondary-default text-body-2-regular text-text-secondary [&_img]:absolute [&_img]:inset-0 [&_img]:block [&_img]:size-full [&_img]:object-cover";
+function Vne({ faces: e, fallback: t, faceAvatar: n, onOpenEntity: r }) {
return e.length ? /* @__PURE__ */ (0, z.jsx)("div", {
"data-mix-avatars": "",
children: e.slice(0, 5).map((e) => /* @__PURE__ */ (0, z.jsx)("button", {
@@ -27368,18 +27368,18 @@ function Kne({ faces: e, fallback: t, faceAvatar: n, onOpenEntity: r }) {
title: `打开资料页:${e.name}`,
"aria-label": `打开资料页:${e.name}`,
onClick: () => r(e.kind, e.name),
- className: `${jb} cursor-pointer outline-none`,
+ className: `${Ib} cursor-pointer outline-none`,
dangerouslySetInnerHTML: { __html: n(e) }
}, `${e.kind}:${e.id}`))
}) : /* @__PURE__ */ (0, z.jsx)("span", {
"data-mix-initial": "",
"aria-hidden": !0,
- className: `${jb} mt-0.5`,
+ className: `${Ib} mt-0.5`,
children: t
});
}
-function Mb({ name: e, caption: t, count: n, poster: r, flipImages: i, canFlip: a, faces: o, faceAvatar: s, onOpenEntity: c, onOpen: l, openLabel: u, menu: d, ratio: f, artwork: p, artworkIdentity: m, relayoutArt: h, faceHtml: g, badge: _, glyph: v, wholeCard: y, ...b }) {
- let x = kb({
+function Lb({ name: e, caption: t, count: n, poster: r, flipImages: i, canFlip: a, faces: o, faceAvatar: s, onOpenEntity: c, onOpen: l, openLabel: u, menu: d, ratio: f, artwork: p, artworkIdentity: m, relayoutArt: h, faceHtml: g, badge: _, glyph: v, wholeCard: y, ...b }) {
+ let x = Nb({
load: i,
canFlip: a
}), S = (0, R.useRef)(x.onPointerLeave);
@@ -27406,11 +27406,11 @@ function Mb({ name: e, caption: t, count: n, poster: r, flipImages: i, canFlip:
style: f === void 0 ? void 0 : { "--card-ratio": String(f) },
className: "relative z-1 flex aspect-video items-center justify-center overflow-hidden rounded-surface",
children: [
- p?.html ? /* @__PURE__ */ (0, z.jsx)(Sb, {
+ p?.html ? /* @__PURE__ */ (0, z.jsx)(db, {
artwork: p,
identity: m,
relayout: h
- }) : r ? /* @__PURE__ */ (0, z.jsx)(Gne, { src: r }, r) : /* @__PURE__ */ (0, z.jsx)("span", {
+ }) : r ? /* @__PURE__ */ (0, z.jsx)(Fb, { src: r }, r) : /* @__PURE__ */ (0, z.jsx)("span", {
className: "text-caption-1-regular tracking-caps text-text-secondary uppercase",
children: "无预览"
}),
@@ -27440,7 +27440,7 @@ function Mb({ name: e, caption: t, count: n, poster: r, flipImages: i, canFlip:
/* @__PURE__ */ (0, z.jsxs)("span", {
"data-mix-badge": "",
className: "absolute right-2.25 bottom-2.25 z-6 flex min-h-7 items-center gap-1.5 rounded-2lg px-2.25 py-1 text-caption-1-semibold text-text-white",
- children: [/* @__PURE__ */ (0, z.jsx)(Ab, {
+ children: [/* @__PURE__ */ (0, z.jsx)(Pb, {
"aria-hidden": !0,
className: "size-3.75"
}), _ ?? `${n} 个视频`]
@@ -27453,8 +27453,8 @@ function Mb({ name: e, caption: t, count: n, poster: r, flipImages: i, canFlip:
v ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-mix-glyph": "",
"aria-hidden": !0,
- children: /* @__PURE__ */ (0, z.jsx)(Ab, {})
- }) : /* @__PURE__ */ (0, z.jsx)(Kne, {
+ children: /* @__PURE__ */ (0, z.jsx)(Pb, {})
+ }) : /* @__PURE__ */ (0, z.jsx)(Vne, {
faces: o,
fallback: e.slice(0, 1),
faceAvatar: s,
@@ -27479,20 +27479,20 @@ function Mb({ name: e, caption: t, count: n, poster: r, flipImages: i, canFlip:
}
//#endregion
//#region src/react/catalog-grid/catalog-grid-page.tsx
-function Nb(e) {
- if (e.mode === "items") return /* @__PURE__ */ (0, z.jsx)(Jne, { ...e });
- let t = e.mode === "entity" ? `entity:${e.entityKey || ""}:${e.revision}` : `catalog:${pb(e.filters || {}, !!e.excludeVertical)}:${e.batchSize || 60}:${e.revision}`;
- return /* @__PURE__ */ (0, z.jsx)(Yne, { ...e }, t);
+function Rb(e) {
+ if (e.mode === "items") return /* @__PURE__ */ (0, z.jsx)(Une, { ...e });
+ let t = e.mode === "entity" ? `entity:${e.entityKey || ""}:${e.revision}` : `catalog:${nb(e.filters || {}, !!e.excludeVertical)}:${e.batchSize || 60}:${e.revision}`;
+ return /* @__PURE__ */ (0, z.jsx)(Wne, { ...e }, t);
}
-function qne({ name: e }) {
+function Hne({ name: e }) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
"aria-hidden": "true",
children: /* @__PURE__ */ (0, z.jsx)("use", { href: `#i-${e}` })
});
}
-function Jne(e) {
- let { actions: t } = e, n = (0, R.useCallback)((e, n) => t.open(e, n), [t]), r = e.variant === "next" ? "next" : "grid", i = (e.items || []).map((i) => /* @__PURE__ */ (0, z.jsx)(Eb, {
+function Une(e) {
+ let { actions: t } = e, n = (0, R.useCallback)((e, n) => t.open(e, n), [t]), r = e.variant === "next" ? "next" : "grid", i = (e.items || []).map((i) => /* @__PURE__ */ (0, z.jsx)(Tb, {
item: i,
variant: r,
layout: e.layout,
@@ -27512,8 +27512,8 @@ function Jne(e) {
children: i
});
}
-function Yne(e) {
- let { helpers: t, actions: n, layout: r } = e, i = e.mode === "entity", a = !i && e.filters?.state === "trash", o = i ? xne(e) : mb(e), s = i && e.initial ? {
+function Wne(e) {
+ let { helpers: t, actions: n, layout: r } = e, i = e.mode === "entity", a = !i && e.filters?.state === "trash", o = i ? Mne(e) : rb(e), s = i && e.initial ? {
pages: [{
...e.initial,
items: e.initial.items || [],
@@ -27533,7 +27533,7 @@ function Yne(e) {
(0, R.useEffect)(() => {
c.isPending || l.current || (l.current = !0, e.settled?.(e.revision));
}, [c.isPending]);
- let { tiles: u, pageStarts: d } = (0, R.useMemo)(() => Ene(c.data?.pages || [], {
+ let { tiles: u, pageStarts: d } = (0, R.useMemo)(() => Lne(c.data?.pages || [], {
collapse: e.groupCollapse !== !1,
mix: !!e.mix && !a,
javImage: r.javImage
@@ -27543,7 +27543,7 @@ function Yne(e) {
e.mix,
a,
r.javImage
- ]), f = u.reduce((e, t) => e + +(t.kind === "card"), 0), p = Number(c.data?.pages[0]?.total || 0), h = _b(c.isPending, e.skeletonHtml), g = (0, R.useRef)(null), _ = Xne(e, c.data, u, d, g);
+ ]), f = u.reduce((e, t) => e + +(t.kind === "card"), 0), p = Number(c.data?.pages[0]?.total || 0), h = ob(c.isPending, e.skeletonHtml), g = (0, R.useRef)(null), _ = Gne(e, c.data, u, d, g);
(0, R.useLayoutEffect)(() => {
c.data && e.onCount?.(p, f);
}, [
@@ -27554,12 +27554,12 @@ function Yne(e) {
let v = (0, R.useCallback)((e, t) => n.open(e, t), [n]), y = (0, R.useCallback)((e, t) => n.openResource(e, t), [n]), b = (0, R.useCallback)((e) => n.openShort(e), [n]), x = (0, R.useCallback)(async () => {
let e = await c.fetchNextPage({ cancelRefetch: !1 });
if (e.isFetchNextPageError) throw e.error;
- }, [c.fetchNextPage]), S = (i) => i.kind === "mix" ? /* @__PURE__ */ (0, z.jsx)(Qne, {
+ }, [c.fetchNextPage]), S = (i) => i.kind === "mix" ? /* @__PURE__ */ (0, z.jsx)(qne, {
seed: i.seed,
layout: r,
helpers: t,
actions: n
- }, `mix:${i.seed.id}`) : /* @__PURE__ */ (0, z.jsx)(Eb, {
+ }, `mix:${i.seed.id}`) : /* @__PURE__ */ (0, z.jsx)(Tb, {
item: i.item,
variant: a && i.item.medium && i.item.medium !== "video" ? "resource" : "grid",
layout: r,
@@ -27576,7 +27576,7 @@ function Yne(e) {
"data-grid-reveal": h.fading ? "" : void 0,
children: [h.layer, (() => {
if (c.isPending) return null;
- if (!c.data) return /* @__PURE__ */ (0, z.jsx)(vb, {
+ if (!c.data) return /* @__PURE__ */ (0, z.jsx)(sb, {
message: m(c.error),
onRetry: () => void c.refetch()
});
@@ -27593,15 +27593,15 @@ function Yne(e) {
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("div", {
"data-media-sections": "",
"data-select-mode": e.selectMode ? "" : void 0,
- children: kne(u, _).map((t) => /* @__PURE__ */ (0, z.jsxs)(R.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("div", {
+ children: Bne(u, _).map((t) => /* @__PURE__ */ (0, z.jsxs)(R.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("div", {
"data-media-grid": "",
children: t.tiles.map(S)
- }), t.strip ? /* @__PURE__ */ (0, z.jsx)(Zne, {
+ }), t.strip ? /* @__PURE__ */ (0, z.jsx)(Kne, {
cut: t.strip,
props: e,
onOpen: b
}) : null] }, t.start))
- }), c.hasNextPage ? /* @__PURE__ */ (0, z.jsx)(Pb, {
+ }), c.hasNextPage ? /* @__PURE__ */ (0, z.jsx)(zb, {
entity: i,
load: x,
enabled: () => e.canLoadMore?.() !== !1
@@ -27609,7 +27609,7 @@ function Yne(e) {
})()]
});
}
-function Pb({ entity: e, load: t, enabled: n, children: r }) {
+function zb({ entity: e, load: t, enabled: n, children: r }) {
let i = (0, R.useRef)(null), a = (0, R.useRef)(!1), o = (0, R.useRef)(!1), [s, c] = (0, R.useState)({
busy: !1,
error: ""
@@ -27670,12 +27670,12 @@ function Pb({ entity: e, load: t, enabled: n, children: r }) {
...f,
onClick: () => void u(!0),
dangerouslySetInnerHTML: { __html: k("继续载入中…") }
- }), s.error ? /* @__PURE__ */ (0, z.jsx)(vb, {
+ }), s.error ? /* @__PURE__ */ (0, z.jsx)(sb, {
message: s.error,
onRetry: () => void u(!0)
}) : null] });
}
-function Xne(e, t, n, r, i) {
+function Gne(e, t, n, r, i) {
let [a, o] = (0, R.useState)([]), [s, c] = (0, R.useState)(null), l = (0, R.useRef)(0), u = (0, R.useRef)(0), d = (0, R.useRef)([]);
return (0, R.useEffect)(() => () => d.current.forEach((e) => e.abort()), []), (0, R.useEffect)(() => {
let n = t?.pages.length || 0;
@@ -27684,7 +27684,7 @@ function Xne(e, t, n, r, i) {
let r = new AbortController();
d.current.push(r);
let i = n - 1;
- W(`/api/items?${One(e.filters || {}, l.current)}`, r.signal).then((t) => {
+ W(`/api/items?${zne(e.filters || {}, l.current)}`, r.signal).then((t) => {
let n = t.items || [];
if (!n.length) {
l.current = 0;
@@ -27700,7 +27700,7 @@ function Xne(e, t, n, r, i) {
}, [t]), (0, R.useLayoutEffect)(() => {
if (!s) return;
c(null);
- let e = a.reduce((e, t) => Math.max(e, t.at), 0), t = i.current?.querySelectorAll("[data-media-sections] > [data-media-grid]"), u = t?.[t.length - 1], d = u ? Math.max(1, getComputedStyle(u).gridTemplateColumns.split(" ").length) : 1, f = Math.max(0, (r[s.page] ?? 0) - e), p = Dne(n.length - e, f, d);
+ let e = a.reduce((e, t) => Math.max(e, t.at), 0), t = i.current?.querySelectorAll("[data-media-sections] > [data-media-grid]"), u = t?.[t.length - 1], d = u ? Math.max(1, getComputedStyle(u).gridTemplateColumns.split(" ").length) : 1, f = Math.max(0, (r[s.page] ?? 0) - e), p = Rne(n.length - e, f, d);
if (!p.length) return;
let m = e + (p[Math.floor(Math.random() * p.length)] ?? 0);
l.current = s.more ? l.current + 18 : 0, o((e) => [...e, {
@@ -27710,7 +27710,7 @@ function Xne(e, t, n, r, i) {
}]);
}, [s]), a;
}
-function Zne({ cut: e, props: t, onOpen: n }) {
+function Kne({ cut: e, props: t, onOpen: n }) {
let r = (0, R.useRef)(null), { wireDrag: i } = t;
return (0, R.useEffect)(() => {
r.current && i(r.current);
@@ -27726,12 +27726,12 @@ function Zne({ cut: e, props: t, onOpen: n }) {
type: "button",
"data-shorts-enter": "",
onClick: () => t.actions.openShorts(),
- children: [/* @__PURE__ */ (0, z.jsx)(qne, { name: "gallery-vertical-end" }), /* @__PURE__ */ (0, z.jsx)("span", { children: "进入沉浸模式" })]
+ children: [/* @__PURE__ */ (0, z.jsx)(Hne, { name: "gallery-vertical-end" }), /* @__PURE__ */ (0, z.jsx)("span", { children: "进入沉浸模式" })]
})
] }), /* @__PURE__ */ (0, z.jsx)("div", {
ref: r,
"data-shorts-row": "",
- children: e.items.map((e) => /* @__PURE__ */ (0, z.jsx)(Eb, {
+ children: e.items.map((e) => /* @__PURE__ */ (0, z.jsx)(Tb, {
item: e,
variant: "short",
layout: t.layout,
@@ -27745,9 +27745,9 @@ function Zne({ cut: e, props: t, onOpen: n }) {
})]
});
}
-function Fb(e, t, n, r) {
+function Bb(e, t, n, r) {
let i = t.active && !!e.is_jav;
- return e.is_jav ? bb(e, i ? t.size : "small", n, t.javImage, r.coverHtml) : !e.has_thumb && !e.has_local_poster ? {
+ return e.is_jav ? lb(e, i ? t.size : "small", n, t.javImage, r.coverHtml) : !e.has_thumb && !e.has_local_poster ? {
kind: "",
html: ""
} : {
@@ -27755,18 +27755,18 @@ function Fb(e, t, n, r) {
html: `<img class="poster" src="/poster?id=${e.id}&c=4" alt="" loading="${n ? "eager" : "lazy"}">`
};
}
-function Qne({ seed: e, layout: t, helpers: n, actions: r }) {
+function qne({ seed: e, layout: t, helpers: n, actions: r }) {
let i = (0, R.useRef)(/* @__PURE__ */ new Map()), a = (0, R.useRef)(t);
a.current = t;
- let o = wne(e, n.tagLabel), s = (0, R.useCallback)(async () => {
- let t = a.current, o = [e, ...await r.mixRelated(e.id)].filter((e) => hb(e, t.javImage)).slice(0, 9);
- return i.current = new Map(o.map((e) => [String(e.id), Fb(e, t, !0, n).html])), o.map((e) => String(e.id));
+ let o = Fne(e, n.tagLabel), s = (0, R.useCallback)(async () => {
+ let t = a.current, o = [e, ...await r.mixRelated(e.id)].filter((e) => ib(e, t.javImage)).slice(0, 9);
+ return i.current = new Map(o.map((e) => [String(e.id), Bb(e, t, !0, n).html])), o.map((e) => String(e.id));
}, [
e,
r,
n
- ]), c = t.active && e.is_jav ? t.size : "small", l = Fb(e, t, !1, n);
- return /* @__PURE__ */ (0, z.jsx)(Mb, {
+ ]), c = t.active && e.is_jav ? t.size : "small", l = Bb(e, t, !1, n);
+ return /* @__PURE__ */ (0, z.jsx)(Lb, {
"data-mix-seed": String(e.id),
name: `Mix · ${o}`,
caption: `${n.displayName(e, e.name || "")}及相似作品`,
@@ -27776,12 +27776,12 @@ function Qne({ seed: e, layout: t, helpers: n, actions: r }) {
wholeCard: !0,
poster: null,
artwork: l,
- artworkIdentity: c === "small" ? l.html : Fb(e, {
+ artworkIdentity: c === "small" ? l.html : Bb(e, {
...t,
size: "small"
}, !1, n).html,
relayoutArt: (e) => n.relayoutArt(e, c),
- ratio: wb(e, "grid", t),
+ ratio: _b(e, "grid", t),
flipImages: s,
faceHtml: (e) => i.current.get(e) || "",
canFlip: r.canFlip,
@@ -27794,32 +27794,32 @@ function Qne({ seed: e, layout: t, helpers: n, actions: r }) {
}
//#endregion
//#region src/react/media-sources.ts
-var $ne = "/api/sources", Ib = ["media-sources"], Lb = (e) => W($ne, e);
-async function Rb(e) {
+var Jne = "/api/sources", Vb = ["media-sources"], Hb = (e) => W(Jne, e);
+async function Ub(e) {
await X.fetchQuery({
- queryKey: Ib,
- queryFn: () => Lb(e)
+ queryKey: Vb,
+ queryFn: () => Hb(e)
});
}
-var ere = [
+var Yne = [
"local",
"115",
"pikpak"
-], tre = (e) => (e?.sources ?? []).filter((e) => ["115", "pikpak"].includes(e.location) && (e.roots === void 0 || e.roots.length > 0)).map((e) => e.location), nre = "/api/duplicates?limit=120", zb = ["duplicates"], Bb = "/api/batch", Vb = (e) => W(nre, e);
-async function rre(e) {
+], Xne = (e) => (e?.sources ?? []).filter((e) => ["115", "pikpak"].includes(e.location) && (e.roots === void 0 || e.roots.length > 0)).map((e) => e.location), Zne = "/api/duplicates?limit=120", Wb = ["duplicates"], Gb = "/api/batch", Kb = (e) => W(Zne, e);
+async function Qne(e) {
await Promise.all([X.fetchQuery({
- queryKey: zb,
- queryFn: () => Vb(e)
- }), Rb(e)]);
+ queryKey: Wb,
+ queryFn: () => Kb(e)
+ }), Ub(e)]);
}
-var Hb = {
+var qb = {
largest: "最大的一个",
longest: "最长的一个",
115: "115(没有则留最大)",
pikpak: "PikPak(没有则留最大)",
all: "零个文件"
-}, ire = (e, t) => t.filter((t) => e.some((e) => e.location === t)), Ub = (e, t) => ire(e, t).filter((t) => e.some((e) => e.location !== t)), are = (e, t) => t.filter((t) => e.some((e) => Ub(e.files, [t]).length));
-function ore(e, t) {
+}, $ne = (e, t) => t.filter((t) => e.some((e) => e.location === t)), Jb = (e, t) => $ne(e, t).filter((t) => e.some((e) => e.location !== t)), ere = (e, t) => t.filter((t) => e.some((e) => Jb(e.files, [t]).length));
+function tre(e, t) {
let n = [];
for (let r of e) {
if (t === "all") {
@@ -27838,47 +27838,47 @@ function ore(e, t) {
}
return n;
}
-function sre(e, t) {
+function nre(e, t) {
let n = new Set(t);
return e.reduce((e, t) => e + t.files.reduce((e, t) => e + (n.has(t.id) && t.size || 0), 0), 0);
}
-async function Wb(e, t) {
- for (let n = 0; n < e.length; n += 200) await G(Bb, {
+async function Yb(e, t) {
+ for (let n = 0; n < e.length; n += 200) await G(Gb, {
ids: e.slice(n, n + 200),
operation: t
});
}
//#endregion
//#region src/react/library-processing/library-processing.ts
-var Gb = "/api/library-processing", Kb = ["library-processing"], qb = (e) => W(Gb, e);
-async function Jb(e) {
+var Xb = "/api/library-processing", Zb = ["library-processing"], Qb = (e) => W(Xb, e);
+async function $b(e) {
await X.fetchQuery({
- queryKey: Kb,
- queryFn: () => qb(e)
+ queryKey: Zb,
+ queryFn: () => Qb(e)
});
}
-var cre = 2e3, lre = 1e4, Yb = "连接中断,正在重新读取处理进度";
-function ure(e, t) {
- return e?.status === "running" ? cre : t ? lre : !1;
+var rre = 2e3, ire = 1e4, ex = "连接中断,正在重新读取处理进度";
+function are(e, t) {
+ return e?.status === "running" ? rre : t ? ire : !1;
}
-var dre = {
+var ore = {
reading_local: "读取本地资料",
querying_metadata: "查询外部资料",
fetching_cover: "采集缺失封面",
writing_candidates: "保存资料候选"
-}, Xb = {
+}, tx = {
querying_metadata: "没有资料",
fetching_cover: "没有封面"
};
-function fre(e) {
- let t = Object.entries(e).filter(([e, t]) => Xb[e] && t > 0).map(([e, t]) => `${Xb[e]} ${t} 部`);
+function sre(e) {
+ let t = Object.entries(e).filter(([e, t]) => tx[e] && t > 0).map(([e, t]) => `${tx[e]} ${t} 部`);
return t.length ? `外部来源${t.join("、")},7 天内不再问。` : "";
}
-function Zb(e) {
- let t = dre[e.current_action || ""] || e.stage || "正在处理", n = e.waited_seconds ? ` · 已等待 ${e.waited_seconds} 秒` : "";
+function nx(e) {
+ let t = ore[e.current_action || ""] || e.stage || "正在处理", n = e.waited_seconds ? ` · 已等待 ${e.waited_seconds} 秒` : "";
return e.current_asset_name ? `当前:${e.current_asset_name} · ${t}${n}` : t + n;
}
-function pre(e) {
+function cre(e) {
let t = e.issue_preview || [];
return t.length ? {
label: e.issues_truncated ? `问题清单:共 ${e.issue_count || 0} 项,展开查看前 ${t.length} 项` : `问题清单:共 ${e.issue_count || 0} 项`,
@@ -27892,21 +27892,21 @@ function pre(e) {
log: e.issues_log || ""
} : null;
}
-var Qb = "peach.library-processing.announced", mre = 120;
-function hre(e, t, n) {
+var rx = "peach.library-processing.announced", lre = 120;
+function ure(e, t, n) {
if (e.status !== "complete") return;
- let r = !!e.job_id && !!e.completed_at && Date.now() / 1e3 - e.completed_at < mre;
+ let r = !!e.job_id && !!e.completed_at && Date.now() / 1e3 - e.completed_at < lre;
if (!(!n && !r)) {
try {
- if (e.job_id && localStorage.getItem(Qb) === e.job_id) return;
- e.job_id && localStorage.setItem(Qb, e.job_id);
+ if (e.job_id && localStorage.getItem(rx) === e.job_id) return;
+ e.job_id && localStorage.setItem(rx, e.job_id);
} catch {}
t(`扫描与资料采集已完成:识别 ${e.identified || 0} 个番号,整理 ${e.candidates || 0} 组资料候选,自动落库 ${e.auto_applied || 0} 条`);
}
}
//#endregion
//#region src/react/media-repair/media-repair.ts
-var $b = "/api/media-repair", ex = ["media-repair"], tx = ["media-repair", "libraries"], gre = {
+var ix = "/api/media-repair", ax = ["media-repair"], ox = ["media-repair", "libraries"], dre = {
status: "idle",
library: "",
stage: "",
@@ -27918,33 +27918,33 @@ var $b = "/api/media-repair", ex = ["media-repair"], tx = ["media-repair", "libr
missing_tool: 0,
skipped: 0,
message: ""
-}, nx = (e) => W($b, e), rx = async (e) => (await W("/api/libraries", e)).libraries || [];
-async function _re(e) {
+}, sx = (e) => W(ix, e), cx = async (e) => (await W("/api/libraries", e)).libraries || [];
+async function fre(e) {
await Promise.all([X.fetchQuery({
- queryKey: ex,
- queryFn: () => nx(e)
+ queryKey: ax,
+ queryFn: () => sx(e)
}), X.fetchQuery({
- queryKey: tx,
- queryFn: () => rx(e)
+ queryKey: ox,
+ queryFn: () => cx(e)
})]);
}
-var ix = (e) => Number(e).toLocaleString();
-function vre(e) {
+var lx = (e) => Number(e).toLocaleString();
+function pre(e) {
if (e.status === "running") {
- let t = e.total ? `${ix(e.checked)} / ${ix(e.total)}` : "准备中";
+ let t = e.total ? `${lx(e.checked)} / ${lx(e.total)}` : "准备中";
return e.stage === "修复" && e.message ? `修复 ${t} · ${e.message}` : `${e.stage || "扫描"} ${t}`;
}
- return e.status === "complete" && (e.repaired || e.failed) ? e.failed ? `修好 ${ix(e.repaired)} 部,${ix(e.failed)} 部修不了` : `修好 ${ix(e.repaired)} 部` : "";
+ return e.status === "complete" && (e.repaired || e.failed) ? e.failed ? `修好 ${lx(e.repaired)} 部,${lx(e.failed)} 部修不了` : `修好 ${lx(e.repaired)} 部` : "";
}
-var yre = (e) => `${ix(e.missing_tool)} 部缺索引的片子要装上 untrunc 才修得了,下载入口在配置页的「运行信息」里。`, bre = "/api/quality-goals?limit=200", ax = ["quality-goals"], ox = (e) => W(bre, e);
-async function xre(e) {
+var mre = (e) => `${lx(e.missing_tool)} 部缺索引的片子要装上 untrunc 才修得了,下载入口在配置页的「运行信息」里。`, hre = "/api/quality-goals?limit=200", ux = ["quality-goals"], dx = (e) => W(hre, e);
+async function gre(e) {
await X.fetchQuery({
- queryKey: ax,
- queryFn: () => ox(e)
+ queryKey: ux,
+ queryFn: () => dx(e)
});
}
-var Sre = (e) => e.has_cover ? `/cover?code=${encodeURIComponent(e.code ?? "")}` : `/poster?id=${e.id}&c=4`;
-function sx(e, t, n = 1) {
+var _re = (e) => e.has_cover ? `/cover?code=${encodeURIComponent(e.code ?? "")}` : `/poster?id=${e.id}&c=4`;
+function fx(e, t, n = 1) {
let r = (e, t) => Array.from({ length: t - e + 1 }, (t, n) => e + n);
if (n * 2 + 5 >= t) return r(1, t);
let i = Math.max(e - n, 1), a = Math.min(e + n, t), o = i > 2, s = a < t - 2;
@@ -27964,21 +27964,21 @@ function sx(e, t, n = 1) {
t
];
}
-function cx(e, t) {
+function px(e, t) {
return Math.max(1, Math.ceil(e / t));
}
-function lx(e, t) {
+function mx(e, t) {
return Math.min(Math.max(1, Math.floor(e) || 1), t);
}
//#endregion
//#region src/selection.ts
-function Cre(e, t, n, r, i, a = i || !e.has(r)) {
+function vre(e, t, n, r, i, a = i || !e.has(r)) {
let o = n === null ? -1 : t.indexOf(n), s = t.indexOf(r);
return i && o >= 0 && s >= 0 ? t.slice(Math.min(o, s), Math.max(o, s) + 1).forEach((t) => e.add(t)) : a ? e.add(r) : e.delete(r), r;
}
//#endregion
//#region src/react/time.ts
-function ux(e) {
+function hx(e) {
if (!e) return "";
let t = /[Zz]|[+-]\d\d:?\d\d$/.test(e) ? e : `${e}Z`, n = new Date(t);
if (Number.isNaN(n.getTime())) return String(e).replace("T", " ").slice(0, 16);
@@ -27987,7 +27987,7 @@ function ux(e) {
}
//#endregion
//#region src/react/review/review.ts
-var wre = "/api/review", Tre = "/api/review/decision", Ere = "/api/review/genre", dx = ["review"], fx = {
+var yre = "/api/review", bre = "/api/review/decision", xre = "/api/review/genre", gx = ["review"], _x = {
metadata_fields: "元数据字段",
creator_tags: "创作者标签",
studio_logos: "厂牌 Logo",
@@ -27997,15 +27997,15 @@ var wre = "/api/review", Tre = "/api/review/decision", Ere = "/api/review/genre"
fc2_markings: "FC2 评论标记",
fc2_similarity: "FC2 跨号相似",
video_endcards: "片尾/出处证据"
-}, Dre = Object.keys(fx), Ore = "metadata_fields", px = (e) => typeof e == "string" && Object.hasOwn(fx, e), kre = {
+}, Sre = Object.keys(_x), Cre = "metadata_fields", vx = (e) => typeof e == "string" && Object.hasOwn(_x, e), wre = {
creator_tags: "creator",
western_identity: "creator"
};
-function Are(e, t) {
+function Tre(e, t) {
let n = [["candidates", t ? "按候选数量" : "全部待复核"]];
return e.some((e) => e.source || e.candidates?.some((e) => e.source)) && n.push(["source", "按来源"]), e.some((e) => e.field) && n.push(["field", "按字段"]), n;
}
-function mx(e, t) {
+function yx(e, t) {
let n = /* @__PURE__ */ new Map();
for (let r of e) {
let e, i;
@@ -28022,43 +28022,43 @@ function mx(e, t) {
}
return [...n.values()];
}
-function jre(e, t, n) {
- return n && mx(e, t).find((e) => e.key === n)?.rows || e;
+function Ere(e, t, n) {
+ return n && yx(e, t).find((e) => e.key === n)?.rows || e;
}
-function Mre(e, t) {
- let n = cx(e.length, 20), r = lx(t, n);
+function Dre(e, t) {
+ let n = px(e.length, 20), r = mx(t, n);
return {
page: r,
pages: n,
rows: e.slice((r - 1) * 20, r * 20)
};
}
-function Nre(e) {
+function Ore(e) {
return e.length ? [...new Set(e.flatMap((e) => e.candidates?.map((e) => e.source || "") || []))].filter((t) => t && e.every((e) => e.candidates?.filter((e) => e.source === t).length === 1)) : [];
}
-function Pre(e, t, n, r, i, a) {
- return Cre(e, t, n, r, i, a);
+function kre(e, t, n, r, i, a) {
+ return vre(e, t, n, r, i, a);
}
-function hx(e, t) {
+function bx(e, t) {
return e === "metadata_fields" ? (t.candidates?.length || 0) > 0 : e !== "creator_tags" || String(t.status || "").trim() === "candidate";
}
-function gx(e, t) {
+function xx(e, t) {
return String(e === "metadata_fields" ? t.query || t.code || "" : t.creator || t.studio || t.current_name || t.name || t.item_key);
}
-var _x = (e, t) => e === "metadata_fields" ? String(t.field_label || t.field || "").trim() : "";
-function Fre(e, t) {
- let n = gx(e, t), r = _x(e, t);
+var Sx = (e, t) => e === "metadata_fields" ? String(t.field_label || t.field || "").trim() : "";
+function Are(e, t) {
+ let n = xx(e, t), r = Sx(e, t);
return r ? `${n} · ${r}` : n;
}
-var Ire = (e) => e.reason || e.evidence || e.note || e.decision_note || "", Lre = (e) => String(e.tags || "").split("|").filter(Boolean), Rre = (e) => [...new Set((e.candidates || []).flatMap((e) => e.unmapped_genres || []))];
-function zre(e) {
+var jre = (e) => e.reason || e.evidence || e.note || e.decision_note || "", Mre = (e) => String(e.tags || "").split("|").filter(Boolean), Nre = (e) => [...new Set((e.candidates || []).flatMap((e) => e.unmapped_genres || []))];
+function Pre(e) {
let t = e.candidates || [];
return {
candidateKey: t.length === 1 ? t[0].candidate_key : "",
assets: (e.preview_assets || []).map((e) => e.id)
};
}
-function vx(e, t, n, r) {
+function Cx(e, t, n, r) {
let i = !!t.asset_path && t.asset_mutation_revision != null;
return {
category: e,
@@ -28074,19 +28074,19 @@ function vx(e, t, n, r) {
...i ? { expected_revision: t.asset_mutation_revision } : {}
};
}
-var Bre = (e) => e === "approved" ? "已通过候选" : e === "rejected" ? "已拒绝候选" : "已跳过候选", yx = (e) => W(wre, e), bx = (e) => G(Tre, e), Vre = (e, t) => G(Ere, {
+var Fre = (e) => e === "approved" ? "已通过候选" : e === "rejected" ? "已拒绝候选" : "已跳过候选", wx = (e) => W(yre, e), Tx = (e) => G(bre, e), Ire = (e, t) => G(xre, {
genre: e,
tag: t
});
-async function Hre(e) {
+async function Lre(e) {
await X.fetchQuery({
- queryKey: dx,
- queryFn: () => yx(e)
+ queryKey: gx,
+ queryFn: () => wx(e)
});
}
-function xx(e, t) {
+function Ex(e, t) {
let n = new Set(t);
- n.size && X.setQueryData(dx, (t) => {
+ n.size && X.setQueryData(gx, (t) => {
if (!t) return t;
let r = t.sections[e] || [], i = r.filter((e) => !n.has(String(e.item_key)));
return i.length === r.length ? t : {
@@ -28102,207 +28102,207 @@ function xx(e, t) {
};
});
}
-var Ure = () => X.invalidateQueries({
- queryKey: dx,
+var Rre = () => X.invalidateQueries({
+ queryKey: gx,
exact: !0
});
-function Wre(e, t) {
- return e?.state === "live" ? "正在显示写入端的实时复核队列" : e?.state === "cached" ? `写入端暂时不可达,显示 ${ux(e.fetched_at)} 的缓存` : e?.error || t;
+function zre(e, t) {
+ return e?.state === "live" ? "正在显示写入端的实时复核队列" : e?.state === "cached" ? `写入端暂时不可达,显示 ${hx(e.fetched_at)} 的缓存` : e?.error || t;
}
//#endregion
//#region src/react/data-cleanup/links.ts
-var Gre = "/api/links", Sx = "/api/links/check", Cx = "/api/links/prune", wx = ["links"], Tx = ["links", "check"], Ex = ["links", "prune"], Dx = {
+var Bre = "/api/links", Dx = "/api/links/check", Ox = "/api/links/prune", kx = ["links"], Ax = ["links", "check"], jx = ["links", "prune"], Mx = {
official: "官网/事务所",
social: "社交账号",
catalog: "作品资料站",
source_reference: "资料出处"
};
-async function Ox(e) {
+async function Nx(e) {
let t = await e;
if (t.ok === !1) throw Error(t.error || "操作未完成,请重试");
return t;
}
-var kx = (e) => W(Gre, e), Ax = (e) => G(Sx, { status_only: !0 }, "POST", e), Kre = ({ retry: e, checkId: t }) => Ox(G(Sx, e ? {
+var Px = (e) => W(Bre, e), Fx = (e) => G(Dx, { status_only: !0 }, "POST", e), Vre = ({ retry: e, checkId: t }) => Nx(G(Dx, e ? {
retry: e,
check_id: t
-} : { restart: !0 })), jx = (e) => W(Cx, e), qre = (e) => Ox(G(Cx, {
+} : { restart: !0 })), Ix = (e) => W(Ox, e), Hre = (e) => Nx(G(Ox, {
confirm: !0,
check_id: e,
background: !0
-})), Mx = (e) => Number(e || 0).toLocaleString(), Jre = (e) => `已删除 ${Mx(e.removed)} 条;${e.marked ? `已隐退女优的 ${Mx(e.marked)} 条留作不可点的记录;` : ""}保留 ${Mx(e.recovered)} 条未确认失效的链接。`;
-function Yre(e) {
+})), Lx = (e) => Number(e || 0).toLocaleString(), Ure = (e) => `已删除 ${Lx(e.removed)} 条;${e.marked ? `已隐退女优的 ${Lx(e.marked)} 条留作不可点的记录;` : ""}保留 ${Lx(e.recovered)} 条未确认失效的链接。`;
+function Wre(e) {
let t = e.scope === "retry";
- return e.total ? `${t ? "已重验" : "已检查"} ${Mx(e.checked)} / ${Mx(e.total)} 条链接` : t ? "正在重验链接" : "正在检查链接";
+ return e.total ? `${t ? "已重验" : "已检查"} ${Lx(e.checked)} / ${Lx(e.total)} 条链接` : t ? "正在重验链接" : "正在检查链接";
}
//#endregion
//#region src/react/settings-panel/settings-data.ts
-var Nx = "/api/settings", Px = "/api/follow/schedule", Fx = "/api/thumbnail-jobs", Ix = ["settings"], Lx = ["follow-schedule"], Rx = ["thumbnail-jobs"], Xre = (e) => W(Nx, e), zx = (e) => W(Px, e), Bx = (e) => W(Fx, e);
-function Vx(e = X) {
+var Rx = "/api/settings", zx = "/api/follow/schedule", Bx = "/api/thumbnail-jobs", Vx = ["settings"], Hx = ["follow-schedule"], Ux = ["thumbnail-jobs"], Gre = (e) => W(Rx, e), Wx = (e) => W(zx, e), Gx = (e) => W(Bx, e);
+function Kre(e = X) {
return e.fetchQuery({
- queryKey: Lx,
- queryFn: ({ signal: e }) => zx(e),
+ queryKey: Hx,
+ queryFn: ({ signal: e }) => Wx(e),
staleTime: 0
}).catch(() => null), e.fetchQuery({
- queryKey: Rx,
- queryFn: ({ signal: e }) => Bx(e),
+ queryKey: Ux,
+ queryFn: ({ signal: e }) => Gx(e),
staleTime: 0
}).catch(() => null), e.fetchQuery({
- queryKey: Ix,
- queryFn: ({ signal: e }) => Xre(e),
+ queryKey: Vx,
+ queryFn: ({ signal: e }) => Gre(e),
staleTime: 0
}).catch(() => null);
}
-function Hx() {
+function Kx() {
return er({
- mutationFn: (e) => G(Nx, e),
- onSuccess: (e) => X.setQueryData(Ix, e)
+ mutationFn: (e) => G(Rx, e),
+ onSuccess: (e) => X.setQueryData(Vx, e)
});
}
-function Ux() {
+function qre() {
return er({
- mutationFn: (e) => G(Px, {
+ mutationFn: (e) => G(zx, {
enabled: e > 0,
interval_minutes: e || 60
}),
- onSuccess: (e) => X.setQueryData(Lx, e)
+ onSuccess: (e) => X.setQueryData(Hx, e)
});
}
-function Wx() {
+function Jre() {
return er({
- mutationFn: (e) => G(Fx, { mode: e }),
- onSuccess: (e) => X.setQueryData(Rx, e)
+ mutationFn: (e) => G(Bx, { mode: e }),
+ onSuccess: (e) => X.setQueryData(Ux, e)
});
}
-function Gx(e) {
- return e.available ? e.running ? "正在检查全部来源…" : e.last_error ? `上次失败:${e.last_error}` : e.last_finished_at ? `上次完成 ${ux(e.last_finished_at)} · 新增 ${e.last_added || 0}` : e.next_run_at ? `下次 ${ux(e.next_run_at)}` : e.enabled ? "等待首次运行" : "已关闭" : "只在账本写入端运行";
+function Yre(e) {
+ return e.available ? e.running ? "正在检查全部来源…" : e.last_error ? `上次失败:${e.last_error}` : e.last_finished_at ? `上次完成 ${hx(e.last_finished_at)} · 新增 ${e.last_added || 0}` : e.next_run_at ? `下次 ${hx(e.next_run_at)}` : e.enabled ? "等待首次运行" : "已关闭" : "只在账本写入端运行";
}
-function Kx(e) {
+function Xre(e) {
return e.status === "running" ? "正在采集,进度在活动页查看。" : e.status === "failed" ? `上一轮采集停下了:${e.stopped || "原因未取得"}` : e.status === "complete" ? e.stopped ? "上一轮采集已按停。" : "上一轮采集已完成。" : e.mode === "off" ? "关闭时不采集;已经生成的图留在盘上,清理走数据管理页。" : "选定档位后从最近看过的片子开始采集。";
}
//#endregion
//#region src/react/data-cleanup/organize.ts
-var qx = "/api/organize", Jx = "/api/organize/preview", Yx = "/api/organize/apply", Xx = "/api/organize/rollback", Zx = ["organize"], Qx = (e) => W(qx, e);
-async function $x(e) {
+var Zre = "/api/organize", Qre = "/api/organize/preview", $re = "/api/organize/apply", eie = "/api/organize/rollback", qx = ["organize"], Jx = (e) => W(Zre, e);
+async function tie(e) {
await X.fetchQuery({
- queryKey: Zx,
- queryFn: () => Qx(e)
+ queryKey: qx,
+ queryFn: () => Jx(e)
});
}
-var eS = (e) => G(Jx, e), tS = (e) => e.kind === "apply" ? G(Yx, {
+var nie = (e) => G(Qre, e), rie = (e) => e.kind === "apply" ? G($re, {
...e.request,
confirm: !0
-}) : G(Xx, { confirm: !0 });
-async function nS(e) {
- X.setQueryData(Zx, (t) => t && {
+}) : G(eie, { confirm: !0 });
+async function iie(e) {
+ X.setQueryData(qx, (t) => t && {
...t,
templates: e
});
try {
- await G(Nx, { organizeTemplates: e });
+ await G(Rx, { organizeTemplates: e });
} catch {}
}
-var rS = (e, t) => e && {
+var aie = (e, t) => e && {
...e,
...t
-}, iS = /目录模板|分隔符|盘符|`\.`/;
-function aS(e) {
+}, oie = /目录模板|分隔符|盘符|`\.`/;
+function Yx(e) {
let t = String(e || "");
return t.slice(Math.max(t.lastIndexOf("\\"), t.lastIndexOf("/")) + 1);
}
-var oS = (e) => Number(e || 0).toLocaleString();
-function sS(e) {
- let t = Object.entries(e.reasons || {}).sort((e, t) => t[1] - e[1]).map(([e, t]) => `${e} ${oS(t)}`).join(" · ");
- return Number(e.counts?.change || 0) ? `${oS(e.counts.change)} 个文件会改名或移动,${oS(e.counts.unchanged)} 个已经就是目标名字${t ? `;跳过 ${t}` : ""}。` : `没有要改的文件。${t ? `跳过:${t}。` : ""}`;
+var Xx = (e) => Number(e || 0).toLocaleString();
+function sie(e) {
+ let t = Object.entries(e.reasons || {}).sort((e, t) => t[1] - e[1]).map(([e, t]) => `${e} ${Xx(t)}`).join(" · ");
+ return Number(e.counts?.change || 0) ? `${Xx(e.counts.change)} 个文件会改名或移动,${Xx(e.counts.unchanged)} 个已经就是目标名字${t ? `;跳过 ${t}` : ""}。` : `没有要改的文件。${t ? `跳过:${t}。` : ""}`;
}
-function cS(e) {
+function Zx(e) {
let t = e.restored !== void 0, n = Number(e.failed || 0), r = Number(t ? e.restored : e.moved || 0);
return {
- text: t ? `已退回 ${oS(r)} 个文件${n ? `,${oS(n)} 行未能退回` : ""}。` : `已整理 ${oS(r)} 个文件${n ? `,${oS(n)} 行未能处理` : ""}。`,
+ text: t ? `已退回 ${Xx(r)} 个文件${n ? `,${Xx(n)} 行未能退回` : ""}。` : `已整理 ${Xx(r)} 个文件${n ? `,${Xx(n)} 行未能处理` : ""}。`,
failed: n,
rollback: t
};
}
//#endregion
//#region src/react/data-cleanup/resource-sync.ts
-var lS = "/api/resource-sync/scan", uS = "/api/resource-sync/apply", dS = ["resource-sync", "scan"], fS = ["resource-sync", "apply"], pS = (e) => G(lS, {
+var Qx = "/api/resource-sync/scan", $x = "/api/resource-sync/apply", eS = ["resource-sync", "scan"], tS = ["resource-sync", "apply"], nS = (e) => G(Qx, {
background: !0,
status_only: !0
-}, "POST", e), mS = () => G(lS, {
+}, "POST", e), cie = () => G(Qx, {
background: !0,
restart: !0
-}), hS = (e) => W(uS, e), gS = (e) => G(uS, {
+}), rS = (e) => W($x, e), lie = (e) => G($x, {
confirm: !0,
clean_cache: !0,
scan_id: e,
background: !0
-}), _S = (e) => (e?.sources ?? []).some((e) => ere.includes(e.location) && Array.isArray(e.roots) && e.roots.length > 0);
-async function vS(e) {
- _S(X.getQueryData(Ib)) && await Promise.all([X.fetchQuery({
- queryKey: dS,
- queryFn: () => pS(e)
+}), iS = (e) => (e?.sources ?? []).some((e) => Yne.includes(e.location) && Array.isArray(e.roots) && e.roots.length > 0);
+async function uie(e) {
+ iS(X.getQueryData(Vb)) && await Promise.all([X.fetchQuery({
+ queryKey: eS,
+ queryFn: () => nS(e)
}), X.fetchQuery({
- queryKey: fS,
- queryFn: () => hS(e)
+ queryKey: tS,
+ queryFn: () => rS(e)
})]);
}
-var yS = (e) => !!(e?.missing || e?.empty || e?.cache?.files), bS = {
+var die = (e) => !!(e?.missing || e?.empty || e?.cache?.files), fie = {
local: "本地磁盘",
115: "115",
pikpak: "PikPak"
-}, xS = (e) => Number(e || 0).toLocaleString(), SS = (e) => e.total_sources ? `已扫描 ${e.completed_sources || 0}/${e.total_sources} 个来源` : "正在扫描来源", CS = (e) => e.purge ?? Number(e.missing || 0) - Number(e.vanish || 0), wS = (e) => e.vanish ? `${xS(e.vanish)} 条带个人记录的标为已消失,记录留着,可在孤儿记录里接到新文件或彻底删除。` : "", TS = (e) => e.vanish ? "这几样不可撤销。" : "这一步不可撤销。", ES = (e) => `将永久删除文件已不在盘上的 ${xS(CS(e))} 条记录和 ${xS(e.empty)} 个空文件夹,并清理 ${xS(e.cache?.files)} 个闲置缓存。${TS(e)}${wS(e)}`, DS = (e) => `将永久删除文件已不在盘上的 ${xS(CS(e))} 条记录(含回收站里的)、${xS(e.empty)} 个空文件夹,并清理 ${xS(e.cache?.files)} 个闲置缓存。来源根目录保留。${TS(e)}${wS(e)}`, OS = (e) => e.online ? [
- `找不到文件 · 共 ${xS(e.total)} 项`,
- e.vanish ? `${xS(e.vanish)} 项带个人记录` : "",
- e.empty ? `空文件夹 ${xS(e.empty)} 个` : "",
- e.unreadable ? `${xS(e.unreadable)} 个目录读取失败,已跳过` : ""
-].filter(Boolean).join(" · ") : `馆藏中有 ${xS(e.total)} 项`;
-function kS(e) {
+}, aS = (e) => Number(e || 0).toLocaleString(), pie = (e) => e.total_sources ? `已扫描 ${e.completed_sources || 0}/${e.total_sources} 个来源` : "正在扫描来源", oS = (e) => e.purge ?? Number(e.missing || 0) - Number(e.vanish || 0), sS = (e) => e.vanish ? `${aS(e.vanish)} 条带个人记录的标为已消失,记录留着,可在孤儿记录里接到新文件或彻底删除。` : "", cS = (e) => e.vanish ? "这几样不可撤销。" : "这一步不可撤销。", mie = (e) => `将永久删除文件已不在盘上的 ${aS(oS(e))} 条记录和 ${aS(e.empty)} 个空文件夹,并清理 ${aS(e.cache?.files)} 个闲置缓存。${cS(e)}${sS(e)}`, hie = (e) => `将永久删除文件已不在盘上的 ${aS(oS(e))} 条记录(含回收站里的)、${aS(e.empty)} 个空文件夹,并清理 ${aS(e.cache?.files)} 个闲置缓存。来源根目录保留。${cS(e)}${sS(e)}`, gie = (e) => e.online ? [
+ `找不到文件 · 共 ${aS(e.total)} 项`,
+ e.vanish ? `${aS(e.vanish)} 项带个人记录` : "",
+ e.empty ? `空文件夹 ${aS(e.empty)} 个` : "",
+ e.unreadable ? `${aS(e.unreadable)} 个目录读取失败,已跳过` : ""
+].filter(Boolean).join(" · ") : `馆藏中有 ${aS(e.total)} 项`;
+function lS(e) {
let t = e.blocked ?? [], n = Number(e.dir_errors || 0), r = e.cache_blocked ?? [], i = Number(e.purged || 0) + Number(e.vanished || 0) + Number(e.reattached || 0) + Number(e.dirs_removed || 0) + Number(e.cache_removed || 0), a = t.length + n + r.length, o = t.slice(0, 3).map((e) => `「${e.name}」`).join("、") + (t.length > 3 ? " 等" : "");
return {
done: i,
left: a,
rest: [
- t.length ? `${xS(t.length)} 条记录没有删除(${o})` : "",
- n ? `${xS(n)} 个文件夹没有删除` : "",
- r.length ? `${xS(r.length)} 个缓存没有清理` : ""
+ t.length ? `${aS(t.length)} 条记录没有删除(${o})` : "",
+ n ? `${aS(n)} 个文件夹没有删除` : "",
+ r.length ? `${aS(r.length)} 个缓存没有清理` : ""
].filter(Boolean).join(",")
};
}
-var AS = (e, t) => {
- let { rest: n } = kS(e), r = `已永久删除 ${xS(e.purged)} 条失效记录和 ${xS(e.dirs_removed)} 个空文件夹,清理 ${xS(e.cache_removed)} 个缓存,释放 ${t(e.bytes_reclaimed || 0)}。` + (e.vanished ? `${xS(e.vanished)} 条带个人记录的已标为已消失,可在孤儿记录里处理。` : "") + (e.reattached ? `${xS(e.reattached)} 条的记录已接到库里的另一个版本。` : "");
+var _ie = (e, t) => {
+ let { rest: n } = lS(e), r = `已永久删除 ${aS(e.purged)} 条失效记录和 ${aS(e.dirs_removed)} 个空文件夹,清理 ${aS(e.cache_removed)} 个缓存,释放 ${t(e.bytes_reclaimed || 0)}。` + (e.vanished ? `${aS(e.vanished)} 条带个人记录的已标为已消失,可在孤儿记录里处理。` : "") + (e.reattached ? `${aS(e.reattached)} 条的记录已接到库里的另一个版本。` : "");
return n ? `${r}${n},重新检查后可再试。` : r;
-}, jS = "/api/review?counts=1", MS = ["review", "counts"], NS = "/api/ads?limit=1", PS = ["junk-summary"], FS = "/api/items?state=trash&limit=1", IS = ["trash-summary"], LS = [
+}, vie = "/api/review?counts=1", uS = ["review", "counts"], yie = "/api/ads?limit=1", dS = ["junk-summary"], fS = "/api/items?state=trash&limit=1", pS = ["trash-summary"], bie = [
["video", "视频"],
["image", "图片"],
["archive", "压缩包"],
["audio", "音频"],
["url", "网址"],
["other", "其它"]
-], RS = (e) => W(jS, e), zS = (e) => W(NS, e), BS = (e) => {
+], mS = (e) => W(vie, e), hS = (e) => W(yie, e), gS = (e) => {
let t = sessionStorage.getItem("peach.library");
- return W(t ? `${FS}&library=${encodeURIComponent(t)}` : FS, e);
-}, VS = (e) => Number(e || 0).toLocaleString();
-function HS(e) {
- let t = fx, n = Object.entries(e?.counts ?? {}).map(([e, n]) => [t[e] || e, Number(n) || 0]).filter(([, e]) => e > 0).sort((e, t) => t[1] - e[1]), r = n.reduce((e, [, t]) => e + t, 0), i = n.slice(0, 3).map(([e, t]) => `${e} ${t.toLocaleString()}`), a = n.slice(3).reduce((e, [, t]) => e + t, 0);
+ return W(t ? `${fS}&library=${encodeURIComponent(t)}` : fS, e);
+}, _S = (e) => Number(e || 0).toLocaleString();
+function xie(e) {
+ let t = _x, n = Object.entries(e?.counts ?? {}).map(([e, n]) => [t[e] || e, Number(n) || 0]).filter(([, e]) => e > 0).sort((e, t) => t[1] - e[1]), r = n.reduce((e, [, t]) => e + t, 0), i = n.slice(0, 3).map(([e, t]) => `${e} ${t.toLocaleString()}`), a = n.slice(3).reduce((e, [, t]) => e + t, 0);
return a && i.push(`其余 ${a.toLocaleString()}`), {
figure: `${r.toLocaleString()} 条待复核`,
meta: i.join(" · ")
};
}
-function US(e) {
+function Sie(e) {
if (!e) return "";
- let t = LS.filter(([t]) => Number(e.counts?.[t]) > 0).map(([t, n]) => `${n} ${VS(e.counts[t])}`);
- return Number(e.dismissed_total) > 0 && t.push(`已忽略 ${VS(e.dismissed_total)}`), t.join(" · ");
-}
-var WS = [
- [MS, ({ signal: e }) => RS(e)],
- [ax, ({ signal: e }) => ox(e)],
- [IS, ({ signal: e }) => BS(e)],
- [wx, ({ signal: e }) => kx(e)],
- [Tx, ({ signal: e }) => Ax(e)],
- [Ex, ({ signal: e }) => jx(e)]
+ let t = bie.filter(([t]) => Number(e.counts?.[t]) > 0).map(([t, n]) => `${n} ${_S(e.counts[t])}`);
+ return Number(e.dismissed_total) > 0 && t.push(`已忽略 ${_S(e.dismissed_total)}`), t.join(" · ");
+}
+var Cie = [
+ [uS, ({ signal: e }) => mS(e)],
+ [ux, ({ signal: e }) => dx(e)],
+ [pS, ({ signal: e }) => gS(e)],
+ [kx, ({ signal: e }) => Px(e)],
+ [Ax, ({ signal: e }) => Fx(e)],
+ [jx, ({ signal: e }) => Ix(e)]
];
-async function GS(e) {
- let t = location.hash === "#resource-sync", n = WS.map(([n, r]) => {
+async function wie(e) {
+ let t = location.hash === "#resource-sync", n = Cie.map(([n, r]) => {
if (t) return X.fetchQuery({
queryKey: n,
queryFn: () => r({ signal: e })
@@ -28315,40 +28315,40 @@ async function GS(e) {
await Promise.all([
...n,
X.fetchQuery({
- queryKey: PS,
- queryFn: () => zS(e)
+ queryKey: dS,
+ queryFn: () => hS(e)
}),
X.fetchQuery({
- queryKey: zb,
- queryFn: () => Vb(e)
+ queryKey: Wb,
+ queryFn: () => Kb(e)
}),
- Rb(e).then(() => vS(e)),
- Jb(e),
- _re(e),
- $x(e)
+ Ub(e).then(() => uie(e)),
+ $b(e),
+ fre(e),
+ tie(e)
]);
}
//#endregion
//#region src/react/components/stat-card.tsx
-var Zre = [
+var Tie = [
"text-chart-6",
"text-chart-5",
"text-chart-7",
"text-chart-8"
-], Qre = [
+], Eie = [
"bg-chart-6/10",
"bg-chart-5/10",
"bg-chart-7/10",
"bg-chart-8/10"
];
-function KS(e = {}) {
+function vS(e = {}) {
return `${Zi({
...e,
padding: "none"
})} flex flex-col overflow-hidden pt-4 text-left`;
}
-var qS = "inline-grid w-full grid-cols-2 gap-3 sm:gap-4 lg:grid-cols-4", $re = "inline-grid w-full grid-cols-2 gap-3 sm:grid-cols-3 sm:gap-4 xl:grid-cols-6";
-function JS({ interactive: e = !1 } = {}) {
+var yS = "inline-grid w-full grid-cols-2 gap-3 sm:gap-4 lg:grid-cols-4", Die = "inline-grid w-full grid-cols-2 gap-3 sm:grid-cols-3 sm:gap-4 xl:grid-cols-6";
+function bS({ interactive: e = !1 } = {}) {
return Zi({
padding: "none",
radius: "plain",
@@ -28356,8 +28356,8 @@ function JS({ interactive: e = !1 } = {}) {
className: "flex min-h-33 flex-col gap-2 p-4 text-left"
});
}
-var eie = "inline-grid w-full grid-cols-5 gap-4 max-plain-stat-pair:grid-cols-2 max-plain-stat-single:grid-cols-1";
-function YS({ label: e, icon: t, mark: n, aside: r, figure: i, meta: a, wrapMeta: o = !1 }) {
+var Oie = "inline-grid w-full grid-cols-5 gap-4 max-plain-stat-pair:grid-cols-2 max-plain-stat-single:grid-cols-1";
+function xS({ label: e, icon: t, mark: n, aside: r, figure: i, meta: a, wrapMeta: o = !1 }) {
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 items-center gap-2 text-body-medium text-text-secondary",
@@ -28390,13 +28390,13 @@ function YS({ label: e, icon: t, mark: n, aside: r, figure: i, meta: a, wrapMeta
})
] });
}
-function XS({ label: e, icon: t, accent: n = 0, figure: r, footer: i }) {
+function SS({ label: e, icon: t, accent: n = 0, figure: r, footer: i }) {
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 items-center gap-2 px-4 text-body-regular text-text-secondary max-sm:gap-1.5 max-sm:px-3",
children: [t ? /* @__PURE__ */ (0, z.jsx)("i", {
"aria-hidden": !0,
- className: `flex size-7 shrink-0 items-center justify-center rounded-lg max-sm:size-6 ${Zre[n % 4]} ${Qre[n % 4]}`,
+ className: `flex size-7 shrink-0 items-center justify-center rounded-lg max-sm:size-6 ${Tie[n % 4]} ${Eie[n % 4]}`,
children: /* @__PURE__ */ (0, z.jsx)(t, {
"aria-hidden": !0,
className: "size-4"
@@ -28418,34 +28418,34 @@ function XS({ label: e, icon: t, accent: n = 0, figure: r, footer: i }) {
}
//#endregion
//#region node_modules/motion-utils/dist/es/array.mjs
-function ZS(e, t) {
+function CS(e, t) {
e.indexOf(t) === -1 && e.push(t);
}
-function QS(e, t) {
+function wS(e, t) {
let n = e.indexOf(t);
n > -1 && e.splice(n, 1);
}
//#endregion
//#region node_modules/motion-utils/dist/es/clamp.mjs
-var $S = (e, t, n) => n > t ? t : n < e ? e : n, eC = {}, tC = (e) => /^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e), nC = (e) => typeof e == "object" && !!e, rC = (e) => /^0[^.\s]+$/u.test(e);
+var TS = (e, t, n) => n > t ? t : n < e ? e : n, ES = {}, DS = (e) => /^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e), OS = (e) => typeof e == "object" && !!e, kS = (e) => /^0[^.\s]+$/u.test(e);
//#endregion
//#region node_modules/motion-utils/dist/es/memo.mjs
/*#__NO_SIDE_EFFECTS__*/
-function iC(e) {
+function AS(e) {
let t;
return () => (t === void 0 && (t = e()), t);
}
//#endregion
//#region node_modules/motion-utils/dist/es/noop.mjs
-var aC = /* @__NO_SIDE_EFFECTS__ */ (e) => e, oC = (...e) => e.reduce((e, t) => (n) => t(e(n))), sC = /* @__NO_SIDE_EFFECTS__ */ (e, t, n) => {
+var jS = /* @__NO_SIDE_EFFECTS__ */ (e) => e, MS = (...e) => e.reduce((e, t) => (n) => t(e(n))), NS = /* @__NO_SIDE_EFFECTS__ */ (e, t, n) => {
let r = t - e;
return r ? (n - e) / r : 1;
-}, cC = class {
+}, PS = class {
constructor() {
this.subscriptions = [];
}
add(e) {
- return ZS(this.subscriptions, e), () => QS(this.subscriptions, e);
+ return CS(this.subscriptions, e), () => wS(this.subscriptions, e);
}
notify(e, t, n) {
let r = this.subscriptions.length;
@@ -28463,42 +28463,42 @@ var aC = /* @__NO_SIDE_EFFECTS__ */ (e) => e, oC = (...e) => e.reduce((e, t) =>
clear() {
this.subscriptions.length = 0;
}
-}, lC = /* @__NO_SIDE_EFFECTS__ */ (e) => e * 1e3, uC = /* @__NO_SIDE_EFFECTS__ */ (e) => e / 1e3, dC = /* @__NO_SIDE_EFFECTS__ */ (e, t) => t ? 1e3 / t * e : 0, fC = (e, t, n) => (((1 - 3 * n + 3 * t) * e + (3 * n - 6 * t)) * e + 3 * t) * e, tie = 1e-7, nie = 12;
-function rie(e, t, n, r, i) {
+}, FS = /* @__NO_SIDE_EFFECTS__ */ (e) => e * 1e3, IS = /* @__NO_SIDE_EFFECTS__ */ (e) => e / 1e3, LS = /* @__NO_SIDE_EFFECTS__ */ (e, t) => t ? 1e3 / t * e : 0, RS = (e, t, n) => (((1 - 3 * n + 3 * t) * e + (3 * n - 6 * t)) * e + 3 * t) * e, kie = 1e-7, Aie = 12;
+function jie(e, t, n, r, i) {
let a, o, s = 0;
do
- o = t + (n - t) / 2, a = fC(o, r, i) - e, a > 0 ? n = o : t = o;
- while (Math.abs(a) > tie && ++s < nie);
+ o = t + (n - t) / 2, a = RS(o, r, i) - e, a > 0 ? n = o : t = o;
+ while (Math.abs(a) > kie && ++s < Aie);
return o;
}
/*#__NO_SIDE_EFFECTS__*/
-function pC(e, t, n, r) {
- if (e === t && n === r) return aC;
- let i = (t) => rie(t, 0, 1, e, n);
- return (e) => e === 0 || e === 1 ? e : fC(i(e), t, r);
+function zS(e, t, n, r) {
+ if (e === t && n === r) return jS;
+ let i = (t) => jie(t, 0, 1, e, n);
+ return (e) => e === 0 || e === 1 ? e : RS(i(e), t, r);
}
//#endregion
//#region node_modules/motion-utils/dist/es/easing/modifiers/mirror.mjs
-var mC = /* @__NO_SIDE_EFFECTS__ */ (e) => (t) => t <= .5 ? e(2 * t) / 2 : (2 - e(2 * (1 - t))) / 2, hC = /* @__NO_SIDE_EFFECTS__ */ (e) => (t) => 1 - e(1 - t), gC = /*@__PURE__*/ pC(.33, 1.53, .69, .99), _C = /*@__PURE__*/ hC(gC), vC = /*@__PURE__*/ mC(_C), yC = (e) => e >= 1 ? 1 : (e *= 2) < 1 ? .5 * _C(e) : .5 * (2 - 2 ** (-10 * (e - 1))), bC = (e) => 1 - Math.sin(Math.acos(e)), xC = /* @__PURE__ */ hC(bC), SC = /* @__PURE__ */ mC(bC), iie = /*@__PURE__*/ pC(.42, 0, 1, 1), aie = /*@__PURE__*/ pC(0, 0, .58, 1), CC = /*@__PURE__*/ pC(.42, 0, .58, 1), oie = /* @__NO_SIDE_EFFECTS__ */ (e) => Array.isArray(e) && typeof e[0] != "number", wC = /* @__NO_SIDE_EFFECTS__ */ (e) => Array.isArray(e) && typeof e[0] == "number", TC = {
- linear: aC,
- easeIn: iie,
- easeInOut: CC,
- easeOut: aie,
- circIn: bC,
- circInOut: SC,
- circOut: xC,
- backIn: _C,
- backInOut: vC,
- backOut: gC,
- anticipate: yC
-}, sie = (e) => typeof e == "string", EC = (e) => {
- if (/* @__PURE__ */ wC(e)) {
+var BS = /* @__NO_SIDE_EFFECTS__ */ (e) => (t) => t <= .5 ? e(2 * t) / 2 : (2 - e(2 * (1 - t))) / 2, VS = /* @__NO_SIDE_EFFECTS__ */ (e) => (t) => 1 - e(1 - t), HS = /*@__PURE__*/ zS(.33, 1.53, .69, .99), US = /*@__PURE__*/ VS(HS), WS = /*@__PURE__*/ BS(US), GS = (e) => e >= 1 ? 1 : (e *= 2) < 1 ? .5 * US(e) : .5 * (2 - 2 ** (-10 * (e - 1))), KS = (e) => 1 - Math.sin(Math.acos(e)), qS = /* @__PURE__ */ VS(KS), JS = /* @__PURE__ */ BS(KS), Mie = /*@__PURE__*/ zS(.42, 0, 1, 1), Nie = /*@__PURE__*/ zS(0, 0, .58, 1), YS = /*@__PURE__*/ zS(.42, 0, .58, 1), Pie = /* @__NO_SIDE_EFFECTS__ */ (e) => Array.isArray(e) && typeof e[0] != "number", XS = /* @__NO_SIDE_EFFECTS__ */ (e) => Array.isArray(e) && typeof e[0] == "number", ZS = {
+ linear: jS,
+ easeIn: Mie,
+ easeInOut: YS,
+ easeOut: Nie,
+ circIn: KS,
+ circInOut: JS,
+ circOut: qS,
+ backIn: US,
+ backInOut: WS,
+ backOut: HS,
+ anticipate: GS
+}, Fie = (e) => typeof e == "string", QS = (e) => {
+ if (/* @__PURE__ */ XS(e)) {
e.length;
let [t, n, r, i] = e;
- return /* @__PURE__ */ pC(t, n, r, i);
+ return /* @__PURE__ */ zS(t, n, r, i);
}
- return sie(e) ? (TC[e], `${e}`, TC[e]) : e;
-}, DC = [
+ return Fie(e) ? (ZS[e], `${e}`, ZS[e]) : e;
+}, $S = [
"setup",
"read",
"resolveKeyframes",
@@ -28510,7 +28510,7 @@ var mC = /* @__NO_SIDE_EFFECTS__ */ (e) => (t) => t <= .5 ? e(2 * t) / 2 : (2 -
];
//#endregion
//#region node_modules/motion-dom/dist/es/frameloop/render-step.mjs
-function cie(e) {
+function Iie(e) {
let t = /* @__PURE__ */ new Set(), n = /* @__PURE__ */ new Set(), r = !1, i = !1, a = /* @__PURE__ */ new WeakSet(), o = {
delta: 0,
timestamp: 0,
@@ -28541,25 +28541,25 @@ function cie(e) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/frameloop/batcher.mjs
-var lie = 40;
-function OC(e, t) {
+var Lie = 40;
+function eC(e, t) {
let n = !1, r = !0, i = {
delta: 0,
timestamp: 0,
isProcessing: !1
- }, a = () => n = !0, o = DC.reduce((e, t) => (e[t] = cie(a), e), {}), { setup: s, read: c, resolveKeyframes: l, preUpdate: u, update: d, preRender: f, render: p, postRender: m } = o, h = () => {
- let a = eC.useManualTiming, o = a ? i.timestamp : performance.now();
- n = !1, a || (i.delta = r ? 1e3 / 60 : Math.max(Math.min(o - i.timestamp, lie), 1)), i.timestamp = o, i.isProcessing = !0, s.process(i), c.process(i), l.process(i), u.process(i), d.process(i), f.process(i), p.process(i), m.process(i), i.isProcessing = !1, n && t && (r = !1, e(h));
+ }, a = () => n = !0, o = $S.reduce((e, t) => (e[t] = Iie(a), e), {}), { setup: s, read: c, resolveKeyframes: l, preUpdate: u, update: d, preRender: f, render: p, postRender: m } = o, h = () => {
+ let a = ES.useManualTiming, o = a ? i.timestamp : performance.now();
+ n = !1, a || (i.delta = r ? 1e3 / 60 : Math.max(Math.min(o - i.timestamp, Lie), 1)), i.timestamp = o, i.isProcessing = !0, s.process(i), c.process(i), l.process(i), u.process(i), d.process(i), f.process(i), p.process(i), m.process(i), i.isProcessing = !1, n && t && (r = !1, e(h));
}, g = () => {
n = !0, r = !0, i.isProcessing || e(h);
};
return {
- schedule: DC.reduce((e, t) => {
+ schedule: $S.reduce((e, t) => {
let r = o[t];
return e[t] = (e, t = !1, i = !1) => (n || g(), r.schedule(e, t, i)), e;
}, {}),
cancel: (e) => {
- for (let t = 0; t < DC.length; t++) o[DC[t]].cancel(e);
+ for (let t = 0; t < $S.length; t++) o[$S[t]].cancel(e);
},
state: i,
steps: o
@@ -28567,59 +28567,59 @@ function OC(e, t) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/frameloop/frame.mjs
-var { schedule: kC, cancel: AC, state: jC, steps: MC } = /* @__PURE__ */ OC(typeof requestAnimationFrame < "u" ? requestAnimationFrame : aC, !0), NC;
-function uie() {
- NC = void 0;
+var { schedule: tC, cancel: nC, state: rC, steps: iC } = /* @__PURE__ */ eC(typeof requestAnimationFrame < "u" ? requestAnimationFrame : jS, !0), aC;
+function Rie() {
+ aC = void 0;
}
-var PC = {
- now: () => (NC === void 0 && PC.set(jC.isProcessing || eC.useManualTiming ? jC.timestamp : performance.now()), NC),
+var oC = {
+ now: () => (aC === void 0 && oC.set(rC.isProcessing || ES.useManualTiming ? rC.timestamp : performance.now()), aC),
set: (e) => {
- NC = e, queueMicrotask(uie);
+ aC = e, queueMicrotask(Rie);
}
-}, FC = (e) => (t) => typeof t == "string" && t.startsWith(e), IC = /*@__PURE__*/ FC("--"), die = /*@__PURE__*/ FC("var(--"), LC = (e) => die(e) ? fie.test(e.split("/*")[0].trim()) : !1, fie = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;
-function RC(e) {
+}, sC = (e) => (t) => typeof t == "string" && t.startsWith(e), cC = /*@__PURE__*/ sC("--"), zie = /*@__PURE__*/ sC("var(--"), lC = (e) => zie(e) ? Bie.test(e.split("/*")[0].trim()) : !1, Bie = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;
+function uC(e) {
return typeof e == "string" && e.split("/*")[0].includes("var(--");
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/numbers/index.mjs
-var zC = {
+var dC = {
test: (e) => typeof e == "number",
parse: parseFloat,
transform: (e) => e
-}, BC = {
- ...zC,
- transform: (e) => $S(0, 1, e)
-}, VC = {
- ...zC,
+}, fC = {
+ ...dC,
+ transform: (e) => TS(0, 1, e)
+}, pC = {
+ ...dC,
default: 1
-}, HC = (e) => Math.round(e * 1e5) / 1e5, UC = /-?(?:\d+(?:\.\d+)?|\.\d+)/gu;
+}, mC = (e) => Math.round(e * 1e5) / 1e5, hC = /-?(?:\d+(?:\.\d+)?|\.\d+)/gu;
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/utils/is-nullish.mjs
-function pie(e) {
+function Vie(e) {
return e == null;
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/utils/single-color-regex.mjs
-var mie = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu, WC = (e, t) => (n) => !!(typeof n == "string" && mie.test(n) && n.startsWith(e) || t && !pie(n) && Object.prototype.hasOwnProperty.call(n, t)), GC = (e, t, n) => (r) => {
+var Hie = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu, gC = (e, t) => (n) => !!(typeof n == "string" && Hie.test(n) && n.startsWith(e) || t && !Vie(n) && Object.prototype.hasOwnProperty.call(n, t)), _C = (e, t, n) => (r) => {
if (typeof r != "string") return r;
- let [i, a, o, s] = r.match(UC);
+ let [i, a, o, s] = r.match(hC);
return {
[e]: parseFloat(i),
[t]: parseFloat(a),
[n]: parseFloat(o),
alpha: s === void 0 ? 1 : parseFloat(s)
};
-}, hie = (e) => $S(0, 255, e), KC = {
- ...zC,
- transform: (e) => Math.round(hie(e))
-}, qC = {
- test: /*@__PURE__*/ WC("rgb", "red"),
- parse: /*@__PURE__*/ GC("red", "green", "blue"),
- transform: ({ red: e, green: t, blue: n, alpha: r = 1 }) => "rgba(" + KC.transform(e) + ", " + KC.transform(t) + ", " + KC.transform(n) + ", " + HC(BC.transform(r)) + ")"
+}, Uie = (e) => TS(0, 255, e), vC = {
+ ...dC,
+ transform: (e) => Math.round(Uie(e))
+}, yC = {
+ test: /*@__PURE__*/ gC("rgb", "red"),
+ parse: /*@__PURE__*/ _C("red", "green", "blue"),
+ transform: ({ red: e, green: t, blue: n, alpha: r = 1 }) => "rgba(" + vC.transform(e) + ", " + vC.transform(t) + ", " + vC.transform(n) + ", " + mC(fC.transform(r)) + ")"
};
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/color/hex.mjs
-function gie(e) {
+function Wie(e) {
let t = "", n = "", r = "", i = "";
return e.length > 5 ? (t = e.substring(1, 3), n = e.substring(3, 5), r = e.substring(5, 7), i = e.substring(7, 9)) : (t = e.substring(1, 2), n = e.substring(2, 3), r = e.substring(3, 4), i = e.substring(4, 5), t += t, n += n, r += r, i += i), {
red: parseInt(t, 16),
@@ -28628,38 +28628,38 @@ function gie(e) {
alpha: i ? parseInt(i, 16) / 255 : 1
};
}
-var JC = {
- test: /*@__PURE__*/ WC("#"),
- parse: gie,
- transform: qC.transform
-}, YC = /* @__NO_SIDE_EFFECTS__ */ (e) => ({
+var bC = {
+ test: /*@__PURE__*/ gC("#"),
+ parse: Wie,
+ transform: yC.transform
+}, xC = /* @__NO_SIDE_EFFECTS__ */ (e) => ({
test: (t) => typeof t == "string" && t.endsWith(e) && t.split(" ").length === 1,
parse: parseFloat,
transform: (t) => `${t}${e}`
-}), XC = /*@__PURE__*/ YC("deg"), ZC = /*@__PURE__*/ YC("%"), QC = /*@__PURE__*/ YC("px"), _ie = /*@__PURE__*/ YC("vh"), vie = /*@__PURE__*/ YC("vw"), $C = {
- ...ZC,
- parse: (e) => ZC.parse(e) / 100,
- transform: (e) => ZC.transform(e * 100)
-}, ew = {
- test: /*@__PURE__*/ WC("hsl", "hue"),
- parse: /*@__PURE__*/ GC("hue", "saturation", "lightness"),
- transform: ({ hue: e, saturation: t, lightness: n, alpha: r = 1 }) => "hsla(" + Math.round(e) + ", " + ZC.transform(HC(t)) + ", " + ZC.transform(HC(n)) + ", " + HC(BC.transform(r)) + ")"
-}, tw = {
- test: (e) => qC.test(e) || JC.test(e) || ew.test(e),
- parse: (e) => qC.test(e) ? qC.parse(e) : ew.test(e) ? ew.parse(e) : JC.parse(e),
- transform: (e) => typeof e == "string" ? e : e.hasOwnProperty("red") ? qC.transform(e) : ew.transform(e),
+}), SC = /*@__PURE__*/ xC("deg"), CC = /*@__PURE__*/ xC("%"), wC = /*@__PURE__*/ xC("px"), TC = /*@__PURE__*/ xC("vh"), EC = /*@__PURE__*/ xC("vw"), DC = {
+ ...CC,
+ parse: (e) => CC.parse(e) / 100,
+ transform: (e) => CC.transform(e * 100)
+}, OC = {
+ test: /*@__PURE__*/ gC("hsl", "hue"),
+ parse: /*@__PURE__*/ _C("hue", "saturation", "lightness"),
+ transform: ({ hue: e, saturation: t, lightness: n, alpha: r = 1 }) => "hsla(" + Math.round(e) + ", " + CC.transform(mC(t)) + ", " + CC.transform(mC(n)) + ", " + mC(fC.transform(r)) + ")"
+}, kC = {
+ test: (e) => yC.test(e) || bC.test(e) || OC.test(e),
+ parse: (e) => yC.test(e) ? yC.parse(e) : OC.test(e) ? OC.parse(e) : bC.parse(e),
+ transform: (e) => typeof e == "string" ? e : e.hasOwnProperty("red") ? yC.transform(e) : OC.transform(e),
getAnimatableNone: (e) => {
- let t = tw.parse(e);
- return t.alpha = 0, tw.transform(t);
+ let t = kC.parse(e);
+ return t.alpha = 0, kC.transform(t);
}
-}, yie = /(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;
+}, AC = /(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/complex/index.mjs
-function bie(e) {
- return isNaN(e) && typeof e == "string" && (e.match(UC)?.length || 0) + (e.match(yie)?.length || 0) > 0;
+function jC(e) {
+ return isNaN(e) && typeof e == "string" && (e.match(hC)?.length || 0) + (e.match(AC)?.length || 0) > 0;
}
-var nw = "number", rw = "color", xie = "var", Sie = "var(", iw = "${}", Cie = /var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;
-function aw(e) {
+var MC = "number", NC = "color", PC = "var", FC = "var(", IC = "${}", LC = /var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;
+function RC(e) {
let t = e.toString(), n = [], r = {
color: [],
number: [],
@@ -28667,51 +28667,51 @@ function aw(e) {
}, i = [], a = 0;
return {
values: n,
- split: t.replace(Cie, (e) => (tw.test(e) ? (r.color.push(a), i.push(rw), n.push(tw.parse(e))) : e.startsWith(Sie) ? (r.var.push(a), i.push(xie), n.push(e)) : (r.number.push(a), i.push(nw), n.push(parseFloat(e))), ++a, iw)).split(iw),
+ split: t.replace(LC, (e) => (kC.test(e) ? (r.color.push(a), i.push(NC), n.push(kC.parse(e))) : e.startsWith(FC) ? (r.var.push(a), i.push(PC), n.push(e)) : (r.number.push(a), i.push(MC), n.push(parseFloat(e))), ++a, IC)).split(IC),
indexes: r,
types: i
};
}
-function wie(e) {
- return aw(e).values;
+function zC(e) {
+ return RC(e).values;
}
-function ow({ split: e, types: t }) {
+function BC({ split: e, types: t }) {
let n = e.length;
return (r) => {
let i = "";
for (let a = 0; a < n; a++) if (i += e[a], r[a] !== void 0) {
let e = t[a];
- i += e === nw ? HC(r[a]) : e === rw ? tw.transform(r[a]) : r[a];
+ i += e === MC ? mC(r[a]) : e === NC ? kC.transform(r[a]) : r[a];
}
return i;
};
}
-function Tie(e) {
- return ow(aw(e));
+function VC(e) {
+ return BC(RC(e));
}
-var Eie = (e) => typeof e == "number" ? 0 : tw.test(e) ? tw.getAnimatableNone(e) : e, Die = (e, t) => typeof e == "number" ? t?.trim().endsWith("/") ? e : 0 : Eie(e);
-function Oie(e) {
- let t = aw(e);
- return ow(t)(t.values.map((e, n) => Die(e, t.split[n])));
+var HC = (e) => typeof e == "number" ? 0 : kC.test(e) ? kC.getAnimatableNone(e) : e, UC = (e, t) => typeof e == "number" ? t?.trim().endsWith("/") ? e : 0 : HC(e);
+function WC(e) {
+ let t = RC(e);
+ return BC(t)(t.values.map((e, n) => UC(e, t.split[n])));
}
-var sw = {
- test: bie,
- parse: wie,
- createTransformer: Tie,
- getAnimatableNone: Oie
+var GC = {
+ test: jC,
+ parse: zC,
+ createTransformer: VC,
+ getAnimatableNone: WC
};
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/color/hsla-to-rgba.mjs
-function cw(e, t, n) {
+function KC(e, t, n) {
return n < 0 && (n += 1), n > 1 && --n, n < 1 / 6 ? e + (t - e) * 6 * n : n < 1 / 2 ? t : n < 2 / 3 ? e + (t - e) * (2 / 3 - n) * 6 : e;
}
-function kie({ hue: e, saturation: t, lightness: n, alpha: r }) {
+function qC({ hue: e, saturation: t, lightness: n, alpha: r }) {
e /= 360, t /= 100, n /= 100;
let i = 0, a = 0, o = 0;
if (!t) i = a = o = n;
else {
let r = n < .5 ? n * (1 + t) : n + t - n * t, s = 2 * n - r;
- i = cw(s, r, e + 1 / 3), a = cw(s, r, e), o = cw(s, r, e - 1 / 3);
+ i = KC(s, r, e + 1 / 3), a = KC(s, r, e), o = KC(s, r, e - 1 / 3);
}
return {
red: Math.round(i * 255),
@@ -28722,61 +28722,61 @@ function kie({ hue: e, saturation: t, lightness: n, alpha: r }) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/utils/mix/immediate.mjs
-function lw(e, t) {
+function JC(e, t) {
return (n) => n > 0 ? t : e;
}
//#endregion
//#region node_modules/motion-dom/dist/es/utils/mix/number.mjs
-var uw = (e, t, n) => e + (t - e) * n, dw = (e, t, n) => {
+var YC = (e, t, n) => e + (t - e) * n, XC = (e, t, n) => {
let r = e * e, i = n * (t * t - r) + r;
return i < 0 ? 0 : Math.sqrt(i);
-}, Aie = [
- JC,
- qC,
- ew
-], jie = (e) => Aie.find((t) => t.test(e));
-function fw(e) {
- let t = jie(e);
+}, ZC = [
+ bC,
+ yC,
+ OC
+], QC = (e) => ZC.find((t) => t.test(e));
+function $C(e) {
+ let t = QC(e);
if (`${e}`, !t) return !1;
let n = t.parse(e);
- return t === ew && (n = kie(n)), n;
+ return t === OC && (n = qC(n)), n;
}
-var pw = (e, t) => {
- let n = fw(e), r = fw(t);
- if (!n || !r) return lw(e, t);
+var ew = (e, t) => {
+ let n = $C(e), r = $C(t);
+ if (!n || !r) return JC(e, t);
let i = { ...n };
- return (e) => (i.red = dw(n.red, r.red, e), i.green = dw(n.green, r.green, e), i.blue = dw(n.blue, r.blue, e), i.alpha = uw(n.alpha, r.alpha, e), qC.transform(i));
-}, mw = /* @__PURE__ */ new Set(["none", "hidden"]);
-function Mie(e, t) {
- return mw.has(e) ? (n) => n <= 0 ? e : t : (n) => n >= 1 ? t : e;
+ return (e) => (i.red = XC(n.red, r.red, e), i.green = XC(n.green, r.green, e), i.blue = XC(n.blue, r.blue, e), i.alpha = YC(n.alpha, r.alpha, e), yC.transform(i));
+}, tw = /* @__PURE__ */ new Set(["none", "hidden"]);
+function nw(e, t) {
+ return tw.has(e) ? (n) => n <= 0 ? e : t : (n) => n >= 1 ? t : e;
}
//#endregion
//#region node_modules/motion-dom/dist/es/utils/mix/complex.mjs
-function Nie(e, t) {
- return (n) => uw(e, t, n);
+function rw(e, t) {
+ return (n) => YC(e, t, n);
}
-function hw(e) {
- return typeof e == "number" ? Nie : typeof e == "string" ? LC(e) ? lw : tw.test(e) ? pw : Iie : Array.isArray(e) ? gw : typeof e == "object" ? tw.test(e) ? pw : Pie : lw;
+function iw(e) {
+ return typeof e == "number" ? rw : typeof e == "string" ? lC(e) ? JC : kC.test(e) ? ew : cw : Array.isArray(e) ? aw : typeof e == "object" ? kC.test(e) ? ew : ow : JC;
}
-function gw(e, t) {
- let n = [...e], r = n.length, i = e.map((e, n) => hw(e)(e, t[n]));
+function aw(e, t) {
+ let n = [...e], r = n.length, i = e.map((e, n) => iw(e)(e, t[n]));
return (e) => {
for (let t = 0; t < r; t++) n[t] = i[t](e);
return n;
};
}
-function Pie(e, t) {
+function ow(e, t) {
let n = {
...e,
...t
}, r = {};
- for (let i in n) e[i] !== void 0 && t[i] !== void 0 && (r[i] = hw(e[i])(e[i], t[i]));
+ for (let i in n) e[i] !== void 0 && t[i] !== void 0 && (r[i] = iw(e[i])(e[i], t[i]));
return (e) => {
for (let t in r) n[t] = r[t](e);
return n;
};
}
-function Fie(e, t) {
+function sw(e, t) {
let n = [], r = {
color: 0,
var: 0,
@@ -28788,50 +28788,50 @@ function Fie(e, t) {
}
return n;
}
-var Iie = (e, t) => {
- let n = sw.createTransformer(t), r = aw(e), i = aw(t);
- return r.indexes.var.length === i.indexes.var.length && r.indexes.color.length === i.indexes.color.length && r.indexes.number.length >= i.indexes.number.length ? mw.has(e) && !i.values.length || mw.has(t) && !r.values.length ? Mie(e, t) : oC(gw(Fie(r, i), i.values), n) : (`${e}${t}`, lw(e, t));
+var cw = (e, t) => {
+ let n = GC.createTransformer(t), r = RC(e), i = RC(t);
+ return r.indexes.var.length === i.indexes.var.length && r.indexes.color.length === i.indexes.color.length && r.indexes.number.length >= i.indexes.number.length ? tw.has(e) && !i.values.length || tw.has(t) && !r.values.length ? nw(e, t) : MS(aw(sw(r, i), i.values), n) : (`${e}${t}`, JC(e, t));
};
//#endregion
//#region node_modules/motion-dom/dist/es/utils/mix/index.mjs
-function _w(e, t, n) {
- return typeof e == "number" && typeof t == "number" && typeof n == "number" ? uw(e, t, n) : hw(e)(e, t);
+function lw(e, t, n) {
+ return typeof e == "number" && typeof t == "number" && typeof n == "number" ? YC(e, t, n) : iw(e)(e, t);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/drivers/frame.mjs
-var Lie = (e) => {
+var uw = (e) => {
let t = ({ timestamp: t }) => e(t);
return {
- start: (e = !0) => kC.update(t, e),
- stop: () => AC(t),
- now: () => jC.isProcessing ? jC.timestamp : PC.now()
+ start: (e = !0) => tC.update(t, e),
+ stop: () => nC(t),
+ now: () => rC.isProcessing ? rC.timestamp : oC.now()
};
-}, vw = (e, t, n = 10) => {
+}, dw = (e, t, n = 10) => {
let r = "", i = Math.max(Math.round(t / n), 2);
for (let t = 0; t < i; t++) r += Math.round(e(t / (i - 1)) * 1e4) / 1e4 + ", ";
return `linear(${r.substring(0, r.length - 2)})`;
-}, yw = 2e4;
-function bw(e) {
+}, fw = 2e4;
+function pw(e) {
let t = 0, n = e.next(t);
for (; !n.done && t < 2e4;) t += 50, n = e.next(t);
return t >= 2e4 ? Infinity : t;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/generators/utils/create-generator-easing.mjs
-function Rie(e, t = 100, n) {
+function mw(e, t = 100, n) {
let r = n({
...e,
keyframes: [0, t]
- }), i = Math.min(bw(r), yw);
+ }), i = Math.min(pw(r), fw);
return {
type: "keyframes",
ease: (e) => r.next(i * e).value / t,
- duration: /* @__PURE__ */ uC(i)
+ duration: /* @__PURE__ */ IS(i)
};
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/generators/spring.mjs
-var xw = {
+var hw = {
stiffness: 100,
damping: 10,
mass: 1,
@@ -28852,31 +28852,31 @@ var xw = {
minDamping: .05,
maxDamping: 1
};
-function Sw(e, t) {
+function gw(e, t) {
return e * Math.sqrt(1 - t * t);
}
-var zie = 12;
-function Bie(e, t, n) {
+var _w = 12;
+function Gie(e, t, n) {
let r = n;
- for (let n = 1; n < zie; n++) r -= e(r) / t(r);
+ for (let n = 1; n < _w; n++) r -= e(r) / t(r);
return r;
}
-var Cw = .001;
-function Vie({ duration: e = xw.duration, bounce: t = xw.bounce, velocity: n = xw.velocity, mass: r = xw.mass }) {
+var vw = .001;
+function Kie({ duration: e = hw.duration, bounce: t = hw.bounce, velocity: n = hw.velocity, mass: r = hw.mass }) {
let i, a;
- xw.maxDuration;
+ hw.maxDuration;
let o = 1 - t;
- o = $S(xw.minDamping, xw.maxDamping, o), e = $S(xw.minDuration, xw.maxDuration, /* @__PURE__ */ uC(e)), o < 1 ? (i = (t) => {
- let r = t * o, i = r * e, a = r - n, s = Sw(t, o), c = Math.exp(-i);
- return Cw - a / s * c;
+ o = TS(hw.minDamping, hw.maxDamping, o), e = TS(hw.minDuration, hw.maxDuration, /* @__PURE__ */ IS(e)), o < 1 ? (i = (t) => {
+ let r = t * o, i = r * e, a = r - n, s = gw(t, o), c = Math.exp(-i);
+ return vw - a / s * c;
}, a = (t) => {
- let r = t * o * e, a = r * n + n, s = o ** 2 * t ** 2 * e, c = Math.exp(-r), l = Sw(t ** 2, o);
- return (-i(t) + Cw > 0 ? -1 : 1) * ((a - s) * c) / l;
+ let r = t * o * e, a = r * n + n, s = o ** 2 * t ** 2 * e, c = Math.exp(-r), l = gw(t ** 2, o);
+ return (-i(t) + vw > 0 ? -1 : 1) * ((a - s) * c) / l;
}) : (i = (t) => -.001 + Math.exp(-t * e) * ((t - n) * e + 1), a = (t) => Math.exp(-t * e) * ((n - t) * (e * e)));
- let s = 5 / e, c = Bie(i, a, s);
- if (e = /* @__PURE__ */ lC(e), isNaN(c)) return {
- stiffness: xw.stiffness,
- damping: xw.damping,
+ let s = 5 / e, c = Gie(i, a, s);
+ if (e = /* @__PURE__ */ FS(e), isNaN(c)) return {
+ stiffness: hw.stiffness,
+ damping: hw.damping,
duration: e
};
{
@@ -28888,47 +28888,47 @@ function Vie({ duration: e = xw.duration, bounce: t = xw.bounce, velocity: n = x
};
}
}
-var Hie = ["duration", "bounce"], Uie = [
+var qie = ["duration", "bounce"], Jie = [
"stiffness",
"damping",
"mass"
];
-function ww(e, t) {
+function yw(e, t) {
return t.some((t) => e[t] !== void 0);
}
-function Wie(e) {
+function Yie(e) {
let t = {
- velocity: xw.velocity,
- stiffness: xw.stiffness,
- damping: xw.damping,
- mass: xw.mass,
+ velocity: hw.velocity,
+ stiffness: hw.stiffness,
+ damping: hw.damping,
+ mass: hw.mass,
isResolvedFromDuration: !1,
...e
};
- if (!ww(e, Uie) && ww(e, Hie)) {
+ if (!yw(e, Jie) && yw(e, qie)) {
if (t.velocity = 0, e.visualDuration) {
- let n = e.visualDuration, r = 2 * Math.PI / (n * 1.2), i = r * r, a = 2 * $S(.05, 1, 1 - (e.bounce || 0)) * Math.sqrt(i);
+ let n = e.visualDuration, r = 2 * Math.PI / (n * 1.2), i = r * r, a = 2 * TS(.05, 1, 1 - (e.bounce || 0)) * Math.sqrt(i);
t = {
...t,
- mass: xw.mass,
+ mass: hw.mass,
stiffness: i,
damping: a
};
} else {
- let n = Vie({
+ let n = Kie({
...e,
velocity: 0
});
t = {
...t,
...n,
- mass: xw.mass
+ mass: hw.mass
}, t.isResolvedFromDuration = !0;
}
}
return t;
}
-function Tw(e = xw.visualDuration, t = xw.bounce) {
+function bw(e = hw.visualDuration, t = hw.bounce) {
let n = typeof e == "object" ? e : {
visualDuration: e,
keyframes: [0, 1],
@@ -28936,13 +28936,13 @@ function Tw(e = xw.visualDuration, t = xw.bounce) {
}, { restSpeed: r, restDelta: i } = n, a = n.keyframes[0], o = n.keyframes[n.keyframes.length - 1], s = {
done: !1,
value: a
- }, { stiffness: c, damping: l, mass: u, duration: d, velocity: f, isResolvedFromDuration: p } = Wie({
+ }, { stiffness: c, damping: l, mass: u, duration: d, velocity: f, isResolvedFromDuration: p } = Yie({
...n,
- velocity: -/* @__PURE__ */ uC(n.velocity || 0)
- }), m = f || 0, h = l / (2 * Math.sqrt(c * u)), g = o - a, _ = /* @__PURE__ */ uC(Math.sqrt(c / u)), v = Math.abs(g) < 5;
- r ||= v ? xw.restSpeed.granular : xw.restSpeed.default, i ||= v ? xw.restDelta.granular : xw.restDelta.default;
+ velocity: -/* @__PURE__ */ IS(n.velocity || 0)
+ }), m = f || 0, h = l / (2 * Math.sqrt(c * u)), g = o - a, _ = /* @__PURE__ */ IS(Math.sqrt(c / u)), v = Math.abs(g) < 5;
+ r ||= v ? hw.restSpeed.granular : hw.restSpeed.default, i ||= v ? hw.restDelta.granular : hw.restDelta.default;
let y, b, x, S, C, w;
- if (h < 1) x = Sw(_, h), S = (m + h * _ * g) / x, y = (e) => {
+ if (h < 1) x = gw(_, h), S = (m + h * _ * g) / x, y = (e) => {
let t = Math.exp(-h * _ * e);
return o - t * (S * Math.sin(x * e) + g * Math.cos(x * e));
}, C = h * _ * S + g * x, w = h * _ * g - S * x, b = (e) => Math.exp(-h * _ * e) * (C * Math.sin(x * e) + w * Math.cos(x * e));
@@ -28964,42 +28964,42 @@ function Tw(e = xw.visualDuration, t = xw.bounce) {
}
let T = {
calculatedDuration: p && d || null,
- velocity: (e) => /* @__PURE__ */ lC(b(e)),
+ velocity: (e) => /* @__PURE__ */ FS(b(e)),
next: (e) => {
if (!p && h < 1) {
- let t = Math.exp(-h * _ * e), n = Math.sin(x * e), a = Math.cos(x * e), c = o - t * (S * n + g * a), l = /* @__PURE__ */ lC(t * (C * n + w * a));
+ let t = Math.exp(-h * _ * e), n = Math.sin(x * e), a = Math.cos(x * e), c = o - t * (S * n + g * a), l = /* @__PURE__ */ FS(t * (C * n + w * a));
return s.done = Math.abs(l) <= r && Math.abs(o - c) <= i, s.value = s.done ? o : c, s;
}
let t = y(e);
if (p) s.done = e >= d;
else {
- let n = /* @__PURE__ */ lC(b(e));
+ let n = /* @__PURE__ */ FS(b(e));
s.done = Math.abs(n) <= r && Math.abs(o - t) <= i;
}
return s.value = s.done ? o : t, s;
},
toString: () => {
- let e = Math.min(bw(T), yw), t = vw((t) => T.next(e * t).value, e, 30);
+ let e = Math.min(pw(T), fw), t = dw((t) => T.next(e * t).value, e, 30);
return e + "ms " + t;
},
toTransition: () => {}
};
return T;
}
-Tw.applyToOptions = (e) => {
- let t = Rie(e, 100, Tw);
- return e.ease = t.ease, e.duration = /* @__PURE__ */ lC(t.duration), e.type = "keyframes", e;
+bw.applyToOptions = (e) => {
+ let t = mw(e, 100, bw);
+ return e.ease = t.ease, e.duration = /* @__PURE__ */ FS(t.duration), e.type = "keyframes", e;
};
//#endregion
//#region node_modules/motion-dom/dist/es/animation/generators/utils/velocity.mjs
-var Gie = 5;
-function Ew(e, t, n) {
- let r = Math.max(t - Gie, 0);
- return /* @__PURE__ */ dC(n - e(r), t - r);
+var Xie = 5;
+function xw(e, t, n) {
+ let r = Math.max(t - Xie, 0);
+ return /* @__PURE__ */ LS(n - e(r), t - r);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/generators/inertia.mjs
-function Dw({ keyframes: e, velocity: t = 0, power: n = .8, timeConstant: r = 325, bounceDamping: i = 10, bounceStiffness: a = 500, modifyTarget: o, min: s, max: c, restDelta: l = .5, restSpeed: u }) {
+function Sw({ keyframes: e, velocity: t = 0, power: n = .8, timeConstant: r = 325, bounceDamping: i = 10, bounceStiffness: a = 500, modifyTarget: o, min: s, max: c, restDelta: l = .5, restSpeed: u }) {
let d = e[0], f = {
done: !1,
value: d
@@ -29009,9 +29009,9 @@ function Dw({ keyframes: e, velocity: t = 0, power: n = .8, timeConstant: r = 32
let t = v(e), n = y(e);
f.done = Math.abs(t) <= l, f.value = f.done ? _ : n;
}, x, S, C = (e) => {
- p(f.value) && (x = e, S = Tw({
+ p(f.value) && (x = e, S = bw({
keyframes: [f.value, m(f.value)],
- velocity: Ew(y, e, f.value),
+ velocity: xw(y, e, f.value),
damping: i,
stiffness: a,
restDelta: l,
@@ -29028,59 +29028,59 @@ function Dw({ keyframes: e, velocity: t = 0, power: n = .8, timeConstant: r = 32
}
//#endregion
//#region node_modules/motion-dom/dist/es/utils/interpolate.mjs
-function Kie(e, t, n) {
- let r = [], i = n || eC.mix || _w, a = e.length - 1;
+function Zie(e, t, n) {
+ let r = [], i = n || ES.mix || lw, a = e.length - 1;
for (let n = 0; n < a; n++) {
let a = i(e[n], e[n + 1]);
- t && (a = oC(Array.isArray(t) ? t[n] || aC : t, a)), r.push(a);
+ t && (a = MS(Array.isArray(t) ? t[n] || jS : t, a)), r.push(a);
}
return r;
}
-function Ow(e, t, { clamp: n = !0, ease: r, mixer: i } = {}) {
+function Cw(e, t, { clamp: n = !0, ease: r, mixer: i } = {}) {
let a = e.length;
if (t.length, a === 1) return () => t[0];
if (a === 2 && t[0] === t[1]) return () => t[1];
let o = e[0] === e[1];
e[0] > e[a - 1] && (e = [...e].reverse(), t = [...t].reverse());
- let s = Kie(t, r, i), c = s.length, l = (n) => {
+ let s = Zie(t, r, i), c = s.length, l = (n) => {
if (o && n < e[0]) return t[0];
let r = 0;
if (c > 1) for (; r < e.length - 2 && !(n < e[r + 1]); r++);
- let i = /* @__PURE__ */ sC(e[r], e[r + 1], n);
+ let i = /* @__PURE__ */ NS(e[r], e[r + 1], n);
return s[r](i);
};
- return n ? (t) => l($S(e[0], e[a - 1], t)) : l;
+ return n ? (t) => l(TS(e[0], e[a - 1], t)) : l;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/offsets/fill.mjs
-function qie(e, t) {
+function Qie(e, t) {
let n = e[e.length - 1];
for (let r = 1; r <= t; r++) {
- let i = /* @__PURE__ */ sC(0, t, r);
- e.push(uw(n, 1, i));
+ let i = /* @__PURE__ */ NS(0, t, r);
+ e.push(YC(n, 1, i));
}
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/offsets/default.mjs
-function Jie(e) {
+function $ie(e) {
let t = [0];
- return qie(t, e.length - 1), t;
+ return Qie(t, e.length - 1), t;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/offsets/time.mjs
-function Yie(e, t) {
+function eae(e, t) {
return e.map((e) => e * t);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/generators/keyframes.mjs
-function Xie(e, t) {
- return e.map(() => t || CC).splice(0, e.length - 1);
+function tae(e, t) {
+ return e.map(() => t || YS).splice(0, e.length - 1);
}
-function kw({ duration: e = 300, keyframes: t, times: n, ease: r = "easeInOut" }) {
- let i = /* @__PURE__ */ oie(r) ? r.map(EC) : EC(r), a = {
+function ww({ duration: e = 300, keyframes: t, times: n, ease: r = "easeInOut" }) {
+ let i = /* @__PURE__ */ Pie(r) ? r.map(QS) : QS(r), a = {
done: !1,
value: t[0]
- }, o = Ow(Yie(n && n.length === t.length ? n : Jie(t), e), t, { ease: Array.isArray(i) ? i : Xie(t, i) });
+ }, o = Cw(eae(n && n.length === t.length ? n : $ie(t), e), t, { ease: Array.isArray(i) ? i : tae(t, i) });
return {
calculatedDuration: e,
next: (t) => (a.value = o(t), a.done = t >= e, a)
@@ -29088,26 +29088,26 @@ function kw({ duration: e = 300, keyframes: t, times: n, ease: r = "easeInOut" }
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/get-final.mjs
-var Zie = (e) => e !== null;
-function Aw(e, { repeat: t, repeatType: n = "loop" }, r, i = 1) {
- let a = e.filter(Zie), o = i < 0 || t && n !== "loop" && t % 2 == 1 ? 0 : a.length - 1;
+var nae = (e) => e !== null;
+function Tw(e, { repeat: t, repeatType: n = "loop" }, r, i = 1) {
+ let a = e.filter(nae), o = i < 0 || t && n !== "loop" && t % 2 == 1 ? 0 : a.length - 1;
return !o || r === void 0 ? a[o] : r;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/utils/replace-transition-type.mjs
-var Qie = {
- decay: Dw,
- inertia: Dw,
- tween: kw,
- keyframes: kw,
- spring: Tw
+var rae = {
+ decay: Sw,
+ inertia: Sw,
+ tween: ww,
+ keyframes: ww,
+ spring: bw
};
-function jw(e) {
- typeof e.type == "string" && (e.type = Qie[e.type]);
+function Ew(e) {
+ typeof e.type == "string" && (e.type = rae[e.type]);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/utils/WithPromise.mjs
-var Mw = class {
+var Dw = class {
constructor() {
this.updateFinished();
}
@@ -29125,21 +29125,21 @@ var Mw = class {
then(e, t) {
return this.finished.then(e, t);
}
-}, $ie = (e) => e / 100, Nw = class extends Mw {
+}, iae = (e) => e / 100, Ow = class extends Dw {
constructor(e) {
super(), this.state = "idle", this.startTime = null, this.isStopped = !1, this.currentTime = 0, this.holdTime = null, this.playbackSpeed = 1, this.delayState = {
done: !1,
value: void 0
}, this.stop = () => {
let { motionValue: e } = this.options;
- e && e.updatedAt !== PC.now() && this.tick(PC.now()), this.isStopped = !0, this.state !== "idle" && (this.teardown(), this.options.onStop?.());
+ e && e.updatedAt !== oC.now() && this.tick(oC.now()), this.isStopped = !0, this.state !== "idle" && (this.teardown(), this.options.onStop?.());
}, this.options = e, this.initAnimation(), this.play(), e.autoplay === !1 && this.pause();
}
initAnimation() {
let { options: e } = this;
- jw(e);
- let { type: t = kw, repeat: n = 0, repeatDelay: r = 0, repeatType: i, velocity: a = 0 } = e, { keyframes: o } = e, s = t || kw;
- s !== kw && typeof o[0] != "number" && (this.mixKeyframes = oC($ie, _w(o[0], o[1])), o = [0, 100]);
+ Ew(e);
+ let { type: t = ww, repeat: n = 0, repeatDelay: r = 0, repeatType: i, velocity: a = 0 } = e, { keyframes: o } = e, s = t || ww;
+ s !== ww && typeof o[0] != "number" && (this.mixKeyframes = MS(iae, lw(o[0], o[1])), o = [0, 100]);
let c = s({
...e,
keyframes: o
@@ -29148,7 +29148,7 @@ var Mw = class {
...e,
keyframes: [...o].reverse(),
velocity: -a
- })), c.calculatedDuration === null && (c.calculatedDuration = bw(c));
+ })), c.calculatedDuration === null && (c.calculatedDuration = pw(c));
let { calculatedDuration: l } = c;
this.calculatedDuration = l, this.resolvedDuration = l + r, this.totalDuration = this.resolvedDuration * (n + 1) - r, this.generator = c;
}
@@ -29166,54 +29166,54 @@ var Mw = class {
let v = this.currentTime, y = n;
if (u) {
let e = Math.min(this.currentTime, r) / o, t = Math.floor(e), n = e % 1;
- !n && e >= 1 && (n = 1), n === 1 && t--, t = Math.min(t, u + 1), t % 2 && (d === "reverse" ? (n = 1 - n, f && (n -= f / o)) : d === "mirror" && (y = a)), v = $S(0, 1, n) * o;
+ !n && e >= 1 && (n = 1), n === 1 && t--, t = Math.min(t, u + 1), t % 2 && (d === "reverse" ? (n = 1 - n, f && (n -= f / o)) : d === "mirror" && (y = a)), v = TS(0, 1, n) * o;
}
let b;
_ ? (this.delayState.value = l[0], b = this.delayState) : b = y.next(v), i && !_ && (b.value = i(b.value));
let { done: x } = b;
!_ && s !== null && (x = this.playbackSpeed >= 0 ? this.currentTime >= r : this.currentTime <= 0);
let S = this.holdTime === null && (this.state === "finished" || this.state === "running" && x);
- return S && p !== Dw && (b.value = Aw(l, this.options, h, this.speed)), m && m(b.value), S && this.finish(), b;
+ return S && p !== Sw && (b.value = Tw(l, this.options, h, this.speed)), m && m(b.value), S && this.finish(), b;
}
then(e, t) {
return this.finished.then(e, t);
}
get duration() {
- return /* @__PURE__ */ uC(this.calculatedDuration);
+ return /* @__PURE__ */ IS(this.calculatedDuration);
}
get iterationDuration() {
let { delay: e = 0 } = this.options || {};
- return this.duration + /* @__PURE__ */ uC(e);
+ return this.duration + /* @__PURE__ */ IS(e);
}
get time() {
- return /* @__PURE__ */ uC(this.currentTime);
+ return /* @__PURE__ */ IS(this.currentTime);
}
set time(e) {
- e = /* @__PURE__ */ lC(e), this.currentTime = e, this.startTime === null || this.holdTime !== null || this.playbackSpeed === 0 ? this.holdTime = e : this.driver && (this.startTime = this.driver.now() - e / this.playbackSpeed), this.driver ? this.driver.start(!1) : (this.startTime = 0, this.state = "paused", this.holdTime = e, this.tick(e));
+ e = /* @__PURE__ */ FS(e), this.currentTime = e, this.startTime === null || this.holdTime !== null || this.playbackSpeed === 0 ? this.holdTime = e : this.driver && (this.startTime = this.driver.now() - e / this.playbackSpeed), this.driver ? this.driver.start(!1) : (this.startTime = 0, this.state = "paused", this.holdTime = e, this.tick(e));
}
getGeneratorVelocity() {
let e = this.currentTime;
if (e <= 0) return this.options.velocity || 0;
if (this.generator.velocity) return this.generator.velocity(e);
let t = this.generator.next(e).value;
- return Ew((e) => this.generator.next(e).value, e, t);
+ return xw((e) => this.generator.next(e).value, e, t);
}
get speed() {
return this.playbackSpeed;
}
set speed(e) {
let t = this.playbackSpeed !== e;
- t && this.driver && this.updateTime(PC.now()), this.playbackSpeed = e, t && this.driver && (this.time = /* @__PURE__ */ uC(this.currentTime));
+ t && this.driver && this.updateTime(oC.now()), this.playbackSpeed = e, t && this.driver && (this.time = /* @__PURE__ */ IS(this.currentTime));
}
play() {
if (this.isStopped) return;
- let { driver: e = Lie, startTime: t } = this.options;
+ let { driver: e = uw, startTime: t } = this.options;
this.driver ||= e((e) => this.tick(e)), this.options.onPlay?.();
let n = this.driver.now();
this.state === "finished" ? (this.updateFinished(), this.startTime = n) : this.holdTime === null ? this.startTime ||= t ?? n : this.startTime = n - this.holdTime, this.state === "finished" && this.speed < 0 && (this.startTime += this.calculatedDuration), this.holdTime = null, this.state = "running", this.driver.start();
}
pause() {
- this.state = "paused", this.updateTime(PC.now()), this.holdTime = this.currentTime;
+ this.state = "paused", this.updateTime(oC.now()), this.holdTime = this.currentTime;
}
complete() {
this.state !== "running" && this.play(), this.state = "finished", this.holdTime = null;
@@ -29239,12 +29239,12 @@ var Mw = class {
};
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/utils/fill-wildcards.mjs
-function Pw(e) {
+function kw(e) {
for (let t = 1; t < e.length; t++) e[t] ?? (e[t] = e[t - 1]);
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/dom/parse-transform.mjs
-var Fw = (e) => e * 180 / Math.PI, Iw = (e) => Lw(Fw(Math.atan2(e[1], e[0]))), eae = {
+var Aw = (e) => e * 180 / Math.PI, jw = (e) => Mw(Aw(Math.atan2(e[1], e[0]))), aae = {
x: 4,
y: 5,
translateX: 4,
@@ -29252,54 +29252,54 @@ var Fw = (e) => e * 180 / Math.PI, Iw = (e) => Lw(Fw(Math.atan2(e[1], e[0]))), e
scaleX: 0,
scaleY: 3,
scale: (e) => (Math.abs(e[0]) + Math.abs(e[3])) / 2,
- rotate: Iw,
- rotateZ: Iw,
- skewX: (e) => Fw(Math.atan(e[1])),
- skewY: (e) => Fw(Math.atan(e[2])),
+ rotate: jw,
+ rotateZ: jw,
+ skewX: (e) => Aw(Math.atan(e[1])),
+ skewY: (e) => Aw(Math.atan(e[2])),
skew: (e) => (Math.abs(e[1]) + Math.abs(e[2])) / 2
-}, Lw = (e) => (e %= 360, e < 0 && (e += 360), e), Rw = Iw, zw = (e) => Math.sqrt(e[0] * e[0] + e[1] * e[1]), Bw = (e) => Math.sqrt(e[4] * e[4] + e[5] * e[5]), tae = {
+}, Mw = (e) => (e %= 360, e < 0 && (e += 360), e), Nw = jw, Pw = (e) => Math.sqrt(e[0] * e[0] + e[1] * e[1]), Fw = (e) => Math.sqrt(e[4] * e[4] + e[5] * e[5]), oae = {
x: 12,
y: 13,
z: 14,
translateX: 12,
translateY: 13,
translateZ: 14,
- scaleX: zw,
- scaleY: Bw,
- scale: (e) => (zw(e) + Bw(e)) / 2,
- rotateX: (e) => Lw(Fw(Math.atan2(e[6], e[5]))),
- rotateY: (e) => Lw(Fw(Math.atan2(-e[2], e[0]))),
- rotateZ: Rw,
- rotate: Rw,
- skewX: (e) => Fw(Math.atan(e[4])),
- skewY: (e) => Fw(Math.atan(e[1])),
+ scaleX: Pw,
+ scaleY: Fw,
+ scale: (e) => (Pw(e) + Fw(e)) / 2,
+ rotateX: (e) => Mw(Aw(Math.atan2(e[6], e[5]))),
+ rotateY: (e) => Mw(Aw(Math.atan2(-e[2], e[0]))),
+ rotateZ: Nw,
+ rotate: Nw,
+ skewX: (e) => Aw(Math.atan(e[4])),
+ skewY: (e) => Aw(Math.atan(e[1])),
skew: (e) => (Math.abs(e[1]) + Math.abs(e[4])) / 2
};
-function Vw(e) {
+function Iw(e) {
return +!!e.includes("scale");
}
-function Hw(e, t) {
- if (!e || e === "none") return Vw(t);
+function Lw(e, t) {
+ if (!e || e === "none") return Iw(t);
let n = e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u), r, i;
- if (n) r = tae, i = n;
+ if (n) r = oae, i = n;
else {
let t = e.match(/^matrix\(([-\d.e\s,]+)\)$/u);
- r = eae, i = t;
+ r = aae, i = t;
}
- if (!i) return Vw(t);
- let a = r[t], o = i[1].split(",").map(rae);
+ if (!i) return Iw(t);
+ let a = r[t], o = i[1].split(",").map(cae);
return typeof a == "function" ? a(o) : o[a];
}
-var nae = (e, t) => {
+var sae = (e, t) => {
let { transform: n = "none" } = getComputedStyle(e);
- return Hw(n, t);
+ return Lw(n, t);
};
-function rae(e) {
+function cae(e) {
return parseFloat(e.trim());
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/keys-transform.mjs
-var Uw = [
+var Rw = [
"transformPerspective",
"x",
"y",
@@ -29317,19 +29317,19 @@ var Uw = [
"skew",
"skewX",
"skewY"
-], Ww = /* @__PURE__ */ new Set([...Uw, "pathRotation"]), Gw = (e) => e === zC || e === QC, iae = /* @__PURE__ */ new Set([
+], zw = /* @__PURE__ */ new Set([...Rw, "pathRotation"]), Bw = (e) => e === dC || e === wC, lae = /* @__PURE__ */ new Set([
"x",
"y",
"z"
-]), aae = Uw.filter((e) => !iae.has(e));
-function oae(e) {
+]), uae = Rw.filter((e) => !lae.has(e));
+function dae(e) {
let t = [];
- return aae.forEach((n) => {
+ return uae.forEach((n) => {
let r = e.getValue(n);
r !== void 0 && (t.push([n, r.get()]), r.set(+!!n.startsWith("scale")));
}), t;
}
-var Kw = {
+var Vw = {
width: ({ x: e }, { paddingLeft: t = "0", paddingRight: n = "0", boxSizing: r }) => {
let i = e.max - e.min;
return r === "border-box" ? i : i - parseFloat(t) - parseFloat(n);
@@ -29342,18 +29342,18 @@ var Kw = {
left: (e, { left: t }) => parseFloat(t),
bottom: ({ y: e }, { top: t }) => parseFloat(t) + (e.max - e.min),
right: ({ x: e }, { left: t }) => parseFloat(t) + (e.max - e.min),
- x: (e, { transform: t }) => Hw(t, "x"),
- y: (e, { transform: t }) => Hw(t, "y")
+ x: (e, { transform: t }) => Lw(t, "x"),
+ y: (e, { transform: t }) => Lw(t, "y")
};
-Kw.translateX = Kw.x, Kw.translateY = Kw.y;
+Vw.translateX = Vw.x, Vw.translateY = Vw.y;
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/KeyframesResolver.mjs
-var qw = /* @__PURE__ */ new Set(), Jw = !1, Yw = !1, Xw = !1;
-function Zw() {
- if (Yw) {
- let e = Array.from(qw).filter((e) => e.needsMeasurement), t = new Set(e.map((e) => e.element)), n = /* @__PURE__ */ new Map();
+var Hw = /* @__PURE__ */ new Set(), Uw = !1, Ww = !1, Gw = !1;
+function Kw() {
+ if (Ww) {
+ let e = Array.from(Hw).filter((e) => e.needsMeasurement), t = new Set(e.map((e) => e.element)), n = /* @__PURE__ */ new Map();
t.forEach((e) => {
- let t = oae(e);
+ let t = dae(e);
t.length && (n.set(e, t), e.render());
}), e.forEach((e) => e.measureInitialState()), t.forEach((e) => {
e.render();
@@ -29365,22 +29365,22 @@ function Zw() {
e.suspendedScrollY !== void 0 && window.scrollTo(0, e.suspendedScrollY);
});
}
- Yw = !1, Jw = !1, qw.forEach((e) => e.complete(Xw)), qw.clear();
+ Ww = !1, Uw = !1, Hw.forEach((e) => e.complete(Gw)), Hw.clear();
}
-function Qw() {
- qw.forEach((e) => {
- e.readKeyframes(), e.needsMeasurement && (Yw = !0);
+function qw() {
+ Hw.forEach((e) => {
+ e.readKeyframes(), e.needsMeasurement && (Ww = !0);
});
}
-function sae() {
- Xw = !0, Qw(), Zw(), Xw = !1;
+function fae() {
+ Gw = !0, qw(), Kw(), Gw = !1;
}
-var $w = class {
+var Jw = class {
constructor(e, t, n, r, i, a = !1) {
this.state = "pending", this.isAsync = !1, this.needsMeasurement = !1, this.unresolvedKeyframes = [...e], this.onComplete = t, this.name = n, this.motionValue = r, this.element = i, this.isAsync = a;
}
scheduleResolve() {
- this.state = "scheduled", this.isAsync ? (qw.add(this), Jw || (Jw = !0, kC.read(Qw), kC.resolveKeyframes(Zw))) : (this.readKeyframes(), this.complete());
+ this.state = "scheduled", this.isAsync ? (Hw.add(this), Uw || (Uw = !0, tC.read(qw), tC.resolveKeyframes(Kw))) : (this.readKeyframes(), this.complete());
}
readKeyframes() {
let { unresolvedKeyframes: e, name: t, element: n, motionValue: r } = this;
@@ -29393,70 +29393,70 @@ var $w = class {
}
e[0] === void 0 && (e[0] = a), r && i === void 0 && r.set(e[0]);
}
- Pw(e);
+ kw(e);
}
setFinalKeyframe() {}
measureInitialState() {}
renderEndStyles() {}
measureEndState() {}
complete(e = !1) {
- this.state = "complete", this.onComplete(this.unresolvedKeyframes, this.finalKeyframe, e), qw.delete(this);
+ this.state = "complete", this.onComplete(this.unresolvedKeyframes, this.finalKeyframe, e), Hw.delete(this);
}
cancel() {
- this.state === "scheduled" && (qw.delete(this), this.state = "pending");
+ this.state === "scheduled" && (Hw.delete(this), this.state = "pending");
}
resume() {
this.state === "pending" && this.scheduleResolve();
}
-}, eT = (e) => e.startsWith("--");
+}, Yw = (e) => e.startsWith("--");
//#endregion
//#region node_modules/motion-dom/dist/es/render/dom/style-set.mjs
-function tT(e, t, n) {
- eT(t) ? e.style.setProperty(t, n) : e.style[t] = n;
+function Xw(e, t, n) {
+ Yw(t) ? e.style.setProperty(t, n) : e.style[t] = n;
}
//#endregion
//#region node_modules/motion-dom/dist/es/utils/supports/flags.mjs
-var cae = {};
+var pae = {};
//#endregion
//#region node_modules/motion-dom/dist/es/utils/supports/memo.mjs
-function nT(e, t) {
- let n = /* @__PURE__ */ iC(e);
- return () => cae[t] ?? n();
+function Zw(e, t) {
+ let n = /* @__PURE__ */ AS(e);
+ return () => pae[t] ?? n();
}
//#endregion
//#region node_modules/motion-dom/dist/es/utils/supports/scroll-timeline.mjs
-var lae = /* @__PURE__ */ nT(() => window.ScrollTimeline !== void 0, "scrollTimeline"), rT = /*@__PURE__*/ nT(() => {
+var mae = /* @__PURE__ */ Zw(() => window.ScrollTimeline !== void 0, "scrollTimeline"), Qw = /*@__PURE__*/ Zw(() => {
try {
document.createElement("div").animate({ opacity: 0 }, { easing: "linear(0, 1)" });
} catch {
return !1;
}
return !0;
-}, "linearEasing"), iT = ([e, t, n, r]) => `cubic-bezier(${e}, ${t}, ${n}, ${r})`, aT = {
+}, "linearEasing"), $w = ([e, t, n, r]) => `cubic-bezier(${e}, ${t}, ${n}, ${r})`, eT = {
linear: "linear",
ease: "ease",
easeIn: "ease-in",
easeOut: "ease-out",
easeInOut: "ease-in-out",
- circIn: /*@__PURE__*/ iT([
+ circIn: /*@__PURE__*/ $w([
0,
.65,
.55,
1
]),
- circOut: /*@__PURE__*/ iT([
+ circOut: /*@__PURE__*/ $w([
.55,
0,
1,
.45
]),
- backIn: /*@__PURE__*/ iT([
+ backIn: /*@__PURE__*/ $w([
.31,
.01,
.66,
-.59
]),
- backOut: /*@__PURE__*/ iT([
+ backOut: /*@__PURE__*/ $w([
.33,
1.53,
.69,
@@ -29465,15 +29465,15 @@ var lae = /* @__PURE__ */ nT(() => window.ScrollTimeline !== void 0, "scrollTime
};
//#endregion
//#region node_modules/motion-dom/dist/es/animation/waapi/easing/map-easing.mjs
-function oT(e, t) {
- if (e) return typeof e == "function" ? rT() ? vw(e, t) : "ease-out" : /* @__PURE__ */ wC(e) ? iT(e) : Array.isArray(e) ? e.map((e) => oT(e, t) || aT.easeOut) : aT[e];
+function tT(e, t) {
+ if (e) return typeof e == "function" ? Qw() ? dw(e, t) : "ease-out" : /* @__PURE__ */ XS(e) ? $w(e) : Array.isArray(e) ? e.map((e) => tT(e, t) || eT.easeOut) : eT[e];
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/waapi/start-waapi-animation.mjs
-function uae(e, t, n, { delay: r = 0, duration: i = 300, repeat: a = 0, repeatType: o = "loop", ease: s = "easeOut", times: c } = {}, l = void 0) {
+function hae(e, t, n, { delay: r = 0, duration: i = 300, repeat: a = 0, repeatType: o = "loop", ease: s = "easeOut", times: c } = {}, l = void 0) {
let u = { [t]: n };
c && (u.offset = c);
- let d = oT(s, i);
+ let d = tT(s, i);
Array.isArray(d) && (u.easing = d);
let f = {
delay: r,
@@ -29487,26 +29487,26 @@ function uae(e, t, n, { delay: r = 0, duration: i = 300, repeat: a = 0, repeatTy
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/generators/utils/is-generator.mjs
-function sT(e) {
+function nT(e) {
return typeof e == "function" && "applyToOptions" in e;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/waapi/utils/apply-generator.mjs
-function dae({ type: e, ...t }) {
- return sT(e) && rT() ? e.applyToOptions(t) : (t.duration ??= 300, t.ease ??= "easeOut", t);
+function gae({ type: e, ...t }) {
+ return nT(e) && Qw() ? e.applyToOptions(t) : (t.duration ??= 300, t.ease ??= "easeOut", t);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/NativeAnimation.mjs
-var cT = class extends Mw {
+var rT = class extends Dw {
constructor(e) {
if (super(), this.finishedTime = null, this.isStopped = !1, this.manualStartTime = null, !e) return;
let { element: t, name: n, keyframes: r, pseudoElement: i, allowFlatten: a = !1, finalKeyframe: o, onComplete: s } = e;
this.isPseudoElement = !!i, this.allowFlatten = a, this.options = e, e.type;
- let c = dae(e);
- this.animation = uae(t, n, r, c, i), c.autoplay === !1 && this.animation.pause(), this.animation.onfinish = () => {
+ let c = gae(e);
+ this.animation = hae(t, n, r, c, i), c.autoplay === !1 && this.animation.pause(), this.animation.onfinish = () => {
if (this.finishedTime = this.time, !i) {
- let e = Aw(r, this.options, o, this.speed);
- this.updateMotionValue && this.updateMotionValue(e), tT(t, n, e), this.animation.cancel();
+ let e = Tw(r, this.options, o, this.speed);
+ this.updateMotionValue && this.updateMotionValue(e), Xw(t, n, e), this.animation.cancel();
}
s?.(), this.notifyFinished();
};
@@ -29537,18 +29537,18 @@ var cT = class extends Mw {
}
get duration() {
let e = this.animation.effect?.getComputedTiming?.().duration || 0;
- return /* @__PURE__ */ uC(Number(e));
+ return /* @__PURE__ */ IS(Number(e));
}
get iterationDuration() {
let { delay: e = 0 } = this.options || {};
- return this.duration + /* @__PURE__ */ uC(e);
+ return this.duration + /* @__PURE__ */ IS(e);
}
get time() {
- return /* @__PURE__ */ uC(Number(this.animation.currentTime) || 0);
+ return /* @__PURE__ */ IS(Number(this.animation.currentTime) || 0);
}
set time(e) {
let t = this.finishedTime !== null;
- this.manualStartTime = null, this.finishedTime = null, this.animation.currentTime = /* @__PURE__ */ lC(e), t && this.animation.pause();
+ this.manualStartTime = null, this.finishedTime = null, this.animation.currentTime = /* @__PURE__ */ FS(e), t && this.animation.pause();
}
get speed() {
return this.animation.playbackRate;
@@ -29566,24 +29566,24 @@ var cT = class extends Mw {
this.manualStartTime = this.animation.startTime = e;
}
attachTimeline({ timeline: e, rangeStart: t, rangeEnd: n, observe: r }) {
- return this.allowFlatten && this.animation.effect?.updateTiming({ easing: "linear" }), this.animation.onfinish = null, e && lae() ? (this.animation.timeline = e, t && (this.animation.rangeStart = t), n && (this.animation.rangeEnd = n), aC) : r(this);
+ return this.allowFlatten && this.animation.effect?.updateTiming({ easing: "linear" }), this.animation.onfinish = null, e && mae() ? (this.animation.timeline = e, t && (this.animation.rangeStart = t), n && (this.animation.rangeEnd = n), jS) : r(this);
}
-}, lT = {
- anticipate: yC,
- backInOut: vC,
- circInOut: SC
+}, iT = {
+ anticipate: GS,
+ backInOut: WS,
+ circInOut: JS
};
-function fae(e) {
- return e in lT;
+function _ae(e) {
+ return e in iT;
}
-function pae(e) {
- typeof e.ease == "string" && fae(e.ease) && (e.ease = lT[e.ease]);
+function vae(e) {
+ typeof e.ease == "string" && _ae(e.ease) && (e.ease = iT[e.ease]);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/NativeAnimationExtended.mjs
-var uT = 10, mae = class extends cT {
+var aT = 10, yae = class extends rT {
constructor(e) {
- pae(e), jw(e), super(e), e.startTime !== void 0 && e.autoplay !== !1 && (this.startTime = e.startTime), this.options = e;
+ vae(e), Ew(e), super(e), e.startTime !== void 0 && e.autoplay !== !1 && (this.startTime = e.startTime), this.options = e;
}
updateMotionValue(e) {
let { motionValue: t, onUpdate: n, onComplete: r, element: i, ...a } = this.options;
@@ -29592,48 +29592,48 @@ var uT = 10, mae = class extends cT {
t.set(e);
return;
}
- let o = new Nw({
+ let o = new Ow({
...a,
autoplay: !1
- }), s = Math.max(uT, PC.now() - this.startTime), c = $S(0, uT, s - uT), l = o.sample(s).value, { name: u } = this.options;
- i && u && tT(i, u, l), t.setWithVelocity(o.sample(Math.max(0, s - c)).value, l, c), o.stop();
+ }), s = Math.max(aT, oC.now() - this.startTime), c = TS(0, aT, s - aT), l = o.sample(s).value, { name: u } = this.options;
+ i && u && Xw(i, u, l), t.setWithVelocity(o.sample(Math.max(0, s - c)).value, l, c), o.stop();
}
-}, dT = (e, t) => t !== "zIndex" && !!(typeof e == "number" || Array.isArray(e) || typeof e == "string" && (sw.test(e) || e === "0") && !e.startsWith("url("));
+}, oT = (e, t) => t !== "zIndex" && !!(typeof e == "number" || Array.isArray(e) || typeof e == "string" && (GC.test(e) || e === "0") && !e.startsWith("url("));
//#endregion
//#region node_modules/motion-dom/dist/es/animation/utils/can-animate.mjs
-function hae(e) {
+function bae(e) {
let t = e[0];
if (e.length === 1) return !0;
for (let n = 0; n < e.length; n++) if (e[n] !== t) return !0;
}
-function gae(e, t, n, r) {
+function xae(e, t, n, r) {
let i = e[0];
if (i === null) return !1;
if (t === "display" || t === "visibility") return !0;
- let a = e[e.length - 1], o = dT(i, t), s = dT(a, t);
- return `${t}${i}${a}${o ? a : i}`, !o || !s ? !1 : hae(e) || (n === "spring" || sT(n)) && r;
+ let a = e[e.length - 1], o = oT(i, t), s = oT(a, t);
+ return `${t}${i}${a}${o ? a : i}`, !o || !s ? !1 : bae(e) || (n === "spring" || nT(n)) && r;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/utils/make-animation-instant.mjs
-function fT(e) {
+function sT(e) {
e.duration = 0, e.type = "keyframes";
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/waapi/utils/accelerated-values.mjs
-var pT = /* @__PURE__ */ new Set([
+var cT = /* @__PURE__ */ new Set([
"opacity",
"clipPath",
"filter",
"transform",
"backgroundColor"
-]), _ae = /^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;
-function vae(e) {
- for (let t = 0; t < e.length; t++) if (typeof e[t] == "string" && _ae.test(e[t])) return !0;
+]), Sae = /^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;
+function Cae(e) {
+ for (let t = 0; t < e.length; t++) if (typeof e[t] == "string" && Sae.test(e[t])) return !0;
return !1;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/waapi/supports/waapi.mjs
-var yae = /* @__PURE__ */ new Set([
+var wae = /* @__PURE__ */ new Set([
"color",
"backgroundColor",
"outlineColor",
@@ -29644,20 +29644,20 @@ var yae = /* @__PURE__ */ new Set([
"borderRightColor",
"borderBottomColor",
"borderLeftColor"
-]), bae = /*@__PURE__*/ iC(() => Object.hasOwnProperty.call(Element.prototype, "animate"));
-function xae(e) {
+]), Tae = /*@__PURE__*/ AS(() => Object.hasOwnProperty.call(Element.prototype, "animate"));
+function Eae(e) {
let { motionValue: t, name: n, repeatDelay: r, repeatType: i, damping: a, type: o, keyframes: s } = e, c = t?.owner?.current;
if (!(c instanceof HTMLElement) && !(c instanceof SVGElement)) return !1;
let { onUpdate: l, transformTemplate: u } = t.owner.getProps();
- return bae() && n && (pT.has(n) || yae.has(n) && vae(s)) && (n !== "transform" || !u) && !l && !r && i !== "mirror" && a !== 0 && o !== "inertia";
+ return Tae() && n && (cT.has(n) || wae.has(n) && Cae(s)) && (n !== "transform" || !u) && !l && !r && i !== "mirror" && a !== 0 && o !== "inertia";
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/AsyncMotionValueAnimation.mjs
-var Sae = 40, Cae = class extends Mw {
+var Dae = 40, Oae = class extends Dw {
constructor({ autoplay: e = !0, delay: t = 0, type: n = "keyframes", repeat: r = 0, repeatDelay: i = 0, repeatType: a = "loop", keyframes: o, name: s, motionValue: c, element: l, ...u }) {
super(), this.stop = () => {
this._animation && (this._animation.stop(), this.stopTimeline?.()), this.keyframeResolver?.cancel();
- }, this.createdAt = PC.now();
+ }, this.createdAt = oC.now();
let d = {
autoplay: e,
delay: t,
@@ -29669,33 +29669,33 @@ var Sae = 40, Cae = class extends Mw {
motionValue: c,
element: l,
...u
- }, f = l?.KeyframeResolver || $w;
+ }, f = l?.KeyframeResolver || Jw;
this.keyframeResolver = new f(o, (e, t, n) => this.onKeyframesResolved(e, t, d, !n), s, c, l), this.keyframeResolver?.scheduleResolve();
}
onKeyframesResolved(e, t, n, r) {
this.keyframeResolver = void 0;
let { name: i, type: a, velocity: o, delay: s, isHandoff: c, onUpdate: l } = n;
- this.resolvedAt = PC.now();
+ this.resolvedAt = oC.now();
let u = !0;
- gae(e, i, a, o) || (u = !1, (eC.instantAnimations || !s) && l?.(Aw(e, n, t)), e[0] = e[e.length - 1], fT(n), n.repeat = 0);
+ xae(e, i, a, o) || (u = !1, (ES.instantAnimations || !s) && l?.(Tw(e, n, t)), e[0] = e[e.length - 1], sT(n), n.repeat = 0);
let d = {
- startTime: r ? this.resolvedAt && this.resolvedAt - this.createdAt > Sae ? this.resolvedAt : this.createdAt : void 0,
+ startTime: r ? this.resolvedAt && this.resolvedAt - this.createdAt > Dae ? this.resolvedAt : this.createdAt : void 0,
finalKeyframe: t,
...n,
keyframes: e
- }, f = u && !c && xae(d), p = d.motionValue?.owner?.current, m;
+ }, f = u && !c && Eae(d), p = d.motionValue?.owner?.current, m;
if (f) try {
- m = new mae({
+ m = new yae({
...d,
element: p
});
} catch {
- m = new Nw(d);
+ m = new Ow(d);
}
- else m = new Nw(d);
+ else m = new Ow(d);
m.finished.then(() => {
this.notifyFinished();
- }).catch(aC), this.pendingTimeline &&= (this.stopTimeline = m.attachTimeline(this.pendingTimeline), void 0), this._animation = m;
+ }).catch(jS), this.pendingTimeline &&= (this.stopTimeline = m.attachTimeline(this.pendingTimeline), void 0), this._animation = m;
}
get finished() {
return this._animation ? this.animation.finished : this._finished;
@@ -29704,7 +29704,7 @@ var Sae = 40, Cae = class extends Mw {
return this.finished.finally(e).then(() => {});
}
get animation() {
- return this._animation || (this.keyframeResolver?.resume(), sae()), this._animation;
+ return this._animation || (this.keyframeResolver?.resume(), fae()), this._animation;
}
get duration() {
return this.animation.duration;
@@ -29745,7 +29745,7 @@ var Sae = 40, Cae = class extends Mw {
cancel() {
this._animation && this.animation.cancel(), this.keyframeResolver?.cancel();
}
-}, wae = class {
+}, kae = class {
constructor(e) {
this.stop = () => this.runAll("stop"), this.animations = e.filter(Boolean);
}
@@ -29785,10 +29785,10 @@ var Sae = 40, Cae = class extends Mw {
return this.getAll("startTime");
}
get duration() {
- return mT(this.animations, "duration");
+ return lT(this.animations, "duration");
}
get iterationDuration() {
- return mT(this.animations, "iterationDuration");
+ return lT(this.animations, "iterationDuration");
}
runAll(e) {
this.animations.forEach((t) => t[e]());
@@ -29806,7 +29806,7 @@ var Sae = 40, Cae = class extends Mw {
this.runAll("complete");
}
};
-function mT(e, t) {
+function lT(e, t) {
let n = 0;
for (let r = 0; r < e.length; r++) {
let i = e[r][t];
@@ -29816,32 +29816,32 @@ function mT(e, t) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/GroupAnimationWithThen.mjs
-var Tae = class extends wae {
+var Aae = class extends kae {
then(e, t) {
return this.finished.finally(e).then(() => {});
}
-}, hT = /* @__PURE__ */ new WeakMap(), Eae = (e, t = "") => `${e}:${t}`;
-function Dae(e) {
- let t = hT.get(e);
- return t || (t = /* @__PURE__ */ new Map(), hT.set(e, t)), t;
+}, uT = /* @__PURE__ */ new WeakMap(), jae = (e, t = "") => `${e}:${t}`;
+function Mae(e) {
+ let t = uT.get(e);
+ return t || (t = /* @__PURE__ */ new Map(), uT.set(e, t)), t;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/utils/calc-child-stagger.mjs
-function gT(e, t, n, r = 0, i = 1) {
+function dT(e, t, n, r = 0, i = 1) {
let a = Array.from(e).sort((e, t) => e.sortNodePosition(t)).indexOf(t), o = e.size, s = (o - 1) * r;
return typeof n == "function" ? n(a, o) : i === 1 ? a * r : s - a * r;
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/index.mjs
-var _T = 30, Oae = (e) => !isNaN(parseFloat(e)), vT = { current: void 0 }, kae = class {
+var fT = 30, Nae = (e) => !isNaN(parseFloat(e)), pT = { current: void 0 }, Pae = class {
constructor(e, t = {}) {
this.canTrackVelocity = null, this.events = {}, this.updateAndNotify = (e) => {
- let t = PC.now();
+ let t = oC.now();
if (this.updatedAt !== t && this.setPrevFrameValue(), this.prev = this.current, this.setCurrent(e), this.current !== this.prev && (this.events.change?.notify(this.current), this.dependents)) for (let e of this.dependents) e.dirty();
}, this.hasAnimated = !1, this.setCurrent(e), this.owner = t.owner;
}
setCurrent(e) {
- this.current = e, this.updatedAt = PC.now(), this.canTrackVelocity === null && e !== void 0 && (this.canTrackVelocity = Oae(this.current));
+ this.current = e, this.updatedAt = oC.now(), this.canTrackVelocity === null && e !== void 0 && (this.canTrackVelocity = Nae(this.current));
}
setPrevFrameValue(e = this.current) {
this.prevFrameValue = e, this.prevUpdatedAt = this.updatedAt;
@@ -29850,10 +29850,10 @@ var _T = 30, Oae = (e) => !isNaN(parseFloat(e)), vT = { current: void 0 }, kae =
return this.on("change", e);
}
on(e, t) {
- this.events[e] || (this.events[e] = new cC());
+ this.events[e] || (this.events[e] = new PS());
let n = this.events[e].add(t);
return e === "change" ? () => {
- n(), kC.read(() => {
+ n(), tC.read(() => {
this.events.change.getSize() || this.stop();
});
} : n;
@@ -29883,16 +29883,16 @@ var _T = 30, Oae = (e) => !isNaN(parseFloat(e)), vT = { current: void 0 }, kae =
this.dependents && this.dependents.delete(e);
}
get() {
- return vT.current && vT.current.push(this), this.current;
+ return pT.current && pT.current.push(this), this.current;
}
getPrevious() {
return this.prev;
}
getVelocity() {
- let e = PC.now();
- if (!this.canTrackVelocity || this.prevFrameValue === void 0 || e - this.updatedAt > _T) return 0;
- let t = Math.min(this.updatedAt - this.prevUpdatedAt, _T);
- return /* @__PURE__ */ dC(parseFloat(this.current) - parseFloat(this.prevFrameValue), t);
+ let e = oC.now();
+ if (!this.canTrackVelocity || this.prevFrameValue === void 0 || e - this.updatedAt > fT) return 0;
+ let t = Math.min(this.updatedAt - this.prevUpdatedAt, fT);
+ return /* @__PURE__ */ LS(parseFloat(this.current) - parseFloat(this.prevFrameValue), t);
}
start(e) {
return this.stop(), new Promise((t) => {
@@ -29914,12 +29914,12 @@ var _T = 30, Oae = (e) => !isNaN(parseFloat(e)), vT = { current: void 0 }, kae =
this.dependents?.clear(), this.events.destroy?.notify(), this.clearListeners(), this.stop(), this.stopPassiveEffect && this.stopPassiveEffect();
}
};
-function yT(e, t) {
- return new kae(e, t);
+function mT(e, t) {
+ return new Pae(e, t);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/utils/resolve-transition.mjs
-function bT(e, t) {
+function hT(e, t) {
if (e?.inherit && t) {
let { inherit: n, ...r } = e;
return {
@@ -29931,26 +29931,26 @@ function bT(e, t) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/utils/get-value-transition.mjs
-function xT(e, t) {
+function gT(e, t) {
let n = e?.[t] ?? e?.default ?? e;
- return n === e ? n : bT(n, e);
+ return n === e ? n : hT(n, e);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/utils/default-transitions.mjs
-var Aae = {
+var Fae = {
type: "spring",
stiffness: 500,
damping: 25,
restSpeed: 10
-}, jae = (e) => ({
+}, Iae = (e) => ({
type: "spring",
stiffness: 550,
damping: e === 0 ? 2 * Math.sqrt(550) : 30,
restSpeed: 10
-}), Mae = {
+}), Lae = {
type: "keyframes",
duration: .8
-}, Nae = {
+}, Rae = {
type: "keyframes",
ease: [
.25,
@@ -29959,7 +29959,7 @@ var Aae = {
1
],
duration: .3
-}, Pae = (e, { keyframes: t }) => t.length > 2 ? Mae : Ww.has(e) ? e.startsWith("scale") ? jae(t[1]) : Aae : Nae, Fae = /* @__PURE__ */ new Set([
+}, zae = (e, { keyframes: t }) => t.length > 2 ? Lae : zw.has(e) ? e.startsWith("scale") ? Iae(t[1]) : Fae : Rae, Bae = /* @__PURE__ */ new Set([
"when",
"delay",
"delayChildren",
@@ -29971,15 +29971,15 @@ var Aae = {
"from",
"elapsed"
]);
-function Iae(e) {
- for (let t in e) if (!Fae.has(t)) return !0;
+function Vae(e) {
+ for (let t in e) if (!Bae.has(t)) return !0;
return !1;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/interfaces/motion-value.mjs
-var ST = (e, t, n, r = {}, i, a) => (o) => {
- let s = xT(r, e) || {}, c = s.delay || r.delay || 0, { elapsed: l = 0 } = r;
- l -= /* @__PURE__ */ lC(c);
+var _T = (e, t, n, r = {}, i, a) => (o) => {
+ let s = gT(r, e) || {}, c = s.delay || r.delay || 0, { elapsed: l = 0 } = r;
+ l -= /* @__PURE__ */ FS(c);
let u = {
keyframes: Array.isArray(n) ? n : [null, n],
ease: "easeOut",
@@ -29996,160 +29996,160 @@ var ST = (e, t, n, r = {}, i, a) => (o) => {
motionValue: t,
element: a ? void 0 : i
};
- Iae(s) || Object.assign(u, Pae(e, u)), u.duration &&= /* @__PURE__ */ lC(u.duration), u.repeatDelay &&= /* @__PURE__ */ lC(u.repeatDelay), u.from !== void 0 && (u.keyframes[0] = u.from);
+ Vae(s) || Object.assign(u, zae(e, u)), u.duration &&= /* @__PURE__ */ FS(u.duration), u.repeatDelay &&= /* @__PURE__ */ FS(u.repeatDelay), u.from !== void 0 && (u.keyframes[0] = u.from);
let d = !1;
- if ((u.type === !1 || u.duration === 0 && !u.repeatDelay) && (fT(u), u.delay === 0 && (d = !0)), (eC.instantAnimations || eC.skipAnimations || i?.shouldSkipAnimations || s.skipAnimations) && (d = !0, fT(u), u.delay = 0), u.allowFlatten = !s.type && !s.ease, d && !a && t.get() !== void 0) {
- let e = Aw(u.keyframes, s);
+ if ((u.type === !1 || u.duration === 0 && !u.repeatDelay) && (sT(u), u.delay === 0 && (d = !0)), (ES.instantAnimations || ES.skipAnimations || i?.shouldSkipAnimations || s.skipAnimations) && (d = !0, sT(u), u.delay = 0), u.allowFlatten = !s.type && !s.ease, d && !a && t.get() !== void 0) {
+ let e = Tw(u.keyframes, s);
if (e !== void 0) {
- kC.update(() => {
+ tC.update(() => {
u.onUpdate(e), u.onComplete();
});
return;
}
}
- return s.isSync ? new Nw(u) : new Cae(u);
-}, Lae = /^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;
-function Rae(e) {
- let t = Lae.exec(e);
+ return s.isSync ? new Ow(u) : new Oae(u);
+}, Hae = /^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;
+function Uae(e) {
+ let t = Hae.exec(e);
if (!t) return [,];
let [, n, r, i] = t;
return [`--${n ?? r}`, i];
}
-function CT(e, t, n = 1) {
+function vT(e, t, n = 1) {
`${e}`;
- let [r, i] = Rae(e);
+ let [r, i] = Uae(e);
if (!r) return;
let a = window.getComputedStyle(t).getPropertyValue(r);
if (a) {
let e = a.trim();
- return tC(e) ? parseFloat(e) : e;
+ return DS(e) ? parseFloat(e) : e;
}
- return LC(i) ? CT(i, t, n + 1) : i;
+ return lC(i) ? vT(i, t, n + 1) : i;
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/resolve-variants.mjs
-function wT(e) {
+function yT(e) {
let t = [{}, {}];
return e?.values.forEach((e, n) => {
t[0][n] = e.get(), t[1][n] = e.getVelocity();
}), t;
}
-function TT(e, t, n, r) {
+function bT(e, t, n, r) {
if (typeof t == "function") {
- let [i, a] = wT(r);
+ let [i, a] = yT(r);
t = t(n === void 0 ? e.custom : n, i, a);
}
if (typeof t == "string" && (t = e.variants && e.variants[t]), typeof t == "function") {
- let [i, a] = wT(r);
+ let [i, a] = yT(r);
t = t(n === void 0 ? e.custom : n, i, a);
}
return t;
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/resolve-dynamic-variants.mjs
-function ET(e, t, n) {
+function xT(e, t, n) {
let r = e.getProps();
- return TT(r, t, n === void 0 ? r.custom : n, e);
+ return bT(r, t, n === void 0 ? r.custom : n, e);
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/keys-position.mjs
-var DT = /* @__PURE__ */ new Set([
+var ST = /* @__PURE__ */ new Set([
"width",
"height",
"top",
"left",
"right",
"bottom",
- ...Uw
-]), OT = (e) => Array.isArray(e);
+ ...Rw
+]), CT = (e) => Array.isArray(e);
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/setters.mjs
-function zae(e, t, n) {
- e.hasValue(t) ? e.getValue(t).set(n) : e.addValue(t, yT(n));
+function Wae(e, t, n) {
+ e.hasValue(t) ? e.getValue(t).set(n) : e.addValue(t, mT(n));
}
-function Bae(e) {
- return OT(e) ? e[e.length - 1] || 0 : e;
+function Gae(e) {
+ return CT(e) ? e[e.length - 1] || 0 : e;
}
-function Vae(e, t) {
- let { transitionEnd: n = {}, transition: r = {}, ...i } = ET(e, t) || {};
+function Kae(e, t) {
+ let { transitionEnd: n = {}, transition: r = {}, ...i } = xT(e, t) || {};
i = {
...i,
...n
};
- for (let t in i) zae(e, t, Bae(i[t]));
+ for (let t in i) Wae(e, t, Gae(i[t]));
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/utils/is-motion-value.mjs
-var kT = (e) => !!(e && e.getVelocity);
+var wT = (e) => !!(e && e.getVelocity);
//#endregion
//#region node_modules/motion-dom/dist/es/value/will-change/is.mjs
-function Hae(e) {
- return !!(kT(e) && e.add);
+function qae(e) {
+ return !!(wT(e) && e.add);
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/will-change/add-will-change.mjs
-function AT(e, t) {
+function TT(e, t) {
let n = e.getValue("willChange");
- if (Hae(n)) return n.add(t);
- if (!n && eC.WillChange) {
- let n = new eC.WillChange("auto");
+ if (qae(n)) return n.add(t);
+ if (!n && ES.WillChange) {
+ let n = new ES.WillChange("auto");
e.addValue("willChange", n), n.add(t);
}
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/dom/utils/camel-to-dash.mjs
-function jT(e) {
+function ET(e) {
return e.replace(/([A-Z])/g, (e) => `-${e.toLowerCase()}`);
}
-var MT = "data-" + jT("framerAppearId");
+var DT = "data-" + ET("framerAppearId");
//#endregion
//#region node_modules/motion-dom/dist/es/animation/optimized-appear/get-appear-id.mjs
-function NT(e) {
- return e.props[MT];
+function OT(e) {
+ return e.props[DT];
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/interfaces/visual-element-target.mjs
-function Uae({ protectedKeys: e, needsAnimating: t }, n) {
+function Jae({ protectedKeys: e, needsAnimating: t }, n) {
let r = e.hasOwnProperty(n) && t[n] !== !0;
return t[n] = !1, r;
}
-function PT(e, t, { delay: n = 0, transitionOverride: r, type: i } = {}) {
+function kT(e, t, { delay: n = 0, transitionOverride: r, type: i } = {}) {
let { transition: a, transitionEnd: o, ...s } = t, c = e.getDefaultTransition();
- a = a ? bT(a, c) : c;
+ a = a ? hT(a, c) : c;
let l = a?.reduceMotion, u = a?.skipAnimations;
r && (a = r);
let d = [], f = i && e.animationState && e.animationState.getState()[i], p = a?.path;
p && p.animateVisualElement(e, s, a, n, d);
for (let t in s) {
let r = e.getValue(t, e.latestValues[t] ?? null), i = s[t];
- if (i === void 0 || f && Uae(f, t)) continue;
+ if (i === void 0 || f && Jae(f, t)) continue;
let o = {
delay: n,
- ...xT(a || {}, t)
+ ...gT(a || {}, t)
};
u && (o.skipAnimations = !0);
let c = r.get();
if (c !== void 0 && !r.isAnimating() && !Array.isArray(i) && i === c && !o.velocity) {
- kC.update(() => r.set(i));
+ tC.update(() => r.set(i));
continue;
}
let p = !1;
if (window.MotionHandoffAnimation) {
- let n = NT(e);
+ let n = OT(e);
if (n) {
- let e = window.MotionHandoffAnimation(n, t, kC);
+ let e = window.MotionHandoffAnimation(n, t, tC);
e !== null && (o.startTime = e, p = !0);
}
}
- AT(e, t);
+ TT(e, t);
let m = l ?? e.shouldReduceMotion;
- r.start(ST(t, r, i, m && DT.has(t) ? { type: !1 } : o, e, p));
+ r.start(_T(t, r, i, m && ST.has(t) ? { type: !1 } : o, e, p));
let h = r.animation;
h && d.push(h);
}
if (o) {
- let t = () => kC.update(() => {
- o && Vae(e, o);
+ let t = () => tC.update(() => {
+ o && Kae(e, o);
});
d.length ? Promise.all(d).then(t) : t();
}
@@ -30157,12 +30157,12 @@ function PT(e, t, { delay: n = 0, transitionOverride: r, type: i } = {}) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/interfaces/visual-element-variant.mjs
-function FT(e, t, n = {}) {
- let r = ET(e, t, n.type === "exit" ? e.presenceContext?.custom : void 0), { transition: i = e.getDefaultTransition() || {} } = r || {};
+function AT(e, t, n = {}) {
+ let r = xT(e, t, n.type === "exit" ? e.presenceContext?.custom : void 0), { transition: i = e.getDefaultTransition() || {} } = r || {};
n.transitionOverride && (i = n.transitionOverride);
- let a = r ? () => Promise.all(PT(e, r, n)) : () => Promise.resolve(), o = e.variantChildren && e.variantChildren.size ? (r = 0) => {
+ let a = r ? () => Promise.all(kT(e, r, n)) : () => Promise.resolve(), o = e.variantChildren && e.variantChildren.size ? (r = 0) => {
let { delayChildren: a = 0, staggerChildren: o, staggerDirection: s } = i;
- return Wae(e, t, r, a, o, s, n);
+ return Yae(e, t, r, a, o, s, n);
} : () => Promise.resolve(), { when: s } = i;
if (s) {
let [e, t] = s === "beforeChildren" ? [a, o] : [o, a];
@@ -30170,26 +30170,26 @@ function FT(e, t, n = {}) {
}
return Promise.all([a(), o(n.delay)]);
}
-function Wae(e, t, n = 0, r = 0, i = 0, a = 1, o) {
+function Yae(e, t, n = 0, r = 0, i = 0, a = 1, o) {
let s = [];
- for (let c of e.variantChildren) c.notify("AnimationStart", t), s.push(FT(c, t, {
+ for (let c of e.variantChildren) c.notify("AnimationStart", t), s.push(AT(c, t, {
...o,
- delay: n + (typeof r == "function" ? 0 : r) + gT(e.variantChildren, c, r, i, a)
+ delay: n + (typeof r == "function" ? 0 : r) + dT(e.variantChildren, c, r, i, a)
}).then(() => c.notify("AnimationComplete", t)));
return Promise.all(s);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/interfaces/visual-element.mjs
-function Gae(e, t, n = {}) {
+function Xae(e, t, n = {}) {
e.notify("AnimationStart", t);
let r;
if (Array.isArray(t)) {
- let i = t.map((t) => FT(e, t, n));
+ let i = t.map((t) => AT(e, t, n));
r = Promise.all(i);
- } else if (typeof t == "string") r = FT(e, t, n);
+ } else if (typeof t == "string") r = AT(e, t, n);
else {
- let i = typeof t == "function" ? ET(e, t, n.custom) : t;
- r = Promise.all(PT(e, i, n));
+ let i = typeof t == "function" ? xT(e, t, n.custom) : t;
+ r = Promise.all(kT(e, i, n));
}
return r.then(() => {
e.notify("AnimationComplete", t);
@@ -30197,176 +30197,176 @@ function Gae(e, t, n = {}) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/auto.mjs
-var Kae = {
+var Zae = {
test: (e) => e === "auto",
parse: (e) => e
-}, IT = (e) => (t) => t.test(e), LT = [
- zC,
- QC,
- ZC,
- XC,
- vie,
- _ie,
- Kae
-], RT = (e) => LT.find(IT(e));
+}, jT = (e) => (t) => t.test(e), MT = [
+ dC,
+ wC,
+ CC,
+ SC,
+ EC,
+ TC,
+ Zae
+], NT = (e) => MT.find(jT(e));
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/utils/is-none.mjs
-function qae(e) {
- return typeof e == "number" ? e === 0 : e === null || e === "none" || e === "0" || rC(e);
+function Qae(e) {
+ return typeof e == "number" ? e === 0 : e === null || e === "none" || e === "0" || kS(e);
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/complex/filter.mjs
-var Jae = /* @__PURE__ */ new Set([
+var $ae = /* @__PURE__ */ new Set([
"brightness",
"contrast",
"saturate",
"opacity"
]);
-function Yae(e) {
+function eoe(e) {
let [t, n] = e.slice(0, -1).split("(");
if (t === "drop-shadow") return e;
- let [r] = n.match(UC) || [];
+ let [r] = n.match(hC) || [];
if (!r) return e;
- let i = n.replace(r, ""), a = +!!Jae.has(t);
+ let i = n.replace(r, ""), a = +!!$ae.has(t);
return r !== n && (a *= 100), t + "(" + a + i + ")";
}
-var Xae = /\b([a-z-]*)\(.*?\)/gu, zT = {
- ...sw,
+var toe = /\b([a-z-]*)\(.*?\)/gu, PT = {
+ ...GC,
getAnimatableNone: (e) => {
- let t = e.match(Xae);
- return t ? t.map(Yae).join(" ") : e;
+ let t = e.match(toe);
+ return t ? t.map(eoe).join(" ") : e;
}
-}, BT = {
- ...sw,
+}, FT = {
+ ...GC,
getAnimatableNone: (e) => {
- let t = sw.parse(e);
- return sw.createTransformer(e)(t.map((e) => typeof e == "number" ? 0 : typeof e == "object" ? {
+ let t = GC.parse(e);
+ return GC.createTransformer(e)(t.map((e) => typeof e == "number" ? 0 : typeof e == "object" ? {
...e,
alpha: 1
} : e));
}
-}, VT = {
- ...zC,
+}, IT = {
+ ...dC,
transform: Math.round
-}, HT = {
- borderWidth: QC,
- borderTopWidth: QC,
- borderRightWidth: QC,
- borderBottomWidth: QC,
- borderLeftWidth: QC,
- borderRadius: QC,
- borderTopLeftRadius: QC,
- borderTopRightRadius: QC,
- borderBottomRightRadius: QC,
- borderBottomLeftRadius: QC,
- width: QC,
- maxWidth: QC,
- height: QC,
- maxHeight: QC,
- top: QC,
- right: QC,
- bottom: QC,
- left: QC,
- inset: QC,
- insetBlock: QC,
- insetBlockStart: QC,
- insetBlockEnd: QC,
- insetInline: QC,
- insetInlineStart: QC,
- insetInlineEnd: QC,
- padding: QC,
- paddingTop: QC,
- paddingRight: QC,
- paddingBottom: QC,
- paddingLeft: QC,
- paddingBlock: QC,
- paddingBlockStart: QC,
- paddingBlockEnd: QC,
- paddingInline: QC,
- paddingInlineStart: QC,
- paddingInlineEnd: QC,
- margin: QC,
- marginTop: QC,
- marginRight: QC,
- marginBottom: QC,
- marginLeft: QC,
- marginBlock: QC,
- marginBlockStart: QC,
- marginBlockEnd: QC,
- marginInline: QC,
- marginInlineStart: QC,
- marginInlineEnd: QC,
- fontSize: QC,
- backgroundPositionX: QC,
- backgroundPositionY: QC,
- rotate: XC,
- pathRotation: XC,
- rotateX: XC,
- rotateY: XC,
- rotateZ: XC,
- scale: VC,
- scaleX: VC,
- scaleY: VC,
- scaleZ: VC,
- skew: XC,
- skewX: XC,
- skewY: XC,
- distance: QC,
- translateX: QC,
- translateY: QC,
- translateZ: QC,
- x: QC,
- y: QC,
- z: QC,
- perspective: QC,
- transformPerspective: QC,
- opacity: BC,
- originX: $C,
- originY: $C,
- originZ: QC,
- zIndex: VT,
- fillOpacity: BC,
- strokeOpacity: BC,
- numOctaves: VT
-}, Zae = {
- ...HT,
- color: tw,
- backgroundColor: tw,
- outlineColor: tw,
- fill: tw,
- stroke: tw,
- borderColor: tw,
- borderTopColor: tw,
- borderRightColor: tw,
- borderBottomColor: tw,
- borderLeftColor: tw,
- filter: zT,
- WebkitFilter: zT,
- mask: BT,
- WebkitMask: BT
-}, UT = (e) => Zae[e], Qae = /*@__PURE__*/ new Set([zT, BT]);
-function WT(e, t) {
- let n = UT(e);
- return Qae.has(n) || (n = sw), n.getAnimatableNone ? n.getAnimatableNone(t) : void 0;
+}, LT = {
+ borderWidth: wC,
+ borderTopWidth: wC,
+ borderRightWidth: wC,
+ borderBottomWidth: wC,
+ borderLeftWidth: wC,
+ borderRadius: wC,
+ borderTopLeftRadius: wC,
+ borderTopRightRadius: wC,
+ borderBottomRightRadius: wC,
+ borderBottomLeftRadius: wC,
+ width: wC,
+ maxWidth: wC,
+ height: wC,
+ maxHeight: wC,
+ top: wC,
+ right: wC,
+ bottom: wC,
+ left: wC,
+ inset: wC,
+ insetBlock: wC,
+ insetBlockStart: wC,
+ insetBlockEnd: wC,
+ insetInline: wC,
+ insetInlineStart: wC,
+ insetInlineEnd: wC,
+ padding: wC,
+ paddingTop: wC,
+ paddingRight: wC,
+ paddingBottom: wC,
+ paddingLeft: wC,
+ paddingBlock: wC,
+ paddingBlockStart: wC,
+ paddingBlockEnd: wC,
+ paddingInline: wC,
+ paddingInlineStart: wC,
+ paddingInlineEnd: wC,
+ margin: wC,
+ marginTop: wC,
+ marginRight: wC,
+ marginBottom: wC,
+ marginLeft: wC,
+ marginBlock: wC,
+ marginBlockStart: wC,
+ marginBlockEnd: wC,
+ marginInline: wC,
+ marginInlineStart: wC,
+ marginInlineEnd: wC,
+ fontSize: wC,
+ backgroundPositionX: wC,
+ backgroundPositionY: wC,
+ rotate: SC,
+ pathRotation: SC,
+ rotateX: SC,
+ rotateY: SC,
+ rotateZ: SC,
+ scale: pC,
+ scaleX: pC,
+ scaleY: pC,
+ scaleZ: pC,
+ skew: SC,
+ skewX: SC,
+ skewY: SC,
+ distance: wC,
+ translateX: wC,
+ translateY: wC,
+ translateZ: wC,
+ x: wC,
+ y: wC,
+ z: wC,
+ perspective: wC,
+ transformPerspective: wC,
+ opacity: fC,
+ originX: DC,
+ originY: DC,
+ originZ: wC,
+ zIndex: IT,
+ fillOpacity: fC,
+ strokeOpacity: fC,
+ numOctaves: IT
+}, noe = {
+ ...LT,
+ color: kC,
+ backgroundColor: kC,
+ outlineColor: kC,
+ fill: kC,
+ stroke: kC,
+ borderColor: kC,
+ borderTopColor: kC,
+ borderRightColor: kC,
+ borderBottomColor: kC,
+ borderLeftColor: kC,
+ filter: PT,
+ WebkitFilter: PT,
+ mask: FT,
+ WebkitMask: FT
+}, RT = (e) => noe[e], roe = /*@__PURE__*/ new Set([PT, FT]);
+function zT(e, t) {
+ let n = RT(e);
+ return roe.has(n) || (n = GC), n.getAnimatableNone ? n.getAnimatableNone(t) : void 0;
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/utils/make-none-animatable.mjs
-var $ae = /* @__PURE__ */ new Set([
+var ioe = /* @__PURE__ */ new Set([
"auto",
"none",
"0"
]);
-function eoe(e, t, n) {
+function aoe(e, t, n) {
let r = 0, i;
for (; r < e.length && !i;) {
let t = e[r];
- typeof t == "string" && !$ae.has(t) && aw(t).values.length && (i = e[r]), r++;
+ typeof t == "string" && !ioe.has(t) && RC(t).values.length && (i = e[r]), r++;
}
- if (i && n) for (let r of t) e[r] = WT(n, i);
+ if (i && n) for (let r of t) e[r] = zT(n, i);
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/DOMKeyframesResolver.mjs
-var toe = class extends $w {
+var ooe = class extends Jw {
constructor(e, t, n, r, i) {
super(e, t, n, r, i, !0);
}
@@ -30376,34 +30376,34 @@ var toe = class extends $w {
super.readKeyframes();
for (let n = 0; n < e.length; n++) {
let r = e[n];
- if (typeof r == "string" && (r = r.trim(), LC(r))) {
- let i = CT(r, t.current);
+ if (typeof r == "string" && (r = r.trim(), lC(r))) {
+ let i = vT(r, t.current);
i !== void 0 && (e[n] = i), n === e.length - 1 && (this.finalKeyframe = r);
}
}
- if (this.resolveNoneKeyframes(), !DT.has(n) || e.length !== 2) return;
- let [r, i] = e, a = RT(r), o = RT(i);
- if (RC(r) !== RC(i) && Kw[n]) {
+ if (this.resolveNoneKeyframes(), !ST.has(n) || e.length !== 2) return;
+ let [r, i] = e, a = NT(r), o = NT(i);
+ if (uC(r) !== uC(i) && Vw[n]) {
this.needsMeasurement = !0;
return;
}
if (a !== o) {
- if (Gw(a) && Gw(o)) for (let t = 0; t < e.length; t++) {
+ if (Bw(a) && Bw(o)) for (let t = 0; t < e.length; t++) {
let n = e[t];
typeof n == "string" && (e[t] = parseFloat(n));
}
- else Kw[n] && (this.needsMeasurement = !0);
+ else Vw[n] && (this.needsMeasurement = !0);
}
}
resolveNoneKeyframes() {
let { unresolvedKeyframes: e, name: t } = this, n = [];
- for (let t = 0; t < e.length; t++) (e[t] === null || qae(e[t])) && n.push(t);
- n.length && eoe(e, n, t);
+ for (let t = 0; t < e.length; t++) (e[t] === null || Qae(e[t])) && n.push(t);
+ n.length && aoe(e, n, t);
}
measureInitialState() {
let { element: e, unresolvedKeyframes: t, name: n } = this;
if (!e || !e.current) return;
- n === "height" && (this.suspendedScrollY = window.pageYOffset), this.measuredOrigin = Kw[n](e.measureViewportBox(), window.getComputedStyle(e.current)), t[0] = this.measuredOrigin;
+ n === "height" && (this.suspendedScrollY = window.pageYOffset), this.measuredOrigin = Vw[n](e.measureViewportBox(), window.getComputedStyle(e.current)), t[0] = this.measuredOrigin;
let r = t[t.length - 1];
r !== void 0 && e.getValue(n, r).jump(r, !1);
}
@@ -30413,23 +30413,23 @@ var toe = class extends $w {
let r = e.getValue(t);
r && r.jump(this.measuredOrigin, !1);
let i = n.length - 1, a = n[i];
- n[i] = Kw[t](e.measureViewportBox(), window.getComputedStyle(e.current)), a !== null && this.finalKeyframe === void 0 && (this.finalKeyframe = a), this.removedTransforms?.length && this.removedTransforms.forEach(([t, n]) => {
+ n[i] = Vw[t](e.measureViewportBox(), window.getComputedStyle(e.current)), a !== null && this.finalKeyframe === void 0 && (this.finalKeyframe = a), this.removedTransforms?.length && this.removedTransforms.forEach(([t, n]) => {
e.getValue(t).set(n);
}), this.resolveNoneKeyframes();
}
-}, GT = [
+}, BT = [
"borderTopLeftRadius",
"borderTopRightRadius",
"borderBottomRightRadius",
"borderBottomLeftRadius"
-], noe = /* @__PURE__ */ new Set([
+], soe = /* @__PURE__ */ new Set([
"borderWidth",
"borderTopWidth",
"borderRightWidth",
"borderBottomWidth",
"borderLeftWidth",
"borderRadius",
- ...GT,
+ ...BT,
"width",
"maxWidth",
"height",
@@ -30473,12 +30473,12 @@ var toe = class extends $w {
]);
//#endregion
//#region node_modules/motion-dom/dist/es/animation/keyframes/utils/apply-px-defaults.mjs
-function roe(e, t) {
- for (let n = 0; n < e.length; n++) typeof e[n] == "number" && noe.has(t) && (e[n] = e[n] + "px");
+function coe(e, t) {
+ for (let n = 0; n < e.length; n++) typeof e[n] == "number" && soe.has(t) && (e[n] = e[n] + "px");
}
//#endregion
//#region node_modules/motion-dom/dist/es/utils/resolve-elements.mjs
-function KT(e, t, n) {
+function VT(e, t, n) {
if (e == null) return [];
if (e instanceof EventTarget) return [e];
if (typeof e == "string") {
@@ -30491,34 +30491,34 @@ function KT(e, t, n) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/utils/get-as-type.mjs
-var qT = (e, t) => t && typeof e == "number" ? t.transform(e) : e;
+var HT = (e, t) => t && typeof e == "number" ? t.transform(e) : e;
//#endregion
//#region node_modules/motion-dom/dist/es/utils/is-html-element.mjs
-function JT(e) {
- return nC(e) && "offsetHeight" in e && !("ownerSVGElement" in e);
+function UT(e) {
+ return OS(e) && "offsetHeight" in e && !("ownerSVGElement" in e);
}
//#endregion
//#region node_modules/motion-dom/dist/es/frameloop/microtask.mjs
-var { schedule: YT, cancel: ioe } = /* @__PURE__ */ OC(queueMicrotask, !1), XT = {
+var { schedule: WT, cancel: loe } = /* @__PURE__ */ eC(queueMicrotask, !1), GT = {
x: !1,
y: !1
};
-function ZT() {
- return XT.x || XT.y;
+function KT() {
+ return GT.x || GT.y;
}
//#endregion
//#region node_modules/motion-dom/dist/es/gestures/drag/state/set-active.mjs
-function aoe(e) {
- return e === "x" || e === "y" ? XT[e] ? null : (XT[e] = !0, () => {
- XT[e] = !1;
- }) : XT.x || XT.y ? null : (XT.x = XT.y = !0, () => {
- XT.x = XT.y = !1;
+function uoe(e) {
+ return e === "x" || e === "y" ? GT[e] ? null : (GT[e] = !0, () => {
+ GT[e] = !1;
+ }) : GT.x || GT.y ? null : (GT.x = GT.y = !0, () => {
+ GT.x = GT.y = !1;
});
}
//#endregion
//#region node_modules/motion-dom/dist/es/gestures/utils/setup.mjs
-function QT(e, t) {
- let n = KT(e), r = new AbortController();
+function qT(e, t) {
+ let n = VT(e), r = new AbortController();
return [
n,
{
@@ -30531,11 +30531,11 @@ function QT(e, t) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/gestures/hover.mjs
-function ooe(e) {
- return !(e.pointerType === "touch" || ZT());
+function doe(e) {
+ return !(e.pointerType === "touch" || KT());
}
-function soe(e, t, n = {}) {
- let [r, i, a] = QT(e, n);
+function foe(e, t, n = {}) {
+ let [r, i, a] = qT(e, n);
return r.forEach((e) => {
let n = !1, r = !1, a, o = () => {
e.removeEventListener("pointerleave", u);
@@ -30555,7 +30555,7 @@ function soe(e, t, n = {}) {
}
};
e.addEventListener("pointerenter", (n) => {
- if (!ooe(n)) return;
+ if (!doe(n)) return;
r = !1;
let o = t(e, n);
typeof o == "function" && (a = o, e.addEventListener("pointerleave", u, i));
@@ -30564,130 +30564,130 @@ function soe(e, t, n = {}) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/gestures/utils/is-node-or-child.mjs
-var $T = (e, t) => t ? e === t || $T(e, t.parentElement) : !1, eE = (e) => e.pointerType === "mouse" ? typeof e.button != "number" || e.button <= 0 : e.isPrimary !== !1, coe = /* @__PURE__ */ new Set([
+var JT = (e, t) => t ? e === t || JT(e, t.parentElement) : !1, YT = (e) => e.pointerType === "mouse" ? typeof e.button != "number" || e.button <= 0 : e.isPrimary !== !1, poe = /* @__PURE__ */ new Set([
"BUTTON",
"INPUT",
"SELECT",
"TEXTAREA",
"A"
]);
-function loe(e) {
- return coe.has(e.tagName) || e.isContentEditable === !0;
+function moe(e) {
+ return poe.has(e.tagName) || e.isContentEditable === !0;
}
-var uoe = /* @__PURE__ */ new Set([
+var hoe = /* @__PURE__ */ new Set([
"INPUT",
"SELECT",
"TEXTAREA"
]);
-function doe(e) {
- return uoe.has(e.tagName) || e.isContentEditable === !0;
+function goe(e) {
+ return hoe.has(e.tagName) || e.isContentEditable === !0;
}
//#endregion
//#region node_modules/motion-dom/dist/es/gestures/press/utils/state.mjs
-var tE = /* @__PURE__ */ new WeakSet();
+var XT = /* @__PURE__ */ new WeakSet();
//#endregion
//#region node_modules/motion-dom/dist/es/gestures/press/utils/keyboard.mjs
-function nE(e) {
+function ZT(e) {
return (t) => {
t.key === "Enter" && e(t);
};
}
-function rE(e, t) {
+function QT(e, t) {
e.dispatchEvent(new PointerEvent("pointer" + t, {
isPrimary: !0,
bubbles: !0
}));
}
-var foe = (e, t) => {
+var _oe = (e, t) => {
let n = e.currentTarget;
if (!n) return;
- let r = nE(() => {
- if (tE.has(n)) return;
- rE(n, "down");
- let e = nE(() => {
- rE(n, "up");
+ let r = ZT(() => {
+ if (XT.has(n)) return;
+ QT(n, "down");
+ let e = ZT(() => {
+ QT(n, "up");
});
- n.addEventListener("keyup", e, t), n.addEventListener("blur", () => rE(n, "cancel"), t);
+ n.addEventListener("keyup", e, t), n.addEventListener("blur", () => QT(n, "cancel"), t);
});
n.addEventListener("keydown", r, t), n.addEventListener("blur", () => n.removeEventListener("keydown", r), t);
};
//#endregion
//#region node_modules/motion-dom/dist/es/gestures/press/index.mjs
-function iE(e) {
- return eE(e) && !ZT();
+function $T(e) {
+ return YT(e) && !KT();
}
-var aE = /* @__PURE__ */ new WeakSet();
-function poe(e, t, n = {}) {
- let [r, i, a] = QT(e, n), o = (e) => {
+var eE = /* @__PURE__ */ new WeakSet();
+function voe(e, t, n = {}) {
+ let [r, i, a] = qT(e, n), o = (e) => {
let r = e.currentTarget;
- if (!iE(e) || aE.has(e)) return;
- tE.add(r), n.stopPropagation && aE.add(e);
+ if (!$T(e) || eE.has(e)) return;
+ XT.add(r), n.stopPropagation && eE.add(e);
let a = t(r, e), o = {
...i,
capture: !0
}, s = (e, t) => {
- window.removeEventListener("pointerup", c, o), window.removeEventListener("pointercancel", l, o), tE.has(r) && tE.delete(r), iE(e) && typeof a == "function" && a(e, { success: t });
+ window.removeEventListener("pointerup", c, o), window.removeEventListener("pointercancel", l, o), XT.has(r) && XT.delete(r), $T(e) && typeof a == "function" && a(e, { success: t });
}, c = (e) => {
- s(e, r === window || r === document || n.useGlobalTarget || $T(r, e.target));
+ s(e, r === window || r === document || n.useGlobalTarget || JT(r, e.target));
}, l = (e) => {
s(e, !1);
};
window.addEventListener("pointerup", c, o), window.addEventListener("pointercancel", l, o);
};
return r.forEach((e) => {
- (n.useGlobalTarget ? window : e).addEventListener("pointerdown", o, i), JT(e) && (e.addEventListener("focus", (e) => foe(e, i)), !loe(e) && !e.hasAttribute("tabindex") && (e.tabIndex = 0));
+ (n.useGlobalTarget ? window : e).addEventListener("pointerdown", o, i), UT(e) && (e.addEventListener("focus", (e) => _oe(e, i)), !moe(e) && !e.hasAttribute("tabindex") && (e.tabIndex = 0));
}), a;
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/dom/style-computed.mjs
-function oE(e, t) {
+function tE(e, t) {
let n = window.getComputedStyle(e);
- return eT(t) ? n.getPropertyValue(t) : n[t];
+ return Yw(t) ? n.getPropertyValue(t) : n[t];
}
//#endregion
//#region node_modules/motion-dom/dist/es/utils/is-svg-element.mjs
-function sE(e) {
- return nC(e) && "ownerSVGElement" in e;
+function nE(e) {
+ return OS(e) && "ownerSVGElement" in e;
}
//#endregion
//#region node_modules/motion-dom/dist/es/resize/handle-element.mjs
-var cE = /* @__PURE__ */ new WeakMap(), lE, uE = (e, t, n) => (r, i) => i && i[0] ? i[0][e + "Size"] : sE(r) && "getBBox" in r ? r.getBBox()[t] : r[n], moe = /*@__PURE__*/ uE("inline", "width", "offsetWidth"), hoe = /*@__PURE__*/ uE("block", "height", "offsetHeight");
-function goe({ target: e, borderBoxSize: t }) {
- cE.get(e)?.forEach((n) => {
+var rE = /* @__PURE__ */ new WeakMap(), iE, aE = (e, t, n) => (r, i) => i && i[0] ? i[0][e + "Size"] : nE(r) && "getBBox" in r ? r.getBBox()[t] : r[n], yoe = /*@__PURE__*/ aE("inline", "width", "offsetWidth"), boe = /*@__PURE__*/ aE("block", "height", "offsetHeight");
+function xoe({ target: e, borderBoxSize: t }) {
+ rE.get(e)?.forEach((n) => {
n(e, {
get width() {
- return moe(e, t);
+ return yoe(e, t);
},
get height() {
- return hoe(e, t);
+ return boe(e, t);
}
});
});
}
-function _oe(e) {
- e.forEach(goe);
+function Soe(e) {
+ e.forEach(xoe);
}
-function voe() {
- typeof ResizeObserver > "u" || (lE = new ResizeObserver(_oe));
+function Coe() {
+ typeof ResizeObserver > "u" || (iE = new ResizeObserver(Soe));
}
-function yoe(e, t) {
- lE || voe();
- let n = KT(e);
+function woe(e, t) {
+ iE || Coe();
+ let n = VT(e);
return n.forEach((e) => {
- let n = cE.get(e);
- n || (n = /* @__PURE__ */ new Set(), cE.set(e, n)), n.add(t), lE?.observe(e);
+ let n = rE.get(e);
+ n || (n = /* @__PURE__ */ new Set(), rE.set(e, n)), n.add(t), iE?.observe(e);
}), () => {
n.forEach((e) => {
- let n = cE.get(e);
- n?.delete(t), n?.size || lE?.unobserve(e);
+ let n = rE.get(e);
+ n?.delete(t), n?.size || iE?.unobserve(e);
});
};
}
//#endregion
//#region node_modules/motion-dom/dist/es/resize/handle-window.mjs
-var dE = /* @__PURE__ */ new Set(), fE;
-function boe() {
- fE = () => {
+var oE = /* @__PURE__ */ new Set(), sE;
+function Toe() {
+ sE = () => {
let e = {
get width() {
return window.innerWidth;
@@ -30696,49 +30696,49 @@ function boe() {
return window.innerHeight;
}
};
- dE.forEach((t) => t(e));
- }, window.addEventListener("resize", fE);
+ oE.forEach((t) => t(e));
+ }, window.addEventListener("resize", sE);
}
-function xoe(e) {
- return dE.add(e), fE || boe(), () => {
- dE.delete(e), !dE.size && typeof fE == "function" && (window.removeEventListener("resize", fE), fE = void 0);
+function Eoe(e) {
+ return oE.add(e), sE || Toe(), () => {
+ oE.delete(e), !oE.size && typeof sE == "function" && (window.removeEventListener("resize", sE), sE = void 0);
};
}
//#endregion
//#region node_modules/motion-dom/dist/es/resize/index.mjs
-function pE(e, t) {
- return typeof e == "function" ? xoe(e) : yoe(e, t);
+function cE(e, t) {
+ return typeof e == "function" ? Eoe(e) : woe(e, t);
}
//#endregion
//#region node_modules/motion-dom/dist/es/stats/buffer.mjs
-var mE = {
+var lE = {
value: null,
addProjectionMetrics: null
};
//#endregion
//#region node_modules/motion-dom/dist/es/utils/is-svg-svg-element.mjs
-function Soe(e) {
- return sE(e) && e.tagName === "svg";
+function Doe(e) {
+ return nE(e) && e.tagName === "svg";
}
//#endregion
//#region node_modules/motion-dom/dist/es/utils/transform.mjs
-function Coe(...e) {
- let t = !Array.isArray(e[0]), n = t ? 0 : -1, r = e[0 + n], i = e[1 + n], a = e[2 + n], o = e[3 + n], s = Ow(i, a, o);
+function Ooe(...e) {
+ let t = !Array.isArray(e[0]), n = t ? 0 : -1, r = e[0 + n], i = e[1 + n], a = e[2 + n], o = e[3 + n], s = Cw(i, a, o);
return t ? s(r) : s;
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/follow-value.mjs
-function woe(e, t, n = {}) {
+function koe(e, t, n = {}) {
let r = e.get(), i = null, a = r, o, s = typeof r == "string" ? r.replace(/[\d.-]/g, "") : void 0, c = () => {
i &&= (i.stop(), null), e.animation = void 0;
}, l = () => {
- let t = gE(e.get()), r = gE(a);
+ let t = dE(e.get()), r = dE(a);
if (t === r) {
c();
return;
}
let s = i ? i.getGeneratorVelocity() : e.getVelocity();
- c(), i = new Nw({
+ c(), i = new Ow({
keyframes: [t, r],
velocity: s,
type: "spring",
@@ -30753,10 +30753,10 @@ function woe(e, t, n = {}) {
});
};
if (e.attach((e, t) => {
- a = e, o = (e) => t(hE(e, s)), kC.postRender(u);
- }, c), kT(t)) {
+ a = e, o = (e) => t(uE(e, s)), tC.postRender(u);
+ }, c), wT(t)) {
let r = n.skipInitialAnimation === !0, i = t.on("change", (t) => {
- r ? (r = !1, e.jump(hE(t, s), !1)) : e.set(hE(t, s));
+ r ? (r = !1, e.jump(uE(t, s), !1)) : e.set(uE(t, s));
}), a = e.on("destroy", i);
return () => {
i(), a();
@@ -30764,46 +30764,46 @@ function woe(e, t, n = {}) {
}
return c;
}
-function hE(e, t) {
+function uE(e, t) {
return t ? e + t : e;
}
-function gE(e) {
+function dE(e) {
return typeof e == "number" ? e : parseFloat(e);
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/types/utils/find.mjs
-var Toe = [
- ...LT,
- tw,
- sw
-], Eoe = (e) => Toe.find(IT(e)), _E = () => ({
+var Aoe = [
+ ...MT,
+ kC,
+ GC
+], joe = (e) => Aoe.find(jT(e)), fE = () => ({
translate: 0,
scale: 1,
origin: 0,
originPoint: 0
-}), vE = () => ({
- x: _E(),
- y: _E()
-}), yE = () => ({
+}), pE = () => ({
+ x: fE(),
+ y: fE()
+}), mE = () => ({
min: 0,
max: 0
-}), bE = () => ({
- x: yE(),
- y: yE()
-}), Doe = /* @__PURE__ */ new WeakMap();
+}), hE = () => ({
+ x: mE(),
+ y: mE()
+}), Moe = /* @__PURE__ */ new WeakMap();
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/is-animation-controls.mjs
-function xE(e) {
+function gE(e) {
return typeof e == "object" && !!e && typeof e.start == "function";
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/is-variant-label.mjs
-function SE(e) {
+function _E(e) {
return typeof e == "string" || Array.isArray(e);
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/variant-props.mjs
-var CE = [
+var vE = [
"animate",
"whileInView",
"whileFocus",
@@ -30811,29 +30811,29 @@ var CE = [
"whileTap",
"whileDrag",
"exit"
-], wE = ["initial", ...CE];
+], yE = ["initial", ...vE];
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/is-controlling-variants.mjs
-function TE(e) {
- return xE(e.animate) || wE.some((t) => SE(e[t]));
+function bE(e) {
+ return gE(e.animate) || yE.some((t) => _E(e[t]));
}
-function EE(e) {
- return !!(TE(e) || e.variants);
+function xE(e) {
+ return !!(bE(e) || e.variants);
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/motion-values.mjs
-function Ooe(e, t, n) {
+function Noe(e, t, n) {
for (let r in t) {
let i = t[r], a = n[r];
- if (kT(i)) e.addValue(r, i);
- else if (kT(a)) e.addValue(r, yT(i, { owner: e }));
+ if (wT(i)) e.addValue(r, i);
+ else if (wT(a)) e.addValue(r, mT(i, { owner: e }));
else if (a !== i) {
if (e.hasValue(r)) {
let t = e.getValue(r);
t.liveStyle === !0 ? t.jump(i) : t.hasAnimated || t.set(i);
} else {
let t = e.getStaticValue(r);
- e.addValue(r, yT(t === void 0 ? i : t, { owner: e }));
+ e.addValue(r, mT(t === void 0 ? i : t, { owner: e }));
}
}
}
@@ -30842,18 +30842,18 @@ function Ooe(e, t, n) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/reduced-motion/state.mjs
-var DE = { current: null }, OE = { current: !1 }, koe = typeof window < "u";
-function kE() {
- if (OE.current = !0, koe) {
+var SE = { current: null }, CE = { current: !1 }, Poe = typeof window < "u";
+function wE() {
+ if (CE.current = !0, Poe) {
if (window.matchMedia) {
- let e = window.matchMedia("(prefers-reduced-motion)"), t = () => DE.current = e.matches;
+ let e = window.matchMedia("(prefers-reduced-motion)"), t = () => SE.current = e.matches;
e.addEventListener("change", t), t();
- } else DE.current = !1;
+ } else SE.current = !1;
}
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/VisualElement.mjs
-var AE = [
+var TE = [
"AnimationStart",
"AnimationComplete",
"Update",
@@ -30861,38 +30861,38 @@ var AE = [
"LayoutMeasure",
"LayoutAnimationStart",
"LayoutAnimationComplete"
-], jE = {};
-function ME(e) {
- jE = e;
+], EE = {};
+function DE(e) {
+ EE = e;
}
-function Aoe() {
- return jE;
+function Foe() {
+ return EE;
}
-var joe = class {
+var Ioe = class {
scrapeMotionValuesFromProps(e, t, n) {
return {};
}
constructor({ parent: e, props: t, presenceContext: n, reducedMotionConfig: r, skipAnimations: i, blockInitialAnimation: a, visualState: o }, s = {}) {
- this.current = null, this.children = /* @__PURE__ */ new Set(), this.isVariantNode = !1, this.isControllingVariants = !1, this.shouldReduceMotion = null, this.shouldSkipAnimations = !1, this.values = /* @__PURE__ */ new Map(), this.KeyframeResolver = $w, this.features = {}, this.valueSubscriptions = /* @__PURE__ */ new Map(), this.prevMotionValues = {}, this.hasBeenMounted = !1, this.events = {}, this.propEventSubscriptions = {}, this.notifyUpdate = () => this.notify("Update", this.latestValues), this.render = () => {
+ this.current = null, this.children = /* @__PURE__ */ new Set(), this.isVariantNode = !1, this.isControllingVariants = !1, this.shouldReduceMotion = null, this.shouldSkipAnimations = !1, this.values = /* @__PURE__ */ new Map(), this.KeyframeResolver = Jw, this.features = {}, this.valueSubscriptions = /* @__PURE__ */ new Map(), this.prevMotionValues = {}, this.hasBeenMounted = !1, this.events = {}, this.propEventSubscriptions = {}, this.notifyUpdate = () => this.notify("Update", this.latestValues), this.render = () => {
this.current && (this.triggerBuild(), this.renderInstance(this.current, this.renderState, this.props.style, this.projection));
}, this.renderScheduledAt = 0, this.scheduleRender = () => {
- let e = PC.now();
- this.renderScheduledAt < e && (this.renderScheduledAt = e, kC.render(this.render, !1, !0));
+ let e = oC.now();
+ this.renderScheduledAt < e && (this.renderScheduledAt = e, tC.render(this.render, !1, !0));
};
let { latestValues: c, renderState: l } = o;
- this.latestValues = c, this.baseTarget = { ...c }, this.initialValues = t.initial ? { ...c } : {}, this.renderState = l, this.parent = e, this.props = t, this.presenceContext = n, this.depth = e ? e.depth + 1 : 0, this.reducedMotionConfig = r, this.skipAnimationsConfig = i, this.options = s, this.blockInitialAnimation = !!a, this.isControllingVariants = TE(t), this.isVariantNode = EE(t), this.isVariantNode && (this.variantChildren = /* @__PURE__ */ new Set()), this.manuallyAnimateOnMount = !!(e && e.current);
+ this.latestValues = c, this.baseTarget = { ...c }, this.initialValues = t.initial ? { ...c } : {}, this.renderState = l, this.parent = e, this.props = t, this.presenceContext = n, this.depth = e ? e.depth + 1 : 0, this.reducedMotionConfig = r, this.skipAnimationsConfig = i, this.options = s, this.blockInitialAnimation = !!a, this.isControllingVariants = bE(t), this.isVariantNode = xE(t), this.isVariantNode && (this.variantChildren = /* @__PURE__ */ new Set()), this.manuallyAnimateOnMount = !!(e && e.current);
let { willChange: u, ...d } = this.scrapeMotionValuesFromProps(t, {}, this);
for (let e in d) {
let t = d[e];
- c[e] !== void 0 && kT(t) && t.set(c[e]);
+ c[e] !== void 0 && wT(t) && t.set(c[e]);
}
}
mount(e) {
if (this.hasBeenMounted) for (let e in this.initialValues) this.values.get(e)?.jump(this.initialValues[e]), this.latestValues[e] = this.initialValues[e];
- this.current = e, Doe.set(e, this), this.projection && !this.projection.instance && this.projection.mount(e), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((e, t) => this.bindToMotionValue(t, e)), this.reducedMotionConfig === "never" ? this.shouldReduceMotion = !1 : this.reducedMotionConfig === "always" ? this.shouldReduceMotion = !0 : (OE.current || kE(), this.shouldReduceMotion = DE.current), this.shouldSkipAnimations = this.skipAnimationsConfig ?? !1, this.parent?.addChild(this), this.update(this.props, this.presenceContext), this.hasBeenMounted = !0;
+ this.current = e, Moe.set(e, this), this.projection && !this.projection.instance && this.projection.mount(e), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((e, t) => this.bindToMotionValue(t, e)), this.reducedMotionConfig === "never" ? this.shouldReduceMotion = !1 : this.reducedMotionConfig === "always" ? this.shouldReduceMotion = !0 : (CE.current || wE(), this.shouldReduceMotion = SE.current), this.shouldSkipAnimations = this.skipAnimationsConfig ?? !1, this.parent?.addChild(this), this.update(this.props, this.presenceContext), this.hasBeenMounted = !0;
}
unmount() {
- this.projection && this.projection.unmount(), AC(this.notifyUpdate), AC(this.render), this.valueSubscriptions.forEach((e) => e()), this.valueSubscriptions.clear(), this.removeFromVariantTree && this.removeFromVariantTree(), this.parent?.removeChild(this);
+ this.projection && this.projection.unmount(), nC(this.notifyUpdate), nC(this.render), this.valueSubscriptions.forEach((e) => e()), this.valueSubscriptions.clear(), this.removeFromVariantTree && this.removeFromVariantTree(), this.parent?.removeChild(this);
for (let e in this.events) this.events[e].clear();
for (let e in this.features) {
let t = this.features[e];
@@ -30907,24 +30907,24 @@ var joe = class {
this.children.delete(e), this.enteringChildren && this.enteringChildren.delete(e);
}
bindToMotionValue(e, t) {
- if (this.valueSubscriptions.has(e) && this.valueSubscriptions.get(e)(), t.accelerate && pT.has(e) && this.current instanceof HTMLElement) {
- let { factory: n, keyframes: r, times: i, ease: a, duration: o } = t.accelerate, s = new cT({
+ if (this.valueSubscriptions.has(e) && this.valueSubscriptions.get(e)(), t.accelerate && cT.has(e) && this.current instanceof HTMLElement) {
+ let { factory: n, keyframes: r, times: i, ease: a, duration: o } = t.accelerate, s = new rT({
element: this.current,
name: e,
keyframes: r,
times: i,
ease: a,
- duration: /* @__PURE__ */ lC(o)
+ duration: /* @__PURE__ */ FS(o)
}), c = n(s);
this.valueSubscriptions.set(e, () => {
c(), s.cancel();
});
return;
}
- let n = Ww.has(e);
+ let n = zw.has(e);
n && this.onBindTransform && this.onBindTransform();
let r = t.on("change", (t) => {
- this.latestValues[e] = t, this.props.onUpdate && kC.preRender(this.notifyUpdate), n && this.projection && (this.projection.isTransformDirty = !0), this.scheduleRender();
+ this.latestValues[e] = t, this.props.onUpdate && tC.preRender(this.notifyUpdate), n && this.projection && (this.projection.isTransformDirty = !0), this.scheduleRender();
}), i;
typeof window < "u" && window.MotionCheckAppearSync && (i = window.MotionCheckAppearSync(this, e, t)), this.valueSubscriptions.set(e, () => {
r(), i && i();
@@ -30935,8 +30935,8 @@ var joe = class {
}
updateFeatures() {
let e = "animation";
- for (e in jE) {
- let t = jE[e];
+ for (e in EE) {
+ let t = EE[e];
if (!t) continue;
let { isEnabled: n, Feature: r } = t;
if (!this.features[e] && r && n(this.props) && (this.features[e] = new r(this)), this.features[e]) {
@@ -30949,7 +30949,7 @@ var joe = class {
this.build(this.renderState, this.latestValues, this.props);
}
measureViewportBox() {
- return this.current ? this.measureInstanceViewportBox(this.current, this.props) : bE();
+ return this.current ? this.measureInstanceViewportBox(this.current, this.props) : hE();
}
getStaticValue(e) {
return this.latestValues[e];
@@ -30959,13 +30959,13 @@ var joe = class {
}
update(e, t) {
(e.transformTemplate || this.props.transformTemplate) && this.scheduleRender(), this.prevProps = this.props, this.props = e, this.prevPresenceContext = this.presenceContext, this.presenceContext = t;
- for (let t = 0; t < AE.length; t++) {
- let n = AE[t];
+ for (let t = 0; t < TE.length; t++) {
+ let n = TE[t];
this.propEventSubscriptions[n] && (this.propEventSubscriptions[n](), delete this.propEventSubscriptions[n]);
let r = e["on" + n];
r && (this.propEventSubscriptions[n] = this.on(n, r));
}
- this.prevMotionValues = Ooe(this, this.scrapeMotionValuesFromProps(e, this.prevProps || {}, this), this.prevMotionValues), this.handleChildMotionValue && this.handleChildMotionValue();
+ this.prevMotionValues = Noe(this, this.scrapeMotionValuesFromProps(e, this.prevProps || {}, this), this.prevMotionValues), this.handleChildMotionValue && this.handleChildMotionValue();
}
getProps() {
return this.props;
@@ -31001,11 +31001,11 @@ var joe = class {
getValue(e, t) {
if (this.props.values && this.props.values[e]) return this.props.values[e];
let n = this.values.get(e);
- return n === void 0 && t !== void 0 && (n = yT(t === null ? void 0 : t, { owner: this }), this.addValue(e, n)), n;
+ return n === void 0 && t !== void 0 && (n = mT(t === null ? void 0 : t, { owner: this }), this.addValue(e, n)), n;
}
readValue(e, t) {
let n = this.latestValues[e] !== void 0 || !this.current ? this.latestValues[e] : this.getBaseTargetFromProps(this.props, e) ?? this.readValueFromInstance(this.current, e, this.options);
- return n != null && (typeof n == "string" && (tC(n) || rC(n)) ? n = parseFloat(n) : !Eoe(n) && sw.test(t) && (n = WT(e, t)), this.setBaseTarget(e, kT(n) ? n.get() : n)), kT(n) ? n.get() : n;
+ return n != null && (typeof n == "string" && (DS(n) || kS(n)) ? n = parseFloat(n) : !joe(n) && GC.test(t) && (n = zT(e, t)), this.setBaseTarget(e, wT(n) ? n.get() : n)), wT(n) ? n.get() : n;
}
setBaseTarget(e, t) {
this.baseTarget[e] = t;
@@ -31013,25 +31013,25 @@ var joe = class {
getBaseTarget(e) {
let { initial: t } = this.props, n;
if (typeof t == "string" || typeof t == "object") {
- let r = TT(this.props, t, this.presenceContext?.custom);
+ let r = bT(this.props, t, this.presenceContext?.custom);
r && (n = r[e]);
}
if (t && n !== void 0) return n;
let r = this.getBaseTargetFromProps(this.props, e);
- return r !== void 0 && !kT(r) ? r : this.initialValues[e] !== void 0 && n === void 0 ? void 0 : this.baseTarget[e];
+ return r !== void 0 && !wT(r) ? r : this.initialValues[e] !== void 0 && n === void 0 ? void 0 : this.baseTarget[e];
}
on(e, t) {
- return this.events[e] || (this.events[e] = new cC()), this.events[e].add(t);
+ return this.events[e] || (this.events[e] = new PS()), this.events[e].add(t);
}
notify(e, ...t) {
this.events[e] && this.events[e].notify(...t);
}
scheduleRenderMicrotask() {
- YT.render(this.render);
+ WT.render(this.render);
}
-}, NE = class extends joe {
+}, OE = class extends Ioe {
constructor() {
- super(...arguments), this.KeyframeResolver = toe;
+ super(...arguments), this.KeyframeResolver = ooe;
}
sortInstanceNodePosition(e, t) {
return e.compareDocumentPosition(t) & 2 ? 1 : -1;
@@ -31046,11 +31046,11 @@ var joe = class {
handleChildMotionValue() {
this.childSubscription && (this.childSubscription(), delete this.childSubscription);
let { children: e } = this.props;
- kT(e) && (this.childSubscription = e.on("change", (e) => {
+ wT(e) && (this.childSubscription = e.on("change", (e) => {
this.current && (this.current.textContent = `${e}`);
}));
}
-}, PE = class {
+}, kE = class {
constructor(e) {
this.isMounted = !1, this.node = e;
}
@@ -31058,7 +31058,7 @@ var joe = class {
};
//#endregion
//#region node_modules/motion-dom/dist/es/projection/geometry/conversion.mjs
-function FE({ top: e, left: t, right: n, bottom: r }) {
+function AE({ top: e, left: t, right: n, bottom: r }) {
return {
x: {
min: t,
@@ -31070,7 +31070,7 @@ function FE({ top: e, left: t, right: n, bottom: r }) {
}
};
}
-function Moe({ x: e, y: t }) {
+function Loe({ x: e, y: t }) {
return {
top: t.min,
right: e.max,
@@ -31078,7 +31078,7 @@ function Moe({ x: e, y: t }) {
left: e.min
};
}
-function Noe(e, t) {
+function Roe(e, t) {
if (!t) return e;
let n = t({
x: e.left,
@@ -31096,37 +31096,37 @@ function Noe(e, t) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/utils/has-transform.mjs
-function IE(e) {
+function jE(e) {
return e === void 0 || e === 1;
}
-function LE({ scale: e, scaleX: t, scaleY: n }) {
- return !IE(e) || !IE(t) || !IE(n);
+function ME({ scale: e, scaleX: t, scaleY: n }) {
+ return !jE(e) || !jE(t) || !jE(n);
}
-function RE(e) {
- return LE(e) || zE(e) || e.z || e.rotate || e.rotateX || e.rotateY || e.skewX || e.skewY;
+function NE(e) {
+ return ME(e) || PE(e) || e.z || e.rotate || e.rotateX || e.rotateY || e.skewX || e.skewY;
}
-function zE(e) {
- return BE(e.x) || BE(e.y);
+function PE(e) {
+ return FE(e.x) || FE(e.y);
}
-function BE(e) {
+function FE(e) {
return e && e !== "0%";
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/geometry/delta-apply.mjs
-function VE(e, t, n) {
+function IE(e, t, n) {
return n + t * (e - n);
}
-function HE(e, t, n, r, i) {
- return i !== void 0 && (e = VE(e, i, r)), VE(e, n, r) + t;
+function LE(e, t, n, r, i) {
+ return i !== void 0 && (e = IE(e, i, r)), IE(e, n, r) + t;
}
-function UE(e, t = 0, n = 1, r, i) {
- e.min = HE(e.min, t, n, r, i), e.max = HE(e.max, t, n, r, i);
+function RE(e, t = 0, n = 1, r, i) {
+ e.min = LE(e.min, t, n, r, i), e.max = LE(e.max, t, n, r, i);
}
-function WE(e, { x: t, y: n }) {
- UE(e.x, t.translate, t.scale, t.originPoint), UE(e.y, n.translate, n.scale, n.originPoint);
+function zE(e, { x: t, y: n }) {
+ RE(e.x, t.translate, t.scale, t.originPoint), RE(e.y, n.translate, n.scale, n.originPoint);
}
-var GE = .999999999999, KE = 1.0000000000001;
-function Poe(e, t, n, r = !1) {
+var BE = .999999999999, VE = 1.0000000000001;
+function zoe(e, t, n, r = !1) {
let i = n.length;
if (!i) return;
t.x = t.y = 1;
@@ -31134,44 +31134,44 @@ function Poe(e, t, n, r = !1) {
for (let s = 0; s < i; s++) {
a = n[s], o = a.projectionDelta;
let { visualElement: i } = a.options;
- i && i.props.style && i.props.style.display === "contents" || (r && a.options.layoutScroll && a.scroll && a !== a.root && (qE(e.x, -a.scroll.offset.x), qE(e.y, -a.scroll.offset.y)), o && (t.x *= o.x.scale, t.y *= o.y.scale, WE(e, o)), r && RE(a.latestValues) && XE(e, a.latestValues, a.layout?.layoutBox));
+ i && i.props.style && i.props.style.display === "contents" || (r && a.options.layoutScroll && a.scroll && a !== a.root && (HE(e.x, -a.scroll.offset.x), HE(e.y, -a.scroll.offset.y)), o && (t.x *= o.x.scale, t.y *= o.y.scale, zE(e, o)), r && NE(a.latestValues) && GE(e, a.latestValues, a.layout?.layoutBox));
}
- t.x < KE && t.x > GE && (t.x = 1), t.y < KE && t.y > GE && (t.y = 1);
+ t.x < VE && t.x > BE && (t.x = 1), t.y < VE && t.y > BE && (t.y = 1);
}
-function qE(e, t) {
+function HE(e, t) {
e.min += t, e.max += t;
}
-function JE(e, t, n, r, i = .5) {
- UE(e, t, n, uw(e.min, e.max, i), r);
+function UE(e, t, n, r, i = .5) {
+ RE(e, t, n, YC(e.min, e.max, i), r);
}
-function YE(e, t) {
+function WE(e, t) {
return typeof e == "string" ? parseFloat(e) / 100 * (t.max - t.min) : e;
}
-function XE(e, t, n) {
+function GE(e, t, n) {
let r = n ?? e;
- JE(e.x, YE(t.x, r.x), t.scaleX, t.scale, t.originX), JE(e.y, YE(t.y, r.y), t.scaleY, t.scale, t.originY);
+ UE(e.x, WE(t.x, r.x), t.scaleX, t.scale, t.originX), UE(e.y, WE(t.y, r.y), t.scaleY, t.scale, t.originY);
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/utils/measure.mjs
-function ZE(e, t) {
- return FE(Noe(e.getBoundingClientRect(), t));
+function KE(e, t) {
+ return AE(Roe(e.getBoundingClientRect(), t));
}
-function Foe(e, t, n) {
- let r = ZE(e, n), { scroll: i } = t;
- return i && (qE(r.x, i.offset.x), qE(r.y, i.offset.y)), r;
+function Boe(e, t, n) {
+ let r = KE(e, n), { scroll: i } = t;
+ return i && (HE(r.x, i.offset.x), HE(r.y, i.offset.y)), r;
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/html/utils/build-transform.mjs
-var Ioe = {
+var Voe = {
x: "translateX",
y: "translateY",
z: "translateZ",
transformPerspective: "perspective"
-}, Loe = Uw.length;
-function Roe(e, t, n) {
+}, Hoe = Rw.length;
+function Uoe(e, t, n) {
let r = "", i = !0;
- for (let a = 0; a < Loe; a++) {
- let o = Uw[a], s = e[o];
+ for (let a = 0; a < Hoe; a++) {
+ let o = Rw[a], s = e[o];
if (s === void 0) continue;
let c = !0;
if (typeof s == "number") c = s === +!!o.startsWith("scale");
@@ -31180,154 +31180,154 @@ function Roe(e, t, n) {
c = o.startsWith("scale") ? e === 1 : e === 0;
}
if (!c || n) {
- let e = qT(s, HT[o]);
+ let e = HT(s, LT[o]);
if (!c) {
i = !1;
- let t = Ioe[o] || o;
+ let t = Voe[o] || o;
r += `${t}(${e}) `;
}
n && (t[o] = e);
}
}
let a = e.pathRotation;
- return a && (i = !1, r += `rotate(${qT(a, HT.pathRotation)}) `), r = r.trim(), n ? r = n(t, i ? "" : r) : i && (r = "none"), r;
+ return a && (i = !1, r += `rotate(${HT(a, LT.pathRotation)}) `), r = r.trim(), n ? r = n(t, i ? "" : r) : i && (r = "none"), r;
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/html/utils/build-styles.mjs
-function QE(e, t, n) {
+function qE(e, t, n) {
let { style: r, vars: i, transformOrigin: a } = e, o = !1, s = !1;
for (let e in t) {
let n = t[e];
- if (Ww.has(e)) {
+ if (zw.has(e)) {
o = !0;
continue;
}
- if (IC(e)) {
+ if (cC(e)) {
i[e] = n;
continue;
}
{
- let t = qT(n, HT[e]);
+ let t = HT(n, LT[e]);
e.startsWith("origin") ? (s = !0, a[e] = t) : r[e] = t;
}
}
- if (t.transform || (o || n ? r.transform = Roe(t, e.transform, n) : r.transform &&= "none"), s) {
+ if (t.transform || (o || n ? r.transform = Uoe(t, e.transform, n) : r.transform &&= "none"), s) {
let { originX: e = "50%", originY: t = "50%", originZ: n = 0 } = a;
r.transformOrigin = `${e} ${t} ${n}`;
}
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/html/utils/render.mjs
-function $E(e, { style: t, vars: n }, r, i) {
+function JE(e, { style: t, vars: n }, r, i) {
let a = e.style, o;
for (o in t) a[o] = t[o];
for (o in i?.applyProjectionStyles(a, r), n) a.setProperty(o, n[o]);
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/styles/scale-border-radius.mjs
-function eD(e, t) {
+function YE(e, t) {
return t.max === t.min ? 0 : e / (t.max - t.min) * 100;
}
-var tD = { correct: (e, t) => {
+var XE = { correct: (e, t) => {
if (!t.target) return e;
if (typeof e == "string") {
- if (QC.test(e)) e = parseFloat(e);
+ if (wC.test(e)) e = parseFloat(e);
else return e;
}
- return `${eD(e, t.target.x)}% ${eD(e, t.target.y)}%`;
-} }, zoe = { correct: (e, { treeScale: t, projectionDelta: n }) => {
- let r = e, i = sw.parse(e);
+ return `${YE(e, t.target.x)}% ${YE(e, t.target.y)}%`;
+} }, Woe = { correct: (e, { treeScale: t, projectionDelta: n }) => {
+ let r = e, i = GC.parse(e);
if (i.length > 5) return r;
- let a = sw.createTransformer(e), o = typeof i[0] == "number" ? 0 : 1, s = n.x.scale * t.x, c = n.y.scale * t.y;
+ let a = GC.createTransformer(e), o = typeof i[0] == "number" ? 0 : 1, s = n.x.scale * t.x, c = n.y.scale * t.y;
i[0 + o] /= s, i[1 + o] /= c;
- let l = uw(s, c, .5);
+ let l = YC(s, c, .5);
return typeof i[2 + o] == "number" && (i[2 + o] /= l), typeof i[3 + o] == "number" && (i[3 + o] /= l), a(i);
-} }, nD = {
+} }, ZE = {
borderRadius: {
- ...tD,
- applyTo: [...GT]
+ ...XE,
+ applyTo: [...BT]
},
- borderTopLeftRadius: tD,
- borderTopRightRadius: tD,
- borderBottomLeftRadius: tD,
- borderBottomRightRadius: tD,
- boxShadow: zoe
+ borderTopLeftRadius: XE,
+ borderTopRightRadius: XE,
+ borderBottomLeftRadius: XE,
+ borderBottomRightRadius: XE,
+ boxShadow: Woe
};
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/is-forced-motion-value.mjs
-function rD(e, { layout: t, layoutId: n }) {
- return Ww.has(e) || e.startsWith("origin") || (t || n !== void 0) && (!!nD[e] || e === "opacity");
+function QE(e, { layout: t, layoutId: n }) {
+ return zw.has(e) || e.startsWith("origin") || (t || n !== void 0) && (!!ZE[e] || e === "opacity");
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/html/utils/scrape-motion-values.mjs
-function iD(e, t, n) {
+function $E(e, t, n) {
let r = e.style, i = t?.style, a = {};
if (!r) return a;
- for (let t in r) (kT(r[t]) || i && kT(i[t]) || rD(t, e) || n?.getValue(t)?.liveStyle !== void 0) && (a[t] = r[t]);
+ for (let t in r) (wT(r[t]) || i && wT(i[t]) || QE(t, e) || n?.getValue(t)?.liveStyle !== void 0) && (a[t] = r[t]);
return a;
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/html/HTMLVisualElement.mjs
-function Boe(e) {
+function Goe(e) {
return window.getComputedStyle(e);
}
-var Voe = class extends NE {
+var Koe = class extends OE {
constructor() {
- super(...arguments), this.type = "html", this.renderInstance = $E;
+ super(...arguments), this.type = "html", this.renderInstance = JE;
}
mount(e) {
e.style, super.mount(e);
}
readValueFromInstance(e, t) {
- if (Ww.has(t)) return this.projection?.isProjecting ? Vw(t) : nae(e, t);
+ if (zw.has(t)) return this.projection?.isProjecting ? Iw(t) : sae(e, t);
{
- let n = Boe(e), r = (IC(t) ? n.getPropertyValue(t) : n[t]) || 0;
+ let n = Goe(e), r = (cC(t) ? n.getPropertyValue(t) : n[t]) || 0;
return typeof r == "string" ? r.trim() : r;
}
}
measureInstanceViewportBox(e, { transformPagePoint: t }) {
- return ZE(e, t);
+ return KE(e, t);
}
build(e, t, n) {
- QE(e, t, n.transformTemplate);
+ qE(e, t, n.transformTemplate);
}
scrapeMotionValuesFromProps(e, t, n) {
- return iD(e, t, n);
+ return $E(e, t, n);
}
-}, Hoe = {
+}, qoe = {
offset: "stroke-dashoffset",
array: "stroke-dasharray"
-}, Uoe = {
+}, Joe = {
offset: "strokeDashoffset",
array: "strokeDasharray"
};
-function Woe(e, t, n = 1, r = 0, i = !0) {
+function Yoe(e, t, n = 1, r = 0, i = !0) {
e.pathLength = 1;
- let a = i ? Hoe : Uoe;
+ let a = i ? qoe : Joe;
e[a.offset] = `${-r}`, e[a.array] = `${t} ${n}`;
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/svg/utils/build-attrs.mjs
-var Goe = [
+var Xoe = [
"offsetDistance",
"offsetPath",
"offsetRotate",
"offsetAnchor"
];
-function aD(e, { attrX: t, attrY: n, attrScale: r, pathLength: i, pathSpacing: a = 1, pathOffset: o = 0, ...s }, c, l, u) {
- if (QE(e, s, l), c) {
+function eD(e, { attrX: t, attrY: n, attrScale: r, pathLength: i, pathSpacing: a = 1, pathOffset: o = 0, ...s }, c, l, u) {
+ if (qE(e, s, l), c) {
e.style.viewBox && (e.attrs.viewBox = e.style.viewBox);
return;
}
e.attrs = e.style, e.style = {};
let { attrs: d, style: f } = e;
d.transform && (f.transform = d.transform, delete d.transform), (f.transform || d.transformOrigin) && (f.transformOrigin = d.transformOrigin ?? "50% 50%", delete d.transformOrigin), f.transform && (f.transformBox = u?.transformBox ?? "fill-box", delete d.transformBox);
- for (let e of Goe) d[e] !== void 0 && (f[e] = d[e], delete d[e]);
- t !== void 0 && (d.x = t), n !== void 0 && (d.y = n), r !== void 0 && (d.scale = r), i !== void 0 && Woe(d, i, a, o, !1);
+ for (let e of Xoe) d[e] !== void 0 && (f[e] = d[e], delete d[e]);
+ t !== void 0 && (d.x = t), n !== void 0 && (d.y = n), r !== void 0 && (d.scale = r), i !== void 0 && Yoe(d, i, a, o, !1);
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/svg/utils/camel-case-attrs.mjs
-var oD = /* @__PURE__ */ new Set([
+var tD = /* @__PURE__ */ new Set([
"baseFrequency",
"diffuseConstant",
"kernelMatrix",
@@ -31351,68 +31351,68 @@ var oD = /* @__PURE__ */ new Set([
"startOffset",
"textLength",
"lengthAdjust"
-]), sD = (e) => typeof e == "string" && e.toLowerCase() === "svg";
+]), nD = (e) => typeof e == "string" && e.toLowerCase() === "svg";
//#endregion
//#region node_modules/motion-dom/dist/es/render/svg/utils/render.mjs
-function Koe(e, t, n, r) {
- $E(e, t, void 0, r);
- for (let n in t.attrs) e.setAttribute(oD.has(n) ? n : jT(n), t.attrs[n]);
+function Zoe(e, t, n, r) {
+ JE(e, t, void 0, r);
+ for (let n in t.attrs) e.setAttribute(tD.has(n) ? n : ET(n), t.attrs[n]);
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/svg/utils/scrape-motion-values.mjs
-function cD(e, t, n) {
- let r = iD(e, t, n);
- for (let n in e) if (kT(e[n]) || kT(t[n])) {
- let t = Uw.indexOf(n) === -1 ? n : "attr" + n.charAt(0).toUpperCase() + n.substring(1);
+function rD(e, t, n) {
+ let r = $E(e, t, n);
+ for (let n in e) if (wT(e[n]) || wT(t[n])) {
+ let t = Rw.indexOf(n) === -1 ? n : "attr" + n.charAt(0).toUpperCase() + n.substring(1);
r[t] = e[n];
}
return r;
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/svg/SVGVisualElement.mjs
-var qoe = class extends NE {
+var Qoe = class extends OE {
constructor() {
- super(...arguments), this.type = "svg", this.isSVGTag = !1, this.measureInstanceViewportBox = bE;
+ super(...arguments), this.type = "svg", this.isSVGTag = !1, this.measureInstanceViewportBox = hE;
}
getBaseTargetFromProps(e, t) {
return e[t];
}
readValueFromInstance(e, t) {
- if (Ww.has(t)) {
- let e = UT(t);
+ if (zw.has(t)) {
+ let e = RT(t);
return e && e.default || 0;
}
- return t = oD.has(t) ? t : jT(t), e.getAttribute(t);
+ return t = tD.has(t) ? t : ET(t), e.getAttribute(t);
}
scrapeMotionValuesFromProps(e, t, n) {
- return cD(e, t, n);
+ return rD(e, t, n);
}
build(e, t, n) {
- aD(e, t, this.isSVGTag, n.transformTemplate, n.style);
+ eD(e, t, this.isSVGTag, n.transformTemplate, n.style);
}
renderInstance(e, t, n, r) {
- Koe(e, t, n, r);
+ Zoe(e, t, n, r);
}
mount(e) {
- this.isSVGTag = sD(e.tagName), super.mount(e);
+ this.isSVGTag = nD(e.tagName), super.mount(e);
}
-}, Joe = wE.length;
-function lD(e) {
+}, $oe = yE.length;
+function iD(e) {
if (!e) return;
if (!e.isControllingVariants) {
- let t = e.parent && lD(e.parent) || {};
+ let t = e.parent && iD(e.parent) || {};
return e.props.initial !== void 0 && (t.initial = e.props.initial), t;
}
let t = {};
- for (let n = 0; n < Joe; n++) {
- let r = wE[n], i = e.props[r];
- (SE(i) || i === !1) && (t[r] = i);
+ for (let n = 0; n < $oe; n++) {
+ let r = yE[n], i = e.props[r];
+ (_E(i) || i === !1) && (t[r] = i);
}
return t;
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/shallow-compare.mjs
-function uD(e, t) {
+function aD(e, t) {
if (!Array.isArray(t)) return !1;
let n = t.length;
if (n !== e.length) return !1;
@@ -31421,13 +31421,13 @@ function uD(e, t) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/render/utils/animation-state.mjs
-var Yoe = [...CE].reverse(), Xoe = CE.length;
-function Zoe(e) {
- return (t) => Promise.all(t.map(({ animation: t, options: n }) => Gae(e, t, n)));
+var ese = [...vE].reverse(), tse = vE.length;
+function nse(e) {
+ return (t) => Promise.all(t.map(({ animation: t, options: n }) => Xae(e, t, n)));
}
-function Qoe(e) {
- let t = Zoe(e), n = fD(), r = !0, i = !1, a = (t) => (n, r) => {
- let i = ET(e, r, t === "exit" ? e.presenceContext?.custom : void 0);
+function rse(e) {
+ let t = nse(e), n = sD(), r = !0, i = !1, a = (t) => (n, r) => {
+ let i = xT(e, r, t === "exit" ? e.presenceContext?.custom : void 0);
if (i) {
let { transition: e, transitionEnd: t, ...r } = i;
n = {
@@ -31442,12 +31442,12 @@ function Qoe(e) {
t = n(e);
}
function s(o) {
- let { props: s } = e, c = lD(e.parent) || {}, l = [], u = /* @__PURE__ */ new Set(), d = {}, f = Infinity;
- for (let t = 0; t < Xoe; t++) {
- let p = Yoe[t], m = n[p], h = s[p] === void 0 ? c[p] : s[p], g = SE(h), _ = p === o ? m.isActive : null;
+ let { props: s } = e, c = iD(e.parent) || {}, l = [], u = /* @__PURE__ */ new Set(), d = {}, f = Infinity;
+ for (let t = 0; t < tse; t++) {
+ let p = ese[t], m = n[p], h = s[p] === void 0 ? c[p] : s[p], g = _E(h), _ = p === o ? m.isActive : null;
_ === !1 && (f = t);
let v = h === c[p] && h !== s[p] && g;
- if (v && (r || i) && e.manuallyAnimateOnMount && (v = !1), m.protectedKeys = { ...d }, !m.isActive && _ === null || !h && !m.prevProp || xE(h) || typeof h == "boolean") continue;
+ if (v && (r || i) && e.manuallyAnimateOnMount && (v = !1), m.protectedKeys = { ...d }, !m.isActive && _ === null || !h && !m.prevProp || gE(h) || typeof h == "boolean") continue;
if (p === "exit" && m.isActive && _ !== !0) {
m.prevResolvedValues && (d = {
...d,
@@ -31455,7 +31455,7 @@ function Qoe(e) {
});
continue;
}
- let y = $oe(m.prevProp, h), b = y || p === o && m.isActive && !v && g || t > f && g, x = !1, S = Array.isArray(h) ? h : [h], C = S.reduce(a(p), {});
+ let y = ise(m.prevProp, h), b = y || p === o && m.isActive && !v && g || t > f && g, x = !1, S = Array.isArray(h) ? h : [h], C = S.reduce(a(p), {});
_ === !1 && (C = {});
let { prevResolvedValues: w = {} } = m, T = {
...w,
@@ -31469,7 +31469,7 @@ function Qoe(e) {
let t = C[e], n = w[e];
if (d.hasOwnProperty(e)) continue;
let r = !1;
- r = OT(t) && OT(n) ? !uD(t, n) || y : t !== n, r ? t == null ? u.add(e) : E(e) : t !== void 0 && u.has(e) ? E(e) : m.protectedKeys[e] = !0;
+ r = CT(t) && CT(n) ? !aD(t, n) || y : t !== n, r ? t == null ? u.add(e) : E(e) : t !== void 0 && u.has(e) ? E(e) : m.protectedKeys[e] = !0;
}
m.prevProp = h, m.prevResolvedValues = C, m.isActive && (d = {
...d,
@@ -31479,10 +31479,10 @@ function Qoe(e) {
b && (!D || x) && l.push(...S.map((t) => {
let n = { type: p };
if (typeof t == "string" && (r || i) && !D && e.manuallyAnimateOnMount && e.parent) {
- let { parent: r } = e, i = ET(r, t);
+ let { parent: r } = e, i = xT(r, t);
if (r.enteringChildren && i) {
let { delayChildren: t } = i.transition || {};
- n.delay = gT(r.enteringChildren, e, t);
+ n.delay = dT(r.enteringChildren, e, t);
}
}
return {
@@ -31494,7 +31494,7 @@ function Qoe(e) {
if (u.size) {
let t = {};
if (typeof s.initial != "boolean") {
- let n = ET(e, Array.isArray(s.initial) ? s.initial[0] : s.initial);
+ let n = xT(e, Array.isArray(s.initial) ? s.initial[0] : s.initial);
n && n.transition && (t.transition = n.transition);
}
u.forEach((n) => {
@@ -31518,14 +31518,14 @@ function Qoe(e) {
setAnimateFunction: o,
getState: () => n,
reset: () => {
- n = fD(), i = !0;
+ n = sD(), i = !0;
}
};
}
-function $oe(e, t) {
- return typeof t == "string" ? t !== e : Array.isArray(t) ? !uD(t, e) : !1;
+function ise(e, t) {
+ return typeof t == "string" ? t !== e : Array.isArray(t) ? !aD(t, e) : !1;
}
-function dD(e = !1) {
+function oD(e = !1) {
return {
isActive: e,
protectedKeys: {},
@@ -31533,115 +31533,115 @@ function dD(e = !1) {
prevResolvedValues: {}
};
}
-function fD() {
+function sD() {
return {
- animate: dD(!0),
- whileInView: dD(),
- whileHover: dD(),
- whileTap: dD(),
- whileDrag: dD(),
- whileFocus: dD(),
- exit: dD()
+ animate: oD(!0),
+ whileInView: oD(),
+ whileHover: oD(),
+ whileTap: oD(),
+ whileDrag: oD(),
+ whileFocus: oD(),
+ exit: oD()
};
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/geometry/copy.mjs
-function pD(e, t) {
+function cD(e, t) {
e.min = t.min, e.max = t.max;
}
-function mD(e, t) {
- pD(e.x, t.x), pD(e.y, t.y);
+function lD(e, t) {
+ cD(e.x, t.x), cD(e.y, t.y);
}
-function hD(e, t) {
+function uD(e, t) {
e.translate = t.translate, e.scale = t.scale, e.originPoint = t.originPoint, e.origin = t.origin;
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/geometry/delta-calc.mjs
-var ese = .9999, tse = 1.0001, nse = -.01, rse = .01;
-function gD(e) {
+var ase = .9999, ose = 1.0001, sse = -.01, cse = .01;
+function dD(e) {
return e.max - e.min;
}
-function ise(e, t, n) {
+function lse(e, t, n) {
return Math.abs(e - t) <= n;
}
-function _D(e, t, n, r = .5) {
- e.origin = r, e.originPoint = uw(t.min, t.max, e.origin), e.scale = gD(n) / gD(t), e.translate = uw(n.min, n.max, e.origin) - e.originPoint, (e.scale >= ese && e.scale <= tse || isNaN(e.scale)) && (e.scale = 1), (e.translate >= nse && e.translate <= rse || isNaN(e.translate)) && (e.translate = 0);
+function fD(e, t, n, r = .5) {
+ e.origin = r, e.originPoint = YC(t.min, t.max, e.origin), e.scale = dD(n) / dD(t), e.translate = YC(n.min, n.max, e.origin) - e.originPoint, (e.scale >= ase && e.scale <= ose || isNaN(e.scale)) && (e.scale = 1), (e.translate >= sse && e.translate <= cse || isNaN(e.translate)) && (e.translate = 0);
}
-function vD(e, t, n, r) {
- _D(e.x, t.x, n.x, r ? r.originX : void 0), _D(e.y, t.y, n.y, r ? r.originY : void 0);
+function pD(e, t, n, r) {
+ fD(e.x, t.x, n.x, r ? r.originX : void 0), fD(e.y, t.y, n.y, r ? r.originY : void 0);
}
-function yD(e, t, n, r = 0) {
- e.min = (r ? uw(n.min, n.max, r) : n.min) + t.min, e.max = e.min + gD(t);
+function mD(e, t, n, r = 0) {
+ e.min = (r ? YC(n.min, n.max, r) : n.min) + t.min, e.max = e.min + dD(t);
}
-function ase(e, t, n, r) {
- yD(e.x, t.x, n.x, r?.x), yD(e.y, t.y, n.y, r?.y);
+function use(e, t, n, r) {
+ mD(e.x, t.x, n.x, r?.x), mD(e.y, t.y, n.y, r?.y);
}
-function bD(e, t, n, r = 0) {
- let i = r ? uw(n.min, n.max, r) : n.min;
- e.min = t.min - i, e.max = e.min + gD(t);
+function hD(e, t, n, r = 0) {
+ let i = r ? YC(n.min, n.max, r) : n.min;
+ e.min = t.min - i, e.max = e.min + dD(t);
}
-function xD(e, t, n, r) {
- bD(e.x, t.x, n.x, r?.x), bD(e.y, t.y, n.y, r?.y);
+function gD(e, t, n, r) {
+ hD(e.x, t.x, n.x, r?.x), hD(e.y, t.y, n.y, r?.y);
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/geometry/delta-remove.mjs
-function SD(e, t, n, r, i) {
- return e -= t, e = VE(e, 1 / n, r), i !== void 0 && (e = VE(e, 1 / i, r)), e;
+function _D(e, t, n, r, i) {
+ return e -= t, e = IE(e, 1 / n, r), i !== void 0 && (e = IE(e, 1 / i, r)), e;
}
-function ose(e, t = 0, n = 1, r = .5, i, a = e, o = e) {
- if (ZC.test(t) && (t = parseFloat(t), t = uw(o.min, o.max, t / 100) - o.min), typeof t != "number") return;
- let s = uw(a.min, a.max, r);
- e === a && (s -= t), e.min = SD(e.min, t, n, s, i), e.max = SD(e.max, t, n, s, i);
+function dse(e, t = 0, n = 1, r = .5, i, a = e, o = e) {
+ if (CC.test(t) && (t = parseFloat(t), t = YC(o.min, o.max, t / 100) - o.min), typeof t != "number") return;
+ let s = YC(a.min, a.max, r);
+ e === a && (s -= t), e.min = _D(e.min, t, n, s, i), e.max = _D(e.max, t, n, s, i);
}
-function CD(e, t, [n, r, i], a, o) {
- ose(e, t[n], t[r], t[i], t.scale, a, o);
+function vD(e, t, [n, r, i], a, o) {
+ dse(e, t[n], t[r], t[i], t.scale, a, o);
}
-var sse = [
+var fse = [
"x",
"scaleX",
"originX"
-], cse = [
+], pse = [
"y",
"scaleY",
"originY"
];
-function wD(e, t, n, r) {
- CD(e.x, t, sse, n ? n.x : void 0, r ? r.x : void 0), CD(e.y, t, cse, n ? n.y : void 0, r ? r.y : void 0);
+function yD(e, t, n, r) {
+ vD(e.x, t, fse, n ? n.x : void 0, r ? r.x : void 0), vD(e.y, t, pse, n ? n.y : void 0, r ? r.y : void 0);
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/geometry/utils.mjs
-function TD(e) {
+function bD(e) {
return e.translate === 0 && e.scale === 1;
}
-function ED(e) {
- return TD(e.x) && TD(e.y);
+function xD(e) {
+ return bD(e.x) && bD(e.y);
}
-function DD(e, t) {
+function SD(e, t) {
return e.min === t.min && e.max === t.max;
}
-function lse(e, t) {
- return DD(e.x, t.x) && DD(e.y, t.y);
+function mse(e, t) {
+ return SD(e.x, t.x) && SD(e.y, t.y);
}
-function OD(e, t) {
+function CD(e, t) {
return Math.round(e.min) === Math.round(t.min) && Math.round(e.max) === Math.round(t.max);
}
-function kD(e, t) {
- return OD(e.x, t.x) && OD(e.y, t.y);
+function wD(e, t) {
+ return CD(e.x, t.x) && CD(e.y, t.y);
}
-function AD(e) {
- return gD(e.x) / gD(e.y);
+function TD(e) {
+ return dD(e.x) / dD(e.y);
}
-function jD(e, t) {
+function ED(e, t) {
return e.translate === t.translate && e.scale === t.scale && e.originPoint === t.originPoint;
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/utils/each-axis.mjs
-function MD(e) {
+function DD(e) {
return [e("x"), e("y")];
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/styles/transform.mjs
-function use(e, t, n) {
+function hse(e, t, n) {
let r = "", i = e.x.translate / t.x, a = e.y.translate / t.y, o = n?.z || 0;
if ((i || a || o) && (r = `translate3d(${i}px, ${a}px, ${o}px) `), (t.x !== 1 || t.y !== 1) && (r += `scale(${1 / t.x}, ${1 / t.y}) `), n) {
let { transformPerspective: e, rotate: t, pathRotation: i, rotateX: a, rotateY: o, skewX: s, skewY: c } = n;
@@ -31652,81 +31652,81 @@ function use(e, t, n) {
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/animation/mix-values.mjs
-var dse = GT.length, ND = (e) => typeof e == "string" ? parseFloat(e) : e, PD = (e) => typeof e == "number" || QC.test(e);
-function fse(e, t, n, r, i, a) {
- i ? (e.opacity = uw(0, n.opacity ?? 1, pse(r)), e.opacityExit = uw(t.opacity ?? 1, 0, mse(r))) : a && (e.opacity = uw(t.opacity ?? 1, n.opacity ?? 1, r));
- for (let i = 0; i < dse; i++) {
- let a = GT[i], o = FD(t, a), s = FD(n, a);
- (o !== void 0 || s !== void 0) && (o ||= 0, s ||= 0, o === 0 || s === 0 || PD(o) === PD(s) ? (e[a] = Math.max(uw(ND(o), ND(s), r), 0), (ZC.test(s) || ZC.test(o)) && (e[a] += "%")) : e[a] = s);
+var gse = BT.length, OD = (e) => typeof e == "string" ? parseFloat(e) : e, kD = (e) => typeof e == "number" || wC.test(e);
+function _se(e, t, n, r, i, a) {
+ i ? (e.opacity = YC(0, n.opacity ?? 1, vse(r)), e.opacityExit = YC(t.opacity ?? 1, 0, yse(r))) : a && (e.opacity = YC(t.opacity ?? 1, n.opacity ?? 1, r));
+ for (let i = 0; i < gse; i++) {
+ let a = BT[i], o = AD(t, a), s = AD(n, a);
+ (o !== void 0 || s !== void 0) && (o ||= 0, s ||= 0, o === 0 || s === 0 || kD(o) === kD(s) ? (e[a] = Math.max(YC(OD(o), OD(s), r), 0), (CC.test(s) || CC.test(o)) && (e[a] += "%")) : e[a] = s);
}
- (t.rotate || n.rotate) && (e.rotate = uw(t.rotate || 0, n.rotate || 0, r));
+ (t.rotate || n.rotate) && (e.rotate = YC(t.rotate || 0, n.rotate || 0, r));
}
-function FD(e, t) {
+function AD(e, t) {
return e[t] === void 0 ? e.borderRadius : e[t];
}
-var pse = /*@__PURE__*/ ID(0, .5, xC), mse = /*@__PURE__*/ ID(.5, .95, aC);
-function ID(e, t, n) {
- return (r) => r < e ? 0 : r > t ? 1 : n(/* @__PURE__ */ sC(e, t, r));
+var vse = /*@__PURE__*/ jD(0, .5, qS), yse = /*@__PURE__*/ jD(.5, .95, jS);
+function jD(e, t, n) {
+ return (r) => r < e ? 0 : r > t ? 1 : n(/* @__PURE__ */ NS(e, t, r));
}
//#endregion
//#region node_modules/motion-dom/dist/es/animation/animate/single-value.mjs
-function hse(e, t, n) {
- let r = kT(e) ? e : yT(e);
- return r.start(ST("", r, t, n)), r.animation;
+function bse(e, t, n) {
+ let r = wT(e) ? e : mT(e);
+ return r.start(_T("", r, t, n)), r.animation;
}
//#endregion
//#region node_modules/motion-dom/dist/es/events/add-dom-event.mjs
-function LD(e, t, n, r = { passive: !0 }) {
+function MD(e, t, n, r = { passive: !0 }) {
return e.addEventListener(t, n, r), () => e.removeEventListener(t, n, r);
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/utils/compare-by-depth.mjs
-var gse = (e, t) => e.depth - t.depth, _se = class {
+var xse = (e, t) => e.depth - t.depth, Sse = class {
constructor() {
this.children = [], this.isDirty = !1;
}
add(e) {
- ZS(this.children, e), this.isDirty = !0;
+ CS(this.children, e), this.isDirty = !0;
}
remove(e) {
- QS(this.children, e), this.isDirty = !0;
+ wS(this.children, e), this.isDirty = !0;
}
forEach(e) {
- this.isDirty && this.children.sort(gse), this.isDirty = !1, this.children.forEach(e);
+ this.isDirty && this.children.sort(xse), this.isDirty = !1, this.children.forEach(e);
}
};
//#endregion
//#region node_modules/motion-dom/dist/es/utils/delay.mjs
-function vse(e, t) {
- let n = PC.now(), r = ({ timestamp: i }) => {
+function Cse(e, t) {
+ let n = oC.now(), r = ({ timestamp: i }) => {
let a = i - n;
- a >= t && (AC(r), e(a - t));
+ a >= t && (nC(r), e(a - t));
};
- return kC.setup(r, !0), () => AC(r);
+ return tC.setup(r, !0), () => nC(r);
}
//#endregion
//#region node_modules/motion-dom/dist/es/value/utils/resolve-motion-value.mjs
-function RD(e) {
- return kT(e) ? e.get() : e;
+function ND(e) {
+ return wT(e) ? e.get() : e;
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/shared/stack.mjs
-var yse = class {
+var wse = class {
constructor() {
this.members = [];
}
add(e) {
- ZS(this.members, e);
+ CS(this.members, e);
for (let t = this.members.length - 1; t >= 0; t--) {
let n = this.members[t];
if (n === e || n === this.lead || n === this.prevLead) continue;
let r = n.instance;
- (!r || r.isConnected === !1) && !n.snapshot && (QS(this.members, n), n.unmount());
+ (!r || r.isConnected === !1) && !n.snapshot && (wS(this.members, n), n.unmount());
}
e.scheduleRender();
}
remove(e) {
- if (QS(this.members, e), e === this.prevLead && (this.prevLead = void 0), e === this.lead) {
+ if (wS(this.members, e), e === this.prevLead && (this.prevLead = void 0), e === this.lead) {
let e = this.members[this.members.length - 1];
e && this.promote(e);
}
@@ -31757,51 +31757,51 @@ var yse = class {
removeLeadSnapshot() {
this.lead?.snapshot && (this.lead.snapshot = void 0);
}
-}, zD = {
+}, PD = {
hasAnimatedSinceResize: !0,
hasEverUpdated: !1
-}, BD = {
+}, FD = {
nodes: 0,
calculatedTargetDeltas: 0,
calculatedProjections: 0
-}, VD = [
+}, ID = [
"",
"X",
"Y",
"Z"
-], bse = 1e3, xse = 0;
-function HD(e, t, n, r) {
+], Tse = 1e3, Ese = 0;
+function LD(e, t, n, r) {
let { latestValues: i } = t;
i[e] && (n[e] = i[e], t.setStaticValue(e, 0), r && (r[e] = 0));
}
-function UD(e) {
+function RD(e) {
if (e.hasCheckedOptimisedAppear = !0, e.root === e) return;
let { visualElement: t } = e.options;
if (!t) return;
- let n = NT(t);
+ let n = OT(t);
if (window.MotionHasOptimisedAnimation(n, "transform")) {
let { layout: t, layoutId: r } = e.options;
- window.MotionCancelOptimisedAnimation(n, "transform", kC, !(t || r));
+ window.MotionCancelOptimisedAnimation(n, "transform", tC, !(t || r));
}
let { parent: r } = e;
- r && !r.hasCheckedOptimisedAppear && UD(r);
+ r && !r.hasCheckedOptimisedAppear && RD(r);
}
-function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, checkIsScrollRoot: r, resetTransform: i }) {
+function zD({ attachResizeListener: e, defaultParent: t, measureScroll: n, checkIsScrollRoot: r, resetTransform: i }) {
return class {
constructor(e = {}, n = t?.()) {
- this.id = xse++, this.animationId = 0, this.animationCommitId = 0, this.children = /* @__PURE__ */ new Set(), this.options = {}, this.isTreeAnimating = !1, this.isAnimationBlocked = !1, this.isLayoutDirty = !1, this.isProjectionDirty = !1, this.isSharedProjectionDirty = !1, this.isTransformDirty = !1, this.updateManuallyBlocked = !1, this.updateBlockedByResize = !1, this.isUpdating = !1, this.isSVG = !1, this.needsReset = !1, this.shouldResetTransform = !1, this.hasCheckedOptimisedAppear = !1, this.treeScale = {
+ this.id = Ese++, this.animationId = 0, this.animationCommitId = 0, this.children = /* @__PURE__ */ new Set(), this.options = {}, this.isTreeAnimating = !1, this.isAnimationBlocked = !1, this.isLayoutDirty = !1, this.isProjectionDirty = !1, this.isSharedProjectionDirty = !1, this.isTransformDirty = !1, this.updateManuallyBlocked = !1, this.updateBlockedByResize = !1, this.isUpdating = !1, this.isSVG = !1, this.needsReset = !1, this.shouldResetTransform = !1, this.hasCheckedOptimisedAppear = !1, this.treeScale = {
x: 1,
y: 1
}, this.eventHandlers = /* @__PURE__ */ new Map(), this.hasTreeAnimated = !1, this.layoutVersion = 0, this.updateScheduled = !1, this.scheduleUpdate = () => this.update(), this.projectionUpdateScheduled = !1, this.checkUpdateFailed = () => {
this.isUpdating && (this.isUpdating = !1, this.clearAllSnapshots());
}, this.updateProjection = () => {
- this.projectionUpdateScheduled = !1, mE.value && (BD.nodes = BD.calculatedTargetDeltas = BD.calculatedProjections = 0), this.nodes.forEach(wse), this.nodes.forEach(Ase), this.nodes.forEach(jse), this.nodes.forEach(Tse), mE.addProjectionMetrics && mE.addProjectionMetrics(BD);
+ this.projectionUpdateScheduled = !1, lE.value && (FD.nodes = FD.calculatedTargetDeltas = FD.calculatedProjections = 0), this.nodes.forEach(kse), this.nodes.forEach(Fse), this.nodes.forEach(Ise), this.nodes.forEach(Ase), lE.addProjectionMetrics && lE.addProjectionMetrics(FD);
}, this.resolvedRelativeTargetAt = 0, this.linkedParentVersion = 0, this.hasProjected = !1, this.isVisible = !0, this.animationProgress = 0, this.sharedNodes = /* @__PURE__ */ new Map(), this.latestValues = e, this.root = n ? n.root || n : this, this.path = n ? [...n.path, n] : [], this.parent = n, this.depth = n ? n.depth + 1 : 0;
for (let e = 0; e < this.path.length; e++) this.path[e].shouldResetTransform = !0;
- this.root === this && (this.nodes = new _se());
+ this.root === this && (this.nodes = new Sse());
}
addEventListener(e, t) {
- return this.eventHandlers.has(e) || this.eventHandlers.set(e, new cC()), this.eventHandlers.get(e).add(t);
+ return this.eventHandlers.has(e) || this.eventHandlers.set(e, new PS()), this.eventHandlers.get(e).add(t);
}
notifyListeners(e, ...t) {
let n = this.eventHandlers.get(e);
@@ -31812,15 +31812,15 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
}
mount(t) {
if (this.instance) return;
- this.isSVG = sE(t) && !Soe(t), this.instance = t;
+ this.isSVG = nE(t) && !Doe(t), this.instance = t;
let { layoutId: n, layout: r, visualElement: i } = this.options;
if (i && !i.current && i.mount(t), this.root.nodes.add(this), this.parent && this.parent.children.add(this), this.root.hasTreeAnimated && (r || n) && (this.isLayoutDirty = !0), e) {
let n, r = 0, i = () => this.root.updateBlockedByResize = !1;
- kC.read(() => {
+ tC.read(() => {
r = window.innerWidth;
}), e(t, () => {
let e = window.innerWidth;
- e !== r && (r = e, this.root.updateBlockedByResize = !0, n && n(), n = vse(i, 250), zD.hasAnimatedSinceResize && (zD.hasAnimatedSinceResize = !1, this.nodes.forEach(qD)));
+ e !== r && (r = e, this.root.updateBlockedByResize = !0, n && n(), n = Cse(i, 250), PD.hasAnimatedSinceResize && (PD.hasAnimatedSinceResize = !1, this.nodes.forEach(HD)));
});
}
n && this.root.registerSharedNode(n, this), this.options.animate !== !1 && i && (n || r) && this.addEventListener("didUpdate", ({ delta: e, hasLayoutChanged: t, hasRelativeLayoutChanged: n, layout: r }) => {
@@ -31828,23 +31828,23 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
this.target = void 0, this.relativeTarget = void 0;
return;
}
- let a = this.options.transition || i.getDefaultTransition() || Ise, { onLayoutAnimationStart: o, onLayoutAnimationComplete: s } = i.getProps(), c = !this.targetLayout || !kD(this.targetLayout, r), l = !t && n;
+ let a = this.options.transition || i.getDefaultTransition() || Vse, { onLayoutAnimationStart: o, onLayoutAnimationComplete: s } = i.getProps(), c = !this.targetLayout || !wD(this.targetLayout, r), l = !t && n;
if (this.options.layoutRoot || this.resumeFrom || l || t && (c || !this.currentAnimation)) {
this.resumeFrom && (this.resumingFrom = this.resumeFrom, this.resumingFrom.resumingFrom = void 0);
let t = {
- ...xT(a, "layout"),
+ ...gT(a, "layout"),
onPlay: o,
onComplete: s
};
(i.shouldReduceMotion || this.options.layoutRoot) && (t.delay = 0, t.type = !1), this.startAnimation(t), this.setAnimationOrigin(e, l, t.path);
- } else t || qD(this), this.isLead() && this.options.onExitComplete && this.options.onExitComplete();
+ } else t || HD(this), this.isLead() && this.options.onExitComplete && this.options.onExitComplete();
this.targetLayout = r;
});
}
unmount() {
this.options.layoutId && this.willUpdate(), this.root.nodes.remove(this);
let e = this.getStack();
- e && e.remove(this), this.parent && this.parent.children.delete(this), this.instance = void 0, this.eventHandlers.clear(), AC(this.updateProjection);
+ e && e.remove(this), this.parent && this.parent.children.delete(this), this.instance = void 0, this.eventHandlers.clear(), nC(this.updateProjection);
}
blockUpdate() {
this.updateManuallyBlocked = !0;
@@ -31859,7 +31859,7 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
return this.isAnimationBlocked || this.parent && this.parent.isTreeAnimationBlocked() || !1;
}
startUpdate() {
- this.isUpdateBlocked() || (this.isUpdating = !0, this.nodes && this.nodes.forEach(Mse), this.animationId++);
+ this.isUpdateBlocked() || (this.isUpdating = !0, this.nodes && this.nodes.forEach(Lse), this.animationId++);
}
getTransformTemplate() {
let { visualElement: e } = this.options;
@@ -31870,7 +31870,7 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
this.options.onExitComplete && this.options.onExitComplete();
return;
}
- if (window.MotionCancelOptimisedAnimation && !this.hasCheckedOptimisedAppear && UD(this), !this.root.isUpdating && this.root.startUpdate(), this.isLayoutDirty) return;
+ if (window.MotionCancelOptimisedAnimation && !this.hasCheckedOptimisedAppear && RD(this), !this.root.isUpdating && this.root.startUpdate(), this.isLayoutDirty) return;
this.isLayoutDirty = !0;
for (let e = 0; e < this.path.length; e++) {
let t = this.path[e];
@@ -31884,39 +31884,39 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
update() {
if (this.updateScheduled = !1, this.isUpdateBlocked()) {
let e = this.updateBlockedByResize;
- this.unblockUpdate(), this.updateBlockedByResize = !1, this.clearAllSnapshots(), e && this.nodes.forEach(Dse), this.nodes.forEach(GD);
+ this.unblockUpdate(), this.updateBlockedByResize = !1, this.clearAllSnapshots(), e && this.nodes.forEach(Mse), this.nodes.forEach(BD);
return;
}
if (this.animationId <= this.animationCommitId) {
- this.nodes.forEach(KD);
+ this.nodes.forEach(VD);
return;
}
- this.animationCommitId = this.animationId, this.isUpdating ? (this.isUpdating = !1, this.nodes.forEach(Ose), this.nodes.forEach(kse), this.nodes.forEach(Sse), this.nodes.forEach(Cse)) : this.nodes.forEach(KD), this.clearAllSnapshots();
- let e = PC.now();
- jC.delta = $S(0, 1e3 / 60, e - jC.timestamp), jC.timestamp = e, jC.isProcessing = !0, MC.update.process(jC), MC.preRender.process(jC), MC.render.process(jC), jC.isProcessing = !1;
+ this.animationCommitId = this.animationId, this.isUpdating ? (this.isUpdating = !1, this.nodes.forEach(Nse), this.nodes.forEach(Pse), this.nodes.forEach(Dse), this.nodes.forEach(Ose)) : this.nodes.forEach(VD), this.clearAllSnapshots();
+ let e = oC.now();
+ rC.delta = TS(0, 1e3 / 60, e - rC.timestamp), rC.timestamp = e, rC.isProcessing = !0, iC.update.process(rC), iC.preRender.process(rC), iC.render.process(rC), rC.isProcessing = !1;
}
didUpdate() {
- this.updateScheduled || (this.updateScheduled = !0, YT.read(this.scheduleUpdate));
+ this.updateScheduled || (this.updateScheduled = !0, WT.read(this.scheduleUpdate));
}
clearAllSnapshots() {
- this.nodes.forEach(Ese), this.sharedNodes.forEach(Nse);
+ this.nodes.forEach(jse), this.sharedNodes.forEach(Rse);
}
scheduleUpdateProjection() {
- this.projectionUpdateScheduled || (this.projectionUpdateScheduled = !0, kC.preRender(this.updateProjection, !1, !0));
+ this.projectionUpdateScheduled || (this.projectionUpdateScheduled = !0, tC.preRender(this.updateProjection, !1, !0));
}
scheduleCheckAfterUnmount() {
- kC.postRender(() => {
+ tC.postRender(() => {
this.isLayoutDirty ? this.root.didUpdate() : this.root.checkUpdateFailed();
});
}
updateSnapshot() {
- this.snapshot || !this.instance || (this.snapshot = this.measure(), this.snapshot && !gD(this.snapshot.measuredBox.x) && !gD(this.snapshot.measuredBox.y) && (this.snapshot = void 0));
+ this.snapshot || !this.instance || (this.snapshot = this.measure(), this.snapshot && !dD(this.snapshot.measuredBox.x) && !dD(this.snapshot.measuredBox.y) && (this.snapshot = void 0));
}
updateLayout() {
if (!this.instance || (this.updateScroll(), !(this.options.alwaysMeasureLayout && this.isLead()) && !this.isLayoutDirty)) return;
if (this.resumeFrom && !this.resumeFrom.instance) for (let e = 0; e < this.path.length; e++) this.path[e].updateScroll();
let e = this.layout;
- this.layout = this.measure(!1), this.layoutVersion++, this.layoutCorrected ||= bE(), this.isLayoutDirty = !1, this.projectionDelta = void 0, this.notifyListeners("measure", this.layout.layoutBox);
+ this.layout = this.measure(!1), this.layoutVersion++, this.layoutCorrected ||= hE(), this.isLayoutDirty = !1, this.projectionDelta = void 0, this.notifyListeners("measure", this.layout.layoutBox);
let { visualElement: t } = this.options;
t && t.notify("LayoutMeasure", this.layout.layoutBox, e ? e.layoutBox : void 0);
}
@@ -31935,12 +31935,12 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
}
resetTransform() {
if (!i) return;
- let e = this.isLayoutDirty || this.shouldResetTransform || this.options.alwaysMeasureLayout, t = this.projectionDelta && !ED(this.projectionDelta), n = this.getTransformTemplate(), r = n ? n(this.latestValues, "") : void 0, a = r !== this.prevTransformTemplateValue;
- e && this.instance && (t || RE(this.latestValues) || a) && (i(this.instance, r), this.shouldResetTransform = !1, this.scheduleRender());
+ let e = this.isLayoutDirty || this.shouldResetTransform || this.options.alwaysMeasureLayout, t = this.projectionDelta && !xD(this.projectionDelta), n = this.getTransformTemplate(), r = n ? n(this.latestValues, "") : void 0, a = r !== this.prevTransformTemplateValue;
+ e && this.instance && (t || NE(this.latestValues) || a) && (i(this.instance, r), this.shouldResetTransform = !1, this.scheduleRender());
}
measure(e = !0) {
let t = this.measurePageBox(), n = this.removeElementScroll(t);
- return e && (n = this.removeTransform(n)), Lse(n), {
+ return e && (n = this.removeTransform(n)), Hse(n), {
animationId: this.root.animationId,
measuredBox: t,
layoutBox: n,
@@ -31950,42 +31950,42 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
}
measurePageBox() {
let { visualElement: e } = this.options;
- if (!e) return bE();
+ if (!e) return hE();
let t = e.measureViewportBox();
- if (!(this.scroll?.wasRoot || this.path.some(Rse))) {
+ if (!(this.scroll?.wasRoot || this.path.some(Use))) {
let { scroll: e } = this.root;
- e && (qE(t.x, e.offset.x), qE(t.y, e.offset.y));
+ e && (HE(t.x, e.offset.x), HE(t.y, e.offset.y));
}
return t;
}
removeElementScroll(e) {
- let t = bE();
- if (mD(t, e), this.scroll?.wasRoot) return t;
+ let t = hE();
+ if (lD(t, e), this.scroll?.wasRoot) return t;
for (let n = 0; n < this.path.length; n++) {
let r = this.path[n], { scroll: i, options: a } = r;
- r !== this.root && i && a.layoutScroll && (i.wasRoot && mD(t, e), qE(t.x, i.offset.x), qE(t.y, i.offset.y));
+ r !== this.root && i && a.layoutScroll && (i.wasRoot && lD(t, e), HE(t.x, i.offset.x), HE(t.y, i.offset.y));
}
return t;
}
applyTransform(e, t = !1, n) {
- let r = n || bE();
- mD(r, e);
+ let r = n || hE();
+ lD(r, e);
for (let e = 0; e < this.path.length; e++) {
let n = this.path[e];
- !t && n.options.layoutScroll && n.scroll && n !== n.root && (qE(r.x, -n.scroll.offset.x), qE(r.y, -n.scroll.offset.y)), RE(n.latestValues) && XE(r, n.latestValues, n.layout?.layoutBox);
+ !t && n.options.layoutScroll && n.scroll && n !== n.root && (HE(r.x, -n.scroll.offset.x), HE(r.y, -n.scroll.offset.y)), NE(n.latestValues) && GE(r, n.latestValues, n.layout?.layoutBox);
}
- return RE(this.latestValues) && XE(r, this.latestValues, this.layout?.layoutBox), r;
+ return NE(this.latestValues) && GE(r, this.latestValues, this.layout?.layoutBox), r;
}
removeTransform(e) {
- let t = bE();
- mD(t, e);
+ let t = hE();
+ lD(t, e);
for (let e = 0; e < this.path.length; e++) {
let n = this.path[e];
- if (!RE(n.latestValues)) continue;
+ if (!NE(n.latestValues)) continue;
let r;
- n.instance && (LE(n.latestValues) && n.updateSnapshot(), r = bE(), mD(r, n.measurePageBox())), wD(t, n.latestValues, n.snapshot?.layoutBox, r);
+ n.instance && (ME(n.latestValues) && n.updateSnapshot(), r = hE(), lD(r, n.measurePageBox())), yD(t, n.latestValues, n.snapshot?.layoutBox, r);
}
- return RE(this.latestValues) && wD(t, this.latestValues), t;
+ return NE(this.latestValues) && yD(t, this.latestValues), t;
}
setTargetDelta(e) {
this.targetDelta = e, this.root.scheduleUpdateProjection(), this.isProjectionDirty = !0;
@@ -32001,7 +32001,7 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
this.scroll = void 0, this.layout = void 0, this.snapshot = void 0, this.prevTransformTemplateValue = void 0, this.targetDelta = void 0, this.target = void 0, this.isLayoutDirty = !1;
}
forceRelativeParentToResolveTarget() {
- this.relativeParent && this.relativeParent.resolvedRelativeTargetAt !== jC.timestamp && this.relativeParent.resolveTargetDelta(!0);
+ this.relativeParent && this.relativeParent.resolvedRelativeTargetAt !== rC.timestamp && this.relativeParent.resolveTargetDelta(!0);
}
resolveTargetDelta(e = !1) {
let t = this.getLead();
@@ -32010,36 +32010,36 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
if (!(e || n && this.isSharedProjectionDirty || this.isProjectionDirty || this.parent?.isProjectionDirty || this.attemptToResolveRelativeTarget || this.root.updateBlockedByResize)) return;
let { layout: r, layoutId: i } = this.options;
if (!this.layout || !(r || i)) return;
- this.resolvedRelativeTargetAt = jC.timestamp;
+ this.resolvedRelativeTargetAt = rC.timestamp;
let a = this.getClosestProjectingParent();
- a && this.linkedParentVersion !== a.layoutVersion && !a.options.layoutRoot && this.removeRelativeTarget(), !this.targetDelta && !this.relativeTarget && (this.options.layoutAnchor !== !1 && a && a.layout ? this.createRelativeTarget(a, this.layout.layoutBox, a.layout.layoutBox) : this.removeRelativeTarget()), !(!this.relativeTarget && !this.targetDelta) && (this.target || (this.target = bE(), this.targetWithTransforms = bE()), this.relativeTarget && this.relativeTargetOrigin && this.relativeParent && this.relativeParent.target ? (this.forceRelativeParentToResolveTarget(), ase(this.target, this.relativeTarget, this.relativeParent.target, this.options.layoutAnchor || void 0)) : this.targetDelta ? (this.resumingFrom ? this.applyTransform(this.layout.layoutBox, !1, this.target) : mD(this.target, this.layout.layoutBox), WE(this.target, this.targetDelta)) : mD(this.target, this.layout.layoutBox), this.attemptToResolveRelativeTarget && (this.attemptToResolveRelativeTarget = !1, this.options.layoutAnchor !== !1 && a && !!a.resumingFrom == !!this.resumingFrom && !a.options.layoutScroll && a.target && this.animationProgress !== 1 ? this.createRelativeTarget(a, this.target, a.target) : this.relativeParent = this.relativeTarget = void 0), mE.value && BD.calculatedTargetDeltas++);
+ a && this.linkedParentVersion !== a.layoutVersion && !a.options.layoutRoot && this.removeRelativeTarget(), !this.targetDelta && !this.relativeTarget && (this.options.layoutAnchor !== !1 && a && a.layout ? this.createRelativeTarget(a, this.layout.layoutBox, a.layout.layoutBox) : this.removeRelativeTarget()), !(!this.relativeTarget && !this.targetDelta) && (this.target || (this.target = hE(), this.targetWithTransforms = hE()), this.relativeTarget && this.relativeTargetOrigin && this.relativeParent && this.relativeParent.target ? (this.forceRelativeParentToResolveTarget(), use(this.target, this.relativeTarget, this.relativeParent.target, this.options.layoutAnchor || void 0)) : this.targetDelta ? (this.resumingFrom ? this.applyTransform(this.layout.layoutBox, !1, this.target) : lD(this.target, this.layout.layoutBox), zE(this.target, this.targetDelta)) : lD(this.target, this.layout.layoutBox), this.attemptToResolveRelativeTarget && (this.attemptToResolveRelativeTarget = !1, this.options.layoutAnchor !== !1 && a && !!a.resumingFrom == !!this.resumingFrom && !a.options.layoutScroll && a.target && this.animationProgress !== 1 ? this.createRelativeTarget(a, this.target, a.target) : this.relativeParent = this.relativeTarget = void 0), lE.value && FD.calculatedTargetDeltas++);
}
getClosestProjectingParent() {
- if (!(!this.parent || LE(this.parent.latestValues) || zE(this.parent.latestValues))) return this.parent.isProjecting() ? this.parent : this.parent.getClosestProjectingParent();
+ if (!(!this.parent || ME(this.parent.latestValues) || PE(this.parent.latestValues))) return this.parent.isProjecting() ? this.parent : this.parent.getClosestProjectingParent();
}
isProjecting() {
return !!((this.relativeTarget || this.targetDelta || this.options.layoutRoot) && this.layout);
}
createRelativeTarget(e, t, n) {
- this.relativeParent = e, this.linkedParentVersion = e.layoutVersion, this.forceRelativeParentToResolveTarget(), this.relativeTarget = bE(), this.relativeTargetOrigin = bE(), xD(this.relativeTargetOrigin, t, n, this.options.layoutAnchor || void 0), mD(this.relativeTarget, this.relativeTargetOrigin);
+ this.relativeParent = e, this.linkedParentVersion = e.layoutVersion, this.forceRelativeParentToResolveTarget(), this.relativeTarget = hE(), this.relativeTargetOrigin = hE(), gD(this.relativeTargetOrigin, t, n, this.options.layoutAnchor || void 0), lD(this.relativeTarget, this.relativeTargetOrigin);
}
removeRelativeTarget() {
this.relativeParent = this.relativeTarget = void 0;
}
calcProjection() {
let e = this.getLead(), t = !!this.resumingFrom || this !== e, n = !0;
- if ((this.isProjectionDirty || this.parent?.isProjectionDirty) && (n = !1), t && (this.isSharedProjectionDirty || this.isTransformDirty) && (n = !1), this.resolvedRelativeTargetAt === jC.timestamp && (n = !1), n) return;
+ if ((this.isProjectionDirty || this.parent?.isProjectionDirty) && (n = !1), t && (this.isSharedProjectionDirty || this.isTransformDirty) && (n = !1), this.resolvedRelativeTargetAt === rC.timestamp && (n = !1), n) return;
let { layout: r, layoutId: i } = this.options;
if (this.isTreeAnimating = !!(this.parent && this.parent.isTreeAnimating || this.currentAnimation || this.pendingAnimation), this.isTreeAnimating || (this.targetDelta = this.relativeTarget = void 0), !this.layout || !(r || i)) return;
- mD(this.layoutCorrected, this.layout.layoutBox);
+ lD(this.layoutCorrected, this.layout.layoutBox);
let a = this.treeScale.x, o = this.treeScale.y;
- Poe(this.layoutCorrected, this.treeScale, this.path, t), e.layout && !e.target && (this.treeScale.x !== 1 || this.treeScale.y !== 1) && (e.target = e.layout.layoutBox, e.targetWithTransforms = bE());
+ zoe(this.layoutCorrected, this.treeScale, this.path, t), e.layout && !e.target && (this.treeScale.x !== 1 || this.treeScale.y !== 1) && (e.target = e.layout.layoutBox, e.targetWithTransforms = hE());
let { target: s } = e;
if (!s) {
this.prevProjectionDelta && (this.createProjectionDeltas(), this.scheduleRender());
return;
}
- !this.projectionDelta || !this.prevProjectionDelta ? this.createProjectionDeltas() : (hD(this.prevProjectionDelta.x, this.projectionDelta.x), hD(this.prevProjectionDelta.y, this.projectionDelta.y)), vD(this.projectionDelta, this.layoutCorrected, s, this.latestValues), (this.treeScale.x !== a || this.treeScale.y !== o || !jD(this.projectionDelta.x, this.prevProjectionDelta.x) || !jD(this.projectionDelta.y, this.prevProjectionDelta.y)) && (this.hasProjected = !0, this.scheduleRender(), this.notifyListeners("projectionUpdate", s)), mE.value && BD.calculatedProjections++;
+ !this.projectionDelta || !this.prevProjectionDelta ? this.createProjectionDeltas() : (uD(this.prevProjectionDelta.x, this.projectionDelta.x), uD(this.prevProjectionDelta.y, this.projectionDelta.y)), pD(this.projectionDelta, this.layoutCorrected, s, this.latestValues), (this.treeScale.x !== a || this.treeScale.y !== o || !ED(this.projectionDelta.x, this.prevProjectionDelta.x) || !ED(this.projectionDelta.y, this.prevProjectionDelta.y)) && (this.hasProjected = !0, this.scheduleRender(), this.notifyListeners("projectionUpdate", s)), lE.value && FD.calculatedProjections++;
}
hide() {
this.isVisible = !1;
@@ -32055,22 +32055,22 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
this.resumingFrom && !this.resumingFrom.instance && (this.resumingFrom = void 0);
}
createProjectionDeltas() {
- this.prevProjectionDelta = vE(), this.projectionDelta = vE(), this.projectionDeltaWithTransform = vE();
+ this.prevProjectionDelta = pE(), this.projectionDelta = pE(), this.projectionDeltaWithTransform = pE();
}
setAnimationOrigin(e, t = !1, n) {
- let r = this.snapshot, i = r ? r.latestValues : {}, a = { ...this.latestValues }, o = vE();
+ let r = this.snapshot, i = r ? r.latestValues : {}, a = { ...this.latestValues }, o = pE();
(!this.relativeParent || !this.relativeParent.options.layoutRoot) && (this.relativeTarget = this.relativeTargetOrigin = void 0), this.attemptToResolveRelativeTarget = !t;
- let s = bE(), c = (r ? r.source : void 0) !== (this.layout ? this.layout.source : void 0), l = this.getStack(), u = !l || l.members.length <= 1, d = !!(c && !u && this.options.crossfade === !0 && !this.path.some(Fse));
+ let s = hE(), c = (r ? r.source : void 0) !== (this.layout ? this.layout.source : void 0), l = this.getStack(), u = !l || l.members.length <= 1, d = !!(c && !u && this.options.crossfade === !0 && !this.path.some(Bse));
this.animationProgress = 0;
let f, p = n?.interpolateProjection(e);
this.mixTargetDelta = (t) => {
let n = t / 1e3, r = p?.(n);
- r ? (o.x.translate = r.x, o.x.scale = uw(e.x.scale, 1, n), o.x.origin = e.x.origin, o.x.originPoint = e.x.originPoint, o.y.translate = r.y, o.y.scale = uw(e.y.scale, 1, n), o.y.origin = e.y.origin, o.y.originPoint = e.y.originPoint) : (JD(o.x, e.x, n), JD(o.y, e.y, n)), this.setTargetDelta(o), this.relativeTarget && this.relativeTargetOrigin && this.layout && this.relativeParent && this.relativeParent.layout && (xD(s, this.layout.layoutBox, this.relativeParent.layout.layoutBox, this.options.layoutAnchor || void 0), Pse(this.relativeTarget, this.relativeTargetOrigin, s, n), f && lse(this.relativeTarget, f) && (this.isProjectionDirty = !1), f ||= bE(), mD(f, this.relativeTarget)), c && (this.animationValues = a, fse(a, i, this.latestValues, n, d, u)), r && r.rotate !== void 0 && (this.animationValues ||= a, this.animationValues.pathRotation = r.rotate), this.root.scheduleUpdateProjection(), this.scheduleRender(), this.animationProgress = n;
+ r ? (o.x.translate = r.x, o.x.scale = YC(e.x.scale, 1, n), o.x.origin = e.x.origin, o.x.originPoint = e.x.originPoint, o.y.translate = r.y, o.y.scale = YC(e.y.scale, 1, n), o.y.origin = e.y.origin, o.y.originPoint = e.y.originPoint) : (UD(o.x, e.x, n), UD(o.y, e.y, n)), this.setTargetDelta(o), this.relativeTarget && this.relativeTargetOrigin && this.layout && this.relativeParent && this.relativeParent.layout && (gD(s, this.layout.layoutBox, this.relativeParent.layout.layoutBox, this.options.layoutAnchor || void 0), zse(this.relativeTarget, this.relativeTargetOrigin, s, n), f && mse(this.relativeTarget, f) && (this.isProjectionDirty = !1), f ||= hE(), lD(f, this.relativeTarget)), c && (this.animationValues = a, _se(a, i, this.latestValues, n, d, u)), r && r.rotate !== void 0 && (this.animationValues ||= a, this.animationValues.pathRotation = r.rotate), this.root.scheduleUpdateProjection(), this.scheduleRender(), this.animationProgress = n;
}, this.mixTargetDelta(this.options.layoutRoot ? 1e3 : 0);
}
startAnimation(e) {
- this.notifyListeners("animationStart"), this.currentAnimation?.stop(), this.resumingFrom?.currentAnimation?.stop(), this.pendingAnimation &&= (AC(this.pendingAnimation), void 0), this.pendingAnimation = kC.update(() => {
- zD.hasAnimatedSinceResize = !0, this.motionValue ||= yT(0), this.motionValue.jump(0, !1), this.currentAnimation = hse(this.motionValue, [0, 1e3], {
+ this.notifyListeners("animationStart"), this.currentAnimation?.stop(), this.resumingFrom?.currentAnimation?.stop(), this.pendingAnimation &&= (nC(this.pendingAnimation), void 0), this.pendingAnimation = tC.update(() => {
+ PD.hasAnimatedSinceResize = !0, this.motionValue ||= mT(0), this.motionValue.jump(0, !1), this.currentAnimation = bse(this.motionValue, [0, 1e3], {
...e,
velocity: 0,
isSync: !0,
@@ -32089,23 +32089,23 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
e && e.exitAnimationComplete(), this.resumingFrom = this.currentAnimation = this.animationValues = void 0, this.notifyListeners("animationComplete");
}
finishAnimation() {
- this.currentAnimation && (this.mixTargetDelta && this.mixTargetDelta(bse), this.currentAnimation.stop()), this.completeAnimation();
+ this.currentAnimation && (this.mixTargetDelta && this.mixTargetDelta(Tse), this.currentAnimation.stop()), this.completeAnimation();
}
applyTransformsToTarget() {
let e = this.getLead(), { targetWithTransforms: t, target: n, layout: r, latestValues: i } = e;
if (!(!t || !n || !r)) {
- if (this !== e && this.layout && r && $D(this.options.animationType, this.layout.layoutBox, r.layoutBox)) {
- n = this.target || bE();
- let t = gD(this.layout.layoutBox.x);
+ if (this !== e && this.layout && r && JD(this.options.animationType, this.layout.layoutBox, r.layoutBox)) {
+ n = this.target || hE();
+ let t = dD(this.layout.layoutBox.x);
n.x.min = e.target.x.min, n.x.max = n.x.min + t;
- let r = gD(this.layout.layoutBox.y);
+ let r = dD(this.layout.layoutBox.y);
n.y.min = e.target.y.min, n.y.max = n.y.min + r;
}
- mD(t, n), XE(t, i), vD(this.projectionDeltaWithTransform, this.layoutCorrected, t, i);
+ lD(t, n), GE(t, i), pD(this.projectionDeltaWithTransform, this.layoutCorrected, t, i);
}
}
registerSharedNode(e, t) {
- this.sharedNodes.has(e) || this.sharedNodes.set(e, new yse()), this.sharedNodes.get(e).add(t);
+ this.sharedNodes.has(e) || this.sharedNodes.set(e, new wse()), this.sharedNodes.get(e).add(t);
let n = t.options.initialPromotionConfig;
t.promote({
transition: n ? n.transition : void 0,
@@ -32142,8 +32142,8 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
let t = !1, { latestValues: n } = e;
if ((n.z || n.rotate || n.rotateX || n.rotateY || n.rotateZ || n.skewX || n.skewY) && (t = !0), !t) return;
let r = {};
- n.z && HD("z", e, r, this.animationValues);
- for (let t = 0; t < VD.length; t++) HD(`rotate${VD[t]}`, e, r, this.animationValues), HD(`skew${VD[t]}`, e, r, this.animationValues);
+ n.z && LD("z", e, r, this.animationValues);
+ for (let t = 0; t < ID.length; t++) LD(`rotate${ID[t]}`, e, r, this.animationValues), LD(`skew${ID[t]}`, e, r, this.animationValues);
e.render();
for (let t in r) e.setStaticValue(t, r[t]), this.animationValues && (this.animationValues[t] = r[t]);
e.scheduleRender();
@@ -32156,71 +32156,71 @@ function WD({ attachResizeListener: e, defaultParent: t, measureScroll: n, check
}
let n = this.getTransformTemplate();
if (this.needsReset) {
- this.needsReset = !1, e.visibility = "", e.opacity = "", e.pointerEvents = RD(t?.pointerEvents) || "", e.transform = n ? n(this.latestValues, "") : "none";
+ this.needsReset = !1, e.visibility = "", e.opacity = "", e.pointerEvents = ND(t?.pointerEvents) || "", e.transform = n ? n(this.latestValues, "") : "none";
return;
}
let r = this.getLead();
if (!this.projectionDelta || !this.layout || !r.target) {
- this.options.layoutId && (e.opacity = this.latestValues.opacity === void 0 ? 1 : this.latestValues.opacity, e.pointerEvents = RD(t?.pointerEvents) || ""), this.hasProjected && !RE(this.latestValues) && (e.transform = n ? n({}, "") : "none", this.hasProjected = !1);
+ this.options.layoutId && (e.opacity = this.latestValues.opacity === void 0 ? 1 : this.latestValues.opacity, e.pointerEvents = ND(t?.pointerEvents) || ""), this.hasProjected && !NE(this.latestValues) && (e.transform = n ? n({}, "") : "none", this.hasProjected = !1);
return;
}
e.visibility = "";
let i = r.animationValues || r.latestValues;
this.applyTransformsToTarget();
- let a = use(this.projectionDeltaWithTransform, this.treeScale, i);
+ let a = hse(this.projectionDeltaWithTransform, this.treeScale, i);
n && (a = n(i, a)), e.transform = a;
let { x: o, y: s } = this.projectionDelta;
e.transformOrigin = `${o.origin * 100}% ${s.origin * 100}% 0`, e.opacity = r.animationValues ? r === this ? i.opacity ?? this.latestValues.opacity ?? 1 : this.preserveOpacity ? this.latestValues.opacity : i.opacityExit : r === this ? i.opacity === void 0 ? "" : i.opacity : i.opacityExit === void 0 ? 0 : i.opacityExit;
- for (let t in nD) {
+ for (let t in ZE) {
if (i[t] === void 0) continue;
- let { correct: n, applyTo: o, isCSSVariable: s } = nD[t], c = a === "none" ? i[t] : n(i[t], r);
+ let { correct: n, applyTo: o, isCSSVariable: s } = ZE[t], c = a === "none" ? i[t] : n(i[t], r);
if (o) {
let t = o.length;
for (let n = 0; n < t; n++) e[o[n]] = c;
} else s ? this.options.visualElement.renderState.vars[t] = c : e[t] = c;
}
- this.options.layoutId && (e.pointerEvents = r === this ? RD(t?.pointerEvents) || "" : "none");
+ this.options.layoutId && (e.pointerEvents = r === this ? ND(t?.pointerEvents) || "" : "none");
}
clearSnapshot() {
this.resumeFrom = this.snapshot = void 0;
}
resetTree() {
- this.root.nodes.forEach((e) => e.currentAnimation?.stop()), this.root.nodes.forEach(GD), this.root.sharedNodes.clear();
+ this.root.nodes.forEach((e) => e.currentAnimation?.stop()), this.root.nodes.forEach(BD), this.root.sharedNodes.clear();
}
};
}
-function Sse(e) {
+function Dse(e) {
e.updateLayout();
}
-function Cse(e) {
+function Ose(e) {
let t = e.resumeFrom?.snapshot || e.snapshot;
if (e.isLead() && e.layout && t && e.hasListeners("didUpdate")) {
let { layoutBox: n, measuredBox: r } = e.layout, { animationType: i } = e.options, a = t.source !== e.layout.source;
- if (i === "size") MD((e) => {
- let r = a ? t.measuredBox[e] : t.layoutBox[e], i = gD(r);
+ if (i === "size") DD((e) => {
+ let r = a ? t.measuredBox[e] : t.layoutBox[e], i = dD(r);
r.min = n[e].min, r.max = r.min + i;
});
else if (i === "x" || i === "y") {
let e = i === "x" ? "y" : "x";
- pD(a ? t.measuredBox[e] : t.layoutBox[e], n[e]);
- } else $D(i, t.layoutBox, n) && MD((r) => {
- let i = a ? t.measuredBox[r] : t.layoutBox[r], o = gD(n[r]);
+ cD(a ? t.measuredBox[e] : t.layoutBox[e], n[e]);
+ } else JD(i, t.layoutBox, n) && DD((r) => {
+ let i = a ? t.measuredBox[r] : t.layoutBox[r], o = dD(n[r]);
i.max = i.min + o, e.relativeTarget && !e.currentAnimation && (e.isProjectionDirty = !0, e.relativeTarget[r].max = e.relativeTarget[r].min + o);
});
- let o = vE();
- vD(o, n, t.layoutBox);
- let s = vE();
- a ? vD(s, e.applyTransform(r, !0), t.measuredBox) : vD(s, n, t.layoutBox);
- let c = !ED(o), l = !1;
+ let o = pE();
+ pD(o, n, t.layoutBox);
+ let s = pE();
+ a ? pD(s, e.applyTransform(r, !0), t.measuredBox) : pD(s, n, t.layoutBox);
+ let c = !xD(o), l = !1;
if (!e.resumeFrom) {
let r = e.getClosestProjectingParent();
if (r && !r.resumeFrom) {
let { snapshot: i, layout: a } = r;
if (i && a) {
- let o = e.options.layoutAnchor || void 0, s = bE();
- xD(s, t.layoutBox, i.layoutBox, o);
- let c = bE();
- xD(c, n, a.layoutBox, o), kD(s, c) || (l = !0), r.options.layoutRoot && (e.relativeTarget = c, e.relativeTargetOrigin = s, e.relativeParent = r);
+ let o = e.options.layoutAnchor || void 0, s = hE();
+ gD(s, t.layoutBox, i.layoutBox, o);
+ let c = hE();
+ gD(c, n, a.layoutBox, o), wD(s, c) || (l = !0), r.options.layoutRoot && (e.relativeTarget = c, e.relativeTargetOrigin = s, e.relativeParent = r);
}
}
}
@@ -32238,59 +32238,59 @@ function Cse(e) {
}
e.options.transition = void 0;
}
-function wse(e) {
- mE.value && BD.nodes++, e.parent && (e.isProjecting() || (e.isProjectionDirty = e.parent.isProjectionDirty), e.isSharedProjectionDirty ||= !!(e.isProjectionDirty || e.parent.isProjectionDirty || e.parent.isSharedProjectionDirty), e.isTransformDirty ||= e.parent.isTransformDirty);
+function kse(e) {
+ lE.value && FD.nodes++, e.parent && (e.isProjecting() || (e.isProjectionDirty = e.parent.isProjectionDirty), e.isSharedProjectionDirty ||= !!(e.isProjectionDirty || e.parent.isProjectionDirty || e.parent.isSharedProjectionDirty), e.isTransformDirty ||= e.parent.isTransformDirty);
}
-function Tse(e) {
+function Ase(e) {
e.isProjectionDirty = e.isSharedProjectionDirty = e.isTransformDirty = !1;
}
-function Ese(e) {
+function jse(e) {
e.clearSnapshot();
}
-function GD(e) {
+function BD(e) {
e.clearMeasurements();
}
-function Dse(e) {
+function Mse(e) {
e.isLayoutDirty = !0, e.updateLayout();
}
-function KD(e) {
+function VD(e) {
e.isLayoutDirty = !1;
}
-function Ose(e) {
+function Nse(e) {
e.isAnimationBlocked && e.layout && !e.isLayoutDirty && (e.snapshot = e.layout, e.isLayoutDirty = !0);
}
-function kse(e) {
+function Pse(e) {
let { visualElement: t } = e.options;
t && t.getProps().onBeforeLayoutMeasure && t.notify("BeforeLayoutMeasure"), e.resetTransform();
}
-function qD(e) {
+function HD(e) {
e.finishAnimation(), e.targetDelta = e.relativeTarget = e.target = void 0, e.isProjectionDirty = !0;
}
-function Ase(e) {
+function Fse(e) {
e.resolveTargetDelta();
}
-function jse(e) {
+function Ise(e) {
e.calcProjection();
}
-function Mse(e) {
+function Lse(e) {
e.resetSkewAndRotation();
}
-function Nse(e) {
+function Rse(e) {
e.removeLeadSnapshot();
}
-function JD(e, t, n) {
- e.translate = uw(t.translate, 0, n), e.scale = uw(t.scale, 1, n), e.origin = t.origin, e.originPoint = t.originPoint;
+function UD(e, t, n) {
+ e.translate = YC(t.translate, 0, n), e.scale = YC(t.scale, 1, n), e.origin = t.origin, e.originPoint = t.originPoint;
}
-function YD(e, t, n, r) {
- e.min = uw(t.min, n.min, r), e.max = uw(t.max, n.max, r);
+function WD(e, t, n, r) {
+ e.min = YC(t.min, n.min, r), e.max = YC(t.max, n.max, r);
}
-function Pse(e, t, n, r) {
- YD(e.x, t.x, n.x, r), YD(e.y, t.y, n.y, r);
+function zse(e, t, n, r) {
+ WD(e.x, t.x, n.x, r), WD(e.y, t.y, n.y, r);
}
-function Fse(e) {
+function Bse(e) {
return e.animationValues && e.animationValues.opacityExit !== void 0;
}
-var Ise = {
+var Vse = {
duration: .45,
ease: [
.4,
@@ -32298,39 +32298,39 @@ var Ise = {
.1,
1
]
-}, XD = (e) => typeof navigator < "u" && navigator.userAgent && navigator.userAgent.toLowerCase().includes(e), ZD = XD("applewebkit/") && !XD("chrome/") ? Math.round : aC;
-function QD(e) {
- e.min = ZD(e.min), e.max = ZD(e.max);
+}, GD = (e) => typeof navigator < "u" && navigator.userAgent && navigator.userAgent.toLowerCase().includes(e), KD = GD("applewebkit/") && !GD("chrome/") ? Math.round : jS;
+function qD(e) {
+ e.min = KD(e.min), e.max = KD(e.max);
}
-function Lse(e) {
- QD(e.x), QD(e.y);
+function Hse(e) {
+ qD(e.x), qD(e.y);
}
-function $D(e, t, n) {
- return e === "position" || e === "preserve-aspect" && !ise(AD(t), AD(n), .2);
+function JD(e, t, n) {
+ return e === "position" || e === "preserve-aspect" && !lse(TD(t), TD(n), .2);
}
-function Rse(e) {
+function Use(e) {
return e !== e.root && e.scroll?.wasRoot;
}
//#endregion
//#region node_modules/motion-dom/dist/es/projection/node/DocumentProjectionNode.mjs
-var zse = WD({
- attachResizeListener: (e, t) => LD(e, "resize", t),
+var Wse = zD({
+ attachResizeListener: (e, t) => MD(e, "resize", t),
measureScroll: () => ({
x: document.documentElement.scrollLeft || document.body?.scrollLeft || 0,
y: document.documentElement.scrollTop || document.body?.scrollTop || 0
}),
checkIsScrollRoot: () => !0
-}), eO = { current: void 0 }, tO = WD({
+}), YD = { current: void 0 }, XD = zD({
measureScroll: (e) => ({
x: e.scrollLeft,
y: e.scrollTop
}),
defaultParent: () => {
- if (!eO.current) {
- let e = new zse({});
- e.mount(window), e.setOptions({ layoutScroll: !0 }), eO.current = e;
+ if (!YD.current) {
+ let e = new Wse({});
+ e.mount(window), e.setOptions({ layoutScroll: !0 }), YD.current = e;
}
- return eO.current;
+ return YD.current;
},
resetTransform: (e, t) => {
e.style.transform = t === void 0 ? "none" : t;
@@ -32339,18 +32339,18 @@ var zse = WD({
});
//#endregion
//#region node_modules/framer-motion/dist/es/animation/animators/waapi/animate-elements.mjs
-function Bse(e, t, n, r) {
+function Gse(e, t, n, r) {
if (e == null) return [];
- let i = KT(e, r), a = i.length, o = [];
+ let i = VT(e, r), a = i.length, o = [];
for (let e = 0; e < a; e++) {
let r = i[e], s = { ...n };
typeof s.delay == "function" && (s.delay = s.delay(e, a));
for (let e in t) {
let n = t[e];
Array.isArray(n) || (n = [n]);
- let i = { ...xT(s, e) };
- i.duration &&= /* @__PURE__ */ lC(i.duration), i.delay &&= /* @__PURE__ */ lC(i.delay);
- let a = Dae(r), c = Eae(e, i.pseudoElement || ""), l = a.get(c);
+ let i = { ...gT(s, e) };
+ i.duration &&= /* @__PURE__ */ FS(i.duration), i.delay &&= /* @__PURE__ */ FS(i.delay);
+ let a = Mae(r), c = jae(e, i.pseudoElement || ""), l = a.get(c);
l && l.stop(), o.push({
map: a,
key: c,
@@ -32366,40 +32366,40 @@ function Bse(e, t, n, r) {
}
for (let e = 0; e < o.length; e++) {
let { unresolvedKeyframes: t, options: n } = o[e], { element: r, name: i, pseudoElement: a } = n;
- !a && t[0] === null && (t[0] = oE(r, i)), Pw(t), roe(t, i), !a && t.length < 2 && t.unshift(oE(r, i)), n.keyframes = t;
+ !a && t[0] === null && (t[0] = tE(r, i)), kw(t), coe(t, i), !a && t.length < 2 && t.unshift(tE(r, i)), n.keyframes = t;
}
let s = [];
for (let e = 0; e < o.length; e++) {
- let { map: t, key: n, options: r } = o[e], i = new cT(r);
+ let { map: t, key: n, options: r } = o[e], i = new rT(r);
t.set(n, i), i.finished.finally(() => t.delete(n)), s.push(i);
}
return s;
}
-var Vse = /*@__PURE__*/ ((e) => {
+var Kse = /*@__PURE__*/ ((e) => {
function t(t, n, r) {
- return new Tae(Bse(t, n, r, e));
+ return new Aae(Gse(t, n, r, e));
}
return t;
-})(), nO = (e, t) => Math.abs(e - t);
-function Hse(e, t) {
- let n = nO(e.x, t.x), r = nO(e.y, t.y);
+})(), ZD = (e, t) => Math.abs(e - t);
+function qse(e, t) {
+ let n = ZD(e.x, t.x), r = ZD(e.y, t.y);
return Math.sqrt(n ** 2 + r ** 2);
}
//#endregion
//#region src/react/components/use-moving-surface.ts
-var Use = {
+var Jse = {
selection: {
- type: Tw,
+ type: bw,
duration: .16,
bounce: 0
},
hover: {
- type: Tw,
+ type: bw,
duration: .08,
bounce: 0
}
};
-function rO(e) {
+function QD(e) {
let [t, n] = (0, R.useState)(null);
return (0, R.useLayoutEffect)(() => {
if (!t) return;
@@ -32420,7 +32420,7 @@ function rO(e) {
let E = `translate(${b}px, ${x}px) scale(1, 1)`;
if (u && a && !r.matches && T && s !== h) {
let r = `translate(${(T.left - _.left) / v + t.scrollLeft - t.clientLeft}px, ${(T.top - _.top) / y + t.scrollTop - t.clientTop}px) scale(${T.width / v / S}, ${T.height / y / C})`;
- l = Vse(n, { transform: [r, E] }, Use[e]);
+ l = Kse(n, { transform: [r, E] }, Jse[e]);
} else n.style.transform = E;
s = h, c = w, t.dataset.surfaceReady = "";
}, m = (t) => {
@@ -32457,9 +32457,9 @@ function rO(e) {
}
//#endregion
//#region src/react/components/menu-dialog.tsx
-function iO(e) {
- let t = rO("hover");
- return /* @__PURE__ */ (0, z.jsx)(Fg, {
+function $D(e) {
+ let t = QD("hover");
+ return /* @__PURE__ */ (0, z.jsx)(Ig, {
...e,
ref: t
});
@@ -32470,67 +32470,67 @@ function iO(e) {
}).medium;
//#endregion
//#region src/management.ts
-var Wse = "扫描媒体文件夹,导入已有资料,采集缺失信息。两段也可以分开跑:新盘刚接上时先只扫描,几万个文件登记完就能用;采集被网络拖住时只重跑采集,不必再扫一遍磁盘。", Gse = "修缺时间戳表(播放卡顿)和缺索引(打不开)的 MP4。常看的片子先修。", Kse = Zi({
+var Yse = "扫描媒体文件夹,导入已有资料,采集缺失信息。两段也可以分开跑:新盘刚接上时先只扫描,几万个文件登记完就能用;采集被网络拖住时只重跑采集,不必再扫一遍磁盘。", Xse = "修缺时间戳表(播放卡顿)和缺索引(打不开)的 MP4。常看的片子先修。", Zse = Zi({
padding: "none",
bordered: "line",
className: "overflow-hidden"
-}), qse = {
+}), Qse = {
split: "min-w-0 p-6",
stack: "flex min-h-30 min-w-0 flex-1 flex-col px-5 pt-5 pb-4 max-cleanup-tight:min-h-0 max-cleanup-tight:p-4.5"
-}, Jse = {
+}, $se = {
split: "flex flex-wrap items-center justify-end gap-2 self-stretch p-6 max-[1001px]:justify-start max-[1001px]:pt-0",
stack: "flex min-h-14 flex-wrap items-center justify-end gap-2 border-t border-border-button-default bg-card-footer px-5 py-3 max-cleanup-tight:px-4.5"
-}, Yse = "flex min-h-14 flex-wrap items-center justify-end gap-2 border-t px-5 py-3", Xse = {
+}, ece = "flex min-h-14 flex-wrap items-center justify-end gap-2 border-t px-5 py-3", tce = {
neutral: "border-border-button-default bg-card-footer",
error: "border-border-error-default bg-background-tertiary-error"
-}, Zse = Zi({
+}, nce = Zi({
padding: "none",
radius: "surface",
bordered: "line",
className: "overflow-hidden"
-}), aO = "border-t border-border-button-default p-4 first:border-t-0";
-function oO({ tone: e = "neutral", status: t, children: n }) {
+}), eO = "border-t border-border-button-default p-4 first:border-t-0";
+function tO({ tone: e = "neutral", status: t, children: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
- className: `${Yse} ${Xse[e]}`,
+ className: `${ece} ${tce[e]}`,
children: [t ? /* @__PURE__ */ (0, z.jsx)("p", {
className: `mr-auto min-w-0 text-caption-1-regular ${e === "error" ? "text-text-error-primary" : "text-text-secondary"}`,
children: t
}) : null, n]
});
}
-function sO({ id: e, children: t }) {
+function nO({ id: e, children: t }) {
return /* @__PURE__ */ (0, z.jsx)("h2", {
id: e,
className: "text-title-2-medium! m-0! text-text-primary",
children: t
});
}
-function cO({ id: e, gap: t = "none", children: n }) {
+function rO({ id: e, gap: t = "none", children: n }) {
return /* @__PURE__ */ (0, z.jsx)("h3", {
id: e,
className: `text-title-2-medium text-text-primary ${t === "medium" ? "mb-3" : t === "small" ? "mb-2" : ""}`,
children: n
});
}
-function lO({ layout: e, label: t, labelledBy: n, id: r, footer: i, children: a, attributes: o }) {
+function iO({ layout: e, label: t, labelledBy: n, id: r, footer: i, children: a, attributes: o }) {
return /* @__PURE__ */ (0, z.jsxs)("section", {
id: r,
"aria-label": t,
"aria-labelledby": n,
...o,
- className: `${Kse} ${e === "split" ? "fieldset-split" : "flex flex-col"}`,
+ className: `${Zse} ${e === "split" ? "fieldset-split" : "flex flex-col"}`,
children: [/* @__PURE__ */ (0, z.jsx)("div", {
- className: qse[e],
+ className: Qse[e],
children: a
}), i ? /* @__PURE__ */ (0, z.jsx)("footer", {
- className: Jse[e],
+ className: $se[e],
children: i
}) : null]
});
}
//#endregion
//#region src/react/components/overlay-scrollbar.ts
-function uO() {
+function aO() {
let e = (0, R.useRef)(null);
return (0, R.useEffect)(() => {
v(e.current);
@@ -32538,7 +32538,7 @@ function uO() {
}
//#endregion
//#region src/react/boardui/components/base/buttons/icon-button.tsx
-var dO = Li({
+var oO = Li({
base: [
"relative inline-flex shrink-0 items-center justify-center overflow-visible rounded-2lg",
"bg-background-primary-default text-foreground-icon-primary",
@@ -32559,21 +32559,21 @@ var dO = Li({
small: "size-4 shrink-0"
}
});
-function fO({ icon: e, size: t = "medium", className: n, type: r = "button", ref: i, ...a }) {
+function sO({ icon: e, size: t = "medium", className: n, type: r = "button", ref: i, ...a }) {
return /* @__PURE__ */ (0, z.jsx)("button", {
ref: i,
type: r,
- className: Ii(dO.base, dO.size[t], n),
+ className: Ii(oO.base, oO.size[t], n),
...a,
children: /* @__PURE__ */ (0, z.jsx)(e, {
- className: dO.icon[t],
+ className: oO.icon[t],
"aria-hidden": !0
})
});
}
//#endregion
//#region src/react/components/path-line.tsx
-function Qse({ className: e }) {
+function rce({ className: e }) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
"aria-hidden": !0,
viewBox: "0 0 24 24",
@@ -32586,8 +32586,8 @@ function Qse({ className: e }) {
children: /* @__PURE__ */ (0, z.jsx)("use", { href: "#i-folder-open" })
});
}
-var $se = "打开文件管理器失败,请重试";
-function pO({ path: e, prefix: t, className: n, onRevealed: r }) {
+var ice = "打开文件管理器失败,请重试";
+function cO({ path: e, prefix: t, className: n, onRevealed: r }) {
let [i, a] = (0, R.useState)(!1), [o, s] = (0, R.useState)(""), c = (0, R.useRef)(!0);
(0, R.useEffect)(() => () => {
c.current = !1;
@@ -32598,7 +32598,7 @@ function pO({ path: e, prefix: t, className: n, onRevealed: r }) {
try {
await G("/api/reveal", { path: e }), r?.("已在资源管理器中显示");
} catch (e) {
- c.current && s(e instanceof Hi ? e.message : $se);
+ c.current && s(e instanceof Hi ? e.message : ice);
} finally {
c.current && a(!1);
}
@@ -32611,8 +32611,8 @@ function pO({ path: e, prefix: t, className: n, onRevealed: r }) {
children: [/* @__PURE__ */ (0, z.jsxs)("p", {
className: Ii("min-w-0 break-all", n),
children: [t, e]
- }), /* @__PURE__ */ (0, z.jsx)(fO, {
- icon: Qse,
+ }), /* @__PURE__ */ (0, z.jsx)(sO, {
+ icon: rce,
size: "small",
className: "shrink-0",
"aria-label": "在资源管理器中显示",
@@ -32627,7 +32627,7 @@ function pO({ path: e, prefix: t, className: n, onRevealed: r }) {
}
//#endregion
//#region src/react/components/task-progress.tsx
-function mO({ label: e, value: t = 0, total: n, embedded: r = !1 }) {
+function lO({ label: e, value: t = 0, total: n, embedded: r = !1 }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-task-progress": !0,
className: r ? "flex flex-col gap-1.5" : Zi({
@@ -32647,18 +32647,18 @@ function mO({ label: e, value: t = 0, total: n, embedded: r = !1 }) {
}
//#endregion
//#region src/react/library-processing/use-library-processing.ts
-function hO({ toast: e, mode: t, monitor: n }) {
+function uO({ toast: e, mode: t, monitor: n }) {
let r = t === "notice" || !!n, i = $n({
- queryKey: Kb,
- queryFn: ({ signal: e }) => qb(e),
- refetchInterval: (e) => ure(e.state.data, r)
+ queryKey: Zb,
+ queryFn: ({ signal: e }) => Qb(e),
+ refetchInterval: (e) => are(e.state.data, r)
}), [a, o] = (0, R.useState)(null), s = (0, R.useRef)(void 0), c = i.data;
return (0, R.useEffect)(() => {
if (!c) return;
let n = s.current;
s.current = c.status;
let r = n === "running" && c.status !== "running";
- r && o(c), (r || t === "notice") && hre(c, e, r);
+ r && o(c), (r || t === "notice") && ure(c, e, r);
}, [
c,
t,
@@ -32671,7 +32671,7 @@ function hO({ toast: e, mode: t, monitor: n }) {
}
//#endregion
//#region src/react/library-processing/library-processing-card.tsx
-var ece = [
+var ace = [
{
label: "扫描并补全资料",
icon: Qe,
@@ -32687,13 +32687,13 @@ var ece = [
icon: it,
command: { stage: "collect" }
}
-], tce = Ii(uy, dy, "text-body-2-medium"), nce = "这一项耗时较长,暂时没有新进展。任务结束后可以重试未完成的部分。", rce = (e) => {
+], oce = Ii(hy, gy, "text-body-2-medium"), sce = "这一项耗时较长,暂时没有新进展。任务结束后可以重试未完成的部分。", cce = (e) => {
let t = e.performer_aliases || 0, n = e.performer_avatars || 0, r = e.performer_profile_conflicts || 0, i = e.performer_profile_failed || 0;
if (!t && !n && !r && !i) return "";
let a = [`补齐女优资料:别名 ${t} 个,头像 ${n} 张`];
return r && a.push(`${r} 个同名冲突交回人工`), i && a.push(`${i} 张头像未取得`), `${a.join(",")}。`;
-}, ice = (e) => `已扫描 ${e.scanned || 0} 个文件,识别 ${e.identified || 0} 个番号,整理 ${e.candidates || 0} 组资料候选,自动落库 ${e.auto_applied || 0} 条。` + rce(e);
-function ace({ busy: e, onRun: t }) {
+}, lce = (e) => `已扫描 ${e.scanned || 0} 个文件,识别 ${e.identified || 0} 个番号,整理 ${e.candidates || 0} 组资料候选,自动落库 ${e.auto_applied || 0} 条。` + cce(e);
+function uce({ busy: e, onRun: t }) {
let n = (0, R.useRef)(null), [r, i] = (0, R.useState)(!1), a = (n) => {
e || (i(!1), t(n));
};
@@ -32724,13 +32724,13 @@ function ace({ busy: e, onRun: t }) {
onOpenChange: i,
placement: "bottom end",
offset: 4,
- className: ly,
- children: /* @__PURE__ */ (0, z.jsx)(iO, {
+ className: my,
+ children: /* @__PURE__ */ (0, z.jsx)($D, {
"aria-label": "更多扫描与采集方式",
className: "flex w-52 flex-col gap-1 outline-none",
- children: ece.map(({ label: e, icon: t, command: n }) => /* @__PURE__ */ (0, z.jsxs)("button", {
+ children: ace.map(({ label: e, icon: t, command: n }) => /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
- className: tce,
+ className: oce,
onClick: () => a(n),
children: [/* @__PURE__ */ (0, z.jsx)(t, {
"aria-hidden": !0,
@@ -32740,8 +32740,8 @@ function ace({ busy: e, onRun: t }) {
})
})] });
}
-function oce({ state: e, problem: t, settled: n, onRetry: r, toast: i }) {
- let a = pre(e), o = e.status === "failed" && !!e.retryable_asset_ids?.length, s = fre(e.notes || {}), c = uO();
+function dce({ state: e, problem: t, settled: n, onRetry: r, toast: i }) {
+ let a = cre(e), o = e.status === "failed" && !!e.retryable_asset_ids?.length, s = sre(e.notes || {}), c = aO();
return /* @__PURE__ */ (0, z.jsxs)("div", {
"aria-live": "polite",
className: "flex flex-col gap-4 empty:hidden",
@@ -32749,7 +32749,7 @@ function oce({ state: e, problem: t, settled: n, onRetry: r, toast: i }) {
e.status === "running" && e.stalled ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "warning",
title: "处理较慢",
- children: nce
+ children: sce
}) : null,
t || e.status === "failed" ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
@@ -32761,7 +32761,7 @@ function oce({ state: e, problem: t, settled: n, onRetry: r, toast: i }) {
}) : null,
extra: a ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "mt-1.5 border-t border-current/20 pt-1.5",
- children: /* @__PURE__ */ (0, z.jsxs)(Ay, {
+ children: /* @__PURE__ */ (0, z.jsxs)(Fy, {
summary: a.label,
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "relative",
@@ -32792,7 +32792,7 @@ function oce({ state: e, problem: t, settled: n, onRetry: r, toast: i }) {
})
}), a.log ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "mt-2 border-t border-current/20 pt-2 text-text-secondary",
- children: /* @__PURE__ */ (0, z.jsx)(pO, {
+ children: /* @__PURE__ */ (0, z.jsx)(cO, {
path: a.log,
prefix: "完整记录:",
className: "text-caption-1-regular",
@@ -32806,13 +32806,13 @@ function oce({ state: e, problem: t, settled: n, onRetry: r, toast: i }) {
n?.status === "complete" ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "success",
title: "处理完成",
- children: ice(n)
+ children: lce(n)
}) : null,
e.status !== "running" && s ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "neutral",
extra: e.issues_log ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "mt-1.5 border-t border-current/20 pt-1.5 text-text-secondary",
- children: /* @__PURE__ */ (0, z.jsx)(pO, {
+ children: /* @__PURE__ */ (0, z.jsx)(cO, {
path: e.issues_log,
prefix: "完整记录:",
className: "text-caption-1-regular",
@@ -32824,38 +32824,38 @@ function oce({ state: e, problem: t, settled: n, onRetry: r, toast: i }) {
]
});
}
-function gO(e) {
- let { toast: t, onComplete: n } = e, { job: r, settled: i, forget: a } = hO(e), o = er({
- mutationFn: (e) => G(Gb, e),
+function dO(e) {
+ let { toast: t, onComplete: n } = e, { job: r, settled: i, forget: a } = uO(e), o = er({
+ mutationFn: (e) => G(Xb, e),
onSuccess: (e) => {
- a(), X.setQueryData(Kb, e), X.invalidateQueries({ queryKey: Kb });
+ a(), X.setQueryData(Zb, e), X.invalidateQueries({ queryKey: Zb });
}
});
(0, R.useEffect)(() => {
i && n?.();
}, [i, n]);
- let s = r.data ?? { status: "idle" }, c = o.error ? U(o.error) : r.isError ? r.data ? Yb : U(r.error) : "", l = o.isPending || s.status === "running", u = Zb(s), d = (e) => {
+ let s = r.data ?? { status: "idle" }, c = o.error ? U(o.error) : r.isError ? r.data ? ex : U(r.error) : "", l = o.isPending || s.status === "running", u = nx(s), d = (e) => {
l || (o.reset(), o.mutate(e));
};
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-4",
- children: [/* @__PURE__ */ (0, z.jsx)(lO, {
+ children: [/* @__PURE__ */ (0, z.jsx)(iO, {
layout: "stack",
label: "扫描与采集",
footer: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
- /* @__PURE__ */ (0, z.jsx)(yy, {
+ /* @__PURE__ */ (0, z.jsx)(wy, {
href: "/scraping",
size: "small",
trailingIcon: We,
children: "来源和凭证"
}),
- s.candidates ? /* @__PURE__ */ (0, z.jsx)(yy, {
+ s.candidates ? /* @__PURE__ */ (0, z.jsx)(wy, {
href: "/review",
size: "small",
trailingIcon: We,
children: "复核资料"
}) : null,
- /* @__PURE__ */ (0, z.jsx)(ace, {
+ /* @__PURE__ */ (0, z.jsx)(uce, {
busy: l,
onRun: d
})
@@ -32863,12 +32863,12 @@ function gO(e) {
children: /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(cO, { children: "扫描与采集" }),
+ /* @__PURE__ */ (0, z.jsx)(rO, { children: "扫描与采集" }),
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
- children: Wse
+ children: Yse
}),
- s.status === "running" ? /* @__PURE__ */ (0, z.jsx)(mO, {
+ s.status === "running" ? /* @__PURE__ */ (0, z.jsx)(lO, {
embedded: !0,
label: u,
value: s.checked,
@@ -32876,7 +32876,7 @@ function gO(e) {
}) : null
]
})
- }), /* @__PURE__ */ (0, z.jsx)(oce, {
+ }), /* @__PURE__ */ (0, z.jsx)(dce, {
state: s,
problem: c,
settled: i,
@@ -32892,9 +32892,9 @@ function gO(e) {
}
//#endregion
//#region src/react/background-job.ts
-var _O = 2e3, sce = (e) => e, cce = (e, t) => t;
-function vO(e) {
- let { queryKey: t, jobOf: n = sce, withJob: r = cce, idlePollMs: i } = e, [a, o] = (0, R.useState)(!1), [s, c] = (0, R.useState)(null), l = (0, R.useRef)(e);
+var fO = 2e3, fce = (e) => e, pce = (e, t) => t;
+function pO(e) {
+ let { queryKey: t, jobOf: n = fce, withJob: r = pce, idlePollMs: i } = e, [a, o] = (0, R.useState)(!1), [s, c] = (0, R.useState)(null), l = (0, R.useRef)(e);
(0, R.useEffect)(() => {
l.current = e;
});
@@ -32903,7 +32903,7 @@ function vO(e) {
queryFn: ({ signal: e }) => l.current.queryFn({ signal: e }),
refetchInterval: (e) => {
let t = e.state.data;
- return t !== void 0 && n(t)?.status === "running" ? _O : i ?? !1;
+ return t !== void 0 && n(t)?.status === "running" ? fO : i ?? !1;
}
}), d = er({
mutationFn: (e) => l.current.start(e),
@@ -32934,32 +32934,32 @@ function vO(e) {
}
//#endregion
//#region src/react/media-repair/media-repair-card.tsx
-var lce = (e) => _[e] || e, yO = (e) => X.setQueryData(ex, e);
-function uce() {
+var mce = (e) => _[e] || e, mO = (e) => X.setQueryData(ax, e);
+function hce() {
let e = $n({
- queryKey: ex,
- queryFn: ({ signal: e }) => nx(e),
- refetchInterval: (e) => e.state.data?.status === "running" && _O
+ queryKey: ax,
+ queryFn: ({ signal: e }) => sx(e),
+ refetchInterval: (e) => e.state.data?.status === "running" && fO
}), t = $n({
- queryKey: tx,
- queryFn: ({ signal: e }) => rx(e)
- }), [n, r] = (0, R.useState)(""), i = aa(), a = e.data ?? gre, o = t.data ?? [], s = a.status === "running", c = o.find((e) => e.id === (s ? a.library : n)) ?? o.find((e) => e.id === a.library) ?? o[0], l = () => {
+ queryKey: ox,
+ queryFn: ({ signal: e }) => cx(e)
+ }), [n, r] = (0, R.useState)(""), i = aa(), a = e.data ?? dre, o = t.data ?? [], s = a.status === "running", c = o.find((e) => e.id === (s ? a.library : n)) ?? o.find((e) => e.id === a.library) ?? o[0], l = () => {
c && b({
title: `修复媒体库「${c.name}」`,
body: "缺时间戳表的片子另存一份修好的头,原文件不动;缺索引的片子重建后替换原文件,坏原件改名成同目录的隐藏文件(.文件名.peach-original)留着。" + (c.metered ? "这个库在计费来源上,每修一部都要把片子完整拉一遍。" : ""),
confirmLabel: "修复媒体库",
- onConfirm: async () => yO(await G($b, {
+ onConfirm: async () => mO(await G(ix, {
library: c.id,
restart: !0
}))
});
- }, u = () => void i.run("stop", (e) => G($b, { stop: !0 }, "POST", e), yO), d = vre(a), f = a.status === "complete", p = i.error || a.error || (e.error ? "读不到媒体修复的状态" : "");
+ }, u = () => void i.run("stop", (e) => G(ix, { stop: !0 }, "POST", e), mO), d = pre(a), f = a.status === "complete", p = i.error || a.error || (e.error ? "读不到媒体修复的状态" : "");
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-4",
- children: [/* @__PURE__ */ (0, z.jsx)(lO, {
+ children: [/* @__PURE__ */ (0, z.jsx)(iO, {
layout: "split",
label: "媒体修复",
- footer: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(py, {
+ footer: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "媒体库",
className: "w-48",
selectedKey: c?.id ?? null,
@@ -32967,10 +32967,10 @@ function uce() {
onSelectionChange: (e) => {
e !== null && r(String(e));
},
- children: o.map((e) => /* @__PURE__ */ (0, z.jsxs)(my, {
+ children: o.map((e) => /* @__PURE__ */ (0, z.jsxs)(yy, {
id: e.id,
textValue: e.name,
- children: [/* @__PURE__ */ (0, z.jsx)(jy, { mark: lce(e.icon) }), e.name]
+ children: [/* @__PURE__ */ (0, z.jsx)(Iy, { mark: mce(e.icon) }), e.name]
}, e.id))
}), s ? /* @__PURE__ */ (0, z.jsx)(H, {
onClick: u,
@@ -32984,10 +32984,10 @@ function uce() {
children: /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(cO, { children: "媒体修复" }),
+ /* @__PURE__ */ (0, z.jsx)(rO, { children: "媒体修复" }),
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
- children: Gse
+ children: Xse
}),
s && a.total ? /* @__PURE__ */ (0, z.jsx)(ia, {
label: "修复进度",
@@ -33013,7 +33013,7 @@ function uce() {
f && a.missing_tool ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "warning",
title: "缺少 untrunc",
- children: yre(a)
+ children: mre(a)
}) : null,
p ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
@@ -33025,7 +33025,7 @@ function uce() {
}
//#endregion
//#region src/react/boardui/components/base/checkbox/checkbox-glyph.tsx
-var bO = {
+var hO = {
md: {
box: "size-4",
glyph: "size-4",
@@ -33039,8 +33039,8 @@ var bO = {
gap: "gap-1.5"
}
};
-function xO({ state: e, size: t = "md" }) {
- let { isSelected: n, isIndeterminate: r, isFocusVisible: i, isDisabled: a, isHovered: o } = e, s = bO[t], c = n || r, l = o && !a;
+function gO({ state: e, size: t = "md" }) {
+ let { isSelected: n, isIndeterminate: r, isFocusVisible: i, isDisabled: a, isHovered: o } = e, s = hO[t], c = n || r, l = o && !a;
return /* @__PURE__ */ (0, z.jsx)("span", {
"aria-hidden": !0,
className: Ii("flex shrink-0 items-center justify-center rounded-sm", "transition-[background-color,border-color,box-shadow] duration-150 ease", s.box, c ? Ii("bg-linear-to-b shadow-checkbox-selected", l ? "from-accent-400 to-accent-500" : "from-accent-500 to-accent-600") : Ii("border bg-background-primary-default shadow-xs", l ? "border-border-checkbox-hover" : "border-border-checkbox-default"), a && "opacity-50", i && "ring-2 ring-border-focus-ring ring-offset-2"),
@@ -33067,13 +33067,13 @@ function xO({ state: e, size: t = "md" }) {
}
//#endregion
//#region src/react/boardui/components/base/checkbox/checkbox.tsx
-function SO({ className: e, children: t, size: n = "md", ref: r, ...i }) {
- let a = bO[n];
+function _O({ className: e, children: t, size: n = "md", ref: r, ...i }) {
+ let a = hO[n];
return /* @__PURE__ */ (0, z.jsx)(ld, {
ref: r,
...i,
className: (t) => Ii("group inline-flex items-center select-none", a.gap, t.isDisabled ? "cursor-not-allowed" : "cursor-pointer", typeof e == "function" ? e(t) : e),
- children: (e) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(xO, {
+ children: (e) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(gO, {
state: e,
size: n
}), t != null && /* @__PURE__ */ (0, z.jsx)("span", {
@@ -33084,10 +33084,10 @@ function SO({ className: e, children: t, size: n = "md", ref: r, ...i }) {
}
//#endregion
//#region src/react/boardui/components/base/table/table.tsx
-function CO({ size: e = "md", className: t, containerClassName: n, ref: r, ...i }) {
+function vO({ size: e = "md", className: t, containerClassName: n, ref: r, ...i }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
className: Ii("w-full overflow-x-auto", n),
- children: /* @__PURE__ */ (0, z.jsx)(wte, {
+ children: /* @__PURE__ */ (0, z.jsx)(Lv, {
ref: r,
...i,
className: Ii("bui-table", e === "sm" && "bui-table-sm", t)
@@ -33096,7 +33096,7 @@ function CO({ size: e = "md", className: t, containerClassName: n, ref: r, ...i
}
//#endregion
//#region src/react/components/row-click.ts
-var dce = [
+var gce = [
"a",
"button",
"input",
@@ -33109,15 +33109,15 @@ var dce = [
"[role=\"link\"]",
"[role=\"menu\"]"
].join(",");
-function wO(e, t) {
+function yO(e, t) {
let n = e.target;
if (!(n instanceof Element) || !t.contains(n)) return !1;
- let r = n.closest(dce);
+ let r = n.closest(gce);
return !r || !t.contains(r) || r === t;
}
//#endregion
//#region src/react/components/data-table-frame.tsx
-function TO({ children: e, follow: t = !1, onRowClick: n }) {
+function bO({ children: e, follow: t = !1, onRowClick: n }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-board-data-table": !0,
"data-follow-table": t || void 0,
@@ -33125,15 +33125,15 @@ function TO({ children: e, follow: t = !1, onRowClick: n }) {
let t = e.target;
if (!(t instanceof Element)) return;
let r = t.closest("[role=\"row\"][data-key]");
- r && wO(e, r) && n(r.dataset.key);
+ r && yO(e, r) && n(r.dataset.key);
} : void 0,
children: e
});
}
//#endregion
//#region src/react/data-cleanup/link-manager.tsx
-var fce = Ob("unlink"), EO = Ob("rotate-cw"), pce = "站点返回 404 或 410,确认这个地址不存在。", mce = "站点拒绝程序访问或一次临时故障都会落在这里。链接保留,可勾选后单独重试。", hce = "删除前会逐条重验一次;此操作不可撤销。", gce = "暂时无法读取进度,正在重新连接…", DO = (e) => Number(e || 0).toLocaleString();
-function OO({ label: e, value: t, note: n }) {
+var _ce = Ob("unlink"), xO = Ob("rotate-cw"), vce = "站点返回 404 或 410,确认这个地址不存在。", yce = "站点拒绝程序访问或一次临时故障都会落在这里。链接保留,可勾选后单独重试。", bce = "删除前会逐条重验一次;此操作不可撤销。", xce = "暂时无法读取进度,正在重新连接…", SO = (e) => Number(e || 0).toLocaleString();
+function CO({ label: e, value: t, note: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-w-0 flex-col gap-0.5",
children: [
@@ -33152,11 +33152,11 @@ function OO({ label: e, value: t, note: n }) {
]
});
}
-function kO({ title: e, items: t, hint: n, picked: r, onPick: i, children: a }) {
+function wO({ title: e, items: t, hint: n, picked: r, onPick: i, children: a }) {
if (!t.length) return null;
let o = r ?? [], s = o.length > 0 && o.length === t.length;
return /* @__PURE__ */ (0, z.jsxs)("div", {
- className: aO,
+ className: eO,
children: [
/* @__PURE__ */ (0, z.jsxs)("h4", {
className: "mb-1 text-body-semibold text-text-primary",
@@ -33169,13 +33169,13 @@ function kO({ title: e, items: t, hint: n, picked: r, onPick: i, children: a })
className: "mb-3 text-caption-1-regular text-text-secondary",
children: n
}),
- /* @__PURE__ */ (0, z.jsx)(TO, { children: /* @__PURE__ */ (0, z.jsxs)(CO, {
+ /* @__PURE__ */ (0, z.jsx)(bO, { children: /* @__PURE__ */ (0, z.jsxs)(vO, {
"aria-label": e,
size: "sm",
- children: [/* @__PURE__ */ (0, z.jsxs)(Iv, { children: [
- i ? /* @__PURE__ */ (0, z.jsx)(zv, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(Wv, { children: [
+ i ? /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "pick",
- children: /* @__PURE__ */ (0, z.jsx)(SO, {
+ children: /* @__PURE__ */ (0, z.jsx)(_O, {
slot: null,
"aria-label": "全选本次未访问成功的链接",
isSelected: s,
@@ -33183,44 +33183,44 @@ function kO({ title: e, items: t, hint: n, picked: r, onPick: i, children: a })
onChange: (e) => i(e ? t.map((e) => e.id) : [])
})
}) : null,
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "entity",
isRowHeader: !0,
children: "所属"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "kind",
children: "类型"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "label",
children: "标签"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "note",
children: "结果"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "url",
children: "地址"
})
- ] }), /* @__PURE__ */ (0, z.jsx)(Vv, { children: t.map((e) => /* @__PURE__ */ (0, z.jsxs)(Wv, {
+ ] }), /* @__PURE__ */ (0, z.jsx)(Jv, { children: t.map((e) => /* @__PURE__ */ (0, z.jsxs)(Zv, {
id: e.id,
children: [
- i ? /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsx)(SO, {
+ i ? /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsx)(_O, {
slot: null,
"aria-label": `选择 ${e.entity} 的${e.label || e.url}`,
isSelected: o.includes(e.id),
onChange: (t) => i(t ? [...o, e.id] : o.filter((t) => t !== e.id))
}) }) : null,
- /* @__PURE__ */ (0, z.jsx)(qv, { children: e.entity }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: Dx[e.link_kind] || e.link_kind }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: e.label || "" }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsx)("span", {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: e.entity }),
+ /* @__PURE__ */ (0, z.jsx)($v, { children: Mx[e.link_kind] || e.link_kind }),
+ /* @__PURE__ */ (0, z.jsx)($v, { children: e.label || "" }),
+ /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsx)("span", {
className: "tabular-nums text-text-error-primary",
children: e.note
}) }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsxs)("a", {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsxs)("a", {
href: e.url,
target: "_blank",
rel: "noreferrer",
@@ -33242,27 +33242,27 @@ function kO({ title: e, items: t, hint: n, picked: r, onPick: i, children: a })
]
});
}
-function _ce() {
+function Sce() {
let e = $n({
- queryKey: wx,
- queryFn: ({ signal: e }) => kx(e)
- }), [t, n] = (0, R.useState)([]), r = vO({
- queryKey: Ex,
- queryFn: ({ signal: e }) => jx(e),
- start: qre,
+ queryKey: kx,
+ queryFn: ({ signal: e }) => Px(e)
+ }), [t, n] = (0, R.useState)([]), r = pO({
+ queryKey: jx,
+ queryFn: ({ signal: e }) => Ix(e),
+ start: Hre,
onFinish: () => {
X.invalidateQueries({
- queryKey: wx,
+ queryKey: kx,
exact: !0
}), X.invalidateQueries({
- queryKey: Tx,
+ queryKey: Ax,
exact: !0
});
}
- }), i = vO({
- queryKey: Tx,
- queryFn: ({ signal: e }) => Ax(e),
- start: Kre,
+ }), i = pO({
+ queryKey: Ax,
+ queryFn: ({ signal: e }) => Fx(e),
+ start: Vre,
onStarted: () => {
r.dismiss(), n([]);
}
@@ -33292,7 +33292,7 @@ function _ce() {
else if (_) x = /* @__PURE__ */ (0, z.jsx)(K, {
tone: "success",
title: "完成",
- children: Jre(_)
+ children: Ure(_)
});
else if (v) x = /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
@@ -33302,7 +33302,7 @@ function _ce() {
else if (i.query.isError && a) x = /* @__PURE__ */ (0, z.jsx)(K, {
tone: "neutral",
title: "任务状态",
- children: gce
+ children: xce
});
else if (a?.status === "failed") x = /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
@@ -33310,12 +33310,12 @@ function _ce() {
children: a.error || "检查失败"
});
else if (a && a.status !== "idle") {
- y = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [a.status === "running" ? /* @__PURE__ */ (0, z.jsx)(mO, {
+ y = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [a.status === "running" ? /* @__PURE__ */ (0, z.jsx)(lO, {
embedded: !0,
- label: Yre(a),
+ label: Wre(a),
value: a.checked,
total: a.total
- }) : null, c ? /* @__PURE__ */ (0, z.jsx)(mO, {
+ }) : null, c ? /* @__PURE__ */ (0, z.jsx)(lO, {
embedded: !0,
label: r.job?.message || "正在重验并删除失效链接…",
value: r.job?.checked,
@@ -33323,38 +33323,38 @@ function _ce() {
}) : null] });
let e = t.length ? `重试选中的 ${t.length} 条` : "重试选中的链接";
x = l || u.length || d.length ? /* @__PURE__ */ (0, z.jsxs)("div", {
- className: Zse,
+ className: nce,
children: [
- /* @__PURE__ */ (0, z.jsx)(kO, {
+ /* @__PURE__ */ (0, z.jsx)(wO, {
title: "地址已失效",
items: u,
- hint: pce
+ hint: vce
}),
- /* @__PURE__ */ (0, z.jsx)(kO, {
+ /* @__PURE__ */ (0, z.jsx)(wO, {
title: "本次未访问成功",
items: d,
- hint: mce,
+ hint: yce,
picked: f.length ? t : void 0,
onPick: f.length ? n : void 0,
children: f.length ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "-mx-4 mt-3 -mb-4",
- children: /* @__PURE__ */ (0, z.jsxs)(oO, { children: [/* @__PURE__ */ (0, z.jsx)(H, {
- leadingIcon: EO,
+ children: /* @__PURE__ */ (0, z.jsxs)(tO, { children: [/* @__PURE__ */ (0, z.jsx)(H, {
+ leadingIcon: xO,
disabled: !t.length,
...q(s),
onClick: () => h(t),
children: e
}), /* @__PURE__ */ (0, z.jsx)(H, {
- leadingIcon: EO,
+ leadingIcon: xO,
...q(s),
onClick: () => h(f.map((e) => e.id)),
children: `全部重试(${f.length})`
})] })
}) : null
}),
- l && u.length ? /* @__PURE__ */ (0, z.jsx)(oO, {
+ l && u.length ? /* @__PURE__ */ (0, z.jsx)(tO, {
tone: "error",
- status: hce,
+ status: bce,
children: /* @__PURE__ */ (0, z.jsx)(H, {
variant: "danger",
...q(c),
@@ -33363,7 +33363,7 @@ function _ce() {
})
}) : null,
l && !u.length && !d.length ? /* @__PURE__ */ (0, z.jsx)("p", {
- className: `${aO} text-body-regular text-notification-success-foreground`,
+ className: `${eO} text-body-regular text-notification-success-foreground`,
children: "全部链接均可访问。"
}) : null
]
@@ -33374,21 +33374,21 @@ function _ce() {
"aria-labelledby": "link-manager-title",
className: "flex scroll-mt-20 flex-col gap-4",
children: [
- /* @__PURE__ */ (0, z.jsx)(sO, {
+ /* @__PURE__ */ (0, z.jsx)(nO, {
id: "link-manager-title",
children: "链接管理"
}),
- /* @__PURE__ */ (0, z.jsxs)(lO, {
+ /* @__PURE__ */ (0, z.jsxs)(iO, {
layout: "stack",
labelledBy: "link-manager-box",
footer: /* @__PURE__ */ (0, z.jsx)(H, {
- leadingIcon: fce,
+ leadingIcon: _ce,
...q(s),
onClick: () => h(),
children: s ? "检查中" : l ? "重新检查" : "检查死链"
}),
children: [
- /* @__PURE__ */ (0, z.jsx)(cO, {
+ /* @__PURE__ */ (0, z.jsx)(rO, {
id: "link-manager-box",
gap: "small",
children: "站外链接"
@@ -33399,13 +33399,13 @@ function _ce() {
children: U(e.error)
}) : p ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "link-stat-grid mt-4 gap-x-8 gap-y-3",
- children: [/* @__PURE__ */ (0, z.jsx)(OO, {
+ children: [/* @__PURE__ */ (0, z.jsx)(CO, {
label: "链接总数",
- value: DO(p.total),
- note: `分布在 ${DO(p.entities)} 个女优、厂牌与系列`
- }), Object.entries(p.by_kind ?? {}).map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(OO, {
- label: Dx[e] || e,
- value: DO(t)
+ value: SO(p.total),
+ note: `分布在 ${SO(p.entities)} 个女优、厂牌与系列`
+ }), Object.entries(p.by_kind ?? {}).map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(CO, {
+ label: Mx[e] || e,
+ value: SO(t)
}, e))]
}), m ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: "mt-4 flex min-w-0 flex-col gap-0.5",
@@ -33434,18 +33434,18 @@ function _ce() {
}
//#endregion
//#region src/react/data-cleanup/organize-card.tsx
-var vce = (e) => `将按这两份模板改动「${e}」上的文件名与目录,目标已存在的行会整行跳过。这一批可以从「回滚上一批」整批退回。`, yce = "将把上一批整理动过的文件退回整理前的名字与位置,账本路径跟着退回。退回后这一批不再出现在这里。", bce = 8;
-function xce({ plan: e }) {
+var Cce = (e) => `将按这两份模板改动「${e}」上的文件名与目录,目标已存在的行会整行跳过。这一批可以从「回滚上一批」整批退回。`, wce = "将把上一批整理动过的文件退回整理前的名字与位置,账本路径跟着退回。退回后这一批不再出现在这里。", Tce = 8;
+function Ece({ plan: e }) {
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("ol", {
className: "mt-2 flex min-w-0 flex-col gap-1",
- children: e.rows.slice(0, bce).map((e) => /* @__PURE__ */ (0, z.jsxs)("li", {
+ children: e.rows.slice(0, Tce).map((e) => /* @__PURE__ */ (0, z.jsxs)("li", {
className: "flex min-w-0 items-center gap-2 text-caption-1-regular text-text-secondary",
children: [
/* @__PURE__ */ (0, z.jsx)("span", {
"data-middle-truncate": !0,
title: e.current_path,
className: "min-w-0 truncate",
- children: aS(e.current_path)
+ children: Yx(e.current_path)
}),
/* @__PURE__ */ (0, z.jsx)("span", {
"aria-hidden": !0,
@@ -33455,7 +33455,7 @@ function xce({ plan: e }) {
"data-middle-truncate": !0,
title: e.target_path,
className: "min-w-0 truncate text-text-primary",
- children: aS(e.target_path)
+ children: Yx(e.target_path)
})
]
}, e.current_path))
@@ -33464,10 +33464,10 @@ function xce({ plan: e }) {
children: "只列出前 8 行,完整计划在计划 CSV 里。"
}) : null] });
}
-function Sce({ toast: t, failure: n }) {
+function Dce({ toast: t, failure: n }) {
let r = $n({
- queryKey: Zx,
- queryFn: ({ signal: e }) => Qx(e)
+ queryKey: qx,
+ queryFn: ({ signal: e }) => Jx(e)
}), i = r.data, a = i?.locations ?? [], [o, s] = (0, R.useState)(""), c = a.some((e) => e.location === o) ? o : a[0]?.location ?? "", l = i?.templates?.[c], [u, d] = (0, R.useState)(null), f = u?.location === c ? u : {
location: c,
file: l?.file ?? "",
@@ -33480,8 +33480,8 @@ function Sce({ toast: t, failure: n }) {
file_template: f.file.trim(),
dir_template: f.dir.trim()
}), x = er({
- mutationFn: eS,
- onSuccess: (e, t) => void nS({
+ mutationFn: nie,
+ onSuccess: (e, t) => void iie({
...i?.templates ?? {},
[t.location]: {
file: t.file_template,
@@ -33489,29 +33489,29 @@ function Sce({ toast: t, failure: n }) {
}
}),
onError: (e) => {
- let t = iS.test(U(e)) ? "dir" : "file";
+ let t = oie.test(U(e)) ? "dir" : "file";
h(t), (t === "dir" ? v : g).current?.focus();
}
- }), S = vO({
- queryKey: Zx,
- queryFn: ({ signal: e }) => Qx(e),
- start: tS,
+ }), S = pO({
+ queryKey: qx,
+ queryFn: ({ signal: e }) => Jx(e),
+ start: rie,
jobOf: (e) => e,
- withJob: rS,
+ withJob: aie,
onStarted: () => x.reset(),
onFinish: (e) => {
if (X.invalidateQueries({
- queryKey: Zx,
+ queryKey: qx,
exact: !0
}), e.status !== "complete") return;
- let { text: r, failed: i } = cS(e);
+ let { text: r, failed: i } = Zx(e);
i ? n("按模板整理", /* @__PURE__ */ Error(`${i} 行未能处理`)) : t(r.replace(/。$/, ""));
}
}), C = S.running || S.start.isPending, w = x.data, T = Number(w?.counts?.change || 0), E = e[c] || c, D = (i?.placeholders ?? []).map((e) => `{${e.key}} ${e.label}`).join(" · "), O = () => {
x.isPending || !c || (h(null), x.mutate(y()));
}, k = () => void b({
title: "按模板整理文件",
- body: vce(E),
+ body: Cce(E),
confirmLabel: "整理文件",
onConfirm: () => S.start.mutateAsync({
kind: "apply",
@@ -33519,13 +33519,13 @@ function Sce({ toast: t, failure: n }) {
})
}), A = () => void b({
title: "回滚上一批整理",
- body: yce,
+ body: wce,
confirmLabel: "回滚整理",
onConfirm: () => S.start.mutateAsync({ kind: "rollback" })
}), j = null, M = S.job, N = S.outcome;
if (M?.status === "running") {
let e = M.message || M.stage || "正在整理文件…";
- j = /* @__PURE__ */ (0, z.jsx)(mO, {
+ j = /* @__PURE__ */ (0, z.jsx)(lO, {
embedded: !0,
label: e,
value: M.checked,
@@ -33537,7 +33537,7 @@ function Sce({ toast: t, failure: n }) {
children: N.error || "请查看任务记录,核对已处理的文件。"
});
else if (N) {
- let { text: e, failed: t } = cS(N);
+ let { text: e, failed: t } = Zx(N);
j = /* @__PURE__ */ (0, z.jsx)(K, {
tone: t ? "warning" : "success",
title: t ? "部分完成" : "整理结果",
@@ -33547,7 +33547,7 @@ function Sce({ toast: t, failure: n }) {
tone: "error",
title: "整理失败",
children: U(S.start.error)
- }) : x.isPending ? j = /* @__PURE__ */ (0, z.jsx)(mO, {
+ }) : x.isPending ? j = /* @__PURE__ */ (0, z.jsx)(lO, {
embedded: !0,
label: "正在按模板算计划…"
}) : x.isError ? j = /* @__PURE__ */ (0, z.jsx)(K, {
@@ -33557,9 +33557,9 @@ function Sce({ toast: t, failure: n }) {
}) : w && (j = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(K, {
tone: "neutral",
title: "预览结果",
- children: sS(w)
- }), T ? /* @__PURE__ */ (0, z.jsx)(xce, { plan: w }) : null] }));
- return /* @__PURE__ */ (0, z.jsxs)(lO, {
+ children: sie(w)
+ }), T ? /* @__PURE__ */ (0, z.jsx)(Ece, { plan: w }) : null] }));
+ return /* @__PURE__ */ (0, z.jsxs)(iO, {
layout: "stack",
id: "organize",
labelledBy: "cleanup-organize-title",
@@ -33583,7 +33583,7 @@ function Sce({ toast: t, failure: n }) {
}) : null
] }),
children: [
- /* @__PURE__ */ (0, z.jsx)(cO, {
+ /* @__PURE__ */ (0, z.jsx)(rO, {
id: "cleanup-organize-title",
gap: "medium",
children: "整理"
@@ -33603,20 +33603,20 @@ function Sce({ toast: t, failure: n }) {
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "mt-3 flex flex-col gap-3",
children: [
- a.length ? /* @__PURE__ */ (0, z.jsx)(py, {
+ a.length ? /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "整理哪个来源",
className: "w-fit min-w-25",
selectedKey: c || null,
onSelectionChange: (e) => {
e !== null && (s(String(e)), h(null), x.reset());
},
- children: a.map((t) => /* @__PURE__ */ (0, z.jsxs)(my, {
+ children: a.map((t) => /* @__PURE__ */ (0, z.jsxs)(yy, {
id: t.location,
textValue: e[t.location] || t.location,
- children: [/* @__PURE__ */ (0, z.jsx)(jy, { mark: _[t.location] || "database" }), e[t.location] || t.location]
+ children: [/* @__PURE__ */ (0, z.jsx)(Iy, { mark: _[t.location] || "database" }), e[t.location] || t.location]
}, t.location))
}) : null,
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "文件名模板",
placeholder: "{number}[ {title}]",
value: f.file,
@@ -33627,7 +33627,7 @@ function Sce({ toast: t, failure: n }) {
p({ file: e }), h(null);
}
}),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "目录模板",
placeholder: "留空表示原地改名",
value: f.dir,
@@ -33667,56 +33667,56 @@ function Sce({ toast: t, failure: n }) {
}
//#endregion
//#region src/react/data-cleanup/orphan-records.ts
-var Cce = "/api/orphan-records", wce = "/api/orphan-records/attach", AO = ["orphan-records"], Tce = [
+var Oce = "/api/orphan-records", kce = "/api/orphan-records/attach", TO = ["orphan-records"], Ace = [
["asset_preference", "喜欢与理由"],
["watch_queue", "稍后看"],
["playlist_item", "播放列表"],
["asset_quality_goal", "寻找更好版本"],
["activity_event", "观看历史"],
["asset_tag_preference", "隐藏标签"]
-], Ece = (e) => W(Cce, e), Dce = (e, t) => G(wce, {
+], jce = (e) => W(Oce, e), Mce = (e, t) => G(kce, {
id: e,
target: t
-}), Oce = (e) => G(Bb, {
+}), Nce = (e) => G(Gb, {
ids: [e],
operation: "delete"
-}), kce = (e) => [
+}), Pce = (e) => [
e.rating ? `评分 ${e.rating}` : "",
e.play_count ? `播放 ${Number(e.play_count).toLocaleString()} 次` : e.last_played ? "播放过" : "",
e.o_count ? `高潮 ${Number(e.o_count).toLocaleString()} 次` : ""
-], jO = (e) => [...Tce.filter(([t]) => e[t]).map(([t, n]) => `${n} ${Number(e[t]).toLocaleString()}`), ...kce(e)].filter(Boolean).join(" · "), Ace = (e) => e ? `${Math.round(e / 60)} 分钟` : "", MO = (e) => [e.name, Ace(e.duration)].filter(Boolean).join(" · "), jce = Ob("play"), NO = () => X.invalidateQueries({
- queryKey: AO,
+], EO = (e) => [...Ace.filter(([t]) => e[t]).map(([t, n]) => `${n} ${Number(e[t]).toLocaleString()}`), ...Pce(e)].filter(Boolean).join(" · "), Fce = (e) => e ? `${Math.round(e / 60)} 分钟` : "", DO = (e) => [e.name, Fce(e.duration)].filter(Boolean).join(" · "), Ice = Ob("play"), OO = () => X.invalidateQueries({
+ queryKey: TO,
exact: !0
});
-function Mce({ item: t, toast: n }) {
+function Lce({ item: t, toast: n }) {
let [r, i] = (0, R.useState)(t.candidates[0]?.id ?? null), a = er({
- mutationFn: () => Dce(t.id, Number(r)),
+ mutationFn: () => Mce(t.id, Number(r)),
onSuccess: (e) => {
- n(`记录已接到新文件,批次 ${e.batch}`), NO();
+ n(`记录已接到新文件,批次 ${e.batch}`), OO();
},
onError: (e) => n(U(e))
}), o = er({
- mutationFn: () => Oce(t.id),
+ mutationFn: () => Nce(t.id),
onSuccess: (e) => {
- n(e.blocked.length ? `${t.name} 的文件又回到盘上,没有删除;下一次扫描会把它接回在库` : `已彻底删除 ${t.name}`), NO();
+ n(e.blocked.length ? `${t.name} 的文件又回到盘上,没有删除;下一次扫描会把它接回在库` : `已彻底删除 ${t.name}`), OO();
}
}), s = () => {
b({
title: "彻底删除",
- body: `将删除「${t.name}」这一条和它带的记录(${jO(t.records)})。此操作不可撤销。`,
+ body: `将删除「${t.name}」这一条和它带的记录(${EO(t.records)})。此操作不可撤销。`,
confirmLabel: "彻底删除",
danger: !0,
onConfirm: () => o.mutateAsync()
});
}, c = a.isPending || o.isPending;
- return /* @__PURE__ */ (0, z.jsxs)(Wv, {
+ return /* @__PURE__ */ (0, z.jsxs)(Zv, {
id: t.id,
children: [
- /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsxs)("span", {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 items-center gap-3",
children: [/* @__PURE__ */ (0, z.jsxs)("span", {
className: "relative inline-grid aspect-16/10 w-24 flex-none place-items-center max-cleanup-tight:hidden overflow-hidden rounded-lg border border-separator-border bg-background-tertiary-default text-text-tertiary",
- children: [/* @__PURE__ */ (0, z.jsx)(jce, {
+ children: [/* @__PURE__ */ (0, z.jsx)(Ice, {
"aria-hidden": !0,
className: "size-5"
}), t.has_thumb ? /* @__PURE__ */ (0, z.jsx)("img", {
@@ -33738,27 +33738,27 @@ function Mce({ item: t, toast: n }) {
})]
})]
}) }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsx)("span", {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsx)("span", {
className: "block min-w-44",
- children: jO(t.records)
+ children: EO(t.records)
}) }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: t.candidates.length ? /* @__PURE__ */ (0, z.jsx)(py, {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: t.candidates.length ? /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": `把 ${t.name} 的记录接到哪个文件`,
className: "w-64",
selectedKey: r,
onSelectionChange: (e) => {
e !== null && i(Number(e));
},
- children: t.candidates.map((e) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: t.candidates.map((e) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e.id,
- textValue: MO(e),
- children: MO(e)
+ textValue: DO(e),
+ children: DO(e)
}, e.id))
}) : /* @__PURE__ */ (0, z.jsx)("span", {
className: "text-text-secondary",
children: "没有番号或文件名对得上的文件"
}) }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsxs)("span", {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex flex-wrap gap-2",
children: [t.candidates.length ? /* @__PURE__ */ (0, z.jsx)(H, {
size: "small",
@@ -33778,23 +33778,23 @@ function Mce({ item: t, toast: n }) {
]
});
}
-function Nce({ toast: e }) {
+function Rce({ toast: e }) {
let t = $n({
- queryKey: AO,
- queryFn: ({ signal: e }) => Ece(e)
+ queryKey: TO,
+ queryFn: ({ signal: e }) => jce(e)
}), n = t.data?.items ?? [];
return !t.isError && !n.length ? null : /* @__PURE__ */ (0, z.jsxs)("section", {
id: "orphan-records",
"aria-labelledby": "orphan-records-title",
className: "flex scroll-mt-20 flex-col gap-4",
- children: [/* @__PURE__ */ (0, z.jsx)(sO, {
+ children: [/* @__PURE__ */ (0, z.jsx)(nO, {
id: "orphan-records-title",
children: "孤儿记录"
- }), /* @__PURE__ */ (0, z.jsxs)(lO, {
+ }), /* @__PURE__ */ (0, z.jsxs)(iO, {
layout: "stack",
labelledBy: "orphan-records-box",
children: [
- /* @__PURE__ */ (0, z.jsx)(cO, {
+ /* @__PURE__ */ (0, z.jsx)(rO, {
id: "orphan-records-box",
gap: "small",
children: "文件已消失的作品"
@@ -33807,28 +33807,28 @@ function Nce({ toast: e }) {
tone: "error",
title: "孤儿记录读取失败",
children: U(t.error)
- }) : /* @__PURE__ */ (0, z.jsx)(TO, { children: /* @__PURE__ */ (0, z.jsxs)(CO, {
+ }) : /* @__PURE__ */ (0, z.jsx)(bO, { children: /* @__PURE__ */ (0, z.jsxs)(vO, {
"aria-label": "文件已消失的作品",
size: "sm",
- children: [/* @__PURE__ */ (0, z.jsxs)(Iv, { children: [
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(Wv, { children: [
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "item",
isRowHeader: !0,
children: "作品"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "records",
children: "带的记录"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "target",
children: "接到"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "actions",
children: "操作"
})
- ] }), /* @__PURE__ */ (0, z.jsx)(Vv, { children: n.map((t) => /* @__PURE__ */ (0, z.jsx)(Mce, {
+ ] }), /* @__PURE__ */ (0, z.jsx)(Jv, { children: n.map((t) => /* @__PURE__ */ (0, z.jsx)(Lce, {
item: t,
toast: e
}, t.id)) })]
@@ -33839,99 +33839,99 @@ function Nce({ toast: e }) {
}
//#endregion
//#region src/react/data-cleanup/resource-sync-card.tsx
-var Pce = Ob("git-compare"), Fce = Ob("rotate-cw"), Ice = "暂时无法读取进度,正在重新连接…", PO = "清理失效条目", FO = "inline-grid w-full grid-flow-col auto-cols-fr gap-4 max-plain-stat-pair:grid-flow-row max-plain-stat-pair:grid-cols-2 max-plain-stat-single:grid-cols-1", IO = (e) => Number(e || 0).toLocaleString();
-function Lce({ scan: e }) {
+var zce = Ob("git-compare"), Bce = Ob("rotate-cw"), Vce = "暂时无法读取进度,正在重新连接…", kO = "清理失效条目", AO = "inline-grid w-full grid-flow-col auto-cols-fr gap-4 max-plain-stat-pair:grid-flow-row max-plain-stat-pair:grid-cols-2 max-plain-stat-single:grid-cols-1", jO = (e) => Number(e || 0).toLocaleString();
+function Hce({ scan: e }) {
let t = e.cache ?? {
files: 0,
bytes: 0
};
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("div", {
- className: FO,
+ className: AO,
children: (e.sources ?? []).map((e) => /* @__PURE__ */ (0, z.jsx)("article", {
- className: JS(),
- children: /* @__PURE__ */ (0, z.jsx)(YS, {
- label: bS[e.location] || "媒体来源",
- mark: /* @__PURE__ */ (0, z.jsx)(jy, { mark: _[e.location] ?? "database" }),
+ className: bS(),
+ children: /* @__PURE__ */ (0, z.jsx)(xS, {
+ label: fie[e.location] || "媒体来源",
+ mark: /* @__PURE__ */ (0, z.jsx)(Iy, { mark: _[e.location] ?? "database" }),
aside: /* @__PURE__ */ (0, z.jsx)("span", {
className: e.online ? "text-notification-success-foreground" : "text-text-error-primary",
children: e.online ? "可访问" : "离线,已跳过"
}),
- figure: e.online ? `${IO(e.missing)} 项` : "—",
- meta: OS(e),
+ figure: e.online ? `${jO(e.missing)} 项` : "—",
+ meta: gie(e),
wrapMeta: !0
})
}, e.location))
}), /* @__PURE__ */ (0, z.jsxs)("div", {
- className: FO,
+ className: AO,
children: [
/* @__PURE__ */ (0, z.jsx)("article", {
- className: JS(),
- children: /* @__PURE__ */ (0, z.jsx)(YS, {
+ className: bS(),
+ children: /* @__PURE__ */ (0, z.jsx)(xS, {
label: "待永久删除",
- figure: `${IO(CS(e))} 项`,
+ figure: `${jO(oS(e))} 项`,
meta: "文件已不在盘上,含回收站"
})
}),
/* @__PURE__ */ (0, z.jsx)("article", {
- className: JS(),
- children: /* @__PURE__ */ (0, z.jsx)(YS, {
+ className: bS(),
+ children: /* @__PURE__ */ (0, z.jsx)(xS, {
label: "将标为已消失",
- figure: `${IO(e.vanish)} 项`,
+ figure: `${jO(e.vanish)} 项`,
meta: "带个人记录,记录留着"
})
}),
/* @__PURE__ */ (0, z.jsx)("article", {
- className: JS(),
- children: /* @__PURE__ */ (0, z.jsx)(YS, {
+ className: bS(),
+ children: /* @__PURE__ */ (0, z.jsx)(xS, {
label: "空文件夹",
- figure: `${IO(e.empty)} 个`,
+ figure: `${jO(e.empty)} 个`,
meta: "保留来源根目录"
})
}),
/* @__PURE__ */ (0, z.jsx)("article", {
- className: JS(),
- children: /* @__PURE__ */ (0, z.jsx)(YS, {
+ className: bS(),
+ children: /* @__PURE__ */ (0, z.jsx)(xS, {
label: "可清理的缓存",
- figure: `${IO(t.files)} 个`,
+ figure: `${jO(t.files)} 个`,
meta: t.files ? s(t.bytes) : ""
})
})
]
})] });
}
-function Rce({ toast: e }) {
- let t = vO({
- queryKey: fS,
- queryFn: ({ signal: e }) => hS(e),
- start: gS,
+function Uce({ toast: e }) {
+ let t = pO({
+ queryKey: tS,
+ queryFn: ({ signal: e }) => rS(e),
+ start: lie,
onFinish: (t) => {
if (X.invalidateQueries({
- queryKey: IS,
+ queryKey: pS,
exact: !0
}), X.invalidateQueries({
- queryKey: dS,
+ queryKey: eS,
exact: !0
}), t.status !== "complete") return;
- let { done: n, left: r } = kS(t);
- r ? e(`已完成 ${IO(n)} 项,${IO(r)} 项没有处理`, { warning: !0 }) : e("已清理失效条目");
+ let { done: n, left: r } = lS(t);
+ r ? e(`已完成 ${jO(n)} 项,${jO(r)} 项没有处理`, { warning: !0 }) : e("已清理失效条目");
}
- }), n = vO({
- queryKey: dS,
- queryFn: ({ signal: e }) => pS(e),
- start: mS,
+ }), n = pO({
+ queryKey: eS,
+ queryFn: ({ signal: e }) => nS(e),
+ start: cie,
onStarted: () => t.dismiss()
}), r = n.job, i = n.running || n.start.isPending, a = t.running || t.start.isPending, o = r?.status === "complete" || r?.status === "failed", c = i ? "扫描中" : o ? "重新扫描" : "检查文件", l = (e) => void b({
- title: PO,
- body: DS(e),
- confirmLabel: PO,
+ title: kO,
+ body: hie(e),
+ confirmLabel: kO,
danger: !0,
onConfirm: () => t.start.mutateAsync(e.scan_id || "")
}), u = t.outcome, d = (e) => {
- let t = kS(e).left > 0;
+ let t = lS(e).left > 0;
return /* @__PURE__ */ (0, z.jsx)(K, {
tone: t ? "warning" : "success",
title: t ? "部分完成" : "清理结果",
- children: AS(e, s)
+ children: _ie(e, s)
});
}, f = null, p = null;
if (u?.status === "failed") p = /* @__PURE__ */ (0, z.jsx)(K, {
@@ -33940,7 +33940,7 @@ function Rce({ toast: e }) {
children: u.error || "请查看任务记录,核对已处理的文件。"
});
else if (u) p = d(u);
- else if (t.running) f = /* @__PURE__ */ (0, z.jsx)(mO, {
+ else if (t.running) f = /* @__PURE__ */ (0, z.jsx)(lO, {
embedded: !0,
label: t.job?.message || "正在复核并清理失效条目…"
});
@@ -33952,11 +33952,11 @@ function Rce({ toast: e }) {
else if (n.query.isError && r) p = /* @__PURE__ */ (0, z.jsx)(K, {
tone: "neutral",
title: "任务状态",
- children: Ice
+ children: Vce
});
else if (r?.status === "running") {
- let e = SS(r);
- f = /* @__PURE__ */ (0, z.jsx)(mO, {
+ let e = pie(r);
+ f = /* @__PURE__ */ (0, z.jsx)(lO, {
embedded: !0,
label: e,
value: r.completed_sources,
@@ -33973,13 +33973,13 @@ function Rce({ toast: e }) {
children: "这次检查的结果已经清理,重新扫描可再核对。"
});
else if (r?.status === "complete") {
- let e = yS(r);
+ let e = die(r);
p = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
- /* @__PURE__ */ (0, z.jsx)(Lce, { scan: r }),
+ /* @__PURE__ */ (0, z.jsx)(Hce, { scan: r }),
e ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "neutral",
title: "清理内容",
- children: ES(r)
+ children: mie(r)
}) : null,
/* @__PURE__ */ (0, z.jsx)("div", {
className: "flex flex-wrap items-center justify-end gap-2",
@@ -33987,7 +33987,7 @@ function Rce({ toast: e }) {
variant: "danger",
...q(a),
onClick: () => l(r),
- children: a ? "正在复核并清理…" : PO
+ children: a ? "正在复核并清理…" : kO
}) : /* @__PURE__ */ (0, z.jsx)("p", {
className: "mr-auto text-body-regular text-notification-success-foreground",
children: "已检查可访问的来源,没有待清理的记录、空文件夹或缓存。"
@@ -34004,16 +34004,16 @@ function Rce({ toast: e }) {
"aria-labelledby": "resource-sync-title",
className: "flex scroll-mt-20 flex-col gap-4",
children: [
- /* @__PURE__ */ (0, z.jsx)(sO, {
+ /* @__PURE__ */ (0, z.jsx)(nO, {
id: "resource-sync-title",
children: "资源同步"
}),
- /* @__PURE__ */ (0, z.jsxs)(lO, {
+ /* @__PURE__ */ (0, z.jsxs)(iO, {
layout: "split",
labelledBy: "resource-sync-box",
footer: /* @__PURE__ */ (0, z.jsx)(H, {
"data-resource-scan": !0,
- leadingIcon: o && !i ? Fce : Pce,
+ leadingIcon: o && !i ? Bce : zce,
...q(i),
onClick: () => {
i || n.start.mutate();
@@ -34021,7 +34021,7 @@ function Rce({ toast: e }) {
children: c
}),
children: [
- /* @__PURE__ */ (0, z.jsx)(cO, {
+ /* @__PURE__ */ (0, z.jsx)(rO, {
id: "resource-sync-box",
gap: "small",
children: "文件与记录核对"
@@ -34047,16 +34047,16 @@ function Rce({ toast: e }) {
}
//#endregion
//#region src/react/data-cleanup/data-cleanup-page.tsx
-function LO(e, t) {
+function MO(e, t) {
return e.data === void 0 ? { figure: e.isError ? "读取失败" : "—" } : t(e.data);
}
-function RO({ section: e, label: t, icon: n, value: r, open: i }) {
+function NO({ section: e, label: t, icon: n, value: r, open: i }) {
return /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
- className: JS({ interactive: !0 }),
+ className: bS({ interactive: !0 }),
"data-cleanup-go": e,
onClick: () => i(e),
- children: /* @__PURE__ */ (0, z.jsx)(YS, {
+ children: /* @__PURE__ */ (0, z.jsx)(xS, {
label: t,
icon: n,
figure: r.figure,
@@ -34064,80 +34064,80 @@ function RO({ section: e, label: t, icon: n, value: r, open: i }) {
})
});
}
-var zce = Ob("square-check-big"), Bce = Ob("sparkles"), Vce = Ob("file-stack"), Hce = Ob("file-archive"), Uce = Ob("trash"), zO = [
- MS,
- ax,
- zb
-], Wce = () => {
- for (let e of zO) X.invalidateQueries({
+var Wce = Ob("square-check-big"), Gce = Ob("sparkles"), Kce = Ob("file-stack"), qce = Ob("file-archive"), Jce = Ob("trash"), Yce = [
+ uS,
+ ux,
+ Wb
+], Xce = () => {
+ for (let e of Yce) X.invalidateQueries({
queryKey: e,
exact: !0
});
};
-function Gce({ toast: e, failure: t, open: n }) {
+function Zce({ toast: e, failure: t, open: n }) {
let r = $n({
- queryKey: MS,
- queryFn: ({ signal: e }) => RS(e)
+ queryKey: uS,
+ queryFn: ({ signal: e }) => mS(e)
}), i = $n({
- queryKey: ax,
- queryFn: ({ signal: e }) => ox(e)
+ queryKey: ux,
+ queryFn: ({ signal: e }) => dx(e)
}), a = $n({
- queryKey: zb,
- queryFn: ({ signal: e }) => Vb(e)
+ queryKey: Wb,
+ queryFn: ({ signal: e }) => Kb(e)
}), o = $n({
- queryKey: PS,
- queryFn: ({ signal: e }) => zS(e)
+ queryKey: dS,
+ queryFn: ({ signal: e }) => hS(e)
}), c = $n({
- queryKey: IS,
- queryFn: ({ signal: e }) => BS(e)
+ queryKey: pS,
+ queryFn: ({ signal: e }) => gS(e)
}), l = $n({
- queryKey: Ib,
- queryFn: ({ signal: e }) => Lb(e)
+ queryKey: Vb,
+ queryFn: ({ signal: e }) => Hb(e)
}), u = (t) => e(t);
return /* @__PURE__ */ (0, z.jsxs)(ta, { children: [
/* @__PURE__ */ (0, z.jsxs)("div", {
- className: eie,
+ className: Oie,
children: [
- /* @__PURE__ */ (0, z.jsx)(RO, {
+ /* @__PURE__ */ (0, z.jsx)(NO, {
section: "review",
label: "人工复核",
- icon: zce,
+ icon: Wce,
open: n,
- value: LO(r, HS)
+ value: MO(r, xie)
}),
- /* @__PURE__ */ (0, z.jsx)(RO, {
+ /* @__PURE__ */ (0, z.jsx)(NO, {
section: "quality",
label: "高清版",
- icon: Bce,
+ icon: Gce,
open: n,
- value: LO(i, (e) => ({ figure: `${Number(e.total || 0).toLocaleString()} 个待升级` }))
+ value: MO(i, (e) => ({ figure: `${Number(e.total || 0).toLocaleString()} 个待升级` }))
}),
- /* @__PURE__ */ (0, z.jsx)(RO, {
+ /* @__PURE__ */ (0, z.jsx)(NO, {
section: "duplicates",
label: "重复文件",
- icon: Vce,
+ icon: Kce,
open: n,
- value: LO(a, (e) => Number(e.total || 0) ? {
+ value: MO(a, (e) => Number(e.total || 0) ? {
figure: `${Number(e.total).toLocaleString()} 组 · ${Number(e.files || 0).toLocaleString()} 个文件`,
meta: `可回收 ${s(e.reclaimable || 0)}`
} : { figure: "没有重复内容" })
}),
- /* @__PURE__ */ (0, z.jsx)(RO, {
+ /* @__PURE__ */ (0, z.jsx)(NO, {
section: "ads",
label: "垃圾文件",
- icon: Hce,
+ icon: qce,
open: n,
- value: LO(o, (e) => ({
+ value: MO(o, (e) => ({
figure: `${Number(e.pending_total || 0).toLocaleString()} 个待判断`,
- meta: US(e)
+ meta: Sie(e)
}))
}),
- /* @__PURE__ */ (0, z.jsx)(RO, {
+ /* @__PURE__ */ (0, z.jsx)(NO, {
section: "trash",
label: "回收站",
- icon: Uce,
+ icon: Jce,
open: n,
- value: LO(c, (e) => ({
+ value: MO(c, (e) => ({
figure: `${Number(e.total || 0).toLocaleString()} 项在回收站`,
meta: e.total ? `占用 ${s(e.bytes || 0)}` : ""
}))
@@ -34150,30 +34150,30 @@ function Gce({ toast: e, failure: t, open: n }) {
/* @__PURE__ */ (0, z.jsx)("div", {
id: "libraryProcessing",
className: "scroll-mt-20",
- children: /* @__PURE__ */ (0, z.jsx)(gO, {
+ children: /* @__PURE__ */ (0, z.jsx)(dO, {
toast: u,
monitor: !0,
- onComplete: Wce
+ onComplete: Xce
})
}),
/* @__PURE__ */ (0, z.jsx)("div", {
id: "mediaRepair",
- children: /* @__PURE__ */ (0, z.jsx)(uce, {})
+ children: /* @__PURE__ */ (0, z.jsx)(hce, {})
}),
- /* @__PURE__ */ (0, z.jsx)(Sce, {
+ /* @__PURE__ */ (0, z.jsx)(Dce, {
toast: u,
failure: t
})
]
}),
- /* @__PURE__ */ (0, z.jsx)(_ce, {}),
- /* @__PURE__ */ (0, z.jsx)(Nce, { toast: u }),
- _S(l.data) ? /* @__PURE__ */ (0, z.jsx)(Rce, { toast: e }) : null
+ /* @__PURE__ */ (0, z.jsx)(Sce, {}),
+ /* @__PURE__ */ (0, z.jsx)(Rce, { toast: u }),
+ iS(l.data) ? /* @__PURE__ */ (0, z.jsx)(Uce, { toast: e }) : null
] });
}
//#endregion
//#region src/react/components/collection-summary.tsx
-function BO({ label: e, figure: t, detail: n = "", pending: r = !1, flush: i = !1 }) {
+function PO({ label: e, figure: t, detail: n = "", pending: r = !1, flush: i = !1 }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-collection-summary": "",
className: `${i ? "" : "mb-5 "}flex items-end justify-between gap-4 rounded-surface bg-background-secondary-default px-6 py-5
@@ -34200,7 +34200,7 @@ function BO({ label: e, figure: t, detail: n = "", pending: r = !1, flush: i = !
}
//#endregion
//#region src/react/components/use-stuck.ts
-function VO(e) {
+function FO(e) {
(0, R.useEffect)(() => {
let t = e.current;
if (!t) return;
@@ -34218,9 +34218,9 @@ function VO(e) {
}
//#endregion
//#region src/react/components/filter-glass.tsx
-function Kce({ title: e, children: t }) {
+function Qce({ title: e, children: t }) {
let n = (0, R.useRef)(null);
- return VO(n), /* @__PURE__ */ (0, z.jsxs)("div", {
+ return FO(n), /* @__PURE__ */ (0, z.jsxs)("div", {
ref: n,
role: "group",
"aria-label": e,
@@ -34233,9 +34233,9 @@ function Kce({ title: e, children: t }) {
}), t]
});
}
-function HO({ label: e, topLabel: t, top: n, bottom: r, className: i, topClassName: a, bottomClassName: o, panes: s, attrs: c, busy: l, bottomRef: u }) {
+function IO({ label: e, topLabel: t, top: n, bottom: r, className: i, topClassName: a, bottomClassName: o, panes: s, attrs: c, busy: l, bottomRef: u }) {
let d = (0, R.useRef)(null);
- return VO(d), /* @__PURE__ */ (0, z.jsxs)("div", {
+ return FO(d), /* @__PURE__ */ (0, z.jsxs)("div", {
ref: d,
role: "group",
"aria-label": e,
@@ -34262,23 +34262,23 @@ function HO({ label: e, topLabel: t, top: n, bottom: r, className: i, topClassNa
]
});
}
-var qce = "flex h-7.5 flex-none cursor-pointer items-center gap-1.75 rounded-lg border border-dashed border-(--glass-low) bg-transparent px-2.5 text-body-2-regular leading-5 whitespace-nowrap text-inherit outline-none hover:border-solid focus-visible:ring-2 focus-visible:ring-border-focus-ring";
-function UO({ children: e, pressed: t, onPress: n, className: r, ...i }) {
+var $ce = "flex h-7.5 flex-none cursor-pointer items-center gap-1.75 rounded-lg border border-dashed border-(--glass-low) bg-transparent px-2.5 text-body-2-regular leading-5 whitespace-nowrap text-inherit outline-none hover:border-solid focus-visible:ring-2 focus-visible:ring-border-focus-ring";
+function LO({ children: e, pressed: t, onPress: n, className: r, ...i }) {
return /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
...i,
"aria-pressed": t,
- className: Ii(qce, r),
+ className: Ii($ce, r),
onClick: n,
children: e
});
}
-var Jce = "h-7.5 cursor-pointer rounded-full border border-(--glass-low) bg-transparent px-3 text-body-2-regular leading-none whitespace-nowrap text-inherit outline-none focus-visible:ring-2 focus-visible:ring-border-focus-ring aria-busy:cursor-wait aria-busy:opacity-55";
-function WO({ children: e, onPress: t, busy: n = !1 }) {
+var ele = "h-7.5 cursor-pointer rounded-full border border-(--glass-low) bg-transparent px-3 text-body-2-regular leading-none whitespace-nowrap text-inherit outline-none focus-visible:ring-2 focus-visible:ring-border-focus-ring aria-busy:cursor-wait aria-busy:opacity-55";
+function RO({ children: e, onPress: t, busy: n = !1 }) {
return /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-glass-pill": "",
- className: Jce,
+ className: ele,
"aria-busy": n || void 0,
"aria-disabled": n || void 0,
onClick: () => {
@@ -34289,29 +34289,29 @@ function WO({ children: e, onPress: t, busy: n = !1 }) {
}
//#endregion
//#region src/react/duplicates/duplicates-page.tsx
-var Yce = Ob("play"), Xce = Ob("file-stack"), Zce = Zi({
+var tle = Ob("play"), nle = Ob("file-stack"), rle = Zi({
padding: "none",
radius: "surface",
className: "mb-6 overflow-hidden dark:bg-background-primary-default"
-}), GO = "rounded-sm px-1.5 py-px text-caption-1-regular leading-5", KO = "rounded-sm px-2 py-0.5 text-caption-1-regular leading-5", qO = "font-mono text-caption-1-regular leading-5 text-text-secondary", JO = () => {
+}), zO = "rounded-sm px-1.5 py-px text-caption-1-regular leading-5", BO = "rounded-sm px-2 py-0.5 text-caption-1-regular leading-5", VO = "font-mono text-caption-1-regular leading-5 text-text-secondary", HO = () => {
X.invalidateQueries({
- queryKey: zb,
+ queryKey: Wb,
exact: !0
}), X.invalidateQueries({
- queryKey: IS,
+ queryKey: pS,
exact: !0
});
};
-function YO(e) {
+function ile(e) {
return e.identical ? /* @__PURE__ */ (0, z.jsx)("span", {
- className: `${KO} text-(--keep)`,
+ className: `${BO} text-(--keep)`,
children: "sha1 一致"
}) : /* @__PURE__ */ (0, z.jsx)("span", {
- className: `${KO} text-text-secondary`,
+ className: `${BO} text-text-secondary`,
children: e.evidence === "same_code_short_copy" ? "同番号短版本" : "时长推断"
});
}
-function XO({ file: t, openItem: n }) {
+function ale({ file: t, openItem: n }) {
let r = () => n(t.id);
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "duplicate-row items-center gap-3 border-t border-separator-border px-5 py-4 max-compact:p-4",
@@ -34321,7 +34321,7 @@ function XO({ file: t, openItem: n }) {
onClick: r,
"aria-label": `预览 ${t.name}`,
className: "relative row-span-2 inline-grid aspect-16/10 w-full cursor-pointer place-items-center overflow-hidden rounded-2lg bg-background-tertiary-default text-text-secondary",
- children: [/* @__PURE__ */ (0, z.jsx)(Yce, {
+ children: [/* @__PURE__ */ (0, z.jsx)(tle, {
"aria-hidden": !0,
className: "size-6"
}), /* @__PURE__ */ (0, z.jsx)("img", {
@@ -34345,55 +34345,55 @@ function XO({ file: t, openItem: n }) {
}), t.is_largest || t.is_longest ? /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex flex-none gap-1",
children: [t.is_largest ? /* @__PURE__ */ (0, z.jsx)("i", {
- className: `${GO} not-italic bg-background-primary-hover text-text-secondary`,
+ className: `${zO} not-italic bg-background-primary-hover text-text-secondary`,
children: "最大"
}) : null, t.is_longest ? /* @__PURE__ */ (0, z.jsx)("i", {
- className: `${GO} not-italic bg-(--keep)/22 text-(--keep)`,
+ className: `${zO} not-italic bg-(--keep)/22 text-(--keep)`,
children: "最长"
}) : null]
}) : null]
}),
/* @__PURE__ */ (0, z.jsxs)("span", {
- className: `${qO} flex min-w-0 items-center gap-1.5`,
- children: [/* @__PURE__ */ (0, z.jsx)(jy, { mark: _[t.location] || "database" }), /* @__PURE__ */ (0, z.jsx)("span", {
+ className: `${VO} flex min-w-0 items-center gap-1.5`,
+ children: [/* @__PURE__ */ (0, z.jsx)(Iy, { mark: _[t.location] || "database" }), /* @__PURE__ */ (0, z.jsx)("span", {
className: "whitespace-nowrap",
children: e[t.location] || t.location || t.drive
})]
}),
/* @__PURE__ */ (0, z.jsx)("span", {
- className: qO,
+ className: VO,
children: s(t.size || 0)
}),
/* @__PURE__ */ (0, z.jsx)("span", {
- className: qO,
+ className: VO,
children: o(t.duration)
}),
/* @__PURE__ */ (0, z.jsx)("span", {
"data-middle-truncate": !0,
title: t.path ?? "",
- className: `${qO} col-start-2 -col-end-1 min-w-0 truncate pt-0.5 max-duplicate-narrow:col-span-full`,
+ className: `${VO} col-start-2 -col-end-1 min-w-0 truncate pt-0.5 max-duplicate-narrow:col-span-full`,
children: t.path ?? ""
})
]
});
}
-function Qce({ openItem: t, toast: n, failure: r }) {
+function ole({ openItem: t, toast: n, failure: r }) {
let i = $n({
- queryKey: zb,
- queryFn: ({ signal: e }) => Vb(e)
+ queryKey: Wb,
+ queryFn: ({ signal: e }) => Kb(e)
}), a = $n({
- queryKey: Ib,
- queryFn: ({ signal: e }) => Lb(e)
+ queryKey: Vb,
+ queryFn: ({ signal: e }) => Hb(e)
}), [o, c] = (0, R.useState)(""), l = er({
- mutationFn: (e) => Wb(e, "dispose"),
+ mutationFn: (e) => Yb(e, "dispose"),
onSuccess: (e, t) => {
- JO(), n(`已把 ${t.length} 项移入回收站`, { undo: async () => {
+ HO(), n(`已把 ${t.length} 项移入回收站`, { undo: async () => {
try {
- await Wb(t, "restore");
+ await Yb(t, "restore");
} catch (e) {
r("撤销移入回收站", e);
} finally {
- JO();
+ HO();
}
} });
},
@@ -34407,12 +34407,12 @@ function Qce({ openItem: t, toast: n, failure: r }) {
children: i.error ? U(i.error) : "未取得重复文件列表,请刷新页面重试。"
})
});
- let d = u.groups ?? [], f = tre(a.data), p = ({ groups: e, keep: t, key: n }) => {
+ let d = u.groups ?? [], f = Xne(a.data), p = ({ groups: e, keep: t, key: n }) => {
if (l.isPending) return;
- let r = ore(e, t);
+ let r = tre(e, t);
r.length && b({
title: "移入回收站",
- body: `将把 ${r.length} 个重复文件的馆藏记录移入回收站,每组保留${Hb[t] ?? Hb.largest}。文件共 ${s(sre(e, r))},记录可从回收站还原。`,
+ body: `将把 ${r.length} 个重复文件的馆藏记录移入回收站,每组保留${qb[t] ?? qb.largest}。文件共 ${s(nre(e, r))},记录可从回收站还原。`,
confirmLabel: "移入回收站",
onConfirm: () => (c(n), l.mutateAsync(r))
});
@@ -34420,15 +34420,15 @@ function Qce({ openItem: t, toast: n, failure: r }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "mx-auto w-full max-w-board pb-10.5",
children: [
- /* @__PURE__ */ (0, z.jsx)(BO, {
+ /* @__PURE__ */ (0, z.jsx)(PO, {
label: "重复内容",
figure: `${Number(u.total || 0).toLocaleString()} 组`,
detail: `${u.files} 个文件 · 可回收 ${s(u.reclaimable)}`
}),
- d.length ? /* @__PURE__ */ (0, z.jsxs)(Kce, {
+ d.length ? /* @__PURE__ */ (0, z.jsxs)(Qce, {
title: "批量保留",
children: [
- /* @__PURE__ */ (0, z.jsx)(WO, {
+ /* @__PURE__ */ (0, z.jsx)(RO, {
busy: o === "all:largest",
onPress: () => p({
groups: d,
@@ -34437,7 +34437,7 @@ function Qce({ openItem: t, toast: n, failure: r }) {
}),
children: "全部保留最大"
}),
- /* @__PURE__ */ (0, z.jsx)(WO, {
+ /* @__PURE__ */ (0, z.jsx)(RO, {
busy: o === "all:longest",
onPress: () => p({
groups: d,
@@ -34446,7 +34446,7 @@ function Qce({ openItem: t, toast: n, failure: r }) {
}),
children: "全部保留最长"
}),
- are(d, f).map((t) => /* @__PURE__ */ (0, z.jsx)(WO, {
+ ere(d, f).map((t) => /* @__PURE__ */ (0, z.jsx)(RO, {
busy: o === `all:${t}`,
onPress: () => p({
groups: d,
@@ -34469,7 +34469,7 @@ function Qce({ openItem: t, toast: n, failure: r }) {
let i = [n], a = (e) => `${r}:${e}`;
return /* @__PURE__ */ (0, z.jsxs)("section", {
"aria-label": n.code,
- className: Zce,
+ className: rle,
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center gap-3 bg-background-tertiary-default p-5 max-compact:p-4 dark:bg-background-secondary-default",
children: [
@@ -34481,9 +34481,9 @@ function Qce({ openItem: t, toast: n, failure: r }) {
className: "font-mono text-caption-1-regular leading-5 text-text-primary",
children: `${n.count} 个 · 可回收 ${s(n.reclaimable)}`
}),
- YO(n),
+ ile(n),
n.cross_drive ? /* @__PURE__ */ (0, z.jsx)("span", {
- className: `${KO} text-text-secondary`,
+ className: `${BO} text-text-secondary`,
children: `跨盘 ${n.drives.join(" ")}`
}) : null,
/* @__PURE__ */ (0, z.jsxs)("span", {
@@ -34511,7 +34511,7 @@ function Qce({ openItem: t, toast: n, failure: r }) {
}),
children: "留最长"
}),
- Ub(n.files, f).map((t) => /* @__PURE__ */ (0, z.jsx)(H, {
+ Jb(n.files, f).map((t) => /* @__PURE__ */ (0, z.jsx)(H, {
variant: "secondary",
size: "small",
...m(a(t)),
@@ -34536,13 +34536,13 @@ function Qce({ openItem: t, toast: n, failure: r }) {
]
})
]
- }), /* @__PURE__ */ (0, z.jsx)("div", { children: n.files.map((e) => /* @__PURE__ */ (0, z.jsx)(XO, {
+ }), /* @__PURE__ */ (0, z.jsx)("div", { children: n.files.map((e) => /* @__PURE__ */ (0, z.jsx)(ale, {
file: e,
openItem: t
}, e.id)) })]
}, `${n.code}-${r}`);
}) : /* @__PURE__ */ (0, z.jsx)($i, {
- icon: Xce,
+ icon: nle,
title: "没有找到重复文件",
children: "所有来源之间没有检测到内容相同的文件。扫描新来源后,这里会自动更新。"
})
@@ -34551,7 +34551,7 @@ function Qce({ openItem: t, toast: n, failure: r }) {
}
//#endregion
//#region src/react/components/use-view-glide.ts
-function $ce(e, t, n) {
+function sle(e, t, n) {
if (!t.contains(e)) return null;
let r = 0, i = 0;
for (let n = e; n && n !== t; n = n.offsetParent) r += n.offsetLeft, i += n.offsetTop;
@@ -34575,11 +34575,11 @@ function $ce(e, t, n) {
h: e.offsetHeight
};
}
-function ZO(e, t, n, r, { axis: i = "x" } = {}) {
+function UO(e, t, n, r, { axis: i = "x" } = {}) {
let a = (0, R.useRef)(null), o = (0, R.useCallback)((r, o) => {
let s = e.current, c = t.current, l = s?.parentElement;
if (!s) return;
- let u = c && c.offsetWidth ? r ?? c.querySelector(n) : null, d = u && l ? $ce(u, l, i) : null;
+ let u = c && c.offsetWidth ? r ?? c.querySelector(n) : null, d = u && l ? sle(u, l, i) : null;
if (!d || !d.w) {
s.hidden = !0;
return;
@@ -34621,33 +34621,33 @@ function ZO(e, t, n, r, { axis: i = "x" } = {}) {
}
//#endregion
//#region src/react/components/segmented.tsx
-function QO(e) {
- let t = rO("selection");
- return /* @__PURE__ */ (0, z.jsx)(ty, {
+function WO(e) {
+ let t = QD("selection");
+ return /* @__PURE__ */ (0, z.jsx)(oy, {
...e,
ref: t
});
}
-function $O(e) {
- let t = rO("selection");
- return /* @__PURE__ */ (0, z.jsx)(E_, {
+function GO(e) {
+ let t = QD("selection");
+ return /* @__PURE__ */ (0, z.jsx)(D_, {
...e,
ref: t
});
}
-var ek = "inline-flex w-max max-w-full items-center gap-0.5 overflow-x-auto overscroll-x-contain rounded-2lg bg-background-tertiary-default p-1", tk = "flex min-h-7 flex-none cursor-pointer items-center gap-1.5 rounded-md px-2.5 py-1 text-body-medium whitespace-nowrap text-text-secondary outline-none transition-colors hover:text-text-primary focus-visible:ring-2 focus-visible:ring-border-focus-ring data-focus-visible:ring-2 data-focus-visible:ring-border-focus-ring data-selected:bg-background-primary-default data-selected:text-text-primary data-selected:shadow-card dark:data-selected:bg-background-primary-hover", ele = "flex size-7 flex-none cursor-pointer items-center justify-center rounded-md text-text-secondary outline-none transition-colors hover:text-text-primary focus-visible:ring-2 focus-visible:ring-border-focus-ring data-focus-visible:ring-2 data-focus-visible:ring-border-focus-ring data-selected:bg-background-primary-default data-selected:text-text-primary data-selected:shadow-card dark:data-selected:bg-background-primary-hover", nk = "inline-flex w-max max-w-full flex-none items-center gap-0.5 rounded-lg", rk = "flex size-7.5 flex-none cursor-pointer items-center justify-center rounded-lg text-(--glass-text)/62 outline-none transition-colors hover:text-(--glass-text) focus-visible:ring-2 focus-visible:ring-border-focus-ring data-selected:text-(--glass-text)", tle = (e) => e === "videos", ik = () => /* @__PURE__ */ (0, z.jsx)("span", {
+var KO = "inline-flex w-max max-w-full items-center gap-0.5 overflow-x-auto overscroll-x-contain rounded-2lg bg-background-tertiary-default p-1", qO = "flex min-h-7 flex-none cursor-pointer items-center gap-1.5 rounded-md px-2.5 py-1 text-body-medium whitespace-nowrap text-text-secondary outline-none transition-colors hover:text-text-primary focus-visible:ring-2 focus-visible:ring-border-focus-ring data-focus-visible:ring-2 data-focus-visible:ring-border-focus-ring data-selected:bg-background-primary-default data-selected:text-text-primary data-selected:shadow-card dark:data-selected:bg-background-primary-hover", cle = "flex size-7 flex-none cursor-pointer items-center justify-center rounded-md text-text-secondary outline-none transition-colors hover:text-text-primary focus-visible:ring-2 focus-visible:ring-border-focus-ring data-focus-visible:ring-2 data-focus-visible:ring-border-focus-ring data-selected:bg-background-primary-default data-selected:text-text-primary data-selected:shadow-card dark:data-selected:bg-background-primary-hover", JO = "inline-flex w-max max-w-full flex-none items-center gap-0.5 rounded-lg", YO = "flex size-7.5 flex-none cursor-pointer items-center justify-center rounded-lg text-(--glass-text)/62 outline-none transition-colors hover:text-(--glass-text) focus-visible:ring-2 focus-visible:ring-border-focus-ring data-selected:text-(--glass-text)", lle = (e) => e === "videos", XO = () => /* @__PURE__ */ (0, z.jsx)("span", {
"data-entity-sep": "",
"aria-hidden": "true"
});
-function nle(e) {
- let { view: t, views: n, state: r, states: i, tags: a, combo: o, actions: s, helpers: c } = e, l = tle(t), u = (0, R.useRef)(null), d = (0, R.useRef)(null), f = (0, R.useRef)(null), p = (0, R.useRef)(null), m = (0, R.useRef)(null), h = (0, R.useRef)(null), g = (0, R.useRef)(null), _ = ZO(u, f, "[data-entity-state][aria-pressed=\"true\"]", `${t}:${r}`), v = ZO(d, p, "[data-media-view][aria-pressed=\"true\"]", `${t}:${!!n}`);
+function ule(e) {
+ let { view: t, views: n, state: r, states: i, tags: a, combo: o, actions: s, helpers: c } = e, l = lle(t), u = (0, R.useRef)(null), d = (0, R.useRef)(null), f = (0, R.useRef)(null), p = (0, R.useRef)(null), m = (0, R.useRef)(null), h = (0, R.useRef)(null), g = (0, R.useRef)(null), _ = UO(u, f, "[data-entity-state][aria-pressed=\"true\"]", `${t}:${r}`), v = UO(d, p, "[data-media-view][aria-pressed=\"true\"]", `${t}:${!!n}`);
return (0, R.useEffect)(() => {
c.wireDrag(h.current), c.wireScroller(m.current), c.wireDrag(g.current);
- }, [c]), /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(ak, {
+ }, [c]), /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(ZO, {
items: o,
hidden: !l,
actions: s
- }), /* @__PURE__ */ (0, z.jsx)(HO, {
+ }), /* @__PURE__ */ (0, z.jsx)(IO, {
label: "筛选与排序",
topLabel: "媒体与标签",
attrs: {
@@ -34667,13 +34667,13 @@ function nle(e) {
"data-view-glide": "round",
"aria-hidden": "true"
})] }),
- top: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [n ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(rle, {
+ top: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [n ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(dle, {
keys: n,
view: t,
row: p,
glide: v,
onView: s.setView
- }), l ? /* @__PURE__ */ (0, z.jsx)(ik, {}) : null] }) : null, /* @__PURE__ */ (0, z.jsxs)("div", {
+ }), l ? /* @__PURE__ */ (0, z.jsx)(XO, {}) : null] }) : null, /* @__PURE__ */ (0, z.jsxs)("div", {
ref: m,
"data-entity-scroll": "",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
@@ -34693,11 +34693,11 @@ function nle(e) {
r !== e.k && s.setState(e.k);
},
children: e.label
- }, e.k)), /* @__PURE__ */ (0, z.jsx)(ik, {})]
+ }, e.k)), /* @__PURE__ */ (0, z.jsx)(XO, {})]
}), /* @__PURE__ */ (0, z.jsx)("div", {
ref: h,
"data-entity-tags": "",
- children: l ? a.map((e) => /* @__PURE__ */ (0, z.jsxs)(UO, {
+ children: l ? a.map((e) => /* @__PURE__ */ (0, z.jsxs)(LO, {
"data-entity-tag": e.k,
"data-entity-press": "",
pressed: e.selected,
@@ -34709,10 +34709,10 @@ function nle(e) {
}, e.k)) : null
})]
})] }),
- bottom: /* @__PURE__ */ (0, z.jsx)(ile, { ...e })
+ bottom: /* @__PURE__ */ (0, z.jsx)(fle, { ...e })
})] });
}
-function rle({ keys: e, view: t, row: n, glide: r, onView: i }) {
+function dle({ keys: e, view: t, row: n, glide: r, onView: i }) {
let a = [];
return e.people && a.push({
value: "people",
@@ -34754,7 +34754,7 @@ function rle({ keys: e, view: t, row: n, glide: r, onView: i }) {
})
});
}
-function ak({ items: e, hidden: t, actions: n }) {
+function ZO({ items: e, hidden: t, actions: n }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-entity-combo": "",
hidden: t,
@@ -34774,7 +34774,7 @@ function ak({ items: e, hidden: t, actions: n }) {
})] }) : null
});
}
-function ile(e) {
+function fle(e) {
let { view: t, readout: n, busy: r, video: i, photo: a, actions: o, helpers: s } = e;
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
t === "photos" && a?.back ? /* @__PURE__ */ (0, z.jsxs)("button", {
@@ -34786,22 +34786,22 @@ function ile(e) {
dangerouslySetInnerHTML: { __html: l("chevron-left") }
}), /* @__PURE__ */ (0, z.jsx)("span", { children: "全部照片" })]
}) : null,
- /* @__PURE__ */ (0, z.jsx)(ale, {
+ /* @__PURE__ */ (0, z.jsx)(ple, {
text: n,
busy: r
}),
- t === "videos" && i ? /* @__PURE__ */ (0, z.jsx)(ole, {
+ t === "videos" && i ? /* @__PURE__ */ (0, z.jsx)(mle, {
head: i,
actions: o
}) : null,
- t === "photos" && a ? /* @__PURE__ */ (0, z.jsx)(sle, {
+ t === "photos" && a ? /* @__PURE__ */ (0, z.jsx)(hle, {
head: a,
actions: o,
helpers: s
}) : null
] });
}
-function ale({ text: e, busy: t }) {
+function ple({ text: e, busy: t }) {
return /* @__PURE__ */ (0, z.jsx)("h3", {
"data-entity-readout": "",
children: t ? /* @__PURE__ */ (0, z.jsx)("span", {
@@ -34811,22 +34811,22 @@ function ale({ text: e, busy: t }) {
}) : e
});
}
-function ok({ name: e, label: t, value: n, options: r, onChange: i }) {
- return /* @__PURE__ */ (0, z.jsx)(E_, {
+function QO({ name: e, label: t, value: n, options: r, onChange: i }) {
+ return /* @__PURE__ */ (0, z.jsx)(D_, {
name: e,
"aria-label": t,
orientation: "horizontal",
value: n,
onChange: i,
"data-entity-layout": "",
- className: nk,
+ className: JO,
children: r.map(([e, t, n]) => {
let r = Ob(n);
- return /* @__PURE__ */ (0, z.jsx)(D_, {
+ return /* @__PURE__ */ (0, z.jsx)(O_, {
value: e,
"aria-label": t,
"data-glass-segment": "",
- className: rk,
+ className: YO,
children: /* @__PURE__ */ (0, z.jsx)("span", {
title: t,
className: "contents",
@@ -34836,7 +34836,7 @@ function ok({ name: e, label: t, value: n, options: r, onChange: i }) {
})
});
}
-function sk({ onPress: e, busy: t = !1 }) {
+function $O({ onPress: e, busy: t = !1 }) {
return /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-entity-batch": "",
@@ -34850,25 +34850,25 @@ function sk({ onPress: e, busy: t = !1 }) {
dangerouslySetInnerHTML: { __html: t ? ie("正在换一批") : l("shuffle") }
});
}
-function ole({ head: e, actions: t }) {
+function mle({ head: e, actions: t }) {
return /* @__PURE__ */ (0, z.jsxs)("span", {
"data-entity-sorts": "",
children: [
- /* @__PURE__ */ (0, z.jsx)(sk, { onPress: () => void t.reshuffle() }),
- e.jav ? /* @__PURE__ */ (0, z.jsx)(ok, {
+ /* @__PURE__ */ (0, z.jsx)($O, { onPress: () => void t.reshuffle() }),
+ e.jav ? /* @__PURE__ */ (0, z.jsx)(QO, {
label: "JAV 卡片版式",
value: e.jav.layout,
options: e.jav.options,
onChange: t.setJavLayout
}) : null,
- /* @__PURE__ */ (0, z.jsx)(ck, {
+ /* @__PURE__ */ (0, z.jsx)(ek, {
sorts: e.sorts,
onSort: t.setSort
})
]
});
}
-function ck({ sorts: e, onSort: t }) {
+function ek({ sorts: e, onSort: t }) {
return /* @__PURE__ */ (0, z.jsx)(z.Fragment, { children: e.map((e) => {
let n = Ob(e.dir === "asc" ? "arrow-up" : "arrow-down");
return /* @__PURE__ */ (0, z.jsxs)("button", {
@@ -34882,20 +34882,20 @@ function ck({ sorts: e, onSort: t }) {
}, e.key);
}) });
}
-function sle({ head: e, actions: t, helpers: n }) {
+function hle({ head: e, actions: t, helpers: n }) {
let [r, i] = (0, R.useState)(!1), a = (0, R.useRef)(null), o = e.back ? n.sourceToolsHtml(e.setId) : "";
return (0, R.useEffect)(() => {
a.current && o && n.wireSourceTools(a.current);
}, [n, o]), /* @__PURE__ */ (0, z.jsxs)("span", {
"data-entity-sorts": "",
children: [
- e.shuffle ? /* @__PURE__ */ (0, z.jsx)(sk, {
+ e.shuffle ? /* @__PURE__ */ (0, z.jsx)($O, {
onPress: () => {
i(!0), t.reshuffle().finally(() => i(!1));
},
busy: r
}) : null,
- /* @__PURE__ */ (0, z.jsx)(ok, {
+ /* @__PURE__ */ (0, z.jsx)(QO, {
label: "图片布局",
value: e.layout,
options: e.layouts,
@@ -34911,34 +34911,34 @@ function sle({ head: e, actions: t, helpers: n }) {
}
//#endregion
//#region src/react/catalog-filter/catalog-filter-page.tsx
-var lk = "";
-function cle(e) {
- let t = !e.tiers, n = hle(e.comboHost);
+var tk = "";
+function gle(e) {
+ let t = !e.tiers, n = Cle(e.comboHost);
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-catalog-root": "",
"data-loading": t || void 0,
"data-refreshing": e.refreshing || void 0,
className: "contents",
children: [
- n ? (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(ak, {
+ n ? (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(ZO, {
items: e.combo,
hidden: e.comboHidden,
actions: e.actions
}), n) : null,
- /* @__PURE__ */ (0, z.jsx)(dle, { ...e }),
- e.offscreen ? null : /* @__PURE__ */ (0, z.jsx)(lle, { ...e })
+ /* @__PURE__ */ (0, z.jsx)(yle, { ...e }),
+ e.offscreen ? null : /* @__PURE__ */ (0, z.jsx)(_le, { ...e })
]
});
}
-function lle(e) {
- let { actions: t, helpers: n } = e, r = (0, R.useRef)(null), i = (0, R.useRef)(null), a = (0, R.useRef)(null), o = (0, R.useRef)(null), s = (0, R.useRef)(null), c = ZO(r, i, "[data-catalog-view][aria-pressed=\"true\"]", e.state);
+function _le(e) {
+ let { actions: t, helpers: n } = e, r = (0, R.useRef)(null), i = (0, R.useRef)(null), a = (0, R.useRef)(null), o = (0, R.useRef)(null), s = (0, R.useRef)(null), c = UO(r, i, "[data-catalog-view][aria-pressed=\"true\"]", e.state);
(0, R.useEffect)(() => {
n.wireDrag(o.current), n.wireScroller(a.current), n.wireDrag(s.current);
}, [n]);
- let l = !e.tiers, u = dk(o, e.tags, e.tiers?.key ?? "", e.tagFirst);
+ let l = !e.tiers, u = rk(o, e.tags, e.tiers?.key ?? "", e.tagFirst);
return (0, R.useLayoutEffect)(() => {
M(o.current, "tagbar");
- }, [u]), /* @__PURE__ */ (0, z.jsx)(HO, {
+ }, [u]), /* @__PURE__ */ (0, z.jsx)(IO, {
label: "筛选与排序",
topLabel: "视图与标签",
attrs: {
@@ -34981,17 +34981,17 @@ function lle(e) {
}), /* @__PURE__ */ (0, z.jsxs)("div", {
ref: o,
"data-catalog-tags": "",
- children: [e.empty || l ? /* @__PURE__ */ (0, z.jsx)(uk, { kind: "tag" }) : null, u.map((e) => /* @__PURE__ */ (0, z.jsx)(ule, {
+ children: [e.empty || l ? /* @__PURE__ */ (0, z.jsx)(nk, { kind: "tag" }) : null, u.map((e) => /* @__PURE__ */ (0, z.jsx)(vle, {
tag: e,
onPress: t.toggleTag
}, e.k))]
})]
}),
- bottom: e.trash ? null : /* @__PURE__ */ (0, z.jsx)(ple, { ...e })
+ bottom: e.trash ? null : /* @__PURE__ */ (0, z.jsx)(xle, { ...e })
});
}
-function ule({ tag: e, onPress: t }) {
- return /* @__PURE__ */ (0, z.jsxs)(UO, {
+function vle({ tag: e, onPress: t }) {
+ return /* @__PURE__ */ (0, z.jsxs)(LO, {
"data-catalog-tag": e.k,
"data-entity-press": "",
pressed: e.selected,
@@ -35002,12 +35002,12 @@ function ule({ tag: e, onPress: t }) {
})]
});
}
-function dle(e) {
+function yle(e) {
let { actions: t, helpers: n } = e, r = e.tiers ?? {
key: "",
performers: [],
studios: []
- }, i = e.empty || !e.tiers, a = (0, R.useRef)(null), o = (0, R.useRef)(null), s = (0, R.useCallback)((e) => () => t.moreTops(e), [t]), c = dk(a, r.performers, r.key, 24, i ? void 0 : s("performers")), l = dk(o, r.studios, r.key, 24, i ? void 0 : s("studios")), u = i || r.performers.length > 0, d = i || r.studios.length > 0;
+ }, i = e.empty || !e.tiers, a = (0, R.useRef)(null), o = (0, R.useRef)(null), s = (0, R.useCallback)((e) => () => t.moreTops(e), [t]), c = rk(a, r.performers, r.key, 24, i ? void 0 : s("performers")), l = rk(o, r.studios, r.key, 24, i ? void 0 : s("studios")), u = i || r.performers.length > 0, d = i || r.studios.length > 0;
return (0, R.useEffect)(() => {
n.wireDrag(a.current), n.wireDrag(o.current);
}, [
@@ -35020,7 +35020,7 @@ function dle(e) {
children: [u ? /* @__PURE__ */ (0, z.jsx)("div", {
ref: a,
"data-catalog-tier": "performers",
- children: i ? /* @__PURE__ */ (0, z.jsx)(uk, { kind: "performer" }) : c.map((e) => /* @__PURE__ */ (0, z.jsxs)("button", {
+ children: i ? /* @__PURE__ */ (0, z.jsx)(nk, { kind: "performer" }) : c.map((e) => /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
"data-tier-performer": "",
"data-entity-kind": "performer",
@@ -35037,18 +35037,18 @@ function dle(e) {
}) : null, d ? /* @__PURE__ */ (0, z.jsx)("div", {
ref: o,
"data-catalog-tier": "studios",
- children: i ? /* @__PURE__ */ (0, z.jsx)(uk, { kind: "studio" }) : l.map((e) => /* @__PURE__ */ (0, z.jsxs)("button", {
+ children: i ? /* @__PURE__ */ (0, z.jsx)(nk, { kind: "studio" }) : l.map((e) => /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
"data-tier-studio": "",
"data-entity-kind": "studio",
"data-entity-name": e.name,
onClick: () => t.openEntity("studio", e.name),
- children: [/* @__PURE__ */ (0, z.jsx)(fle, { studio: e }), e.name]
+ children: [/* @__PURE__ */ (0, z.jsx)(ble, { studio: e }), e.name]
}, e.name))
}) : null]
});
}
-function fle({ studio: e }) {
+function ble({ studio: e }) {
let [t, n] = (0, R.useState)(!1);
return /* @__PURE__ */ (0, z.jsx)("span", {
"data-tier-mark": "",
@@ -35062,7 +35062,7 @@ function fle({ studio: e }) {
}) : e.fallback
});
}
-function uk({ kind: e }) {
+function nk({ kind: e }) {
let t = Array.from({ length: 64 }, (e, t) => t);
return e === "tag" ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-catalog-placeholder": "tag",
@@ -35078,32 +35078,32 @@ function uk({ kind: e }) {
children: [/* @__PURE__ */ (0, z.jsx)("span", {}), /* @__PURE__ */ (0, z.jsx)("span", { children: "\xA0" })]
}, t)) });
}
-function ple({ count: e, refreshing: t, layout: n, sorts: r, actions: i }) {
+function xle({ count: e, refreshing: t, layout: n, sorts: r, actions: i }) {
let [a, o] = (0, R.useState)(!1);
- return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(mle, { count: e }), /* @__PURE__ */ (0, z.jsxs)("span", {
+ return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(Sle, { count: e }), /* @__PURE__ */ (0, z.jsxs)("span", {
"data-entity-sorts": "",
children: [
- /* @__PURE__ */ (0, z.jsx)(sk, {
+ /* @__PURE__ */ (0, z.jsx)($O, {
onPress: () => {
o(!0), i.reshuffle().finally(() => o(!1));
},
busy: a || t
}),
- n ? /* @__PURE__ */ (0, z.jsx)(ok, {
+ n ? /* @__PURE__ */ (0, z.jsx)(QO, {
name: n.name,
label: n.label,
value: n.value,
options: n.options,
onChange: i.setLayout
}, n.name) : null,
- /* @__PURE__ */ (0, z.jsx)(ck, {
+ /* @__PURE__ */ (0, z.jsx)(ek, {
sorts: r,
onSort: i.setSort
})
]
})] });
}
-function mle({ count: e }) {
+function Sle({ count: e }) {
let t = (0, R.useRef)(null), n = (0, R.useRef)(null), r = e ? `${e.total.toLocaleString()} 个符合 · 显示 ${e.shown}` : "";
return (0, R.useLayoutEffect)(() => {
if (!e) {
@@ -35111,7 +35111,7 @@ function mle({ count: e }) {
return;
}
let i = t.current;
- i && (lk && i.dataset.popCount === void 0 && (i.dataset.popCount = lk), lk = r, N(i, r));
+ i && (tk && i.dataset.popCount === void 0 && (i.dataset.popCount = tk), tk = r, N(i, r));
}, [e, r]), e ? /* @__PURE__ */ (0, z.jsx)("span", {
ref: t,
"data-catalog-readout": "",
@@ -35127,7 +35127,7 @@ function mle({ count: e }) {
})
}, "skeleton");
}
-function hle(e) {
+function Cle(e) {
let [t, n] = (0, R.useState)(null);
return (0, R.useLayoutEffect)(() => {
if (!e) return;
@@ -35137,7 +35137,7 @@ function hle(e) {
};
}, [e]), t;
}
-function dk(e, t, n, r, i) {
+function rk(e, t, n, r, i) {
let a = () => ({
key: n,
limit: r,
@@ -35183,15 +35183,15 @@ function dk(e, t, n, r, i) {
}
//#endregion
//#region src/react/components/board-tabs.tsx
-function fk({ value: e }) {
+function ik({ value: e }) {
return /* @__PURE__ */ (0, z.jsx)("span", {
"data-tab-count": "",
className: "ml-1.5 inline-block rounded-sm bg-text-primary/10 px-1 py-px text-caption-1-medium text-text-primary opacity-50",
children: e.toLocaleString()
});
}
-var pk = "relative z-1 flex flex-none cursor-pointer items-center whitespace-nowrap border-b-2 border-transparent px-3 py-2.5 text-body-regular text-text-secondary outline-none focus-visible:outline-2 focus-visible:-outline-offset-3 focus-visible:outline-border-focus-ring aria-selected:font-medium aria-selected:text-border-focus-ring max-board-narrow:px-2.25 max-board-narrow:text-body-2-regular";
-function mk({ tabs: e, value: t, label: n, onChange: r }) {
+var wle = "relative z-1 flex flex-none cursor-pointer items-center whitespace-nowrap border-b-2 border-transparent px-3 py-2.5 text-body-regular text-text-secondary outline-none focus-visible:outline-2 focus-visible:-outline-offset-3 focus-visible:outline-border-focus-ring aria-selected:font-medium aria-selected:text-border-focus-ring max-board-narrow:px-2.25 max-board-narrow:text-body-2-regular";
+function ak({ tabs: e, value: t, label: n, onChange: r }) {
let i = (0, R.useRef)(null), a = (0, R.useRef)(null);
return (0, R.useLayoutEffect)(() => {
let e = i.current;
@@ -35226,7 +35226,7 @@ function mk({ tabs: e, value: t, label: n, onChange: r }) {
"data-tab": e.value,
"aria-selected": i,
tabIndex: i ? 0 : -1,
- className: pk,
+ className: wle,
onClick: () => {
i || r(e.value);
},
@@ -35242,21 +35242,21 @@ function mk({ tabs: e, value: t, label: n, onChange: r }) {
}
//#endregion
//#region src/react/search/search.ts
-var hk = /* @__PURE__ */ new Set([
+var ok = /* @__PURE__ */ new Set([
"performer",
"creator",
"studio",
"agency",
"series"
-]), gk = /* @__PURE__ */ new Set(["asset"]), _k = (e) => String(e ?? "").normalize("NFKC").trim().toLocaleLowerCase();
-function vk({ query: e, history: t, picks: n, suggestFor: r, groups: i, tabs: a, kind: o }) {
+]), sk = /* @__PURE__ */ new Set(["asset"]), ck = (e) => String(e ?? "").normalize("NFKC").trim().toLocaleLowerCase();
+function Tle({ query: e, history: t, picks: n, suggestFor: r, groups: i, tabs: a, kind: o }) {
let s = 0, c = [], l = (e) => {
let t = {
...e,
index: s++
};
return c.push(t), t;
- }, u = t.filter((t) => !e || _k(t).includes(_k(e)));
+ }, u = t.filter((t) => !e || ck(t).includes(ck(e)));
if (!e) {
let e = u.length ? {
label: "搜索记录",
@@ -35294,7 +35294,7 @@ function vk({ query: e, history: t, picks: n, suggestFor: r, groups: i, tabs: a,
kind: e.kind,
item: t
}))
- }), h = p.filter((e) => !gk.has(e.kind)).map(m), g = p.filter((e) => gk.has(e.kind)).map(m);
+ }), h = p.filter((e) => !sk.has(e.kind)).map(m), g = p.filter((e) => sk.has(e.kind)).map(m);
return {
tabs: d && a.length > 1 ? [...a] : null,
recent: f,
@@ -35303,17 +35303,17 @@ function vk({ query: e, history: t, picks: n, suggestFor: r, groups: i, tabs: a,
options: c
};
}
-function yk(e, t, n = Math.random) {
+function Ele(e, t, n = Math.random) {
let r = [...e];
for (let e = r.length - 1; e > 0; --e) {
let t = Math.floor(n() * (e + 1));
[r[e], r[t]] = [r[t], r[e]];
}
- return r.filter((e) => !t.some((t) => _k(t) === _k(e))).slice(0, 5);
+ return r.filter((e) => !t.some((t) => ck(t) === ck(e))).slice(0, 5);
}
//#endregion
//#region src/react/search/search-page.tsx
-var bk = () => ({
+var Dle = () => ({
history: [],
pool: [],
poolRequest: 0,
@@ -35328,7 +35328,7 @@ var bk = () => ({
active: -1,
reveal: !1,
rewind: !1
-}), xk = (e) => vk({
+}), lk = (e) => Tle({
query: e.query,
history: e.history,
picks: e.picks,
@@ -35336,18 +35336,18 @@ var bk = () => ({
groups: e.groups,
tabs: e.tabs,
kind: e.kind
-}), gle = (e) => !!(e.tabs || e.recent || e.left.length || e.right.length), Sk = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("svg", {
+}), uk = (e) => !!(e.tabs || e.recent || e.left.length || e.right.length), dk = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
"aria-hidden": "true",
children: /* @__PURE__ */ (0, z.jsx)("use", { href: `#i-${e}` })
});
-function _le(e) {
+function fk(e) {
let t = (0, R.useRef)(e);
t.current = e;
let n = (0, R.useRef)(null);
- n.current ??= bk();
+ n.current ??= Dle();
let r = n.current, i = (0, R.useRef)(null), [, a] = (0, R.useReducer)((e) => e + 1, 0), o = (0, R.useRef)(null);
- o.current ??= vle(() => t.current, r, () => i.current?.closest("[data-search-menu]") ?? null, a);
+ o.current ??= pk(() => t.current, r, () => i.current?.closest("[data-search-menu]") ?? null, a);
let s = o.current;
(0, R.useLayoutEffect)(() => {
let { input: e } = t.current, n = (e) => s.input(e), i = () => t.current.helpers.composing(), a = (e) => s.key(e), o = () => s.focus();
@@ -35360,7 +35360,7 @@ function _le(e) {
let e = i.current?.closest("[data-search-menu]");
r.rewind && e && (e.scrollTop = 0), r.rewind = !1, r.reveal && i.current?.querySelector("[data-search-option][data-active]")?.scrollIntoView({ block: "nearest" }), r.reveal = !1;
});
- let c = xk(r), l = e.historyLimit, u = (t) => /* @__PURE__ */ (0, z.jsx)(ble, {
+ let c = lk(r), l = e.historyLimit, u = (t) => /* @__PURE__ */ (0, z.jsx)(gk, {
entry: t,
active: t.index === r.active,
helpers: e.helpers,
@@ -35380,7 +35380,7 @@ function _le(e) {
"data-search-root": "",
"data-history-limit": l,
children: [
- c.tabs ? /* @__PURE__ */ (0, z.jsx)(yle, {
+ c.tabs ? /* @__PURE__ */ (0, z.jsx)(mk, {
tabs: c.tabs,
kind: r.kind,
onPick: s.pickKind,
@@ -35401,7 +35401,7 @@ function _le(e) {
]
});
}
-function vle(e, t, n, r) {
+function pk(e, t, n, r) {
let i = () => e().input, a = () => document.activeElement === i(), o = () => t.history.slice(0, e().historyLimit), s = (n) => {
t.history = n.slice(0, e().historyLimit);
}, c = async () => {
@@ -35415,7 +35415,7 @@ function vle(e, t, n, r) {
t.history = Array.isArray(e.items) ? e.items.map(String) : [];
} catch {}
}, l = (t) => {
- !t || !e().historyLimit || (s([t, ...o().filter((e) => _k(e) !== _k(t))]), G("/api/search-history", { query: t }).catch(() => null));
+ !t || !e().historyLimit || (s([t, ...o().filter((e) => ck(e) !== ck(t))]), G("/api/search-history", { query: t }).catch(() => null));
}, u = async () => {
let n = ++t.poolRequest;
t.pool = [];
@@ -35448,9 +35448,9 @@ function vle(e, t, n, r) {
let i = n();
i && e().helpers.dismiss(i), t.active = -1, r();
}, m = () => {
- t.query = i().value.trim(), t.picks = t.query ? [] : yk(t.pool, o()), t.active = -1;
+ t.query = i().value.trim(), t.picks = t.query ? [] : Ele(t.pool, o()), t.active = -1;
let a = n();
- a && (gle(xk(t)) ? e().helpers.present(a) : e().helpers.dismiss(a)), r();
+ a && (uk(lk(t)) ? e().helpers.present(a) : e().helpers.dismiss(a)), r();
}, h = () => {
t.active = -1, t.kind = "", clearTimeout(t.timer);
let e = i().value.trim();
@@ -35462,7 +35462,7 @@ function vle(e, t, n, r) {
!n || e === t.kind || (t.kind = e, clearTimeout(t.timer), m(), t.rewind = !0, d(n, e).then(() => {
a() && t.kind === e && m();
}));
- }, _ = () => f() ? xk(t).options : [], v = (e) => {
+ }, _ = () => f() ? lk(t).options : [], v = (e) => {
let n = _();
return n.length ? (t.active = (t.active + e + n.length) % n.length, t.reveal = !0, r(), !0) : !1;
}, y = (t, n) => {
@@ -35475,7 +35475,7 @@ function vle(e, t, n, r) {
i().blur(), e().actions.openItem(t.item.id);
return;
}
- if (t.type === "suggest" && hk.has(t.kind)) {
+ if (t.type === "suggest" && ok.has(t.kind)) {
b(t.kind, t.value);
return;
}
@@ -35527,12 +35527,12 @@ function vle(e, t, n, r) {
await G("/api/search-history", {
operation: "remove",
query: e
- }).catch(() => null), s(o().filter((t) => _k(t) !== _k(e))), t.active = -1, r();
+ }).catch(() => null), s(o().filter((t) => ck(t) !== ck(e))), t.active = -1, r();
},
pickKind: g
};
}
-function yle({ tabs: e, kind: t, onPick: n, wire: r }) {
+function mk({ tabs: e, kind: t, onPick: n, wire: r }) {
let i = (0, R.useRef)(null);
(0, R.useLayoutEffect)(() => {
r(i.current);
@@ -35544,7 +35544,7 @@ function yle({ tabs: e, kind: t, onPick: n, wire: r }) {
"aria-selected": t === e,
onMouseDown: (e) => e.preventDefault(),
onClick: () => n(e),
- children: [r, i ? /* @__PURE__ */ (0, z.jsx)(fk, { value: i }) : null]
+ children: [r, i ? /* @__PURE__ */ (0, z.jsx)(ik, { value: i }) : null]
}, e || "all");
return /* @__PURE__ */ (0, z.jsxs)("div", {
ref: i,
@@ -35554,8 +35554,8 @@ function yle({ tabs: e, kind: t, onPick: n, wire: r }) {
children: [a("", "全部"), e.map((e) => a(e.kind, e.label, e.total))]
});
}
-var Ck = (e) => e.preventDefault();
-function ble({ entry: e, active: t, helpers: n, onPick: r, onPeek: i, onRemove: a }) {
+var hk = (e) => e.preventDefault();
+function gk({ entry: e, active: t, helpers: n, onPick: r, onPeek: i, onRemove: a }) {
let o = {
"data-search-value": e.value,
"data-active": t ? "" : void 0,
@@ -35567,28 +35567,28 @@ function ble({ entry: e, active: t, helpers: n, onPick: r, onPeek: i, onRemove:
"data-search-option": "",
...o,
children: [
- /* @__PURE__ */ (0, z.jsx)(Sk, { name: e.type === "history" ? "history" : "sparkles" }),
+ /* @__PURE__ */ (0, z.jsx)(dk, { name: e.type === "history" ? "history" : "sparkles" }),
/* @__PURE__ */ (0, z.jsx)("span", { children: e.value }),
e.type === "history" ? /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-remove-history": e.value,
"aria-label": `删除历史 ${e.value}`,
- onMouseDown: Ck,
+ onMouseDown: hk,
onClick: (t) => {
t.stopPropagation(), a(e.value);
},
- children: /* @__PURE__ */ (0, z.jsx)(Sk, { name: "x" })
+ children: /* @__PURE__ */ (0, z.jsx)(dk, { name: "x" })
}) : null
]
});
- let { item: s, kind: c } = e, l = hk.has(c) ? c : void 0;
+ let { item: s, kind: c } = e, l = ok.has(c) ? c : void 0;
if (c === "asset") {
let e = [s.who, s.code ? s.title : ""].filter(Boolean).join(" · ");
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-search-option": "work",
"data-open-item": s.id,
...o,
- children: [/* @__PURE__ */ (0, z.jsx)(wk, {
+ children: [/* @__PURE__ */ (0, z.jsx)(_k, {
card: s.card,
helpers: n
}), /* @__PURE__ */ (0, z.jsxs)("span", {
@@ -35614,7 +35614,7 @@ function ble({ entry: e, active: t, helpers: n, onPick: r, onPeek: i, onRemove:
"data-open-entity": l,
...o,
children: [
- /* @__PURE__ */ (0, z.jsx)(Tk, {
+ /* @__PURE__ */ (0, z.jsx)(vk, {
item: s,
kind: c,
helpers: n
@@ -35635,11 +35635,11 @@ function ble({ entry: e, active: t, helpers: n, onPick: r, onPeek: i, onRemove:
type: "button",
"data-open-work": e.id,
"aria-label": `打开 ${e.code || s.value}`,
- onMouseDown: Ck,
+ onMouseDown: hk,
onClick: (t) => {
t.stopPropagation(), i(e);
},
- children: /* @__PURE__ */ (0, z.jsx)(wk, {
+ children: /* @__PURE__ */ (0, z.jsx)(_k, {
card: e,
helpers: n
})
@@ -35653,7 +35653,7 @@ function ble({ entry: e, active: t, helpers: n, onPick: r, onPeek: i, onRemove:
"data-open-entity": l,
...o,
children: [
- c === "studio" || c === "agency" ? /* @__PURE__ */ (0, z.jsx)(Tk, {
+ c === "studio" || c === "agency" ? /* @__PURE__ */ (0, z.jsx)(vk, {
item: s,
kind: c,
helpers: n
@@ -35667,13 +35667,13 @@ function ble({ entry: e, active: t, helpers: n, onPick: r, onPeek: i, onRemove:
]
});
}
-function wk({ card: e, helpers: t }) {
+function _k({ card: e, helpers: t }) {
return /* @__PURE__ */ (0, z.jsx)("span", {
"data-search-pic": "",
dangerouslySetInnerHTML: { __html: t.coverHtml(e) }
});
}
-function Tk({ item: e, kind: t, helpers: n }) {
+function vk({ item: e, kind: t, helpers: n }) {
return /* @__PURE__ */ (0, z.jsx)("span", {
"data-search-face": "",
"data-kind": t,
@@ -35682,8 +35682,8 @@ function Tk({ item: e, kind: t, helpers: n }) {
}
//#endregion
//#region src/react/feed-new/feed-new.ts
-var Ek = (e) => ["feed-new", e ?? "home"], xle = 8, Sle = 1500;
-function Cle(e, t, n) {
+var yk = (e) => ["feed-new", e ?? "home"], bk = 8, xk = 1500;
+function Sk(e, t, n) {
let r = document.createElement("template");
r.innerHTML = e;
let i = [...r.content.querySelectorAll("img[src]")].slice(0, t).map((e) => {
@@ -35694,32 +35694,32 @@ function Cle(e, t, n) {
setTimeout(e, n);
})]);
}
-async function wle(e, n, r) {
+async function Ck(e, n, r) {
let i = new URLSearchParams({ limit: "12" });
e && i.set("entity", String(e));
let a = await t(`/api/feeds/discoveries?${i}`).catch(() => null), o = a && !a.error ? a : null, s = o?.items || [], c = n(o);
- return r && s.length && await Cle(c, xle, Sle), {
+ return r && s.length && await Sk(c, bk, xk), {
items: s,
html: c
};
}
-var Dk = (e, t, n = !1) => ({
- queryKey: Ek(e),
- queryFn: () => wle(e, t, n),
+var wk = (e, t, n = !1) => ({
+ queryKey: yk(e),
+ queryFn: () => Ck(e, t, n),
staleTime: Infinity
-}), Ok = (e, n) => t("/api/feeds/discovery", {
+}), Tk = (e, n) => t("/api/feeds/discovery", {
method: "POST",
body: JSON.stringify({
action: n,
ids: [e]
})
}).then(() => void 0, () => void 0);
-async function Tle(e) {
- X.removeQueries({ queryKey: Ek(null) }), await X.fetchQuery(Dk(null, e.helpers.feedRowHtml, e.host.getAttribute("aria-busy") === "true"));
+async function Ek(e) {
+ X.removeQueries({ queryKey: yk(null) }), await X.fetchQuery(wk(null, e.helpers.feedRowHtml, e.host.getAttribute("aria-busy") === "true"));
}
//#endregion
//#region src/react/entity-page/entity-page.ts
-var Ele = [
+var Dk = [
"loc",
"creator",
"tag",
@@ -35729,14 +35729,14 @@ var Ele = [
"orient",
"sort",
"dir"
-], kk = {
+], Ok = {
media: "videos",
set: 0
-}, Ak = (e, t) => [
+}, kk = (e, t) => [
"entity",
e,
t
-], Dle = (e, t, n, r) => [
+], Ak = (e, t, n, r) => [
"entity-items",
e,
t,
@@ -35748,33 +35748,33 @@ var Ele = [
t,
n,
r
-], Mk = (e) => String(e || "").split(",").filter(Boolean), Ole = (e, t) => Mk(e).includes(t);
-function Nk(e, t, n, r, i = 0) {
+], Mk = (e) => String(e || "").split(",").filter(Boolean), Nk = (e, t) => Mk(e).includes(t);
+function Pk(e, t, n, r, i = 0) {
let a = new URLSearchParams();
a.set(e, t), a.set("limit", "48"), a.set("offset", String(i)), a.set("sort", n.sort || "new"), n.dir && a.set("dir", n.dir), n.sort === "seed" && a.set("seed", r.seed), i && a.set("count", "0");
- for (let t of Ele) n[t] && t !== e && t !== "sort" && a.set(t, n[t]);
+ for (let t of Dk) n[t] && t !== e && t !== "sort" && a.set(t, n[t]);
return r.jav && a.set("jav", "1"), a;
}
-async function Pk(e, n, r, i, a, o, s) {
- let c = await t(`/api/items?${Nk(e, n, r, i, a)}`, s ? { signal: s } : {});
+async function Fk(e, n, r, i, a, o, s) {
+ let c = await t(`/api/items?${Pk(e, n, r, i, a)}`, s ? { signal: s } : {});
return o(c.items || []), c;
}
-var Fk = (e) => {
+var Ik = (e) => {
let t = {
jav: e.jav,
seed: e.seed
- }, n = Nk(e.kind, e.name, e.filters, t).toString();
+ }, n = Pk(e.kind, e.name, e.filters, t).toString();
return {
- queryKey: Dle(e.kind, e.name, n, e.revision),
- queryFn: ({ signal: n }) => Pk(e.kind, e.name, e.filters, t, 0, e.cache, n),
+ queryKey: Ak(e.kind, e.name, n, e.revision),
+ queryFn: ({ signal: n }) => Fk(e.kind, e.name, e.filters, t, 0, e.cache, n),
staleTime: Infinity
};
-}, Ik = (e, n) => ({
- queryKey: Ak(e, n),
+}, Lk = (e, n) => ({
+ queryKey: kk(e, n),
queryFn: ({ signal: r }) => t(`/api/entity?kind=${encodeURIComponent(e)}&name=${encodeURIComponent(n)}`, { signal: r }),
staleTime: Infinity
});
-function kle(e, t, n, r, i, a) {
+function Rk(e, t, n, r, i, a) {
let o = `kind=${encodeURIComponent(e)}&name=${encodeURIComponent(t)}`;
if (i) {
let e = `&limit=120&offset=${i}${a ? `&seed=${encodeURIComponent(a)}` : ""}`;
@@ -35783,10 +35783,10 @@ function kle(e, t, n, r, i, a) {
let s = r ? `&seed=${encodeURIComponent(r)}` : "";
return n ? `/api/photo-set?id=${n}&limit=120${s}` : r ? `/api/photos?${o}&limit=120${s}` : `/api/photos?${o}`;
}
-var Lk = (e, n, r, i) => ({
+var zk = (e, n, r, i) => ({
queryKey: jk(e, n, r, i),
queryFn: async ({ pageParam: a }) => {
- let o = await t(kle(e, n, r, i, a?.offset || 0, a?.seed || "")).catch((e) => {
+ let o = await t(Rk(e, n, r, i, a?.offset || 0, a?.seed || "")).catch((e) => {
if (a) throw e;
return { error: String(e) };
});
@@ -35799,8 +35799,8 @@ var Lk = (e, n, r, i) => ({
seed: t[0]?.seed || ""
} : void 0,
staleTime: Infinity
-}), Rk = (e) => e && !e.error ? (e.sets || []).filter((e) => e.kind === "code") : [];
-async function Ale(e) {
+}), Bk = (e) => e && !e.error ? (e.sets || []).filter((e) => e.kind === "code") : [];
+async function Vk(e) {
let { kind: t, name: n } = e;
for (let e of [
"entity",
@@ -35812,51 +35812,51 @@ async function Ale(e) {
n
] });
await Promise.all([
- X.fetchQuery(Ik(t, n)).then((t) => !t || t.error || !t.id ? null : (X.removeQueries({ queryKey: Ek(Number(t.id)) }), X.fetchQuery(Dk(Number(t.id), e.helpers.feedRowHtml, !0)))),
- X.fetchQuery(Fk(e)),
- X.fetchInfiniteQuery(Lk(t, n, 0, "")),
- e.media.media === "photos" && e.media.set ? X.fetchInfiniteQuery(Lk(t, n, e.media.set, "")) : null
+ X.fetchQuery(Lk(t, n)).then((t) => !t || t.error || !t.id ? null : (X.removeQueries({ queryKey: yk(Number(t.id)) }), X.fetchQuery(wk(Number(t.id), e.helpers.feedRowHtml, !0)))),
+ X.fetchQuery(Ik(e)),
+ X.fetchInfiniteQuery(zk(t, n, 0, "")),
+ e.media.media === "photos" && e.media.set ? X.fetchInfiniteQuery(zk(t, n, e.media.set, "")) : null
]);
}
//#endregion
//#region src/react/follow/online-vocab.ts
-var jle = "/api/follow/authors", Mle = "/api/follow/tags", Nle = (e) => [
+var Hk = "/api/follow/authors", Uk = "/api/follow/tags", Wk = (e) => [
"follow",
"authors",
e
-], Ple = (e, t) => [
+], Gk = (e, t) => [
"follow",
"tags",
e,
t
];
-function Fle(e, t, n) {
+function Kk(e, t, n) {
let r = new URLSearchParams({
limit: String(t),
offset: String(n)
});
- return e && r.set("q", e), `${jle}?${r}`;
+ return e && r.set("q", e), `${Hk}?${r}`;
}
-function Ile(e, t, n, r) {
+function qk(e, t, n, r) {
let i = new URLSearchParams({
types: "all",
limit: String(n),
offset: String(r)
});
- return t && t !== "all" && i.set("type", t), e && i.set("q", e), `${Mle}?${i}`;
+ return t && t !== "all" && i.set("type", t), e && i.set("q", e), `${Uk}?${i}`;
}
-var Lle = (e, t, n, r) => W(Fle(e, t, n), r), Rle = (e, t, n, r, i) => W(Ile(e, t, n, r), i), zle = "/api/index", zk = {
+var Jk = (e, t, n, r) => W(Kk(e, t, n), r), Yk = (e, t, n, r, i) => W(qk(e, t, n, r), i), Xk = "/api/index", Zk = {
performers: "艺人",
creators: "创作者",
studios: "厂牌",
agencies: "事务所",
tags: "标签"
-}, Ble = {
+}, Qk = {
performers: "performer",
creators: "creator",
studios: "studio",
agencies: "agency"
-}, Bk = [
+}, $k = [
["all", "全部"],
["meta", "影片属性"],
["relationship", "人物关系"],
@@ -35866,26 +35866,26 @@ var Lle = (e, t, n, r) => W(Fle(e, t, n), r), Rle = (e, t, n, r, i) => W(Ile(e,
["story", "故事剧情"],
["position", "性交体位"],
["general", "其他内容"]
-], Vk = [
+], eA = [
["all", "全部"],
["general", "通用"],
["artist", "创作者"],
["character", "角色"],
["copyright", "作品"],
["metadata", "元数据"]
-], Hk = {
+], tA = {
people: 120,
tags: 180
-}, Uk = (e) => e !== "tags", Wk = (e) => e === "studios" || e === "agencies";
-function Gk(e) {
- let t = e.kind === "tags" || e.kind === "performers" ? e.scope : "local", n = (t === "online" ? Vk : Bk).some(([t]) => t === e.category);
+}, nA = (e) => e !== "tags", rA = (e) => e === "studios" || e === "agencies";
+function iA(e) {
+ let t = e.kind === "tags" || e.kind === "performers" ? e.scope : "local", n = (t === "online" ? eA : $k).some(([t]) => t === e.category);
return {
...e,
scope: t,
category: e.kind === "tags" && n ? e.category : "all"
};
}
-function Kk(e) {
+function aA(e) {
let { kind: t, q: n, scope: r, category: i } = e;
return t === "tags" ? r === "online" ? {
what: "online-tags",
@@ -35904,50 +35904,50 @@ function Kk(e) {
q: n
};
}
-var qk = (e, t, n = "all") => [
+var oA = (e, t, n = "all") => [
"index",
e,
t,
...e === "tags" ? [n] : []
];
-function Jk(e, t, n, r, i) {
+function sA(e, t, n, r, i) {
let a = new URLSearchParams({
kind: e,
limit: String(r),
offset: String(i)
});
- return t && a.set("q", t), e === "tags" && n !== "all" && a.set("category", n), `${zle}?${a}`;
+ return t && a.set("q", t), e === "tags" && n !== "all" && a.set("category", n), `${Xk}?${a}`;
}
-function Yk(e) {
- let t = e.what === "people" || e.what === "online-authors" ? Hk.people : Hk.tags, n = {
+function cA(e) {
+ let t = e.what === "people" || e.what === "online-authors" ? tA.people : tA.tags, n = {
initialPageParam: 0,
getNextPageParam: (e, t) => e.has_more ? t.reduce((e, t) => e + t.items.length, 0) : void 0
};
switch (e.what) {
case "people": return {
...n,
- queryKey: qk(e.kind, e.q),
- queryFn: ({ pageParam: n, signal: r }) => W(Jk(e.kind, e.q, "all", t, n), r)
+ queryKey: oA(e.kind, e.q),
+ queryFn: ({ pageParam: n, signal: r }) => W(sA(e.kind, e.q, "all", t, n), r)
};
case "tags": return {
...n,
- queryKey: qk("tags", e.q, e.category),
- queryFn: ({ pageParam: n, signal: r }) => W(Jk("tags", e.q, e.category, t, n), r)
+ queryKey: oA("tags", e.q, e.category),
+ queryFn: ({ pageParam: n, signal: r }) => W(sA("tags", e.q, e.category, t, n), r)
};
case "online-authors": return {
...n,
- queryKey: Nle(e.q),
- queryFn: ({ pageParam: n, signal: r }) => Lle(e.q, t, n, r)
+ queryKey: Wk(e.q),
+ queryFn: ({ pageParam: n, signal: r }) => Jk(e.q, t, n, r)
};
case "online-tags": return {
...n,
- queryKey: Ple(e.q, e.category),
- queryFn: ({ pageParam: n, signal: r }) => Rle(e.q, e.category, t, n, r)
+ queryKey: Gk(e.q, e.category),
+ queryFn: ({ pageParam: n, signal: r }) => Yk(e.q, e.category, t, n, r)
};
}
}
-async function Vle(e, t) {
- let n = Yk(Kk(Gk(e)));
+async function lA(e, t) {
+ let n = cA(aA(iA(e)));
X.removeQueries({
queryKey: n.queryKey,
exact: !0
@@ -35961,13 +35961,13 @@ async function Vle(e, t) {
getNextPageParam: n.getNextPageParam
});
}
-var Hle = (e) => e ? e.pages.flatMap((e) => e.items) : [], Ule = (e, t) => `${e}${t ? "+" : ""} 项`, Xk = (e, t) => e ? `r34-${t || "unknown"}` : t || "general", Wle = (e, t) => e === "agencies" ? `${(t.members || 0).toLocaleString()} 人` : t.n.toLocaleString(), Gle = {
+var uA = (e) => e ? e.pages.flatMap((e) => e.items) : [], dA = (e, t) => `${e}${t ? "+" : ""} 项`, fA = (e, t) => e ? `r34-${t || "unknown"}` : t || "general", pA = (e, t) => e === "agencies" ? `${(t.members || 0).toLocaleString()} 人` : t.n.toLocaleString(), mA = {
numeric: !0,
sensitivity: "base"
};
-function Kle(e, t) {
+function hA(e, t) {
let n = /* @__PURE__ */ new Map();
- for (let r of [...e].sort((e, t) => e.k.localeCompare(t.k, "zh-CN", Gle))) {
+ for (let r of [...e].sort((e, t) => e.k.localeCompare(t.k, "zh-CN", mA))) {
let e = t(r.k).normalize("NFKC").trim().charAt(0).toUpperCase(), i = /[A-Z]/.test(e) ? e : /[0-9]/.test(e) ? "#" : /[㐀-鿿]/.test(e) ? "中文" : "其他", a = n.get(i);
a ? a.push(r) : n.set(i, [r]);
}
@@ -35975,7 +35975,7 @@ function Kle(e, t) {
}
//#endregion
//#region src/react/index/index-people.tsx
-function Zk({ html: e, face: t, company: n, big: r }) {
+function gA({ html: e, face: t, company: n, big: r }) {
let i = (0, R.useRef)(null);
return (0, R.useLayoutEffect)(() => {
t ? i.current?.style.setProperty("--face", t) : i.current?.style.removeProperty("--face");
@@ -35987,8 +35987,8 @@ function Zk({ html: e, face: t, company: n, big: r }) {
dangerouslySetInnerHTML: { __html: e }
});
}
-var qle = "flex cursor-pointer flex-col gap-2 p-3 text-inherit";
-function Qk({ name: e, readout: t, big: n, children: r, onPress: i, ...a }) {
+var _A = "flex cursor-pointer flex-col gap-2 p-3 text-inherit";
+function vA({ name: e, readout: t, big: n, children: r, onPress: i, ...a }) {
return /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
...a,
@@ -35998,7 +35998,7 @@ function Qk({ name: e, readout: t, big: n, children: r, onPress: i, ...a }) {
radius: "plain",
padding: "none",
interactive: !0,
- className: `${qle} ${n ? "items-stretch text-left" : "items-center text-center"}`
+ className: `${_A} ${n ? "items-stretch text-left" : "items-center text-center"}`
}),
children: [
r,
@@ -36015,8 +36015,8 @@ function Qk({ name: e, readout: t, big: n, children: r, onPress: i, ...a }) {
]
});
}
-function $k({ kind: e, items: t, layout: n, props: r }) {
- let i = Ble[e], a = Wk(e), o = n === "big";
+function yA({ kind: e, items: t, layout: n, props: r }) {
+ let i = Qk[e], a = rA(e), o = n === "big";
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-index-grid": "",
"data-layout": n,
@@ -36024,14 +36024,14 @@ function $k({ kind: e, items: t, layout: n, props: r }) {
className: `${a ? "index-grid-company" : "index-grid-person"} gap-3`,
children: t.map((t) => {
let n = r.personAvatar(t, i, o);
- return /* @__PURE__ */ (0, z.jsx)(Qk, {
+ return /* @__PURE__ */ (0, z.jsx)(vA, {
"data-k": t.k,
"data-kind": i,
name: t.k,
- readout: Wle(e, t),
+ readout: pA(e, t),
big: o,
onPress: () => r.openEntity(i, t.k),
- children: /* @__PURE__ */ (0, z.jsx)(Zk, {
+ children: /* @__PURE__ */ (0, z.jsx)(gA, {
html: n.html,
face: n.face,
company: a,
@@ -36041,21 +36041,21 @@ function $k({ kind: e, items: t, layout: n, props: r }) {
})
});
}
-function Jle({ items: e, layout: t, props: n }) {
+function bA({ items: e, layout: t, props: n }) {
let r = t === "big";
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-index-grid": "",
"data-layout": t,
"data-cells": "people",
className: "index-grid-person gap-3",
- children: e.map((e) => /* @__PURE__ */ (0, z.jsx)(Qk, {
+ children: e.map((e) => /* @__PURE__ */ (0, z.jsx)(vA, {
"data-follow-author": e.key,
"data-kind": "performer",
name: e.k,
readout: `${e.n.toLocaleString()} 项更新`,
big: r,
onPress: () => n.openFollowAuthor(e.key),
- children: /* @__PURE__ */ (0, z.jsx)(Zk, {
+ children: /* @__PURE__ */ (0, z.jsx)(gA, {
html: n.authorAvatar(e),
company: !1,
big: r
@@ -36065,14 +36065,14 @@ function Jle({ items: e, layout: t, props: n }) {
}
//#endregion
//#region src/board-controls.ts
-function Yle(e) {
+function xA(e) {
let t = Number(e.min) || 0, n = Number(e.max) || 100, r = Number(e.value), i = n > t ? Math.max(0, Math.min(100, (r - t) / (n - t) * 100)) : 0;
e.style.setProperty("--board-range-value", `${i}%`);
}
//#endregion
//#region src/react/photo-lightbox/photo-lightbox.ts
-var eA = "/vendor/swiper/14.2.0/", tA = null, Xle = () => tA ??= Promise.all([new Promise((e, t) => {
- let n = `${eA}swiper-bundle.min.css`, r = document.querySelector(`link[href="${n}"]`);
+var SA = "/vendor/swiper/14.2.0/", CA = null, wA = () => CA ??= Promise.all([new Promise((e, t) => {
+ let n = `${SA}swiper-bundle.min.css`, r = document.querySelector(`link[href="${n}"]`);
if (r?.sheet) {
e();
return;
@@ -36086,11 +36086,11 @@ var eA = "/vendor/swiper/14.2.0/", tA = null, Xle = () => tA ??= Promise.all([ne
return;
}
let r = document.createElement("script");
- r.src = `${eA}swiper-bundle.min.js`, r.onload = () => e(window.Swiper), r.onerror = () => t(/* @__PURE__ */ Error("swiper unavailable")), document.head.append(r);
+ r.src = `${SA}swiper-bundle.min.js`, r.onload = () => e(window.Swiper), r.onerror = () => t(/* @__PURE__ */ Error("swiper unavailable")), document.head.append(r);
})]).then(([, e]) => e).catch((e) => {
- throw tA = null, e;
+ throw CA = null, e;
});
-function Zle(e, t, n) {
+function TA(e, t, n) {
let r = "fit", i = () => t.slides?.[t.activeIndex]?.querySelector("img"), a = () => {
let e = i();
return !e?.naturalWidth || !e.naturalHeight ? 100 : Math.min(100, e.offsetWidth / e.naturalWidth * 100, e.offsetHeight / e.naturalHeight * 100);
@@ -36111,48 +36111,48 @@ function Zle(e, t, n) {
}
};
}
-var nA = (e) => {
+var EA = (e) => {
let t = Number(e) || 0;
return t ? (t < 1048576 ? `${Math.max(1, Math.round(t / 1024))} KB` : s(t)).replace(" ", "\xA0") : "大小未知";
-}, Qle = (e) => e.asset?.name || e.name || "未命名图片";
-function $le(t, n) {
+}, DA = (e) => e.asset?.name || e.name || "未命名图片";
+function OA(t, n) {
let r = t.asset;
- if (r) return [e[r.location ?? ""] || r.location || "来源未知", nA(r.size)].join(" · ");
+ if (r) return [e[r.location ?? ""] || r.location || "来源未知", EA(r.size)].join(" · ");
let i = (t.total ?? 0) > 1 ? `第 ${t.position} / ${t.total} 张` : "", a = n?.[0] && n[1] ? `${n[0]} × ${n[1]}` : "";
return [
t.source || "在线图片",
i,
a,
- t.size ? nA(t.size) : ""
+ t.size ? EA(t.size) : ""
].filter(Boolean).join(" · ");
}
//#endregion
//#region src/react/photo-lightbox/photo-lightbox-dialog.tsx
-var rA = null, iA = null, eue = 0;
-function tue() {
- return (!iA || !rA?.isConnected) && (iA?.unmount(), rA = document.createElement("div"), rA.className = "peach-react", rA.dataset.photoLightboxHost = "", document.body.append(rA), iA = (0, Be.createRoot)(rA)), iA;
+var kA = null, AA = null, jA = 0;
+function MA() {
+ return (!AA || !kA?.isConnected) && (AA?.unmount(), kA = document.createElement("div"), kA.className = "peach-react", kA.dataset.photoLightboxHost = "", document.body.append(kA), AA = (0, Be.createRoot)(kA)), AA;
}
-async function aA(e, t, n) {
+async function NA(e, t, n) {
if (!t.length || e < 0 || e >= t.length) return;
let r;
try {
- r = await Xle();
+ r = await wA();
} catch {
window.open(t[e].src, "_blank", "noopener");
return;
}
- let i = tue();
- (0, ze.flushSync)(() => i.render(/* @__PURE__ */ (0, z.jsx)(nue, {
+ let i = MA();
+ (0, ze.flushSync)(() => i.render(/* @__PURE__ */ (0, z.jsx)(FA, {
slides: t,
index: e,
Swiper: r,
host: n ?? null
- }, ++eue)));
+ }, ++jA)));
}
-function oA() {
- iA && (0, ze.flushSync)(() => iA.render(null));
+function PA() {
+ AA && (0, ze.flushSync)(() => AA.render(null));
}
-function nue({ slides: e, index: t, Swiper: n, host: r }) {
+function FA({ slides: e, index: t, Swiper: n, host: r }) {
let i = e.length > 1, a = (0, R.useId)(), o = (0, R.useRef)(null), s = (0, R.useRef)(null), c = (0, R.useRef)(null), u = (0, R.useRef)(null), d = (0, R.useRef)(null), f = (0, R.useRef)(null), p = (0, R.useRef)(null), m = (0, R.useRef)(null), h = (0, R.useRef)(null), g = (0, R.useRef)(null), _ = (0, R.useRef)(null), [v, y] = (0, R.useState)(t), [b, x] = (0, R.useState)(100), [S, C] = (0, R.useState)({}), [w, T] = (0, R.useState)(() => /* @__PURE__ */ new Set()), [E, D] = (0, R.useState)(!1), [O, k] = (0, R.useState)({
at: t,
text: ""
@@ -36195,7 +36195,7 @@ function nue({ slides: e, index: t, Swiper: n, host: r }) {
y(this.activeIndex), i(this.activeIndex);
} }
});
- i(t, 0), g.current = Zle(e, a, x);
+ i(t, 0), g.current = TA(e, a, x);
let l = se(e, p.current, m.current), h = (e = !1) => {
l.hide(), p.current?.setAttribute("aria-expanded", "false"), e && p.current && document.contains(p.current) && p.current.focus();
};
@@ -36212,13 +36212,13 @@ function nue({ slides: e, index: t, Swiper: n, host: r }) {
});
v.observe(e);
let b = (e) => {
- e.key === "Escape" && (e.preventDefault(), e.stopImmediatePropagation(), _.current?.isOpen() ? _.current.dismiss(!0) : oA());
+ e.key === "Escape" && (e.preventDefault(), e.stopImmediatePropagation(), _.current?.isOpen() ? _.current.dismiss(!0) : PA());
};
return document.addEventListener("keydown", b, !0), () => {
document.removeEventListener("keydown", b, !0), h(), v.disconnect(), a.destroy(!0, !0), r.destroy(!0, !0), g.current = null, _.current = null, e.close(), document.body.classList.remove("photolight-open");
};
}, []), (0, R.useLayoutEffect)(() => {
- h.current && Yle(h.current);
+ h.current && xA(h.current);
}, [b]);
let A = e[v], j = A.asset ?? null, M = async (e) => {
if (!j || !r || e.getAttribute("aria-busy") === "true") return;
@@ -36249,18 +36249,18 @@ function nue({ slides: e, index: t, Swiper: n, host: r }) {
"data-photo-lightbox": "",
"data-has-strip": i ? "" : void 0,
onCancel: (e) => {
- e.preventDefault(), oA();
+ e.preventDefault(), PA();
},
onClick: (e) => {
let t = e.target;
- _.current?.dismissOutside(t) || (t === o.current || t.classList.contains("swiper-zoom-container")) && oA();
+ _.current?.dismissOutside(t) || (t === o.current || t.classList.contains("swiper-zoom-container")) && PA();
},
children: [
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-photo-close": "",
"aria-label": "关闭",
- onClick: oA,
+ onClick: PA,
dangerouslySetInnerHTML: { __html: l("x") }
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
@@ -36393,10 +36393,10 @@ function nue({ slides: e, index: t, Swiper: n, host: r }) {
id: `${a}-title`,
"data-middle-truncate": "",
tabIndex: -1,
- children: Qle(A)
+ children: DA(A)
}, v), /* @__PURE__ */ (0, z.jsx)("span", {
"data-photo-detail-meta": "",
- children: $le(A, S[v])
+ children: OA(A, S[v])
})]
}),
/* @__PURE__ */ (0, z.jsx)("button", {
@@ -36435,33 +36435,33 @@ function nue({ slides: e, index: t, Swiper: n, host: r }) {
}
//#endregion
//#region src/react/entity-body/entity-body-page.tsx
-function rue(e) {
- return e.view === "people" && e.roster ? /* @__PURE__ */ (0, z.jsx)(iue, {
+function IA(e) {
+ return e.view === "people" && e.roster ? /* @__PURE__ */ (0, z.jsx)(LA, {
roster: e.roster,
props: e
- }) : e.view === "videos" ? /* @__PURE__ */ (0, z.jsx)(aue, { ...e }, e.revision) : e.view === "photos" && e.photos ? /* @__PURE__ */ (0, z.jsx)(cue, {
+ }) : e.view === "videos" ? /* @__PURE__ */ (0, z.jsx)(RA, { ...e }, e.revision) : e.view === "photos" && e.photos ? /* @__PURE__ */ (0, z.jsx)(WA, {
photos: e.photos,
props: e
}, e.photos.revision) : null;
}
-function iue({ roster: e, props: t }) {
+function LA({ roster: e, props: t }) {
let { helpers: n, actions: r } = t, i = (0, R.useMemo)(() => ({
personAvatar: n.personAvatar,
openEntity: r.openEntity
}), [n, r]);
- return /* @__PURE__ */ (0, z.jsx)($k, {
+ return /* @__PURE__ */ (0, z.jsx)(yA, {
kind: e.kind,
items: e.people,
layout: e.layout,
props: i
});
}
-function aue(e) {
- let t = _b(!e.items, e.skeletonHtml);
+function RA(e) {
+ let t = ob(!e.items, e.skeletonHtml);
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-entity-grid": "",
"data-grid-reveal": t.fading ? "" : void 0,
- children: [t.layer, e.items ? /* @__PURE__ */ (0, z.jsx)(Nb, {
+ children: [t.layer, e.items ? /* @__PURE__ */ (0, z.jsx)(Rb, {
mode: "entity",
entityKey: `${e.kind}:${e.name}`,
revision: e.revision,
@@ -36481,16 +36481,16 @@ function aue(e) {
}) : null]
});
}
-var oue = (e) => Array.from({ length: e.n }, (t, n) => ({
+var zA = (e) => Array.from({ length: e.n }, (t, n) => ({
sample: !0,
code: e.code,
position: n + 1,
total: e.n,
name: `${e.code} 样张 ${n + 1}`,
source: e.site_label || "官方样张"
-})), sA = (e) => e.sample === !0, cA = (e) => `code=${encodeURIComponent(e.code)}&n=${e.position}`, lA = (e) => sA(e) ? `/sample-thumb?${cA(e)}` : `/photo-thumb?id=${e.id}`, sue = (e) => sA(e) ? {
- src: `/sample-image?${cA(e)}`,
- thumb: lA(e),
+})), BA = (e) => e.sample === !0, VA = (e) => `code=${encodeURIComponent(e.code)}&n=${e.position}`, HA = (e) => BA(e) ? `/sample-thumb?${VA(e)}` : `/photo-thumb?id=${e.id}`, UA = (e) => BA(e) ? {
+ src: `/sample-image?${VA(e)}`,
+ thumb: HA(e),
name: e.name,
asset: null,
source: e.source,
@@ -36498,18 +36498,18 @@ var oue = (e) => Array.from({ length: e.n }, (t, n) => ({
total: e.total
} : {
src: `/photo?id=${e.id}`,
- thumb: lA(e),
+ thumb: HA(e),
name: e.name || "",
asset: e
};
-function cue({ photos: e, props: t }) {
- let { photoSize: n, photoLayout: r, actions: i, canLoadMore: a } = t, o = (0, R.useMemo)(() => [...e.codeSets.flatMap(oue), ...e.items], [e]), [s, c] = (0, R.useState)(() => /* @__PURE__ */ new Set()), l = (0, R.useCallback)((e) => c((t) => {
+function WA({ photos: e, props: t }) {
+ let { photoSize: n, photoLayout: r, actions: i, canLoadMore: a } = t, o = (0, R.useMemo)(() => [...e.codeSets.flatMap(zA), ...e.items], [e]), [s, c] = (0, R.useState)(() => /* @__PURE__ */ new Set()), l = (0, R.useCallback)((e) => c((t) => {
if (t.has(e)) return t;
let n = new Set(t);
return n.add(e), n;
}), []), u = (0, R.useCallback)((e) => {
- aA(e, o.map(sue), { revealSource: i.revealSource });
- }, [i, o]), d = (e, t) => /* @__PURE__ */ (0, z.jsx)(lue, {
+ NA(e, o.map(UA), { revealSource: i.revealSource });
+ }, [i, o]), d = (e, t) => /* @__PURE__ */ (0, z.jsx)(KA, {
item: e,
index: t,
lost: s.has(t),
@@ -36527,7 +36527,7 @@ function cue({ photos: e, props: t }) {
};
}), h = p;
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
- m.map(({ set: e, from: t }) => /* @__PURE__ */ (0, z.jsxs)(R.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(uA, {
+ m.map(({ set: e, from: t }) => /* @__PURE__ */ (0, z.jsxs)(R.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(GA, {
label: e.code,
title: e.name,
meta: [
@@ -36539,7 +36539,7 @@ function cue({ photos: e, props: t }) {
...f,
children: o.slice(t, t + e.n).map((e, n) => d(e, t + n))
})] }, e.code)),
- m.length && e.total ? /* @__PURE__ */ (0, z.jsx)(uA, {
+ m.length && e.total ? /* @__PURE__ */ (0, z.jsx)(GA, {
label: "本地图片",
meta: `${e.total.toLocaleString()} 张`
}) : null,
@@ -36548,14 +36548,14 @@ function cue({ photos: e, props: t }) {
"data-local-wall": "",
children: e.items.map((e, t) => s.has(h + t) ? null : d(e, h + t))
}),
- e.hasMore ? /* @__PURE__ */ (0, z.jsx)(Pb, {
+ e.hasMore ? /* @__PURE__ */ (0, z.jsx)(zb, {
entity: !0,
load: i.loadMorePhotos,
enabled: () => a?.() !== !1
}, e.items.length) : null
] });
}
-function uA({ label: e, title: t, meta: n }) {
+function GA({ label: e, title: t, meta: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-photo-group": "",
children: [
@@ -36572,7 +36572,7 @@ function uA({ label: e, title: t, meta: n }) {
]
});
}
-function lue({ item: e, index: t, lost: n, onLose: r, onOpen: i }) {
+function KA({ item: e, index: t, lost: n, onLose: r, onOpen: i }) {
let a = e.name ?? "";
return /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -36581,7 +36581,7 @@ function lue({ item: e, index: t, lost: n, onLose: r, onOpen: i }) {
title: a,
onClick: () => i(t),
children: n ? null : /* @__PURE__ */ (0, z.jsx)("img", {
- src: lA(e),
+ src: HA(e),
alt: a,
loading: "lazy",
decoding: "async",
@@ -36590,7 +36590,7 @@ function lue({ item: e, index: t, lost: n, onLose: r, onOpen: i }) {
})
});
}
-function dA(e) {
+function qA(e) {
return {
x0: 0,
y0: 0,
@@ -36598,7 +36598,7 @@ function dA(e) {
y1: e.height
};
}
-function fA(e) {
+function JA(e) {
return {
x0: Math.round(e.x0),
y0: Math.round(e.y0),
@@ -36606,40 +36606,40 @@ function fA(e) {
y1: Math.round(e.y1)
};
}
-function pA(e) {
+function YA(e) {
return !!e && Number.isFinite(e.width) && Number.isFinite(e.height) && e.width > 0 && e.height > 0;
}
-function mA(e, t) {
- if (!pA(e)) return {
+function XA(e, t) {
+ if (!YA(e)) return {
x0: 0,
y0: 0,
x1: 0,
y1: 0
};
- if (t == null || !(t > 0)) return dA(e);
+ if (t == null || !(t > 0)) return qA(e);
let n = e.width, r = n / t;
r > e.height && (r = e.height, n = r * t);
let i = (e.width - n) / 2, a = (e.height - r) / 2;
- return fA({
+ return JA({
x0: i,
y0: a,
x1: i + n,
y1: a + r
});
}
-function hA(e, t) {
- if (!pA(e) || !(t > 0)) return dA(e);
+function Ole(e, t) {
+ if (!YA(e) || !(t > 0)) return qA(e);
let n = Math.min(e.width, e.height * t);
- return fA({
+ return JA({
x0: e.width - n,
y0: 0,
x1: e.width,
y1: e.height
});
}
-function gA(e, t, n) {
- if (!pA(t) || !(n > 0)) return dA(t);
- let r = _A(e, t), i = mA({
+function kle(e, t, n) {
+ if (!YA(t) || !(n > 0)) return qA(t);
+ let r = ZA(e, t), i = XA({
width: r.x1 - r.x0,
height: r.y1 - r.y0
}, n);
@@ -36650,8 +36650,8 @@ function gA(e, t, n) {
y1: r.y0 + i.y1
};
}
-function _A(e, t, n = null, r = "width") {
- if (!pA(t)) return {
+function ZA(e, t, n = null, r = "width") {
+ if (!YA(t)) return {
x0: 0,
y0: 0,
x1: 0,
@@ -36660,43 +36660,43 @@ function _A(e, t, n = null, r = "width") {
let i = Math.min(16, t.width, t.height), a = Math.max(i, Math.min(e.x1 - e.x0, t.width)), o = Math.max(i, Math.min(e.y1 - e.y0, t.height));
n != null && n > 0 && (r === "width" ? (o = a / n, o > t.height && (o = t.height, a = o * n)) : (a = o * n, a > t.width && (a = t.width, o = a / n)), a > t.width && (a = t.width, o = a / n));
let s = Math.max(0, Math.min(e.x0, t.width - a)), c = Math.max(0, Math.min(e.y0, t.height - o));
- return fA({
+ return JA({
x0: s,
y0: c,
x1: s + a,
y1: c + o
});
}
-function vA(e, t, n, r) {
+function QA(e, t, n, r) {
let i = e.x1 - e.x0, a = e.y1 - e.y0, o = Math.max(0, Math.min(e.x0 + t, r.width - i)), s = Math.max(0, Math.min(e.y0 + n, r.height - a));
- return fA({
+ return JA({
x0: o,
y0: s,
x1: o + i,
y1: s + a
});
}
-function yA(e, t, n, r = null) {
- if (!pA(n) || !(t > 0)) return e;
+function $A(e, t, n, r = null) {
+ if (!YA(n) || !(t > 0)) return e;
let i = (e.x0 + e.x1) / 2, a = (e.y0 + e.y1) / 2, o = (e.x1 - e.x0) * t, s = (e.y1 - e.y0) * t;
- return _A({
+ return ZA({
x0: i - o / 2,
y0: a - s / 2,
x1: i + o / 2,
y1: a + s / 2
}, n, r);
}
-function bA(e, t, n, r, i = null) {
+function Ale(e, t, n, r, i = null) {
let a = {
x0: e.x0,
y0: e.y0,
x1: Math.max(e.x0 + 1, t),
y1: Math.max(e.y0 + 1, n)
};
- return _A(a, r, i, (a.x1 - a.x0) / Math.max(1, a.y1 - a.y0) > (i ?? 1) ? "height" : "width");
+ return ZA(a, r, i, (a.x1 - a.x0) / Math.max(1, a.y1 - a.y0) > (i ?? 1) ? "height" : "width");
}
-function xA(e, t) {
- return pA(t) ? {
+function jle(e, t) {
+ return YA(t) ? {
left: e.x0 / t.width * 100,
top: e.y0 / t.height * 100,
width: (e.x1 - e.x0) / t.width * 100,
@@ -36708,8 +36708,8 @@ function xA(e, t) {
height: 0
};
}
-function SA(e, t) {
- if (!pA(t)) return {
+function Mle(e, t) {
+ if (!YA(t)) return {
size: "cover",
position: "50% 50%"
};
@@ -36719,7 +36719,7 @@ function SA(e, t) {
position: `${i(e.x0, t.width, n)}% ${i(e.y0, t.height, r)}%`
};
}
-function CA(e, t) {
+function Nle(e, t) {
let n = Math.max(1, e.x1 - e.x0), r = Math.max(1, e.y1 - e.y0);
return {
left: `${-e.x0 / n * 100}%`,
@@ -36728,29 +36728,29 @@ function CA(e, t) {
height: `${t.height / r * 100}%`
};
}
-function wA(e, t, n) {
+function ej(e, t, n) {
return t > 0 ? e * n / t : 0;
}
//#endregion
//#region src/react/components/modal-frame.tsx
-var TA = {
+var Ple = {
"avatar-picker": "max-w-avatar-picker",
"cover-crop": "max-w-cover-crop",
form: "max-w-form-modal"
};
-function EA({ isOpen: e, onOpenChange: t, width: n, label: r, children: i }) {
+function tj({ isOpen: e, onOpenChange: t, width: n, label: r, children: i }) {
let { isFocusVisible: a } = xs();
- return /* @__PURE__ */ (0, z.jsx)(S_, {
+ return /* @__PURE__ */ (0, z.jsx)(C_, {
isOpen: e,
onOpenChange: t,
isDismissable: !0,
"data-modal-motion": "",
"data-motion-instant": a || void 0,
className: "fixed inset-0 z-dialog flex items-center justify-center bg-scrim p-4",
- children: /* @__PURE__ */ (0, z.jsx)(Eee, {
+ children: /* @__PURE__ */ (0, z.jsx)(Tee, {
"data-modal-surface": "",
- className: `flex max-h-full w-full ${TA[n]} flex-col overflow-hidden rounded-2-5xl border border-separator-border bg-background-full shadow-dropdown`,
- children: /* @__PURE__ */ (0, z.jsx)(Fg, {
+ className: `flex max-h-full w-full ${Ple[n]} flex-col overflow-hidden rounded-2-5xl border border-separator-border bg-background-full shadow-dropdown`,
+ children: /* @__PURE__ */ (0, z.jsx)(Ig, {
"aria-label": r,
className: "flex min-h-0 flex-col outline-none",
children: i
@@ -36758,7 +36758,7 @@ function EA({ isOpen: e, onOpenChange: t, width: n, label: r, children: i }) {
})
});
}
-function DA({ children: e }) {
+function nj({ children: e }) {
return /* @__PURE__ */ (0, z.jsx)("span", {
"aria-hidden": !0,
className: "flex size-14 shrink-0 items-center justify-center rounded-2xl border border-separator-border bg-background-secondary-default text-foreground-icon-secondary",
@@ -36767,8 +36767,8 @@ function DA({ children: e }) {
}
//#endregion
//#region src/react/crop/crop-frame.tsx
-var OA = .02, kA = 1.08;
-function AA({ src: e, aspect: t, box: n, size: r, onBox: i, onSize: a, label: o }) {
+var Fle = .02, rj = 1.08;
+function ij({ src: e, aspect: t, box: n, size: r, onBox: i, onSize: a, label: o }) {
let s = (0, R.useRef)(null), c = (0, R.useRef)(null), [l, u] = (0, R.useState)(!1);
(0, R.useEffect)(() => {
u(!1);
@@ -36779,8 +36779,8 @@ function AA({ src: e, aspect: t, box: n, size: r, onBox: i, onSize: a, label: o
dx: 0,
dy: 0
} : {
- dx: wA(e, n.clientWidth, r.width),
- dy: wA(t, n.clientHeight, r.height)
+ dx: ej(e, n.clientWidth, r.width),
+ dy: ej(t, n.clientHeight, r.height)
};
}, [r]);
function f(e) {
@@ -36798,29 +36798,29 @@ function AA({ src: e, aspect: t, box: n, size: r, onBox: i, onSize: a, label: o
if (!n || !a || !r) return;
let o = d(e.clientX - n.x, e.clientY - n.y);
if (n.mode === "move") {
- i(vA(n.box, o.dx, o.dy, r));
+ i(QA(n.box, o.dx, o.dy, r));
return;
}
- i(bA(n.box, n.box.x0 + (n.box.x1 - n.box.x0) + o.dx, n.box.y0 + (n.box.y1 - n.box.y0) + o.dy, r, t));
+ i(Ale(n.box, n.box.x0 + (n.box.x1 - n.box.x0) + o.dx, n.box.y0 + (n.box.y1 - n.box.y0) + o.dy, r, t));
}
function m(e) {
c.current && (c.current = null, e.currentTarget.hasPointerCapture(e.pointerId) && e.currentTarget.releasePointerCapture(e.pointerId));
}
function h(e) {
if (!n || !r) return;
- let a = Math.max(1, (n.x1 - n.x0) * OA), o = {
+ let a = Math.max(1, (n.x1 - n.x0) * Fle), o = {
ArrowLeft: [-a, 0],
ArrowRight: [a, 0],
ArrowUp: [0, -a],
ArrowDown: [0, a]
};
if (o[e.key]) {
- e.preventDefault(), i(vA(n, o[e.key][0], o[e.key][1], r));
+ e.preventDefault(), i(QA(n, o[e.key][0], o[e.key][1], r));
return;
}
- (e.key === "+" || e.key === "=" || e.key === "-") && (e.preventDefault(), i(yA(n, e.key === "-" ? 1 / kA : kA, r, t)));
+ (e.key === "+" || e.key === "=" || e.key === "-") && (e.preventDefault(), i($A(n, e.key === "-" ? 1 / rj : rj, r, t)));
}
- let g = n && r ? xA(_A(n, r, t), r) : null, _ = g ? {
+ let g = n && r ? jle(ZA(n, r, t), r) : null, _ = g ? {
"--crop-l": `${g.left}%`,
"--crop-t": `${g.top}%`,
"--crop-w": `${g.width}%`,
@@ -36839,7 +36839,7 @@ function AA({ src: e, aspect: t, box: n, size: r, onBox: i, onSize: a, label: o
draggable: !1,
onLoad: (e) => {
let t = e.currentTarget;
- pA({
+ YA({
width: t.naturalWidth,
height: t.naturalHeight
}) && a({
@@ -36878,7 +36878,7 @@ function AA({ src: e, aspect: t, box: n, size: r, onBox: i, onSize: a, label: o
onPointerCancel: m,
onKeyDown: h,
onWheel: (e) => {
- !n || !r || i(yA(n, e.deltaY > 0 ? kA : 1 / kA, r, t));
+ !n || !r || i($A(n, e.deltaY > 0 ? rj : 1 / rj, r, t));
},
className: "absolute left-(--crop-l) top-(--crop-t) h-(--crop-h) w-(--crop-w) cursor-move touch-none outline-none ring-2 ring-border-focus-ring ring-inset focus-visible:ring-4",
children: /* @__PURE__ */ (0, z.jsx)("span", {
@@ -36900,29 +36900,29 @@ function AA({ src: e, aspect: t, box: n, size: r, onBox: i, onSize: a, label: o
}
//#endregion
//#region src/react/avatar-picker/avatar-picker.ts
-var jA = "/api/avatar-choices", MA = "/api/avatar-pick", uue = "/api/avatar-code-cover", due = "/avatar-choice", NA = (e, t) => [
+var Ile = "/api/avatar-choices", aj = "/api/avatar-pick", Lle = "/api/avatar-code-cover", Rle = "/avatar-choice", oj = (e, t) => [
"avatar-choices",
e,
t
-], PA = (e, t) => `?kind=${encodeURIComponent(e)}&id=${t}`, FA = (e, t, n) => `${due}${PA(e, t)}&ref=${encodeURIComponent(n)}`, fue = (e, t, n) => W(jA + PA(e, t), n), pue = (e) => G(uue, { code: e });
-function IA(e, t, n) {
+], sj = (e, t) => `?kind=${encodeURIComponent(e)}&id=${t}`, cj = (e, t, n) => `${Rle}${sj(e, t)}&ref=${encodeURIComponent(n)}`, zle = (e, t, n) => W(Ile + sj(e, t), n), Ble = (e) => G(Lle, { code: e });
+function lj(e, t, n) {
let r = t.width === e.width && t.height === e.height;
- return e.focus && r ? gA(e.focus, t, n) : mA(t, n);
+ return e.focus && r ? kle(e.focus, t, n) : XA(t, n);
}
-var mue = (e) => e.crop && pA({
+var Vle = (e) => e.crop && YA({
width: e.width,
height: e.height
});
-async function hue(e, t, n) {
+async function Hle(e, t, n) {
if (!("file" in n)) {
- await G(MA, {
+ await G(aj, {
kind: e,
id: t,
...n
});
return;
}
- let r = n.file, i = await fetch(`${MA}${PA(e, t)}&name=${encodeURIComponent(r.name)}`, {
+ let r = n.file, i = await fetch(`${aj}${sj(e, t)}&name=${encodeURIComponent(r.name)}`, {
method: "POST",
credentials: "same-origin",
body: r
@@ -36931,30 +36931,30 @@ async function hue(e, t, n) {
let a = await i.json().catch(() => null);
throw new Hi(a?.error || `请求失败(${i.status})`, i.status, a);
}
-function gue(e, t) {
+function Ule(e, t) {
if (!t) return e;
let n = t.matched_names.filter((t) => t !== e);
return n.length ? `${e}:图库里按「${n.join("」「")}」找到的。` : t.choices.length ? `${e}:换上的那张留在本机,随时能换回来。` : `${e}:图库里没有这个名字,用下面两种方式换。`;
}
-var _ue = (e) => e < 48 ? `${Math.max(1, Math.round(e))} 小时` : `${Math.floor(e / 24)} 天`;
-function vue(e) {
- return !e || !e.index_stale || e.choices.some((e) => e.source === "gfriends") ? "" : e.index_age_hours === null ? "图库索引还没取过,只能从用过的图里选。" : `图库索引 ${_ue(e.index_age_hours)}没更新,新收的人像这里还查不到。`;
+var Wle = (e) => e < 48 ? `${Math.max(1, Math.round(e))} 小时` : `${Math.floor(e / 24)} 天`;
+function Gle(e) {
+ return !e || !e.index_stale || e.choices.some((e) => e.source === "gfriends") ? "" : e.index_age_hours === null ? "图库索引还没取过,只能从用过的图里选。" : `图库索引 ${Wle(e.index_age_hours)}没更新,新收的人像这里还查不到。`;
}
-var LA = (e) => e.cast > 1, yue = (e) => LA(e) ? `${e.label}:${e.cast} 人合演,先找到她自己的脸,再拖动方框选一块。` : `${e.label}:拖动方框选一块,滚轮或角上那枚方块改大小。`, bue = {
+var uj = (e) => e.cast > 1, Kle = (e) => uj(e) ? `${e.label}:${e.cast} 人合演,先找到她自己的脸,再拖动方框选一块。` : `${e.label}:拖动方框选一块,滚轮或角上那枚方块改大小。`, qle = {
gfriends: "图库",
history: "用过的",
asset: "作品画面",
code: "番号封面"
};
-function xue(e) {
+function Jle(e) {
if (e.startsWith("cover:")) return "封面";
let t = e.split(":")[2] || "";
if (t === "cover") return "封面";
let n = Number(t.replace("cell", ""));
return Number.isFinite(n) ? `第 ${n + 1} 格` : t;
}
-var Sue = (e) => `${bue[e.source] || e.source} · ${e.label}` + (e.width ? ` · ${e.width}×${e.height}` : "") + (LA(e) ? ` · ${e.cast} 人合演` : "") + (e.found_by ? ` · 按「${e.found_by}」找到` : ""), Cue = 8, wue = 3 / 4;
-function Tue({ kind: e, entityId: t, name: n, onPicked: r }) {
+var Yle = (e) => `${qle[e.source] || e.source} · ${e.label}` + (e.width ? ` · ${e.width}×${e.height}` : "") + (uj(e) ? ` · ${e.cast} 人合演` : "") + (e.found_by ? ` · 按「${e.found_by}」找到` : ""), Xle = 8, Zle = 3 / 4;
+function Qle({ kind: e, entityId: t, name: n, onPicked: r }) {
let [i, a] = (0, R.useState)(!1);
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("span", {
className: "absolute right-1 bottom-1 z-10",
@@ -36969,12 +36969,12 @@ function Tue({ kind: e, entityId: t, name: n, onPicked: r }) {
className: "size-4"
})
})
- }), /* @__PURE__ */ (0, z.jsx)(EA, {
+ }), /* @__PURE__ */ (0, z.jsx)(tj, {
isOpen: i,
onOpenChange: a,
width: "avatar-picker",
label: "更换头像",
- children: /* @__PURE__ */ (0, z.jsx)(Eue, {
+ children: /* @__PURE__ */ (0, z.jsx)($le, {
kind: e,
entityId: t,
name: n,
@@ -36983,33 +36983,33 @@ function Tue({ kind: e, entityId: t, name: n, onPicked: r }) {
})
})] });
}
-function Eue({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
- let a = (0, R.useRef)(null), o = uO(), [s, c] = (0, R.useState)(""), [l, u] = (0, R.useState)(""), [d, f] = (0, R.useState)(""), [p, m] = (0, R.useState)(null), h = NA(e, t), g = (0, R.useRef)(!1), _ = $n({
+function $le({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
+ let a = (0, R.useRef)(null), o = aO(), [s, c] = (0, R.useState)(""), [l, u] = (0, R.useState)(""), [d, f] = (0, R.useState)(""), [p, m] = (0, R.useState)(null), h = oj(e, t), g = (0, R.useRef)(!1), _ = $n({
queryKey: h,
- queryFn: ({ signal: n }) => fue(e, t, n),
+ queryFn: ({ signal: n }) => zle(e, t, n),
retryOnMount: !0
});
(0, R.useEffect)(() => () => {
- g.current && X.removeQueries({ queryKey: NA(e, t) });
+ g.current && X.removeQueries({ queryKey: oj(e, t) });
}, [e, t]);
let v = er({
- mutationFn: (n) => hue(e, t, n),
+ mutationFn: (n) => Hle(e, t, n),
onSuccess: () => {
g.current = !0, i(), r();
}
}), y = er({
- mutationFn: (e) => pue(e),
+ mutationFn: (e) => Ble(e),
onSuccess: (e) => m(e)
});
function b(e) {
let t = e.currentTarget, n = t.files?.[0];
t.value = "", f(""), n && v.mutate({ file: n });
}
- let x = _.data, S = x?.choices ?? [], C = d || (v.error ? U(v.error) : "") || (!p && y.error ? U(y.error) : "") || (_.error ? U(_.error) : ""), w = v.isPending || y.isPending, T = p ? "" : vue(x);
+ let x = _.data, S = x?.choices ?? [], C = d || (v.error ? U(v.error) : "") || (!p && y.error ? U(y.error) : "") || (_.error ? U(_.error) : ""), w = v.isPending || y.isPending, T = p ? "" : Gle(x);
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex shrink-0 items-start gap-4 p-5",
children: [
- /* @__PURE__ */ (0, z.jsx)(DA, { children: /* @__PURE__ */ (0, z.jsx)(St, { className: "size-6" }) }),
+ /* @__PURE__ */ (0, z.jsx)(nj, { children: /* @__PURE__ */ (0, z.jsx)(St, { className: "size-6" }) }),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-w-0 flex-1 flex-col gap-2",
children: [
@@ -37026,7 +37026,7 @@ function Eue({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
}),
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
- children: p ? yue(p) : gue(n, x)
+ children: p ? Kle(p) : Ule(n, x)
}),
T ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "neutral",
@@ -37038,14 +37038,14 @@ function Eue({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
}) : null
]
}),
- /* @__PURE__ */ (0, z.jsx)(fO, {
+ /* @__PURE__ */ (0, z.jsx)(sO, {
icon: Xe,
size: "small",
"aria-label": "关闭",
onClick: i
})
]
- }), p ? /* @__PURE__ */ (0, z.jsx)(Oue, {
+ }), p ? /* @__PURE__ */ (0, z.jsx)(tue, {
kind: e,
entityId: t,
choice: p,
@@ -37068,7 +37068,7 @@ function Eue({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
"aria-busy": _.isPending || void 0,
"data-skeleton": _.isPending ? "avatar-choices" : void 0,
className: "inline-grid grid-cols-3 content-start gap-2 sm:grid-cols-4",
- children: _.isPending ? Array.from({ length: Cue }, (e, t) => /* @__PURE__ */ (0, z.jsxs)("span", {
+ children: _.isPending ? Array.from({ length: Xle }, (e, t) => /* @__PURE__ */ (0, z.jsxs)("span", {
"aria-hidden": !0,
"data-avatar-skeleton": !0,
className: "flex flex-col gap-1 overflow-hidden rounded-2lg border border-separator-border bg-background-secondary-default pb-1 text-caption-1-regular",
@@ -37081,15 +37081,15 @@ function Eue({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
role: "option",
"data-avatar-choice": !0,
"aria-selected": n.current,
- title: Sue(n),
+ title: Yle(n),
...q(w),
onClick: () => {
w || (n.crop ? m(n) : v.mutate({ ref: n.ref }));
},
className: "relative flex cursor-pointer flex-col gap-1 overflow-hidden rounded-2lg border border-separator-border bg-background-secondary-default pb-1 text-center text-caption-1-regular text-text-secondary outline-none hover:border-border-button-hover hover:text-text-primary focus-visible:ring-2 focus-visible:ring-border-focus-ring aria-selected:border-border-focus-ring aria-selected:bg-background-tertiary-default aria-selected:text-text-primary aria-disabled:cursor-progress aria-disabled:opacity-60",
children: [
- /* @__PURE__ */ (0, z.jsx)(Due, {
- src: FA(e, t, n.ref),
+ /* @__PURE__ */ (0, z.jsx)(eue, {
+ src: cj(e, t, n.ref),
choice: n
}),
/* @__PURE__ */ (0, z.jsx)("span", {
@@ -37104,7 +37104,7 @@ function Eue({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
children: "在用"
})
}) : null,
- LA(n) ? /* @__PURE__ */ (0, z.jsx)("span", {
+ uj(n) ? /* @__PURE__ */ (0, z.jsx)("span", {
className: "absolute top-1 right-1",
children: /* @__PURE__ */ (0, z.jsxs)(zi, {
variant: "caption",
@@ -37125,7 +37125,7 @@ function Eue({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
},
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "min-w-0 flex-1",
- children: /* @__PURE__ */ (0, z.jsx)(cy, {
+ children: /* @__PURE__ */ (0, z.jsx)(py, {
"aria-label": "番号",
placeholder: "番号,如 ABW-232",
value: l,
@@ -37160,7 +37160,7 @@ function Eue({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
className: "flex min-w-0 flex-1 items-center gap-2",
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "min-w-0 flex-1",
- children: /* @__PURE__ */ (0, z.jsx)(cy, {
+ children: /* @__PURE__ */ (0, z.jsx)(py, {
type: "url",
"aria-label": "图片地址",
placeholder: "https://…",
@@ -37180,7 +37180,7 @@ function Eue({ kind: e, entityId: t, name: n, onPicked: r, close: i }) {
})]
})] })] });
}
-function Due({ src: e, choice: t }) {
+function eue({ src: e, choice: t }) {
let n = (0, R.useRef)(null), [r, i] = (0, R.useState)(!1);
(0, R.useEffect)(() => {
n.current?.complete && n.current.naturalWidth && i(!0);
@@ -37188,7 +37188,7 @@ function Due({ src: e, choice: t }) {
let a = {
width: t.width,
height: t.height
- }, o = mue(t) ? CA(IA(t, a, wue), a) : null, s = r ? !0 : void 0;
+ }, o = Vle(t) ? Nle(lj(t, a, Zle), a) : null, s = r ? !0 : void 0;
return /* @__PURE__ */ (0, z.jsxs)("span", {
className: "relative block w-full aspect-avatar-choice overflow-hidden",
children: [/* @__PURE__ */ (0, z.jsx)("img", {
@@ -37213,23 +37213,23 @@ function Due({ src: e, choice: t }) {
})]
});
}
-function Oue({ kind: e, entityId: t, choice: n, busy: r, back: i, confirm: a }) {
- let o = n.bases.length ? n.bases : [n.ref], [s, c] = (0, R.useState)(o[0]), [l, u] = (0, R.useState)(null), [d, f] = (0, R.useState)(null), p = FA(e, t, s), m = uO();
+function tue({ kind: e, entityId: t, choice: n, busy: r, back: i, confirm: a }) {
+ let o = n.bases.length ? n.bases : [n.ref], [s, c] = (0, R.useState)(o[0]), [l, u] = (0, R.useState)(null), [d, f] = (0, R.useState)(null), p = cj(e, t, s), m = aO();
function h(e) {
c(e), u(null), f(null);
}
- let g = d && l ? SA(d, l) : null;
+ let g = d && l ? Mle(d, l) : null;
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsxs)("div", {
ref: m,
className: "flex min-h-0 flex-1 flex-col items-center gap-4 overflow-y-auto border-t border-separator-border px-5 py-4",
- children: [/* @__PURE__ */ (0, z.jsx)(AA, {
+ children: [/* @__PURE__ */ (0, z.jsx)(ij, {
src: p,
aspect: 1,
box: d,
size: l,
label: `${n.label} 的头像取景框`,
onSize: (e) => {
- u(e), pA(e) && f(s === n.ref ? IA(n, e, 1) : mA(e, 1));
+ u(e), YA(e) && f(s === n.ref ? lj(n, e, 1) : XA(e, 1));
},
onBox: f
}), o.length > 1 ? /* @__PURE__ */ (0, z.jsx)("div", {
@@ -37243,7 +37243,7 @@ function Oue({ kind: e, entityId: t, choice: n, busy: r, back: i, confirm: a })
"data-crop-base": !0,
onClick: () => h(e),
className: "cursor-pointer rounded-lg px-2 py-1 text-caption-1-regular text-text-secondary outline-none hover:text-text-primary focus-visible:ring-2 focus-visible:ring-border-focus-ring aria-checked:bg-background-tertiary-default aria-checked:text-text-primary",
- children: xue(e)
+ children: Jle(e)
}, e))
}) : null]
}), /* @__PURE__ */ (0, z.jsxs)("div", {
@@ -37277,7 +37277,7 @@ function Oue({ kind: e, entityId: t, choice: n, busy: r, back: i, confirm: a })
}
//#endregion
//#region src/react/feed-new/feed-new-row.tsx
-function RA({ feedNew: e, host: t, wire: n, act: r, settled: i }) {
+function dj({ feedNew: e, host: t, wire: n, act: r, settled: i }) {
let a = (0, R.useRef)(null), o = e?.items.length ? e.html : "";
(0, R.useLayoutEffect)(() => {
t.removeAttribute("aria-busy"), t.hidden = !o, e && i?.(!!o);
@@ -37311,12 +37311,12 @@ function RA({ feedNew: e, host: t, wire: n, act: r, settled: i }) {
}
//#endregion
//#region src/react/entity-hero/glyph.tsx
-var kue = {
+var nue = {
"text-aa": 1.435,
"mark-javdb": 326 / 111
};
-function zA({ name: e }) {
- let t = kue[e];
+function fj({ name: e }) {
+ let t = nue[e];
return /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: t ? `0 0 ${(24 * t).toFixed(2)} 24` : "0 0 24 24",
"aria-hidden": "true",
@@ -37326,19 +37326,19 @@ function zA({ name: e }) {
}
//#endregion
//#region src/react/entity-hero/hero-pop.tsx
-function BA(e, t) {
+function pj(e, t) {
let n = e.getBoundingClientRect(), r = t.getBoundingClientRect();
t.style.left = `${Math.max(8, Math.min(innerWidth - r.width - 8, n.left))}px`;
let i = n.bottom + 8;
t.style.top = `${i + r.height <= innerHeight - 8 ? i : Math.max(8, n.top - r.height - 8)}px`;
}
-var VA = (e) => !!e?.isConnected && e.matches(":popover-open");
-function HA(e, t, n, r) {
+var mj = (e) => !!e?.isConnected && e.matches(":popover-open");
+function hj(e, t, n, r) {
let i = (0, R.useRef)(r);
i.current = r, (0, R.useEffect)(() => {
if (!e) return;
let r = () => {
- t.current && VA(n.current) ? BA(t.current, n.current) : i.current();
+ t.current && mj(n.current) ? pj(t.current, n.current) : i.current();
};
return addEventListener("scroll", r, {
capture: !0,
@@ -37352,17 +37352,17 @@ function HA(e, t, n, r) {
n
]);
}
-function UA({ id: e, rest: t, label: n, heading: r, hook: i, children: a }) {
+function gj({ id: e, rest: t, label: n, heading: r, hook: i, children: a }) {
let o = (0, R.useRef)(null), s = (0, R.useRef)(null), [c, l] = (0, R.useState)(!1), u = (0, R.useRef)(!1), d = (0, R.useRef)(0), f = () => {
- clearTimeout(d.current), u.current = !1, VA(s.current) && s.current.hidePopover(), l(!1);
+ clearTimeout(d.current), u.current = !1, mj(s.current) && s.current.hidePopover(), l(!1);
}, p = () => {
- clearTimeout(d.current), !(!s.current || !o.current || VA(s.current)) && (s.current.showPopover(), BA(o.current, s.current), l(!0));
+ clearTimeout(d.current), !(!s.current || !o.current || mj(s.current)) && (s.current.showPopover(), pj(o.current, s.current), l(!0));
}, m = () => {
clearTimeout(d.current), d.current = window.setTimeout(() => {
!u.current && !o.current?.matches(":hover,:focus-visible") && !s.current?.matches(":hover") && f();
}, 150);
};
- return HA(c, o, s, f), (0, R.useEffect)(() => {
+ return hj(c, o, s, f), (0, R.useEffect)(() => {
if (!c) return;
let e = (e) => {
let t = e.target;
@@ -37388,7 +37388,7 @@ function UA({ id: e, rest: t, label: n, heading: r, hook: i, children: a }) {
u.current ? f() : (p(), u.current = !0);
},
onKeyDown: (e) => {
- e.key === "Escape" && VA(s.current) && (e.preventDefault(), f());
+ e.key === "Escape" && mj(s.current) && (e.preventDefault(), f());
},
children: ["+", t]
}), /* @__PURE__ */ (0, z.jsxs)("div", {
@@ -37406,16 +37406,16 @@ function UA({ id: e, rest: t, label: n, heading: r, hook: i, children: a }) {
}), a]
})] });
}
-function Aue({ following: e, busy: t, onToggle: n, tip: r }) {
+function rue({ following: e, busy: t, onToggle: n, tip: r }) {
let i = (0, R.useRef)(null), a = (0, R.useRef)(null), o = (0, R.useRef)(null), [s, c] = (0, R.useState)(!1), l = (0, R.useRef)(!1), u = () => {
- VA(o.current) && o.current.hidePopover(), c(!1);
+ mj(o.current) && o.current.hidePopover(), c(!1);
}, d = () => {
- l.current || !o.current || !i.current || VA(o.current) || (o.current.showPopover(), BA(i.current, o.current), c(!0));
+ l.current || !o.current || !i.current || mj(o.current) || (o.current.showPopover(), pj(i.current, o.current), c(!0));
}, f = () => {
l.current = !1, u();
};
- return HA(s, i, o, () => c(!1)), (0, R.useEffect)(() => {
- i.current && VA(o.current) && BA(i.current, o.current);
+ return hj(s, i, o, () => c(!1)), (0, R.useEffect)(() => {
+ i.current && mj(o.current) && pj(i.current, o.current);
}, [r]), /* @__PURE__ */ (0, z.jsxs)("label", {
ref: i,
"data-entry-feed": "",
@@ -37424,7 +37424,7 @@ function Aue({ following: e, busy: t, onToggle: n, tip: r }) {
a.current?.matches(":focus-visible") || f();
},
children: [
- /* @__PURE__ */ (0, z.jsx)(zA, { name: "rss" }),
+ /* @__PURE__ */ (0, z.jsx)(fj, { name: "rss" }),
/* @__PURE__ */ (0, z.jsx)("input", {
ref: a,
type: "checkbox",
@@ -37459,29 +37459,29 @@ function Aue({ following: e, busy: t, onToggle: n, tip: r }) {
}
//#endregion
//#region src/react/entity-hero/name-picker.tsx
-function jue({ current: e, choices: t, onChoose: n, onAddAlias: r }) {
+function iue({ current: e, choices: t, onChoose: n, onAddAlias: r }) {
let [i, a] = (0, R.useState)(!1), o = (0, R.useRef)(null);
return (0, R.useEffect)(() => {
o.current?.setAttribute("title", "名字与别名");
- }, []), /* @__PURE__ */ (0, z.jsxs)(lee, {
+ }, []), /* @__PURE__ */ (0, z.jsxs)(cee, {
isOpen: i,
onOpenChange: a,
children: [/* @__PURE__ */ (0, z.jsx)(fu, {
ref: o,
"data-namepick-toggle": "",
"aria-label": "名字与别名",
- children: /* @__PURE__ */ (0, z.jsx)(zA, { name: "chevron-down" })
+ children: /* @__PURE__ */ (0, z.jsx)(fj, { name: "chevron-down" })
}), /* @__PURE__ */ (0, z.jsx)(zh, {
placement: "bottom start",
offset: 8,
containerPadding: 8,
- className: ly,
+ className: my,
"data-namepick-menu": "",
- children: /* @__PURE__ */ (0, z.jsxs)(dee, {
+ children: /* @__PURE__ */ (0, z.jsxs)(uee, {
"aria-label": "名字与别名",
"data-namepick-list": "",
children: [
- /* @__PURE__ */ (0, z.jsx)(jg, {
+ /* @__PURE__ */ (0, z.jsx)(Mg, {
selectionMode: "single",
disallowEmptySelection: !0,
selectedKeys: [e],
@@ -37489,31 +37489,31 @@ function jue({ current: e, choices: t, onChoose: n, onAddAlias: r }) {
let r = [...t][0];
r && r !== e && n(r);
},
- children: t.map((e) => /* @__PURE__ */ (0, z.jsxs)(Ng, {
+ children: t.map((e) => /* @__PURE__ */ (0, z.jsxs)(Pg, {
id: e,
textValue: e,
"data-namepick-name": e,
- children: [/* @__PURE__ */ (0, z.jsx)(zA, { name: "check" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e })]
+ children: [/* @__PURE__ */ (0, z.jsx)(fj, { name: "check" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e })]
}, e))
}),
/* @__PURE__ */ (0, z.jsx)(uf, { "data-namepick-rule": "" }),
- /* @__PURE__ */ (0, z.jsx)(jg, { children: /* @__PURE__ */ (0, z.jsxs)(Ng, {
+ /* @__PURE__ */ (0, z.jsx)(Mg, { children: /* @__PURE__ */ (0, z.jsxs)(Pg, {
id: "alias",
textValue: "添加别名",
"data-namepick-alias": "",
onAction: r,
- children: [/* @__PURE__ */ (0, z.jsx)(zA, { name: "plus" }), /* @__PURE__ */ (0, z.jsx)("span", { children: "添加别名…" })]
+ children: [/* @__PURE__ */ (0, z.jsx)(fj, { name: "plus" }), /* @__PURE__ */ (0, z.jsx)("span", { children: "添加别名…" })]
}) })
]
})
})]
});
}
-var Mue = (e) => e === "studio" || e === "agency", Nue = (e) => e === "performer" || e === "creator", Pue = (e) => e ? "已订阅新作:库里还没有的新片排在资料卡下面。再点一下取消订阅。" : "订阅新作:定时去 JavDB 查这位有没有出新片,库里还没有的排在资料卡下面。";
-function Fue(e) {
+var aue = (e) => e === "studio" || e === "agency", oue = (e) => e === "performer" || e === "creator", sue = (e) => e ? "已订阅新作:库里还没有的新片排在资料卡下面。再点一下取消订阅。" : "订阅新作:定时去 JavDB 查这位有没有出新片,库里还没有的排在资料卡下面。";
+function cue(e) {
return [e.canonical_name, ...e.aliases || []].filter((e, t, n) => e && n.indexOf(e) === t);
}
-function WA(e) {
+function _j(e) {
if (e.agency) return {
name: e.agency.canonical_name,
linked: !0
@@ -37524,13 +37524,13 @@ function WA(e) {
linked: !1
} : null;
}
-function GA(e, t) {
+function vj(e, t) {
let n = f(e, "performer"), r = c(t);
return r && [e.label, n].map(c).some((e) => e && (r.includes(e) || e.includes(r))) ? `${t} 官方资料` : n || e.label || "";
}
-var KA = (e) => ({ site: u(e) });
-function Iue(e, t) {
- let r = WA(e)?.name || "", i = (e.entry_links || []).filter((e) => e.slot === "pill").map((e) => ({
+var yj = (e) => ({ site: u(e) });
+function lue(e, t) {
+ let r = _j(e)?.name || "", i = (e.entry_links || []).filter((e) => e.slot === "pill").map((e) => ({
type: "icon",
url: e.url,
title: e.label,
@@ -37540,7 +37540,7 @@ function Iue(e, t) {
let t = e.retired_year ? `已于 ${e.retired_year} 年隐退` : "链接已失效";
return {
type: "gone",
- title: `${GA(e, r)} · ${t}`
+ title: `${vj(e, r)} · ${t}`
};
}
let i = e.url || "";
@@ -37551,8 +37551,8 @@ function Iue(e, t) {
if (t === "performer" && e.link_kind !== "social") return {
type: "icon",
url: i,
- title: GA(e, r),
- mark: KA(e)
+ title: vj(e, r),
+ mark: yj(e)
};
if (e.link_kind === "social") {
let t = n(i);
@@ -37560,7 +37560,7 @@ function Iue(e, t) {
type: "icon",
url: i,
title: e.label || "",
- mark: t ? { brand: t } : KA(e)
+ mark: t ? { brand: t } : yj(e)
};
}
return {
@@ -37568,13 +37568,13 @@ function Iue(e, t) {
url: i,
title: e.label || "",
text: f(e, t, a),
- mark: KA(e)
+ mark: yj(e)
};
});
return [...i, ...o];
}
-var qA = (e) => (e.entry_links || []).filter((e) => e.slot === "mark");
-function Lue(e) {
+var bj = (e) => (e.entry_links || []).filter((e) => e.slot === "mark");
+function uue(e) {
if (!e) return [];
let t = [];
e.birth_date && t.push({
@@ -37631,14 +37631,14 @@ function Lue(e) {
tags: e.tags
}), t;
}
-function Rue(e) {
+function due(e) {
let t = e.length > 5 ? 4 : e.length;
return {
shown: e.slice(0, t),
rest: e.length - t
};
}
-function zue(e) {
+function fue(e) {
if (!e) return null;
let t = e.shown || [], n = [e.reading || "", ...t].filter(Boolean), r = (e.total || 0) - t.length;
return n.length || r > 0 ? {
@@ -37649,8 +37649,8 @@ function zue(e) {
}
//#endregion
//#region src/react/entity-hero/entity-hero-page.tsx
-function Bue({ kind: e, name: t, entity: n, feedNew: r, feedHost: a, actions: o, helpers: s }) {
- let c = Nue(e), l = Mue(e), u = e === "performer" ? Lue(n.profile) : [], d = Iue(n, e), f = qA(n), p = e === "agency" ? [] : n.related_performers || [], m = (0, R.useRef)(null), h = (0, R.useRef)(null);
+function pue({ kind: e, name: t, entity: n, feedNew: r, feedHost: a, actions: o, helpers: s }) {
+ let c = oue(e), l = aue(e), u = e === "performer" ? uue(n.profile) : [], d = lue(n, e), f = bj(n), p = e === "agency" ? [] : n.related_performers || [], m = (0, R.useRef)(null), h = (0, R.useRef)(null);
return (0, R.useEffect)(() => {
s.wireScroller(m.current);
}, [s, d.length]), (0, R.useEffect)(() => {
@@ -37663,7 +37663,7 @@ function Bue({ kind: e, name: t, entity: n, feedNew: r, feedHost: a, actions: o,
children: [
/* @__PURE__ */ (0, z.jsxs)("div", {
"data-entity-portrait-wrap": "",
- children: [/* @__PURE__ */ (0, z.jsx)(Vue, {
+ children: [/* @__PURE__ */ (0, z.jsx)(mue, {
kind: e,
name: t,
helpers: s,
@@ -37671,7 +37671,7 @@ function Bue({ kind: e, name: t, entity: n, feedNew: r, feedHost: a, actions: o,
company: l
}), c && n.id ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-avatar-picker": "",
- children: /* @__PURE__ */ (0, z.jsx)(Tue, {
+ children: /* @__PURE__ */ (0, z.jsx)(Qle, {
kind: e,
entityId: Number(n.id),
name: n.canonical_name || t,
@@ -37684,14 +37684,14 @@ function Bue({ kind: e, name: t, entity: n, feedNew: r, feedHost: a, actions: o,
children: [
/* @__PURE__ */ (0, z.jsxs)("div", {
"data-entity-title": "",
- children: [/* @__PURE__ */ (0, z.jsx)("h2", { children: n.canonical_name }), /* @__PURE__ */ (0, z.jsx)(jue, {
+ children: [/* @__PURE__ */ (0, z.jsx)("h2", { children: n.canonical_name }), /* @__PURE__ */ (0, z.jsx)(iue, {
current: n.canonical_name,
- choices: Fue(n),
+ choices: cue(n),
onChoose: o.chooseName,
onAddAlias: o.addAlias
})]
}),
- /* @__PURE__ */ (0, z.jsx)(Hue, {
+ /* @__PURE__ */ (0, z.jsx)(hue, {
kind: e,
entity: n,
actions: o
@@ -37699,9 +37699,9 @@ function Bue({ kind: e, name: t, entity: n, feedNew: r, feedHost: a, actions: o,
d.length ? /* @__PURE__ */ (0, z.jsx)("div", {
ref: m,
"data-entity-links": "",
- children: d.map((e, t) => /* @__PURE__ */ (0, z.jsx)(Kue, { link: e }, t))
+ children: d.map((e, t) => /* @__PURE__ */ (0, z.jsx)(yue, { link: e }, t))
}) : null,
- f.length || n.feed ? /* @__PURE__ */ (0, z.jsx)(que, {
+ f.length || n.feed ? /* @__PURE__ */ (0, z.jsx)(bue, {
entity: n,
actions: o,
helpers: s
@@ -37710,11 +37710,11 @@ function Bue({ kind: e, name: t, entity: n, feedNew: r, feedHost: a, actions: o,
}),
u.length ? /* @__PURE__ */ (0, z.jsx)("dl", {
"data-entity-facts": "",
- children: u.map((e) => /* @__PURE__ */ (0, z.jsx)(Wue, {
+ children: u.map((e) => /* @__PURE__ */ (0, z.jsx)(_ue, {
glyph: e.glyph,
label: e.label,
clip: e.clip,
- children: e.tags ? /* @__PURE__ */ (0, z.jsx)(Gue, { tags: e.tags }) : e.parts.map((e, t) => /* @__PURE__ */ (0, z.jsxs)("span", {
+ children: e.tags ? /* @__PURE__ */ (0, z.jsx)(vue, { tags: e.tags }) : e.parts.map((e, t) => /* @__PURE__ */ (0, z.jsxs)("span", {
"data-fact-tone": e.tone === "plain" ? void 0 : e.tone,
children: [t ? " " : "", e.text]
}, t))
@@ -37741,14 +37741,14 @@ function Bue({ kind: e, name: t, entity: n, feedNew: r, feedHost: a, actions: o,
}, e.k))
})
}) : null]
- }), a ? (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(RA, {
+ }), a ? (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(dj, {
feedNew: r,
host: a,
wire: s.wireFeedRow,
act: (e, t) => o.feedAction(e, t)
}), a) : null] });
}
-function Vue({ kind: e, name: t, helpers: n, people: r, company: a }) {
+function mue({ kind: e, name: t, helpers: n, people: r, company: a }) {
let [o] = (0, R.useState)(() => `${n.portraitImg()}<span>${i(t.slice(0, 1))}</span>`);
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-entity-portrait": r ? "round" : "square",
@@ -37757,8 +37757,8 @@ function Vue({ kind: e, name: t, helpers: n, people: r, company: a }) {
dangerouslySetInnerHTML: { __html: o }
});
}
-function Hue({ kind: e, entity: t, actions: n }) {
- let i = WA(t), a = (e, t) => (r) => {
+function hue({ kind: e, entity: t, actions: n }) {
+ let i = _j(t), a = (e, t) => (r) => {
r.preventDefault(), n.openEntity(e, t);
}, o = i ? i.linked ? /* @__PURE__ */ (0, z.jsx)("a", {
href: r("agency", i.name),
@@ -37767,36 +37767,36 @@ function Hue({ kind: e, entity: t, actions: n }) {
children: i.name
}) : i.name : null, s = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("b", { children: t.asset_count.toLocaleString() }), " 个视频"] });
if (e === "performer") {
- let e = zue(t.name_groups);
+ let e = fue(t.name_groups);
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-entity-alias": "meta",
children: [
/* @__PURE__ */ (0, z.jsxs)("span", {
"data-meta-item": "",
title: "视频",
- children: [/* @__PURE__ */ (0, z.jsx)(zA, { name: "film" }), /* @__PURE__ */ (0, z.jsx)("span", { children: s })]
+ children: [/* @__PURE__ */ (0, z.jsx)(fj, { name: "film" }), /* @__PURE__ */ (0, z.jsx)("span", { children: s })]
}),
o ? /* @__PURE__ */ (0, z.jsxs)("span", {
"data-meta-item": "",
title: "事务所",
- children: [/* @__PURE__ */ (0, z.jsx)(zA, { name: "briefcase" }), /* @__PURE__ */ (0, z.jsx)("span", { children: o })]
+ children: [/* @__PURE__ */ (0, z.jsx)(fj, { name: "briefcase" }), /* @__PURE__ */ (0, z.jsx)("span", { children: o })]
}) : null,
e ? /* @__PURE__ */ (0, z.jsxs)("div", {
"data-meta-item": "names",
children: [
- /* @__PURE__ */ (0, z.jsx)(zA, { name: "id-card" }),
+ /* @__PURE__ */ (0, z.jsx)(fj, { name: "id-card" }),
/* @__PURE__ */ (0, z.jsx)("span", {
"data-alias-names": "",
title: "别名",
children: e.names.map((e, t) => /* @__PURE__ */ (0, z.jsx)("span", { children: e }, t))
}),
- e.rest > 0 ? /* @__PURE__ */ (0, z.jsx)(UA, {
+ e.rest > 0 ? /* @__PURE__ */ (0, z.jsx)(gj, {
id: "entityAliasPop",
hook: "alias",
rest: e.rest,
label: `另外 ${e.rest} 个别名`,
heading: `${e.total} 个别名`,
- children: /* @__PURE__ */ (0, z.jsx)("dl", { children: (t.name_groups?.groups || []).map((e, t) => /* @__PURE__ */ (0, z.jsx)(Uue, {
+ children: /* @__PURE__ */ (0, z.jsx)("dl", { children: (t.name_groups?.groups || []).map((e, t) => /* @__PURE__ */ (0, z.jsx)(gue, {
label: e.label,
names: e.names
}, t)) })
@@ -37831,25 +37831,25 @@ function Hue({ kind: e, entity: t, actions: n }) {
]
});
}
-function Uue({ label: e, names: t }) {
+function gue({ label: e, names: t }) {
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [e ? /* @__PURE__ */ (0, z.jsx)("dt", { children: e }) : null, /* @__PURE__ */ (0, z.jsx)("dd", {
"data-wide": e ? void 0 : "",
children: t.map((e, t) => /* @__PURE__ */ (0, z.jsxs)("span", { children: [e.name, e.reading ? /* @__PURE__ */ (0, z.jsx)("small", { children: e.reading }) : null] }, t))
})] });
}
-function Wue({ glyph: e, label: t, clip: n, children: r }) {
- return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsxs)("dt", { children: [/* @__PURE__ */ (0, z.jsx)(zA, { name: e }), t] }), /* @__PURE__ */ (0, z.jsx)("dd", {
+function _ue({ glyph: e, label: t, clip: n, children: r }) {
+ return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsxs)("dt", { children: [/* @__PURE__ */ (0, z.jsx)(fj, { name: e }), t] }), /* @__PURE__ */ (0, z.jsx)("dd", {
"data-fact": e === "tags" ? "tags" : n ? "clip" : e === "calendar-range" ? "num" : void 0,
title: n,
children: r
})] });
}
-function Gue({ tags: e }) {
- let { shown: t, rest: n } = Rue(e);
+function vue({ tags: e }) {
+ let { shown: t, rest: n } = due(e);
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [t.map((e) => /* @__PURE__ */ (0, z.jsx)("span", {
"data-fact-tag": "",
children: e
- }, e)), n ? /* @__PURE__ */ (0, z.jsx)(UA, {
+ }, e)), n ? /* @__PURE__ */ (0, z.jsx)(gj, {
id: "entityTagPop",
hook: "fact",
rest: n,
@@ -37864,10 +37864,10 @@ function Gue({ tags: e }) {
})
}) : null] });
}
-function JA({ mark: e }) {
+function xj({ mark: e }) {
if ("brand" in e) return /* @__PURE__ */ (0, z.jsx)("span", {
"data-link-icon": "brand",
- children: /* @__PURE__ */ (0, z.jsx)(zA, { name: e.brand })
+ children: /* @__PURE__ */ (0, z.jsx)(fj, { name: e.brand })
});
let t = l("globe") + ("site" in e ? `<img src="${i(e.site)}" alt="" loading="lazy" referrerpolicy="no-referrer" data-drop="self">` : "");
return /* @__PURE__ */ (0, z.jsx)("span", {
@@ -37875,7 +37875,7 @@ function JA({ mark: e }) {
dangerouslySetInnerHTML: { __html: t }
});
}
-function Kue({ link: e }) {
+function yue({ link: e }) {
switch (e.type) {
case "icon": return /* @__PURE__ */ (0, z.jsx)("a", {
"data-link": "icon",
@@ -37884,19 +37884,19 @@ function Kue({ link: e }) {
rel: "noreferrer",
title: e.title,
"aria-label": e.title,
- children: /* @__PURE__ */ (0, z.jsx)(JA, { mark: e.mark })
+ children: /* @__PURE__ */ (0, z.jsx)(xj, { mark: e.mark })
});
case "gone": return /* @__PURE__ */ (0, z.jsx)("span", {
"data-link": "gone",
tabIndex: 0,
title: e.title,
"aria-label": e.title,
- children: /* @__PURE__ */ (0, z.jsx)(JA, { mark: { globe: !0 } })
+ children: /* @__PURE__ */ (0, z.jsx)(xj, { mark: { globe: !0 } })
});
case "private": return /* @__PURE__ */ (0, z.jsxs)("span", {
"data-link": "private",
title: "私人馆藏来源记录,不直接打开下载页",
- children: [/* @__PURE__ */ (0, z.jsx)(JA, { mark: { globe: !0 } }), /* @__PURE__ */ (0, z.jsxs)("span", {
+ children: [/* @__PURE__ */ (0, z.jsx)(xj, { mark: { globe: !0 } }), /* @__PURE__ */ (0, z.jsxs)("span", {
"data-link-label": "",
children: ["来源 · ", e.label]
})]
@@ -37907,14 +37907,14 @@ function Kue({ link: e }) {
target: "_blank",
rel: "noreferrer",
title: e.title,
- children: [/* @__PURE__ */ (0, z.jsx)(JA, { mark: e.mark }), /* @__PURE__ */ (0, z.jsx)("span", {
+ children: [/* @__PURE__ */ (0, z.jsx)(xj, { mark: e.mark }), /* @__PURE__ */ (0, z.jsx)("span", {
"data-link-label": "",
children: e.text
})]
});
}
}
-function que({ entity: e, actions: t, helpers: n }) {
+function bue({ entity: e, actions: t, helpers: n }) {
let [r, i] = (0, R.useState)(!!e.feed?.following), [a, o] = (0, R.useState)(!1), s = (0, R.useRef)(!1), c = async (e) => {
if (s.current) return !1;
s.current = !0, o(!0);
@@ -37932,47 +37932,47 @@ function que({ entity: e, actions: t, helpers: n }) {
};
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-entry-marks": "",
- children: [qA(e).map((e, t) => /* @__PURE__ */ (0, z.jsxs)("a", {
+ children: [bj(e).map((e, t) => /* @__PURE__ */ (0, z.jsxs)("a", {
"data-entry-mark": "",
href: e.url,
target: "_blank",
rel: "noreferrer",
title: e.label,
"aria-label": e.label,
- children: [e.mark ? /* @__PURE__ */ (0, z.jsx)(zA, { name: e.mark }) : /* @__PURE__ */ (0, z.jsxs)("span", {
+ children: [e.mark ? /* @__PURE__ */ (0, z.jsx)(fj, { name: e.mark }) : /* @__PURE__ */ (0, z.jsxs)("span", {
"data-missav-mark": "",
children: [/* @__PURE__ */ (0, z.jsx)("span", { children: "MISS" }), /* @__PURE__ */ (0, z.jsx)("span", { children: "AV" })]
}), e.ordinal ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-entry-ordinal": "",
children: e.ordinal
}) : null]
- }, t)), e.feed ? /* @__PURE__ */ (0, z.jsx)(Aue, {
+ }, t)), e.feed ? /* @__PURE__ */ (0, z.jsx)(rue, {
following: r,
busy: a,
onToggle: (e) => {
l(e);
},
- tip: Pue(r)
+ tip: sue(r)
}) : null]
});
}
//#endregion
//#region src/react/entity-page/entity-page-view.tsx
-function Jue(e) {
- let { kind: t, name: n } = e, r = $n(Ik(t, n)), i = !!r.data?.error, { actions: a } = e;
+function xue(e) {
+ let { kind: t, name: n } = e, r = $n(Lk(t, n)), i = !!r.data?.error, { actions: a } = e;
return (0, R.useLayoutEffect)(() => {
i && a.missing();
- }, [a, i]), r.isError ? /* @__PURE__ */ (0, z.jsx)(vb, {
+ }, [a, i]), r.isError ? /* @__PURE__ */ (0, z.jsx)(sb, {
message: U(r.error),
onRetry: () => {
r.refetch();
}
- }) : !r.data || i ? null : /* @__PURE__ */ (0, z.jsx)(Zue, {
+ }) : !r.data || i ? null : /* @__PURE__ */ (0, z.jsx)(wue, {
...e,
entity: r.data
});
}
-function YA(e) {
+function Sj(e) {
let [t, n] = (0, R.useState)({
key: e,
n: 1
@@ -37984,14 +37984,14 @@ function YA(e) {
};
return n(r), r.n;
}
-var Yue = () => String(((Date.now() ^ (Math.random() * 1e9 | 0)) >>> 0) % 99991);
-function Xue(e, t) {
+var Sue = () => String(((Date.now() ^ (Math.random() * 1e9 | 0)) >>> 0) % 99991);
+function Cue(e, t) {
return `照片 · ${[e.total || !t ? `${(e.total || 0).toLocaleString()} 张` : "", t ? `样张 ${(e.sample_total || 0).toLocaleString()} 张 · ${t} 部作品` : ""].filter(Boolean).join(" · ")}`;
}
-function Zue(e) {
- let { kind: n, name: r, entity: i, filters: a, media: o, helpers: s, actions: c, hosts: l } = e, u = n === "agency" || n === "studio", d = n === "agency" ? i.related_performers || [] : n === "studio" && i.labels || [], f = Number(i.id) || 0, p = tr(Lk(n, r, 0, "")).data?.pages[0], m = p && !p.error ? p : null, h = m ? (m.total || 0) + (m.sample_total || 0) : 0, g = (m?.total || 0) > 0 || Rk(m).length > 0, _ = o.media === "photos" && g ? o : kk, [v, y] = (0, R.useState)("people"), x = new URLSearchParams(Object.entries(a).filter(([, e]) => e)).toString(), [S, C] = (0, R.useState)(x);
+function wue(e) {
+ let { kind: n, name: r, entity: i, filters: a, media: o, helpers: s, actions: c, hosts: l } = e, u = n === "agency" || n === "studio", d = n === "agency" ? i.related_performers || [] : n === "studio" && i.labels || [], f = Number(i.id) || 0, p = tr(zk(n, r, 0, "")).data?.pages[0], m = p && !p.error ? p : null, h = m ? (m.total || 0) + (m.sample_total || 0) : 0, g = (m?.total || 0) > 0 || Bk(m).length > 0, _ = o.media === "photos" && g ? o : Ok, [v, y] = (0, R.useState)("people"), x = new URLSearchParams(Object.entries(a).filter(([, e]) => e)).toString(), [S, C] = (0, R.useState)(x);
S !== x && (C(x), y("videos"));
- let w = u && v === "people" && d.length ? "people" : _.media, T = Fk(e), E = $n(T), D = YA(JSON.stringify(T.queryKey)), [O] = (0, R.useState)(() => (n === "performer" || n === "studio") && (e.jav || (E.data?.items || []).some((e) => e.is_jav)));
+ let w = u && v === "people" && d.length ? "people" : _.media, T = Ik(e), E = $n(T), D = Sj(JSON.stringify(T.queryKey)), [O] = (0, R.useState)(() => (n === "performer" || n === "studio") && (e.jav || (E.data?.items || []).some((e) => e.is_jav)));
(0, R.useLayoutEffect)(() => {
c.javContext(O);
}, [c, O]);
@@ -38001,26 +38001,26 @@ function Zue(e) {
}, [e.layout, O]), A = {
jav: e.jav,
seed: e.seed
- }, j = (0, R.useCallback)((t, i) => Pk(n, r, a, A, t, e.cache, i), [D]), [M, N] = (0, R.useState)({}), P = _.set, ee = M[P] || "", F = tr({
- ...Lk(n, r, P, ee),
+ }, j = (0, R.useCallback)((t, i) => Fk(n, r, a, A, t, e.cache, i), [D]), [M, N] = (0, R.useState)({}), P = _.set, ee = M[P] || "", F = tr({
+ ...zk(n, r, P, ee),
enabled: w === "photos"
- }), I = F.data?.pages[0], te = YA(JSON.stringify(jk(n, r, P, ee))), ne = (0, R.useMemo)(() => {
+ }), I = F.data?.pages[0], te = Sj(JSON.stringify(jk(n, r, P, ee))), ne = (0, R.useMemo)(() => {
let e = F.data?.pages;
if (!e?.[0] || e[0].error) return null;
let t = e[0];
return {
revision: te,
- codeSets: t.id ? [] : Rk(t),
+ codeSets: t.id ? [] : Bk(t),
items: e.flatMap((e) => e.items || []),
total: t.total || 0,
hasMore: !!e[e.length - 1]?.has_more
};
}, [F.data, te]), re = F.refetch, ie = F.fetchNextPage, ae = $n({
- ...Dk(f, s.feedRowHtml),
+ ...wk(f, s.feedRowHtml),
enabled: !!f
}), oe = (0, R.useRef)(e.feedRevision);
(0, R.useEffect)(() => {
- oe.current !== e.feedRevision && (oe.current = e.feedRevision, X.invalidateQueries({ queryKey: Ek(f) }));
+ oe.current !== e.feedRevision && (oe.current = e.feedRevision, X.invalidateQueries({ queryKey: yk(f) }));
}, [f, e.feedRevision]);
let se = !!E.data;
(0, R.useEffect)(() => {
@@ -38037,7 +38037,7 @@ function Zue(e) {
ce.current = !1;
}, []);
let [le, ue] = (0, R.useState)(0), L = (0, R.useCallback)(async () => {
- await X.invalidateQueries({ queryKey: Ak(n, r) }), await X.invalidateQueries({ queryKey: [
+ await X.invalidateQueries({ queryKey: kk(n, r) }), await X.invalidateQueries({ queryKey: [
"entity-items",
n,
r
@@ -38068,7 +38068,7 @@ function Zue(e) {
enabled: e
})
}),
- onSuccess: (e, t) => X.setQueryData(Ak(n, r), (e) => e && {
+ onSuccess: (e, t) => X.setQueryData(kk(n, r), (e) => e && {
...e,
feed: {
...e.feed,
@@ -38116,12 +38116,12 @@ function Zue(e) {
let e = await t("/api/feeds/check").catch(() => null);
if (!e || e.status !== "running") break;
}
- ce.current && await X.invalidateQueries({ queryKey: Ek(f) });
+ ce.current && await X.invalidateQueries({ queryKey: yk(f) });
})();
},
- feedAction: Ok,
+ feedAction: Tk,
avatarPicked: () => {
- X.refetchQueries({ queryKey: Ak(n, r) }).then(() => {
+ X.refetchQueries({ queryKey: kk(n, r) }).then(() => {
ce.current && ue((e) => e + 1);
});
}
@@ -38150,19 +38150,19 @@ function Zue(e) {
e === w && !_.set || (y(e === "people" ? "people" : "videos"), c.route(a, e === "photos" ? {
media: "photos",
set: 0
- } : kk));
+ } : Ok));
},
setState: (e) => c.route({
...a,
state: e
- }, kk),
+ }, Ok),
toggleTag: c.toggleTag,
clearFilter: c.clearFilter,
clearAll: c.clearAll,
setSort: c.setSort,
reshuffle: async () => {
if (w !== "photos") {
- let t = c.reshuffleVideos(), i = Fk({
+ let t = c.reshuffleVideos(), i = Ik({
kind: n,
name: r,
filters: {
@@ -38177,7 +38177,7 @@ function Zue(e) {
await X.fetchQuery(i).catch(() => null);
return;
}
- let t = Yue(), i = await X.fetchInfiniteQuery(Lk(n, r, P, t)).catch(() => null);
+ let t = Sue(), i = await X.fetchInfiniteQuery(zk(n, r, P, t)).catch(() => null);
!ce.current || !i?.pages[0] || i.pages[0].error || N((e) => ({
...e,
[P]: t
@@ -38211,7 +38211,7 @@ function Zue(e) {
k: e.k,
label: s.tagLabel(e.k),
n: e.n,
- selected: Ole(a.tag, e.k)
+ selected: Nk(a.tag, e.k)
})), ye = h || d.length ? {
label: d.length ? "页面视图" : "媒体类型",
people: d.length ? {
@@ -38239,7 +38239,7 @@ function Zue(e) {
we = !E.data;
let e = Mk(a.tag).map(s.tagLabel);
Ce = `视频 · ${(E.data?.total || 0).toLocaleString()}${e.length ? ` · ${e.join(" · ")}` : ""}`;
- } else I && !I.error ? Ce = xe ? `${I.title} · ${(I.total || 0).toLocaleString()} 张` : Xue(I, Rk(I).length) : we = F.isPending;
+ } else I && !I.error ? Ce = xe ? `${I.title} · ${(I.total || 0).toLocaleString()} 张` : Cue(I, Bk(I).length) : we = F.isPending;
let Te = (0, R.useMemo)(() => ({
...e.card.actions,
loadMorePhotos: async () => {
@@ -38256,7 +38256,7 @@ function Zue(e) {
d
]);
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
- /* @__PURE__ */ (0, z.jsx)(Bue, {
+ /* @__PURE__ */ (0, z.jsx)(pue, {
kind: n,
name: r,
entity: i,
@@ -38266,7 +38266,7 @@ function Zue(e) {
actions: me,
helpers: he
}, le),
- (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(nle, {
+ (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(ule, {
kind: n,
name: r,
view: w,
@@ -38282,12 +38282,12 @@ function Zue(e) {
actions: ge,
helpers: _e
}), l.filter),
- (0, ze.createPortal)(w === "videos" && E.isError ? /* @__PURE__ */ (0, z.jsx)(vb, {
+ (0, ze.createPortal)(w === "videos" && E.isError ? /* @__PURE__ */ (0, z.jsx)(sb, {
message: U(E.error),
onRetry: () => {
E.refetch();
}
- }) : /* @__PURE__ */ (0, z.jsx)(rue, {
+ }) : /* @__PURE__ */ (0, z.jsx)(IA, {
kind: n,
name: r,
view: w,
@@ -38314,21 +38314,21 @@ function Zue(e) {
}
//#endregion
//#region src/react/feed-new/feed-new-page.tsx
-function Que({ host: e, revision: t, helpers: n, actions: r }) {
- let i = $n(Dk(null, n.feedRowHtml)), a = (0, R.useRef)(t);
+function Tue({ host: e, revision: t, helpers: n, actions: r }) {
+ let i = $n(wk(null, n.feedRowHtml)), a = (0, R.useRef)(t);
return (0, R.useEffect)(() => {
- a.current !== t && (a.current = t, X.invalidateQueries({ queryKey: Ek(null) }));
- }, [t]), (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(RA, {
+ a.current !== t && (a.current = t, X.invalidateQueries({ queryKey: yk(null) }));
+ }, [t]), (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(dj, {
feedNew: i.data ?? null,
host: e,
wire: n.wireFeedRow,
- act: Ok,
+ act: Tk,
settled: r.settled
}), e);
}
//#endregion
//#region src/follow-sort.ts
-var XA = [
+var Cj = [
["checked", "检查时间"],
["added", "添加时间"],
["name", "创作者名称"],
@@ -38336,7 +38336,7 @@ var XA = [
["source", "来源名称"],
["provider", "站点"],
["status", "状态"]
-], $ue = "checked", ZA = {
+], Eue = "checked", wj = {
checked: "desc",
added: "desc",
name: "asc",
@@ -38344,32 +38344,32 @@ var XA = [
source: "asc",
provider: "asc",
status: "asc"
-}, ede = (e) => XA.some(([t]) => t === e);
-function QA(e, t) {
- let n = ede(e) ? e : $ue;
+}, Due = (e) => Cj.some(([t]) => t === e);
+function Tj(e, t) {
+ let n = Due(e) ? e : Eue;
return {
sort: n,
- dir: t === "asc" || t === "desc" ? t : ZA[n]
+ dir: t === "asc" || t === "desc" ? t : wj[n]
};
}
//#endregion
//#region src/react/follow-manage/follow-manage.ts
-var $A = "/api/follow", ej = "/api/follow/credentials", tj = "/api/follow/check", nj = "/api/follow/source", rj = "/api/follow/resolve", tde = "/api/follow/suggest", ij = "/api/follow/author-alias", nde = "/api/follow/credential", aj = "/api/follow/status", rde = "/api/feeds", oj = "/api/feeds/source", ide = "/api/feeds/check", ade = "/api/feeds/lookup", sj = ["follow-manage"], cj = ["follow-manage", "credentials"], ode = ["follow-manage", "check"], sde = ["follow-manage", "resolve"], lj = ["follow-manage", "feeds"], cde = (e) => [
+var Ej = "/api/follow", Dj = "/api/follow/credentials", Oj = "/api/follow/check", kj = "/api/follow/source", Aj = "/api/follow/resolve", Oue = "/api/follow/suggest", jj = "/api/follow/author-alias", kue = "/api/follow/credential", Mj = "/api/follow/status", Aue = "/api/feeds", Nj = "/api/feeds/source", jue = "/api/feeds/check", Mue = "/api/feeds/lookup", Pj = ["follow-manage"], Fj = ["follow-manage", "credentials"], Nue = ["follow-manage", "check"], Pue = ["follow-manage", "resolve"], Ij = ["follow-manage", "feeds"], Fue = (e) => [
"follow-manage",
"suggest",
e
-], uj = [["default", "默认视图"], ["table", "表格视图"]], dj = [
+], Lj = [["default", "默认视图"], ["table", "表格视图"]], Rj = [
10,
20,
50,
100
-], lde = Object.fromEntries(XA), fj = {
+], Iue = Object.fromEntries(Cj), zj = {
author: "name",
source: "source",
provider: "provider",
status: "status",
checked: "checked"
-}, ude = (e) => uj.some(([t]) => t === e), dde = (e) => dj.includes(Number(e)) ? Number(e) : 20, fde = {
+}, Lue = (e) => Lj.some(([t]) => t === e), Rue = (e) => Rj.includes(Number(e)) ? Number(e) : 20, zue = {
checked: ["从近到远", "从远到近"],
added: ["从近到远", "从远到近"],
name: ["倒序", "正序"],
@@ -38377,25 +38377,25 @@ var $A = "/api/follow", ej = "/api/follow/credentials", tj = "/api/follow/check"
source: ["倒序", "正序"],
provider: ["倒序", "正序"],
status: ["倒序", "正序"]
-}, pde = (e, t) => `按${lde[e]}${fde[e][t === "asc" ? 0 : 1]}排序`;
-function pj(e) {
+}, Bue = (e, t) => `按${Iue[e]}${zue[e][t === "asc" ? 0 : 1]}排序`;
+function Bj(e) {
let t = e.last_status;
return t === "error" || t === "unauthorized" ? 0 : e.enabled ? t === "ok" ? 3 : 2 : 1;
}
-function mde(e) {
+function Vue(e) {
return e.history_exhausted ? "没有更多" : e.enabled ? e.last_status === "ok" ? "正常" : e.last_status === "error" || e.last_status === "unauthorized" ? "检查失败" : "未检查" : "已暂停";
}
-var mj = (e) => e.last_status === "error" || e.last_status === "unauthorized", hj = (e, t) => String(e.label || "").localeCompare(String(t.label || ""), "zh-CN", { numeric: !0 }), gj = {
- source: hj,
- provider: (e, t) => String(e.provider_label || "").localeCompare(String(t.provider_label || ""), "zh-CN") || hj(e, t),
- status: (e, t) => pj(e) - pj(t) || hj(e, t)
-}, _j = (e) => Date.parse(e || "") || 0, vj = (e) => String(e || "").replace(/\s*[·|]\s*[A-Za-z0-9_-]+\s*$/, "").replace(/\s+collections?\s*$/i, "").trim();
-function yj(e, t = []) {
+var Vj = (e) => e.last_status === "error" || e.last_status === "unauthorized", Hj = (e, t) => String(e.label || "").localeCompare(String(t.label || ""), "zh-CN", { numeric: !0 }), Uj = {
+ source: Hj,
+ provider: (e, t) => String(e.provider_label || "").localeCompare(String(t.provider_label || ""), "zh-CN") || Hj(e, t),
+ status: (e, t) => Bj(e) - Bj(t) || Hj(e, t)
+}, Wj = (e) => Date.parse(e || "") || 0, Gj = (e) => String(e || "").replace(/\s*[·|]\s*[A-Za-z0-9_-]+\s*$/, "").replace(/\s+collections?\s*$/i, "").trim();
+function Kj(e, t = []) {
if (!e.length) return "";
- let n = (e) => String(e.author_name || "").trim() || vj(e.label), r = e.find((e) => e.entity_name);
+ let n = (e) => String(e.author_name || "").trim() || Gj(e.label), r = e.find((e) => e.entity_name);
if (r) return r.entity_name;
let i = t.find((t) => `name:${t.canonical_key}` === e[0]?.author_key);
- if (i) return vj(i.canonical_name);
+ if (i) return Gj(i.canonical_name);
let a = e.find((e) => e.official_avatar_url);
if (a && n(a)) return n(a);
let o = e.map(n).filter(Boolean);
@@ -38403,18 +38403,18 @@ function yj(e, t = []) {
let s = (e) => (e.match(/[A-Z]/g) || []).length;
return o.reduce((e, t) => s(t) > s(e) ? t : e, o[0]);
}
-function bj(e) {
+function qj(e) {
let t = e.trim().match(/[A-Za-z0-9]/);
return (t ? t[0] : Array.from(e.trim())[0] || "?").toUpperCase();
}
-function xj(e) {
+function Jj(e) {
let t = e.find((e) => e.official_avatar_url), n = e.find((e) => e.avatar_url), r = t?.official_avatar_url || n?.avatar_url || "";
return {
src: r,
fallback: t && n && n.avatar_url !== r && n.avatar_url || ""
};
}
-function Sj(e) {
+function Yj(e) {
let t = [], n = /* @__PURE__ */ new Map();
for (let r of e) {
let e = r.author_key || `source:${r.id}`;
@@ -38422,32 +38422,32 @@ function Sj(e) {
}
return t.map((e) => n.get(e));
}
-function hde(e, t, n, r = []) {
- let i = Sj(e), a = n === ZA[t] ? 1 : -1, o = (e) => yj(e, r), s = (e, t) => o(e).localeCompare(o(t), "zh-CN", { numeric: !0 }), c = gj[t];
+function Hue(e, t, n, r = []) {
+ let i = Yj(e), a = n === wj[t] ? 1 : -1, o = (e) => Kj(e, r), s = (e, t) => o(e).localeCompare(o(t), "zh-CN", { numeric: !0 }), c = Uj[t];
if (c) {
for (let e of i) e.sort((e, t) => a * c(e, t));
return i.sort((e, t) => a * c(e[0], t[0]) || s(e, t));
}
- let l = (e) => Math.max(...e.map((e) => _j(e.last_checked_at))), u = (e) => Math.max(...e.map((e) => _j(e.created_at)));
+ let l = (e) => Math.max(...e.map((e) => Wj(e.last_checked_at))), u = (e) => Math.max(...e.map((e) => Wj(e.created_at)));
return i.sort((e, n) => t === "name" ? a * s(e, n) : t === "sources" ? a * (n.length - e.length) || s(e, n) : t === "added" ? a * (u(n) - u(e)) || s(e, n) : a * (l(n) - l(e)) || s(e, n));
}
-function gde(e, t, n, r = []) {
+function Uue(e, t, n, r = []) {
let i = e.flatMap((e) => {
- let t = yj(e, r);
+ let t = Kj(e, r);
return e.map((n) => ({
source: n,
group: e,
author: t
}));
- }), a = gj[t];
+ }), a = Uj[t];
if (a) {
- let e = n === ZA[t] ? 1 : -1;
+ let e = n === wj[t] ? 1 : -1;
i.sort((t, n) => e * a(t.source, n.source));
}
return i;
}
-function Cj(e, t, n) {
- let r = cx(e, t), i = lx(n, r), a = (i - 1) * t;
+function Xj(e, t, n) {
+ let r = px(e, t), i = mx(n, r), a = (i - 1) * t;
return {
page: i,
pages: r,
@@ -38456,91 +38456,91 @@ function Cj(e, t, n) {
end: Math.min(a + t, e)
};
}
-function _de(e, t) {
+function Wue(e, t) {
let n = new Set(t.map((e) => e.id));
return new Set([...e].filter((e) => n.has(e)));
}
-function wj(e, t) {
+function Zj(e, t) {
let n = t.filter((t) => e.has(t)).length;
return {
all: t.length > 0 && n === t.length,
some: n > 0 && n < t.length
};
}
-function Tj(e, t, n) {
+function Qj(e, t, n) {
let r = new Set(e);
for (let e of t) n ? r.add(e) : r.delete(e);
return r;
}
-var Ej = (e) => W(`${$A}?summary=1`, e), Dj = (e) => W(ej, e), vde = (e) => W(tj, e), yde = (e) => W(rj, e), bde = (e, t) => W(`${tde}?q=${encodeURIComponent(e)}`, t), Oj = (e) => G(tj, {
+var $j = (e) => W(`${Ej}?summary=1`, e), eM = (e) => W(Dj, e), Gue = (e) => W(Oj, e), Kue = (e) => W(Aj, e), que = (e, t) => W(`${Oue}?q=${encodeURIComponent(e)}`, t), tM = (e) => G(Oj, {
...e?.length ? { sources: e } : {},
background: !0
-}), xde = (e) => G(rj, {
+}), Jue = (e) => G(Aj, {
lines: e,
background: !0
-}), kj = (e, t) => G(nj, {
+}), nM = (e, t) => G(kj, {
action: "enabled",
id: e,
enabled: t
-}), Aj = (e) => G(nj, {
+}), rM = (e) => G(kj, {
action: "remove",
id: e
-}), Sde = (e) => G(nj, {
+}), Yue = (e) => G(kj, {
action: "add",
url: e.url,
label: e.label,
author: e.author || "",
aliases: e.aliases || [],
defer_check: !0
-}), jj = (e, t) => G(ij, {
+}), iM = (e, t) => G(jj, {
action: "add",
canonical: e,
alias: t
-}), Cde = (e) => G(ij, {
+}), Xue = (e) => G(jj, {
action: "remove",
alias: e
-}), wde = (e, t) => G(nde, {
+}), Zue = (e, t) => G(kue, {
provider: e,
values: t
-}), Tde = (e, t) => G(aj, {
+}), Que = (e, t) => G(Mj, {
item: e,
to: t
-}), Ede = () => W(`${$A}?status=new&limit=1000`);
-async function Mj(e) {
- let t = await W(rde, e);
+}), $ue = () => W(`${Ej}?status=new&limit=1000`);
+async function aM(e) {
+ let t = await W(Aue, e);
if (!Array.isArray(t?.sources)) throw Error("没有读到订阅源");
return t;
}
-var Nj = (e, t, n) => G(oj, {
+var oM = (e, t, n) => G(Nj, {
action: "enabled",
id: e,
enabled: t
-}, "POST", n), Pj = (e, t) => G(oj, {
+}, "POST", n), sM = (e, t) => G(Nj, {
action: "remove",
id: e
-}, "POST", t), Fj = (e, t) => G(ide, t?.length ? { sources: t } : { all: !0 }, "POST", e), Dde = (e, t) => W(`${ade}?q=${encodeURIComponent(e)}`, t), Ode = (e, t, n) => G(oj, {
+}, "POST", t), cM = (e, t) => G(jue, t?.length ? { sources: t } : { all: !0 }, "POST", e), ede = (e, t) => W(`${Mue}?q=${encodeURIComponent(e)}`, t), tde = (e, t, n) => G(Nj, {
action: "follow-name",
name: e,
ids: t
}, "POST", n);
-async function kde(e, t = "") {
+async function nde(e, t = "") {
await Promise.all([
X.fetchQuery({
- queryKey: sj,
- queryFn: () => Ej(e)
+ queryKey: Pj,
+ queryFn: () => $j(e)
}),
X.fetchQuery({
- queryKey: cj,
- queryFn: () => Dj(e)
+ queryKey: Fj,
+ queryFn: () => eM(e)
}),
t === "feeds" ? X.fetchQuery({
- queryKey: lj,
- queryFn: () => Mj(e)
+ queryKey: Ij,
+ queryFn: () => aM(e)
}) : null
]);
}
-function Ij(e, t) {
- X.setQueryData(sj, (n) => n && {
+function lM(e, t) {
+ X.setQueryData(Pj, (n) => n && {
...n,
sources: n.sources.map((n) => n.id === e ? {
...n,
@@ -38548,24 +38548,24 @@ function Ij(e, t) {
} : n)
});
}
-function Lj(e) {
+function uM(e) {
let t = new Set(e);
- X.setQueryData(sj, (e) => e && {
+ X.setQueryData(Pj, (e) => e && {
...e,
sources: e.sources.filter((e) => !t.has(e.id))
});
}
-var Rj = () => X.invalidateQueries({
- queryKey: sj,
+var dM = () => X.invalidateQueries({
+ queryKey: Pj,
exact: !0
});
-function Ade(e) {
+function rde(e) {
let t = e.results || [], n = (e) => t.reduce((t, n) => t + (e(n) || 0), 0), r = n((e) => e.added), i = n((e) => e.updated), a = n((e) => e.skipped_compilations), o = n((e) => e.skipped) - a, s = n((e) => e.history_skipped), c = n((e) => e.probed), l = t.filter((e) => e.ok && !e.added && !e.updated).length, u = t.filter((e) => !e.ok).length, d = [];
r && d.push(`新增 ${r} 条`), i && d.push(`更新 ${i} 条`), o && d.push(`跳过 ${o} 条无资源`), a && d.push(`排除 ${a} 个超大合集`), s && d.push(`跳过 ${s} 条超出首次采集范围的历史内容`), c && d.push(`回查 ${c} 条`), l && d.push(`${l} 个来源没有更新`), d.length || d.push("没有任何更新");
let f = t.filter((e) => e.exhausted).length;
return f && d.push(`${f} 个没有更多内容`), u && d.push(`${u} 个失败`), `检查了 ${t.length} 个来源:${d.join(" · ")}`;
}
-var jde = (e) => (e?.results || []).filter((e) => !e.ok), Mde = (e) => (e?.results || []).find((e) => e.evidence_error)?.evidence_error || "", zj = (e) => e.last_checked_at ? ux(e.last_checked_at) : "未检查", Nde = /* @__PURE__ */ new Set([
+var ide = (e) => (e?.results || []).filter((e) => !e.ok), ade = (e) => (e?.results || []).find((e) => e.evidence_error)?.evidence_error || "", fM = (e) => e.last_checked_at ? hx(e.last_checked_at) : "未检查", ode = /* @__PURE__ */ new Set([
"fanbox",
"patreon",
"subscribestar",
@@ -38578,50 +38578,50 @@ var jde = (e) => (e?.results || []).filter((e) => !e.ok), Mde = (e) => (e?.resul
"gofile",
"f95zone",
"simpcity"
-]), Bj = (e) => Nde.has(e) ? `/source-icon?provider=${encodeURIComponent(e)}` : "", Pde = {
+]), pM = (e) => ode.has(e) ? `/source-icon?provider=${encodeURIComponent(e)}` : "", sde = {
required: "需要",
optional: "可选",
none: "不需要",
blocked: "接不进来"
-}, Vj = (e) => !!e.present && !e.missing.length, Fde = [
+}, mM = (e) => !!e.present && !e.missing.length, cde = [
["", "全部"],
["new", "未看"],
["saved", "已保存"],
["ignored", "已忽略"]
-], Ide = [
+], lde = [
["new", "更新时间"],
["hot", "热度"],
["dur", "时长"]
-], Hj = {
+], hM = {
new: ["从新到旧", "从旧到新"],
hot: ["从高到低", "从低到高"],
dur: ["从长到短", "从短到长"]
};
-function Uj(e, t) {
+function gM(e, t) {
let n = (e) => encodeURIComponent(e.join(","));
return `/api/follow?limit=300&offset=${t}` + (e.status ? `&status=${e.status}` : "") + (e.author ? `&author=${n([e.author])}` : "") + (e.provider ? `&provider=${n([e.provider])}` : "") + (e.tags.length ? `&tag=${n(e.tags)}` : "") + (e.work ? `&work=${n([e.work])}` : "") + (e.sort === "new" ? "" : `&sort=${e.sort}`) + (e.sort === "rand" ? `&seed=${e.seed}` : "") + (e.dir === "desc" ? "" : `&dir=${e.dir}`);
}
-function Wj(e, t) {
+function _M(e, t) {
return {
queryKey: [
"follow-feed",
- Uj(e, 0),
+ gM(e, 0),
t
],
- queryFn: ({ pageParam: t, signal: n }) => W(Uj(e, t), n),
+ queryFn: ({ pageParam: t, signal: n }) => W(gM(e, t), n),
initialPageParam: 0,
getNextPageParam: (e) => e.has_more ? (e.offset || 0) + 300 : void 0,
placeholderData: Zt
};
}
-var Gj = ["follow-feed", "credentials"], Kj = (e) => W(ej, e).catch(() => ({ providers: [] }));
-async function Lde(e, t) {
- let n = Wj(e.view, e.revision);
+var vM = ["follow-feed", "credentials"], yM = (e) => W(Dj, e).catch(() => ({ providers: [] }));
+async function ude(e, t) {
+ let n = _M(e.view, e.revision);
X.removeQueries({
queryKey: n.queryKey,
exact: !0
}), X.removeQueries({
- queryKey: Gj,
+ queryKey: vM,
exact: !0
}), await Promise.all([X.fetchInfiniteQuery({
queryKey: n.queryKey,
@@ -38632,11 +38632,11 @@ async function Lde(e, t) {
initialPageParam: 0,
getNextPageParam: n.getNextPageParam
}), X.fetchQuery({
- queryKey: Gj,
- queryFn: () => Kj(t)
+ queryKey: vM,
+ queryFn: () => yM(t)
})]);
}
-function qj(e) {
+function bM(e) {
if (!e?.pages.length) return null;
let t = e.pages, n = t[t.length - 1];
return {
@@ -38645,10 +38645,10 @@ function qj(e) {
groups: t.flatMap((e) => e.groups || [])
};
}
-function Jj(e, t, n) {
+function xM(e, t, n) {
return [...e].sort((e, r) => h(n, t(e)) - h(n, t(r)) || String(t(e)).localeCompare(String(t(r))));
}
-function Yj(e) {
+function SM(e) {
let t = /* @__PURE__ */ new Set();
return [
e.primary,
@@ -38656,12 +38656,12 @@ function Yj(e) {
...e.duplicates
].filter((e) => !e || t.has(e.id) ? !1 : (t.add(e.id), !0));
}
-function Rde(e) {
+function dde(e) {
for (let [, t] of X.getQueriesData({ queryKey: ["follow-feed"] })) {
if (!Array.isArray(t?.pages) || !t.pages.length) continue;
let n = t.pages[t.pages.length - 1];
for (let r of t.pages) for (let t of r.groups || []) {
- let r = Yj(t).find((t) => t.id === e);
+ let r = SM(t).find((t) => t.id === e);
if (r) return {
item: r,
group: t,
@@ -38672,7 +38672,7 @@ function Rde(e) {
}
return null;
}
-function zde(e) {
+function fde(e) {
X.setQueriesData({
queryKey: ["follow-feed"],
predicate: (e) => Array.isArray(e.state.data?.pages)
@@ -38682,7 +38682,7 @@ function zde(e) {
...t,
groups: (t.groups || []).map((t) => {
let n = (t) => t.id === e.id ? e : t;
- return Yj(t).some((t) => t.id === e.id) ? {
+ return SM(t).some((t) => t.id === e.id) ? {
...t,
primary: n(t.primary),
variants: t.variants.map(n),
@@ -38692,39 +38692,39 @@ function zde(e) {
}))
});
}
-function Bde(e, t) {
+function pde(e, t) {
X.setQueriesData({
queryKey: ["follow-feed"],
predicate: (e) => Array.isArray(e.state.data?.pages)
- }, (n) => n && rM(n, null, e, t));
+ }, (n) => n && AM(n, null, e, t));
}
-function Xj(e) {
- return Yj(e).sort((e, t) => (Date.parse(t.published_at || "") || 0) - (Date.parse(e.published_at || "") || 0) || (+t.id || 0) - (+e.id || 0));
+function CM(e) {
+ return SM(e).sort((e, t) => (Date.parse(t.published_at || "") || 0) - (Date.parse(e.published_at || "") || 0) || (+t.id || 0) - (+e.id || 0));
}
-function Zj(e) {
+function wM(e) {
let t = /* @__PURE__ */ new Set(), n = e.media_items || [];
return n.length ? n.forEach((e) => {
(e.media_kind === "image" || e.media_kind === "video") && t.add(e.media_kind);
}) : (e.media_kind === "image" || e.media_kind === "video") && t.add(e.media_kind), t;
}
-function Qj(e) {
+function TM(e) {
let t = /* @__PURE__ */ new Set();
- return Yj(e).forEach((e) => Zj(e).forEach((e) => t.add(e))), t;
+ return SM(e).forEach((e) => wM(e).forEach((e) => t.add(e))), t;
}
-function $j(e, t) {
+function EM(e, t) {
let n = t === "images" ? "image" : "video";
- return Xj(e).find((e) => Zj(e).has(n)) || e.primary;
+ return CM(e).find((e) => wM(e).has(n)) || e.primary;
}
-function eM(e) {
- return Xj(e).filter((e) => e.playable && e.media_kind === "video");
+function DM(e) {
+ return CM(e).filter((e) => e.playable && e.media_kind === "video");
}
-var tM = {
+var OM = {
video: "个视频",
image: "张图片",
mixed: "个媒体"
};
-function Vde({ cover: e = "", coverFace: t = null, stack: n = null, imageView: r = !1, limit: i = 9 } = {}) {
- let a = n?.media || 0, o = n?.copies || 0, s = n?.kind || "", c = a > 1 ? `${a} ${tM[s] || tM.mixed}` : o > 1 ? `${o} 个来源` : "", l = s === "image" || s !== "video" && r ? "pics" : "play", u = /* @__PURE__ */ new Set([t ?? e]), d = e ? [e] : [];
+function mde({ cover: e = "", coverFace: t = null, stack: n = null, imageView: r = !1, limit: i = 9 } = {}) {
+ let a = n?.media || 0, o = n?.copies || 0, s = n?.kind || "", c = a > 1 ? `${a} ${OM[s] || OM.mixed}` : o > 1 ? `${o} 个来源` : "", l = s === "image" || s !== "video" && r ? "pics" : "play", u = /* @__PURE__ */ new Set([t ?? e]), d = e ? [e] : [];
for (let t of n?.faces || []) r && t.media_kind !== "image" || !t.thumb_url || t.thumb_url === e || u.has(t.face) || (u.add(t.face), d.push(t.thumb_url));
return {
isMix: !!c,
@@ -38733,14 +38733,14 @@ function Vde({ cover: e = "", coverFace: t = null, stack: n = null, imageView: r
faces: d.length > 1 ? d.slice(0, i) : []
};
}
-function Hde(e) {
+function hde(e) {
let t = e.filter((e) => e.can_backfill).map((e) => (e.backfill_page || 0) + 1);
if (!t.length) return "";
let n = Math.max(...t), r = Math.min(...t);
return n <= 1 ? "每个来源都只抓了第 1 页" : r === n ? `每个来源都抓到第 ${n} 页` : `已抓到第 ${r}–${n} 页`;
}
-function nM(e, t, n) {
- return e === t ? Hj[e] ? {
+function kM(e, t, n) {
+ return e === t ? hM[e] ? {
sort: e,
dir: n === "asc" ? "desc" : "asc"
} : null : {
@@ -38748,13 +38748,13 @@ function nM(e, t, n) {
dir: "desc"
};
}
-function Ude(e, t, n, r) {
- let i = nM(e, n, r);
+function gde(e, t, n, r) {
+ let i = kM(e, n, r);
if (!i) return "";
- let a = Hj[i.sort];
+ let a = hM[i.sort];
return `按${t}${a ? a[+(i.dir === "asc")] : ""}排序`;
}
-function rM(e, t, n, r) {
+function AM(e, t, n, r) {
let i = "", a = e.pages.map((e) => ({
...e,
groups: (e.groups || []).flatMap((e) => {
@@ -38784,7 +38784,7 @@ function rM(e, t, n, r) {
})
};
}
-function Wde(e, t) {
+function _de(e, t) {
let n = [];
return e.author && n.push({
kind: "创作者",
@@ -38804,7 +38804,7 @@ function Wde(e, t) {
label: e
})), n;
}
-function Gde(e, t) {
+function vde(e, t) {
return t.kind === "创作者" ? {
...e,
author: ""
@@ -38819,7 +38819,7 @@ function Gde(e, t) {
tags: e.tags.filter((e) => e !== t.key)
};
}
-function Kde(e, t) {
+function yde(e, t) {
for (let n of e) {
let e = n.primary?.tag_types?.[t];
if (e) return e;
@@ -38828,7 +38828,7 @@ function Kde(e, t) {
}
//#endregion
//#region src/sidebar.ts
-var qde = [
+var bde = [
"",
"follow",
"jav",
@@ -38837,7 +38837,7 @@ var qde = [
"studios",
"flagged",
"manage"
-], Jde = [
+], xde = [
"playlists",
"immerse",
"stats",
@@ -38847,77 +38847,77 @@ var qde = [
"follow-manage",
"quality"
];
-[...qde, ...Jde];
-function Yde(e) {
+[...bde, ...xde];
+function Sde(e) {
let t = /* @__PURE__ */ new Map();
for (let n of e) for (let e of new Set(n.tags || [])) t.set(e, (t.get(e) || 0) + 1);
return [...t].sort((e, t) => t[1] - e[1]).slice(0, 30);
}
//#endregion
//#region src/react/follow-feed/follow-marks.ts
-var iM = (e) => typeof e == "string" ? e : "", aM = (e) => e.aliases;
-function oM(e, t = "") {
- let n = Bj(e);
+var jM = (e) => typeof e == "string" ? e : "", MM = (e) => e.aliases;
+function NM(e, t = "") {
+ let n = pM(e);
return n ? `<img data-follow-site-icon="" src="${n}" alt="${i(t)}"${t ? ` title="${i(t)}"` : ""} loading="lazy" data-drop="self">` : "";
}
-var sM = (e, t) => yj(e, aM(t));
-function cM(e, t) {
- let { src: n, fallback: r } = xj(e), a = bj(t);
+var PM = (e, t) => Kj(e, MM(t));
+function FM(e, t) {
+ let { src: n, fallback: r } = Jj(e), a = qj(t);
if (!n) return `<span class="favatar none" title="没有可用头像">${i(a)}</span>`;
let o = r ? ` data-fallbacks="${i(r)}"` : "";
return `<img class="favatar" src="${i(n)}" alt="" loading="lazy" referrerpolicy="no-referrer" data-drop="initial"${o} data-initial="${i(a)}" data-drop-class="favatar none">`;
}
-function lM(e, t, n) {
- let r = aM(n), i = e.credit, a = i?.poster;
+function IM(e, t, n) {
+ let r = MM(n), i = e.credit, a = i?.poster;
if (!a) {
- let n = yj(t, r);
+ let n = Kj(t, r);
return {
- author: n || iM(e.author) || iM(e.source_label) || "创作者未取得",
- avatar: cM(t, n),
+ author: n || jM(e.author) || jM(e.source_label) || "创作者未取得",
+ avatar: FM(t, n),
credited: ""
};
}
- let o = (e) => String(e || "").toLowerCase().replace(/[^a-z0-9]/g, ""), s = n.sources.find((e) => o(e.ref) === o(a)), c = s?.author_key ? n.sources.filter((e) => e.author_key === s.author_key) : s ? [s] : [], l = c.length && yj(c, r) || a;
+ let o = (e) => String(e || "").toLowerCase().replace(/[^a-z0-9]/g, ""), s = n.sources.find((e) => o(e.ref) === o(a)), c = s?.author_key ? n.sources.filter((e) => e.author_key === s.author_key) : s ? [s] : [], l = c.length && Kj(c, r) || a;
return {
author: l,
- avatar: cM(c, l),
+ avatar: FM(c, l),
credited: i.credited || ""
};
}
-function uM(e, t = e.primary) {
+function LM(e, t = e.primary) {
let n = [], r = (e, t) => `<small class="javedition" data-follow-edition="${e}">${t}</small>`;
e.primary.variant_kind === "wip" ? n.push(r("wip", "WIP")) : e.has_wip && n.push(r("has-wip", "含 WIP"));
- let a = iM(e.primary.version);
+ let a = jM(e.primary.version);
a && n.push(r("version", i(a)));
- let o = iM(t.audio), s = o === "voiced" ? "配音版" : o === "silent" ? "无声版" : "";
+ let o = jM(t.audio), s = o === "voiced" ? "配音版" : o === "silent" ? "无声版" : "";
return s && n.push(r(o, s)), n.join("");
}
-function dM(e, t = e.primary) {
+function RM(e, t = e.primary) {
let n = new Map([
e.primary,
...e.variants,
...e.duplicates
].filter((e) => e.provider !== t.provider).map((e) => [e.provider, e.provider_label || e.provider]));
if (!n.size) return "";
- let r = [...n].map(([e, t]) => oM(e, t) || `<span>${i(t)}</span>`).join("");
+ let r = [...n].map(([e, t]) => NM(e, t) || `<span>${i(t)}</span>`).join("");
return `<span data-follow-seealso="" title="另见 ${i([...n.values()].join("、"))}">另见 ${r}</span>`;
}
-function fM(e, t) {
- let n = iM(e.media_error);
+function zM(e, t) {
+ let n = jM(e.media_error);
return n ? `媒体未取得:${n}` : e.media_needs_credential && !t.credentials.has(e.provider) ? e.playable ? "部分媒体未取得:需要 F95 登录会话解析" : "媒体未取得:需要 F95 登录会话解析" : "";
}
-var pM = (e) => e.published_at ? ux(e.published_at) : "时间未取得", mM = /* @__PURE__ */ new Set(), hM = [], gM = null;
-function _M() {
- if (gM = null, !hM.length) return;
- let e = hM.splice(0, 200);
+var BM = (e) => e.published_at ? hx(e.published_at) : "时间未取得", VM = /* @__PURE__ */ new Set(), HM = [], UM = null;
+function WM() {
+ if (UM = null, !HM.length) return;
+ let e = HM.splice(0, 200);
t("/api/follow/image-dims", {
method: "POST",
body: JSON.stringify({ entries: e })
- }).catch(() => {}), hM.length && (gM = setTimeout(_M, 800));
+ }).catch(() => {}), HM.length && (UM = setTimeout(WM, 800));
}
-function Xde(e, t, n, r) {
+function Cde(e, t, n, r) {
let i = `${e}:${t ?? ""}`;
- mM.has(i) || (mM.add(i), hM.push(t === null ? {
+ VM.has(i) || (VM.add(i), HM.push(t === null ? {
item: e,
width: n,
height: r
@@ -38926,15 +38926,15 @@ function Xde(e, t, n, r) {
width: n,
height: r,
media: t
- }), gM ||= setTimeout(_M, 800));
+ }), UM ||= setTimeout(WM, 800));
}
//#endregion
//#region src/react/follow-feed/follow-card.tsx
-var Zde = (e) => Number(e) > 0;
-function Qde(e) {
+var wde = (e) => Number(e) > 0;
+function Tde(e) {
return /^\d{4}-/.test(e) ? e.startsWith(String((/* @__PURE__ */ new Date()).getFullYear())) ? e.slice(5, 10) : e.slice(0, 10) : e;
}
-function $de({ src: e, width: t, height: n, onLearn: r }) {
+function Ede({ src: e, width: t, height: n, onLearn: r }) {
let [i, a] = (0, R.useState)(!1);
return i ? null : /* @__PURE__ */ (0, z.jsx)("img", {
src: e,
@@ -38950,8 +38950,8 @@ function $de({ src: e, width: t, height: n, onLearn: r }) {
} : void 0
});
}
-function efe(e) {
- let { group: t, authorSources: n, media: r, context: a, selected: s, selectMode: c, busy: u, failure: d, helpers: f, actions: p } = e, m = $j(t, r), h = r === "images", g = h ? (m.media_items || []).find((e) => e.media_kind === "image") : void 0, _ = g?.thumb_url || m.thumb_url || "", v = g && g.thumb_url === _ ? g : null, y = !v || _ === m.thumb_url, b = h ? [v, y ? m : null].find((e) => Number(e?.width) > 0 && Number(e?.height) > 0) : null, x = h && !b && _ ? (e, t) => Xde(m.id, v ? v.index : null, e, t) : void 0, S = r === "videos" ? eM(t) : [], C = (m.media_items || []).length > 1 ? m.id : S[0]?.id || m.id, w = Vde({
+function Dde(e) {
+ let { group: t, authorSources: n, media: r, context: a, selected: s, selectMode: c, busy: u, failure: d, helpers: f, actions: p } = e, m = EM(t, r), h = r === "images", g = h ? (m.media_items || []).find((e) => e.media_kind === "image") : void 0, _ = g?.thumb_url || m.thumb_url || "", v = g && g.thumb_url === _ ? g : null, y = !v || _ === m.thumb_url, b = h ? [v, y ? m : null].find((e) => Number(e?.width) > 0 && Number(e?.height) > 0) : null, x = h && !b && _ ? (e, t) => Cde(m.id, v ? v.index : null, e, t) : void 0, S = r === "videos" ? DM(t) : [], C = (m.media_items || []).length > 1 ? m.id : S[0]?.id || m.id, w = mde({
cover: _,
coverFace: (g?.thumb_url ? g : m).face,
stack: t.stack,
@@ -38959,7 +38959,7 @@ function efe(e) {
limit: 9
}), T = (0, R.useRef)(w.faces);
T.current = w.faces;
- let E = kb({
+ let E = Nb({
load: async () => T.current,
canFlip: () => T.current.length > 1 && p.canFlip(),
referrerPolicy: "no-referrer"
@@ -38967,7 +38967,7 @@ function efe(e) {
D.current = E.onPointerLeave;
let O = (0, R.useCallback)((e) => {
e && (e._stopHover = () => D.current());
- }, []), k = lM(m, n, a), A = pM(m), j = (m.tags || []).slice(0, 3), M = fM(m, a), N = dM(t, m), P = m.status === "saved", ee = (e) => {
+ }, []), k = IM(m, n, a), A = BM(m), j = (m.tags || []).slice(0, 3), M = zM(m, a), N = RM(t, m), P = m.status === "saved", ee = (e) => {
if (!e.target.closest("[data-media-tag]")) {
if (c || e.shiftKey || e.ctrlKey || e.metaKey) {
e.preventDefault(), p.toggleSelection(m.id, e.shiftKey);
@@ -39001,14 +39001,14 @@ function efe(e) {
"data-follow-open": "",
"aria-label": `打开 ${m.title} 详情`
}),
- _ ? /* @__PURE__ */ (0, z.jsx)($de, {
+ _ ? /* @__PURE__ */ (0, z.jsx)(Ede, {
src: _,
width: b?.width,
height: b?.height,
onLearn: x
}, _) : /* @__PURE__ */ (0, z.jsx)("span", {
"data-follow-nothumb": "",
- dangerouslySetInnerHTML: { __html: oM(m.resource_provider || m.provider) }
+ dangerouslySetInnerHTML: { __html: NM(m.resource_provider || m.provider) }
}),
w.faces.length > 1 ? /* @__PURE__ */ (0, z.jsx)("div", {
"data-mix-faces": "",
@@ -39027,7 +39027,7 @@ function efe(e) {
"data-media-badge": "",
title: m.provider_label,
"aria-label": `来源:${m.provider_label || ""}`,
- dangerouslySetInnerHTML: { __html: oM(m.provider) }
+ dangerouslySetInnerHTML: { __html: NM(m.provider) }
}),
/* @__PURE__ */ (0, z.jsx)("span", {
"data-media-check": "",
@@ -39036,7 +39036,7 @@ function efe(e) {
},
dangerouslySetInnerHTML: { __html: l("check") }
}),
- Zde(m.duration) ? /* @__PURE__ */ (0, z.jsx)("span", {
+ wde(m.duration) ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-media-duration": "",
children: o(m.duration)
}) : null,
@@ -39118,7 +39118,7 @@ function efe(e) {
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-media-title": "",
- dangerouslySetInnerHTML: { __html: uM(t, m) + i(m.title) }
+ dangerouslySetInnerHTML: { __html: LM(t, m) + i(m.title) }
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
"data-follow-byline": "",
@@ -39129,7 +39129,7 @@ function efe(e) {
}), /* @__PURE__ */ (0, z.jsx)("time", {
dateTime: m.published_at || "",
title: A,
- children: Qde(A)
+ children: Tde(A)
})]
}),
k.credited ? /* @__PURE__ */ (0, z.jsx)("div", {
@@ -39165,10 +39165,10 @@ function efe(e) {
]
});
}
-var tfe = (0, R.memo)(efe), vM = () => /* @__PURE__ */ (0, z.jsx)("span", {
+var Ode = (0, R.memo)(Dde), GM = () => /* @__PURE__ */ (0, z.jsx)("span", {
"data-entity-sep": "",
"aria-hidden": "true"
-}), nfe = Ob("settings"), rfe = Ob("chevron-down"), ife = Ob("history"), afe = [[
+}), kde = Ob("settings"), Ade = Ob("chevron-down"), jde = Ob("history"), Mde = [[
"fixed",
"固定比例",
"layout-grid"
@@ -39177,19 +39177,19 @@ var tfe = (0, R.memo)(efe), vM = () => /* @__PURE__ */ (0, z.jsx)("span", {
"瀑布流",
"columns-2"
]];
-function ofe(e, t, n) {
+function Nde(e, t, n) {
return (0, R.useMemo)(() => {
let r = e?.groups || [], i = e?.counts || {}, a = e?.sources || [], o = e?.facets || {}, s = new Set(o.authors || []), c = new Map(a.map((e) => [e.provider, e.provider_label || e.provider])), l = new Map((o.providers || []).map((e) => [e, c.get(e) || e])), u = new Map(o.tags || []), d = /* @__PURE__ */ new Map();
a.forEach((e) => {
e.author_key && (d.has(e.author_key) || d.set(e.author_key, []), d.get(e.author_key).push(e));
});
- let f = Jj([...d.keys()].filter((e) => s.has(e)), (e) => e, n), p = Jj(o.works || [], (e) => e[0], n).slice(0, 24);
+ let f = xM([...d.keys()].filter((e) => s.has(e)), (e) => e, n), p = xM(o.works || [], (e) => e[0], n).slice(0, 24);
t.work && !p.some((e) => e[0] === t.work) && p.push([
t.work,
t.work,
0
]);
- let m = Object.values(i).reduce((e, t) => e + (Number(t) || 0), 0), h = Jj([...u], (e) => e[0], n).slice(0, 20);
+ let m = Object.values(i).reduce((e, t) => e + (Number(t) || 0), 0), h = xM([...u], (e) => e[0], n).slice(0, 20);
t.tags.forEach((e) => {
h.some(([t]) => t === e) || h.push([e, u.get(e) || m]);
});
@@ -39197,7 +39197,7 @@ function ofe(e, t, n) {
videos: 0,
images: 0
};
- r.forEach((e) => Qj(e).forEach((e) => {
+ r.forEach((e) => TM(e).forEach((e) => {
g[e === "image" ? "images" : "videos"] += 1;
}));
let _ = t.media === "images" ? "image" : "video";
@@ -39212,7 +39212,7 @@ function ofe(e, t, n) {
workRows: p,
allCount: m,
mediaCounts: g,
- visible: r.filter((e) => Qj(e).has(_)),
+ visible: r.filter((e) => TM(e).has(_)),
author: d.has(t.author) && s.has(t.author) ? t.author : "",
provider: l.has(t.provider) ? t.provider : "",
workNames: new Map((o.works || []).map((e) => [e[0], e[1]])),
@@ -39225,15 +39225,15 @@ function ofe(e, t, n) {
n
]);
}
-function sfe(e) {
- let { view: t, seed: n, revision: r, helpers: i, actions: a } = e, o = Wj(t, r), s = tr(o), c = $n({
- queryKey: Gj,
- queryFn: ({ signal: e }) => Kj(e)
- }), l = (0, R.useMemo)(() => qj(s.data), [s.data]), u = (0, R.useMemo)(() => new Set((c.data?.providers || []).filter((e) => e.present).map((e) => e.provider)), [c.data]), d = (0, R.useMemo)(() => ({
+function Pde(e) {
+ let { view: t, seed: n, revision: r, helpers: i, actions: a } = e, o = _M(t, r), s = tr(o), c = $n({
+ queryKey: vM,
+ queryFn: ({ signal: e }) => yM(e)
+ }), l = (0, R.useMemo)(() => bM(s.data), [s.data]), u = (0, R.useMemo)(() => new Set((c.data?.providers || []).filter((e) => e.present).map((e) => e.provider)), [c.data]), d = (0, R.useMemo)(() => ({
sources: l?.sources || [],
aliases: l?.author_aliases || [],
credentials: u
- }), [l, u]), f = ofe(l, t, n), p = s.isPending || s.isPlaceholderData, h = !p && !!l, g = (0, R.useMemo)(() => Yde(f.visible.flatMap(Yj).map((e) => ({ tags: e.tags || [] }))), [f.visible]);
+ }), [l, u]), f = Nde(l, t, n), p = s.isPending || s.isPlaceholderData, h = !p && !!l, g = (0, R.useMemo)(() => Sde(f.visible.flatMap(SM).map((e) => ({ tags: e.tags || [] }))), [f.visible]);
(0, R.useEffect)(() => {
h && a.loaded(g);
}, [
@@ -39241,20 +39241,20 @@ function sfe(e) {
g,
a
]);
- let _ = cfe(e, !!l);
- if (!l) return s.isError ? /* @__PURE__ */ (0, z.jsx)(vb, {
+ let _ = Fde(e, !!l);
+ if (!l) return s.isError ? /* @__PURE__ */ (0, z.jsx)(sb, {
message: m(s.error),
onRetry: () => void s.refetch()
}) : null;
let v = (e) => a.route({
...t,
...e
- }), y = Wde({
+ }), y = _de({
...t,
author: f.author,
provider: f.provider
}, {
- authors: new Map([...f.authorSources].map(([e, t]) => [e, sM(t, d)])),
+ authors: new Map([...f.authorSources].map(([e, t]) => [e, PM(t, d)])),
providers: f.providers,
works: f.workNames
}), b = t.status ? f.counts[t.status] || 0 : f.allCount, x = f.sources.some((e) => e.can_backfill);
@@ -39274,7 +39274,7 @@ function sfe(e) {
"data-follow-head-actions": "",
children: [/* @__PURE__ */ (0, z.jsx)(H, {
variant: "secondary",
- leadingIcon: nfe,
+ leadingIcon: kde,
"data-follow-manage": "",
onClick: a.openManage,
children: "管理关注"
@@ -39291,20 +39291,20 @@ function sfe(e) {
}) : null]
})]
}),
- /* @__PURE__ */ (0, z.jsx)(lfe, {
+ /* @__PURE__ */ (0, z.jsx)(Ide, {
facets: f,
pressed: f.author,
context: d,
props: e,
onPick: (e) => v({ author: f.author === e ? "" : e })
}),
- /* @__PURE__ */ (0, z.jsx)(ufe, {
+ /* @__PURE__ */ (0, z.jsx)(Lde, {
rows: f.workRows,
pressed: t.work,
props: e,
onPick: (e) => v({ work: t.work === e ? "" : e })
}),
- /* @__PURE__ */ (0, z.jsx)(dfe, {
+ /* @__PURE__ */ (0, z.jsx)(Rde, {
facets: f,
view: t,
total: b,
@@ -39312,9 +39312,9 @@ function sfe(e) {
props: e,
route: v
}),
- /* @__PURE__ */ (0, z.jsx)(ffe, {
+ /* @__PURE__ */ (0, z.jsx)(zde, {
conditions: y,
- onDrop: (e) => a.route(Gde(t, e)),
+ onDrop: (e) => a.route(vde(t, e)),
onClear: () => v({
author: "",
provider: "",
@@ -39322,11 +39322,11 @@ function sfe(e) {
tags: []
})
}),
- f.broken.length ? /* @__PURE__ */ (0, z.jsx)(pfe, {
+ f.broken.length ? /* @__PURE__ */ (0, z.jsx)(Bde, {
count: f.broken.length,
onManage: a.openManage
}) : null,
- /* @__PURE__ */ (0, z.jsx)(mfe, {
+ /* @__PURE__ */ (0, z.jsx)(Vde, {
pending: p,
facets: f,
data: l,
@@ -39337,19 +39337,19 @@ function sfe(e) {
"data-follow-pagination": "",
children: [l.has_more ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-follow-page-action": "",
- children: /* @__PURE__ */ (0, z.jsxs)(Pb, {
+ children: /* @__PURE__ */ (0, z.jsxs)(zb, {
entity: !0,
enabled: () => !_.busyRef.current,
load: async () => {
await s.fetchNextPage({ throwOnError: !0 });
},
- children: [/* @__PURE__ */ (0, z.jsx)(rfe, { className: "size-3.5" }), "加载更多"]
+ children: [/* @__PURE__ */ (0, z.jsx)(Ade, { className: "size-3.5" }), "加载更多"]
}, s.data?.pages.length)
}) : null, x ? /* @__PURE__ */ (0, z.jsxs)("span", {
"data-follow-page-action": "",
children: [/* @__PURE__ */ (0, z.jsx)(H, {
variant: "secondary",
- leadingIcon: _.olderBusy ? void 0 : ife,
+ leadingIcon: _.olderBusy ? void 0 : jde,
"data-follow-older": "",
"aria-busy": _.busy || void 0,
onClick: () => void _.start(!0),
@@ -39359,14 +39359,14 @@ function sfe(e) {
}), /* @__PURE__ */ (0, z.jsx)("span", { children: "抓取中…" })] }) : "抓更早的一页"
}), /* @__PURE__ */ (0, z.jsx)("span", {
"data-follow-backfill": "",
- children: Hde(f.sources)
+ children: hde(f.sources)
})]
}) : null]
}) : null
]
})] });
}
-function cfe(e, t) {
+function Fde(e, t) {
let { helpers: n, actions: r } = e, [i, a] = (0, R.useState)(0), [o, s] = (0, R.useState)(!1), [c, l] = (0, R.useState)(""), [u, d] = (0, R.useState)(!1), f = (0, R.useRef)(!1), p = (0, R.useRef)(null), h = (0, R.useRef)({
helpers: n,
actions: r
@@ -39381,7 +39381,7 @@ function cfe(e, t) {
return h.current.helpers.jobProgress({
host: e,
active: () => t,
- read: (e) => W(tj, e),
+ read: (e) => W(Oj, e),
busy: (e) => {
t && (f.current = e, s(e));
},
@@ -39406,7 +39406,7 @@ function cfe(e, t) {
f.current = !0, l(e ? "older" : "check");
let t = !1;
try {
- let n = await G(tj, e ? {
+ let n = await G(Oj, e ? {
older: !0,
background: !0
} : { background: !0 });
@@ -39424,7 +39424,7 @@ function cfe(e, t) {
olderBusy: c === "older" || u && o
};
}
-function lfe({ facets: e, pressed: t, context: n, props: r, onPick: i }) {
+function Ide({ facets: e, pressed: t, context: n, props: r, onPick: i }) {
let a = (0, R.useRef)(null);
return (0, R.useEffect)(() => {
r.helpers.wireDrag(a.current);
@@ -39441,16 +39441,16 @@ function lfe({ facets: e, pressed: t, context: n, props: r, onPick: i }) {
onClick: () => i(r),
children: [/* @__PURE__ */ (0, z.jsx)("span", {
"data-follow-ring": "",
- dangerouslySetInnerHTML: { __html: cM(a, sM(a, n)) }
+ dangerouslySetInnerHTML: { __html: FM(a, PM(a, n)) }
}), /* @__PURE__ */ (0, z.jsx)("span", {
"data-follow-name": "",
- children: sM(a, n)
+ children: PM(a, n)
})]
}, r);
})
}) : null;
}
-function ufe({ rows: e, pressed: t, props: n, onPick: r }) {
+function Lde({ rows: e, pressed: t, props: n, onPick: r }) {
let i = (0, R.useRef)(null);
return (0, R.useEffect)(() => {
n.helpers.wireDrag(i.current);
@@ -39471,13 +39471,13 @@ function ufe({ rows: e, pressed: t, props: n, onPick: r }) {
}, e[0]))
}) : null;
}
-function dfe({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
- let { helpers: o, actions: s } = i, c = (0, R.useRef)(null), u = (0, R.useRef)(null), d = (0, R.useRef)(null), f = (0, R.useRef)(null), p = (0, R.useRef)(null), m = (0, R.useRef)(null), h = !!e.mediaCounts.images || t.media === "images", g = ZO(c, d, "[data-follow-filter][aria-pressed=\"true\"]", t.status), _ = ZO(u, f, "[data-media-view][aria-pressed=\"true\"]", `${t.media}:${h}`);
+function Rde({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
+ let { helpers: o, actions: s } = i, c = (0, R.useRef)(null), u = (0, R.useRef)(null), d = (0, R.useRef)(null), f = (0, R.useRef)(null), p = (0, R.useRef)(null), m = (0, R.useRef)(null), h = !!e.mediaCounts.images || t.media === "images", g = UO(c, d, "[data-follow-filter][aria-pressed=\"true\"]", t.status), _ = UO(u, f, "[data-media-view][aria-pressed=\"true\"]", `${t.media}:${h}`);
(0, R.useEffect)(() => {
o.wireDrag(p.current), o.wireDrag(m.current), o.wireScroller(m.current);
}, [o]);
let v = [...e.providers], y = v.length + e.tagRows.length > 0, b = t.media === "images";
- return /* @__PURE__ */ (0, z.jsx)(HO, {
+ return /* @__PURE__ */ (0, z.jsx)(IO, {
label: "筛选与排序",
topLabel: h ? "媒体与关注筛选" : "关注筛选",
attrs: {
@@ -39529,7 +39529,7 @@ function dfe({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
dangerouslySetInnerHTML: { __html: l(i) }
}, e);
})
- }), /* @__PURE__ */ (0, z.jsx)(vM, {})] }) : null, /* @__PURE__ */ (0, z.jsxs)("div", {
+ }), /* @__PURE__ */ (0, z.jsx)(GM, {})] }) : null, /* @__PURE__ */ (0, z.jsxs)("div", {
ref: p,
"data-entity-scroll": "",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
@@ -39538,7 +39538,7 @@ function dfe({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
"aria-label": "状态",
"data-entity-states": "",
onPointerLeave: g.leave,
- children: [Fde.map(([e, n]) => /* @__PURE__ */ (0, z.jsx)("button", {
+ children: [cde.map(([e, n]) => /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-entity-state": e,
"data-follow-filter": e,
@@ -39549,7 +39549,7 @@ function dfe({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
t.status !== e && a({ status: e });
},
children: n
- }, e)), y ? /* @__PURE__ */ (0, z.jsx)(vM, {}) : null]
+ }, e)), y ? /* @__PURE__ */ (0, z.jsx)(GM, {}) : null]
}), /* @__PURE__ */ (0, z.jsxs)("div", {
ref: m,
"data-entity-tags": "",
@@ -39562,13 +39562,13 @@ function dfe({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
title: n,
"aria-label": `来源:${n}`,
onClick: () => a({ provider: e.provider === t ? "" : t }),
- dangerouslySetInnerHTML: { __html: oM(t) }
+ dangerouslySetInnerHTML: { __html: NM(t) }
}, t)),
- v.length && e.tagRows.length ? /* @__PURE__ */ (0, z.jsx)(vM, {}) : null,
- e.tagRows.map(([n, r]) => /* @__PURE__ */ (0, z.jsxs)(UO, {
+ v.length && e.tagRows.length ? /* @__PURE__ */ (0, z.jsx)(GM, {}) : null,
+ e.tagRows.map(([n, r]) => /* @__PURE__ */ (0, z.jsxs)(LO, {
"data-follow-tag": n,
"data-entity-press": "",
- "data-tag-cat": `r34-${Kde(e.groups, n)}`,
+ "data-tag-cat": `r34-${yde(e.groups, n)}`,
pressed: t.tags.includes(n),
onPress: () => a({ tags: t.tags.includes(n) ? t.tags.filter((e) => e !== n) : [...t.tags, n] }),
children: [o.tagLabel(n), r ? /* @__PURE__ */ (0, z.jsx)("span", {
@@ -39586,11 +39586,11 @@ function dfe({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
}), /* @__PURE__ */ (0, z.jsxs)("span", {
"data-entity-sorts": "",
children: [
- /* @__PURE__ */ (0, z.jsx)(sk, { onPress: s.shuffle }),
- b ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(ok, {
+ /* @__PURE__ */ (0, z.jsx)($O, { onPress: s.shuffle }),
+ b ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(QO, {
label: "图片布局",
value: i.photoLayout,
- options: afe,
+ options: Mde,
onChange: (e) => s.setPhotoLayout(e === "fixed" ? "fixed" : "masonry")
}), /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
@@ -39607,7 +39607,7 @@ function dfe({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
dangerouslySetInnerHTML: { __html: l("captions-off") }
})]
})] }) : null,
- Ide.map(([e, n]) => {
+ lde.map(([e, n]) => {
let r = t.sort === e, i = Ob(t.dir === "asc" ? "arrow-up" : "arrow-down");
return /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
@@ -39615,9 +39615,9 @@ function dfe({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
"data-follow-sort": e,
"data-entity-press": "",
"aria-pressed": r,
- "aria-label": Ude(e, n, t.sort, t.dir) || void 0,
+ "aria-label": gde(e, n, t.sort, t.dir) || void 0,
onClick: () => {
- let n = nM(e, t.sort, t.dir);
+ let n = kM(e, t.sort, t.dir);
n && a(n);
},
children: [n, r ? /* @__PURE__ */ (0, z.jsx)(i, { className: "size-3.5" }) : null]
@@ -39627,7 +39627,7 @@ function dfe({ facets: e, view: t, total: n, busy: r, props: i, route: a }) {
})] })
});
}
-function ffe({ conditions: e, onDrop: t, onClear: n }) {
+function zde({ conditions: e, onDrop: t, onClear: n }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-entity-combo": "",
"data-follow-combo": "",
@@ -39652,7 +39652,7 @@ function ffe({ conditions: e, onDrop: t, onClear: n }) {
})] }) : null
});
}
-function pfe({ count: e, onManage: t }) {
+function Bde({ count: e, onManage: t }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-follow-broken": "",
onClick: (e) => {
@@ -39661,12 +39661,12 @@ function pfe({ count: e, onManage: t }) {
dangerouslySetInnerHTML: { __html: `<div class="geist-note geist-note-error fwarn" role="alert">${l("alert")}<span>${e} 个来源上次检查失败,去<button type="button" class="flink" data-follow-manage>管理关注</button>看原因。</span></div>` }
});
}
-function mfe({ pending: e, facets: t, data: n, context: r, props: i }) {
- let { view: a, helpers: o } = i, s = a.media === "images", c = _b(e, () => o.listSkeletonHtml(a.media));
+function Vde({ pending: e, facets: t, data: n, context: r, props: i }) {
+ let { view: a, helpers: o } = i, s = a.media === "images", c = ob(e, () => o.listSkeletonHtml(a.media));
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-follow-list-body": "",
"data-grid-reveal": c.fading ? "" : void 0,
- children: [c.layer, e ? null : /* @__PURE__ */ (0, z.jsx)(hfe, {
+ children: [c.layer, e ? null : /* @__PURE__ */ (0, z.jsx)(Hde, {
facets: t,
data: n,
context: r,
@@ -39675,39 +39675,39 @@ function mfe({ pending: e, facets: t, data: n, context: r, props: i }) {
})]
});
}
-function hfe({ facets: e, data: t, context: n, props: r, images: i }) {
- let { view: a, helpers: o, actions: s } = r, c = vfe(r), l = i ? {
+function Hde({ facets: e, data: t, context: n, props: r, images: i }) {
+ let { view: a, helpers: o, actions: s } = r, c = Gde(r), l = i ? {
"data-size": r.photoSize,
"data-layout": r.photoLayout,
"data-images-only": String(r.imagesOnly)
} : {}, u;
return u = e.visible.length ? e.visible.map((t) => {
let i = e.byId.get(t.primary?.source_id), l = i?.author_key && e.authorSources.get(i.author_key) || [], u = t.primary.id;
- return /* @__PURE__ */ (0, z.jsx)(tfe, {
+ return /* @__PURE__ */ (0, z.jsx)(Ode, {
group: t,
authorSources: l,
media: a.media,
context: n,
- selected: r.selected.has(yM(t, a)),
+ selected: r.selected.has(KM(t, a)),
selectMode: r.selectMode,
- busy: c.busy.get(yM(t, a)) || "",
- failure: c.failures.get(yM(t, a)) || "",
+ busy: c.busy.get(KM(t, a)) || "",
+ failure: c.failures.get(KM(t, a)) || "",
helpers: o,
actions: s,
onStatus: c.status,
onSave: c.save
}, `${u}:${a.media}`);
- }) : /* @__PURE__ */ (0, z.jsx)(gfe, { data: t }), /* @__PURE__ */ (0, z.jsx)("div", {
+ }) : /* @__PURE__ */ (0, z.jsx)(Ude, { data: t }), /* @__PURE__ */ (0, z.jsx)("div", {
"data-follow-list": "",
"data-follow-wall": i ? "" : void 0,
...l,
children: u
});
}
-function yM(e, t) {
- return $j(e, t.media).id;
+function KM(e, t) {
+ return EM(e, t.media).id;
}
-function gfe({ data: e }) {
+function Ude({ data: e }) {
let t = (e.groups || []).length ? C("search-x", "当前筛选下没有更新", "切换媒体类型、创作者、来源或标签后再试。") : (e.sources || []).length ? C("rss", "没有符合条件的更新", "切换状态或来源筛选后再试。") : C("rss", "还没有关注任何来源", "添加创作者或订阅来源后,更新会集中显示在这里。", { actions: "<a class=\"geist-button primary\" href=\"/follow-manage?tab=add\">添加关注</a>" });
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-follow-empty": "",
@@ -39715,22 +39715,22 @@ function gfe({ data: e }) {
dangerouslySetInnerHTML: { __html: t }
});
}
-var _fe = {
+var Wde = {
new: "已恢复未看",
seen: "已标记已看",
ignored: "已忽略"
};
-function vfe(e) {
- let { view: t, revision: n, actions: r } = e, [i, a] = (0, R.useState)(() => /* @__PURE__ */ new Map()), [o, s] = (0, R.useState)(() => /* @__PURE__ */ new Map()), c = Wj(t, n).queryKey, l = (e, t, n) => n((n) => {
+function Gde(e) {
+ let { view: t, revision: n, actions: r } = e, [i, a] = (0, R.useState)(() => /* @__PURE__ */ new Map()), [o, s] = (0, R.useState)(() => /* @__PURE__ */ new Map()), c = _M(t, n).queryKey, l = (e, t, n) => n((n) => {
let r = new Map(n);
return t ? r.set(e, t) : r.delete(e), r;
}), u = (e, n) => {
- X.setQueryData(c, (r) => r && rM(r, t, e, n));
+ X.setQueryData(c, (r) => r && AM(r, t, e, n));
}, d = () => void X.invalidateQueries({
queryKey: c,
exact: !0
}), f = (e) => {
- let t = qj(X.getQueryData(c));
+ let t = bM(X.getQueryData(c));
for (let n of t?.groups || []) for (let t of [
n.primary,
...n.variants,
@@ -39738,13 +39738,13 @@ function vfe(e) {
]) if (t.id === e) return t.status;
return "new";
}, p = er({
- mutationFn: ({ id: e, to: t }) => G(aj, {
+ mutationFn: ({ id: e, to: t }) => G(Mj, {
item: e,
to: t
}),
onSuccess: (e, { id: t, to: n, was: i }) => {
- u(t, n), d(), r.toast(_fe[n] || "已更新关注状态", { undo: i === "saved" ? void 0 : async () => {
- await G(aj, {
+ u(t, n), d(), r.toast(Wde[n] || "已更新关注状态", { undo: i === "saved" ? void 0 : async () => {
+ await G(Mj, {
item: t,
to: i
}), u(t, i), d();
@@ -39789,8 +39789,8 @@ function vfe(e) {
}
//#endregion
//#region src/react/follow-manage/source-view.tsx
-function bM({ provider: e, label: t }) {
- let n = Bj(e), [r, i] = (0, R.useState)(!1);
+function qM({ provider: e, label: t }) {
+ let n = pM(e), [r, i] = (0, R.useState)(!1);
return !n || r ? t ? /* @__PURE__ */ (0, z.jsx)(z.Fragment, { children: t }) : null : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("img", {
src: n,
alt: "",
@@ -39801,8 +39801,8 @@ function bM({ provider: e, label: t }) {
className: "size-3.5 shrink-0 rounded-sm object-contain"
}), t ? /* @__PURE__ */ (0, z.jsx)(ju, { children: t }) : null] });
}
-function xM({ group: e, name: t }) {
- let { src: n, fallback: r } = xj(e), [i, a] = (0, R.useState)(0), o = [n, r].filter(Boolean)[i];
+function JM({ group: e, name: t }) {
+ let { src: n, fallback: r } = Jj(e), [i, a] = (0, R.useState)(0), o = [n, r].filter(Boolean)[i];
return o ? /* @__PURE__ */ (0, z.jsx)("img", {
src: o,
alt: "",
@@ -39815,18 +39815,18 @@ function xM({ group: e, name: t }) {
}) : /* @__PURE__ */ (0, z.jsx)("span", {
title: "没有可用头像",
className: "inline-grid size-8 shrink-0 place-items-center rounded-full bg-background-tertiary-default text-caption-1-semibold text-text-secondary",
- children: bj(t)
+ children: qj(t)
});
}
-function SM({ source: e }) {
- let t = mj(e) ? "rose" : e.enabled && e.last_status === "ok" ? "lime" : e.enabled ? "yellow" : "neutral";
+function YM({ source: e }) {
+ let t = Vj(e) ? "rose" : e.enabled && e.last_status === "ok" ? "lime" : e.enabled ? "yellow" : "neutral";
return /* @__PURE__ */ (0, z.jsx)(zi, {
variant: "caption",
color: t,
- children: mde(e)
+ children: Vue(e)
});
}
-function CM({ source: e }) {
+function XM({ source: e }) {
return /* @__PURE__ */ (0, z.jsx)("a", {
href: e.url,
target: "_blank",
@@ -39838,8 +39838,8 @@ function CM({ source: e }) {
}
//#endregion
//#region src/react/follow-manage/add-source.tsx
-var wM = Ii(uy, dy, "text-body-2-medium"), yfe = "粘贴来源链接,或输入创作者名、id…", bfe = "查找中…(首次按名字查要下载创作者索引,可能几十秒)", xfe = "识别中…", Sfe = "站内没有查到来源", TM = (e, t) => `${e}:${t.url}`;
-function Cfe({ field: e, menu: t, options: n, active: r, busy: i, onPick: a, onClose: o }) {
+var ZM = Ii(hy, gy, "text-body-2-medium"), Kde = "粘贴来源链接,或输入创作者名、id…", qde = "查找中…(首次按名字查要下载创作者索引,可能几十秒)", Jde = "识别中…", Yde = "站内没有查到来源", QM = (e, t) => `${e}:${t.url}`;
+function Xde({ field: e, menu: t, options: n, active: r, busy: i, onPick: a, onClose: o }) {
return (0, R.useEffect)(() => {
t.current?.querySelector("[aria-current=\"true\"]")?.scrollIntoView({ block: "nearest" });
}, [t, r]), /* @__PURE__ */ (0, z.jsxs)(zh, {
@@ -39854,7 +39854,7 @@ function Cfe({ field: e, menu: t, options: n, active: r, busy: i, onPick: a, onC
placement: "bottom start",
offset: 4,
"aria-label": "来源建议",
- className: Ii(ly, "flex w-(--trigger-width) flex-col gap-1 overscroll-contain"),
+ className: Ii(my, "flex w-(--trigger-width) flex-col gap-1 overscroll-contain"),
children: [i && !n.length ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "px-2 py-1.5",
children: /* @__PURE__ */ (0, z.jsx)(ea, { label: "正在查找建议" })
@@ -39864,7 +39864,7 @@ function Cfe({ field: e, menu: t, options: n, active: r, busy: i, onPick: a, onC
}), /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
"aria-current": t === r ? "true" : void 0,
- className: t === r ? Ii(wM, "bg-background-secondary-default") : wM,
+ className: t === r ? Ii(ZM, "bg-background-secondary-default") : ZM,
onMouseDown: (e) => e.preventDefault(),
onClick: () => a(e.value),
children: [
@@ -39884,7 +39884,7 @@ function Cfe({ field: e, menu: t, options: n, active: r, busy: i, onPick: a, onC
})] }, `${e.group}-${e.value}`))]
});
}
-function wfe({ credentials: e, hidden: t, onHidden: n, openCredentials: r }) {
+function Zde({ credentials: e, hidden: t, onHidden: n, openCredentials: r }) {
let i = (0, R.useRef)(null), [a, o] = (0, R.useState)(!1), s = (e.providers || []).filter((e) => e.followable), c = s.filter((e) => !t.has(e.provider_label)).length, l = c === s.length ? "全部来源" : `${c}/${s.length} 个来源`, u = (e, r) => {
let i = new Set(t);
r ? i.delete(e) : i.add(e), n(i);
@@ -39904,8 +39904,8 @@ function wfe({ credentials: e, hidden: t, onHidden: n, openCredentials: r }) {
onOpenChange: o,
placement: "bottom end",
offset: 4,
- className: ly,
- children: /* @__PURE__ */ (0, z.jsxs)(Fg, {
+ className: my,
+ children: /* @__PURE__ */ (0, z.jsxs)(Ig, {
"aria-label": "来源筛选",
className: "flex w-64 flex-col gap-1 outline-none",
children: [s.length ? /* @__PURE__ */ (0, z.jsxs)("div", {
@@ -39921,16 +39921,16 @@ function wfe({ credentials: e, hidden: t, onHidden: n, openCredentials: r }) {
onClick: () => n(new Set(s.map((e) => e.provider_label))),
children: "全不选"
})]
- }) : /* @__PURE__ */ (0, z.jsx)(wy, { children: "暂无可用来源" }), s.map((e) => {
+ }) : /* @__PURE__ */ (0, z.jsx)(ky, { children: "暂无可用来源" }), s.map((e) => {
let n = e.requirement === "required" && (!e.present || (e.missing || []).length > 0);
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex items-center gap-2",
- children: [/* @__PURE__ */ (0, z.jsx)(SO, {
+ children: [/* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: !t.has(e.provider_label),
onChange: (t) => u(e.provider_label, t),
children: /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 items-center gap-1.5",
- children: [/* @__PURE__ */ (0, z.jsx)(bM, { provider: e.provider }), e.provider_label]
+ children: [/* @__PURE__ */ (0, z.jsx)(qM, { provider: e.provider }), e.provider_label]
})
}), n ? /* @__PURE__ */ (0, z.jsx)(H, {
variant: "ghost",
@@ -39946,7 +39946,7 @@ function wfe({ credentials: e, hidden: t, onHidden: n, openCredentials: r }) {
})
})] });
}
-function Tfe({ row: e, at: t, hidden: n, unpicked: r, onPick: i }) {
+function Qde({ row: e, at: t, hidden: n, unpicked: r, onPick: i }) {
if (e.kind === "error") return /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
title: e.line,
@@ -39965,15 +39965,15 @@ function Tfe({ row: e, at: t, hidden: n, unpicked: r, onPick: i }) {
children: e.line
}),
a.length ? a.map((e) => {
- let n = TM(t, e);
- return /* @__PURE__ */ (0, z.jsx)(SO, {
+ let n = QM(t, e);
+ return /* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: !e.known && !r.has(n),
isDisabled: e.known,
onChange: (e) => i(n, e),
children: /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 flex-wrap items-center gap-1.5",
children: [
- /* @__PURE__ */ (0, z.jsx)(bM, { provider: e.provider }),
+ /* @__PURE__ */ (0, z.jsx)(qM, { provider: e.provider }),
/* @__PURE__ */ (0, z.jsx)("b", {
className: "text-body-medium",
children: e.provider_label
@@ -39989,22 +39989,22 @@ function Tfe({ row: e, at: t, hidden: n, unpicked: r, onPick: i }) {
]
})
}, n);
- }) : /* @__PURE__ */ (0, z.jsx)(wy, { children: Sfe }),
+ }) : /* @__PURE__ */ (0, z.jsx)(ky, { children: Yde }),
(e.external_searches || []).map((e) => /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center gap-2",
children: [/* @__PURE__ */ (0, z.jsx)("small", {
className: "text-caption-1-regular text-text-secondary",
children: e.evidence
- }), /* @__PURE__ */ (0, z.jsx)(Dy, {
+ }), /* @__PURE__ */ (0, z.jsx)(My, {
href: e.url,
children: `${e.label}:${e.query}`
})]
}, e.url)),
- o.length ? /* @__PURE__ */ (0, z.jsx)(wy, { children: o.map(([e, t]) => `${e}:${t}`).join(";") }) : null
+ o.length ? /* @__PURE__ */ (0, z.jsx)(ky, { children: o.map(([e, t]) => `${e}:${t}`).join(";") }) : null
]
});
}
-function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials: i }) {
+function $de({ data: e, credentials: t, readOnly: n, toast: r, openCredentials: i }) {
let [a, o] = (0, R.useState)(""), [s, c] = (0, R.useState)(""), [l, u] = (0, R.useState)(""), [d, f] = (0, R.useState)(!1), [p, m] = (0, R.useState)(null), [h, g] = (0, R.useState)(-1), _ = (0, R.useRef)(null), v = (0, R.useRef)(null), [y, b] = (0, R.useState)(/* @__PURE__ */ new Set()), [x, S] = (0, R.useState)(/* @__PURE__ */ new Set()), [C, w] = (0, R.useState)(""), [T, E] = (0, R.useState)(0);
(0, R.useEffect)(() => {
let e = a.trim();
@@ -40016,18 +40016,18 @@ function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials:
return () => clearTimeout(t);
}, [a]);
let D = $n({
- queryKey: cde(l),
- queryFn: ({ signal: e }) => bde(l, e),
+ queryKey: Fue(l),
+ queryFn: ({ signal: e }) => que(l, e),
enabled: l.length > 0 && d
}), O = (0, R.useMemo)(() => (D.data?.groups || []).flatMap((e) => e.items.map((t) => ({
value: t.value,
matched: t.matched || "",
n: t.n || 0,
group: e.label
- }))), [D.data]), { job: k, running: A, outcome: j, start: M, dismiss: N } = vO({
- queryKey: sde,
- queryFn: ({ signal: e }) => yde(e),
- start: (e) => xde([e]),
+ }))), [D.data]), { job: k, running: A, outcome: j, start: M, dismiss: N } = pO({
+ queryKey: Pue,
+ queryFn: ({ signal: e }) => Kue(e),
+ start: (e) => Jue([e]),
onStarted: () => S(/* @__PURE__ */ new Set()),
onError: (e) => w(U(e)),
onFinish: (e) => {
@@ -40061,14 +40061,14 @@ function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials:
}
}, ne = j?.results || [], re = ne.flatMap((e, t) => (e.candidates || []).filter((e) => !e.known && !y.has(e.provider_label || "")).map((e) => ({
candidate: e,
- key: TM(t, e)
+ key: QM(t, e)
})).filter((e) => !x.has(e.key))), ie = er({
mutationFn: async (e) => {
let t = [], n = [];
E(0);
for (let r of e) {
try {
- let e = await Sde(r.candidate);
+ let e = await Yue(r.candidate);
n.push(e.source);
} catch (e) {
t.push(`${r.candidate.label}:${U(e)}`);
@@ -40076,7 +40076,7 @@ function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials:
E((e) => e + 1);
}
if (n.length) try {
- await Oj(n);
+ await tM(n);
} catch (e) {
t.push(U(e));
}
@@ -40086,7 +40086,7 @@ function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials:
};
},
onSuccess: (e) => {
- if (Rj(), e.failures.length) {
+ if (dM(), e.failures.length) {
w(e.failures.join(";"));
return;
}
@@ -40115,15 +40115,15 @@ function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials:
let t = e.relatedTarget;
!e.currentTarget.contains(t) && !v.current?.contains(t) && f(!1);
},
- children: [/* @__PURE__ */ (0, z.jsx)(cy, {
+ children: [/* @__PURE__ */ (0, z.jsx)(py, {
"aria-label": "来源链接、名字或 id",
- placeholder: yfe,
+ placeholder: Kde,
value: a,
leadingIcon: gt,
isDisabled: n,
onChange: o,
onKeyDown: te
- }), F ? /* @__PURE__ */ (0, z.jsx)(Cfe, {
+ }), F ? /* @__PURE__ */ (0, z.jsx)(Xde, {
field: _,
menu: v,
options: O,
@@ -40133,7 +40133,7 @@ function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials:
onClose: I
}) : null]
}),
- /* @__PURE__ */ (0, z.jsx)(wfe, {
+ /* @__PURE__ */ (0, z.jsx)(Zde, {
credentials: t,
hidden: y,
onHidden: b,
@@ -40151,9 +40151,9 @@ function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials:
/* @__PURE__ */ (0, z.jsxs)("div", {
"aria-live": "polite",
className: "flex flex-col gap-3 empty:hidden",
- children: [A || M.isPending ? /* @__PURE__ */ (0, z.jsx)(mO, {
+ children: [A || M.isPending ? /* @__PURE__ */ (0, z.jsx)(lO, {
embedded: !0,
- label: k?.message || (k?.total ? `查找中:${k.checked || 0}/${k.total}` : oe ? bfe : xfe),
+ label: k?.message || (k?.total ? `查找中:${k.checked || 0}/${k.total}` : oe ? qde : Jde),
value: k?.checked,
total: k?.total
}) : null, C ? /* @__PURE__ */ (0, z.jsx)(K, {
@@ -40165,8 +40165,8 @@ function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials:
ne.length ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-3",
children: [
- /* @__PURE__ */ (0, z.jsx)(Ey, { children: "查找结果" }),
- ne.map((e, t) => /* @__PURE__ */ (0, z.jsx)(Tfe, {
+ /* @__PURE__ */ (0, z.jsx)(jy, { children: "查找结果" }),
+ ne.map((e, t) => /* @__PURE__ */ (0, z.jsx)(Qde, {
row: e,
at: t,
hidden: y,
@@ -40221,16 +40221,16 @@ function Efe({ data: e, credentials: t, readOnly: n, toast: r, openCredentials:
}
//#endregion
//#region src/react/follow-manage/alias-manager.tsx
-var Dfe = (e) => `将移除别名「${e}」,对应来源恢复为独立创作者组。`, EM = (e) => e.alias;
-function Ofe(e, t, n) {
+var efe = (e) => `将移除别名「${e}」,对应来源恢复为独立创作者组。`, $M = (e) => e.alias;
+function tfe(e, t, n) {
let r = n ? `name:${n}` : "", i = r ? e.find((e) => e.author_key === r) : e.find((e) => e.author_name === t || e.entity_name === t);
return i ? e.filter((e) => e.author_key === i.author_key) : [];
}
-function DM({ sources: e, name: t, canonicalKey: n }) {
+function eN({ sources: e, name: t, canonicalKey: n }) {
return /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex items-center gap-2",
- children: [/* @__PURE__ */ (0, z.jsx)(xM, {
- group: Ofe(e, t, n),
+ children: [/* @__PURE__ */ (0, z.jsx)(JM, {
+ group: tfe(e, t, n),
name: t
}), /* @__PURE__ */ (0, z.jsx)("b", {
className: "text-body-medium",
@@ -40238,15 +40238,15 @@ function DM({ sources: e, name: t, canonicalKey: n }) {
})]
});
}
-function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i }) {
+function nfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i }) {
let [a, o] = (0, R.useState)(/* @__PURE__ */ new Set()), [s, c] = (0, R.useState)(""), [l, u] = (0, R.useState)(""), [d, f] = (0, R.useState)(""), p = er({
mutationFn: async (e) => {
let t = 0;
for (let n of e) {
try {
- await jj(n.canonical, n.alias);
+ await iM(n.canonical, n.alias);
} catch (n) {
- throw t && Rj(), Error(`${U(n)}(还有 ${e.length - t} 组没有合并)`);
+ throw t && dM(), Error(`${U(n)}(还有 ${e.length - t} 组没有合并)`);
}
t += 1;
}
@@ -40256,19 +40256,19 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
};
},
onSuccess: (e) => {
- c(""), o(/* @__PURE__ */ new Set()), Rj(), i(`已合并 ${e.done} 组创作者别名`);
+ c(""), o(/* @__PURE__ */ new Set()), dM(), i(`已合并 ${e.done} 组创作者别名`);
},
onError: (e) => c(U(e))
}), m = er({
- mutationFn: (e) => jj(e.canonical, e.alias),
+ mutationFn: (e) => iM(e.canonical, e.alias),
onSuccess: () => {
- c(""), u(""), f(""), Rj(), i("已保存创作者别名");
+ c(""), u(""), f(""), dM(), i("已保存创作者别名");
},
onError: (e) => c(U(e))
}), h = er({
- mutationFn: (e) => Cde(e),
+ mutationFn: (e) => Xue(e),
onSuccess: () => {
- c(""), Rj(), i("已移除创作者别名");
+ c(""), dM(), i("已移除创作者别名");
},
onError: (e) => c(U(e))
}), g = (e, t) => {
@@ -40278,7 +40278,7 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
confirmLabel: t ? "合并全部别名" : "合并所选别名",
onConfirm: () => p.mutateAsync(e)
});
- }, _ = t.filter((e) => a.has(EM(e))), v = t.length > 0 && _.length === t.length, y = q(p.isPending);
+ }, _ = t.filter((e) => a.has($M(e))), v = t.length > 0 && _.length === t.length, y = q(p.isPending);
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: Zi({
padding: "none",
@@ -40291,10 +40291,10 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-2",
- children: [/* @__PURE__ */ (0, z.jsx)(Ey, { children: "手动添加别名" }), /* @__PURE__ */ (0, z.jsxs)("div", {
+ children: [/* @__PURE__ */ (0, z.jsx)(jy, { children: "手动添加别名" }), /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-end gap-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
"aria-label": "规范创作者名",
placeholder: "规范创作者名",
value: l,
@@ -40302,7 +40302,7 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
isDisabled: r,
className: "w-56"
}),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
"aria-label": "平台别名",
placeholder: "平台别名",
value: d,
@@ -40323,13 +40323,13 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
]
})]
}),
- s ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: s }) : null,
+ s ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: s }) : null,
t.length ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-2",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center gap-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(Ey, { children: "待合并" }),
+ /* @__PURE__ */ (0, z.jsx)(jy, { children: "待合并" }),
/* @__PURE__ */ (0, z.jsx)("span", {
className: "mr-auto text-body-2-regular text-text-secondary",
children: `${t.length} 组`
@@ -40351,44 +40351,44 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
children: `全部合并(${t.length})`
})
]
- }), /* @__PURE__ */ (0, z.jsx)(TO, { children: /* @__PURE__ */ (0, z.jsxs)(CO, {
+ }), /* @__PURE__ */ (0, z.jsx)(bO, { children: /* @__PURE__ */ (0, z.jsxs)(vO, {
"aria-label": "待合并创作者别名",
size: "sm",
- children: [/* @__PURE__ */ (0, z.jsxs)(Iv, { children: [
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(Wv, { children: [
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "select",
- children: /* @__PURE__ */ (0, z.jsx)(SO, {
+ children: /* @__PURE__ */ (0, z.jsx)(_O, {
slot: null,
isSelected: v,
isIndeterminate: _.length > 0 && !v,
"aria-label": "全选待合并别名",
- onChange: (e) => o(e ? new Set(t.map(EM)) : /* @__PURE__ */ new Set())
+ onChange: (e) => o(e ? new Set(t.map($M)) : /* @__PURE__ */ new Set())
})
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "canonical",
children: "规范创作者"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "alias",
isRowHeader: !0,
children: "平台别名"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "evidence",
children: "依据"
}),
- /* @__PURE__ */ (0, z.jsx)(zv, {
+ /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "actions",
children: "操作"
})
- ] }), /* @__PURE__ */ (0, z.jsx)(Vv, { children: t.map((e) => {
- let t = EM(e);
- return /* @__PURE__ */ (0, z.jsxs)(Wv, {
+ ] }), /* @__PURE__ */ (0, z.jsx)(Jv, { children: t.map((e) => {
+ let t = $M(e);
+ return /* @__PURE__ */ (0, z.jsxs)(Zv, {
id: t,
"data-board-selected": a.has(t) || void 0,
children: [
- /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsx)(SO, {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsx)(_O, {
slot: null,
isSelected: a.has(t),
"aria-label": `选择别名 ${e.alias},归入 ${e.canonical}`,
@@ -40397,16 +40397,16 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
e ? n.add(t) : n.delete(t), o(n);
}
}) }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsx)(DM, {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsx)(eN, {
sources: n,
name: e.canonical
}) }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: e.alias }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsx)("span", {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: e.alias }),
+ /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsx)("span", {
className: "text-body-2-regular text-text-secondary",
children: e.evidence
}) }),
- /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsx)(H, {
+ /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsx)(H, {
variant: "secondary",
size: "small",
disabled: r,
@@ -40423,27 +40423,27 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
className: "flex flex-col gap-2",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center gap-2",
- children: [/* @__PURE__ */ (0, z.jsx)(Ey, { children: "已保存别名" }), /* @__PURE__ */ (0, z.jsx)("span", {
+ children: [/* @__PURE__ */ (0, z.jsx)(jy, { children: "已保存别名" }), /* @__PURE__ */ (0, z.jsx)("span", {
className: "text-body-2-regular text-text-secondary",
children: `${e.length} 组`
})]
- }), e.length ? /* @__PURE__ */ (0, z.jsx)(TO, { children: /* @__PURE__ */ (0, z.jsxs)(CO, {
+ }), e.length ? /* @__PURE__ */ (0, z.jsx)(bO, { children: /* @__PURE__ */ (0, z.jsxs)(vO, {
"aria-label": "已保存创作者别名",
size: "sm",
- children: [/* @__PURE__ */ (0, z.jsxs)(Iv, { children: [/* @__PURE__ */ (0, z.jsx)(zv, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(Wv, { children: [/* @__PURE__ */ (0, z.jsx)(Kv, {
id: "canonical",
isRowHeader: !0,
children: "规范创作者"
- }), /* @__PURE__ */ (0, z.jsx)(zv, {
+ }), /* @__PURE__ */ (0, z.jsx)(Kv, {
id: "aliases",
children: "平台别名"
- })] }), /* @__PURE__ */ (0, z.jsx)(Vv, { children: e.map((e) => /* @__PURE__ */ (0, z.jsxs)(Wv, {
+ })] }), /* @__PURE__ */ (0, z.jsx)(Jv, { children: e.map((e) => /* @__PURE__ */ (0, z.jsxs)(Zv, {
id: e.canonical_key,
- children: [/* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsx)(DM, {
+ children: [/* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsx)(eN, {
sources: n,
name: e.canonical_name,
canonicalKey: e.canonical_key
- }) }), /* @__PURE__ */ (0, z.jsx)(qv, { children: /* @__PURE__ */ (0, z.jsx)("span", {
+ }) }), /* @__PURE__ */ (0, z.jsx)($v, { children: /* @__PURE__ */ (0, z.jsx)("span", {
className: "flex flex-wrap items-center gap-1.5",
children: e.aliases.map((e) => /* @__PURE__ */ (0, z.jsxs)("span", {
className: "inline-flex items-center gap-1 rounded-md bg-background-secondary-default px-1.5 py-1 text-caption-1-medium text-text-secondary",
@@ -40457,7 +40457,7 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
...q(h.isPending),
onClick: () => void b({
title: "移除创作者别名",
- body: Dfe(e.name),
+ body: efe(e.name),
confirmLabel: "移除创作者别名",
onConfirm: () => h.mutateAsync(e.name)
})
@@ -40477,12 +40477,12 @@ function kfe({ groups: e, suggestions: t, sources: n = [], readOnly: r, toast: i
}
//#endregion
//#region src/react/follow-manage/credentials.tsx
-var Afe = "这些账号信息存在哪里", jfe = "存成运行 Peach 那台电脑上的一个文件。在 Windows 上它不额外加锁,能登录那台电脑的人都能打开。", Mfe = "将清除这个来源在本机和共享副本中的登录凭据。", Nfe = "文件权限过宽。在运行 Peach 的 POSIX 主机上收紧为 0600。";
-function Pfe(e, t) {
+var rfe = "这些账号信息存在哪里", ife = "存成运行 Peach 那台电脑上的一个文件。在 Windows 上它不额外加锁,能登录那台电脑的人都能打开。", afe = "将清除这个来源在本机和共享副本中的登录凭据。", ofe = "文件权限过宽。在运行 Peach 的 POSIX 主机上收紧为 0600。";
+function sfe(e, t) {
return (e.shared_fields || []).includes(t) ? "来自共享,留空表示不改" : e.fields.includes(t) ? "已保存,留空表示不改" : "未填写";
}
-function Ffe({ row: e }) {
- if (Vj(e)) return /* @__PURE__ */ (0, z.jsx)(zi, {
+function cfe({ row: e }) {
+ if (mM(e)) return /* @__PURE__ */ (0, z.jsx)(zi, {
variant: "caption",
color: "lime",
children: "已配置"
@@ -40491,19 +40491,19 @@ function Ffe({ row: e }) {
return /* @__PURE__ */ (0, z.jsx)(zi, {
variant: "caption",
color: t,
- children: Pde[e.requirement] || ""
+ children: sde[e.requirement] || ""
});
}
-function Ife({ row: e, readOnly: t, toast: n }) {
- let [r, i] = (0, R.useState)({}), [a, o] = (0, R.useState)(""), s = Vj(e), c = er({
- mutationFn: (t) => wde(e.provider, t),
+function lfe({ row: e, readOnly: t, toast: n }) {
+ let [r, i] = (0, R.useState)({}), [a, o] = (0, R.useState)(""), s = mM(e), c = er({
+ mutationFn: (t) => Zue(e.provider, t),
onSuccess: (e, t) => {
if (e.note) {
o(e.note);
return;
}
o(""), i({}), X.invalidateQueries({
- queryKey: cj,
+ queryKey: Fj,
exact: !0
}), n(Object.keys(t).length ? "已保存来源凭据" : "已清除来源凭据");
},
@@ -40519,17 +40519,17 @@ function Ife({ row: e, readOnly: t, toast: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-3",
children: [
- /* @__PURE__ */ (0, z.jsxs)(wy, { children: [e.why, e.where ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [" ", /* @__PURE__ */ (0, z.jsx)(Dy, {
+ /* @__PURE__ */ (0, z.jsxs)(ky, { children: [e.why, e.where ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [" ", /* @__PURE__ */ (0, z.jsx)(My, {
href: e.where,
children: "去取"
})] }) : null] }),
- e.howto ? /* @__PURE__ */ (0, z.jsx)(wy, { children: e.howto }) : null,
+ e.howto ? /* @__PURE__ */ (0, z.jsx)(ky, { children: e.howto }) : null,
/* @__PURE__ */ (0, z.jsx)("div", {
className: "flex w-full flex-col gap-3",
- children: (e.needs || []).map((n) => /* @__PURE__ */ (0, z.jsx)(cy, {
+ children: (e.needs || []).map((n) => /* @__PURE__ */ (0, z.jsx)(py, {
type: "password",
label: n,
- placeholder: Pfe(e, n),
+ placeholder: sfe(e, n),
autoComplete: "off",
spellCheck: "false",
isDisabled: t,
@@ -40557,7 +40557,7 @@ function Ife({ row: e, readOnly: t, toast: n }) {
...q(c.isPending),
onClick: () => void b({
title: "清除来源凭据",
- body: Mfe,
+ body: afe,
confirmLabel: "清除来源凭据",
danger: !0,
onConfirm: () => c.mutateAsync({})
@@ -40565,9 +40565,9 @@ function Ife({ row: e, readOnly: t, toast: n }) {
children: "清除"
}) : null]
}),
- a ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: a }) : null,
- (e.shared_fields || []).length ? /* @__PURE__ */ (0, z.jsx)(wy, { children: `${e.shared_fields.join("、")} 是从共享副本回填的,本机没有单独存。清除会把两边一起删。` }) : null,
- e.path ? /* @__PURE__ */ (0, z.jsx)(pO, {
+ a ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: a }) : null,
+ (e.shared_fields || []).length ? /* @__PURE__ */ (0, z.jsx)(ky, { children: `${e.shared_fields.join("、")} 是从共享副本回填的,本机没有单独存。清除会把两边一起删。` }) : null,
+ e.path ? /* @__PURE__ */ (0, z.jsx)(cO, {
path: e.path,
className: "font-mono text-caption-1-regular text-text-tertiary",
onRevealed: n
@@ -40575,24 +40575,24 @@ function Ife({ row: e, readOnly: t, toast: n }) {
e.world_readable ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
title: "凭据文件权限过宽",
- children: Nfe
+ children: ofe
}) : null
]
});
}
-function Lfe({ row: e, readOnly: t, toast: n }) {
+function ufe({ row: e, readOnly: t, toast: n }) {
let r = /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 items-center gap-2",
children: [
/* @__PURE__ */ (0, z.jsx)("span", {
className: "inline-flex size-3.5 shrink-0 items-center justify-center",
- children: /* @__PURE__ */ (0, z.jsx)(bM, { provider: e.provider })
+ children: /* @__PURE__ */ (0, z.jsx)(qM, { provider: e.provider })
}),
/* @__PURE__ */ (0, z.jsx)("b", {
className: "text-body-medium text-text-primary",
children: e.provider_label
}),
- /* @__PURE__ */ (0, z.jsx)(Ffe, { row: e }),
+ /* @__PURE__ */ (0, z.jsx)(cfe, { row: e }),
e.missing.length ? /* @__PURE__ */ (0, z.jsx)(zi, {
variant: "caption",
color: "rose",
@@ -40602,13 +40602,13 @@ function Lfe({ row: e, readOnly: t, toast: n }) {
});
return e.requirement === "none" || e.requirement === "blocked" ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center gap-3 border-b border-separator-border px-6 py-5 last:border-b-0 max-sm:px-4",
- children: [r, e.requirement === "blocked" ? /* @__PURE__ */ (0, z.jsx)(wy, { children: e.why }) : null]
+ children: [r, e.requirement === "blocked" ? /* @__PURE__ */ (0, z.jsx)(ky, { children: e.why }) : null]
}) : /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-2 border-b border-separator-border px-6 py-5 last:border-b-0 max-sm:px-4",
- children: [r, /* @__PURE__ */ (0, z.jsx)(Ay, {
- summary: Vj(e) ? "修改凭据" : "填写凭据",
- defaultOpen: e.requirement === "required" && !Vj(e),
- children: /* @__PURE__ */ (0, z.jsx)(Ife, {
+ children: [r, /* @__PURE__ */ (0, z.jsx)(Fy, {
+ summary: mM(e) ? "修改凭据" : "填写凭据",
+ defaultOpen: e.requirement === "required" && !mM(e),
+ children: /* @__PURE__ */ (0, z.jsx)(lfe, {
row: e,
readOnly: t,
toast: n
@@ -40616,8 +40616,8 @@ function Lfe({ row: e, readOnly: t, toast: n }) {
})]
});
}
-function Rfe({ data: e, readOnly: t, toast: n }) {
- let r = e.providers || [], i = r.filter((e) => e.requirement === "required" && !Vj(e));
+function dfe({ data: e, readOnly: t, toast: n }) {
+ let r = e.providers || [], i = r.filter((e) => e.requirement === "required" && !mM(e));
return r.length ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: Zi({
padding: "none",
@@ -40659,7 +40659,7 @@ function Rfe({ data: e, readOnly: t, toast: n }) {
padding: "none",
className: "flex flex-col overflow-hidden"
}),
- children: e.rows.map((e) => /* @__PURE__ */ (0, z.jsx)(Lfe, {
+ children: e.rows.map((e) => /* @__PURE__ */ (0, z.jsx)(ufe, {
row: e,
readOnly: t,
toast: n
@@ -40671,13 +40671,13 @@ function Rfe({ data: e, readOnly: t, toast: n }) {
children: [
/* @__PURE__ */ (0, z.jsx)("b", {
className: "text-body-medium text-text-primary",
- children: Afe
+ children: rfe
}),
/* @__PURE__ */ (0, z.jsx)("span", {
className: "text-body-2-regular text-text-secondary",
- children: jfe
+ children: ife
}),
- /* @__PURE__ */ (0, z.jsx)(pO, {
+ /* @__PURE__ */ (0, z.jsx)(cO, {
path: e.root,
prefix: "凭据文件在 ",
className: "text-body-2-regular text-text-secondary",
@@ -40695,7 +40695,7 @@ function Rfe({ data: e, readOnly: t, toast: n }) {
}
//#endregion
//#region node_modules/@tanstack/table-core/build/lib/index.mjs
-function OM() {
+function tN() {
return {
accessor: (e, t) => typeof e == "function" ? {
...t,
@@ -40708,24 +40708,24 @@ function OM() {
group: (e) => e
};
}
-function kM(e, t) {
+function nN(e, t) {
return typeof e == "function" ? e(t) : e;
}
-function AM(e, t) {
+function rN(e, t) {
return (n) => {
t.setState((t) => ({
...t,
- [e]: kM(n, t[e])
+ [e]: nN(n, t[e])
}));
};
}
-function jM(e) {
+function iN(e) {
return e instanceof Function;
}
-function zfe(e) {
+function ffe(e) {
return Array.isArray(e) && e.every((e) => typeof e == "number");
}
-function Bfe(e, t) {
+function pfe(e, t) {
let n = [], r = (e) => {
e.forEach((e) => {
n.push(e);
@@ -40735,7 +40735,7 @@ function Bfe(e, t) {
};
return r(e), n;
}
-function MM(e, t, n) {
+function aN(e, t, n) {
let r = [], i;
return (a) => {
let o;
@@ -40757,21 +40757,21 @@ function MM(e, t, n) {
return i;
};
}
-function NM(e, t, n, r) {
+function oN(e, t, n, r) {
return {
debug: () => e?.debugAll ?? e[t],
key: !1,
onChange: r
};
}
-function PM(e, t, n, r) {
+function mfe(e, t, n, r) {
let i = {
id: `${t.id}_${n.id}`,
row: t,
column: n,
getValue: () => t.getValue(r),
renderValue: () => i.getValue() ?? e.options.renderFallbackValue,
- getContext: MM(() => [
+ getContext: aN(() => [
e,
n,
t,
@@ -40783,13 +40783,13 @@ function PM(e, t, n, r) {
cell: r,
getValue: r.getValue,
renderValue: r.renderValue
- }), NM(e.options, "debugCells", "cell.getContext"))
+ }), oN(e.options, "debugCells", "cell.getContext"))
};
return e._features.forEach((r) => {
r.createCell == null || r.createCell(i, n, t, e);
}, {}), i;
}
-function FM(e, t, n, r) {
+function hfe(e, t, n, r) {
let i = {
...e._getDefaultColumnDef(),
...t
@@ -40806,17 +40806,17 @@ function FM(e, t, n, r) {
depth: n,
columnDef: i,
columns: [],
- getFlatColumns: MM(() => [!0], () => [c, ...c.columns?.flatMap((e) => e.getFlatColumns())], NM(e.options, "debugColumns", "column.getFlatColumns")),
- getLeafColumns: MM(() => [e._getOrderColumnsFn()], (e) => {
+ getFlatColumns: aN(() => [!0], () => [c, ...c.columns?.flatMap((e) => e.getFlatColumns())], oN(e.options, "debugColumns", "column.getFlatColumns")),
+ getLeafColumns: aN(() => [e._getOrderColumnsFn()], (e) => {
var t;
return (t = c.columns) != null && t.length ? e(c.columns.flatMap((e) => e.getLeafColumns())) : [c];
- }, NM(e.options, "debugColumns", "column.getLeafColumns"))
+ }, oN(e.options, "debugColumns", "column.getLeafColumns"))
};
for (let t of e._features) t.createColumn == null || t.createColumn(c, e);
return c;
}
-var IM = "debugHeaders";
-function LM(e, t, n) {
+var sN = "debugHeaders";
+function cN(e, t, n) {
let r = {
id: n.id ?? t.id,
column: t,
@@ -40844,42 +40844,42 @@ function LM(e, t, n) {
t.createHeader == null || t.createHeader(r, e);
}), r;
}
-var RM = { createTable: (e) => {
- e.getHeaderGroups = MM(() => [
+var gfe = { createTable: (e) => {
+ e.getHeaderGroups = aN(() => [
e.getAllColumns(),
e.getVisibleLeafColumns(),
e.getState().columnPinning.left,
e.getState().columnPinning.right
], (t, n, r, i) => {
let a = r?.map((e) => n.find((t) => t.id === e)).filter(Boolean) ?? [], o = i?.map((e) => n.find((t) => t.id === e)).filter(Boolean) ?? [], s = n.filter((e) => !(r != null && r.includes(e.id)) && !(i != null && i.includes(e.id)));
- return zM(t, [
+ return lN(t, [
...a,
...s,
...o
], e);
- }, NM(e.options, IM, "getHeaderGroups")), e.getCenterHeaderGroups = MM(() => [
+ }, oN(e.options, sN, "getHeaderGroups")), e.getCenterHeaderGroups = aN(() => [
e.getAllColumns(),
e.getVisibleLeafColumns(),
e.getState().columnPinning.left,
e.getState().columnPinning.right
- ], (t, n, r, i) => (n = n.filter((e) => !(r != null && r.includes(e.id)) && !(i != null && i.includes(e.id))), zM(t, n, e, "center")), NM(e.options, IM, "getCenterHeaderGroups")), e.getLeftHeaderGroups = MM(() => [
+ ], (t, n, r, i) => (n = n.filter((e) => !(r != null && r.includes(e.id)) && !(i != null && i.includes(e.id))), lN(t, n, e, "center")), oN(e.options, sN, "getCenterHeaderGroups")), e.getLeftHeaderGroups = aN(() => [
e.getAllColumns(),
e.getVisibleLeafColumns(),
e.getState().columnPinning.left
- ], (t, n, r) => zM(t, r?.map((e) => n.find((t) => t.id === e)).filter(Boolean) ?? [], e, "left"), NM(e.options, IM, "getLeftHeaderGroups")), e.getRightHeaderGroups = MM(() => [
+ ], (t, n, r) => lN(t, r?.map((e) => n.find((t) => t.id === e)).filter(Boolean) ?? [], e, "left"), oN(e.options, sN, "getLeftHeaderGroups")), e.getRightHeaderGroups = aN(() => [
e.getAllColumns(),
e.getVisibleLeafColumns(),
e.getState().columnPinning.right
- ], (t, n, r) => zM(t, r?.map((e) => n.find((t) => t.id === e)).filter(Boolean) ?? [], e, "right"), NM(e.options, IM, "getRightHeaderGroups")), e.getFooterGroups = MM(() => [e.getHeaderGroups()], (e) => [...e].reverse(), NM(e.options, IM, "getFooterGroups")), e.getLeftFooterGroups = MM(() => [e.getLeftHeaderGroups()], (e) => [...e].reverse(), NM(e.options, IM, "getLeftFooterGroups")), e.getCenterFooterGroups = MM(() => [e.getCenterHeaderGroups()], (e) => [...e].reverse(), NM(e.options, IM, "getCenterFooterGroups")), e.getRightFooterGroups = MM(() => [e.getRightHeaderGroups()], (e) => [...e].reverse(), NM(e.options, IM, "getRightFooterGroups")), e.getFlatHeaders = MM(() => [e.getHeaderGroups()], (e) => e.map((e) => e.headers).flat(), NM(e.options, IM, "getFlatHeaders")), e.getLeftFlatHeaders = MM(() => [e.getLeftHeaderGroups()], (e) => e.map((e) => e.headers).flat(), NM(e.options, IM, "getLeftFlatHeaders")), e.getCenterFlatHeaders = MM(() => [e.getCenterHeaderGroups()], (e) => e.map((e) => e.headers).flat(), NM(e.options, IM, "getCenterFlatHeaders")), e.getRightFlatHeaders = MM(() => [e.getRightHeaderGroups()], (e) => e.map((e) => e.headers).flat(), NM(e.options, IM, "getRightFlatHeaders")), e.getCenterLeafHeaders = MM(() => [e.getCenterFlatHeaders()], (e) => e.filter((e) => {
+ ], (t, n, r) => lN(t, r?.map((e) => n.find((t) => t.id === e)).filter(Boolean) ?? [], e, "right"), oN(e.options, sN, "getRightHeaderGroups")), e.getFooterGroups = aN(() => [e.getHeaderGroups()], (e) => [...e].reverse(), oN(e.options, sN, "getFooterGroups")), e.getLeftFooterGroups = aN(() => [e.getLeftHeaderGroups()], (e) => [...e].reverse(), oN(e.options, sN, "getLeftFooterGroups")), e.getCenterFooterGroups = aN(() => [e.getCenterHeaderGroups()], (e) => [...e].reverse(), oN(e.options, sN, "getCenterFooterGroups")), e.getRightFooterGroups = aN(() => [e.getRightHeaderGroups()], (e) => [...e].reverse(), oN(e.options, sN, "getRightFooterGroups")), e.getFlatHeaders = aN(() => [e.getHeaderGroups()], (e) => e.map((e) => e.headers).flat(), oN(e.options, sN, "getFlatHeaders")), e.getLeftFlatHeaders = aN(() => [e.getLeftHeaderGroups()], (e) => e.map((e) => e.headers).flat(), oN(e.options, sN, "getLeftFlatHeaders")), e.getCenterFlatHeaders = aN(() => [e.getCenterHeaderGroups()], (e) => e.map((e) => e.headers).flat(), oN(e.options, sN, "getCenterFlatHeaders")), e.getRightFlatHeaders = aN(() => [e.getRightHeaderGroups()], (e) => e.map((e) => e.headers).flat(), oN(e.options, sN, "getRightFlatHeaders")), e.getCenterLeafHeaders = aN(() => [e.getCenterFlatHeaders()], (e) => e.filter((e) => {
var t;
return !((t = e.subHeaders) != null && t.length);
- }), NM(e.options, IM, "getCenterLeafHeaders")), e.getLeftLeafHeaders = MM(() => [e.getLeftFlatHeaders()], (e) => e.filter((e) => {
+ }), oN(e.options, sN, "getCenterLeafHeaders")), e.getLeftLeafHeaders = aN(() => [e.getLeftFlatHeaders()], (e) => e.filter((e) => {
var t;
return !((t = e.subHeaders) != null && t.length);
- }), NM(e.options, IM, "getLeftLeafHeaders")), e.getRightLeafHeaders = MM(() => [e.getRightFlatHeaders()], (e) => e.filter((e) => {
+ }), oN(e.options, sN, "getLeftLeafHeaders")), e.getRightLeafHeaders = aN(() => [e.getRightFlatHeaders()], (e) => e.filter((e) => {
var t;
return !((t = e.subHeaders) != null && t.length);
- }), NM(e.options, IM, "getRightLeafHeaders")), e.getLeafHeaders = MM(() => [
+ }), oN(e.options, sN, "getRightLeafHeaders")), e.getLeafHeaders = aN(() => [
e.getLeftHeaderGroups(),
e.getCenterHeaderGroups(),
e.getRightHeaderGroups()
@@ -40887,9 +40887,9 @@ var RM = { createTable: (e) => {
...e[0]?.headers ?? [],
...t[0]?.headers ?? [],
...n[0]?.headers ?? []
- ].map((e) => e.getLeafHeaders()).flat(), NM(e.options, IM, "getLeafHeaders"));
+ ].map((e) => e.getLeafHeaders()).flat(), oN(e.options, sN, "getLeafHeaders"));
} };
-function zM(e, t, n, r) {
+function lN(e, t, n, r) {
let i = 0, a = function(e, t) {
t === void 0 && (t = 1), i = Math.max(i, t), e.filter((e) => e.getIsVisible()).forEach((e) => {
var n;
@@ -40907,7 +40907,7 @@ function zM(e, t, n, r) {
let o = [...a].reverse()[0], s = e.column.depth === i.depth, c, l = !1;
if (s && e.column.parent ? c = e.column.parent : (c = e.column, l = !0), o && o?.column === c) o.subHeaders.push(e);
else {
- let i = LM(n, c, {
+ let i = cN(n, c, {
id: [
r,
t,
@@ -40924,7 +40924,7 @@ function zM(e, t, n, r) {
i.headers.push(e), e.headerGroup = i;
}), o.push(i), t > 0 && s(a, t - 1);
};
- s(t.map((e, t) => LM(n, e, {
+ s(t.map((e, t) => cN(n, e, {
depth: i,
index: t
})), i - 1), o.reverse();
@@ -40942,7 +40942,7 @@ function zM(e, t, n, r) {
});
return c(o[0]?.headers ?? []), o;
}
-var BM = (e, t, n, r, i, a, o) => {
+var _fe = (e, t, n, r, i, a, o) => {
let s = {
id: t,
index: r,
@@ -40963,7 +40963,7 @@ var BM = (e, t, n, r, i, a, o) => {
},
renderValue: (t) => s.getValue(t) ?? e.options.renderFallbackValue,
subRows: a ?? [],
- getLeafRows: () => Bfe(s.subRows, (e) => e.subRows),
+ getLeafRows: () => pfe(s.subRows, (e) => e.subRows),
getParentRow: () => s.parentId ? e.getRow(s.parentId, !0) : void 0,
getParentRows: () => {
let e = [], t = s;
@@ -40974,95 +40974,95 @@ var BM = (e, t, n, r, i, a, o) => {
}
return e.reverse();
},
- getAllCells: MM(() => [e.getAllLeafColumns()], (t) => t.map((t) => PM(e, s, t, t.id)), NM(e.options, "debugRows", "getAllCells")),
- _getAllCellsByColumnId: MM(() => [s.getAllCells()], (e) => e.reduce((e, t) => (e[t.column.id] = t, e), {}), NM(e.options, "debugRows", "getAllCellsByColumnId"))
+ getAllCells: aN(() => [e.getAllLeafColumns()], (t) => t.map((t) => mfe(e, s, t, t.id)), oN(e.options, "debugRows", "getAllCells")),
+ _getAllCellsByColumnId: aN(() => [s.getAllCells()], (e) => e.reduce((e, t) => (e[t.column.id] = t, e), {}), oN(e.options, "debugRows", "getAllCellsByColumnId"))
};
for (let t = 0; t < e._features.length; t++) {
let n = e._features[t];
n == null || n.createRow == null || n.createRow(s, e);
}
return s;
-}, VM = { createColumn: (e, t) => {
+}, vfe = { createColumn: (e, t) => {
e._getFacetedRowModel = t.options.getFacetedRowModel && t.options.getFacetedRowModel(t, e.id), e.getFacetedRowModel = () => e._getFacetedRowModel ? e._getFacetedRowModel() : t.getPreFilteredRowModel(), e._getFacetedUniqueValues = t.options.getFacetedUniqueValues && t.options.getFacetedUniqueValues(t, e.id), e.getFacetedUniqueValues = () => e._getFacetedUniqueValues ? e._getFacetedUniqueValues() : /* @__PURE__ */ new Map(), e._getFacetedMinMaxValues = t.options.getFacetedMinMaxValues && t.options.getFacetedMinMaxValues(t, e.id), e.getFacetedMinMaxValues = () => {
if (e._getFacetedMinMaxValues) return e._getFacetedMinMaxValues();
};
-} }, HM = (e, t, n) => {
+} }, uN = (e, t, n) => {
var r, i;
let a = n == null || (r = n.toString()) == null ? void 0 : r.toLowerCase();
return !!((i = e.getValue(t)) != null && (i = i.toString()) != null && (i = i.toLowerCase()) != null && i.includes(a));
};
-HM.autoRemove = (e) => QM(e);
-var UM = (e, t, n) => {
+uN.autoRemove = (e) => bN(e);
+var dN = (e, t, n) => {
var r;
return !!((r = e.getValue(t)) != null && (r = r.toString()) != null && r.includes(n));
};
-UM.autoRemove = (e) => QM(e);
-var WM = (e, t, n) => {
+dN.autoRemove = (e) => bN(e);
+var fN = (e, t, n) => {
var r;
return ((r = e.getValue(t)) == null || (r = r.toString()) == null ? void 0 : r.toLowerCase()) === n?.toLowerCase();
};
-WM.autoRemove = (e) => QM(e);
-var GM = (e, t, n) => e.getValue(t)?.includes(n);
-GM.autoRemove = (e) => QM(e);
-var KM = (e, t, n) => !n.some((n) => {
+fN.autoRemove = (e) => bN(e);
+var pN = (e, t, n) => e.getValue(t)?.includes(n);
+pN.autoRemove = (e) => bN(e);
+var mN = (e, t, n) => !n.some((n) => {
var r;
return !((r = e.getValue(t)) != null && r.includes(n));
});
-KM.autoRemove = (e) => QM(e) || !(e != null && e.length);
-var qM = (e, t, n) => n.some((n) => e.getValue(t)?.includes(n));
-qM.autoRemove = (e) => QM(e) || !(e != null && e.length);
-var JM = (e, t, n) => e.getValue(t) === n;
-JM.autoRemove = (e) => QM(e);
-var YM = (e, t, n) => e.getValue(t) == n;
-YM.autoRemove = (e) => QM(e);
-var XM = (e, t, n) => {
+mN.autoRemove = (e) => bN(e) || !(e != null && e.length);
+var hN = (e, t, n) => n.some((n) => e.getValue(t)?.includes(n));
+hN.autoRemove = (e) => bN(e) || !(e != null && e.length);
+var gN = (e, t, n) => e.getValue(t) === n;
+gN.autoRemove = (e) => bN(e);
+var _N = (e, t, n) => e.getValue(t) == n;
+_N.autoRemove = (e) => bN(e);
+var vN = (e, t, n) => {
let [r, i] = n, a = e.getValue(t);
return a >= r && a <= i;
};
-XM.resolveFilterValue = (e) => {
+vN.resolveFilterValue = (e) => {
let [t, n] = e, r = typeof t == "number" ? t : parseFloat(t), i = typeof n == "number" ? n : parseFloat(n), a = t === null || Number.isNaN(r) ? -Infinity : r, o = n === null || Number.isNaN(i) ? Infinity : i;
if (a > o) {
let e = a;
a = o, o = e;
}
return [a, o];
-}, XM.autoRemove = (e) => QM(e) || QM(e[0]) && QM(e[1]);
-var ZM = {
- includesString: HM,
- includesStringSensitive: UM,
- equalsString: WM,
- arrIncludes: GM,
- arrIncludesAll: KM,
- arrIncludesSome: qM,
- equals: JM,
- weakEquals: YM,
- inNumberRange: XM
+}, vN.autoRemove = (e) => bN(e) || bN(e[0]) && bN(e[1]);
+var yN = {
+ includesString: uN,
+ includesStringSensitive: dN,
+ equalsString: fN,
+ arrIncludes: pN,
+ arrIncludesAll: mN,
+ arrIncludesSome: hN,
+ equals: gN,
+ weakEquals: _N,
+ inNumberRange: vN
};
-function QM(e) {
+function bN(e) {
return e == null || e === "";
}
-var $M = {
+var yfe = {
getDefaultColumnDef: () => ({ filterFn: "auto" }),
getInitialState: (e) => ({
columnFilters: [],
...e
}),
getDefaultOptions: (e) => ({
- onColumnFiltersChange: AM("columnFilters", e),
+ onColumnFiltersChange: rN("columnFilters", e),
filterFromLeafRows: !1,
maxLeafRowFilterDepth: 100
}),
createColumn: (e, t) => {
e.getAutoFilterFn = () => {
let n = t.getCoreRowModel().flatRows[0]?.getValue(e.id);
- return typeof n == "string" ? ZM.includesString : typeof n == "number" ? ZM.inNumberRange : typeof n == "boolean" || typeof n == "object" && n ? ZM.equals : Array.isArray(n) ? ZM.arrIncludes : ZM.weakEquals;
- }, e.getFilterFn = () => jM(e.columnDef.filterFn) ? e.columnDef.filterFn : e.columnDef.filterFn === "auto" ? e.getAutoFilterFn() : t.options.filterFns?.[e.columnDef.filterFn] ?? ZM[e.columnDef.filterFn], e.getCanFilter = () => (e.columnDef.enableColumnFilter ?? !0) && (t.options.enableColumnFilters ?? !0) && (t.options.enableFilters ?? !0) && !!e.accessorFn, e.getIsFiltered = () => e.getFilterIndex() > -1, e.getFilterValue = () => {
+ return typeof n == "string" ? yN.includesString : typeof n == "number" ? yN.inNumberRange : typeof n == "boolean" || typeof n == "object" && n ? yN.equals : Array.isArray(n) ? yN.arrIncludes : yN.weakEquals;
+ }, e.getFilterFn = () => iN(e.columnDef.filterFn) ? e.columnDef.filterFn : e.columnDef.filterFn === "auto" ? e.getAutoFilterFn() : t.options.filterFns?.[e.columnDef.filterFn] ?? yN[e.columnDef.filterFn], e.getCanFilter = () => (e.columnDef.enableColumnFilter ?? !0) && (t.options.enableColumnFilters ?? !0) && (t.options.enableFilters ?? !0) && !!e.accessorFn, e.getIsFiltered = () => e.getFilterIndex() > -1, e.getFilterValue = () => {
var n;
return (n = t.getState().columnFilters) == null || (n = n.find((t) => t.id === e.id)) == null ? void 0 : n.value;
}, e.getFilterIndex = () => t.getState().columnFilters?.findIndex((t) => t.id === e.id) ?? -1, e.setFilterValue = (n) => {
t.setColumnFilters((t) => {
- let r = e.getFilterFn(), i = t?.find((t) => t.id === e.id), a = kM(n, i ? i.value : void 0);
- if (eN(r, a, e)) return t?.filter((t) => t.id !== e.id) ?? [];
+ let r = e.getFilterFn(), i = t?.find((t) => t.id === e.id), a = nN(n, i ? i.value : void 0);
+ if (xN(r, a, e)) return t?.filter((t) => t.id !== e.id) ?? [];
let o = {
id: e.id,
value: a
@@ -41077,19 +41077,19 @@ var $M = {
createTable: (e) => {
e.setColumnFilters = (t) => {
let n = e.getAllLeafColumns();
- e.options.onColumnFiltersChange == null || e.options.onColumnFiltersChange((e) => kM(t, e)?.filter((e) => {
+ e.options.onColumnFiltersChange == null || e.options.onColumnFiltersChange((e) => nN(t, e)?.filter((e) => {
let t = n.find((t) => t.id === e.id);
- return !(t && eN(t.getFilterFn(), e.value, t));
+ return !(t && xN(t.getFilterFn(), e.value, t));
}));
}, e.resetColumnFilters = (t) => {
e.setColumnFilters(t ? [] : e.initialState?.columnFilters ?? []);
}, e.getPreFilteredRowModel = () => e.getCoreRowModel(), e.getFilteredRowModel = () => (!e._getFilteredRowModel && e.options.getFilteredRowModel && (e._getFilteredRowModel = e.options.getFilteredRowModel(e)), e.options.manualFiltering || !e._getFilteredRowModel ? e.getPreFilteredRowModel() : e._getFilteredRowModel());
}
};
-function eN(e, t, n) {
+function xN(e, t, n) {
return (e && e.autoRemove ? e.autoRemove(t, n) : !1) || t === void 0 || typeof t == "string" && !t;
}
-var tN = {
+var SN = {
sum: (e, t, n) => n.reduce((t, n) => {
let r = n.getValue(e);
return t + (typeof r == "number" ? r : 0);
@@ -41125,7 +41125,7 @@ var tN = {
median: (e, t) => {
if (!t.length) return;
let n = t.map((t) => t.getValue(e));
- if (!zfe(n)) return;
+ if (!ffe(n)) return;
if (n.length === 1) return n[0];
let r = Math.floor(n.length / 2), i = n.sort((e, t) => e - t);
return n.length % 2 == 0 ? (i[r - 1] + i[r]) / 2 : i[r];
@@ -41133,7 +41133,7 @@ var tN = {
unique: (e, t) => Array.from(new Set(t.map((t) => t.getValue(e))).values()),
uniqueCount: (e, t) => new Set(t.map((t) => t.getValue(e))).size,
count: (e, t) => t.length
-}, nN = {
+}, bfe = {
getDefaultColumnDef: () => ({
aggregatedCell: (e) => {
var t;
@@ -41146,7 +41146,7 @@ var tN = {
...e
}),
getDefaultOptions: (e) => ({
- onGroupingChange: AM("grouping", e),
+ onGroupingChange: rN("grouping", e),
groupedColumnMode: "reorder"
}),
createColumn: (e, t) => {
@@ -41159,11 +41159,11 @@ var tN = {
};
}, e.getAutoAggregationFn = () => {
let n = t.getCoreRowModel().flatRows[0]?.getValue(e.id);
- if (typeof n == "number") return tN.sum;
- if (Object.prototype.toString.call(n) === "[object Date]") return tN.extent;
+ if (typeof n == "number") return SN.sum;
+ if (Object.prototype.toString.call(n) === "[object Date]") return SN.extent;
}, e.getAggregationFn = () => {
if (!e) throw Error();
- return jM(e.columnDef.aggregationFn) ? e.columnDef.aggregationFn : e.columnDef.aggregationFn === "auto" ? e.getAutoAggregationFn() : t.options.aggregationFns?.[e.columnDef.aggregationFn] ?? tN[e.columnDef.aggregationFn];
+ return iN(e.columnDef.aggregationFn) ? e.columnDef.aggregationFn : e.columnDef.aggregationFn === "auto" ? e.getAutoAggregationFn() : t.options.aggregationFns?.[e.columnDef.aggregationFn] ?? SN[e.columnDef.aggregationFn];
};
},
createTable: (e) => {
@@ -41185,27 +41185,27 @@ var tN = {
};
}
};
-function rN(e, t, n) {
+function xfe(e, t, n) {
if (!(t != null && t.length) || !n) return e;
let r = e.filter((e) => !t.includes(e.id));
return n === "remove" ? r : [...t.map((t) => e.find((e) => e.id === t)).filter(Boolean), ...r];
}
-var iN = {
+var Sfe = {
getInitialState: (e) => ({
columnOrder: [],
...e
}),
- getDefaultOptions: (e) => ({ onColumnOrderChange: AM("columnOrder", e) }),
+ getDefaultOptions: (e) => ({ onColumnOrderChange: rN("columnOrder", e) }),
createColumn: (e, t) => {
- e.getIndex = MM((e) => [hN(t, e)], (t) => t.findIndex((t) => t.id === e.id), NM(t.options, "debugColumns", "getIndex")), e.getIsFirstColumn = (n) => hN(t, n)[0]?.id === e.id, e.getIsLastColumn = (n) => {
- let r = hN(t, n);
+ e.getIndex = aN((e) => [ON(t, e)], (t) => t.findIndex((t) => t.id === e.id), oN(t.options, "debugColumns", "getIndex")), e.getIsFirstColumn = (n) => ON(t, n)[0]?.id === e.id, e.getIsLastColumn = (n) => {
+ let r = ON(t, n);
return r[r.length - 1]?.id === e.id;
};
},
createTable: (e) => {
e.setColumnOrder = (t) => e.options.onColumnOrderChange == null ? void 0 : e.options.onColumnOrderChange(t), e.resetColumnOrder = (t) => {
e.setColumnOrder(t ? [] : e.initialState.columnOrder ?? []);
- }, e._getOrderColumnsFn = MM(() => [
+ }, e._getOrderColumnsFn = aN(() => [
e.getState().columnOrder,
e.getState().grouping,
e.options.groupedColumnMode
@@ -41220,18 +41220,18 @@ var iN = {
}
i = [...i, ...n];
}
- return rN(i, t, n);
- }, NM(e.options, "debugTable", "_getOrderColumnsFn"));
+ return xfe(i, t, n);
+ }, oN(e.options, "debugTable", "_getOrderColumnsFn"));
}
-}, aN = () => ({
+}, CN = () => ({
left: [],
right: []
-}), oN = {
+}), Cfe = {
getInitialState: (e) => ({
- columnPinning: aN(),
+ columnPinning: CN(),
...e
}),
- getDefaultOptions: (e) => ({ onColumnPinningChange: AM("columnPinning", e) }),
+ getDefaultOptions: (e) => ({ onColumnPinningChange: rN("columnPinning", e) }),
createColumn: (e, t) => {
e.pin = (n) => {
let r = e.getLeafColumns().map((e) => e.id).filter(Boolean);
@@ -41255,75 +41255,75 @@ var iN = {
};
},
createRow: (e, t) => {
- e.getCenterVisibleCells = MM(() => [
+ e.getCenterVisibleCells = aN(() => [
e._getAllVisibleCells(),
t.getState().columnPinning.left,
t.getState().columnPinning.right
], (e, t, n) => {
let r = [...t ?? [], ...n ?? []];
return e.filter((e) => !r.includes(e.column.id));
- }, NM(t.options, "debugRows", "getCenterVisibleCells")), e.getLeftVisibleCells = MM(() => [e._getAllVisibleCells(), t.getState().columnPinning.left], (e, t) => (t ?? []).map((t) => e.find((e) => e.column.id === t)).filter(Boolean).map((e) => ({
+ }, oN(t.options, "debugRows", "getCenterVisibleCells")), e.getLeftVisibleCells = aN(() => [e._getAllVisibleCells(), t.getState().columnPinning.left], (e, t) => (t ?? []).map((t) => e.find((e) => e.column.id === t)).filter(Boolean).map((e) => ({
...e,
position: "left"
- })), NM(t.options, "debugRows", "getLeftVisibleCells")), e.getRightVisibleCells = MM(() => [e._getAllVisibleCells(), t.getState().columnPinning.right], (e, t) => (t ?? []).map((t) => e.find((e) => e.column.id === t)).filter(Boolean).map((e) => ({
+ })), oN(t.options, "debugRows", "getLeftVisibleCells")), e.getRightVisibleCells = aN(() => [e._getAllVisibleCells(), t.getState().columnPinning.right], (e, t) => (t ?? []).map((t) => e.find((e) => e.column.id === t)).filter(Boolean).map((e) => ({
...e,
position: "right"
- })), NM(t.options, "debugRows", "getRightVisibleCells"));
+ })), oN(t.options, "debugRows", "getRightVisibleCells"));
},
createTable: (e) => {
- e.setColumnPinning = (t) => e.options.onColumnPinningChange == null ? void 0 : e.options.onColumnPinningChange(t), e.resetColumnPinning = (t) => e.setColumnPinning(t ? aN() : e.initialState?.columnPinning ?? aN()), e.getIsSomeColumnsPinned = (t) => {
+ e.setColumnPinning = (t) => e.options.onColumnPinningChange == null ? void 0 : e.options.onColumnPinningChange(t), e.resetColumnPinning = (t) => e.setColumnPinning(t ? CN() : e.initialState?.columnPinning ?? CN()), e.getIsSomeColumnsPinned = (t) => {
let n = e.getState().columnPinning;
return t ? !!n[t]?.length : !!(n.left?.length || n.right?.length);
- }, e.getLeftLeafColumns = MM(() => [e.getAllLeafColumns(), e.getState().columnPinning.left], (e, t) => (t ?? []).map((t) => e.find((e) => e.id === t)).filter(Boolean), NM(e.options, "debugColumns", "getLeftLeafColumns")), e.getRightLeafColumns = MM(() => [e.getAllLeafColumns(), e.getState().columnPinning.right], (e, t) => (t ?? []).map((t) => e.find((e) => e.id === t)).filter(Boolean), NM(e.options, "debugColumns", "getRightLeafColumns")), e.getCenterLeafColumns = MM(() => [
+ }, e.getLeftLeafColumns = aN(() => [e.getAllLeafColumns(), e.getState().columnPinning.left], (e, t) => (t ?? []).map((t) => e.find((e) => e.id === t)).filter(Boolean), oN(e.options, "debugColumns", "getLeftLeafColumns")), e.getRightLeafColumns = aN(() => [e.getAllLeafColumns(), e.getState().columnPinning.right], (e, t) => (t ?? []).map((t) => e.find((e) => e.id === t)).filter(Boolean), oN(e.options, "debugColumns", "getRightLeafColumns")), e.getCenterLeafColumns = aN(() => [
e.getAllLeafColumns(),
e.getState().columnPinning.left,
e.getState().columnPinning.right
], (e, t, n) => {
let r = [...t ?? [], ...n ?? []];
return e.filter((e) => !r.includes(e.id));
- }, NM(e.options, "debugColumns", "getCenterLeafColumns"));
+ }, oN(e.options, "debugColumns", "getCenterLeafColumns"));
}
};
-function sN(e) {
+function wfe(e) {
return e || (typeof document < "u" ? document : null);
}
-var cN = {
+var wN = {
size: 150,
minSize: 20,
maxSize: 2 ** 53 - 1
-}, lN = () => ({
+}, TN = () => ({
startOffset: null,
startSize: null,
deltaOffset: null,
deltaPercentage: null,
isResizingColumn: !1,
columnSizingStart: []
-}), uN = {
- getDefaultColumnDef: () => cN,
+}), Tfe = {
+ getDefaultColumnDef: () => wN,
getInitialState: (e) => ({
columnSizing: {},
- columnSizingInfo: lN(),
+ columnSizingInfo: TN(),
...e
}),
getDefaultOptions: (e) => ({
columnResizeMode: "onEnd",
columnResizeDirection: "ltr",
- onColumnSizingChange: AM("columnSizing", e),
- onColumnSizingInfoChange: AM("columnSizingInfo", e)
+ onColumnSizingChange: rN("columnSizing", e),
+ onColumnSizingInfoChange: rN("columnSizingInfo", e)
}),
createColumn: (e, t) => {
e.getSize = () => {
let n = t.getState().columnSizing[e.id];
- return Math.min(Math.max(e.columnDef.minSize ?? cN.minSize, n ?? e.columnDef.size ?? cN.size), e.columnDef.maxSize ?? cN.maxSize);
- }, e.getStart = MM((e) => [
+ return Math.min(Math.max(e.columnDef.minSize ?? wN.minSize, n ?? e.columnDef.size ?? wN.size), e.columnDef.maxSize ?? wN.maxSize);
+ }, e.getStart = aN((e) => [
e,
- hN(t, e),
+ ON(t, e),
t.getState().columnSizing
- ], (t, n) => n.slice(0, e.getIndex(t)).reduce((e, t) => e + t.getSize(), 0), NM(t.options, "debugColumns", "getStart")), e.getAfter = MM((e) => [
+ ], (t, n) => n.slice(0, e.getIndex(t)).reduce((e, t) => e + t.getSize(), 0), oN(t.options, "debugColumns", "getStart")), e.getAfter = aN((e) => [
e,
- hN(t, e),
+ ON(t, e),
t.getState().columnSizing
- ], (t, n) => n.slice(e.getIndex(t) + 1).reduce((e, t) => e + t.getSize(), 0), NM(t.options, "debugColumns", "getAfter")), e.resetSize = () => {
+ ], (t, n) => n.slice(e.getIndex(t) + 1).reduce((e, t) => e + t.getSize(), 0), oN(t.options, "debugColumns", "getAfter")), e.resetSize = () => {
t.setColumnSizing((t) => {
let { [e.id]: n, ...r } = t;
return r;
@@ -41345,8 +41345,8 @@ var cN = {
}, e.getResizeHandler = (n) => {
let r = t.getColumn(e.column.id), i = r?.getCanResize();
return (a) => {
- if (!r || !i || (a.persist == null || a.persist(), pN(a) && a.touches && a.touches.length > 1)) return;
- let o = e.getSize(), s = e ? e.getLeafHeaders().map((e) => [e.column.id, e.column.getSize()]) : [[r.id, r.getSize()]], c = pN(a) ? Math.round(a.touches[0].clientX) : a.clientX, l = {}, u = (e, n) => {
+ if (!r || !i || (a.persist == null || a.persist(), DN(a) && a.touches && a.touches.length > 1)) return;
+ let o = e.getSize(), s = e ? e.getLeafHeaders().map((e) => [e.column.id, e.column.getSize()]) : [[r.id, r.getSize()]], c = DN(a) ? Math.round(a.touches[0].clientX) : a.clientX, l = {}, u = (e, n) => {
typeof n == "number" && (t.setColumnSizingInfo((e) => {
let r = t.options.columnResizeDirection === "rtl" ? -1 : 1, i = (n - (e?.startOffset ?? 0)) * r, a = Math.max(i / (e?.startSize ?? 0), -.999999);
return e.columnSizingStart.forEach((e) => {
@@ -41371,7 +41371,7 @@ var cN = {
deltaPercentage: null,
columnSizingStart: []
}));
- }, p = sN(n), m = {
+ }, p = wfe(n), m = {
moveHandler: (e) => d(e.clientX),
upHandler: (e) => {
p?.removeEventListener("mousemove", m.moveHandler), p?.removeEventListener("mouseup", m.upHandler), f(e.clientX);
@@ -41381,8 +41381,8 @@ var cN = {
upHandler: (e) => {
p?.removeEventListener("touchmove", h.moveHandler), p?.removeEventListener("touchend", h.upHandler), e.cancelable && (e.preventDefault(), e.stopPropagation()), f(e.touches[0]?.clientX);
}
- }, g = fN() ? { passive: !1 } : !1;
- pN(a) ? (p?.addEventListener("touchmove", h.moveHandler, g), p?.addEventListener("touchend", h.upHandler, g)) : (p?.addEventListener("mousemove", m.moveHandler, g), p?.addEventListener("mouseup", m.upHandler, g)), t.setColumnSizingInfo((e) => ({
+ }, g = Efe() ? { passive: !1 } : !1;
+ DN(a) ? (p?.addEventListener("touchmove", h.moveHandler, g), p?.addEventListener("touchend", h.upHandler, g)) : (p?.addEventListener("mousemove", m.moveHandler, g), p?.addEventListener("mouseup", m.upHandler, g)), t.setColumnSizingInfo((e) => ({
...e,
startOffset: c,
startSize: o,
@@ -41398,12 +41398,12 @@ var cN = {
e.setColumnSizing = (t) => e.options.onColumnSizingChange == null ? void 0 : e.options.onColumnSizingChange(t), e.setColumnSizingInfo = (t) => e.options.onColumnSizingInfoChange == null ? void 0 : e.options.onColumnSizingInfoChange(t), e.resetColumnSizing = (t) => {
e.setColumnSizing(t ? {} : e.initialState.columnSizing ?? {});
}, e.resetHeaderSizeInfo = (t) => {
- e.setColumnSizingInfo(t ? lN() : e.initialState.columnSizingInfo ?? lN());
+ e.setColumnSizingInfo(t ? TN() : e.initialState.columnSizingInfo ?? TN());
}, e.getTotalSize = () => e.getHeaderGroups()[0]?.headers.reduce((e, t) => e + t.getSize(), 0) ?? 0, e.getLeftTotalSize = () => e.getLeftHeaderGroups()[0]?.headers.reduce((e, t) => e + t.getSize(), 0) ?? 0, e.getCenterTotalSize = () => e.getCenterHeaderGroups()[0]?.headers.reduce((e, t) => e + t.getSize(), 0) ?? 0, e.getRightTotalSize = () => e.getRightHeaderGroups()[0]?.headers.reduce((e, t) => e + t.getSize(), 0) ?? 0;
}
-}, dN = null;
-function fN() {
- if (typeof dN == "boolean") return dN;
+}, EN = null;
+function Efe() {
+ if (typeof EN == "boolean") return EN;
let e = !1;
try {
let t = { get passive() {
@@ -41413,17 +41413,17 @@ function fN() {
} catch {
e = !1;
}
- return dN = e, dN;
+ return EN = e, EN;
}
-function pN(e) {
+function DN(e) {
return e.type === "touchstart";
}
-var mN = {
+var Dfe = {
getInitialState: (e) => ({
columnVisibility: {},
...e
}),
- getDefaultOptions: (e) => ({ onColumnVisibilityChange: AM("columnVisibility", e) }),
+ getDefaultOptions: (e) => ({ onColumnVisibilityChange: rN("columnVisibility", e) }),
createColumn: (e, t) => {
e.toggleVisibility = (n) => {
e.getCanHide() && t.setColumnVisibility((t) => ({
@@ -41438,7 +41438,7 @@ var mN = {
};
},
createRow: (e, t) => {
- e._getAllVisibleCells = MM(() => [e.getAllCells(), t.getState().columnVisibility], (e) => e.filter((e) => e.column.getIsVisible()), NM(t.options, "debugRows", "_getAllVisibleCells")), e.getVisibleCells = MM(() => [
+ e._getAllVisibleCells = aN(() => [e.getAllCells(), t.getState().columnVisibility], (e) => e.filter((e) => e.column.getIsVisible()), oN(t.options, "debugRows", "_getAllVisibleCells")), e.getVisibleCells = aN(() => [
e.getLeftVisibleCells(),
e.getCenterVisibleCells(),
e.getRightVisibleCells()
@@ -41446,10 +41446,10 @@ var mN = {
...e,
...t,
...n
- ], NM(t.options, "debugRows", "getVisibleCells"));
+ ], oN(t.options, "debugRows", "getVisibleCells"));
},
createTable: (e) => {
- let t = (t, n) => MM(() => [n(), n().filter((e) => e.getIsVisible()).map((e) => e.id).join("_")], (e) => e.filter((e) => e.getIsVisible == null ? void 0 : e.getIsVisible()), NM(e.options, "debugColumns", t));
+ let t = (t, n) => aN(() => [n(), n().filter((e) => e.getIsVisible()).map((e) => e.id).join("_")], (e) => e.filter((e) => e.getIsVisible == null ? void 0 : e.getIsVisible()), oN(e.options, "debugColumns", t));
e.getVisibleFlatColumns = t("getVisibleFlatColumns", () => e.getAllFlatColumns()), e.getVisibleLeafColumns = t("getVisibleLeafColumns", () => e.getAllLeafColumns()), e.getLeftVisibleLeafColumns = t("getLeftVisibleLeafColumns", () => e.getLeftLeafColumns()), e.getRightVisibleLeafColumns = t("getRightVisibleLeafColumns", () => e.getRightLeafColumns()), e.getCenterVisibleLeafColumns = t("getCenterVisibleLeafColumns", () => e.getCenterLeafColumns()), e.setColumnVisibility = (t) => e.options.onColumnVisibilityChange == null ? void 0 : e.options.onColumnVisibilityChange(t), e.resetColumnVisibility = (t) => {
e.setColumnVisibility(t ? {} : e.initialState.columnVisibility ?? {});
}, e.toggleAllColumnsVisible = (t) => {
@@ -41462,20 +41462,20 @@ var mN = {
};
}
};
-function hN(e, t) {
+function ON(e, t) {
return t ? t === "center" ? e.getCenterVisibleLeafColumns() : t === "left" ? e.getLeftVisibleLeafColumns() : e.getRightVisibleLeafColumns() : e.getVisibleLeafColumns();
}
-var gN = { createTable: (e) => {
+var Ofe = { createTable: (e) => {
e._getGlobalFacetedRowModel = e.options.getFacetedRowModel && e.options.getFacetedRowModel(e, "__global__"), e.getGlobalFacetedRowModel = () => e.options.manualFiltering || !e._getGlobalFacetedRowModel ? e.getPreFilteredRowModel() : e._getGlobalFacetedRowModel(), e._getGlobalFacetedUniqueValues = e.options.getFacetedUniqueValues && e.options.getFacetedUniqueValues(e, "__global__"), e.getGlobalFacetedUniqueValues = () => e._getGlobalFacetedUniqueValues ? e._getGlobalFacetedUniqueValues() : /* @__PURE__ */ new Map(), e._getGlobalFacetedMinMaxValues = e.options.getFacetedMinMaxValues && e.options.getFacetedMinMaxValues(e, "__global__"), e.getGlobalFacetedMinMaxValues = () => {
if (e._getGlobalFacetedMinMaxValues) return e._getGlobalFacetedMinMaxValues();
};
-} }, _N = {
+} }, kfe = {
getInitialState: (e) => ({
globalFilter: void 0,
...e
}),
getDefaultOptions: (e) => ({
- onGlobalFilterChange: AM("globalFilter", e),
+ onGlobalFilterChange: rN("globalFilter", e),
globalFilterFn: "auto",
getColumnCanGlobalFilter: (t) => {
var n;
@@ -41487,22 +41487,22 @@ var gN = { createTable: (e) => {
e.getCanGlobalFilter = () => (e.columnDef.enableGlobalFilter ?? !0) && (t.options.enableGlobalFilter ?? !0) && (t.options.enableFilters ?? !0) && ((t.options.getColumnCanGlobalFilter == null ? void 0 : t.options.getColumnCanGlobalFilter(e)) ?? !0) && !!e.accessorFn;
},
createTable: (e) => {
- e.getGlobalAutoFilterFn = () => ZM.includesString, e.getGlobalFilterFn = () => {
+ e.getGlobalAutoFilterFn = () => yN.includesString, e.getGlobalFilterFn = () => {
let { globalFilterFn: t } = e.options;
- return jM(t) ? t : t === "auto" ? e.getGlobalAutoFilterFn() : e.options.filterFns?.[t] ?? ZM[t];
+ return iN(t) ? t : t === "auto" ? e.getGlobalAutoFilterFn() : e.options.filterFns?.[t] ?? yN[t];
}, e.setGlobalFilter = (t) => {
e.options.onGlobalFilterChange == null || e.options.onGlobalFilterChange(t);
}, e.resetGlobalFilter = (t) => {
e.setGlobalFilter(t ? void 0 : e.initialState.globalFilter);
};
}
-}, vN = {
+}, Afe = {
getInitialState: (e) => ({
expanded: {},
...e
}),
getDefaultOptions: (e) => ({
- onExpandedChange: AM("expanded", e),
+ onExpandedChange: rN("expanded", e),
paginateExpandedRows: !0
}),
createTable: (e) => {
@@ -41573,18 +41573,18 @@ var gN = { createTable: (e) => {
};
};
}
-}, yN = 0, bN = 10, xN = () => ({
- pageIndex: yN,
- pageSize: bN
-}), SN = {
+}, kN = 0, AN = 10, jN = () => ({
+ pageIndex: kN,
+ pageSize: AN
+}), jfe = {
getInitialState: (e) => ({
...e,
pagination: {
- ...xN(),
+ ...jN(),
...e?.pagination
}
}),
- getDefaultOptions: (e) => ({ onPaginationChange: AM("pagination", e) }),
+ getDefaultOptions: (e) => ({ onPaginationChange: rN("pagination", e) }),
createTable: (e) => {
let t = !1, n = !1;
e._autoResetPageIndex = () => {
@@ -41600,11 +41600,11 @@ var gN = { createTable: (e) => {
e.resetPageIndex(), n = !1;
});
}
- }, e.setPagination = (t) => e.options.onPaginationChange == null ? void 0 : e.options.onPaginationChange((e) => kM(t, e)), e.resetPagination = (t) => {
- e.setPagination(t ? xN() : e.initialState.pagination ?? xN());
+ }, e.setPagination = (t) => e.options.onPaginationChange == null ? void 0 : e.options.onPaginationChange((e) => nN(t, e)), e.resetPagination = (t) => {
+ e.setPagination(t ? jN() : e.initialState.pagination ?? jN());
}, e.setPageIndex = (t) => {
e.setPagination((n) => {
- let r = kM(t, n.pageIndex), i = e.options.pageCount === void 0 || e.options.pageCount === -1 ? 2 ** 53 - 1 : e.options.pageCount - 1;
+ let r = nN(t, n.pageIndex), i = e.options.pageCount === void 0 || e.options.pageCount === -1 ? 2 ** 53 - 1 : e.options.pageCount - 1;
return r = Math.max(0, Math.min(r, i)), {
...n,
pageIndex: r
@@ -41612,13 +41612,13 @@ var gN = { createTable: (e) => {
});
}, e.resetPageIndex = (t) => {
var n;
- e.setPageIndex(t ? yN : ((n = e.initialState) == null || (n = n.pagination) == null ? void 0 : n.pageIndex) ?? yN);
+ e.setPageIndex(t ? kN : ((n = e.initialState) == null || (n = n.pagination) == null ? void 0 : n.pageIndex) ?? kN);
}, e.resetPageSize = (t) => {
var n;
- e.setPageSize(t ? bN : ((n = e.initialState) == null || (n = n.pagination) == null ? void 0 : n.pageSize) ?? bN);
+ e.setPageSize(t ? AN : ((n = e.initialState) == null || (n = n.pagination) == null ? void 0 : n.pageSize) ?? AN);
}, e.setPageSize = (t) => {
e.setPagination((e) => {
- let n = Math.max(1, kM(t, e.pageSize)), r = e.pageSize * e.pageIndex, i = Math.floor(r / n);
+ let n = Math.max(1, nN(t, e.pageSize)), r = e.pageSize * e.pageIndex, i = Math.floor(r / n);
return {
...e,
pageIndex: i,
@@ -41626,28 +41626,28 @@ var gN = { createTable: (e) => {
};
});
}, e.setPageCount = (t) => e.setPagination((n) => {
- let r = kM(t, e.options.pageCount ?? -1);
+ let r = nN(t, e.options.pageCount ?? -1);
return typeof r == "number" && (r = Math.max(-1, r)), {
...n,
pageCount: r
};
- }), e.getPageOptions = MM(() => [e.getPageCount()], (e) => {
+ }), e.getPageOptions = aN(() => [e.getPageCount()], (e) => {
let t = [];
return e && e > 0 && (t = [...Array(e)].fill(null).map((e, t) => t)), t;
- }, NM(e.options, "debugTable", "getPageOptions")), e.getCanPreviousPage = () => e.getState().pagination.pageIndex > 0, e.getCanNextPage = () => {
+ }, oN(e.options, "debugTable", "getPageOptions")), e.getCanPreviousPage = () => e.getState().pagination.pageIndex > 0, e.getCanNextPage = () => {
let { pageIndex: t } = e.getState().pagination, n = e.getPageCount();
return n === -1 || n !== 0 && t < n - 1;
}, e.previousPage = () => e.setPageIndex((e) => e - 1), e.nextPage = () => e.setPageIndex((e) => e + 1), e.firstPage = () => e.setPageIndex(0), e.lastPage = () => e.setPageIndex(e.getPageCount() - 1), e.getPrePaginationRowModel = () => e.getExpandedRowModel(), e.getPaginationRowModel = () => (!e._getPaginationRowModel && e.options.getPaginationRowModel && (e._getPaginationRowModel = e.options.getPaginationRowModel(e)), e.options.manualPagination || !e._getPaginationRowModel ? e.getPrePaginationRowModel() : e._getPaginationRowModel()), e.getPageCount = () => e.options.pageCount ?? Math.ceil(e.getRowCount() / e.getState().pagination.pageSize), e.getRowCount = () => e.options.rowCount ?? e.getPrePaginationRowModel().rows.length;
}
-}, CN = () => ({
+}, MN = () => ({
top: [],
bottom: []
-}), wN = {
+}), Mfe = {
getInitialState: (e) => ({
- rowPinning: CN(),
+ rowPinning: MN(),
...e
}),
- getDefaultOptions: (e) => ({ onRowPinningChange: AM("rowPinning", e) }),
+ getDefaultOptions: (e) => ({ onRowPinningChange: rN("rowPinning", e) }),
createRow: (e, t) => {
e.pin = (n, r, i) => {
let a = r ? e.getLeafRows().map((e) => {
@@ -41686,7 +41686,7 @@ var gN = { createTable: (e) => {
};
},
createTable: (e) => {
- e.setRowPinning = (t) => e.options.onRowPinningChange == null ? void 0 : e.options.onRowPinningChange(t), e.resetRowPinning = (t) => e.setRowPinning(t ? CN() : e.initialState?.rowPinning ?? CN()), e.getIsSomeRowsPinned = (t) => {
+ e.setRowPinning = (t) => e.options.onRowPinningChange == null ? void 0 : e.options.onRowPinningChange(t), e.resetRowPinning = (t) => e.setRowPinning(t ? MN() : e.initialState?.rowPinning ?? MN()), e.getIsSomeRowsPinned = (t) => {
let n = e.getState().rowPinning;
return t ? !!n[t]?.length : !!(n.top?.length || n.bottom?.length);
}, e._getPinnedRows = (t, n, r) => (e.options.keepPinnedRows ?? !0 ? (n ?? []).map((t) => {
@@ -41695,22 +41695,22 @@ var gN = { createTable: (e) => {
}) : (n ?? []).map((e) => t.find((t) => t.id === e))).filter(Boolean).map((e) => ({
...e,
position: r
- })), e.getTopRows = MM(() => [e.getRowModel().rows, e.getState().rowPinning.top], (t, n) => e._getPinnedRows(t, n, "top"), NM(e.options, "debugRows", "getTopRows")), e.getBottomRows = MM(() => [e.getRowModel().rows, e.getState().rowPinning.bottom], (t, n) => e._getPinnedRows(t, n, "bottom"), NM(e.options, "debugRows", "getBottomRows")), e.getCenterRows = MM(() => [
+ })), e.getTopRows = aN(() => [e.getRowModel().rows, e.getState().rowPinning.top], (t, n) => e._getPinnedRows(t, n, "top"), oN(e.options, "debugRows", "getTopRows")), e.getBottomRows = aN(() => [e.getRowModel().rows, e.getState().rowPinning.bottom], (t, n) => e._getPinnedRows(t, n, "bottom"), oN(e.options, "debugRows", "getBottomRows")), e.getCenterRows = aN(() => [
e.getRowModel().rows,
e.getState().rowPinning.top,
e.getState().rowPinning.bottom
], (e, t, n) => {
let r = /* @__PURE__ */ new Set([...t ?? [], ...n ?? []]);
return e.filter((e) => !r.has(e.id));
- }, NM(e.options, "debugRows", "getCenterRows"));
+ }, oN(e.options, "debugRows", "getCenterRows"));
}
-}, TN = {
+}, Nfe = {
getInitialState: (e) => ({
rowSelection: {},
...e
}),
getDefaultOptions: (e) => ({
- onRowSelectionChange: AM("rowSelection", e),
+ onRowSelectionChange: rN("rowSelection", e),
enableRowSelection: !0,
enableMultiRowSelection: !0,
enableSubRowSelection: !0
@@ -41729,21 +41729,21 @@ var gN = { createTable: (e) => {
}, e.toggleAllPageRowsSelected = (t) => e.setRowSelection((n) => {
let r = t === void 0 ? !e.getIsAllPageRowsSelected() : t, i = { ...n };
return e.getRowModel().rows.forEach((t) => {
- EN(i, t.id, r, !0, e);
+ NN(i, t.id, r, !0, e);
}), i;
- }), e.getPreSelectedRowModel = () => e.getCoreRowModel(), e.getSelectedRowModel = MM(() => [e.getState().rowSelection, e.getCoreRowModel()], (t, n) => Object.keys(t).length ? DN(e, n) : {
+ }), e.getPreSelectedRowModel = () => e.getCoreRowModel(), e.getSelectedRowModel = aN(() => [e.getState().rowSelection, e.getCoreRowModel()], (t, n) => Object.keys(t).length ? PN(e, n) : {
rows: [],
flatRows: [],
rowsById: {}
- }, NM(e.options, "debugTable", "getSelectedRowModel")), e.getFilteredSelectedRowModel = MM(() => [e.getState().rowSelection, e.getFilteredRowModel()], (t, n) => Object.keys(t).length ? DN(e, n) : {
+ }, oN(e.options, "debugTable", "getSelectedRowModel")), e.getFilteredSelectedRowModel = aN(() => [e.getState().rowSelection, e.getFilteredRowModel()], (t, n) => Object.keys(t).length ? PN(e, n) : {
rows: [],
flatRows: [],
rowsById: {}
- }, NM(e.options, "debugTable", "getFilteredSelectedRowModel")), e.getGroupedSelectedRowModel = MM(() => [e.getState().rowSelection, e.getSortedRowModel()], (t, n) => Object.keys(t).length ? DN(e, n) : {
+ }, oN(e.options, "debugTable", "getFilteredSelectedRowModel")), e.getGroupedSelectedRowModel = aN(() => [e.getState().rowSelection, e.getSortedRowModel()], (t, n) => Object.keys(t).length ? PN(e, n) : {
rows: [],
flatRows: [],
rowsById: {}
- }, NM(e.options, "debugTable", "getGroupedSelectedRowModel")), e.getIsAllRowsSelected = () => {
+ }, oN(e.options, "debugTable", "getGroupedSelectedRowModel")), e.getIsAllRowsSelected = () => {
let t = e.getFilteredRowModel().flatRows, { rowSelection: n } = e.getState(), r = !!(t.length && Object.keys(n).length);
return r && t.some((e) => e.getCanSelect() && !n[e.id]) && (r = !1), r;
}, e.getIsAllPageRowsSelected = () => {
@@ -41767,17 +41767,17 @@ var gN = { createTable: (e) => {
t.setRowSelection((a) => {
if (n = n === void 0 ? !i : n, e.getCanSelect() && i === n) return a;
let o = { ...a };
- return EN(o, e.id, n, r?.selectChildren ?? !0, t), o;
+ return NN(o, e.id, n, r?.selectChildren ?? !0, t), o;
});
}, e.getIsSelected = () => {
let { rowSelection: n } = t.getState();
- return ON(e, n);
+ return FN(e, n);
}, e.getIsSomeSelected = () => {
let { rowSelection: n } = t.getState();
- return kN(e, n) === "some";
+ return IN(e, n) === "some";
}, e.getIsAllSubRowsSelected = () => {
let { rowSelection: n } = t.getState();
- return kN(e, n) === "all";
+ return IN(e, n) === "all";
}, e.getCanSelect = () => typeof t.options.enableRowSelection == "function" ? t.options.enableRowSelection(e) : t.options.enableRowSelection ?? !0, e.getCanSelectSubRows = () => typeof t.options.enableSubRowSelection == "function" ? t.options.enableSubRowSelection(e) : t.options.enableSubRowSelection ?? !0, e.getCanMultiSelect = () => typeof t.options.enableMultiRowSelection == "function" ? t.options.enableMultiRowSelection(e) : t.options.enableMultiRowSelection ?? !0, e.getToggleSelectedHandler = () => {
let t = e.getCanSelect();
return (n) => {
@@ -41785,16 +41785,16 @@ var gN = { createTable: (e) => {
};
};
}
-}, EN = (e, t, n, r, i) => {
+}, NN = (e, t, n, r, i) => {
var a;
let o = i.getRow(t, !0);
- n ? (o.getCanMultiSelect() || Object.keys(e).forEach((t) => delete e[t]), o.getCanSelect() && (e[t] = !0)) : delete e[t], r && (a = o.subRows) != null && a.length && o.getCanSelectSubRows() && o.subRows.forEach((t) => EN(e, t.id, n, r, i));
+ n ? (o.getCanMultiSelect() || Object.keys(e).forEach((t) => delete e[t]), o.getCanSelect() && (e[t] = !0)) : delete e[t], r && (a = o.subRows) != null && a.length && o.getCanSelectSubRows() && o.subRows.forEach((t) => NN(e, t.id, n, r, i));
};
-function DN(e, t) {
+function PN(e, t) {
let n = e.getState().rowSelection, r = [], i = {}, a = function(e, t) {
return e.map((e) => {
var t;
- let o = ON(e, n);
+ let o = FN(e, n);
if (o && (r.push(e), i[e.id] = e), (t = e.subRows) != null && t.length && (e = {
...e,
subRows: a(e.subRows)
@@ -41807,32 +41807,32 @@ function DN(e, t) {
rowsById: i
};
}
-function ON(e, t) {
+function FN(e, t) {
return t[e.id] ?? !1;
}
-function kN(e, t, n) {
+function IN(e, t, n) {
var r;
if (!((r = e.subRows) != null && r.length)) return !1;
let i = !0, a = !1;
return e.subRows.forEach((e) => {
- if (!(a && !i) && (e.getCanSelect() && (ON(e, t) ? a = !0 : i = !1), e.subRows && e.subRows.length)) {
- let n = kN(e, t);
+ if (!(a && !i) && (e.getCanSelect() && (FN(e, t) ? a = !0 : i = !1), e.subRows && e.subRows.length)) {
+ let n = IN(e, t);
n === "all" ? a = !0 : (n === "some" && (a = !0), i = !1);
}
}), i ? "all" : a ? "some" : !1;
}
-var AN = /([0-9]+)/gm, jN = (e, t, n) => zN(RN(e.getValue(n)).toLowerCase(), RN(t.getValue(n)).toLowerCase()), MN = (e, t, n) => zN(RN(e.getValue(n)), RN(t.getValue(n))), NN = (e, t, n) => LN(RN(e.getValue(n)).toLowerCase(), RN(t.getValue(n)).toLowerCase()), PN = (e, t, n) => LN(RN(e.getValue(n)), RN(t.getValue(n))), FN = (e, t, n) => {
+var LN = /([0-9]+)/gm, Pfe = (e, t, n) => BN(zN(e.getValue(n)).toLowerCase(), zN(t.getValue(n)).toLowerCase()), Ffe = (e, t, n) => BN(zN(e.getValue(n)), zN(t.getValue(n))), Ife = (e, t, n) => RN(zN(e.getValue(n)).toLowerCase(), zN(t.getValue(n)).toLowerCase()), Lfe = (e, t, n) => RN(zN(e.getValue(n)), zN(t.getValue(n))), Rfe = (e, t, n) => {
let r = e.getValue(n), i = t.getValue(n);
return r > i ? 1 : r < i ? -1 : 0;
-}, IN = (e, t, n) => LN(e.getValue(n), t.getValue(n));
-function LN(e, t) {
+}, zfe = (e, t, n) => RN(e.getValue(n), t.getValue(n));
+function RN(e, t) {
return e === t ? 0 : e > t ? 1 : -1;
}
-function RN(e) {
+function zN(e) {
return typeof e == "number" ? isNaN(e) || e === Infinity || e === -Infinity ? "" : String(e) : typeof e == "string" ? e : "";
}
-function zN(e, t) {
- let n = e.split(AN).filter(Boolean), r = t.split(AN).filter(Boolean);
+function BN(e, t) {
+ let n = e.split(LN).filter(Boolean), r = t.split(LN).filter(Boolean);
for (; n.length && r.length;) {
let e = n.shift(), t = r.shift(), i = parseInt(e, 10), a = parseInt(t, 10), o = [i, a].sort();
if (isNaN(o[0])) {
@@ -41846,22 +41846,22 @@ function zN(e, t) {
}
return n.length - r.length;
}
-var BN = {
- alphanumeric: jN,
- alphanumericCaseSensitive: MN,
- text: NN,
- textCaseSensitive: PN,
- datetime: FN,
- basic: IN
-}, Vfe = [
- RM,
- mN,
- iN,
- oN,
- VM,
- $M,
- gN,
- _N,
+var VN = {
+ alphanumeric: Pfe,
+ alphanumericCaseSensitive: Ffe,
+ text: Ife,
+ textCaseSensitive: Lfe,
+ datetime: Rfe,
+ basic: zfe
+}, Bfe = [
+ gfe,
+ Dfe,
+ Sfe,
+ Cfe,
+ vfe,
+ yfe,
+ Ofe,
+ kfe,
{
getInitialState: (e) => ({
sorting: [],
@@ -41872,7 +41872,7 @@ var BN = {
sortUndefined: 1
}),
getDefaultOptions: (e) => ({
- onSortingChange: AM("sorting", e),
+ onSortingChange: rN("sorting", e),
isMultiSortEvent: (e) => e.shiftKey
}),
createColumn: (e, t) => {
@@ -41880,13 +41880,13 @@ var BN = {
let n = t.getFilteredRowModel().flatRows.slice(10), r = !1;
for (let t of n) {
let n = t?.getValue(e.id);
- if (Object.prototype.toString.call(n) === "[object Date]") return BN.datetime;
- if (typeof n == "string" && (r = !0, n.split(AN).length > 1)) return BN.alphanumeric;
+ if (Object.prototype.toString.call(n) === "[object Date]") return VN.datetime;
+ if (typeof n == "string" && (r = !0, n.split(LN).length > 1)) return VN.alphanumeric;
}
- return r ? BN.text : BN.basic;
+ return r ? VN.text : VN.basic;
}, e.getAutoSortDir = () => typeof t.getFilteredRowModel().flatRows[0]?.getValue(e.id) == "string" ? "asc" : "desc", e.getSortingFn = () => {
if (!e) throw Error();
- return jM(e.columnDef.sortingFn) ? e.columnDef.sortingFn : e.columnDef.sortingFn === "auto" ? e.getAutoSortingFn() : t.options.sortingFns?.[e.columnDef.sortingFn] ?? BN[e.columnDef.sortingFn];
+ return iN(e.columnDef.sortingFn) ? e.columnDef.sortingFn : e.columnDef.sortingFn === "auto" ? e.getAutoSortingFn() : t.options.sortingFns?.[e.columnDef.sortingFn] ?? VN[e.columnDef.sortingFn];
}, e.toggleSorting = (n, r) => {
let i = e.getNextSortingOrder(), a = n != null;
t.setSorting((o) => {
@@ -41923,15 +41923,15 @@ var BN = {
}, e.getPreSortedRowModel = () => e.getGroupedRowModel(), e.getSortedRowModel = () => (!e._getSortedRowModel && e.options.getSortedRowModel && (e._getSortedRowModel = e.options.getSortedRowModel(e)), e.options.manualSorting || !e._getSortedRowModel ? e.getPreSortedRowModel() : e._getSortedRowModel());
}
},
- nN,
- vN,
- SN,
- wN,
- TN,
- uN
+ bfe,
+ Afe,
+ jfe,
+ Mfe,
+ Nfe,
+ Tfe
];
-function Hfe(e) {
- let t = [...Vfe, ...e._features ?? []], n = { _features: t }, r = n._features.reduce((e, t) => Object.assign(e, t.getDefaultOptions == null ? void 0 : t.getDefaultOptions(n)), {}), i = (e) => n.options.mergeOptions ? n.options.mergeOptions(r, e) : {
+function Vfe(e) {
+ let t = [...Bfe, ...e._features ?? []], n = { _features: t }, r = n._features.reduce((e, t) => Object.assign(e, t.getDefaultOptions == null ? void 0 : t.getDefaultOptions(n)), {}), i = (e) => n.options.mergeOptions ? n.options.mergeOptions(r, e) : {
...r,
...e
}, a = { ...e.initialState ?? {} };
@@ -41957,7 +41957,7 @@ function Hfe(e) {
n.setState(n.initialState);
},
setOptions: (e) => {
- let t = kM(e, n.options);
+ let t = nN(e, n.options);
n.options = i(t);
},
getState: () => n.options.state,
@@ -41972,7 +41972,7 @@ function Hfe(e) {
if (!r && (r = n.getCoreRowModel().rowsById[e], !r)) throw Error();
return r;
},
- _getDefaultColumnDef: MM(() => [n.options.defaultColumn], (e) => (e ??= {}, {
+ _getDefaultColumnDef: aN(() => [n.options.defaultColumn], (e) => (e ??= {}, {
header: (e) => {
let t = e.header.column.columnDef;
return t.accessorKey ? t.accessorKey : t.accessorFn ? t.id : null;
@@ -41983,20 +41983,20 @@ function Hfe(e) {
},
...n._features.reduce((e, t) => Object.assign(e, t.getDefaultColumnDef == null ? void 0 : t.getDefaultColumnDef()), {}),
...e
- }), NM(e, "debugColumns", "_getDefaultColumnDef")),
+ }), oN(e, "debugColumns", "_getDefaultColumnDef")),
_getColumnDefs: () => n.options.columns,
- getAllColumns: MM(() => [n._getColumnDefs()], (e) => {
+ getAllColumns: aN(() => [n._getColumnDefs()], (e) => {
let t = function(e, r, i) {
return i === void 0 && (i = 0), e.map((e) => {
- let a = FM(n, e, i, r), o = e;
+ let a = hfe(n, e, i, r), o = e;
return a.columns = o.columns ? t(o.columns, a, i + 1) : [], a;
});
};
return t(e);
- }, NM(e, "debugColumns", "getAllColumns")),
- getAllFlatColumns: MM(() => [n.getAllColumns()], (e) => e.flatMap((e) => e.getFlatColumns()), NM(e, "debugColumns", "getAllFlatColumns")),
- _getAllFlatColumnsById: MM(() => [n.getAllFlatColumns()], (e) => e.reduce((e, t) => (e[t.id] = t, e), {}), NM(e, "debugColumns", "getAllFlatColumnsById")),
- getAllLeafColumns: MM(() => [n.getAllColumns(), n._getOrderColumnsFn()], (e, t) => t(e.flatMap((e) => e.getLeafColumns())), NM(e, "debugColumns", "getAllLeafColumns")),
+ }, oN(e, "debugColumns", "getAllColumns")),
+ getAllFlatColumns: aN(() => [n.getAllColumns()], (e) => e.flatMap((e) => e.getFlatColumns()), oN(e, "debugColumns", "getAllFlatColumns")),
+ _getAllFlatColumnsById: aN(() => [n.getAllFlatColumns()], (e) => e.reduce((e, t) => (e[t.id] = t, e), {}), oN(e, "debugColumns", "getAllFlatColumnsById")),
+ getAllLeafColumns: aN(() => [n.getAllColumns(), n._getOrderColumnsFn()], (e, t) => t(e.flatMap((e) => e.getLeafColumns())), oN(e, "debugColumns", "getAllLeafColumns")),
getColumn: (e) => n._getAllFlatColumnsById()[e]
};
Object.assign(n, c);
@@ -42006,8 +42006,8 @@ function Hfe(e) {
}
return n;
}
-function VN() {
- return (e) => MM(() => [e.options.data], (t) => {
+function HN() {
+ return (e) => aN(() => [e.options.data], (t) => {
let n = {
rows: [],
flatRows: [],
@@ -42016,7 +42016,7 @@ function VN() {
i === void 0 && (i = 0);
let o = [];
for (let c = 0; c < t.length; c++) {
- let l = BM(e, e._getRowId(t[c], c, a), t[c], c, i, void 0, a?.id);
+ let l = _fe(e, e._getRowId(t[c], c, a), t[c], c, i, void 0, a?.id);
if (n.flatRows.push(l), n.rowsById[l.id] = l, o.push(l), e.options.getSubRows) {
var s;
l.originalSubRows = e.options.getSubRows(t[c], c), (s = l.originalSubRows) != null && s.length && (l.subRows = r(l.originalSubRows, i + 1, l));
@@ -42025,9 +42025,9 @@ function VN() {
return o;
};
return n.rows = r(t), n;
- }, NM(e.options, "debugTable", "getRowModel", () => e._autoResetPageIndex()));
+ }, oN(e.options, "debugTable", "getRowModel", () => e._autoResetPageIndex()));
}
-function Ufe(e) {
+function Hfe(e) {
let t = [], n = (e) => {
var r;
t.push(e), (r = e.subRows) != null && r.length && e.getIsExpanded() && e.subRows.forEach(n);
@@ -42038,8 +42038,8 @@ function Ufe(e) {
rowsById: e.rowsById
};
}
-function HN(e) {
- return (e) => MM(() => [
+function UN(e) {
+ return (e) => aN(() => [
e.getState().pagination,
e.getPrePaginationRowModel(),
e.options.paginateExpandedRows ? void 0 : e.getState().expanded
@@ -42052,7 +42052,7 @@ function HN(e) {
rows: a,
flatRows: o,
rowsById: s
- } : Ufe({
+ } : Hfe({
rows: a,
flatRows: o,
rowsById: s
@@ -42061,32 +42061,32 @@ function HN(e) {
u.flatRows.push(e), e.subRows.length && e.subRows.forEach(d);
};
return u.rows.forEach(d), u;
- }, NM(e.options, "debugTable", "getPaginationRowModel"));
+ }, oN(e.options, "debugTable", "getPaginationRowModel"));
}
//#endregion
//#region node_modules/@tanstack/react-table/build/lib/index.mjs
-function UN(e, t) {
- return e ? Wfe(e) ? /*#__PURE__*/ R.createElement(e, t) : e : null;
+function WN(e, t) {
+ return e ? Ufe(e) ? /*#__PURE__*/ R.createElement(e, t) : e : null;
}
-function Wfe(e) {
- return Gfe(e) || typeof e == "function" || Kfe(e);
+function Ufe(e) {
+ return Wfe(e) || typeof e == "function" || Gfe(e);
}
-function Gfe(e) {
+function Wfe(e) {
return typeof e == "function" && (() => {
let t = Object.getPrototypeOf(e);
return t.prototype && t.prototype.isReactComponent;
})();
}
-function Kfe(e) {
+function Gfe(e) {
return typeof e == "object" && typeof e.$$typeof == "symbol" && ["react.memo", "react.forward_ref"].includes(e.$$typeof.description);
}
-function WN(e) {
+function GN(e) {
let t = {
state: {},
onStateChange: () => {},
renderFallbackValue: null,
...e
- }, [n] = R.useState(() => ({ current: Hfe(t) })), [r, i] = R.useState(() => n.current.initialState);
+ }, [n] = R.useState(() => ({ current: Vfe(t) })), [r, i] = R.useState(() => n.current.initialState);
return n.current.setOptions((t) => ({
...t,
...e,
@@ -42101,7 +42101,7 @@ function WN(e) {
}
//#endregion
//#region src/react/boardui/components/base/switch/switch.tsx
-var qfe = Li({
+var Kfe = Li({
sm: {
track: "h-4 w-7",
trackRadius: {
@@ -42163,8 +42163,8 @@ var qfe = Li({
}
}
});
-function Jfe({ state: e, size: t = "md", shape: n = "pill" }) {
- let r = qfe[t];
+function qfe({ state: e, size: t = "md", shape: n = "pill" }) {
+ let r = Kfe[t];
return /* @__PURE__ */ (0, z.jsx)("span", {
"aria-hidden": !0,
className: Ii("relative shrink-0 transition-colors duration-200 ease", r.track, r.trackRadius[n], e.isSelected ? Ii("bg-linear-to-b from-accent-500 to-accent-600", r.onShadow) : "bg-background-tertiary-default", e.isDisabled && "opacity-50", e.isFocusVisible && "ring-2 ring-border-focus-ring ring-offset-2"),
@@ -42174,12 +42174,12 @@ function Jfe({ state: e, size: t = "md", shape: n = "pill" }) {
})
});
}
-function GN({ className: e, children: t, size: n = "md", shape: r = "pill", ref: i, ...a }) {
- return /* @__PURE__ */ (0, z.jsx)(Yee, {
+function KN({ className: e, children: t, size: n = "md", shape: r = "pill", ref: i, ...a }) {
+ return /* @__PURE__ */ (0, z.jsx)(Jee, {
ref: i,
...a,
className: (t) => Ii("group inline-flex items-center gap-2 select-none", t.isDisabled ? "cursor-not-allowed" : "cursor-pointer", typeof e == "function" ? e(t) : e),
- children: (e) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(Jfe, {
+ children: (e) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(qfe, {
state: e,
size: n,
shape: r
@@ -42191,50 +42191,50 @@ function GN({ className: e, children: t, size: n = "md", shape: r = "pill", ref:
}
//#endregion
//#region src/react/components/legacy-avatar.ts
-var KN = "[&_img]:absolute [&_img]:inset-0 [&_img]:size-full [&_img]:max-w-none [&_img]:max-h-none [&_img]:object-cover", qN = (0, R.createContext)({});
+var qN = "[&_img]:absolute [&_img]:inset-0 [&_img]:size-full [&_img]:max-w-none [&_img]:max-h-none [&_img]:object-cover", JN = (0, R.createContext)({});
//#endregion
//#region node_modules/framer-motion/dist/es/utils/use-constant.mjs
-function JN(e) {
+function YN(e) {
let t = (0, R.useRef)(null);
return t.current === null && (t.current = e()), t.current;
}
//#endregion
//#region node_modules/framer-motion/dist/es/utils/use-isomorphic-effect.mjs
-var YN = typeof window < "u" ? R.useLayoutEffect : R.useEffect, XN = /* @__PURE__ */ (0, R.createContext)(null), ZN = (0, R.createContext)({
+var XN = typeof window < "u" ? R.useLayoutEffect : R.useEffect, ZN = /* @__PURE__ */ (0, R.createContext)(null), QN = (0, R.createContext)({
transformPagePoint: (e) => e,
isStatic: !1,
reducedMotion: "never"
});
//#endregion
//#region node_modules/framer-motion/dist/es/utils/use-composed-ref.mjs
-function QN(e, t) {
+function $N(e, t) {
if (typeof e == "function") return e(t);
e != null && (e.current = t);
}
-function Yfe(...e) {
+function Jfe(...e) {
return (t) => {
let n = !1, r = e.map((e) => {
- let r = QN(e, t);
+ let r = $N(e, t);
return !n && typeof r == "function" && (n = !0), r;
});
if (n) return () => {
for (let t = 0; t < r.length; t++) {
let n = r[t];
- typeof n == "function" ? n() : QN(e[t], null);
+ typeof n == "function" ? n() : $N(e[t], null);
}
};
};
}
-function Xfe(...e) {
- return R.useCallback(Yfe(...e), e);
+function Yfe(...e) {
+ return R.useCallback(Jfe(...e), e);
}
//#endregion
//#region node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.mjs
-var Zfe = class extends R.Component {
+var Xfe = class extends R.Component {
getSnapshotBeforeUpdate(e) {
let t = this.props.childRef.current;
- if (JT(t) && e.isPresent && !this.props.isPresent && this.props.pop !== !1) {
- let e = t.offsetParent, n = JT(e) && e.offsetWidth || 0, r = JT(e) && e.offsetHeight || 0, i = getComputedStyle(t), a = this.props.sizeRef.current;
+ if (UT(t) && e.isPresent && !this.props.isPresent && this.props.pop !== !1) {
+ let e = t.offsetParent, n = UT(e) && e.offsetWidth || 0, r = UT(e) && e.offsetHeight || 0, i = getComputedStyle(t), a = this.props.sizeRef.current;
a.height = parseFloat(i.height), a.width = parseFloat(i.width), a.top = t.offsetTop, a.left = t.offsetLeft, a.right = n - a.width - a.left, a.bottom = r - a.height - a.top, a.direction = i.direction;
}
return null;
@@ -42244,7 +42244,7 @@ var Zfe = class extends R.Component {
return this.props.children;
}
};
-function Qfe({ children: e, isPresent: t, anchorX: n, anchorY: r, root: i, pop: a }) {
+function Zfe({ children: e, isPresent: t, anchorX: n, anchorY: r, root: i, pop: a }) {
let o = (0, R.useId)(), s = (0, R.useRef)(null), c = (0, R.useRef)({
width: 0,
height: 0,
@@ -42253,7 +42253,7 @@ function Qfe({ children: e, isPresent: t, anchorX: n, anchorY: r, root: i, pop:
right: 0,
bottom: 0,
direction: "ltr"
- }), { nonce: l } = (0, R.useContext)(ZN), u = Xfe(s, a === !1 ? void 0 : e.props?.ref ?? e?.ref);
+ }), { nonce: l } = (0, R.useContext)(QN), u = Yfe(s, a === !1 ? void 0 : e.props?.ref ?? e?.ref);
return (0, R.useInsertionEffect)(() => {
let { width: e, height: u, top: d, left: f, right: p, bottom: m, direction: h } = c.current;
if (t || a === !1 || !s.current || !e || !u) return;
@@ -42273,7 +42273,7 @@ function Qfe({ children: e, isPresent: t, anchorX: n, anchorY: r, root: i, pop:
`), () => {
s.current?.removeAttribute("data-motion-pop-id"), b.contains(y) && b.removeChild(y);
};
- }, [t]), (0, z.jsx)(Zfe, {
+ }, [t]), (0, z.jsx)(Xfe, {
isPresent: t,
childRef: s,
sizeRef: c,
@@ -42283,9 +42283,9 @@ function Qfe({ children: e, isPresent: t, anchorX: n, anchorY: r, root: i, pop:
}
//#endregion
//#region node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.mjs
-var $fe = ({ children: e, initial: t, isPresent: n, onExitComplete: r, custom: i, presenceAffectsLayout: a, mode: o, anchorX: s, anchorY: c, root: l }) => {
- let u = JN(epe), d = (0, R.useId)(), f = (0, R.useRef)(n), p = (0, R.useRef)(r);
- YN(() => {
+var Qfe = ({ children: e, initial: t, isPresent: n, onExitComplete: r, custom: i, presenceAffectsLayout: a, mode: o, anchorX: s, anchorY: c, root: l }) => {
+ let u = YN($fe), d = (0, R.useId)(), f = (0, R.useRef)(n), p = (0, R.useRef)(r);
+ XN(() => {
f.current = n, p.current = r;
});
let m = !0, h = (0, R.useMemo)(() => (m = !1, {
@@ -42310,25 +42310,25 @@ var $fe = ({ children: e, initial: t, isPresent: n, onExitComplete: r, custom: i
u.forEach((e, t) => u.set(t, !1));
}, [n]), R.useEffect(() => {
!n && !u.size && r && r();
- }, [n]), e = (0, z.jsx)(Qfe, {
+ }, [n]), e = (0, z.jsx)(Zfe, {
pop: o === "popLayout",
isPresent: n,
anchorX: s,
anchorY: c,
root: l,
children: e
- }), (0, z.jsx)(XN.Provider, {
+ }), (0, z.jsx)(ZN.Provider, {
value: h,
children: e
});
};
-function epe() {
+function $fe() {
return /* @__PURE__ */ new Map();
}
//#endregion
//#region node_modules/framer-motion/dist/es/components/AnimatePresence/use-presence.mjs
-function $N(e = !0) {
- let t = (0, R.useContext)(XN);
+function eP(e = !0) {
+ let t = (0, R.useContext)(ZN);
if (t === null) return [!0, null];
let { isPresent: n, onExitComplete: r, register: i } = t, a = (0, R.useId)();
(0, R.useEffect)(() => {
@@ -42341,16 +42341,16 @@ function $N(e = !0) {
]);
return !n && r ? [!1, o] : [!0];
}
-function tpe() {
- return npe((0, R.useContext)(XN));
+function epe() {
+ return tpe((0, R.useContext)(ZN));
}
-function npe(e) {
+function tpe(e) {
return e === null || e.isPresent;
}
//#endregion
//#region node_modules/framer-motion/dist/es/components/AnimatePresence/utils.mjs
-var eP = (e) => e.key || "";
-function tP(e) {
+var tP = (e) => e.key || "";
+function nP(e) {
let t = [];
return R.Children.forEach(e, (e) => {
(0, R.isValidElement)(e) && t.push(e);
@@ -42358,12 +42358,12 @@ function tP(e) {
}
//#endregion
//#region node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs
-var rpe = ({ children: e, custom: t, initial: n = !0, onExitComplete: r, presenceAffectsLayout: i = !0, mode: a = "sync", propagate: o = !1, anchorX: s = "left", anchorY: c = "top", root: l }) => {
- let [u, d] = $N(o), f = (0, R.useMemo)(() => tP(e), [e]), p = o && !u ? [] : f.map(eP), m = (0, R.useRef)(!0), h = (0, R.useRef)(f), g = JN(() => /* @__PURE__ */ new Map()), _ = (0, R.useRef)(/* @__PURE__ */ new Set()), [v, y] = (0, R.useState)(f), [b, x] = (0, R.useState)(f);
- YN(() => {
+var npe = ({ children: e, custom: t, initial: n = !0, onExitComplete: r, presenceAffectsLayout: i = !0, mode: a = "sync", propagate: o = !1, anchorX: s = "left", anchorY: c = "top", root: l }) => {
+ let [u, d] = eP(o), f = (0, R.useMemo)(() => nP(e), [e]), p = o && !u ? [] : f.map(tP), m = (0, R.useRef)(!0), h = (0, R.useRef)(f), g = YN(() => /* @__PURE__ */ new Map()), _ = (0, R.useRef)(/* @__PURE__ */ new Set()), [v, y] = (0, R.useState)(f), [b, x] = (0, R.useState)(f);
+ XN(() => {
m.current = !1, h.current = f;
for (let e = 0; e < b.length; e++) {
- let t = eP(b[e]);
+ let t = tP(b[e]);
p.includes(t) ? (g.delete(t), _.current.delete(t)) : g.get(t) !== !0 && g.set(t, !1);
}
}, [
@@ -42375,15 +42375,15 @@ var rpe = ({ children: e, custom: t, initial: n = !0, onExitComplete: r, presenc
if (f !== v) {
let e = [...f];
for (let t = 0; t < b.length; t++) {
- let n = b[t], r = eP(n);
+ let n = b[t], r = tP(n);
p.includes(r) || (e.splice(t, 0, n), S.push(n));
}
- return a === "wait" && S.length && (e = S), x(tP(e)), y(f), null;
+ return a === "wait" && S.length && (e = S), x(nP(e)), y(f), null;
}
- let { forceRender: C } = (0, R.useContext)(qN);
+ let { forceRender: C } = (0, R.useContext)(JN);
return (0, z.jsx)(z.Fragment, { children: b.map((e) => {
- let v = eP(e), y = o && !u ? !1 : f === b || p.includes(v);
- return (0, z.jsx)($fe, {
+ let v = tP(e), y = o && !u ? !1 : f === b || p.includes(v);
+ return (0, z.jsx)(Qfe, {
isPresent: y,
initial: !m.current || n ? void 0 : !1,
custom: t,
@@ -42404,7 +42404,7 @@ var rpe = ({ children: e, custom: t, initial: n = !0, onExitComplete: r, presenc
children: e
}, v);
}) });
-}, nP = (0, R.createContext)({ strict: !1 }), rP = {
+}, rP = (0, R.createContext)({ strict: !1 }), iP = {
animation: [
"animate",
"variants",
@@ -42441,98 +42441,98 @@ var rpe = ({ children: e, custom: t, initial: n = !0, onExitComplete: r, presenc
"onViewportLeave"
],
layout: ["layout", "layoutId"]
-}, iP = !1;
-function ipe() {
- if (iP) return;
+}, aP = !1;
+function rpe() {
+ if (aP) return;
let e = {};
- for (let t in rP) e[t] = { isEnabled: (e) => rP[t].some((t) => !!e[t]) };
- ME(e), iP = !0;
+ for (let t in iP) e[t] = { isEnabled: (e) => iP[t].some((t) => !!e[t]) };
+ DE(e), aP = !0;
}
-function aP() {
- return ipe(), Aoe();
+function oP() {
+ return rpe(), Foe();
}
//#endregion
//#region node_modules/framer-motion/dist/es/motion/features/load-features.mjs
-function ape(e) {
- let t = aP();
+function ipe(e) {
+ let t = oP();
for (let n in e) t[n] = {
...t[n],
...e[n]
};
- ME(t);
+ DE(t);
}
//#endregion
//#region node_modules/framer-motion/dist/es/motion/utils/valid-prop.mjs
-var ope = /* @__PURE__ */ new Set(/* @__PURE__ */ "animate.exit.variants.initial.style.values.variants.transition.transformTemplate.custom.inherit.onBeforeLayoutMeasure.onAnimationStart.onAnimationComplete.onUpdate.onDragStart.onDrag.onDragEnd.onMeasureDragConstraints.onDirectionLock.onDragTransitionEnd._dragX._dragY.onHoverStart.onHoverEnd.onViewportEnter.onViewportLeave.globalTapTarget.propagate.ignoreStrict.viewport".split("."));
-function oP(e) {
- return e.startsWith("while") || e.startsWith("drag") && e !== "draggable" || e.startsWith("layout") || e.startsWith("onTap") || e.startsWith("onPan") || e.startsWith("onLayout") || ope.has(e);
+var ape = /* @__PURE__ */ new Set(/* @__PURE__ */ "animate.exit.variants.initial.style.values.variants.transition.transformTemplate.custom.inherit.onBeforeLayoutMeasure.onAnimationStart.onAnimationComplete.onUpdate.onDragStart.onDrag.onDragEnd.onMeasureDragConstraints.onDirectionLock.onDragTransitionEnd._dragX._dragY.onHoverStart.onHoverEnd.onViewportEnter.onViewportLeave.globalTapTarget.propagate.ignoreStrict.viewport".split("."));
+function sP(e) {
+ return e.startsWith("while") || e.startsWith("drag") && e !== "draggable" || e.startsWith("layout") || e.startsWith("onTap") || e.startsWith("onPan") || e.startsWith("onLayout") || ape.has(e);
}
//#endregion
//#region __vite-optional-peer-dep:@emotion/is-prop-valid:framer-motion
-var spe = /* @__PURE__ */ De({ default: () => sP }), sP, cpe = Te((() => {
- throw sP = {}, Error("Could not resolve \"@emotion/is-prop-valid\" imported by \"framer-motion\". Is it installed?");
-})), cP = (e) => !oP(e);
-function lP(e) {
- typeof e == "function" && (cP = (t) => t.startsWith("on") ? !oP(t) : e(t));
+var ope = /* @__PURE__ */ De({ default: () => cP }), cP, spe = Te((() => {
+ throw cP = {}, Error("Could not resolve \"@emotion/is-prop-valid\" imported by \"framer-motion\". Is it installed?");
+})), lP = (e) => !sP(e);
+function uP(e) {
+ typeof e == "function" && (lP = (t) => t.startsWith("on") ? !sP(t) : e(t));
}
try {
- lP((cpe(), Ae(spe)).default);
+ uP((spe(), Ae(ope)).default);
} catch {}
-function lpe(e, t, n) {
+function cpe(e, t, n) {
let r = {};
- for (let i in e) (i !== "values" || typeof e.values != "object") && (kT(e[i]) || (cP(i) || n === !0 && oP(i) || !t && !oP(i) || e.draggable && i.startsWith("onDrag")) && (r[i] = e[i]));
+ for (let i in e) (i !== "values" || typeof e.values != "object") && (wT(e[i]) || (lP(i) || n === !0 && sP(i) || !t && !sP(i) || e.draggable && i.startsWith("onDrag")) && (r[i] = e[i]));
return r;
}
//#endregion
//#region node_modules/framer-motion/dist/es/components/MotionConfig/index.mjs
-function upe({ children: e, isValidProp: t, ...n }) {
- t && lP(t);
- let r = (0, R.useContext)(ZN);
+function lpe({ children: e, isValidProp: t, ...n }) {
+ t && uP(t);
+ let r = (0, R.useContext)(QN);
n = {
...r,
...n
- }, n.transition = bT(n.transition, r.transition), n.isStatic = JN(() => n.isStatic);
+ }, n.transition = hT(n.transition, r.transition), n.isStatic = YN(() => n.isStatic);
let i = (0, R.useMemo)(() => n, [
JSON.stringify(n.transition),
n.transformPagePoint,
n.reducedMotion,
n.skipAnimations
]);
- return (0, z.jsx)(ZN.Provider, {
+ return (0, z.jsx)(QN.Provider, {
value: i,
children: e
});
}
//#endregion
//#region node_modules/framer-motion/dist/es/context/MotionContext/index.mjs
-var uP = /* @__PURE__ */ (0, R.createContext)({});
+var dP = /* @__PURE__ */ (0, R.createContext)({});
//#endregion
//#region node_modules/framer-motion/dist/es/context/MotionContext/utils.mjs
-function dpe(e, t) {
- if (TE(e)) {
+function upe(e, t) {
+ if (bE(e)) {
let { initial: t, animate: n } = e;
return {
- initial: t === !1 || SE(t) ? t : void 0,
- animate: SE(n) ? n : void 0
+ initial: t === !1 || _E(t) ? t : void 0,
+ animate: _E(n) ? n : void 0
};
}
return e.inherit === !1 ? {} : t;
}
//#endregion
//#region node_modules/framer-motion/dist/es/context/MotionContext/create.mjs
-function fpe(e) {
- let { initial: t, animate: n } = dpe(e, (0, R.useContext)(uP));
+function dpe(e) {
+ let { initial: t, animate: n } = upe(e, (0, R.useContext)(dP));
return (0, R.useMemo)(() => ({
initial: t,
animate: n
- }), [dP(t), dP(n)]);
+ }), [fP(t), fP(n)]);
}
-function dP(e) {
+function fP(e) {
return Array.isArray(e) ? e.join(" ") : e;
}
//#endregion
//#region node_modules/framer-motion/dist/es/render/html/utils/create-render-state.mjs
-var fP = () => ({
+var pP = () => ({
style: {},
transform: {},
transformOrigin: {},
@@ -42540,42 +42540,42 @@ var fP = () => ({
});
//#endregion
//#region node_modules/framer-motion/dist/es/render/html/use-props.mjs
-function pP(e, t, n) {
- for (let r in t) !kT(t[r]) && !rD(r, n) && (e[r] = t[r]);
+function mP(e, t, n) {
+ for (let r in t) !wT(t[r]) && !QE(r, n) && (e[r] = t[r]);
}
-function ppe({ transformTemplate: e }, t) {
+function fpe({ transformTemplate: e }, t) {
return (0, R.useMemo)(() => {
- let n = fP();
- return QE(n, t, e), Object.assign({}, n.vars, n.style);
+ let n = pP();
+ return qE(n, t, e), Object.assign({}, n.vars, n.style);
}, [t]);
}
-function mpe(e, t) {
+function ppe(e, t) {
let n = e.style || {}, r = {};
- return pP(r, n, e), Object.assign(r, ppe(e, t)), r;
+ return mP(r, n, e), Object.assign(r, fpe(e, t)), r;
}
-function hpe(e, t) {
- let n = {}, r = mpe(e, t);
+function mpe(e, t) {
+ let n = {}, r = ppe(e, t);
return e.drag && e.dragListener !== !1 && (n.draggable = !1, r.userSelect = r.WebkitUserSelect = r.WebkitTouchCallout = "none", r.touchAction = e.drag === !0 ? "none" : `pan-${e.drag === "x" ? "y" : "x"}`), e.tabIndex === void 0 && (e.onTap || e.onTapStart || e.whileTap) && (n.tabIndex = 0), n.style = r, n;
}
//#endregion
//#region node_modules/framer-motion/dist/es/render/svg/utils/create-render-state.mjs
-var mP = () => ({
- ...fP(),
+var hP = () => ({
+ ...pP(),
attrs: {}
});
//#endregion
//#region node_modules/framer-motion/dist/es/render/svg/use-props.mjs
-function gpe(e, t, n, r) {
+function hpe(e, t, n, r) {
let i = (0, R.useMemo)(() => {
- let n = mP();
- return aD(n, t, sD(r), e.transformTemplate, e.style), {
+ let n = hP();
+ return eD(n, t, nD(r), e.transformTemplate, e.style), {
...n.attrs,
style: { ...n.style }
};
}, [t]);
if (e.style) {
let t = {};
- pP(t, e.style, e), i.style = {
+ mP(t, e.style, e), i.style = {
...t,
...i.style
};
@@ -42584,7 +42584,7 @@ function gpe(e, t, n, r) {
}
//#endregion
//#region node_modules/framer-motion/dist/es/render/svg/lowercase-elements.mjs
-var _pe = [
+var gpe = [
"animate",
"circle",
"defs",
@@ -42613,17 +42613,17 @@ var _pe = [
];
//#endregion
//#region node_modules/framer-motion/dist/es/render/dom/utils/is-svg-component.mjs
-function hP(e) {
- return typeof e != "string" || e.includes("-") ? !1 : !!(_pe.indexOf(e) > -1 || /[A-Z]/u.test(e));
+function gP(e) {
+ return typeof e != "string" || e.includes("-") ? !1 : !!(gpe.indexOf(e) > -1 || /[A-Z]/u.test(e));
}
//#endregion
//#region node_modules/framer-motion/dist/es/render/dom/use-render.mjs
-function vpe(e, t, n, { latestValues: r }, i, a = !1, o) {
- let s = (o ?? hP(e) ? gpe : hpe)(t, r, i, e), c = lpe(t, typeof e == "string", a), l = e === R.Fragment ? {} : {
+function _pe(e, t, n, { latestValues: r }, i, a = !1, o) {
+ let s = (o ?? gP(e) ? hpe : mpe)(t, r, i, e), c = cpe(t, typeof e == "string", a), l = e === R.Fragment ? {} : {
...c,
...s,
ref: n
- }, { children: u } = t, d = (0, R.useMemo)(() => kT(u) ? u.get() : u, [u]);
+ }, { children: u } = t, d = (0, R.useMemo)(() => wT(u) ? u.get() : u, [u]);
return (0, R.createElement)(e, {
...l,
children: d
@@ -42631,24 +42631,24 @@ function vpe(e, t, n, { latestValues: r }, i, a = !1, o) {
}
//#endregion
//#region node_modules/framer-motion/dist/es/motion/utils/use-visual-state.mjs
-function ype({ scrapeMotionValuesFromProps: e, createRenderState: t }, n, r, i) {
+function vpe({ scrapeMotionValuesFromProps: e, createRenderState: t }, n, r, i) {
return {
- latestValues: bpe(n, r, i, e),
+ latestValues: ype(n, r, i, e),
renderState: t()
};
}
-function bpe(e, t, n, r) {
+function ype(e, t, n, r) {
let i = {}, a = r(e, {});
- for (let e in a) i[e] = RD(a[e]);
- let { initial: o, animate: s } = e, c = TE(e), l = EE(e);
+ for (let e in a) i[e] = ND(a[e]);
+ let { initial: o, animate: s } = e, c = bE(e), l = xE(e);
t && l && !c && e.inherit !== !1 && (o === void 0 && (o = t.initial), s === void 0 && (s = t.animate));
let u = n ? n.initial === !1 : !1;
u ||= o === !1;
let d = u ? s : o;
- if (d && typeof d != "boolean" && !xE(d)) {
+ if (d && typeof d != "boolean" && !gE(d)) {
let t = Array.isArray(d) ? d : [d];
for (let n = 0; n < t.length; n++) {
- let r = TT(e, t[n]);
+ let r = bT(e, t[n]);
if (r) {
let { transitionEnd: e, transition: t, ...n } = r;
for (let e in n) {
@@ -42665,19 +42665,19 @@ function bpe(e, t, n, r) {
}
return i;
}
-var gP = (e) => (t, n) => {
- let r = (0, R.useContext)(uP), i = (0, R.useContext)(XN), a = () => ype(e, t, r, i);
- return n ? a() : JN(a);
-}, xpe = /*@__PURE__*/ gP({
- scrapeMotionValuesFromProps: iD,
- createRenderState: fP
-}), Spe = /*@__PURE__*/ gP({
- scrapeMotionValuesFromProps: cD,
- createRenderState: mP
-}), Cpe = Symbol.for("motionComponentSymbol");
+var _P = (e) => (t, n) => {
+ let r = (0, R.useContext)(dP), i = (0, R.useContext)(ZN), a = () => vpe(e, t, r, i);
+ return n ? a() : YN(a);
+}, bpe = /*@__PURE__*/ _P({
+ scrapeMotionValuesFromProps: $E,
+ createRenderState: pP
+}), xpe = /*@__PURE__*/ _P({
+ scrapeMotionValuesFromProps: rD,
+ createRenderState: hP
+}), Spe = Symbol.for("motionComponentSymbol");
//#endregion
//#region node_modules/framer-motion/dist/es/motion/utils/use-motion-ref.mjs
-function wpe(e, t, n) {
+function Cpe(e, t, n) {
let r = (0, R.useRef)(n);
(0, R.useInsertionEffect)(() => {
r.current = n;
@@ -42696,16 +42696,16 @@ function wpe(e, t, n) {
}
//#endregion
//#region node_modules/framer-motion/dist/es/context/SwitchLayoutGroupContext.mjs
-var _P = (0, R.createContext)({});
+var vP = (0, R.createContext)({});
//#endregion
//#region node_modules/framer-motion/dist/es/utils/is-ref-object.mjs
-function vP(e) {
+function yP(e) {
return e && typeof e == "object" && Object.prototype.hasOwnProperty.call(e, "current");
}
//#endregion
//#region node_modules/framer-motion/dist/es/motion/utils/use-visual-element.mjs
-function Tpe(e, t, n, r, i, a) {
- let { visualElement: o } = (0, R.useContext)(uP), s = (0, R.useContext)(nP), c = (0, R.useContext)(XN), l = (0, R.useContext)(ZN), u = l.reducedMotion, d = l.skipAnimations, f = (0, R.useRef)(null), p = (0, R.useRef)(!1);
+function wpe(e, t, n, r, i, a) {
+ let { visualElement: o } = (0, R.useContext)(dP), s = (0, R.useContext)(rP), c = (0, R.useContext)(ZN), l = (0, R.useContext)(QN), u = l.reducedMotion, d = l.skipAnimations, f = (0, R.useRef)(null), p = (0, R.useRef)(!1);
r ||= s.renderer, !f.current && r && (f.current = r(e, {
visualState: t,
parent: o,
@@ -42716,14 +42716,14 @@ function Tpe(e, t, n, r, i, a) {
skipAnimations: d,
isSVG: a
}), p.current && f.current && (f.current.manuallyAnimateOnMount = !0));
- let m = f.current, h = (0, R.useContext)(_P);
- m && !m.projection && i && (m.type === "html" || m.type === "svg") && Epe(f.current, n, i, h);
+ let m = f.current, h = (0, R.useContext)(vP);
+ m && !m.projection && i && (m.type === "html" || m.type === "svg") && Tpe(f.current, n, i, h);
let g = (0, R.useRef)(!1);
(0, R.useInsertionEffect)(() => {
m && g.current && m.update(n, c);
});
- let _ = n[MT], v = (0, R.useRef)(!!_ && typeof window < "u" && !window.MotionHandoffIsComplete?.(_) && window.MotionHasOptimisedAnimation?.(_));
- return YN(() => {
+ let _ = n[DT], v = (0, R.useRef)(!!_ && typeof window < "u" && !window.MotionHandoffIsComplete?.(_) && window.MotionHasOptimisedAnimation?.(_));
+ return XN(() => {
p.current = !0, m && (g.current = !0, window.MotionIsMounted = !0, m.updateFeatures(), m.scheduleRenderMicrotask(), v.current && m.animationState && m.animationState.animateChanges());
}), (0, R.useEffect)(() => {
m && (!v.current && m.animationState && m.animationState.animateChanges(), v.current &&= (queueMicrotask(() => {
@@ -42731,12 +42731,12 @@ function Tpe(e, t, n, r, i, a) {
}), !1), m.enteringChildren = void 0);
}), m;
}
-function Epe(e, t, n, r) {
+function Tpe(e, t, n, r) {
let { layoutId: i, layout: a, drag: o, dragConstraints: s, layoutScroll: c, layoutRoot: l, layoutAnchor: u, layoutCrossfade: d } = t;
- e.projection = new n(e.latestValues, t["data-framer-portal-id"] ? void 0 : yP(e.parent)), e.projection.setOptions({
+ e.projection = new n(e.latestValues, t["data-framer-portal-id"] ? void 0 : bP(e.parent)), e.projection.setOptions({
layoutId: i,
layout: a,
- alwaysMeasureLayout: !!o || s && vP(s),
+ alwaysMeasureLayout: !!o || s && yP(s),
visualElement: e,
animationType: typeof a == "string" ? a : "both",
initialPromotionConfig: r,
@@ -42746,46 +42746,46 @@ function Epe(e, t, n, r) {
layoutAnchor: u
});
}
-function yP(e) {
- if (e) return e.options.allowProjection === !1 ? yP(e.parent) : e.projection;
+function bP(e) {
+ if (e) return e.options.allowProjection === !1 ? bP(e.parent) : e.projection;
}
//#endregion
//#region node_modules/framer-motion/dist/es/motion/index.mjs
-function bP(e, { forwardMotionProps: t = !1, type: n } = {}, r, i) {
- r && ape(r);
- let a = n ? n === "svg" : hP(e), o = a ? Spe : xpe;
+function xP(e, { forwardMotionProps: t = !1, type: n } = {}, r, i) {
+ r && ipe(r);
+ let a = n ? n === "svg" : gP(e), o = a ? xpe : bpe;
function s(n, s) {
let c, l = {
- ...(0, R.useContext)(ZN),
+ ...(0, R.useContext)(QN),
...n,
- layoutId: Dpe(n)
- }, { isStatic: u } = l, d = fpe(n), f = o(n, u);
+ layoutId: Epe(n)
+ }, { isStatic: u } = l, d = dpe(n), f = o(n, u);
if (!u && typeof window < "u") {
- Ope(l, r);
- let t = kpe(l);
- c = t.MeasureLayout, d.visualElement = Tpe(e, f, l, i, t.ProjectionNode, a);
+ Dpe(l, r);
+ let t = Ope(l);
+ c = t.MeasureLayout, d.visualElement = wpe(e, f, l, i, t.ProjectionNode, a);
}
- return (0, z.jsxs)(uP.Provider, {
+ return (0, z.jsxs)(dP.Provider, {
value: d,
children: [c && d.visualElement ? (0, z.jsx)(c, {
visualElement: d.visualElement,
...l
- }) : null, vpe(e, n, wpe(f, d.visualElement, s), f, u, t, a)]
+ }) : null, _pe(e, n, Cpe(f, d.visualElement, s), f, u, t, a)]
});
}
s.displayName = `motion.${typeof e == "string" ? e : `create(${e.displayName ?? e.name ?? ""})`}`;
let c = (0, R.forwardRef)(s);
- return c[Cpe] = e, c;
+ return c[Spe] = e, c;
}
-function Dpe({ layoutId: e }) {
- let t = (0, R.useContext)(qN).id;
+function Epe({ layoutId: e }) {
+ let t = (0, R.useContext)(JN).id;
return t && e !== void 0 ? t + "-" + e : e;
}
-function Ope(e, t) {
- (0, R.useContext)(nP).strict;
+function Dpe(e, t) {
+ (0, R.useContext)(rP).strict;
}
-function kpe(e) {
- let { drag: t, layout: n } = aP();
+function Ope(e) {
+ let { drag: t, layout: n } = oP();
if (!t && !n) return {};
let r = {
...t,
@@ -42798,20 +42798,20 @@ function kpe(e) {
}
//#endregion
//#region node_modules/framer-motion/dist/es/render/components/create-proxy.mjs
-function Ape(e, t) {
- if (typeof Proxy > "u") return bP;
- let n = /* @__PURE__ */ new Map(), r = (n, r) => bP(n, r, e, t);
- return new Proxy((e, t) => r(e, t), { get: (i, a) => a === "create" ? r : (n.has(a) || n.set(a, bP(a, void 0, e, t)), n.get(a)) });
+function kpe(e, t) {
+ if (typeof Proxy > "u") return xP;
+ let n = /* @__PURE__ */ new Map(), r = (n, r) => xP(n, r, e, t);
+ return new Proxy((e, t) => r(e, t), { get: (i, a) => a === "create" ? r : (n.has(a) || n.set(a, xP(a, void 0, e, t)), n.get(a)) });
}
//#endregion
//#region node_modules/framer-motion/dist/es/render/dom/create-visual-element.mjs
-var jpe = (e, t) => t.isSVG ?? hP(e) ? new qoe(t) : new Voe(t, { allowProjection: e !== R.Fragment }), Mpe = class extends PE {
+var Ape = (e, t) => t.isSVG ?? gP(e) ? new Qoe(t) : new Koe(t, { allowProjection: e !== R.Fragment }), jpe = class extends kE {
constructor(e) {
- super(e), e.animationState ||= Qoe(e);
+ super(e), e.animationState ||= rse(e);
}
updateAnimationControlsSubscription() {
let { animate: e } = this.node.getProps();
- xE(e) && (this.unmountControls = e.subscribe(this.node));
+ gE(e) && (this.unmountControls = e.subscribe(this.node));
}
mount() {
this.updateAnimationControlsSubscription();
@@ -42823,11 +42823,11 @@ var jpe = (e, t) => t.isSVG ?? hP(e) ? new qoe(t) : new Voe(t, { allowProjection
unmount() {
this.node.animationState.reset(), this.unmountControls?.();
}
-}, Npe = 0, Ppe = {
- animation: { Feature: Mpe },
- exit: { Feature: class extends PE {
+}, Mpe = 0, Npe = {
+ animation: { Feature: jpe },
+ exit: { Feature: class extends kE {
constructor() {
- super(...arguments), this.id = Npe++, this.isExitComplete = !1;
+ super(...arguments), this.id = Mpe++, this.isExitComplete = !1;
}
update() {
if (!this.node.presenceContext) return;
@@ -42837,7 +42837,7 @@ var jpe = (e, t) => t.isSVG ?? hP(e) ? new qoe(t) : new Voe(t, { allowProjection
if (this.isExitComplete) {
let { initial: e, custom: t } = this.node.getProps();
if (typeof e == "string" || typeof e == "object" && e && !Array.isArray(e)) {
- let n = ET(this.node, e, t);
+ let n = xT(this.node, e, t);
if (n) {
let { transition: e, transitionEnd: t, ...r } = n;
for (let e in r) this.node.getValue(e)?.jump(r[e]);
@@ -42862,21 +42862,21 @@ var jpe = (e, t) => t.isSVG ?? hP(e) ? new qoe(t) : new Voe(t, { allowProjection
};
//#endregion
//#region node_modules/framer-motion/dist/es/events/event-info.mjs
-function xP(e) {
+function SP(e) {
return { point: {
x: e.pageX,
y: e.pageY
} };
}
-var Fpe = (e) => (t) => eE(t) && e(t, xP(t));
+var Ppe = (e) => (t) => YT(t) && e(t, SP(t));
//#endregion
//#region node_modules/framer-motion/dist/es/events/add-pointer-event.mjs
-function SP(e, t, n, r) {
- return LD(e, t, Fpe(n), r);
+function CP(e, t, n, r) {
+ return MD(e, t, Ppe(n), r);
}
//#endregion
//#region node_modules/framer-motion/dist/es/utils/get-context-window.mjs
-var CP = ({ current: e }) => e ? e.ownerDocument.defaultView : null, wP = /*#__PURE__*/ new Set(["auto", "scroll"]), TP = class {
+var wP = ({ current: e }) => e ? e.ownerDocument.defaultView : null, TP = /*#__PURE__*/ new Set(["auto", "scroll"]), EP = class {
constructor(e, t, { transformPagePoint: n, contextWindow: r = window, dragSnapToOrigin: i = !1, distanceThreshold: a = 3, element: o } = {}) {
if (this.startEvent = null, this.lastMoveEvent = null, this.lastMoveEventInfo = null, this.lastRawMoveEventInfo = null, this.handlers = {}, this.contextWindow = window, this.scrollPositions = /* @__PURE__ */ new Map(), this.removeScrollListeners = null, this.onElementScroll = (e) => {
this.handleScroll(e.target);
@@ -42884,13 +42884,13 @@ var CP = ({ current: e }) => e ? e.ownerDocument.defaultView : null, wP = /*#__P
this.handleScroll(window);
}, this.updatePoint = () => {
if (!(this.lastMoveEvent && this.lastMoveEventInfo)) return;
- this.lastRawMoveEventInfo && (this.lastMoveEventInfo = EP(this.lastRawMoveEventInfo, this.transformPagePoint));
- let e = OP(this.lastMoveEventInfo, this.history), t = this.startEvent !== null, n = Hse(e.offset, {
+ this.lastRawMoveEventInfo && (this.lastMoveEventInfo = DP(this.lastRawMoveEventInfo, this.transformPagePoint));
+ let e = kP(this.lastMoveEventInfo, this.history), t = this.startEvent !== null, n = qse(e.offset, {
x: 0,
y: 0
}) >= this.distanceThreshold;
if (!t && !n) return;
- let { point: r } = e, { timestamp: i } = jC;
+ let { point: r } = e, { timestamp: i } = rC;
this.history.push({
...r,
timestamp: i
@@ -42898,33 +42898,33 @@ var CP = ({ current: e }) => e ? e.ownerDocument.defaultView : null, wP = /*#__P
let { onStart: a, onMove: o } = this.handlers;
t || (a && a(this.lastMoveEvent, e), this.startEvent = this.lastMoveEvent), o && o(this.lastMoveEvent, e);
}, this.handlePointerMove = (e, t) => {
- this.lastMoveEvent = e, this.lastRawMoveEventInfo = t, this.lastMoveEventInfo = EP(t, this.transformPagePoint), kC.update(this.updatePoint, !0);
+ this.lastMoveEvent = e, this.lastRawMoveEventInfo = t, this.lastMoveEventInfo = DP(t, this.transformPagePoint), tC.update(this.updatePoint, !0);
}, this.handlePointerUp = (e, t) => {
this.end();
let { onEnd: n, onSessionEnd: r, resumeAnimation: i } = this.handlers;
if ((this.dragSnapToOrigin || !this.startEvent) && i && i(), !(this.lastMoveEvent && this.lastMoveEventInfo)) return;
- let a = OP(e.type === "pointercancel" ? this.lastMoveEventInfo : EP(t, this.transformPagePoint), this.history);
+ let a = kP(e.type === "pointercancel" ? this.lastMoveEventInfo : DP(t, this.transformPagePoint), this.history);
this.startEvent && n && n(e, a), r && r(e, a);
- }, !eE(e)) return;
+ }, !YT(e)) return;
this.dragSnapToOrigin = i, this.handlers = t, this.transformPagePoint = n, this.distanceThreshold = a, this.contextWindow = r || window;
- let s = EP(xP(e), this.transformPagePoint), { point: c } = s, { timestamp: l } = jC;
+ let s = DP(SP(e), this.transformPagePoint), { point: c } = s, { timestamp: l } = rC;
this.history = [{
...c,
timestamp: l
}];
let { onSessionStart: u } = t;
- u && u(e, OP(s, this.history));
+ u && u(e, kP(s, this.history));
let d = {
passive: !0,
capture: !0
};
- this.removeListeners = oC(SP(this.contextWindow, "pointermove", this.handlePointerMove, d), SP(this.contextWindow, "pointerup", this.handlePointerUp, d), SP(this.contextWindow, "pointercancel", this.handlePointerUp, d)), o && this.startScrollTracking(o);
+ this.removeListeners = MS(CP(this.contextWindow, "pointermove", this.handlePointerMove, d), CP(this.contextWindow, "pointerup", this.handlePointerUp, d), CP(this.contextWindow, "pointercancel", this.handlePointerUp, d)), o && this.startScrollTracking(o);
}
startScrollTracking(e) {
let t = e.parentElement;
for (; t;) {
let e = getComputedStyle(t);
- (wP.has(e.overflowX) || wP.has(e.overflowY)) && this.scrollPositions.set(t, {
+ (TP.has(e.overflowX) || TP.has(e.overflowY)) && this.scrollPositions.set(t, {
x: t.scrollLeft,
y: t.scrollTop
}), t = t.parentElement;
@@ -42949,51 +42949,51 @@ var CP = ({ current: e }) => e ? e.ownerDocument.defaultView : null, wP = /*#__P
x: r.x - t.x,
y: r.y - t.y
};
- (i.x !== 0 || i.y !== 0) && (n ? this.lastMoveEventInfo && (this.lastMoveEventInfo.point.x += i.x, this.lastMoveEventInfo.point.y += i.y) : this.history.length > 0 && (this.history[0].x -= i.x, this.history[0].y -= i.y), this.scrollPositions.set(e, r), kC.update(this.updatePoint, !0));
+ (i.x !== 0 || i.y !== 0) && (n ? this.lastMoveEventInfo && (this.lastMoveEventInfo.point.x += i.x, this.lastMoveEventInfo.point.y += i.y) : this.history.length > 0 && (this.history[0].x -= i.x, this.history[0].y -= i.y), this.scrollPositions.set(e, r), tC.update(this.updatePoint, !0));
}
updateHandlers(e) {
this.handlers = e;
}
end() {
- this.removeListeners && this.removeListeners(), this.removeScrollListeners && this.removeScrollListeners(), this.scrollPositions.clear(), AC(this.updatePoint);
+ this.removeListeners && this.removeListeners(), this.removeScrollListeners && this.removeScrollListeners(), this.scrollPositions.clear(), nC(this.updatePoint);
}
};
-function EP(e, t) {
+function DP(e, t) {
return t ? { point: t(e.point) } : e;
}
-function DP(e, t) {
+function OP(e, t) {
return {
x: e.x - t.x,
y: e.y - t.y
};
}
-function OP({ point: e }, t) {
+function kP({ point: e }, t) {
return {
point: e,
- delta: DP(e, kP(t)),
- offset: DP(e, Ipe(t)),
- velocity: Lpe(t, .1)
+ delta: OP(e, AP(t)),
+ offset: OP(e, Fpe(t)),
+ velocity: Ipe(t, .1)
};
}
-function Ipe(e) {
+function Fpe(e) {
return e[0];
}
-function kP(e) {
+function AP(e) {
return e[e.length - 1];
}
-function Lpe(e, t) {
+function Ipe(e, t) {
if (e.length < 2) return {
x: 0,
y: 0
};
- let n = e.length - 1, r = null, i = kP(e);
- for (; n >= 0 && (r = e[n], !(i.timestamp - r.timestamp > /* @__PURE__ */ lC(t)));) n--;
+ let n = e.length - 1, r = null, i = AP(e);
+ for (; n >= 0 && (r = e[n], !(i.timestamp - r.timestamp > /* @__PURE__ */ FS(t)));) n--;
if (!r) return {
x: 0,
y: 0
};
- r === e[0] && e.length > 2 && i.timestamp - r.timestamp > /* @__PURE__ */ lC(t) * 2 && (r = e[1]);
- let a = /* @__PURE__ */ uC(i.timestamp - r.timestamp);
+ r === e[0] && e.length > 2 && i.timestamp - r.timestamp > /* @__PURE__ */ FS(t) * 2 && (r = e[1]);
+ let a = /* @__PURE__ */ IS(i.timestamp - r.timestamp);
if (a === 0) return {
x: 0,
y: 0
@@ -43006,86 +43006,86 @@ function Lpe(e, t) {
}
//#endregion
//#region node_modules/framer-motion/dist/es/gestures/drag/utils/constraints.mjs
-function Rpe(e, { min: t, max: n }, r) {
- return t !== void 0 && e < t ? e = r ? uw(t, e, r.min) : Math.max(e, t) : n !== void 0 && e > n && (e = r ? uw(n, e, r.max) : Math.min(e, n)), e;
+function Lpe(e, { min: t, max: n }, r) {
+ return t !== void 0 && e < t ? e = r ? YC(t, e, r.min) : Math.max(e, t) : n !== void 0 && e > n && (e = r ? YC(n, e, r.max) : Math.min(e, n)), e;
}
-function AP(e, t, n) {
+function jP(e, t, n) {
return {
min: t === void 0 ? void 0 : e.min + t,
max: n === void 0 ? void 0 : e.max + n - (e.max - e.min)
};
}
-function zpe(e, { top: t, left: n, bottom: r, right: i }) {
+function Rpe(e, { top: t, left: n, bottom: r, right: i }) {
return {
- x: AP(e.x, n, i),
- y: AP(e.y, t, r)
+ x: jP(e.x, n, i),
+ y: jP(e.y, t, r)
};
}
-function jP(e, t) {
+function MP(e, t) {
let n = t.min - e.min, r = t.max - e.max;
return t.max - t.min < e.max - e.min && ([n, r] = [r, n]), {
min: n,
max: r
};
}
-function Bpe(e, t) {
+function zpe(e, t) {
return {
- x: jP(e.x, t.x),
- y: jP(e.y, t.y)
+ x: MP(e.x, t.x),
+ y: MP(e.y, t.y)
};
}
-function Vpe(e, t) {
- let n = .5, r = gD(e), i = gD(t);
- return i > r ? n = /* @__PURE__ */ sC(t.min, t.max - r, e.min) : r > i && (n = /* @__PURE__ */ sC(e.min, e.max - i, t.min)), $S(0, 1, n);
+function Bpe(e, t) {
+ let n = .5, r = dD(e), i = dD(t);
+ return i > r ? n = /* @__PURE__ */ NS(t.min, t.max - r, e.min) : r > i && (n = /* @__PURE__ */ NS(e.min, e.max - i, t.min)), TS(0, 1, n);
}
-function Hpe(e, t) {
+function Vpe(e, t) {
let n = {};
return t.min !== void 0 && (n.min = t.min - e.min), t.max !== void 0 && (n.max = t.max - e.min), n;
}
-var MP = .35;
-function Upe(e = MP) {
- return e === !1 ? e = 0 : e === !0 && (e = MP), {
- x: NP(e, "left", "right"),
- y: NP(e, "top", "bottom")
+var NP = .35;
+function Hpe(e = NP) {
+ return e === !1 ? e = 0 : e === !0 && (e = NP), {
+ x: PP(e, "left", "right"),
+ y: PP(e, "top", "bottom")
};
}
-function NP(e, t, n) {
+function PP(e, t, n) {
return {
- min: PP(e, t),
- max: PP(e, n)
+ min: FP(e, t),
+ max: FP(e, n)
};
}
-function PP(e, t) {
+function FP(e, t) {
return typeof e == "number" ? e : e[t] || 0;
}
//#endregion
//#region node_modules/framer-motion/dist/es/gestures/drag/VisualElementDragControls.mjs
-var Wpe = /* @__PURE__ */ new WeakMap(), Gpe = class {
+var Upe = /* @__PURE__ */ new WeakMap(), Wpe = class {
constructor(e) {
this.openDragLock = null, this.isDragging = !1, this.currentDirection = null, this.originPoint = {
x: 0,
y: 0
- }, this.constraints = !1, this.hasMutatedConstraints = !1, this.elastic = bE(), this.latestPointerEvent = null, this.latestPanInfo = null, this.visualElement = e;
+ }, this.constraints = !1, this.hasMutatedConstraints = !1, this.elastic = hE(), this.latestPointerEvent = null, this.latestPanInfo = null, this.visualElement = e;
}
start(e, { snapToCursor: t = !1, distanceThreshold: n } = {}) {
let { presenceContext: r } = this.visualElement;
if (r && r.isPresent === !1) return;
let i = (e) => {
- t && this.snapToCursor(xP(e).point), this.stopAnimation();
+ t && this.snapToCursor(SP(e).point), this.stopAnimation();
}, a = (e, t) => {
let { drag: n, dragPropagation: r, onDragStart: i } = this.getProps();
- if (n && !r && (this.openDragLock && this.openDragLock(), this.openDragLock = aoe(n), !this.openDragLock)) return;
- this.latestPointerEvent = e, this.latestPanInfo = t, this.isDragging = !0, this.currentDirection = null, this.resolveConstraints(), this.visualElement.projection && (this.visualElement.projection.isAnimationBlocked = !0, this.visualElement.projection.target = void 0), MD((e) => {
+ if (n && !r && (this.openDragLock && this.openDragLock(), this.openDragLock = uoe(n), !this.openDragLock)) return;
+ this.latestPointerEvent = e, this.latestPanInfo = t, this.isDragging = !0, this.currentDirection = null, this.resolveConstraints(), this.visualElement.projection && (this.visualElement.projection.isAnimationBlocked = !0, this.visualElement.projection.target = void 0), DD((e) => {
let t = this.getAxisMotionValue(e).get() || 0;
- if (ZC.test(t)) {
+ if (CC.test(t)) {
let { projection: n } = this.visualElement;
if (n && n.layout) {
let r = n.layout.layoutBox[e];
- r && (t = gD(r) * (parseFloat(t) / 100));
+ r && (t = dD(r) * (parseFloat(t) / 100));
}
}
this.originPoint[e] = t;
- }), i && kC.update(() => i(e, t), !1, !0), AT(this.visualElement, "transform");
+ }), i && tC.update(() => i(e, t), !1, !0), TT(this.visualElement, "transform");
let { animationState: a } = this.visualElement;
a && a.setActive("whileDrag", !0);
}, o = (e, t) => {
@@ -43094,10 +43094,10 @@ var Wpe = /* @__PURE__ */ new WeakMap(), Gpe = class {
if (!n && !this.openDragLock) return;
let { offset: o } = t;
if (r && this.currentDirection === null) {
- this.currentDirection = qpe(o), this.currentDirection !== null && i && i(this.currentDirection);
+ this.currentDirection = Kpe(o), this.currentDirection !== null && i && i(this.currentDirection);
return;
}
- this.updateAxis("x", t.point, o), this.updateAxis("y", t.point, o), this.visualElement.render(), a && kC.update(() => a(e, t), !1, !0);
+ this.updateAxis("x", t.point, o), this.updateAxis("y", t.point, o), this.visualElement.render(), a && tC.update(() => a(e, t), !1, !0);
}, s = (e, t) => {
this.latestPointerEvent = e, this.latestPanInfo = t, this.stop(e, t), this.latestPointerEvent = null, this.latestPanInfo = null;
}, c = () => {
@@ -43107,7 +43107,7 @@ var Wpe = /* @__PURE__ */ new WeakMap(), Gpe = class {
y: 0
});
}, { dragSnapToOrigin: l } = this.getProps();
- this.panSession = new TP(e, {
+ this.panSession = new EP(e, {
onSessionStart: i,
onStart: a,
onMove: o,
@@ -43117,7 +43117,7 @@ var Wpe = /* @__PURE__ */ new WeakMap(), Gpe = class {
transformPagePoint: this.visualElement.getTransformPagePoint(),
dragSnapToOrigin: l,
distanceThreshold: n,
- contextWindow: CP(this.visualElement),
+ contextWindow: wP(this.visualElement),
element: this.visualElement.current
});
}
@@ -43127,7 +43127,7 @@ var Wpe = /* @__PURE__ */ new WeakMap(), Gpe = class {
let { velocity: a } = r;
this.startAnimation(a);
let { onDragEnd: o } = this.getProps();
- o && kC.postRender(() => o(n, r));
+ o && tC.postRender(() => o(n, r));
}
cancel() {
this.isDragging = !1;
@@ -43141,32 +43141,32 @@ var Wpe = /* @__PURE__ */ new WeakMap(), Gpe = class {
}
updateAxis(e, t, n) {
let { drag: r } = this.getProps();
- if (!n || !IP(e, r, this.currentDirection)) return;
+ if (!n || !LP(e, r, this.currentDirection)) return;
let i = this.getAxisMotionValue(e), a = this.originPoint[e] + n[e];
- this.constraints && this.constraints[e] && (a = Rpe(a, this.constraints[e], this.elastic[e])), i.set(a);
+ this.constraints && this.constraints[e] && (a = Lpe(a, this.constraints[e], this.elastic[e])), i.set(a);
}
resolveConstraints() {
let { dragConstraints: e, dragElastic: t } = this.getProps(), n = this.visualElement.projection && !this.visualElement.projection.layout ? this.visualElement.projection.measure(!1) : this.visualElement.projection?.layout, r = this.constraints;
- e && vP(e) ? this.constraints ||= this.resolveRefConstraints() : this.constraints = e && n ? zpe(n.layoutBox, e) : !1, this.elastic = Upe(t), r !== this.constraints && !vP(e) && n && this.constraints && !this.hasMutatedConstraints && MD((e) => {
- this.constraints !== !1 && this.getAxisMotionValue(e) && (this.constraints[e] = Hpe(n.layoutBox[e], this.constraints[e]));
+ e && yP(e) ? this.constraints ||= this.resolveRefConstraints() : this.constraints = e && n ? Rpe(n.layoutBox, e) : !1, this.elastic = Hpe(t), r !== this.constraints && !yP(e) && n && this.constraints && !this.hasMutatedConstraints && DD((e) => {
+ this.constraints !== !1 && this.getAxisMotionValue(e) && (this.constraints[e] = Vpe(n.layoutBox[e], this.constraints[e]));
});
}
resolveRefConstraints() {
let { dragConstraints: e, onMeasureDragConstraints: t } = this.getProps();
- if (!e || !vP(e)) return !1;
+ if (!e || !yP(e)) return !1;
let n = e.current, { projection: r } = this.visualElement;
if (!r || !r.layout) return !1;
r.root && (r.root.scroll = void 0, r.root.updateScroll());
- let i = Foe(n, r.root, this.visualElement.getTransformPagePoint()), a = Bpe(r.layout.layoutBox, i);
+ let i = Boe(n, r.root, this.visualElement.getTransformPagePoint()), a = zpe(r.layout.layoutBox, i);
if (t) {
- let e = t(Moe(a));
- this.hasMutatedConstraints = !!e, e && (a = FE(e));
+ let e = t(Loe(a));
+ this.hasMutatedConstraints = !!e, e && (a = AE(e));
}
return a;
}
startAnimation(e) {
- let { drag: t, dragMomentum: n, dragElastic: r, dragTransition: i, dragSnapToOrigin: a, onDragTransitionEnd: o } = this.getProps(), s = this.constraints || {}, c = MD((o) => {
- if (!IP(o, t, this.currentDirection)) return;
+ let { drag: t, dragMomentum: n, dragElastic: r, dragTransition: i, dragSnapToOrigin: a, onDragTransitionEnd: o } = this.getProps(), s = this.constraints || {}, c = DD((o) => {
+ if (!LP(o, t, this.currentDirection)) return;
let c = s && s[o] || {};
(a === !0 || a === o) && (c = {
min: 0,
@@ -43189,65 +43189,65 @@ var Wpe = /* @__PURE__ */ new WeakMap(), Gpe = class {
}
startAxisValueAnimation(e, t) {
let n = this.getAxisMotionValue(e);
- return AT(this.visualElement, e), n.start(ST(e, n, 0, t, this.visualElement, !1));
+ return TT(this.visualElement, e), n.start(_T(e, n, 0, t, this.visualElement, !1));
}
stopAnimation() {
- MD((e) => this.getAxisMotionValue(e).stop());
+ DD((e) => this.getAxisMotionValue(e).stop());
}
getAxisMotionValue(e) {
let t = `_drag${e.toUpperCase()}`;
return this.visualElement.getProps()[t] || this.visualElement.getValue(e, this.visualElement.latestValues[e] ?? 0);
}
snapToCursor(e) {
- MD((t) => {
+ DD((t) => {
let { drag: n } = this.getProps();
- if (!IP(t, n, this.currentDirection)) return;
+ if (!LP(t, n, this.currentDirection)) return;
let { projection: r } = this.visualElement, i = this.getAxisMotionValue(t);
if (r && r.layout) {
let { min: n, max: a } = r.layout.layoutBox[t], o = i.get() || 0;
- i.set(e[t] - uw(n, a, .5) + o);
+ i.set(e[t] - YC(n, a, .5) + o);
}
});
}
scalePositionWithinConstraints() {
if (!this.visualElement.current) return;
let { drag: e, dragConstraints: t } = this.getProps(), { projection: n } = this.visualElement;
- if (!vP(t) || !n || !this.constraints) return;
+ if (!yP(t) || !n || !this.constraints) return;
this.stopAnimation();
let r = {
x: 0,
y: 0
};
- MD((e) => {
+ DD((e) => {
let t = this.getAxisMotionValue(e);
if (t && this.constraints !== !1) {
let n = t.get();
- r[e] = Vpe({
+ r[e] = Bpe({
min: n,
max: n
}, this.constraints[e]);
}
});
let { transformTemplate: i } = this.visualElement.getProps();
- this.visualElement.current.style.transform = i ? i({}, "") : "none", n.root && n.root.updateScroll(), n.updateLayout(), this.constraints = !1, this.resolveConstraints(), MD((t) => {
- if (!IP(t, e, null)) return;
+ this.visualElement.current.style.transform = i ? i({}, "") : "none", n.root && n.root.updateScroll(), n.updateLayout(), this.constraints = !1, this.resolveConstraints(), DD((t) => {
+ if (!LP(t, e, null)) return;
let n = this.getAxisMotionValue(t), { min: i, max: a } = this.constraints[t];
- n.set(uw(i, a, r[t]));
+ n.set(YC(i, a, r[t]));
}), this.visualElement.render();
}
addListeners() {
if (!this.visualElement.current) return;
- Wpe.set(this.visualElement, this);
- let e = this.visualElement.current, t = SP(e, "pointerdown", (t) => {
- let { drag: n, dragListener: r = !0 } = this.getProps(), i = t.target, a = i !== e && doe(i);
+ Upe.set(this.visualElement, this);
+ let e = this.visualElement.current, t = CP(e, "pointerdown", (t) => {
+ let { drag: n, dragListener: r = !0 } = this.getProps(), i = t.target, a = i !== e && goe(i);
n && r && !a && this.start(t);
}), n, r = () => {
let { dragConstraints: t } = this.getProps();
- vP(t) && t.current && (this.constraints = this.resolveRefConstraints(), n ||= Kpe(e, t.current, () => this.scalePositionWithinConstraints()));
+ yP(t) && t.current && (this.constraints = this.resolveRefConstraints(), n ||= Gpe(e, t.current, () => this.scalePositionWithinConstraints()));
}, { projection: i } = this.visualElement, a = i.addEventListener("measure", r);
- i && !i.layout && (i.root && i.root.updateScroll(), i.updateLayout()), kC.read(r);
- let o = LD(window, "resize", () => this.scalePositionWithinConstraints()), s = i.addEventListener("didUpdate", (({ delta: e, hasLayoutChanged: t }) => {
- this.isDragging && t && (MD((t) => {
+ i && !i.layout && (i.root && i.root.updateScroll(), i.updateLayout()), tC.read(r);
+ let o = MD(window, "resize", () => this.scalePositionWithinConstraints()), s = i.addEventListener("didUpdate", (({ delta: e, hasLayoutChanged: t }) => {
+ this.isDragging && t && (DD((t) => {
let n = this.getAxisMotionValue(t);
n && (this.originPoint[t] += e[t].translate, n.set(n.get() + e[t].translate));
}), this.visualElement.render());
@@ -43257,7 +43257,7 @@ var Wpe = /* @__PURE__ */ new WeakMap(), Gpe = class {
};
}
getProps() {
- let e = this.visualElement.getProps(), { drag: t = !1, dragDirectionLock: n = !1, dragPropagation: r = !1, dragConstraints: i = !1, dragElastic: a = MP, dragMomentum: o = !0 } = e;
+ let e = this.visualElement.getProps(), { drag: t = !1, dragDirectionLock: n = !1, dragPropagation: r = !1, dragConstraints: i = !1, dragElastic: a = NP, dragMomentum: o = !0 } = e;
return {
...e,
drag: t,
@@ -43269,7 +43269,7 @@ var Wpe = /* @__PURE__ */ new WeakMap(), Gpe = class {
};
}
};
-function FP(e) {
+function IP(e) {
let t = !0;
return () => {
if (t) {
@@ -43279,28 +43279,28 @@ function FP(e) {
e();
};
}
-function Kpe(e, t, n) {
- let r = pE(e, FP(n)), i = pE(t, FP(n));
+function Gpe(e, t, n) {
+ let r = cE(e, IP(n)), i = cE(t, IP(n));
return () => {
r(), i();
};
}
-function IP(e, t, n) {
+function LP(e, t, n) {
return (t === !0 || t === e) && (n === null || n === e);
}
-function qpe(e, t = 10) {
+function Kpe(e, t = 10) {
let n = null;
return Math.abs(e.y) > t ? n = "y" : Math.abs(e.x) > t && (n = "x"), n;
}
//#endregion
//#region node_modules/framer-motion/dist/es/gestures/drag/index.mjs
-var Jpe = class extends PE {
+var qpe = class extends kE {
constructor(e) {
- super(e), this.removeGroupControls = aC, this.removeListeners = aC, this.controls = new Gpe(e);
+ super(e), this.removeGroupControls = jS, this.removeListeners = jS, this.controls = new Wpe(e);
}
mount() {
let { dragControls: e } = this.node.getProps();
- e && (this.removeGroupControls = e.subscribe(this.controls)), this.removeListeners = this.controls.addListeners() || aC;
+ e && (this.removeGroupControls = e.subscribe(this.controls)), this.removeListeners = this.controls.addListeners() || jS;
}
update() {
let { dragControls: e } = this.node.getProps(), { dragControls: t } = this.node.prevProps || {};
@@ -43309,31 +43309,31 @@ var Jpe = class extends PE {
unmount() {
this.removeGroupControls(), this.removeListeners(), this.controls.isDragging || this.controls.endPanSession();
}
-}, LP = (e) => (t, n) => {
- e && kC.update(() => e(t, n), !1, !0);
-}, Ype = class extends PE {
+}, RP = (e) => (t, n) => {
+ e && tC.update(() => e(t, n), !1, !0);
+}, Jpe = class extends kE {
constructor() {
- super(...arguments), this.removePointerDownListener = aC;
+ super(...arguments), this.removePointerDownListener = jS;
}
onPointerDown(e) {
- this.session = new TP(e, this.createPanHandlers(), {
+ this.session = new EP(e, this.createPanHandlers(), {
transformPagePoint: this.node.getTransformPagePoint(),
- contextWindow: CP(this.node)
+ contextWindow: wP(this.node)
});
}
createPanHandlers() {
let { onPanSessionStart: e, onPanStart: t, onPan: n, onPanEnd: r } = this.node.getProps();
return {
- onSessionStart: LP(e),
- onStart: LP(t),
- onMove: LP(n),
+ onSessionStart: RP(e),
+ onStart: RP(t),
+ onMove: RP(n),
onEnd: (e, t) => {
- delete this.session, r && kC.postRender(() => r(e, t));
+ delete this.session, r && tC.postRender(() => r(e, t));
}
};
}
mount() {
- this.removePointerDownListener = SP(this.node.current, "pointerdown", (e) => this.onPointerDown(e));
+ this.removePointerDownListener = CP(this.node.current, "pointerdown", (e) => this.onPointerDown(e));
}
update() {
this.session && this.session.updateHandlers(this.createPanHandlers());
@@ -43341,36 +43341,36 @@ var Jpe = class extends PE {
unmount() {
this.removePointerDownListener(), this.session && this.session.end();
}
-}, RP = !1, Xpe = class extends R.Component {
+}, zP = !1, Ype = class extends R.Component {
componentDidMount() {
let { visualElement: e, layoutGroup: t, switchLayoutGroup: n, layoutId: r } = this.props, { projection: i } = e;
- i && (t.group && t.group.add(i), n && n.register && r && n.register(i), RP && i.root.didUpdate(), i.addEventListener("animationComplete", () => {
+ i && (t.group && t.group.add(i), n && n.register && r && n.register(i), zP && i.root.didUpdate(), i.addEventListener("animationComplete", () => {
this.safeToRemove();
}), i.setOptions({
...i.options,
layoutDependency: this.props.layoutDependency,
onExitComplete: () => this.safeToRemove()
- })), zD.hasEverUpdated = !0;
+ })), PD.hasEverUpdated = !0;
}
getSnapshotBeforeUpdate(e) {
let { layoutDependency: t, visualElement: n, drag: r, isPresent: i } = this.props, { projection: a } = n;
return a ? (a.isPresent = i, e.layoutDependency !== t && a.setOptions({
...a.options,
layoutDependency: t
- }), RP = !0, r || e.layoutDependency !== t || t === void 0 || e.isPresent !== i ? a.willUpdate() : this.safeToRemove(), e.isPresent !== i && (i ? a.promote() : a.relegate() || kC.postRender(() => {
+ }), zP = !0, r || e.layoutDependency !== t || t === void 0 || e.isPresent !== i ? a.willUpdate() : this.safeToRemove(), e.isPresent !== i && (i ? a.promote() : a.relegate() || tC.postRender(() => {
let e = a.getStack();
(!e || !e.members.length) && this.safeToRemove();
})), null) : null;
}
componentDidUpdate() {
let { visualElement: e, layoutAnchor: t } = this.props, { projection: n } = e;
- n && (n.options.layoutAnchor = t, n.root.didUpdate(), YT.postRender(() => {
+ n && (n.options.layoutAnchor = t, n.root.didUpdate(), WT.postRender(() => {
!n.currentAnimation && n.isLead() && this.safeToRemove();
}));
}
componentWillUnmount() {
let { visualElement: e, layoutGroup: t, switchLayoutGroup: n } = this.props, { projection: r } = e;
- RP = !0, r && (r.scheduleCheckAfterUnmount(), t && t.group && t.group.remove(r), n && n.deregister && n.deregister(r));
+ zP = !0, r && (r.scheduleCheckAfterUnmount(), t && t.group && t.group.remove(r), n && n.deregister && n.deregister(r));
}
safeToRemove() {
let { safeToRemove: e } = this.props;
@@ -43380,41 +43380,41 @@ var Jpe = class extends PE {
return null;
}
};
-function zP(e) {
- let [t, n] = $N(), r = (0, R.useContext)(qN);
- return (0, z.jsx)(Xpe, {
+function BP(e) {
+ let [t, n] = eP(), r = (0, R.useContext)(JN);
+ return (0, z.jsx)(Ype, {
...e,
layoutGroup: r,
- switchLayoutGroup: (0, R.useContext)(_P),
+ switchLayoutGroup: (0, R.useContext)(vP),
isPresent: t,
safeToRemove: n
});
}
//#endregion
//#region node_modules/framer-motion/dist/es/motion/features/drag.mjs
-var Zpe = {
- pan: { Feature: Ype },
+var Xpe = {
+ pan: { Feature: Jpe },
drag: {
- Feature: Jpe,
- ProjectionNode: tO,
- MeasureLayout: zP
+ Feature: qpe,
+ ProjectionNode: XD,
+ MeasureLayout: BP
}
};
//#endregion
//#region node_modules/framer-motion/dist/es/gestures/hover.mjs
-function BP(e, t, n) {
+function VP(e, t, n) {
let { props: r } = e;
e.animationState && r.whileHover && e.animationState.setActive("whileHover", n === "Start");
let i = r["onHover" + n];
- i && kC.postRender(() => i(t, xP(t)));
+ i && tC.postRender(() => i(t, SP(t)));
}
-var Qpe = class extends PE {
+var Zpe = class extends kE {
mount() {
let { current: e } = this.node;
- e && (this.unmount = soe(e, (e, t) => (BP(this.node, t, "Start"), (e) => BP(this.node, e, "End"))));
+ e && (this.unmount = foe(e, (e, t) => (VP(this.node, t, "Start"), (e) => VP(this.node, e, "End"))));
}
unmount() {}
-}, $pe = class extends PE {
+}, Qpe = class extends kE {
constructor() {
super(...arguments), this.isActive = !1;
}
@@ -43431,57 +43431,57 @@ var Qpe = class extends PE {
!this.isActive || !this.node.animationState || (this.node.animationState.setActive("whileFocus", !1), this.isActive = !1);
}
mount() {
- this.unmount = oC(LD(this.node.current, "focus", () => this.onFocus()), LD(this.node.current, "blur", () => this.onBlur()));
+ this.unmount = MS(MD(this.node.current, "focus", () => this.onFocus()), MD(this.node.current, "blur", () => this.onBlur()));
}
unmount() {}
};
//#endregion
//#region node_modules/framer-motion/dist/es/gestures/press.mjs
-function VP(e, t, n) {
+function HP(e, t, n) {
let { props: r } = e;
if (e.current instanceof HTMLButtonElement && e.current.disabled) return;
e.animationState && r.whileTap && e.animationState.setActive("whileTap", n === "Start");
let i = r["onTap" + (n === "End" ? "" : n)];
- i && kC.postRender(() => i(t, xP(t)));
+ i && tC.postRender(() => i(t, SP(t)));
}
-var eme = class extends PE {
+var $pe = class extends kE {
mount() {
let { current: e } = this.node;
if (!e) return;
let { globalTapTarget: t, propagate: n } = this.node.props;
- this.unmount = poe(e, (e, t) => (VP(this.node, t, "Start"), (e, { success: t }) => VP(this.node, e, t ? "End" : "Cancel")), {
+ this.unmount = voe(e, (e, t) => (HP(this.node, t, "Start"), (e, { success: t }) => HP(this.node, e, t ? "End" : "Cancel")), {
useGlobalTarget: t,
stopPropagation: n?.tap === !1
});
}
unmount() {}
-}, HP = /* @__PURE__ */ new WeakMap(), UP = /* @__PURE__ */ new WeakMap(), tme = (e) => {
- let t = HP.get(e.target);
+}, UP = /* @__PURE__ */ new WeakMap(), WP = /* @__PURE__ */ new WeakMap(), eme = (e) => {
+ let t = UP.get(e.target);
t && t(e);
-}, nme = (e) => {
- e.forEach(tme);
+}, tme = (e) => {
+ e.forEach(eme);
};
-function rme({ root: e, ...t }) {
+function nme({ root: e, ...t }) {
let n = e || document;
- UP.has(n) || UP.set(n, {});
- let r = UP.get(n), i = JSON.stringify(t);
- return r[i] || (r[i] = new IntersectionObserver(nme, {
+ WP.has(n) || WP.set(n, {});
+ let r = WP.get(n), i = JSON.stringify(t);
+ return r[i] || (r[i] = new IntersectionObserver(tme, {
root: e,
...t
})), r[i];
}
-function ime(e, t, n) {
- let r = rme(t);
- return HP.set(e, n), r.observe(e), () => {
- HP.delete(e), r.unobserve(e);
+function rme(e, t, n) {
+ let r = nme(t);
+ return UP.set(e, n), r.observe(e), () => {
+ UP.delete(e), r.unobserve(e);
};
}
//#endregion
//#region node_modules/framer-motion/dist/es/motion/features/viewport/index.mjs
-var ame = {
+var ime = {
some: 0,
all: 1
-}, ome = class extends PE {
+}, ame = class extends kE {
constructor() {
super(...arguments), this.hasEnteredView = !1, this.isInView = !1;
}
@@ -43490,7 +43490,7 @@ var ame = {
let { viewport: e = {} } = this.node.getProps(), { root: t, margin: n, amount: r = "some", once: i } = e, a = {
root: t ? t.current : void 0,
rootMargin: n,
- threshold: typeof r == "number" ? r : ame[r]
+ threshold: typeof r == "number" ? r : ime[r]
}, o = (e) => {
let { isIntersecting: t } = e;
if (this.isInView === t || (this.isInView = t, i && !t && this.hasEnteredView)) return;
@@ -43498,7 +43498,7 @@ var ame = {
let { onViewportEnter: n, onViewportLeave: r } = this.node.getProps(), a = t ? n : r;
a && a(e);
};
- this.stopObserver = ime(this.node.current, a, o);
+ this.stopObserver = rme(this.node.current, a, o);
}
mount() {
this.startObserver();
@@ -43510,34 +43510,34 @@ var ame = {
"amount",
"margin",
"root"
- ].some(sme(e, t)) && this.startObserver();
+ ].some(ome(e, t)) && this.startObserver();
}
unmount() {
this.stopObserver?.(), this.hasEnteredView = !1, this.isInView = !1;
}
};
-function sme({ viewport: e = {} }, { viewport: t = {} } = {}) {
+function ome({ viewport: e = {} }, { viewport: t = {} } = {}) {
return (n) => e[n] !== t[n];
}
//#endregion
//#region node_modules/framer-motion/dist/es/motion/features/gestures.mjs
-var cme = {
- inView: { Feature: ome },
- tap: { Feature: eme },
- focus: { Feature: $pe },
- hover: { Feature: Qpe }
-}, lme = { layout: {
- ProjectionNode: tO,
- MeasureLayout: zP
-} }, ume = /*@__PURE__*/ Ape({
- ...Ppe,
- ...cme,
- ...Zpe,
- ...lme
-}, jpe);
+var sme = {
+ inView: { Feature: ame },
+ tap: { Feature: $pe },
+ focus: { Feature: Qpe },
+ hover: { Feature: Zpe }
+}, cme = { layout: {
+ ProjectionNode: XD,
+ MeasureLayout: BP
+} }, lme = /*@__PURE__*/ kpe({
+ ...Npe,
+ ...sme,
+ ...Xpe,
+ ...cme
+}, Ape);
//#endregion
//#region node_modules/framer-motion/dist/es/utils/use-motion-value-event.mjs
-function WP(e, t, n) {
+function GP(e, t, n) {
(0, R.useInsertionEffect)(() => e.on(t, n), [
e,
t,
@@ -43546,8 +43546,8 @@ function WP(e, t, n) {
}
//#endregion
//#region node_modules/framer-motion/dist/es/value/use-motion-value.mjs
-function GP(e) {
- let t = JN(() => yT(e)), { isStatic: n } = (0, R.useContext)(ZN);
+function KP(e) {
+ let t = YN(() => mT(e)), { isStatic: n } = (0, R.useContext)(QN);
if (n) {
let [, n] = (0, R.useState)(e);
(0, R.useEffect)(() => t.on("change", n), []);
@@ -43556,28 +43556,28 @@ function GP(e) {
}
//#endregion
//#region node_modules/framer-motion/dist/es/value/use-combine-values.mjs
-function KP(e, t) {
- let n = GP(t()), r = () => n.set(t());
- return r(), YN(() => {
- let t = () => kC.preRender(r, !1, !0), n = e.map((e) => e.on("change", t));
+function qP(e, t) {
+ let n = KP(t()), r = () => n.set(t());
+ return r(), XN(() => {
+ let t = () => tC.preRender(r, !1, !0), n = e.map((e) => e.on("change", t));
return () => {
- n.forEach((e) => e()), AC(r);
+ n.forEach((e) => e()), nC(r);
};
}), n;
}
//#endregion
//#region node_modules/framer-motion/dist/es/value/use-computed.mjs
-function dme(e) {
- vT.current = [], e();
- let t = KP(vT.current, e);
- return vT.current = void 0, t;
+function ume(e) {
+ pT.current = [], e();
+ let t = qP(pT.current, e);
+ return pT.current = void 0, t;
}
//#endregion
//#region node_modules/framer-motion/dist/es/value/use-transform.mjs
-function qP(e, t, n, r) {
- if (typeof e == "function") return dme(e);
- if (n !== void 0 && !Array.isArray(n) && typeof t != "function") return fme(e, t, n, r);
- let i = typeof t == "function" ? t : Coe(t, n, r), a = Array.isArray(e) ? JP(e, i) : JP([e], ([e]) => i(e)), o = Array.isArray(e) ? void 0 : e.accelerate;
+function JP(e, t, n, r) {
+ if (typeof e == "function") return ume(e);
+ if (n !== void 0 && !Array.isArray(n) && typeof t != "function") return dme(e, t, n, r);
+ let i = typeof t == "function" ? t : Ooe(t, n, r), a = Array.isArray(e) ? YP(e, i) : YP([e], ([e]) => i(e)), o = Array.isArray(e) ? void 0 : e.accelerate;
return o && !o.isTransformed && typeof t != "function" && Array.isArray(n) && r?.clamp !== !1 && (a.accelerate = {
...o,
times: t,
@@ -43586,55 +43586,55 @@ function qP(e, t, n, r) {
...r?.ease ? { ease: r.ease } : {}
}), a;
}
-function JP(e, t) {
- let n = JN(() => []);
- return KP(e, () => {
+function YP(e, t) {
+ let n = YN(() => []);
+ return qP(e, () => {
n.length = 0;
let r = e.length;
for (let t = 0; t < r; t++) n[t] = e[t].get();
return t(n);
});
}
-function fme(e, t, n, r) {
- let i = JN(() => Object.keys(n)), a = JN(() => ({}));
- for (let o of i) a[o] = qP(e, t, n[o], r);
+function dme(e, t, n, r) {
+ let i = YN(() => Object.keys(n)), a = YN(() => ({}));
+ for (let o of i) a[o] = JP(e, t, n[o], r);
return a;
}
//#endregion
//#region node_modules/framer-motion/dist/es/value/use-follow-value.mjs
-function pme(e, t = {}) {
- let { isStatic: n } = (0, R.useContext)(ZN), r = () => kT(e) ? e.get() : e;
- if (n) return qP(r);
- let i = GP(r());
- return (0, R.useInsertionEffect)(() => woe(i, e, t), [i, JSON.stringify(t)]), i;
+function fme(e, t = {}) {
+ let { isStatic: n } = (0, R.useContext)(QN), r = () => wT(e) ? e.get() : e;
+ if (n) return JP(r);
+ let i = KP(r());
+ return (0, R.useInsertionEffect)(() => koe(i, e, t), [i, JSON.stringify(t)]), i;
}
//#endregion
//#region node_modules/framer-motion/dist/es/value/use-spring.mjs
-function YP(e, t = {}) {
- return pme(e, {
+function XP(e, t = {}) {
+ return fme(e, {
type: "spring",
...t
});
}
//#endregion
//#region node_modules/framer-motion/dist/es/utils/reduced-motion/use-reduced-motion.mjs
-function mme() {
- !OE.current && kE();
- let [e] = (0, R.useState)(DE.current);
+function pme() {
+ !CE.current && wE();
+ let [e] = (0, R.useState)(SE.current);
return e;
}
//#endregion
//#region node_modules/motion/dist/es/react.mjs
-var XP = ume, ZP = "(prefers-reduced-motion: reduce)", hme = () => matchMedia(ZP).matches, gme = (e) => {
- let t = matchMedia(ZP);
+var ZP = lme, QP = "(prefers-reduced-motion: reduce)", mme = () => matchMedia(QP).matches, hme = (e) => {
+ let t = matchMedia(QP);
return t.addEventListener("change", e), () => t.removeEventListener("change", e);
};
-function _me({ children: e, count: t, label: n }) {
- let r = tpe(), i = (0, R.useSyncExternalStore)(gme, hme, () => !1), { isFocusVisible: a } = xs(), o = i || a, s = {
+function gme({ children: e, count: t, label: n }) {
+ let r = epe(), i = (0, R.useSyncExternalStore)(hme, mme, () => !1), { isFocusVisible: a } = xs(), o = i || a, s = {
opacity: 0,
transform: "translate(-50%, 8px)"
};
- return /* @__PURE__ */ (0, z.jsxs)(XP.div, {
+ return /* @__PURE__ */ (0, z.jsxs)(ZP.div, {
role: "group",
"aria-label": n,
"data-selection-dock": !0,
@@ -43666,13 +43666,13 @@ function _me({ children: e, count: t, label: n }) {
}), e]
});
}
-function QP({ visible: e, ...t }) {
- return /* @__PURE__ */ (0, z.jsx)(rpe, { children: e ? /* @__PURE__ */ (0, z.jsx)(_me, { ...t }, "selection") : null });
+function $P({ visible: e, ...t }) {
+ return /* @__PURE__ */ (0, z.jsx)(npe, { children: e ? /* @__PURE__ */ (0, z.jsx)(gme, { ...t }, "selection") : null });
}
//#endregion
//#region src/react/follow-manage/add-feed.tsx
-var vme = "输入女优名,到 JavDB 找她的演员页";
-function yme(e, t) {
+var _me = "输入女优名,到 JavDB 找她的演员页";
+function vme(e, t) {
let n = /* @__PURE__ */ new Map();
for (let r of e.candidates) t.has(r.id) && r.held_by && n.set(r.held_by.id, r.held_by.name);
if (n.size > 1) return {
@@ -43691,10 +43691,10 @@ function yme(e, t) {
blocked: !1
};
}
-function bme({ card: e, picked: t, onPick: n }) {
+function yme({ card: e, picked: t, onPick: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center gap-2",
- children: [/* @__PURE__ */ (0, z.jsx)(SO, {
+ children: [/* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: t,
onChange: n,
children: /* @__PURE__ */ (0, z.jsxs)("span", {
@@ -43715,16 +43715,16 @@ function bme({ card: e, picked: t, onPick: n }) {
}) : null
]
})
- }), /* @__PURE__ */ (0, z.jsx)(Dy, {
+ }), /* @__PURE__ */ (0, z.jsx)(My, {
href: e.url,
children: e.id
})]
});
}
-function xme({ readOnly: e, toast: t, onAdded: n }) {
+function bme({ readOnly: e, toast: t, onAdded: n }) {
let [r, i] = (0, R.useState)(""), [a, o] = (0, R.useState)(null), [s, c] = (0, R.useState)(/* @__PURE__ */ new Set()), l = aa(), u = () => {
let t = r.trim();
- !t || e || l.run("lookup", (e) => Dde(t, e), (e) => {
+ !t || e || l.run("lookup", (e) => ede(t, e), (e) => {
o(e), c(new Set(e.suggested));
});
}, d = (e) => {
@@ -43732,10 +43732,10 @@ function xme({ readOnly: e, toast: t, onAdded: n }) {
}, f = () => {
o(null), c(/* @__PURE__ */ new Set()), l.setError("");
}, p = () => {
- a && l.run("follow", (e) => Ode(a.q, [...s], e), (e) => {
+ a && l.run("follow", (e) => tde(a.q, [...s], e), (e) => {
t(e.created ? `已新建「${e.entity_name}」并订阅她的新作` : `已订阅「${e.entity_name}」的新作`), i(""), f(), n();
});
- }, m = a ? yme(a, s) : null;
+ }, m = a ? vme(a, s) : null;
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: Zi({
padding: "none",
@@ -43750,9 +43750,9 @@ function xme({ readOnly: e, toast: t, onAdded: n }) {
className: "flex flex-wrap items-end gap-2",
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "min-w-64 grow",
- children: /* @__PURE__ */ (0, z.jsx)(cy, {
+ children: /* @__PURE__ */ (0, z.jsx)(py, {
"aria-label": "女优名",
- placeholder: vme,
+ placeholder: _me,
value: r,
leadingIcon: gt,
isDisabled: e,
@@ -43775,16 +43775,16 @@ function xme({ readOnly: e, toast: t, onAdded: n }) {
a ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-3",
children: [
- /* @__PURE__ */ (0, z.jsx)(Ey, { children: "JavDB 上的演员卡" }),
- a.candidates.length ? a.candidates.map((e) => /* @__PURE__ */ (0, z.jsx)(bme, {
+ /* @__PURE__ */ (0, z.jsx)(jy, { children: "JavDB 上的演员卡" }),
+ a.candidates.length ? a.candidates.map((e) => /* @__PURE__ */ (0, z.jsx)(yme, {
card: e,
picked: s.has(e.id),
onPick: (t) => c((n) => {
let r = new Set(n);
return t ? r.add(e.id) : r.delete(e.id), r;
})
- }, e.id)) : /* @__PURE__ */ (0, z.jsx)(wy, { children: "JavDB 上没有搜到这个名字。" }),
- a.candidates.length ? /* @__PURE__ */ (0, z.jsx)(wy, {
+ }, e.id)) : /* @__PURE__ */ (0, z.jsx)(ky, { children: "JavDB 上没有搜到这个名字。" }),
+ a.candidates.length ? /* @__PURE__ */ (0, z.jsx)(ky, {
role: "status",
children: s.size ? m.text : "勾选她的演员卡;有碼与無碼两条记录都是她的话,两张都勾。"
}) : null,
@@ -43811,19 +43811,19 @@ function xme({ readOnly: e, toast: t, onAdded: n }) {
}
//#endregion
//#region src/react/follow-manage/source-list.tsx
-var Sme = Object.fromEntries(Object.entries(fj).map(([e, t]) => [t, e])), $P = 740;
-function Cme() {
+var xme = Object.fromEntries(Object.entries(zj).map(([e, t]) => [t, e])), eF = 740;
+function Sme() {
let [e, t] = (0, R.useState)(!1), n = (0, R.useRef)(null), r = (0, R.useCallback)((e) => {
if (n.current?.disconnect(), !e) {
n.current = null;
return;
}
- let r = new ResizeObserver(() => t(e.clientWidth < $P));
- r.observe(e), n.current = r, t(e.clientWidth < $P);
+ let r = new ResizeObserver(() => t(e.clientWidth < eF));
+ r.observe(e), n.current = r, t(e.clientWidth < eF);
}, []);
return (0, R.useEffect)(() => () => n.current?.disconnect(), []), [r, e];
}
-var wme = {
+var Cme = {
select: "选择",
author: "创作者",
source: "来源",
@@ -43832,7 +43832,7 @@ var wme = {
checked: "上次检查",
actions: "操作"
};
-function eF({ page: e, pages: t, onPage: n, label: r = "关注列表分页" }) {
+function tF({ page: e, pages: t, onPage: n, label: r = "关注列表分页" }) {
return t <= 1 ? null : /* @__PURE__ */ (0, z.jsxs)("nav", {
"aria-label": r,
className: "flex flex-wrap items-center justify-center gap-2",
@@ -43846,7 +43846,7 @@ function eF({ page: e, pages: t, onPage: n, label: r = "关注列表分页" }) {
}),
/* @__PURE__ */ (0, z.jsx)("ul", {
className: "flex flex-wrap items-center gap-1",
- children: sx(e, t).map((t, r) => /* @__PURE__ */ (0, z.jsx)("li", { children: t === "…" ? /* @__PURE__ */ (0, z.jsx)("span", {
+ children: fx(e, t).map((t, r) => /* @__PURE__ */ (0, z.jsx)("li", { children: t === "…" ? /* @__PURE__ */ (0, z.jsx)("span", {
"aria-hidden": !0,
className: "px-1 text-body-2-regular text-text-tertiary",
children: "…"
@@ -43869,22 +43869,22 @@ function eF({ page: e, pages: t, onPage: n, label: r = "关注列表分页" }) {
]
});
}
-function Tme({ source: e, selected: t, onToggle: n, handlers: r }) {
+function wme({ source: e, selected: t, onToggle: n, handlers: r }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-selected": t || void 0,
className: "flex min-h-16 flex-wrap items-center gap-3 px-2 py-3",
onClick: (e) => {
- wO(e, e.currentTarget) && n(!t);
+ yO(e, e.currentTarget) && n(!t);
},
children: [
- /* @__PURE__ */ (0, z.jsx)(SO, {
+ /* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: t,
onChange: n,
"aria-label": `选择 ${e.label}`
}),
/* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 grow flex-col gap-0.5",
- children: [/* @__PURE__ */ (0, z.jsx)(CM, { source: e }), e.last_error ? /* @__PURE__ */ (0, z.jsx)("small", {
+ children: [/* @__PURE__ */ (0, z.jsx)(XM, { source: e }), e.last_error ? /* @__PURE__ */ (0, z.jsx)("small", {
className: "text-caption-1-regular text-text-error-primary",
children: e.last_error
}) : null]
@@ -43892,17 +43892,17 @@ function Tme({ source: e, selected: t, onToggle: n, handlers: r }) {
/* @__PURE__ */ (0, z.jsx)("span", {
className: "flex shrink-0 items-center gap-1.5 text-body-2-regular text-text-secondary",
title: e.provider_label,
- children: /* @__PURE__ */ (0, z.jsx)(bM, {
+ children: /* @__PURE__ */ (0, z.jsx)(qM, {
provider: e.provider,
label: e.provider_label
})
}),
- /* @__PURE__ */ (0, z.jsx)(SM, { source: e }),
+ /* @__PURE__ */ (0, z.jsx)(YM, { source: e }),
/* @__PURE__ */ (0, z.jsx)("span", {
className: "shrink-0 text-body-2-regular whitespace-nowrap text-text-secondary",
- children: zj(e)
+ children: fM(e)
}),
- /* @__PURE__ */ (0, z.jsx)(GN, {
+ /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": `启用 ${e.label}`,
isSelected: e.enabled,
isDisabled: r.readOnly,
@@ -43932,8 +43932,8 @@ function Tme({ source: e, selected: t, onToggle: n, handlers: r }) {
]
});
}
-function Eme({ group: e, name: t, open: n, selected: r, handlers: i, onOpen: a, onToggleGroup: o, onToggle: s }) {
- let c = e.map((e) => e.id), l = e.filter((e) => e.enabled).map((e) => e.id), u = e.filter(mj).length, d = [...new Set(e.map((e) => e.provider_label || e.provider))].join("、"), f = `follow-author-${e[0].id}`, p = wj(r, c);
+function Tme({ group: e, name: t, open: n, selected: r, handlers: i, onOpen: a, onToggleGroup: o, onToggle: s }) {
+ let c = e.map((e) => e.id), l = e.filter((e) => e.enabled).map((e) => e.id), u = e.filter(Vj).length, d = [...new Set(e.map((e) => e.provider_label || e.provider))].join("、"), f = `follow-author-${e[0].id}`, p = Zj(r, c);
return /* @__PURE__ */ (0, z.jsxs)("section", {
"aria-label": `${t} 的关注来源`,
className: Zi({
@@ -43946,7 +43946,7 @@ function Eme({ group: e, name: t, open: n, selected: r, handlers: i, onOpen: a,
"data-open": n || void 0,
className: "flex flex-wrap items-center gap-3 px-2 py-2.5",
children: [
- /* @__PURE__ */ (0, z.jsx)(xM, {
+ /* @__PURE__ */ (0, z.jsx)(JM, {
group: e,
name: t
}),
@@ -43967,7 +43967,7 @@ function Eme({ group: e, name: t, open: n, selected: r, handlers: i, onOpen: a,
/* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex shrink-0 items-center gap-1",
title: d,
- children: [e.map((e) => /* @__PURE__ */ (0, z.jsx)(bM, { provider: e.provider }, e.id)), /* @__PURE__ */ (0, z.jsx)(ju, { children: `来源:${d}` })]
+ children: [e.map((e) => /* @__PURE__ */ (0, z.jsx)(qM, { provider: e.provider }, e.id)), /* @__PURE__ */ (0, z.jsx)(ju, { children: `来源:${d}` })]
}),
u ? /* @__PURE__ */ (0, z.jsx)("span", {
className: "shrink-0 text-body-2-regular text-text-error-primary",
@@ -43997,7 +43997,7 @@ function Eme({ group: e, name: t, open: n, selected: r, handlers: i, onOpen: a,
id: f,
hidden: !n,
"data-source-divider": !0,
- children: e.map((e) => /* @__PURE__ */ (0, z.jsx)(Tme, {
+ children: e.map((e) => /* @__PURE__ */ (0, z.jsx)(wme, {
source: e,
handlers: i,
selected: r.has(e.id),
@@ -44006,37 +44006,37 @@ function Eme({ group: e, name: t, open: n, selected: r, handlers: i, onOpen: a,
})]
});
}
-function Dme(e) {
- let { data: t, sort: n, dir: r, page: i, layout: a, pageSize: o, selected: s, readOnly: c, onSort: l, onPage: u, onLayout: f, onPageSize: p, onSelected: m, toast: h, openFollow: g } = e, _ = t.sources, v = (0, R.useMemo)(() => t.author_aliases || [], [t.author_aliases]), y = t.counts || {}, [x, S] = (0, R.useState)(/* @__PURE__ */ new Set()), [C, w] = Cme(), [T, E] = (0, R.useState)(""), D = (0, R.useMemo)(() => hde(_, n, r, v), [
+function Eme(e) {
+ let { data: t, sort: n, dir: r, page: i, layout: a, pageSize: o, selected: s, readOnly: c, onSort: l, onPage: u, onLayout: f, onPageSize: p, onSelected: m, toast: h, openFollow: g } = e, _ = t.sources, v = (0, R.useMemo)(() => t.author_aliases || [], [t.author_aliases]), y = t.counts || {}, [x, S] = (0, R.useState)(/* @__PURE__ */ new Set()), [C, w] = Sme(), [T, E] = (0, R.useState)(""), D = (0, R.useMemo)(() => Hue(_, n, r, v), [
_,
n,
r,
v
- ]), O = (0, R.useMemo)(() => gde(D, n, r, v), [
+ ]), O = (0, R.useMemo)(() => Uue(D, n, r, v), [
D,
n,
r,
v
- ]), { job: k, running: A, outcome: j, start: M } = vO({
- queryKey: ode,
- queryFn: ({ signal: e }) => vde(e),
- start: (e) => Oj(e),
+ ]), { job: k, running: A, outcome: j, start: M } = pO({
+ queryKey: Nue,
+ queryFn: ({ signal: e }) => Gue(e),
+ start: (e) => tM(e),
onError: (e) => E(U(e)),
onFinish: (e) => {
- Rj(), h(e.status === "failed" ? e.error || "检查失败" : Ade(e));
+ dM(), h(e.status === "failed" ? e.error || "检查失败" : rde(e));
}
}), N = (e) => {
A || M.isPending || (E(""), M.mutate(e));
- }, P = (e, t) => m(Tj(s, [e], t)), ee = (e, t) => m(Tj(s, e, t)), F = er({
- mutationFn: (e) => Aj(e),
+ }, P = (e, t) => m(Qj(s, [e], t)), ee = (e, t) => m(Qj(s, e, t)), F = er({
+ mutationFn: (e) => rM(e),
onSuccess: (e, t) => {
- Lj([t]), m(Tj(s, [t], !1)), h("已取消关注来源");
+ uM([t]), m(Qj(s, [t], !1)), h("已取消关注来源");
},
onError: (e) => E(U(e))
}), I = er({
- mutationFn: (e) => kj(e.id, e.enabled),
+ mutationFn: (e) => nM(e.id, e.enabled),
onSuccess: (e, t) => {
- Ij(t.id, { enabled: t.enabled }), E("");
+ lM(t.id, { enabled: t.enabled }), E("");
},
onError: (e) => E(U(e))
}), te = (e) => void b({
@@ -44048,7 +44048,7 @@ function Dme(e) {
}), ne = er({
mutationFn: async (e) => {
let t = await d(e.ids, 4, async (t) => {
- e.action === "remove" ? await Aj(t) : await kj(t, e.action === "enabled");
+ e.action === "remove" ? await rM(t) : await nM(t, e.action === "enabled");
});
return {
...e,
@@ -44057,9 +44057,9 @@ function Dme(e) {
};
},
onSuccess: (e) => {
- if (e.action === "remove") Lj(e.done);
- else for (let t of e.done) Ij(t, { enabled: e.action === "enabled" });
- m(Tj(s, e.done, !1));
+ if (e.action === "remove") uM(e.done);
+ else for (let t of e.done) lM(t, { enabled: e.action === "enabled" });
+ m(Qj(s, e.done, !1));
let t = e.results.filter((e) => !e.ok);
if (t.length) {
E(`${t.length}/${e.ids.length} 个来源未更新:${U(t[0]?.error)}`);
@@ -44072,18 +44072,18 @@ function Dme(e) {
onError: (e) => E(U(e))
}), re = er({
mutationFn: async (e) => {
- let t = ((await Ede()).groups || []).flatMap((e) => [
+ let t = ((await $ue()).groups || []).flatMap((e) => [
e.primary,
...e.variants,
...e.duplicates
]).filter((e) => e.status === "new").map((e) => e.id);
return {
ids: t,
- failed: (await d(t, 6, (t) => Tde(t, e))).filter((e) => !e.ok)
+ failed: (await d(t, 6, (t) => Que(t, e))).filter((e) => !e.ok)
};
},
onSuccess: (e) => {
- if (Rj(), e.failed.length) {
+ if (dM(), e.failed.length) {
E(`批量更新 ${e.failed.length}/${e.ids.length} 项未完成`);
return;
}
@@ -44108,12 +44108,12 @@ function Dme(e) {
readOnly: c
};
let oe = ae.current, se = (0, R.useMemo)(() => {
- let e = OM(), t = (e) => () => wme[e] || e;
+ let e = tN(), t = (e) => () => Cme[e] || e;
return [
e.display({
id: "select",
header: t("select"),
- cell: (e) => /* @__PURE__ */ (0, z.jsx)(SO, {
+ cell: (e) => /* @__PURE__ */ (0, z.jsx)(_O, {
slot: null,
isSelected: e.row.getIsSelected(),
onChange: (t) => e.row.toggleSelected(t),
@@ -44125,7 +44125,7 @@ function Dme(e) {
header: t("author"),
cell: (e) => /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 items-center gap-2",
- children: [/* @__PURE__ */ (0, z.jsx)(xM, {
+ children: [/* @__PURE__ */ (0, z.jsx)(JM, {
group: e.row.original.group,
name: e.row.original.author
}), /* @__PURE__ */ (0, z.jsx)("span", {
@@ -44139,7 +44139,7 @@ function Dme(e) {
header: t("source"),
cell: (e) => /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 flex-col gap-0.5",
- children: [/* @__PURE__ */ (0, z.jsx)(CM, { source: e.row.original.source }), e.row.original.source.last_error ? /* @__PURE__ */ (0, z.jsx)("small", {
+ children: [/* @__PURE__ */ (0, z.jsx)(XM, { source: e.row.original.source }), e.row.original.source.last_error ? /* @__PURE__ */ (0, z.jsx)("small", {
className: "text-caption-1-regular text-text-error-primary",
children: e.row.original.source.last_error
}) : null]
@@ -44150,18 +44150,18 @@ function Dme(e) {
header: t("provider"),
cell: (e) => /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex items-center gap-1.5",
- children: [/* @__PURE__ */ (0, z.jsx)(bM, { provider: e.row.original.source.provider }), e.row.original.source.provider_label]
+ children: [/* @__PURE__ */ (0, z.jsx)(qM, { provider: e.row.original.source.provider }), e.row.original.source.provider_label]
})
}),
e.display({
id: "status",
header: t("status"),
- cell: (e) => /* @__PURE__ */ (0, z.jsx)(SM, { source: e.row.original.source })
+ cell: (e) => /* @__PURE__ */ (0, z.jsx)(YM, { source: e.row.original.source })
}),
e.accessor((e) => e.source.last_checked_at || "", {
id: "checked",
header: t("checked"),
- cell: (e) => zj(e.row.original.source)
+ cell: (e) => fM(e.row.original.source)
}),
e.display({
id: "actions",
@@ -44169,7 +44169,7 @@ function Dme(e) {
cell: (e) => /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex items-center gap-1",
children: [
- /* @__PURE__ */ (0, z.jsx)(GN, {
+ /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": `启用 ${e.row.original.source.label}`,
isSelected: e.row.original.source.enabled,
isDisabled: oe.readOnly,
@@ -44199,12 +44199,12 @@ function Dme(e) {
})
];
}, [oe]), ce = (0, R.useMemo)(() => {
- let e = Sme[n];
+ let e = xme[n];
return e ? [{
id: e,
desc: r === "desc"
}] : [];
- }, [n, r]), le = (0, R.useMemo)(() => Object.fromEntries([...s].map((e) => [String(e), !0])), [s]), ue = a === "table", L = Cj(ue ? O.length : D.length, o, i), de = WN({
+ }, [n, r]), le = (0, R.useMemo)(() => Object.fromEntries([...s].map((e) => [String(e), !0])), [s]), ue = a === "table", L = Xj(ue ? O.length : D.length, o, i), de = GN({
data: O,
columns: se,
getRowId: (e) => String(e.source.id),
@@ -44221,7 +44221,7 @@ function Dme(e) {
onSortingChange: (e) => {
let t = (typeof e == "function" ? e(ce) : e)[0];
if (!t) return;
- let n = fj[t.id];
+ let n = zj[t.id];
n && l(n, t.desc ? "desc" : "asc");
},
onRowSelectionChange: (e) => {
@@ -44235,9 +44235,9 @@ function Dme(e) {
}, n = typeof e == "function" ? e(t) : e;
n.pageSize === o ? n.pageIndex !== t.pageIndex && u(n.pageIndex + 1) : p(n.pageSize);
},
- getCoreRowModel: VN(),
- getPaginationRowModel: HN()
- }), fe = de.getRowModel().rows, pe = ue ? fe.map((e) => e.original.source.id) : D.slice(L.start, L.end).flatMap((e) => e.map((e) => e.id)), me = wj(s, pe), he = [...s], ge = jde(j), _e = Mde(j), ve = D.length > 0 && x.size >= D.length;
+ getCoreRowModel: HN(),
+ getPaginationRowModel: UN()
+ }), fe = de.getRowModel().rows, pe = ue ? fe.map((e) => e.original.source.id) : D.slice(L.start, L.end).flatMap((e) => e.map((e) => e.id)), me = Zj(s, pe), he = [...s], ge = ide(j), _e = ade(j), ve = D.length > 0 && x.size >= D.length;
return _.length ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: Zi({
padding: "none",
@@ -44274,27 +44274,27 @@ function Dme(e) {
variant: "ghost",
iconOnly: !0,
leadingIcon: dt,
- "aria-label": uj[0][1],
+ "aria-label": Lj[0][1],
"aria-pressed": !ue,
onClick: () => f("default")
}), /* @__PURE__ */ (0, z.jsx)(H, {
variant: "ghost",
iconOnly: !0,
leadingIcon: vt,
- "aria-label": uj[1][1],
+ "aria-label": Lj[1][1],
"aria-pressed": ue,
onClick: () => f("table")
})]
}),
- /* @__PURE__ */ (0, z.jsx)(py, {
+ /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "关注列表排序",
selectedKey: n,
onSelectionChange: (e) => {
if (e === null) return;
let t = String(e);
- l(t, ZA[t]);
+ l(t, wj[t]);
},
- children: XA.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: Cj.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e,
children: t
}, e))
@@ -44303,7 +44303,7 @@ function Dme(e) {
variant: "secondary",
iconOnly: !0,
leadingIcon: r === "asc" ? Ke : He,
- "aria-label": pde(n, r),
+ "aria-label": Bue(n, r),
onClick: () => l(n, r === "asc" ? "desc" : "asc")
}),
ue ? null : /* @__PURE__ */ (0, z.jsx)(H, {
@@ -44320,7 +44320,7 @@ function Dme(e) {
"aria-live": "polite",
className: "flex flex-col gap-3 empty:hidden",
children: [
- A ? /* @__PURE__ */ (0, z.jsx)(mO, {
+ A ? /* @__PURE__ */ (0, z.jsx)(lO, {
embedded: !0,
label: k?.message || (k?.total ? `${k.older ? "抓取历史" : "检查更新"}:已完成 ${k.checked || 0}/${k.total} 个来源` : "正在准备检查任务"),
value: k?.checked,
@@ -44346,7 +44346,7 @@ function Dme(e) {
}) : null
]
}),
- /* @__PURE__ */ (0, z.jsxs)(QP, {
+ /* @__PURE__ */ (0, z.jsxs)($P, {
label: "关注来源批量操作",
visible: he.length > 0,
count: `已选 ${he.length} 个来源`,
@@ -44406,10 +44406,10 @@ function Dme(e) {
})
]
}),
- ue ? /* @__PURE__ */ (0, z.jsx)(TO, {
+ ue ? /* @__PURE__ */ (0, z.jsx)(bO, {
follow: !0,
onRowClick: (e) => P(Number(e), !s.has(Number(e))),
- children: /* @__PURE__ */ (0, z.jsxs)(CO, {
+ children: /* @__PURE__ */ (0, z.jsxs)(vO, {
"aria-label": "关注来源",
size: "sm",
sortDescriptor: ce[0] ? {
@@ -44420,9 +44420,9 @@ function Dme(e) {
id: String(e.column),
desc: e.direction === "descending"
}]),
- children: [/* @__PURE__ */ (0, z.jsx)(Iv, { children: de.getHeaderGroups()[0].headers.map((e) => {
- let t = e.column.id in fj, n = UN(e.column.columnDef.header, e.getContext());
- return /* @__PURE__ */ (0, z.jsx)(zv, {
+ children: [/* @__PURE__ */ (0, z.jsx)(Wv, { children: de.getHeaderGroups()[0].headers.map((e) => {
+ let t = e.column.id in zj, n = WN(e.column.columnDef.header, e.getContext());
+ return /* @__PURE__ */ (0, z.jsx)(Kv, {
id: e.id,
allowsSorting: t,
isRowHeader: e.column.id === "source",
@@ -44431,20 +44431,20 @@ function Dme(e) {
children: [n, /* @__PURE__ */ (0, z.jsx)("span", {
"data-sort-indicator": !0,
"data-direction": e || void 0,
- children: /* @__PURE__ */ (0, z.jsx)(nne, {})
+ children: /* @__PURE__ */ (0, z.jsx)(Zte, {})
})]
}) : /* @__PURE__ */ (0, z.jsx)(ju, { children: n })
}, e.id);
- }) }), /* @__PURE__ */ (0, z.jsx)(Vv, {
+ }) }), /* @__PURE__ */ (0, z.jsx)(Jv, {
renderEmptyState: () => "这一页没有来源",
- children: fe.map((e) => /* @__PURE__ */ (0, z.jsx)(Wv, {
+ children: fe.map((e) => /* @__PURE__ */ (0, z.jsx)(Zv, {
id: e.id,
"data-follow-selected": e.getIsSelected() || void 0,
- children: e.getVisibleCells().map((e) => /* @__PURE__ */ (0, z.jsx)(qv, { children: UN(e.column.columnDef.cell, e.getContext()) }, e.id))
+ children: e.getVisibleCells().map((e) => /* @__PURE__ */ (0, z.jsx)($v, { children: WN(e.column.columnDef.cell, e.getContext()) }, e.id))
}, e.id))
})]
})
- }) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(SO, {
+ }) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: me.all,
isIndeterminate: me.some,
onChange: (e) => ee(pe, e),
@@ -44454,9 +44454,9 @@ function Dme(e) {
className: "flex flex-col gap-3",
children: D.slice(L.start, L.end).map((e) => {
let t = String(e[0].author_key || e[0].id);
- return /* @__PURE__ */ (0, z.jsx)(Eme, {
+ return /* @__PURE__ */ (0, z.jsx)(Tme, {
group: e,
- name: yj(e, v),
+ name: Kj(e, v),
handlers: oe,
selected: s,
open: !x.has(t),
@@ -44476,19 +44476,19 @@ function Dme(e) {
className: "text-body-2-regular text-text-secondary",
children: `${L.start + 1}–${L.end} / ${L.total} ${ue ? "个来源" : "位创作者"}`
}),
- /* @__PURE__ */ (0, z.jsx)(py, {
+ /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "每页显示数量",
size: "sm",
selectedKey: String(o),
onSelectionChange: (e) => {
e !== null && de.setPageSize(Number(e));
},
- children: dj.map((e) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: Rj.map((e) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: String(e),
children: `每页 ${e} ${ue ? "条" : "位"}`
}, e))
}),
- /* @__PURE__ */ (0, z.jsx)(eF, {
+ /* @__PURE__ */ (0, z.jsx)(tF, {
page: L.page,
pages: L.pages,
onPage: (e) => de.setPageIndex(e - 1)
@@ -44552,7 +44552,7 @@ function Dme(e) {
}
//#endregion
//#region src/react/follow-manage/feed-sources.tsx
-var Ome = {
+var Dme = {
select: "选择",
name: "名称",
kind: "类型",
@@ -44562,18 +44562,18 @@ var Ome = {
fetched: "上次拉取",
fresh: "上次新增",
actions: "操作"
-}, kme = /* @__PURE__ */ new Set(["select", "actions"]), tF = () => X.invalidateQueries({
- queryKey: lj,
+}, Ome = /* @__PURE__ */ new Set(["select", "actions"]), nF = () => X.invalidateQueries({
+ queryKey: Ij,
exact: !0
-}), nF = (e) => e.name || e.url, Ame = (e) => e >= 60 ? `每 ${Math.round(e / 60)} 小时` : `每 ${e} 分钟`;
-function jme(e) {
+}), rF = (e) => e.name || e.url, kme = (e) => e >= 60 ? `每 ${Math.round(e / 60)} 小时` : `每 ${e} 分钟`;
+function Ame(e) {
try {
return new URL(e).hostname.replace(/^www\./, "");
} catch {
return e;
}
}
-function Mme({ source: e }) {
+function jme({ source: e }) {
return e.last_error ? /* @__PURE__ */ (0, z.jsx)(zi, {
variant: "caption",
color: "rose",
@@ -44588,7 +44588,7 @@ function Mme({ source: e }) {
children: "已暂停"
});
}
-function Nme({ source: e, avatarInner: t }) {
+function Mme({ source: e, avatarInner: t }) {
let n = e.entity_id ? {
id: e.entity_id,
has_image: !!e.has_image,
@@ -44596,31 +44596,31 @@ function Nme({ source: e, avatarInner: t }) {
} : null;
return /* @__PURE__ */ (0, z.jsx)("span", {
"aria-hidden": !0,
- className: `relative inline-grid size-8 shrink-0 place-items-center overflow-hidden rounded-full bg-background-tertiary-default text-caption-1-semibold text-text-secondary ${KN}`,
- dangerouslySetInnerHTML: { __html: t(nF(e), n, null, "performer") }
+ className: `relative inline-grid size-8 shrink-0 place-items-center overflow-hidden rounded-full bg-background-tertiary-default text-caption-1-semibold text-text-secondary ${qN}`,
+ dangerouslySetInnerHTML: { __html: t(rF(e), n, null, "performer") }
});
}
-var Pme = (e, t) => e.entity_id !== null && t.has(e.entity_id) && e.page_name && e.page_name !== e.name ? e.page_name : "";
-function Fme(e) {
+var Nme = (e, t) => e.entity_id !== null && t.has(e.entity_id) && e.page_name && e.page_name !== e.name ? e.page_name : "";
+function Pme(e) {
let t = /* @__PURE__ */ new Set(), n = /* @__PURE__ */ new Set();
for (let { entity_id: r } of e) r !== null && (t.has(r) ? n.add(r) : t.add(r));
return n;
}
-function rF(e, t) {
+function iF(e, t) {
let n = e.length === 1 ? e[0] : null;
return b({
title: n ? "移除订阅源" : `移除 ${e.length} 条订阅源`,
- body: n ? `将移除订阅源「${nF(n)}」,之后不再拉取它的新作;已经拉到的新作保留。` : "将移除所选订阅源,之后不再拉取它们的新作;已经拉到的新作保留。",
+ body: n ? `将移除订阅源「${rF(n)}」,之后不再拉取它的新作;已经拉到的新作保留。` : "将移除所选订阅源,之后不再拉取它们的新作;已经拉到的新作保留。",
confirmLabel: n ? "移除订阅源" : "移除所选订阅源",
danger: !0,
onConfirm: t
});
}
-function Ime({ readOnly: e, toast: t, avatarInner: n }) {
+function Fme({ readOnly: e, toast: t, avatarInner: n }) {
let r = $n({
- queryKey: lj,
- queryFn: ({ signal: e }) => Mj(e)
- }), i = aa(), a = r.data, o = (0, R.useMemo)(() => a?.sources ?? [], [a]), [s, c] = (0, R.useState)(/* @__PURE__ */ new Set()), [l, u] = (0, R.useState)(1), [f, p] = (0, R.useState)(20), m = Cj(o.length, f, l);
+ queryKey: Ij,
+ queryFn: ({ signal: e }) => aM(e)
+ }), i = aa(), a = r.data, o = (0, R.useMemo)(() => a?.sources ?? [], [a]), [s, c] = (0, R.useState)(/* @__PURE__ */ new Set()), [l, u] = (0, R.useState)(1), [f, p] = (0, R.useState)(20), m = Xj(o.length, f, l);
(0, R.useEffect)(() => {
u((e) => Math.min(e, m.pages));
}, [m.pages]), (0, R.useEffect)(() => {
@@ -44632,7 +44632,7 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
let h = er({
mutationFn: async (e) => {
let t = await d(e.ids, 4, async (t) => {
- e.action === "remove" ? await Pj(t) : await Nj(t, e.action === "enabled");
+ e.action === "remove" ? await sM(t) : await oM(t, e.action === "enabled");
});
return {
...e,
@@ -44641,13 +44641,13 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
},
onSuccess: (e) => {
let n = e.results.filter((e) => !e.ok), r = e.ids.length - n.length;
- if (c(/* @__PURE__ */ new Set()), tF(), e.action === "remove" && r && t(`已移除 ${r} 条订阅源`), n.length) {
+ if (c(/* @__PURE__ */ new Set()), nF(), e.action === "remove" && r && t(`已移除 ${r} 条订阅源`), n.length) {
let e = n[0];
i.setError(`${n.length} 条没有写入:${e.ok ? "" : U(e.error)}`);
}
},
onError: (e) => i.setError(U(e))
- }), g = (0, R.useMemo)(() => Fme(o), [o]), _ = (0, R.useRef)({
+ }), g = (0, R.useMemo)(() => Pme(o), [o]), _ = (0, R.useRef)({
readOnly: e,
avatarInner: n,
shared: g,
@@ -44661,34 +44661,34 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
avatarInner: n,
shared: g,
busy: i.busy,
- toggle: (e, t) => void i.run(`enabled-${e.id}`, (n) => Nj(e.id, t, n), () => void tF()),
- fetch: (e) => void i.run(`check-${e.id}`, (t) => Fj(t, [e.id]), () => void tF()),
- remove: (e) => void rF([e], async () => {
- await Pj(e.id), t(`已移除订阅源「${nF(e)}」`), tF();
+ toggle: (e, t) => void i.run(`enabled-${e.id}`, (n) => oM(e.id, t, n), () => void nF()),
+ fetch: (e) => void i.run(`check-${e.id}`, (t) => cM(t, [e.id]), () => void nF()),
+ remove: (e) => void iF([e], async () => {
+ await sM(e.id), t(`已移除订阅源「${rF(e)}」`), nF();
})
};
let v = (0, R.useMemo)(() => {
- let e = OM(), t = (e) => () => Ome[e] || e;
+ let e = tN(), t = (e) => () => Dme[e] || e;
return [
e.display({
id: "select",
header: t("select"),
- cell: (e) => /* @__PURE__ */ (0, z.jsx)(SO, {
+ cell: (e) => /* @__PURE__ */ (0, z.jsx)(_O, {
slot: null,
isSelected: e.row.getIsSelected(),
onChange: (t) => e.row.toggleSelected(t),
- "aria-label": `选择 ${nF(e.row.original)}`
+ "aria-label": `选择 ${rF(e.row.original)}`
})
}),
- e.accessor(nF, {
+ e.accessor(rF, {
id: "name",
header: t("name"),
cell: (e) => {
- let t = Pme(e.row.original, _.current.shared);
+ let t = Nme(e.row.original, _.current.shared);
return /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex items-center gap-2 whitespace-nowrap text-body-medium text-text-primary",
children: [
- /* @__PURE__ */ (0, z.jsx)(Nme, {
+ /* @__PURE__ */ (0, z.jsx)(Mme, {
source: e.row.original,
avatarInner: _.current.avatarInner
}),
@@ -44719,15 +44719,15 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
rel: "noreferrer noopener",
title: "打开来源页面",
className: "text-text-primary underline-offset-2 hover:underline",
- children: jme(e.getValue())
+ children: Ame(e.getValue())
})
}),
e.display({
id: "status",
header: t("status"),
- cell: (e) => /* @__PURE__ */ (0, z.jsx)(Mme, { source: e.row.original })
+ cell: (e) => /* @__PURE__ */ (0, z.jsx)(jme, { source: e.row.original })
}),
- e.accessor((e) => Ame(e.interval_minutes), {
+ e.accessor((e) => kme(e.interval_minutes), {
id: "interval",
header: t("interval"),
cell: (e) => /* @__PURE__ */ (0, z.jsx)("span", {
@@ -44735,7 +44735,7 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
children: e.getValue()
})
}),
- e.accessor((e) => e.last_fetched_at ? ux(e.last_fetched_at) : "还没拉过", {
+ e.accessor((e) => e.last_fetched_at ? hx(e.last_fetched_at) : "还没拉过", {
id: "fetched",
header: t("fetched"),
cell: (e) => /* @__PURE__ */ (0, z.jsx)("span", {
@@ -44757,8 +44757,8 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
cell: (e) => /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex items-center gap-1",
children: [
- /* @__PURE__ */ (0, z.jsx)(GN, {
- "aria-label": `启用 ${nF(e.row.original)}`,
+ /* @__PURE__ */ (0, z.jsx)(KN, {
+ "aria-label": `启用 ${rF(e.row.original)}`,
isSelected: e.row.original.enabled,
isDisabled: _.current.readOnly,
onChange: (t) => _.current.toggle(e.row.original, t)
@@ -44768,7 +44768,7 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
size: "xs",
iconOnly: !0,
leadingIcon: mt,
- "aria-label": `拉取 ${nF(e.row.original)}`,
+ "aria-label": `拉取 ${rF(e.row.original)}`,
disabled: _.current.readOnly,
...q(_.current.busy === `check-${e.row.original.id}`),
onClick: () => _.current.fetch(e.row.original)
@@ -44778,7 +44778,7 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
size: "xs",
iconOnly: !0,
leadingIcon: $e,
- "aria-label": `移除 ${nF(e.row.original)}`,
+ "aria-label": `移除 ${rF(e.row.original)}`,
disabled: _.current.readOnly,
onClick: () => _.current.remove(e.row.original)
})
@@ -44786,7 +44786,7 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
})
})
];
- }, []), y = (0, R.useMemo)(() => Object.fromEntries([...s].map((e) => [String(e), !0])), [s]), b = WN({
+ }, []), y = (0, R.useMemo)(() => Object.fromEntries([...s].map((e) => [String(e), !0])), [s]), b = GN({
data: o,
columns: v,
getRowId: (e) => String(e.id),
@@ -44802,24 +44802,24 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
let t = typeof e == "function" ? e(y) : e;
c(new Set(Object.entries(t).filter(([, e]) => e).map(([e]) => Number(e))));
},
- getCoreRowModel: VN(),
- getPaginationRowModel: HN()
+ getCoreRowModel: HN(),
+ getPaginationRowModel: UN()
});
if (!a) return r.error ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
title: "打不开订阅源",
children: U(r.error)
- }) : /* @__PURE__ */ (0, z.jsx)(wy, { children: "正在读订阅源。" });
- let x = () => void i.run("check", (e) => Fj(e), () => void tF()), S = (e) => c((t) => {
+ }) : /* @__PURE__ */ (0, z.jsx)(ky, { children: "正在读订阅源。" });
+ let x = () => void i.run("check", (e) => cM(e), () => void nF()), S = (e) => c((t) => {
let n = new Set(t);
return n.has(e) ? n.delete(e) : n.add(e), n;
}), C = o.filter((e) => s.has(e.id)), w = o.filter((e) => e.last_error);
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-3",
- children: [/* @__PURE__ */ (0, z.jsx)(xme, {
+ children: [/* @__PURE__ */ (0, z.jsx)(bme, {
readOnly: e,
toast: t,
- onAdded: () => void tF()
+ onAdded: () => void nF()
}), /* @__PURE__ */ (0, z.jsxs)("section", {
"aria-label": "JAV 订阅列表",
className: Zi({
@@ -44850,11 +44850,11 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
className: "flex flex-col gap-3",
children: [w.map((e) => /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
- title: `${nF(e)} 拉取失败`,
+ title: `${rF(e)} 拉取失败`,
children: e.last_error
- }, e.id)), i.error ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: i.error }) : null]
+ }, e.id)), i.error ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: i.error }) : null]
}) : null,
- /* @__PURE__ */ (0, z.jsxs)(QP, {
+ /* @__PURE__ */ (0, z.jsxs)($P, {
visible: C.length > 0,
label: "订阅源批量操作",
count: `已选 ${C.length} 条订阅源`,
@@ -44886,7 +44886,7 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
size: "small",
disabled: e,
...q(h.isPending),
- onClick: () => void rF(C, () => h.mutateAsync({
+ onClick: () => void iF(C, () => h.mutateAsync({
ids: C.map((e) => e.id),
action: "remove"
})),
@@ -44900,22 +44900,22 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
})
]
}),
- o.length ? /* @__PURE__ */ (0, z.jsx)(TO, {
+ o.length ? /* @__PURE__ */ (0, z.jsx)(bO, {
onRowClick: (e) => S(Number(e)),
- children: /* @__PURE__ */ (0, z.jsxs)(CO, {
+ children: /* @__PURE__ */ (0, z.jsxs)(vO, {
"aria-label": "JAV 订阅源",
size: "sm",
- children: [/* @__PURE__ */ (0, z.jsx)(Iv, { children: b.getHeaderGroups()[0].headers.map((e) => {
- let t = UN(e.column.columnDef.header, e.getContext());
- return /* @__PURE__ */ (0, z.jsx)(zv, {
+ children: [/* @__PURE__ */ (0, z.jsx)(Wv, { children: b.getHeaderGroups()[0].headers.map((e) => {
+ let t = WN(e.column.columnDef.header, e.getContext());
+ return /* @__PURE__ */ (0, z.jsx)(Kv, {
id: e.id,
isRowHeader: e.column.id === "name",
- children: kme.has(e.column.id) ? /* @__PURE__ */ (0, z.jsx)(ju, { children: t }) : t
+ children: Ome.has(e.column.id) ? /* @__PURE__ */ (0, z.jsx)(ju, { children: t }) : t
}, e.id);
- }) }), /* @__PURE__ */ (0, z.jsx)(Vv, { children: b.getRowModel().rows.map((e) => /* @__PURE__ */ (0, z.jsx)(Wv, {
+ }) }), /* @__PURE__ */ (0, z.jsx)(Jv, { children: b.getRowModel().rows.map((e) => /* @__PURE__ */ (0, z.jsx)(Zv, {
id: e.id,
"data-follow-selected": e.getIsSelected() || void 0,
- children: e.getVisibleCells().map((e) => /* @__PURE__ */ (0, z.jsx)(qv, { children: UN(e.column.columnDef.cell, e.getContext()) }, e.id))
+ children: e.getVisibleCells().map((e) => /* @__PURE__ */ (0, z.jsx)($v, { children: WN(e.column.columnDef.cell, e.getContext()) }, e.id))
}, e.id)) })]
})
}) : /* @__PURE__ */ (0, z.jsx)($i, {
@@ -44931,19 +44931,19 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
className: "text-body-2-regular text-text-secondary",
children: `${m.start + 1}–${m.end} / ${m.total} 个订阅源`
}),
- /* @__PURE__ */ (0, z.jsx)(py, {
+ /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "每页显示数量",
size: "sm",
selectedKey: String(f),
onSelectionChange: (e) => {
e !== null && (p(Number(e)), u(1));
},
- children: dj.map((e) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: Rj.map((e) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: String(e),
children: `每页 ${e} 条`
}, e))
}),
- /* @__PURE__ */ (0, z.jsx)(eF, {
+ /* @__PURE__ */ (0, z.jsx)(tF, {
label: "JAV 订阅分页",
page: m.page,
pages: m.pages,
@@ -44965,41 +44965,41 @@ function Ime({ readOnly: e, toast: t, avatarInner: n }) {
}
//#endregion
//#region src/react/wants/wants.ts
-var iF = "/api/wants", aF = ["wants"], Lme = (e) => [
+var aF = "/api/wants", oF = ["wants"], Ime = (e) => [
"wants",
"follow",
e
-], Rme = [
+], Lme = [
["searching", "待找"],
["unreleased", "未发售"],
["given_up", "暂时放弃"],
["acquired", "已入库"]
-], zme = (e) => W(iF, e), Bme = (e, t) => W(`${iF}?follow=${encodeURIComponent(e)}`, t), oF = (e, t) => G(iF, {
+], Rme = (e) => W(aF, e), zme = (e, t) => W(`${aF}?follow=${encodeURIComponent(e)}`, t), sF = (e, t) => G(aF, {
action: "add",
...e
-}, "POST", t), sF = (e, t) => G(iF, {
+}, "POST", t), cF = (e, t) => G(aF, {
action: "remove",
ids: e
-}, "POST", t), Vme = (e, t) => G(iF, {
+}, "POST", t), Bme = (e, t) => G(aF, {
action: "reset",
ids: e
-}, "POST", t), cF = () => X.invalidateQueries({ queryKey: aF }), lF = (e) => e.code || e.title || `关注条目 ${e.follow_item_id ?? e.id}`;
-function Hme(e) {
+}, "POST", t), lF = () => X.invalidateQueries({ queryKey: oF }), uF = (e) => e.code || e.title || `关注条目 ${e.follow_item_id ?? e.id}`;
+function Vme(e) {
return e.phase === "acquired" ? e.acquired_at ? `入库于 ${e.acquired_at.slice(0, 10)}` : "已入库" : e.phase === "unreleased" ? e.release_date ? `${e.release_date} 发售` : "还没发售" : e.phase === "given_up" ? `查过 ${e.search_count} 次都没找到` : e.fresh ? "新片:查不到也一直留在待找" : e.search_count ? `查过 ${e.search_count} 次` : "还没查过";
}
//#endregion
//#region src/react/wants/want-list.tsx
-var Ume = {
+var Hme = {
code: "手动添加",
feed: "Feed 新作",
follow: "关注"
-}, uF = (e) => [
+}, dF = (e) => [
e.release_date,
e.studio,
e.performers,
- Ume[e.origin]
+ Hme[e.origin]
].filter(Boolean).join(" · ");
-function Wme({ want: e }) {
+function Ume({ want: e }) {
return /* @__PURE__ */ (0, z.jsxs)("span", {
className: "relative inline-grid w-card-cover shrink-0 aspect-card-cover place-items-center overflow-hidden rounded-2lg bg-background-tertiary-default max-sm:w-24",
children: [/* @__PURE__ */ (0, z.jsx)("span", {
@@ -45015,36 +45015,36 @@ function Wme({ want: e }) {
}) : null]
});
}
-function Gme({ want: e, first: t, readOnly: n, busy: r, onReset: i, onRemove: a, onCloudDownload: o }) {
+function Wme({ want: e, first: t, readOnly: n, busy: r, onReset: i, onRemove: a, onCloudDownload: o }) {
return /* @__PURE__ */ (0, z.jsxs)("li", {
"data-want-id": e.id,
className: `flex min-w-0 items-start gap-4 py-4 max-sm:gap-3 ${t ? "" : "border-t border-separator-border"}`,
- children: [/* @__PURE__ */ (0, z.jsx)(Wme, { want: e }), /* @__PURE__ */ (0, z.jsxs)("div", {
+ children: [/* @__PURE__ */ (0, z.jsx)(Ume, { want: e }), /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-w-0 flex-1 flex-col gap-1",
children: [
/* @__PURE__ */ (0, z.jsxs)("p", {
className: "flex min-w-0 flex-wrap items-baseline gap-x-2",
children: [/* @__PURE__ */ (0, z.jsx)("b", {
className: "text-headline-medium text-text-primary",
- children: lF(e)
+ children: uF(e)
}), e.code && e.title ? /* @__PURE__ */ (0, z.jsx)("span", {
className: "min-w-0 truncate text-body-2-regular text-text-secondary",
children: e.title
}) : null]
}),
- uF(e) ? /* @__PURE__ */ (0, z.jsx)("p", {
+ dF(e) ? /* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
- children: uF(e)
+ children: dF(e)
}) : null,
/* @__PURE__ */ (0, z.jsxs)("p", {
"data-want-note": "",
className: "text-caption-1-regular text-text-secondary",
- children: [Hme(e), e.scrape_error ? `;资料没取到:${e.scrape_error}` : ""]
+ children: [Vme(e), e.scrape_error ? `;资料没取到:${e.scrape_error}` : ""]
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "mt-1 flex flex-wrap items-center gap-2",
children: [
- e.link ? /* @__PURE__ */ (0, z.jsx)(Dy, {
+ e.link ? /* @__PURE__ */ (0, z.jsx)(My, {
href: e.link,
children: "来源页"
}) : null,
@@ -45077,25 +45077,25 @@ function Gme({ want: e, first: t, readOnly: n, busy: r, onReset: i, onRemove: a,
})]
});
}
-function Kme({ readOnly: e, toast: t, cloudDownload: n }) {
+function Gme({ readOnly: e, toast: t, cloudDownload: n }) {
let [r, i] = (0, R.useState)(""), a = aa(), o = $n({
- queryKey: aF,
- queryFn: ({ signal: e }) => zme(e),
+ queryKey: oF,
+ queryFn: ({ signal: e }) => Rme(e),
refetchInterval: (e) => e.state.data?.scraping ? 3e3 : !1
}), s = () => {
let n = r.trim();
- !n || e || a.run("add", (e) => oF({ code: n }, e), (e) => {
- t(e.created ? `已加入想要:${lF(e.want)}` : `${lF(e.want)} 已经在想要里`), i(""), cF();
+ !n || e || a.run("add", (e) => sF({ code: n }, e), (e) => {
+ t(e.created ? `已加入想要:${uF(e.want)}` : `${uF(e.want)} 已经在想要里`), i(""), lF();
});
}, c = (e) => {
e.key === "Enter" && !e.nativeEvent.isComposing && (e.preventDefault(), s());
}, l = (e) => {
- a.run(`remove:${e.id}`, (t) => sF([e.id], t), () => {
- t(`已移除:${lF(e)}`), cF();
+ a.run(`remove:${e.id}`, (t) => cF([e.id], t), () => {
+ t(`已移除:${uF(e)}`), lF();
});
}, u = (e) => {
- a.run(`reset:${e.id}`, (t) => Vme([e.id], t), () => {
- t(`${lF(e)} 回到待找`), cF();
+ a.run(`reset:${e.id}`, (t) => Bme([e.id], t), () => {
+ t(`${uF(e)} 回到待找`), lF();
});
}, d = o.data, f = d?.items || [];
return /* @__PURE__ */ (0, z.jsxs)("div", {
@@ -45115,7 +45115,7 @@ function Kme({ readOnly: e, toast: t, cloudDownload: n }) {
className: "flex flex-wrap items-end gap-2",
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "min-w-64 grow max-sm:min-w-0",
- children: /* @__PURE__ */ (0, z.jsx)(cy, {
+ children: /* @__PURE__ */ (0, z.jsx)(py, {
"aria-label": "番号",
placeholder: "输入番号,例如 SSIS-950",
value: r,
@@ -45131,7 +45131,7 @@ function Kme({ readOnly: e, toast: t, cloudDownload: n }) {
children: "添加"
})]
}),
- /* @__PURE__ */ (0, z.jsx)(wy, { children: "Feed 新作卡和关注详情上点「想要」也会加到这里。文件扫进库后自动挪到「已入库」。" }),
+ /* @__PURE__ */ (0, z.jsx)(ky, { children: "Feed 新作卡和关注详情上点「想要」也会加到这里。文件扫进库后自动挪到「已入库」。" }),
a.error ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
title: "这一次没有完成",
@@ -45144,7 +45144,7 @@ function Kme({ readOnly: e, toast: t, cloudDownload: n }) {
title: "想要清单读取失败",
children: U(o.error)
}) : null,
- d?.scraping ? /* @__PURE__ */ (0, z.jsx)(wy, {
+ d?.scraping ? /* @__PURE__ */ (0, z.jsx)(ky, {
role: "status",
children: "正在给刚加入的番号取资料与封面。"
}) : null,
@@ -45154,7 +45154,7 @@ function Kme({ readOnly: e, toast: t, cloudDownload: n }) {
title: "还没有想要的作品",
children: "在上面输入番号,或在 Feed 新作卡、关注详情上点「想要」。"
}) : null,
- Rme.map(([t, r]) => {
+ Lme.map(([t, r]) => {
let i = f.filter((e) => e.phase === t);
return i.length ? /* @__PURE__ */ (0, z.jsxs)("section", {
"aria-label": r,
@@ -45168,7 +45168,7 @@ function Kme({ readOnly: e, toast: t, cloudDownload: n }) {
})]
}), /* @__PURE__ */ (0, z.jsx)("ul", {
className: "flex flex-col",
- children: i.map((t, r) => /* @__PURE__ */ (0, z.jsx)(Gme, {
+ children: i.map((t, r) => /* @__PURE__ */ (0, z.jsx)(Wme, {
want: t,
first: r === 0,
readOnly: e,
@@ -45189,14 +45189,14 @@ function Kme({ readOnly: e, toast: t, cloudDownload: n }) {
}
//#endregion
//#region src/react/follow-manage/follow-manage-page.tsx
-var dF = [
+var fF = [
["list", "关注列表"],
["add", "添加关注"],
["feeds", "JAV 订阅源"],
["wants", "想要"],
["source", "来源和凭证"]
-], fF = (e) => dF.some(([t]) => t === e);
-function pF({ term: e, figure: t, unit: n }) {
+], pF = (e) => fF.some(([t]) => t === e);
+function mF({ term: e, figure: t, unit: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: Zi({
padding: "none",
@@ -45214,23 +45214,23 @@ function pF({ term: e, figure: t, unit: n }) {
})]
});
}
-function qme(e) {
- let { route: t, savePreference: n, toast: r, openFollow: i, cloudDownload: a, readOnly: o, readOnlyMessage: s, writerUrl: c } = e, [l, u] = (0, R.useState)(fF(e.tab) ? e.tab : "list"), [d, f] = (0, R.useState)(Math.max(1, Math.floor(e.page) || 1)), [p, m] = (0, R.useState)(() => QA(e.sort, e.dir).sort), [h, g] = (0, R.useState)(() => QA(e.sort, e.dir).dir), [_, v] = (0, R.useState)(ude(e.layout) ? e.layout : "default"), [y, b] = (0, R.useState)(dde(e.pageSize)), [x, S] = (0, R.useState)(/* @__PURE__ */ new Set()), C = $n({
- queryKey: sj,
- queryFn: ({ signal: e }) => Ej(e)
+function Kme(e) {
+ let { route: t, savePreference: n, toast: r, openFollow: i, cloudDownload: a, readOnly: o, readOnlyMessage: s, writerUrl: c } = e, [l, u] = (0, R.useState)(pF(e.tab) ? e.tab : "list"), [d, f] = (0, R.useState)(Math.max(1, Math.floor(e.page) || 1)), [p, m] = (0, R.useState)(() => Tj(e.sort, e.dir).sort), [h, g] = (0, R.useState)(() => Tj(e.sort, e.dir).dir), [_, v] = (0, R.useState)(Lue(e.layout) ? e.layout : "default"), [y, b] = (0, R.useState)(Rue(e.pageSize)), [x, S] = (0, R.useState)(/* @__PURE__ */ new Set()), C = $n({
+ queryKey: Pj,
+ queryFn: ({ signal: e }) => $j(e)
}), w = $n({
- queryKey: cj,
- queryFn: ({ signal: e }) => Dj(e)
+ queryKey: Fj,
+ queryFn: ({ signal: e }) => eM(e)
}), T = $n({
- queryKey: lj,
- queryFn: ({ signal: e }) => Mj(e)
+ queryKey: Ij,
+ queryFn: ({ signal: e }) => aM(e)
}), E = C.data || { sources: [] }, D = w.data || {
root: "",
providers: []
}, O = E.sources;
(0, R.useEffect)(() => {
S((e) => {
- let t = _de(e, O);
+ let t = Wue(e, O);
return t.size === e.size ? e : t;
});
}, [O]);
@@ -45240,9 +45240,9 @@ function qme(e) {
tab: e.tab ?? l,
page: e.page ?? d,
sort: n === "checked" ? "" : n,
- dir: r === ZA[n] ? "" : r
+ dir: r === wj[n] ? "" : r
});
- }, A = Sj(O), j = O.filter(mj).length, M = O.filter((e) => e.enabled).length, N = (D.providers || []).filter((e) => e.requirement === "required" && !Vj(e)).length, P = new Set((T.data?.sources || []).map((e) => e.entity_id ?? `source-${e.id}`)).size;
+ }, A = Yj(O), j = O.filter(Vj).length, M = O.filter((e) => e.enabled).length, N = (D.providers || []).filter((e) => e.requirement === "required" && !mM(e)).length, P = new Set((T.data?.sources || []).map((e) => e.entity_id ?? `source-${e.id}`)).size;
return /* @__PURE__ */ (0, z.jsxs)(ta, { children: [
o ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "warning",
@@ -45258,64 +45258,64 @@ function qme(e) {
children: s
}) : null,
/* @__PURE__ */ (0, z.jsxs)("div", {
- className: $re,
+ className: Die,
"aria-label": "关注概览",
children: [
- /* @__PURE__ */ (0, z.jsx)(pF, {
+ /* @__PURE__ */ (0, z.jsx)(mF, {
term: "关注创作者",
figure: A.length,
unit: "位"
}),
- /* @__PURE__ */ (0, z.jsx)(pF, {
+ /* @__PURE__ */ (0, z.jsx)(mF, {
term: "启用来源",
figure: M,
unit: `/ ${O.length}`
}),
- /* @__PURE__ */ (0, z.jsx)(pF, {
+ /* @__PURE__ */ (0, z.jsx)(mF, {
term: "检查失败",
figure: j,
unit: "个来源"
}),
- /* @__PURE__ */ (0, z.jsx)(pF, {
+ /* @__PURE__ */ (0, z.jsx)(mF, {
term: "未看更新",
figure: E.counts?.new || 0,
unit: "条"
}),
- /* @__PURE__ */ (0, z.jsx)(pF, {
+ /* @__PURE__ */ (0, z.jsx)(mF, {
term: "JAV 订阅",
figure: P,
unit: "位"
}),
- /* @__PURE__ */ (0, z.jsx)(pF, {
+ /* @__PURE__ */ (0, z.jsx)(mF, {
term: "未看新作",
figure: T.data?.unread || 0,
unit: "条"
})
]
}),
- /* @__PURE__ */ (0, z.jsxs)($v, {
+ /* @__PURE__ */ (0, z.jsxs)(ay, {
selectedKey: l,
onSelectionChange: (e) => {
let t = String(e);
- fF(t) && (u(t), k({ tab: t }));
+ pF(t) && (u(t), k({ tab: t }));
},
className: "flex flex-col gap-6",
children: [
- /* @__PURE__ */ (0, z.jsx)(ty, {
+ /* @__PURE__ */ (0, z.jsx)(oy, {
"aria-label": "关注管理区域",
"data-section-nav": !0,
"data-section-items": !0,
className: "flex max-w-full flex-nowrap overflow-x-auto",
- children: dF.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(ny, {
+ children: fF.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(sy, {
id: e,
className: "cursor-pointer whitespace-nowrap",
children: e === "source" && N ? `${t}(${N})` : t
}, e))
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "list",
className: "flex flex-col gap-4",
- children: /* @__PURE__ */ (0, z.jsx)(Dme, {
+ children: /* @__PURE__ */ (0, z.jsx)(Eme, {
data: E,
sort: p,
dir: h,
@@ -45345,10 +45345,10 @@ function qme(e) {
}
})
}),
- /* @__PURE__ */ (0, z.jsxs)(ry, {
+ /* @__PURE__ */ (0, z.jsxs)(cy, {
id: "add",
className: "flex flex-col gap-8",
- children: [/* @__PURE__ */ (0, z.jsx)(Efe, {
+ children: [/* @__PURE__ */ (0, z.jsx)($de, {
data: E,
credentials: D,
readOnly: o,
@@ -45356,7 +45356,7 @@ function qme(e) {
openCredentials: () => {
u("source"), k({ tab: "source" });
}
- }), /* @__PURE__ */ (0, z.jsx)(kfe, {
+ }), /* @__PURE__ */ (0, z.jsx)(nfe, {
groups: E.author_aliases || [],
readOnly: o,
toast: r,
@@ -45364,28 +45364,28 @@ function qme(e) {
sources: E.sources
})]
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "feeds",
className: "flex flex-col gap-4",
- children: /* @__PURE__ */ (0, z.jsx)(Ime, {
+ children: /* @__PURE__ */ (0, z.jsx)(Fme, {
readOnly: o,
toast: r,
avatarInner: e.avatarInner
})
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "wants",
className: "flex flex-col gap-4",
- children: /* @__PURE__ */ (0, z.jsx)(Kme, {
+ children: /* @__PURE__ */ (0, z.jsx)(Gme, {
readOnly: o,
toast: r,
cloudDownload: a
})
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "source",
className: "flex flex-col gap-4",
- children: /* @__PURE__ */ (0, z.jsx)(Rfe, {
+ children: /* @__PURE__ */ (0, z.jsx)(dfe, {
data: D,
readOnly: o,
toast: r
@@ -45397,23 +45397,23 @@ function qme(e) {
}
//#endregion
//#region src/react/index/index-tags.tsx
-var mF = () => /* @__PURE__ */ (0, z.jsx)("span", {
+var hF = () => /* @__PURE__ */ (0, z.jsx)("span", {
"aria-hidden": !0,
"data-tag-dot": "",
className: "size-1.75 flex-none rounded-full"
});
-function Jme({ tag: e, actions: t }) {
+function qme({ tag: e, actions: t }) {
let n = t.picked.has(e.k);
return /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
"data-alpha-tag": "",
"data-k": e.k,
- "data-tag-cat": Xk(t.online, e.cat),
+ "data-tag-cat": fA(t.online, e.cat),
"aria-pressed": n,
onClick: () => t.press(e.k),
className: "flex h-9 min-w-0 cursor-pointer items-center gap-2.25 rounded-lg px-2.5 text-left text-body-regular text-text-secondary outline-none hover:text-text-primary focus-visible:ring-2 focus-visible:ring-border-focus-ring",
children: [
- /* @__PURE__ */ (0, z.jsx)(mF, {}),
+ /* @__PURE__ */ (0, z.jsx)(hF, {}),
/* @__PURE__ */ (0, z.jsx)("span", {
className: "min-w-0 flex-1 truncate",
children: e.label
@@ -45425,7 +45425,7 @@ function Jme({ tag: e, actions: t }) {
]
});
}
-function Yme({ groups: e, actions: t }) {
+function Jme({ groups: e, actions: t }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-alphabet": "",
className: "flex flex-col gap-4",
@@ -45438,10 +45438,10 @@ function Yme({ groups: e, actions: t }) {
}),
children: [/* @__PURE__ */ (0, z.jsxs)("h3", {
className: "mb-2 flex items-center text-title-2-medium text-text-primary",
- children: [e, /* @__PURE__ */ (0, z.jsx)(fk, { value: n.length })]
+ children: [e, /* @__PURE__ */ (0, z.jsx)(ik, { value: n.length })]
}), /* @__PURE__ */ (0, z.jsx)("div", {
className: "index-tag-list gap-x-4 gap-y-0.5",
- children: n.map((e) => /* @__PURE__ */ (0, z.jsx)(Jme, {
+ children: n.map((e) => /* @__PURE__ */ (0, z.jsx)(qme, {
tag: e,
actions: t
}, e.k))
@@ -45449,8 +45449,8 @@ function Yme({ groups: e, actions: t }) {
}, e))
});
}
-var Xme = "\xA0";
-function Zme({ tags: e, actions: t }) {
+var Yme = "\xA0";
+function Xme({ tags: e, actions: t }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-tag-cloud": "",
className: "flex flex-wrap gap-1.75",
@@ -45458,11 +45458,11 @@ function Zme({ tags: e, actions: t }) {
type: "button",
"data-tag-chip": "",
"data-k": e.k,
- "data-tag-cat": Xk(t.online, e.cat),
+ "data-tag-cat": fA(t.online, e.cat),
"aria-pressed": t.picked.has(e.k),
onClick: () => t.press(e.k),
className: "inline-flex cursor-pointer items-center rounded-lg border px-3 py-1.25 text-body-2-regular text-text-secondary outline-none focus-visible:ring-2 focus-visible:ring-border-focus-ring",
- children: [e.label + Xme, /* @__PURE__ */ (0, z.jsx)("span", {
+ children: [e.label + Yme, /* @__PURE__ */ (0, z.jsx)("span", {
"data-tag-n": "",
className: "text-caption-1-regular opacity-60",
children: e.n.toLocaleString()
@@ -45470,7 +45470,7 @@ function Zme({ tags: e, actions: t }) {
}, e.k))
});
}
-var Qme = [[
+var Zme = [[
"cloud",
"标签云",
"tags"
@@ -45479,16 +45479,16 @@ var Qme = [[
"字母表",
"text-aa"
]];
-function $me({ categories: e, category: t, online: n, readout: r, letters: i, view: a, onCategory: o, onJump: s, onView: c }) {
- return /* @__PURE__ */ (0, z.jsx)(HO, {
+function Qme({ categories: e, category: t, online: n, readout: r, letters: i, view: a, onCategory: o, onJump: s, onView: c }) {
+ return /* @__PURE__ */ (0, z.jsx)(IO, {
label: "标签筛选",
topLabel: "标签类型",
- top: e.map(([e, r]) => /* @__PURE__ */ (0, z.jsxs)(UO, {
+ top: e.map(([e, r]) => /* @__PURE__ */ (0, z.jsxs)(LO, {
"data-tag-pill": "",
- "data-tag-cat": e === "all" ? "all" : Xk(n, e),
+ "data-tag-cat": e === "all" ? "all" : fA(n, e),
pressed: t === e,
onPress: () => o(e),
- children: [/* @__PURE__ */ (0, z.jsx)(mF, {}), r]
+ children: [/* @__PURE__ */ (0, z.jsx)(hF, {}), r]
}, e)),
bottom: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsx)("span", {
@@ -45507,19 +45507,19 @@ function $me({ categories: e, category: t, online: n, readout: r, letters: i, vi
children: e
}, e))
}) : null,
- /* @__PURE__ */ (0, z.jsx)(E_, {
+ /* @__PURE__ */ (0, z.jsx)(D_, {
"aria-label": "标签视图",
orientation: "horizontal",
value: a,
onChange: (e) => c(e),
- className: `ml-auto ${nk}`,
- children: Qme.map(([e, t, n]) => {
+ className: `ml-auto ${JO}`,
+ children: Zme.map(([e, t, n]) => {
let r = Ob(n);
- return /* @__PURE__ */ (0, z.jsx)(D_, {
+ return /* @__PURE__ */ (0, z.jsx)(O_, {
value: e,
"aria-label": t,
"data-glass-segment": "",
- className: rk,
+ className: YO,
children: /* @__PURE__ */ (0, z.jsx)("span", {
title: t,
className: "contents",
@@ -45531,13 +45531,13 @@ function $me({ categories: e, category: t, online: n, readout: r, letters: i, vi
] })
});
}
-function ehe({ count: e, match: t, onMatch: n, onClear: r, onApply: i }) {
- return /* @__PURE__ */ (0, z.jsxs)(QP, {
+function $me({ count: e, match: t, onMatch: n, onClear: r, onApply: i }) {
+ return /* @__PURE__ */ (0, z.jsxs)($P, {
visible: e > 0,
label: "所选标签操作",
count: `已选 ${e} 个标签`,
children: [
- /* @__PURE__ */ (0, z.jsx)(SO, {
+ /* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: t === "any",
onChange: (e) => n(e ? "any" : "all"),
children: /* @__PURE__ */ (0, z.jsxs)("span", {
@@ -45569,7 +45569,7 @@ function ehe({ count: e, match: t, onMatch: n, onClear: r, onApply: i }) {
}
//#endregion
//#region src/react/index/index-page.tsx
-var the = [{
+var ehe = [{
value: "studios",
label: "厂牌",
symbol: "clapperboard"
@@ -45577,7 +45577,7 @@ var the = [{
value: "agencies",
label: "事务所",
symbol: "briefcase"
-}], hF = [{
+}], gF = [{
value: "local",
label: "本地",
symbol: "hard-drive"
@@ -45585,7 +45585,7 @@ var the = [{
value: "online",
label: "在线",
symbol: "rss"
-}], nhe = {
+}], the = {
people: [[
"big",
"大图 · 竖幅头像",
@@ -45605,20 +45605,20 @@ var the = [{
"layout-grid"
]]
};
-function rhe({ kind: e, layout: t, onChange: n }) {
- return /* @__PURE__ */ (0, z.jsx)($O, {
- "aria-label": `${zk[e]}索引版式`,
+function nhe({ kind: e, layout: t, onChange: n }) {
+ return /* @__PURE__ */ (0, z.jsx)(GO, {
+ "aria-label": `${Zk[e]}索引版式`,
orientation: "horizontal",
value: t,
onChange: (e) => n(e),
"data-index-layout": "",
- className: `flex-none max-board-narrow:order-3 ${ek}`,
- children: nhe[Wk(e) ? "company" : "people"].map(([e, t, n]) => {
+ className: `flex-none max-board-narrow:order-3 ${KO}`,
+ children: the[rA(e) ? "company" : "people"].map(([e, t, n]) => {
let r = Ob(n);
- return /* @__PURE__ */ (0, z.jsx)(D_, {
+ return /* @__PURE__ */ (0, z.jsx)(O_, {
value: e,
"aria-label": t,
- className: ele,
+ className: cle,
children: /* @__PURE__ */ (0, z.jsx)("span", {
title: t,
className: "contents",
@@ -45628,8 +45628,8 @@ function rhe({ kind: e, layout: t, onChange: n }) {
})
});
}
-var ihe = Ob("search");
-function ahe({ label: e, value: t, onQuery: n }) {
+var rhe = Ob("search");
+function ihe({ label: e, value: t, onQuery: n }) {
let [r, i] = (0, R.useState)(t), a = (0, R.useRef)(!1), o = (0, R.useRef)(void 0);
(0, R.useEffect)(() => () => clearTimeout(o.current), []);
let s = (e) => {
@@ -45644,15 +45644,15 @@ function ahe({ label: e, value: t, onQuery: n }) {
onCompositionEnd: (e) => {
a.current = !1, s(e.target.value);
},
- children: /* @__PURE__ */ (0, z.jsx)(ay, {
+ children: /* @__PURE__ */ (0, z.jsx)(uy, {
"aria-label": e,
value: r,
onChange: (e) => {
i(e), a.current || s(e);
},
- children: /* @__PURE__ */ (0, z.jsx)(sy, {
+ children: /* @__PURE__ */ (0, z.jsx)(fy, {
type: "search",
- leadingIcon: ihe,
+ leadingIcon: rhe,
spellCheck: !1,
autoComplete: "off",
onKeyDown: (e) => {
@@ -45662,14 +45662,14 @@ function ahe({ label: e, value: t, onQuery: n }) {
})
});
}
-function ohe(e) {
- let [t, n] = (0, R.useState)(() => Gk({
+function ahe(e) {
+ let [t, n] = (0, R.useState)(() => iA({
kind: e.kind,
q: e.q,
scope: e.scope,
view: e.view,
category: e.category
- })), [r, i] = (0, R.useState)(e.layout), [a, o] = (0, R.useState)(/* @__PURE__ */ new Set()), [s, c] = (0, R.useState)("any"), l = (0, R.useRef)(null), { kind: u, q: d, scope: f, view: p, category: h } = t, g = zk[u], _ = u === "tags" && f === "online", v = u === "performers" && f === "online";
+ })), [r, i] = (0, R.useState)(e.layout), [a, o] = (0, R.useState)(/* @__PURE__ */ new Set()), [s, c] = (0, R.useState)("any"), l = (0, R.useRef)(null), { kind: u, q: d, scope: f, view: p, category: h } = t, g = Zk[u], _ = u === "tags" && f === "online", v = u === "performers" && f === "online";
(0, R.useEffect)(() => {
e.selectMode || o(/* @__PURE__ */ new Set());
}, [e.selectMode]);
@@ -45679,7 +45679,7 @@ function ohe(e) {
...r
};
b(Object.keys(r).every((e) => e === "q")), n(a), e.route(a, { replace: i });
- }, S = Yk(Kk(t)), C = tr({
+ }, S = cA(aA(t)), C = tr({
queryKey: S.queryKey,
queryFn: ({ pageParam: e, signal: t }) => S.queryFn({
pageParam: e,
@@ -45688,21 +45688,21 @@ function ohe(e) {
initialPageParam: 0,
getNextPageParam: S.getNextPageParam,
placeholderData: y ? Zt : void 0
- }), w = Hle(C.data), T = !!C.hasNextPage && !C.isPlaceholderData, E = Ule(w.length, !!C.hasNextPage);
+ }), w = uA(C.data), T = !!C.hasNextPage && !C.isPlaceholderData, E = dA(w.length, !!C.hasNextPage);
(0, R.useLayoutEffect)(() => {
l.current && e.refitImages(l.current);
}, [r]);
let D = (0, R.useMemo)(() => u === "tags" ? w.map((t) => ({
...t,
label: e.tagLabel(t.k)
- })) : [], [w, u]), k = (0, R.useMemo)(() => u === "tags" && p === "alphabet" ? Kle(D, (t) => e.tagLabel(t)) : [], [
+ })) : [], [w, u]), k = (0, R.useMemo)(() => u === "tags" && p === "alphabet" ? hA(D, (t) => e.tagLabel(t)) : [], [
D,
p,
u
]), A = (t) => {
i(t), e.savePreference({ layout: t });
- }, j = u === "tags" ? /* @__PURE__ */ (0, z.jsx)(mk, {
- tabs: hF,
+ }, j = u === "tags" ? /* @__PURE__ */ (0, z.jsx)(ak, {
+ tabs: gF,
value: f,
label: "词表",
onChange: (e) => {
@@ -45712,15 +45712,15 @@ function ohe(e) {
view: e === "online" ? "alphabet" : p
});
}
- }) : u === "performers" ? /* @__PURE__ */ (0, z.jsx)(mk, {
- tabs: hF,
+ }) : u === "performers" ? /* @__PURE__ */ (0, z.jsx)(ak, {
+ tabs: gF,
value: f,
label: "名册",
onChange: (t) => {
t === "online" && e.exitSelectMode(), x({ scope: t });
}
- }) : Wk(u) ? /* @__PURE__ */ (0, z.jsx)(mk, {
- tabs: the,
+ }) : rA(u) ? /* @__PURE__ */ (0, z.jsx)(ak, {
+ tabs: ehe,
value: u,
label: "公司类型",
onChange: (e) => x({ kind: e })
@@ -45737,7 +45737,7 @@ function ohe(e) {
let n = new Set(e);
return n.delete(t) || n.add(t), n;
});
- }, N = (_ ? Vk : Bk).filter(([e]) => e === "all" || Number(C.data?.pages[0]?.categories?.[e] || 0) > 0);
+ }, N = (_ ? eA : $k).filter(([e]) => e === "all" || Number(C.data?.pages[0]?.categories?.[e] || 0) > 0);
return /* @__PURE__ */ (0, z.jsxs)("div", {
ref: l,
"data-index-page": u,
@@ -45752,12 +45752,12 @@ function ohe(e) {
className: "flex items-center text-display-4-medium whitespace-nowrap text-text-primary max-board-narrow:text-title-1-medium",
children: g
}),
- Uk(u) ? /* @__PURE__ */ (0, z.jsx)("span", {
+ nA(u) ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-index-count": "",
className: "text-caption-1-regular leading-5 whitespace-nowrap text-text-secondary tabular-nums",
children: C.isPending ? "" : E
}) : null,
- Uk(u) ? /* @__PURE__ */ (0, z.jsx)(rhe, {
+ nA(u) ? /* @__PURE__ */ (0, z.jsx)(nhe, {
kind: u,
layout: r,
onChange: A
@@ -45766,7 +45766,7 @@ function ohe(e) {
"aria-hidden": !0,
className: "hidden h-0 basis-full max-board-narrow:order-2 max-board-narrow:block"
}),
- /* @__PURE__ */ (0, z.jsx)(ahe, {
+ /* @__PURE__ */ (0, z.jsx)(ihe, {
label: `过滤${g}`,
value: d,
onQuery: (e) => {
@@ -45776,7 +45776,7 @@ function ohe(e) {
]
}),
j,
- u === "tags" ? /* @__PURE__ */ (0, z.jsx)($me, {
+ u === "tags" ? /* @__PURE__ */ (0, z.jsx)(Qme, {
categories: N,
category: h,
online: _,
@@ -45811,18 +45811,18 @@ function ohe(e) {
}),
children: m(C.error)
});
- if (!w.length) return /* @__PURE__ */ (0, z.jsx)(che, {
+ if (!w.length) return /* @__PURE__ */ (0, z.jsx)(she, {
kind: u,
filtered: !!d || u === "tags" && h !== "all",
online: _ || v,
configurable: e.configurable
});
- if (v) return /* @__PURE__ */ (0, z.jsx)(Jle, {
+ if (v) return /* @__PURE__ */ (0, z.jsx)(bA, {
items: w,
layout: r,
props: e
});
- if (Uk(u)) return /* @__PURE__ */ (0, z.jsx)($k, {
+ if (nA(u)) return /* @__PURE__ */ (0, z.jsx)(yA, {
kind: u,
items: w,
layout: r,
@@ -45833,10 +45833,10 @@ function ohe(e) {
picked: a,
press: M
};
- return p === "alphabet" ? /* @__PURE__ */ (0, z.jsx)(Yme, {
+ return p === "alphabet" ? /* @__PURE__ */ (0, z.jsx)(Jme, {
groups: k,
actions: t
- }) : /* @__PURE__ */ (0, z.jsx)(Zme, {
+ }) : /* @__PURE__ */ (0, z.jsx)(Xme, {
tags: D,
actions: t
});
@@ -45857,7 +45857,7 @@ function ohe(e) {
}) : "载入更多"
})
}) : null,
- u === "tags" && !_ && e.selectMode ? /* @__PURE__ */ (0, z.jsx)(ehe, {
+ u === "tags" && !_ && e.selectMode ? /* @__PURE__ */ (0, z.jsx)($me, {
count: a.size,
match: s,
onMatch: c,
@@ -45870,14 +45870,14 @@ function ohe(e) {
]
});
}
-var she = {
+var ohe = {
tags: "标签",
performers: "艺人",
creators: "创作者",
studios: "厂牌",
agencies: "事务所"
};
-function che({ kind: e, filtered: t, online: n, configurable: r }) {
+function she({ kind: e, filtered: t, online: n, configurable: r }) {
if (t) return /* @__PURE__ */ (0, z.jsx)($i, {
icon: Ob("search"),
title: "没有符合条件的内容",
@@ -45888,7 +45888,7 @@ function che({ kind: e, filtered: t, online: n, configurable: r }) {
}),
children: "清除筛选或搜索条件后查看全部内容。"
});
- let i = n && e === "performers" ? "创作者" : she[e], a = /* @__PURE__ */ (0, z.jsx)(Vi, {
+ let i = n && e === "performers" ? "创作者" : ohe[e], a = /* @__PURE__ */ (0, z.jsx)(Vi, {
variant: !r || n ? "primary" : "secondary",
href: "/follow-manage?tab=add",
children: "添加关注"
@@ -45904,15 +45904,15 @@ function che({ kind: e, filtered: t, online: n, configurable: r }) {
children: n ? `添加关注来源并获取内容后,这里会显示来源上的${i}。` : "添加内容并补充资料后,这里会显示对应信息。"
});
}
-var gF = {
+var _F = {
video: ["视频", "play"],
image: ["图片", "pics"],
archive: ["压缩包", "file-archive"],
audio: ["音频", "file-audio"],
url: ["网址快捷方式", "globe"],
other: ["其它文件", "hard-drive"]
-}, lhe = (e) => gF[e.junk_kind || "other"] || gF.other;
-function uhe(e) {
+}, che = (e) => _F[e.junk_kind || "other"] || _F.other;
+function lhe(e) {
return e === "dismissed" ? {
operation: "reconsider-junk",
label: "重新判断",
@@ -45923,21 +45923,21 @@ function uhe(e) {
glyph: "check"
};
}
-var _F = (e, t) => Number((t ? e.counts?.[t] : e.all_total) || 0), dhe = (e, t) => [
+var vF = (e, t) => Number((t ? e.counts?.[t] : e.all_total) || 0), uhe = (e, t) => [
"junk-queue",
e.view,
e.kind,
t
];
-function fhe({ kind: e, view: t }) {
+function dhe({ kind: e, view: t }) {
let n = new URLSearchParams({
limit: "200",
status: t
});
return e && n.set("kind", e), n.toString();
}
-async function phe(e, t) {
- let n = await W(`/api/ads?${fhe(e)}`, t);
+async function fhe(e, t) {
+ let n = await W(`/api/ads?${dhe(e)}`, t);
return {
...n,
items: n.items || []
@@ -45945,19 +45945,19 @@ async function phe(e, t) {
}
//#endregion
//#region src/react/junk-queue/junk-card.tsx
-function vF({ name: e }) {
+function yF({ name: e }) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
"aria-hidden": "true",
children: /* @__PURE__ */ (0, z.jsx)("use", { href: `#i-${e}` })
});
}
-var yF = (e, t) => e || t.shiftKey || t.ctrlKey || t.metaKey;
-function mhe({ item: e, view: t, selected: n, selectMode: r, helpers: a, actions: o }) {
- let c = (0, R.useRef)(null), [l, u] = (0, R.useState)(""), [d, f] = (0, R.useState)(""), p = e.junk_kind || "other", [m, h] = lhe(e), g = String(e.name || ""), _ = uhe(t), v = p === "video" ? `/thumb?id=${e.id}&c=4` : p === "image" ? `/photo-thumb?id=${e.id}` : "", y = p === "video" || p === "image", b = (t) => {
- t.target.closest("[data-junk-actions]") || yF(r, t) && (t.preventDefault(), o.toggleSelection(e.id, t.shiftKey));
+var bF = (e, t) => e || t.shiftKey || t.ctrlKey || t.metaKey;
+function phe({ item: e, view: t, selected: n, selectMode: r, helpers: a, actions: o }) {
+ let c = (0, R.useRef)(null), [l, u] = (0, R.useState)(""), [d, f] = (0, R.useState)(""), p = e.junk_kind || "other", [m, h] = che(e), g = String(e.name || ""), _ = lhe(t), v = p === "video" ? `/thumb?id=${e.id}&c=4` : p === "image" ? `/photo-thumb?id=${e.id}` : "", y = p === "video" || p === "image", b = (t) => {
+ t.target.closest("[data-junk-actions]") || bF(r, t) && (t.preventDefault(), o.toggleSelection(e.id, t.shiftKey));
}, x = (t) => {
- if (t.stopPropagation(), yF(r, t)) {
+ if (t.stopPropagation(), bF(r, t)) {
t.preventDefault(), o.toggleSelection(e.id, t.shiftKey);
return;
}
@@ -45999,7 +45999,7 @@ function mhe({ item: e, view: t, selected: n, selectMode: r, helpers: a, actions
children: [
/* @__PURE__ */ (0, z.jsxs)("span", {
"data-media-glyph": "",
- children: [/* @__PURE__ */ (0, z.jsx)(vF, { name: h }), /* @__PURE__ */ (0, z.jsx)("b", { children: m })]
+ children: [/* @__PURE__ */ (0, z.jsx)(yF, { name: h }), /* @__PURE__ */ (0, z.jsx)("b", { children: m })]
}),
v ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-media-art": "thumb",
@@ -46011,7 +46011,7 @@ function mhe({ item: e, view: t, selected: n, selectMode: r, helpers: a, actions
}),
/* @__PURE__ */ (0, z.jsx)("span", {
"data-media-check": "",
- children: /* @__PURE__ */ (0, z.jsx)(vF, { name: "check" })
+ children: /* @__PURE__ */ (0, z.jsx)(yF, { name: "check" })
})
]
}),
@@ -46048,7 +46048,7 @@ function mhe({ item: e, view: t, selected: n, selectMode: r, helpers: a, actions
children: [l === "reveal" ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-junk-spinner": "",
dangerouslySetInnerHTML: { __html: ie("正在定位") }
- }) : /* @__PURE__ */ (0, z.jsx)(vF, { name: "folder-open" }), /* @__PURE__ */ (0, z.jsx)("span", {
+ }) : /* @__PURE__ */ (0, z.jsx)(yF, { name: "folder-open" }), /* @__PURE__ */ (0, z.jsx)("span", {
"data-junk-label": "",
children: "打开位置"
})]
@@ -46060,7 +46060,7 @@ function mhe({ item: e, view: t, selected: n, selectMode: r, helpers: a, actions
"aria-label": _.label,
...w(_.operation),
onClick: C(_.operation),
- children: [/* @__PURE__ */ (0, z.jsx)(vF, { name: _.glyph }), /* @__PURE__ */ (0, z.jsx)("span", {
+ children: [/* @__PURE__ */ (0, z.jsx)(yF, { name: _.glyph }), /* @__PURE__ */ (0, z.jsx)("span", {
"data-junk-label": "",
children: _.label
})]
@@ -46072,7 +46072,7 @@ function mhe({ item: e, view: t, selected: n, selectMode: r, helpers: a, actions
"aria-label": "移入回收站",
...w("dispose"),
onClick: C("dispose"),
- children: [/* @__PURE__ */ (0, z.jsx)(vF, { name: "trash" }), /* @__PURE__ */ (0, z.jsx)("span", {
+ children: [/* @__PURE__ */ (0, z.jsx)(yF, { name: "trash" }), /* @__PURE__ */ (0, z.jsx)("span", {
"data-junk-label": "",
children: "移入回收站"
})]
@@ -46087,7 +46087,7 @@ function mhe({ item: e, view: t, selected: n, selectMode: r, helpers: a, actions
]
});
}
-var hhe = (0, R.memo)(mhe), bF = [
+var mhe = (0, R.memo)(phe), xF = [
[
"",
"全部",
@@ -46124,53 +46124,53 @@ var hhe = (0, R.memo)(mhe), bF = [
"hard-drive"
]
];
-function xF(e = "", t = "pending") {
+function SF(e = "", t = "pending") {
let n = new URLSearchParams();
e && n.set("type", e), t === "dismissed" && n.set("view", "dismissed");
let r = n.toString();
return `/junk-files${r ? `?${r}` : ""}`;
}
-function ghe(e) {
+function hhe(e) {
return e === "dismissed" ? {
view: "pending",
label: "返回待判断",
glyph: "rotate-ccw",
- href: xF("", "pending")
+ href: SF("", "pending")
} : {
view: "dismissed",
label: "已排除",
glyph: "eye-off",
- href: xF("", "dismissed")
+ href: SF("", "dismissed")
};
}
-var _he = (e) => e === "dismissed" ? "已排除" : "待判断";
+var ghe = (e) => e === "dismissed" ? "已排除" : "待判断";
//#endregion
//#region src/react/junk-queue/junk-count.tsx
-function SF({ name: e }) {
+function CF({ name: e }) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
"aria-hidden": "true",
children: /* @__PURE__ */ (0, z.jsx)("use", { href: `#i-${e}` })
});
}
-function CF({ scope: e, count: t }) {
+function wF({ scope: e, count: t }) {
return t ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [" ", /* @__PURE__ */ (0, z.jsx)("span", {
"data-count-badge": `junk:${e}`,
children: t.toLocaleString()
})] }) : null;
}
-function vhe({ route: e, page: t, failed: n, onNavigate: r }) {
- let i = uO(), a = (0, R.useRef)(null), { kind: o, view: s } = e, c = ZO(a, i, "[data-junk-kind-link][aria-current=\"page\"]", `${s}:${o}:${t ? bF.map(([e]) => _F(t, e)).join(",") : ""}`), l = ghe(s), u = (e) => {
+function _he({ route: e, page: t, failed: n, onNavigate: r }) {
+ let i = aO(), a = (0, R.useRef)(null), { kind: o, view: s } = e, c = UO(a, i, "[data-junk-kind-link][aria-current=\"page\"]", `${s}:${o}:${t ? xF.map(([e]) => vF(t, e)).join(",") : ""}`), l = hhe(s), u = (e) => {
let t = e.target.closest("a");
- !t || e.button !== 0 || e.metaKey || e.ctrlKey || e.shiftKey || e.altKey || (e.preventDefault(), r(t.getAttribute("href") || xF()));
+ !t || e.button !== 0 || e.metaKey || e.ctrlKey || e.shiftKey || e.altKey || (e.preventDefault(), r(t.getAttribute("href") || SF()));
}, d = t ? `${Number(t.total || 0).toLocaleString()} 个` : n ? "—" : "";
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-junk-count": "",
children: [/* @__PURE__ */ (0, z.jsx)("div", {
"data-junk-summary": "",
"aria-live": "polite",
- children: /* @__PURE__ */ (0, z.jsx)(BO, {
- label: _he(s),
+ children: /* @__PURE__ */ (0, z.jsx)(PO, {
+ label: ghe(s),
figure: d,
pending: !t && !n,
flush: !0
@@ -46190,17 +46190,17 @@ function vhe({ route: e, page: t, failed: n, onNavigate: r }) {
onClick: u,
onPointerLeave: c.leave,
children: [
- bF.map(([e, n, r]) => /* @__PURE__ */ (0, z.jsxs)("a", {
- href: xF(e, s),
+ xF.map(([e, n, r]) => /* @__PURE__ */ (0, z.jsxs)("a", {
+ href: SF(e, s),
"data-junk-kind-link": e,
"aria-current": e === o ? "page" : void 0,
onPointerEnter: c.hover,
children: [
- /* @__PURE__ */ (0, z.jsx)(SF, { name: r }),
+ /* @__PURE__ */ (0, z.jsx)(CF, { name: r }),
n,
- /* @__PURE__ */ (0, z.jsx)(CF, {
+ /* @__PURE__ */ (0, z.jsx)(wF, {
scope: e,
- count: t ? _F(t, e) : 0
+ count: t ? vF(t, e) : 0
})
]
}, e || "all")),
@@ -46214,9 +46214,9 @@ function vhe({ route: e, page: t, failed: n, onNavigate: r }) {
"aria-current": s === "dismissed" ? "page" : void 0,
onPointerEnter: s === "dismissed" ? void 0 : c.hover,
children: [
- /* @__PURE__ */ (0, z.jsx)(SF, { name: l.glyph }),
+ /* @__PURE__ */ (0, z.jsx)(CF, { name: l.glyph }),
l.label,
- /* @__PURE__ */ (0, z.jsx)(CF, {
+ /* @__PURE__ */ (0, z.jsx)(wF, {
scope: "dismissed",
count: Number(t?.dismissed_total || 0)
})
@@ -46229,38 +46229,38 @@ function vhe({ route: e, page: t, failed: n, onNavigate: r }) {
}
//#endregion
//#region src/react/junk-queue/junk-queue-page.tsx
-var yhe = Ob("check"), bhe = (e, t) => e[1] === t.view && e[2] === t.kind;
-function xhe(e) {
+var vhe = Ob("check"), yhe = (e, t) => e[1] === t.view && e[2] === t.kind;
+function bhe(e) {
let t = {
kind: e.kind,
view: e.view
}, n = (0, R.useRef)(e.cache);
n.current = e.cache;
let r = $n({
- queryKey: dhe(t, e.revision),
+ queryKey: uhe(t, e.revision),
queryFn: async ({ signal: e }) => {
- let r = await phe(t, e);
+ let r = await fhe(t, e);
return n.current(r.items), r;
},
- placeholderData: (e, n) => n && bhe(n.queryKey, t) ? e : void 0
+ placeholderData: (e, n) => n && yhe(n.queryKey, t) ? e : void 0
});
(0, R.useEffect)(() => {
r.isFetching || e.settled?.(e.revision);
}, [r.isFetching, e.revision]);
- let i = She(e.countRow), a = r.isPending;
+ let i = xhe(e.countRow), a = r.isPending;
(0, R.useLayoutEffect)(() => {
let t = e.countRow;
t && (a ? t.setAttribute("aria-busy", "true") : t.removeAttribute("aria-busy"));
}, [e.countRow, a]), (0, R.useLayoutEffect)(() => {
i && r.data && M(i, "junk");
}, [i, r.data]);
- let { navigate: o } = e.actions, s = i ? (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(vhe, {
+ let { navigate: o } = e.actions, s = i ? (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)(_he, {
route: t,
page: r.data,
failed: r.isError && !r.data,
onNavigate: o
}), i) : null;
- return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [s, /* @__PURE__ */ (0, z.jsx)(Che, {
+ return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [s, /* @__PURE__ */ (0, z.jsx)(She, {
props: e,
data: r.data,
pending: a,
@@ -46268,7 +46268,7 @@ function xhe(e) {
retry: () => void r.refetch()
}, `${t.view}:${t.kind}`)] });
}
-function She(e) {
+function xhe(e) {
let [t, n] = (0, R.useState)(null);
return (0, R.useLayoutEffect)(() => {
if (!e) return;
@@ -46278,8 +46278,8 @@ function She(e) {
};
}, [e]), t;
}
-function Che({ props: e, data: t, pending: n, error: r, retry: i }) {
- let a = _b(n, e.skeletonHtml), o = Math.max(1, e.batchSize || 60), [s, c] = (0, R.useState)(1), l = t?.items || [], u = l.slice(0, s * o), { canLoadMore: d } = e, f = (0, R.useCallback)(() => {
+function She({ props: e, data: t, pending: n, error: r, retry: i }) {
+ let a = ob(n, e.skeletonHtml), o = Math.max(1, e.batchSize || 60), [s, c] = (0, R.useState)(1), l = t?.items || [], u = l.slice(0, s * o), { canLoadMore: d } = e, f = (0, R.useCallback)(() => {
d?.() !== !1 && c((e) => e + 1);
}, [d]);
return /* @__PURE__ */ (0, z.jsxs)("div", {
@@ -46287,14 +46287,14 @@ function Che({ props: e, data: t, pending: n, error: r, retry: i }) {
"data-grid-reveal": a.fading ? "" : void 0,
children: [a.layer, (() => {
if (n) return null;
- if (!t) return /* @__PURE__ */ (0, z.jsx)(vb, {
+ if (!t) return /* @__PURE__ */ (0, z.jsx)(sb, {
message: m(r),
onRetry: i
});
if (!l.length) {
let t = e.view === "dismissed";
return /* @__PURE__ */ (0, z.jsx)($i, {
- icon: yhe,
+ icon: vhe,
title: t ? "没有已排除的文件" : "没有待判断的垃圾文件",
children: t ? "点“不是垃圾”的资源会保留在这里,可随时重新判断。" : "当前分类没有候选文件。"
});
@@ -46303,7 +46303,7 @@ function Che({ props: e, data: t, pending: n, error: r, retry: i }) {
"data-media-grid": "",
"data-junk-grid": "",
"data-select-mode": e.selectMode ? "" : void 0,
- children: u.map((t) => /* @__PURE__ */ (0, z.jsx)(hhe, {
+ children: u.map((t) => /* @__PURE__ */ (0, z.jsx)(mhe, {
item: t,
view: e.view,
selected: e.selected.has(t.id),
@@ -46311,11 +46311,11 @@ function Che({ props: e, data: t, pending: n, error: r, retry: i }) {
helpers: e.helpers,
actions: e.actions
}, t.id))
- }), u.length < l.length ? /* @__PURE__ */ (0, z.jsx)(whe, { onMore: f }, s) : null] });
+ }), u.length < l.length ? /* @__PURE__ */ (0, z.jsx)(Che, { onMore: f }, s) : null] });
})()]
});
}
-function whe({ onMore: e }) {
+function Che({ onMore: e }) {
let t = (0, R.useRef)(null);
return (0, R.useEffect)(() => {
let n = t.current;
@@ -46333,12 +46333,12 @@ function whe({ onMore: e }) {
}
//#endregion
//#region src/react/library-processing/library-processing-notice.tsx
-var wF = "flex min-h-10 flex-wrap items-center justify-center gap-x-4 gap-y-2 border-y px-6 py-2 max-sm:justify-start", The = {
- gray: `${wF} border-separator-border bg-background-secondary-default text-text-secondary`,
- warning: `${wF} border-current/35 bg-status-yellow-background text-status-yellow-text`,
- error: `${wF} border-current/35 bg-background-tertiary-error text-text-error-primary`
+var TF = "flex min-h-10 flex-wrap items-center justify-center gap-x-4 gap-y-2 border-y px-6 py-2 max-sm:justify-start", whe = {
+ gray: `${TF} border-separator-border bg-background-secondary-default text-text-secondary`,
+ warning: `${TF} border-current/35 bg-status-yellow-background text-status-yellow-text`,
+ error: `${TF} border-current/35 bg-background-tertiary-error text-text-error-primary`
};
-function Ehe({ value: e, max: t }) {
+function The({ value: e, max: t }) {
let n = Math.max(0, Math.min(100, e / t * 100));
return /* @__PURE__ */ (0, z.jsxs)("svg", {
role: "progressbar",
@@ -46366,16 +46366,16 @@ function Ehe({ value: e, max: t }) {
})]
});
}
-function Dhe(e) {
- let { job: t } = hO(e), n = t.data, r = t.isError ? n ? Yb : U(t.error) : "", i = n?.status ?? "idle", a = i === "failed", o = i === "running";
+function Ehe(e) {
+ let { job: t } = uO(e), n = t.data, r = t.isError ? n ? ex : U(t.error) : "", i = n?.status ?? "idle", a = i === "failed", o = i === "running";
if (!r && !o && !a) return null;
- let s = a ? "error" : r || n?.stalled ? "warning" : "gray", c = n?.checked || 0, l = n?.total || 0, u = r || (a ? "扫描与资料采集未完成" : Zb(n) + (l ? ` · ${c} / ${l}` : "")), d = s === "gray" ? lt : et;
+ let s = a ? "error" : r || n?.stalled ? "warning" : "gray", c = n?.checked || 0, l = n?.total || 0, u = r || (a ? "扫描与资料采集未完成" : nx(n) + (l ? ` · ${c} / ${l}` : "")), d = s === "gray" ? lt : et;
return /* @__PURE__ */ (0, z.jsxs)("aside", {
role: a ? "alert" : "status",
- className: The[s],
+ className: whe[s],
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-w-0 items-center gap-3",
- children: [o && l ? /* @__PURE__ */ (0, z.jsx)(Ehe, {
+ children: [o && l ? /* @__PURE__ */ (0, z.jsx)(The, {
value: c,
max: l
}) : /* @__PURE__ */ (0, z.jsx)(d, {
@@ -46385,7 +46385,7 @@ function Dhe(e) {
className: "min-w-0 text-body-2-regular",
children: u
})]
- }), /* @__PURE__ */ (0, z.jsx)(yy, {
+ }), /* @__PURE__ */ (0, z.jsx)(wy, {
href: "/data-cleanup#libraryProcessing",
size: "small",
trailingIcon: We,
@@ -46395,32 +46395,32 @@ function Dhe(e) {
}
//#endregion
//#region src/react/playlists/playlists.ts
-var Ohe = "/api/playlists", TF = "/api/playlist", EF = ["playlists"], DF = (e) => W(Ohe, e);
-async function khe(e) {
+var Dhe = "/api/playlists", EF = "/api/playlist", DF = ["playlists"], OF = (e) => W(Dhe, e);
+async function Ohe(e) {
await X.fetchQuery({
- queryKey: EF,
- queryFn: () => DF(e),
+ queryKey: DF,
+ queryFn: () => OF(e),
staleTime: 0
});
}
-var OF = () => X.invalidateQueries({
- queryKey: EF,
+var kF = () => X.invalidateQueries({
+ queryKey: DF,
exact: !0
-}), Ahe = (e) => e.current_asset_id || e.preview_asset_id || null, kF = (e) => `/poster?id=${e}&c=4`, jhe = (e) => G(TF, {
+}), khe = (e) => e.current_asset_id || e.preview_asset_id || null, AF = (e) => `/poster?id=${e}&c=4`, Ahe = (e) => G(EF, {
action: "create",
name: e,
asset_ids: []
-}), AF = (e, t) => G(TF, {
+}), jF = (e, t) => G(EF, {
action: "rename",
id: e,
name: t
-}), jF = (e) => G(TF, {
+}), MF = (e) => G(EF, {
action: "delete",
id: e
-}), Mhe = (e) => W(`${TF}?id=${e}`).catch(() => null);
-function Nhe(e) {
+}), jhe = (e) => W(`${EF}?id=${e}`).catch(() => null);
+function Mhe(e) {
let t = (e.items || []).map((e) => e.id), n = e.source_seed_asset_id;
- return G(TF, {
+ return G(EF, {
action: "create",
name: e.name,
asset_ids: t,
@@ -46430,18 +46430,18 @@ function Nhe(e) {
}
//#endregion
//#region src/react/playlists/playlists-page.tsx
-var Phe = Ob("ellipsis"), Fhe = Ob("pencil"), Ihe = Ob("trash"), Lhe = Ob("playlist"), MF = Ii(uy, dy, "text-body-2-medium"), NF = "播放列表名称不能为空", PF = (e) => async () => {
+var Nhe = Ob("ellipsis"), Phe = Ob("pencil"), Fhe = Ob("trash"), Ihe = Ob("playlist"), NF = Ii(hy, gy, "text-body-2-medium"), PF = "播放列表名称不能为空", FF = (e) => async () => {
try {
await e();
} finally {
- OF();
+ kF();
}
};
-function Rhe({ toast: e }) {
+function Lhe({ toast: e }) {
let [t, n] = (0, R.useState)(""), [r, i] = (0, R.useState)(""), a = er({
- mutationFn: (e) => jhe(e),
+ mutationFn: (e) => Ahe(e),
onSuccess: (t) => {
- n(""), i(""), OF(), e("已新建播放列表", { undo: PF(() => jF(t.playlist.id)) });
+ n(""), i(""), kF(), e("已新建播放列表", { undo: FF(() => MF(t.playlist.id)) });
},
onError: (e) => i(U(e) || "新建失败")
});
@@ -46451,7 +46451,7 @@ function Rhe({ toast: e }) {
onSubmit: (e) => {
if (e.preventDefault(), !a.isPending) {
if (!t.trim()) {
- i(NF);
+ i(PF);
return;
}
a.mutate(t);
@@ -46460,7 +46460,7 @@ function Rhe({ toast: e }) {
className: "flex flex-wrap items-end gap-2",
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "min-w-50 max-w-80 flex-1 basis-50 max-board-narrow:min-w-0 max-board-narrow:max-w-none",
- children: /* @__PURE__ */ (0, z.jsx)(cy, {
+ children: /* @__PURE__ */ (0, z.jsx)(py, {
label: "新播放列表",
placeholder: "输入名称",
maxLength: 80,
@@ -46479,7 +46479,7 @@ function Rhe({ toast: e }) {
})]
});
}
-function zhe({ target: e, close: t, toast: n }) {
+function Rhe({ target: e, close: t, toast: n }) {
let [r, i] = (0, R.useState)(""), [a, o] = (0, R.useState)(""), s = (0, R.useRef)(null);
(0, R.useEffect)(() => {
if (!e) return;
@@ -46490,13 +46490,13 @@ function zhe({ target: e, close: t, toast: n }) {
return () => cancelAnimationFrame(t);
}, [e]);
let c = er({
- mutationFn: ({ row: e, value: t }) => AF(e.id, t),
+ mutationFn: ({ row: e, value: t }) => jF(e.id, t),
onSuccess: (e, { row: r }) => {
- t(), OF(), n("已重命名播放列表", { undo: PF(() => AF(r.id, r.name)) });
+ t(), kF(), n("已重命名播放列表", { undo: FF(() => jF(r.id, r.name)) });
},
onError: (e) => o(U(e))
});
- return /* @__PURE__ */ (0, z.jsx)(EA, {
+ return /* @__PURE__ */ (0, z.jsx)(tj, {
isOpen: !!e,
onOpenChange: (e) => {
e || t();
@@ -46508,7 +46508,7 @@ function zhe({ target: e, close: t, toast: n }) {
if (t.preventDefault(), !e || c.isPending) return;
let n = r.trim();
if (!n) {
- o(NF);
+ o(PF);
return;
}
c.mutate({
@@ -46523,7 +46523,7 @@ function zhe({ target: e, close: t, toast: n }) {
slot: "title",
className: "text-title-2-semibold text-text-primary",
children: "编辑名称"
- }), /* @__PURE__ */ (0, z.jsx)(cy, {
+ }), /* @__PURE__ */ (0, z.jsx)(py, {
ref: s,
label: "名称",
placeholder: "输入名称",
@@ -46551,7 +46551,7 @@ function zhe({ target: e, close: t, toast: n }) {
})
});
}
-function Bhe({ name: e, onRename: t, onDelete: n }) {
+function zhe({ name: e, onRename: t, onDelete: n }) {
let r = (0, R.useRef)(null), [i, a] = (0, R.useState)(!1), o = (e) => {
a(!1), e();
};
@@ -46565,7 +46565,7 @@ function Bhe({ name: e, onRename: t, onDelete: n }) {
"data-playlist-menu": "",
onClick: () => a(!0),
className: "flex size-7.5 flex-none cursor-pointer items-center justify-center rounded-2lg text-foreground-icon-secondary outline-none transition-colors hover:bg-background-primary-hover hover:text-foreground-icon-primary aria-expanded:bg-background-primary-hover aria-expanded:text-foreground-icon-primary focus-visible:ring-2 focus-visible:ring-border-focus-ring",
- children: /* @__PURE__ */ (0, z.jsx)(Phe, {
+ children: /* @__PURE__ */ (0, z.jsx)(Nhe, {
"aria-hidden": !0,
className: "size-4.5"
})
@@ -46575,23 +46575,23 @@ function Bhe({ name: e, onRename: t, onDelete: n }) {
onOpenChange: a,
placement: "bottom end",
offset: 4,
- className: ly,
- children: /* @__PURE__ */ (0, z.jsxs)(iO, {
+ className: my,
+ children: /* @__PURE__ */ (0, z.jsxs)($D, {
"aria-label": `播放列表操作:${e}`,
className: "flex w-37.5 flex-col gap-0.5 outline-none",
children: [/* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
- className: MF,
+ className: NF,
onClick: () => o(t),
- children: [/* @__PURE__ */ (0, z.jsx)(Fhe, {
+ children: [/* @__PURE__ */ (0, z.jsx)(Phe, {
"aria-hidden": !0,
className: "size-4 shrink-0"
}), "编辑名称"]
}), /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
- className: MF,
+ className: NF,
onClick: () => o(n),
- children: [/* @__PURE__ */ (0, z.jsx)(Ihe, {
+ children: [/* @__PURE__ */ (0, z.jsx)(Fhe, {
"aria-hidden": !0,
className: "size-4 shrink-0"
}), "删除播放列表"]
@@ -46599,13 +46599,13 @@ function Bhe({ name: e, onRename: t, onDelete: n }) {
})
})] });
}
-function Vhe({ openPlaylist: e, openEntity: t, faceAvatar: n, canFlip: r, toast: i, revision: a }) {
+function Bhe({ openPlaylist: e, openEntity: t, faceAvatar: n, canFlip: r, toast: i, revision: a }) {
let o = $n({
- queryKey: EF,
- queryFn: ({ signal: e }) => DF(e)
+ queryKey: DF,
+ queryFn: ({ signal: e }) => OF(e)
}), [s, c] = (0, R.useState)(null), l = (0, R.useRef)(a);
(0, R.useEffect)(() => {
- l.current !== a && (l.current = a, OF());
+ l.current !== a && (l.current = a, kF());
}, [a]);
let u = o.data;
if (!u) return /* @__PURE__ */ (0, z.jsx)("div", {
@@ -46623,8 +46623,8 @@ function Vhe({ openPlaylist: e, openEntity: t, faceAvatar: n, canFlip: r, toast:
confirmLabel: "删除播放列表",
danger: !0,
onConfirm: async () => {
- let t = await Mhe(e.id);
- await jF(e.id), OF(), i("已删除播放列表", t ? { undo: PF(() => Nhe(t)) } : void 0);
+ let t = await jhe(e.id);
+ await MF(e.id), kF(), i("已删除播放列表", t ? { undo: FF(() => Mhe(t)) } : void 0);
}
});
};
@@ -46639,27 +46639,27 @@ function Vhe({ openPlaylist: e, openEntity: t, faceAvatar: n, canFlip: r, toast:
}), /* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
children: "保存 Mix,按自己的顺序继续播放。"
- })] }), /* @__PURE__ */ (0, z.jsx)(Rhe, { toast: i })]
+ })] }), /* @__PURE__ */ (0, z.jsx)(Lhe, { toast: i })]
}),
d.length ? /* @__PURE__ */ (0, z.jsx)("div", {
"data-playlist-grid": "",
className: "card-grid-cover gap-4.5",
children: d.map((i) => {
- let a = Ahe(i);
- return /* @__PURE__ */ (0, z.jsx)(Mb, {
+ let a = khe(i);
+ return /* @__PURE__ */ (0, z.jsx)(Lb, {
"data-playlist-card": String(i.id),
name: i.name,
caption: i.source_kind === "mix" ? "由 Mix 保存" : "手动播放列表",
count: i.item_count,
- poster: i.preview_asset_id ? kF(i.preview_asset_id) : null,
- flipImages: async () => (i.preview_ids || []).map(kF),
+ poster: i.preview_asset_id ? AF(i.preview_asset_id) : null,
+ flipImages: async () => (i.preview_ids || []).map(AF),
canFlip: r,
faces: i.faces || [],
faceAvatar: n,
onOpenEntity: t,
...a ? { onOpen: () => e(i.id, a) } : {},
openLabel: `打开播放列表 ${i.name}`,
- menu: /* @__PURE__ */ (0, z.jsx)(Bhe, {
+ menu: /* @__PURE__ */ (0, z.jsx)(zhe, {
name: i.name,
onRename: () => c(i),
onDelete: () => f(i)
@@ -46667,11 +46667,11 @@ function Vhe({ openPlaylist: e, openEntity: t, faceAvatar: n, canFlip: r, toast:
}, i.id);
})
}) : /* @__PURE__ */ (0, z.jsx)($i, {
- icon: Lhe,
+ icon: Ihe,
title: "还没有播放列表",
children: "保存 Mix 或新建列表后,会在这里按自己的顺序继续播放。"
}),
- /* @__PURE__ */ (0, z.jsx)(zhe, {
+ /* @__PURE__ */ (0, z.jsx)(Rhe, {
target: s,
close: () => c(null),
toast: i
@@ -46681,7 +46681,7 @@ function Vhe({ openPlaylist: e, openEntity: t, faceAvatar: n, canFlip: r, toast:
}
//#endregion
//#region src/react/quality-goals/quality-goals-page.tsx
-function Hhe({ item: t, openItem: n, javTitleHtml: r, javDisplayName: i, srcBadge: a }) {
+function Vhe({ item: t, openItem: n, javTitleHtml: r, javDisplayName: i, srcBadge: a }) {
let c = () => n(t.id);
return /* @__PURE__ */ (0, z.jsxs)("li", {
"data-goal-id": t.id,
@@ -46701,7 +46701,7 @@ function Hhe({ item: t, openItem: n, javTitleHtml: r, javDisplayName: i, srcBadg
className: "text-caption-1-regular text-text-secondary",
children: "暂无预览"
}), /* @__PURE__ */ (0, z.jsx)("img", {
- src: Sre(t),
+ src: _re(t),
alt: "",
loading: "lazy",
onError: (e) => e.currentTarget.remove(),
@@ -46749,10 +46749,10 @@ function Hhe({ item: t, openItem: n, javTitleHtml: r, javDisplayName: i, srcBadg
})]
});
}
-function Uhe(e) {
+function Hhe(e) {
let t = $n({
- queryKey: ax,
- queryFn: ({ signal: e }) => ox(e)
+ queryKey: ux,
+ queryFn: ({ signal: e }) => dx(e)
}), n = t.data;
if (!n) return /* @__PURE__ */ (0, z.jsx)(ta, { children: /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
@@ -46760,13 +46760,13 @@ function Uhe(e) {
children: t.error ? U(t.error) : "未取得高清版目标,请刷新页面重试。"
}) });
let r = n.items || [];
- return r.length ? /* @__PURE__ */ (0, z.jsxs)(ta, { children: [/* @__PURE__ */ (0, z.jsx)(BO, {
+ return r.length ? /* @__PURE__ */ (0, z.jsxs)(ta, { children: [/* @__PURE__ */ (0, z.jsx)(PO, {
label: "待升级",
figure: `${n.total} 部作品`,
flush: !0
}), /* @__PURE__ */ (0, z.jsx)("ul", {
className: "card-grid-cover gap-5",
- children: r.map((t) => /* @__PURE__ */ (0, z.jsx)(Hhe, {
+ children: r.map((t) => /* @__PURE__ */ (0, z.jsx)(Vhe, {
item: t,
...e
}, t.id))
@@ -46779,17 +46779,17 @@ function Uhe(e) {
}
//#endregion
//#region src/react/providers.tsx
-var FF = null;
-function Whe() {
- return FF?.isConnected || (FF = document.createElement("div"), FF.className = "peach-react", FF.dataset.reactOverlays = "", document.body.append(FF)), FF;
+var IF = null;
+function Uhe() {
+ return IF?.isConnected || (IF = document.createElement("div"), IF.className = "peach-react", IF.dataset.reactOverlays = "", document.body.append(IF)), IF;
}
-function IF({ children: e }) {
+function LF({ children: e }) {
return /* @__PURE__ */ (0, z.jsx)(Ot, {
client: X,
- children: /* @__PURE__ */ (0, z.jsx)(upe, {
+ children: /* @__PURE__ */ (0, z.jsx)(lpe, {
reducedMotion: "user",
children: /* @__PURE__ */ (0, z.jsx)(Oh, {
- getContainer: Whe,
+ getContainer: Uhe,
children: e
})
})
@@ -46797,8 +46797,8 @@ function IF({ children: e }) {
}
//#endregion
//#region src/react/review/bulk-toolbar.tsx
-function Ghe(e) {
- let { groupOptions: t, groupBy: n, onGroupBy: r, groups: i, filter: a, onFilter: o, pageKeys: s, selected: c, onSelected: l, selectedRows: u, metadata: d, approvable: f, busy: p, feedback: m, onUnifySource: h, onRun: g } = e, _ = s.filter((e) => c.has(e)), v = _.length > 0 && _.length === s.length, y = Nre(u), b = d && u.some((e) => (e.candidates?.length || 0) > 1), x = y.length ? "统一选择来源" : "所选项目无共同来源";
+function Whe(e) {
+ let { groupOptions: t, groupBy: n, onGroupBy: r, groups: i, filter: a, onFilter: o, pageKeys: s, selected: c, onSelected: l, selectedRows: u, metadata: d, approvable: f, busy: p, feedback: m, onUnifySource: h, onRun: g } = e, _ = s.filter((e) => c.has(e)), v = _.length > 0 && _.length === s.length, y = Ore(u), b = d && u.some((e) => (e.candidates?.length || 0) > 1), x = y.length ? "统一选择来源" : "所选项目无共同来源";
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsxs)("div", {
role: "group",
"aria-label": "复核筛选",
@@ -46806,29 +46806,29 @@ function Ghe(e) {
"data-glass-pane": "",
className: "sticky top-topbar z-10 flex flex-wrap items-center gap-2 p-3",
children: [
- /* @__PURE__ */ (0, z.jsx)(py, {
+ /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "筛选分组方式",
size: "sm",
selectedKey: n,
onSelectionChange: (e) => {
e !== null && r(String(e));
},
- children: t.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: t.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e,
children: t
}, e))
}),
- i.length > 1 ? /* @__PURE__ */ (0, z.jsxs)(py, {
+ i.length > 1 ? /* @__PURE__ */ (0, z.jsxs)(vy, {
"aria-label": n === "field" ? "筛选字段分类" : "筛选当前分类",
size: "sm",
selectedKey: a || "*",
onSelectionChange: (e) => {
e !== null && o(String(e) === "*" ? "" : String(e));
},
- children: [/* @__PURE__ */ (0, z.jsx)(my, {
+ children: [/* @__PURE__ */ (0, z.jsx)(yy, {
id: "*",
children: "全部分类"
- }), i.map((e) => /* @__PURE__ */ (0, z.jsx)(my, {
+ }), i.map((e) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e.key,
children: `${e.title} · ${e.rows.length}`
}, e.key))]
@@ -46847,12 +46847,12 @@ function Ghe(e) {
children: v ? "清空当前选择" : a ? "全选当前分类" : "全选本页"
})
]
- }), /* @__PURE__ */ (0, z.jsxs)(QP, {
+ }), /* @__PURE__ */ (0, z.jsxs)($P, {
label: "复核所选项目",
visible: c.size > 0,
count: `已选 ${c.size} 项`,
children: [
- b ? /* @__PURE__ */ (0, z.jsxs)(py, {
+ b ? /* @__PURE__ */ (0, z.jsxs)(vy, {
"aria-label": "统一选择来源",
size: "sm",
selectedKey: "",
@@ -46860,10 +46860,10 @@ function Ghe(e) {
onSelectionChange: (e) => {
e !== null && e !== "" && h(String(e));
},
- children: [/* @__PURE__ */ (0, z.jsx)(my, {
+ children: [/* @__PURE__ */ (0, z.jsx)(yy, {
id: "",
children: x
- }), y.map((e) => /* @__PURE__ */ (0, z.jsx)(my, {
+ }), y.map((e) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e,
children: e
}, e))]
@@ -46899,7 +46899,7 @@ function Ghe(e) {
}
//#endregion
//#region src/react/review/candidate-form.tsx
-var Khe = {
+var Ghe = {
title: "标题",
original_title: "原标题",
runtime: "来源时长",
@@ -46909,14 +46909,14 @@ var Khe = {
cover_url: "封面",
screenshot_urls: "截图",
trailer_url: "预告片"
-}, LF = "reviewgenretags";
-function qhe({ tags: e }) {
+}, RF = "reviewgenretags";
+function Khe({ tags: e }) {
return e.length ? /* @__PURE__ */ (0, z.jsx)("datalist", {
- id: LF,
+ id: RF,
children: e.map((e) => /* @__PURE__ */ (0, z.jsx)("option", { value: e }, e))
}) : null;
}
-function RF({ candidate: e, selectable: t = !1 }) {
+function zF({ candidate: e, selectable: t = !1 }) {
let n = Object.entries(e.catalog_evidence || {}).filter(([, e]) => e && e.display_value), r = e.content_id || e.provider_id;
return /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 flex-1 flex-col",
@@ -46953,7 +46953,7 @@ function RF({ candidate: e, selectable: t = !1 }) {
children: [
/* @__PURE__ */ (0, z.jsx)("dt", {
className: "text-body-2-regular text-text-secondary",
- children: Khe[e] || e
+ children: Ghe[e] || e
}),
/* @__PURE__ */ (0, z.jsx)("dd", {
className: "min-w-0 text-body-2-regular break-words text-text-primary",
@@ -46968,36 +46968,36 @@ function RF({ candidate: e, selectable: t = !1 }) {
}) : null]
});
}
-function Jhe({ row: e, fieldName: t, value: n, onChange: r, locked: i }) {
+function qhe({ row: e, fieldName: t, value: n, onChange: r, locked: i }) {
let a = e.candidates || [];
return a.length ? a.length === 1 ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "flex overflow-hidden rounded-surface border border-separator-border bg-background-secondary-default",
- children: /* @__PURE__ */ (0, z.jsx)(RF, { candidate: a[0] })
- }) : /* @__PURE__ */ (0, z.jsx)(E_, {
+ children: /* @__PURE__ */ (0, z.jsx)(zF, { candidate: a[0] })
+ }) : /* @__PURE__ */ (0, z.jsx)(D_, {
"aria-label": `${t || "候选"}的来源`,
value: n,
isDisabled: i,
onChange: r,
className: "flex flex-col gap-2",
- children: a.map((e) => /* @__PURE__ */ (0, z.jsx)(D_, {
+ children: a.map((e) => /* @__PURE__ */ (0, z.jsx)(O_, {
value: e.candidate_key,
className: "group flex cursor-pointer items-center gap-2 overflow-hidden rounded-surface border border-separator-border bg-background-secondary-default outline-none focus-visible:ring-2 focus-visible:ring-border-focus-ring data-selected:border-border-button-active data-disabled:cursor-not-allowed",
- children: /* @__PURE__ */ (0, z.jsx)(RF, {
+ children: /* @__PURE__ */ (0, z.jsx)(zF, {
candidate: e,
selectable: !0
})
}, e.candidate_key))
}) : null;
}
-function Yhe({ genre: e, tags: t, locked: n, toast: r }) {
+function Jhe({ genre: e, tags: t, locked: n, toast: r }) {
let [i, a] = (0, R.useState)(""), [o, s] = (0, R.useState)(""), c = er({
- mutationFn: (t) => Vre(e, t),
+ mutationFn: (t) => Ire(e, t),
onSuccess: async (t, n) => {
if (!t.ok) {
s(t.error || "服务端拒绝了这次收录");
return;
}
- r(n ? `已把「${e}」收录为标签「${n}」` : `已把「${e}」判为非内容标签`), await Ure();
+ r(n ? `已把「${e}」收录为标签「${n}」` : `已把「${e}」判为非内容标签`), await Rre();
},
onError: (e) => s(U(e))
}), l = () => {
@@ -47016,16 +47016,16 @@ function Yhe({ genre: e, tags: t, locked: n, toast: r }) {
className: "text-body-medium text-text-primary",
children: e
}),
- /* @__PURE__ */ (0, z.jsx)(ay, {
+ /* @__PURE__ */ (0, z.jsx)(uy, {
"aria-label": `「${e}」收录成的中文标签`,
value: i,
onChange: a,
maxLength: 40,
isDisabled: n || c.isPending,
className: "min-w-40 flex-1",
- children: /* @__PURE__ */ (0, z.jsx)(sy, {
+ children: /* @__PURE__ */ (0, z.jsx)(fy, {
size: "small",
- list: t.length ? LF : void 0,
+ list: t.length ? RF : void 0,
autoComplete: "off",
placeholder: "中文标签",
onKeyDown: (e) => {
@@ -47057,8 +47057,8 @@ function Yhe({ genre: e, tags: t, locked: n, toast: r }) {
]
});
}
-function Xhe({ row: e, tags: t, locked: n, toast: r }) {
- let i = Rre(e);
+function Yhe({ row: e, tags: t, locked: n, toast: r }) {
+ let i = Nre(e);
return i.length ? /* @__PURE__ */ (0, z.jsxs)("div", {
role: "group",
"aria-label": "未收录 genre",
@@ -47066,7 +47066,7 @@ function Xhe({ row: e, tags: t, locked: n, toast: r }) {
children: [/* @__PURE__ */ (0, z.jsx)("h5", {
className: "text-body-2-medium text-text-secondary",
children: `未收录 genre · ${i.length}`
- }), i.map((e) => /* @__PURE__ */ (0, z.jsx)(Yhe, {
+ }), i.map((e) => /* @__PURE__ */ (0, z.jsx)(Jhe, {
genre: e,
tags: t,
locked: n,
@@ -47076,9 +47076,9 @@ function Xhe({ row: e, tags: t, locked: n, toast: r }) {
}
//#endregion
//#region src/react/review/review-evidence.tsx
-var zF = (e = "") => /^https?:\/\//i.test(e) ? e : "", Zhe = (e = "") => zF(e) || (e.startsWith("/") && !e.startsWith("//") ? e : "");
-function BF({ url: e }) {
- let t = Zhe(e || ""), [n, r] = (0, R.useState)(!1);
+var BF = (e = "") => /^https?:\/\//i.test(e) ? e : "", Xhe = (e = "") => BF(e) || (e.startsWith("/") && !e.startsWith("//") ? e : "");
+function VF({ url: e }) {
+ let t = Xhe(e || ""), [n, r] = (0, R.useState)(!1);
return /* @__PURE__ */ (0, z.jsx)("div", {
className: "flex h-review-image items-center justify-center overflow-hidden rounded-surface bg-background-secondary-default",
children: t && !n ? /* @__PURE__ */ (0, z.jsx)("img", {
@@ -47093,7 +47093,7 @@ function BF({ url: e }) {
})
});
}
-function VF({ asset: e, openItem: t }) {
+function HF({ asset: e, openItem: t }) {
let n = e.name || "";
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-w-0 items-center gap-2.5 rounded-surface bg-background-secondary-default p-2",
@@ -47126,14 +47126,14 @@ function VF({ asset: e, openItem: t }) {
})]
});
}
-function Qhe({ kind: e, name: t, works: n, avatar: r, openEntity: i }) {
+function Zhe({ kind: e, name: t, works: n, avatar: r, openEntity: i }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-w-0 items-center gap-3",
children: [/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"aria-label": `打开创作者页:${t}`,
onClick: () => i(e, t),
- className: `relative inline-grid size-11 shrink-0 cursor-pointer place-items-center overflow-hidden rounded-full bg-background-secondary-default text-caption-1-medium text-text-secondary outline-none focus-visible:ring-2 focus-visible:ring-border-focus-ring ${KN}`,
+ className: `relative inline-grid size-11 shrink-0 cursor-pointer place-items-center overflow-hidden rounded-full bg-background-secondary-default text-caption-1-medium text-text-secondary outline-none focus-visible:ring-2 focus-visible:ring-border-focus-ring ${qN}`,
dangerouslySetInnerHTML: { __html: r }
}), /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-w-0 flex-col items-start",
@@ -47149,8 +47149,8 @@ function Qhe({ kind: e, name: t, works: n, avatar: r, openEntity: i }) {
})]
});
}
-function $he({ row: e, openItem: t, openEntity: n, onReveal: r, revealing: i, note: a }) {
- let o = zF(e.profile_url || ""), s = (e.preview_assets || []).slice(0, 6), c = Math.max(0, Number(e.video_count || e.videos || 0));
+function Qhe({ row: e, openItem: t, openEntity: n, onReveal: r, revealing: i, note: a }) {
+ let o = BF(e.profile_url || ""), s = (e.preview_assets || []).slice(0, 6), c = Math.max(0, Number(e.video_count || e.videos || 0));
return /* @__PURE__ */ (0, z.jsxs)("section", {
className: "flex flex-col gap-3",
children: [
@@ -47175,7 +47175,7 @@ function $he({ row: e, openItem: t, openEntity: n, onReveal: r, revealing: i, no
children: `查看全部 ${c.toLocaleString()} 部作品`
})]
}),
- /* @__PURE__ */ (0, z.jsx)(BF, { url: e.preview_url }),
+ /* @__PURE__ */ (0, z.jsx)(VF, { url: e.preview_url }),
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
children: "通过后记录身份判断。"
@@ -47218,7 +47218,7 @@ function $he({ row: e, openItem: t, openEntity: n, onReveal: r, revealing: i, no
]
});
}
-function ege({ assets: e, picked: t, onPicked: n, locked: r }) {
+function $he({ assets: e, picked: t, onPicked: n, locked: r }) {
let [i, a] = (0, R.useState)(null), o = new Set(t), s = (t, s) => {
if (r) return;
let c = new Set(o);
@@ -47274,7 +47274,7 @@ function ege({ assets: e, picked: t, onPicked: n, locked: r }) {
}),
/* @__PURE__ */ (0, z.jsx)("span", {
className: "absolute top-1 right-1",
- children: /* @__PURE__ */ (0, z.jsx)(xO, {
+ children: /* @__PURE__ */ (0, z.jsx)(gO, {
size: "sm",
state: {
isSelected: n,
@@ -47294,19 +47294,19 @@ function ege({ assets: e, picked: t, onPicked: n, locked: r }) {
}
//#endregion
//#region src/react/review/review-card.tsx
-var tge = Zi({
+var ege = Zi({
variant: "outlined",
padding: "none",
className: "flex flex-col gap-4 px-5 pt-4"
-}), HF = "flex min-h-6 min-w-0 items-center", nge = (e) => e === "western_identity" ? "h-review-card-tall" : "h-review-card";
-function rge(e) {
- let { category: t, row: n, choice: r, onChoice: i, selected: a, onSelect: o, locked: s, busy: c, problem: l, genreTags: u, onDecide: d, handlers: f } = e, p = (0, R.useRef)(!1), m = uO(), h = uO(), g = t === "metadata_fields", _ = kre[t] || "", v = String(n.creator || "").trim(), y = !!_ && !!v, b = Fre(t, n), x = _x(t, n), S = gx(t, n), C = Ire(n), w = Lre(n), T = hx(t, n), E = n.comparison_assets || [], D = n.preview_assets || [], O = String(n.decision || "pending") !== "pending", k = E.length > 1 ? /* @__PURE__ */ (0, z.jsx)("div", {
+}), UF = "flex min-h-6 min-w-0 items-center", tge = (e) => e === "western_identity" ? "h-review-card-tall" : "h-review-card";
+function nge(e) {
+ let { category: t, row: n, choice: r, onChoice: i, selected: a, onSelect: o, locked: s, busy: c, problem: l, genreTags: u, onDecide: d, handlers: f } = e, p = (0, R.useRef)(!1), m = aO(), h = aO(), g = t === "metadata_fields", _ = wre[t] || "", v = String(n.creator || "").trim(), y = !!_ && !!v, b = Are(t, n), x = Sx(t, n), S = xx(t, n), C = jre(n), w = Mre(n), T = bx(t, n), E = n.comparison_assets || [], D = n.preview_assets || [], O = String(n.decision || "pending") !== "pending", k = E.length > 1 ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "flex flex-col gap-3",
- children: E.map((e) => /* @__PURE__ */ (0, z.jsx)(VF, {
+ children: E.map((e) => /* @__PURE__ */ (0, z.jsx)(HF, {
asset: e,
openItem: f.openItem
}, e.id))
- }) : y ? /* @__PURE__ */ (0, z.jsx)(Qhe, {
+ }) : y ? /* @__PURE__ */ (0, z.jsx)(Zhe, {
kind: _,
name: v,
works: Number(n.video_count || n.videos || 0),
@@ -47316,14 +47316,14 @@ function rge(e) {
has_image: !!n.has_image,
avatar_focus: n.avatar_focus
} : null, null, _)
- }) : n.asset_id ? /* @__PURE__ */ (0, z.jsx)(VF, {
+ }) : n.asset_id ? /* @__PURE__ */ (0, z.jsx)(HF, {
openItem: f.openItem,
asset: {
id: n.asset_id,
name: n.asset_name,
preview_url: n.asset_preview_url
}
- }) : null, A = g ? /* @__PURE__ */ (0, z.jsx)(Jhe, {
+ }) : null, A = g ? /* @__PURE__ */ (0, z.jsx)(qhe, {
row: n,
fieldName: x,
value: r.candidateKey,
@@ -47332,7 +47332,7 @@ function rge(e) {
candidateKey: e
}),
locked: s
- }) : t === "creator_tags" ? D.length ? /* @__PURE__ */ (0, z.jsx)(ege, {
+ }) : t === "creator_tags" ? D.length ? /* @__PURE__ */ (0, z.jsx)($he, {
assets: D,
picked: r.assets,
locked: s,
@@ -47345,15 +47345,15 @@ function rge(e) {
icon: st,
title: "这批作品尚未抽帧",
children: `${n.video_count || ""} 条作品还没有可用预览;批准后仍会按候选写入标签。`
- }) : t === "fc2_similarity" ? null : t === "western_identity" ? /* @__PURE__ */ (0, z.jsx)($he, {
+ }) : t === "fc2_similarity" ? null : t === "western_identity" ? /* @__PURE__ */ (0, z.jsx)(Qhe, {
row: n,
openItem: f.openItem,
openEntity: f.openEntity,
onReveal: f.onReveal,
revealing: f.revealing,
note: f.revealNote
- }) : /* @__PURE__ */ (0, z.jsx)(BF, { url: n.preview_url }), j = y ? k : x ? /* @__PURE__ */ (0, z.jsxs)("h4", {
- className: `${HF} flex-wrap gap-2`,
+ }) : /* @__PURE__ */ (0, z.jsx)(VF, { url: n.preview_url }), j = y ? k : x ? /* @__PURE__ */ (0, z.jsxs)("h4", {
+ className: `${UF} flex-wrap gap-2`,
children: [/* @__PURE__ */ (0, z.jsx)(zi, {
variant: "caption",
color: "blue",
@@ -47364,7 +47364,7 @@ function rge(e) {
children: S
})]
}) : /* @__PURE__ */ (0, z.jsx)("h4", {
- className: HF,
+ className: UF,
children: /* @__PURE__ */ (0, z.jsx)("span", {
title: b,
className: "min-w-0 truncate text-body-medium text-text-primary",
@@ -47374,20 +47374,20 @@ function rge(e) {
return /* @__PURE__ */ (0, z.jsxs)("section", {
"aria-label": b,
"data-review-key": n.item_key,
- className: `${tge} ${nge(t)} overflow-hidden`,
+ className: `${ege} ${tge(t)} overflow-hidden`,
children: [
/* @__PURE__ */ (0, z.jsxs)("header", {
className: "flex min-w-0 shrink-0 items-start gap-2",
children: [
s ? null : /* @__PURE__ */ (0, z.jsx)("span", {
- className: `${HF} shrink-0`,
+ className: `${UF} shrink-0`,
onPointerDownCapture: (e) => {
p.current = e.shiftKey;
},
onKeyDownCapture: (e) => {
p.current = e.shiftKey;
},
- children: /* @__PURE__ */ (0, z.jsx)(SO, {
+ children: /* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: a,
"aria-label": `选择 ${b}`,
onChange: (e) => o(p.current, e)
@@ -47431,7 +47431,7 @@ function rge(e) {
})
}) : null,
A,
- /* @__PURE__ */ (0, z.jsx)(Xhe, {
+ /* @__PURE__ */ (0, z.jsx)(Yhe, {
row: n,
tags: u,
locked: s,
@@ -47493,8 +47493,8 @@ function rge(e) {
}
//#endregion
//#region src/react/review/review-page.tsx
-var ige = "flex cursor-pointer items-center justify-between gap-2";
-function age({ page: e, pages: t, onPage: n }) {
+var rge = "flex cursor-pointer items-center justify-between gap-2";
+function ige({ page: e, pages: t, onPage: n }) {
return t <= 1 ? null : /* @__PURE__ */ (0, z.jsxs)("nav", {
"aria-label": "复核分页",
className: "flex w-full flex-wrap items-center justify-between gap-2",
@@ -47508,7 +47508,7 @@ function age({ page: e, pages: t, onPage: n }) {
}),
/* @__PURE__ */ (0, z.jsx)("ul", {
className: "flex flex-wrap items-center gap-1",
- children: sx(e, t).map((t, r) => /* @__PURE__ */ (0, z.jsx)("li", { children: t === "…" ? /* @__PURE__ */ (0, z.jsx)("span", {
+ children: fx(e, t).map((t, r) => /* @__PURE__ */ (0, z.jsx)("li", { children: t === "…" ? /* @__PURE__ */ (0, z.jsx)("span", {
"aria-hidden": !0,
className: "px-1 text-body-2-regular text-text-tertiary",
children: "…"
@@ -47531,38 +47531,38 @@ function age({ page: e, pages: t, onPage: n }) {
]
});
}
-function oge(e) {
+function age(e) {
let [t, n] = (0, R.useState)(() => matchMedia("(max-width:900px)").matches);
(0, R.useEffect)(() => {
let e = matchMedia("(max-width:900px)"), t = () => n(e.matches);
return e.addEventListener("change", t), () => e.removeEventListener("change", t);
}, []);
- let { route: r, openItem: i, openEntity: a, revealSource: o, avatarInner: s, toast: c, readOnly: l, readOnlyMessage: u, writerUrl: d } = e, [f, p] = (0, R.useState)(px(e.category) ? e.category : Ore), [m, h] = (0, R.useState)("candidates"), [g, _] = (0, R.useState)(""), [v, y] = (0, R.useState)(1), [b, x] = (0, R.useState)(/* @__PURE__ */ new Set()), [S, C] = (0, R.useState)(/* @__PURE__ */ new Map()), [w, T] = (0, R.useState)(/* @__PURE__ */ new Map()), [E, D] = (0, R.useState)(""), O = (0, R.useRef)(null), [k, A] = (0, R.useState)(0), [j, M] = (0, R.useState)(""), N = (0, R.useRef)(!0);
+ let { route: r, openItem: i, openEntity: a, revealSource: o, avatarInner: s, toast: c, readOnly: l, readOnlyMessage: u, writerUrl: d } = e, [f, p] = (0, R.useState)(vx(e.category) ? e.category : Cre), [m, h] = (0, R.useState)("candidates"), [g, _] = (0, R.useState)(""), [v, y] = (0, R.useState)(1), [b, x] = (0, R.useState)(/* @__PURE__ */ new Set()), [S, C] = (0, R.useState)(/* @__PURE__ */ new Map()), [w, T] = (0, R.useState)(/* @__PURE__ */ new Map()), [E, D] = (0, R.useState)(""), O = (0, R.useRef)(null), [k, A] = (0, R.useState)(0), [j, M] = (0, R.useState)(""), N = (0, R.useRef)(!0);
(0, R.useEffect)(() => () => {
N.current = !1;
}, []);
let P = $n({
- queryKey: dx,
- queryFn: ({ signal: e }) => yx(e)
+ queryKey: gx,
+ queryFn: ({ signal: e }) => wx(e)
}).data || {
sections: {},
counts: {}
- }, ee = P.sections[f] || [], F = f === "metadata_fields", I = l, te = Are(ee, F), ne = te.some(([e]) => e === m) ? m : "candidates", re = mx(ee, ne), ie = re.some((e) => e.key === g) ? g : "", ae = Mre(jre(ee, ne, ie), v), oe = ae.rows.map((e) => e.item_key), se = new Set(oe), ce = re.map((e) => ({
+ }, ee = P.sections[f] || [], F = f === "metadata_fields", I = l, te = Tre(ee, F), ne = te.some(([e]) => e === m) ? m : "candidates", re = yx(ee, ne), ie = re.some((e) => e.key === g) ? g : "", ae = Dre(Ere(ee, ne, ie), v), oe = ae.rows.map((e) => e.item_key), se = new Set(oe), ce = re.map((e) => ({
...e,
rows: e.rows.filter((e) => se.has(e.item_key))
- })).filter((e) => e.rows.length), le = (e) => S.get(e.item_key) || zre(e), ue = ee.filter((e) => b.has(e.item_key)), L = (e) => {
+ })).filter((e) => e.rows.length), le = (e) => S.get(e.item_key) || Pre(e), ue = ee.filter((e) => b.has(e.item_key)), L = (e) => {
let t = new Set(e);
x((e) => new Set([...e].filter((e) => !t.has(e)))), C((e) => new Map([...e].filter(([e]) => !t.has(e)))), T((e) => new Map([...e].filter(([e]) => !t.has(e))));
}, de = (e, t) => T((n) => new Map(n).set(e, t)), fe = (e) => {
p(e), h("candidates"), _(""), y(1), x(/* @__PURE__ */ new Set()), C(/* @__PURE__ */ new Map()), T(/* @__PURE__ */ new Map()), D(""), O.current = null, r({ category: e === "metadata_fields" ? "" : e });
}, pe = er({
- mutationFn: ({ row: e, status: t }) => bx(vx(f, e, t, le(e))),
+ mutationFn: ({ row: e, status: t }) => Tx(Cx(f, e, t, le(e))),
onSuccess: (e, { row: t, status: n }) => {
if (!e.ok) {
de(t.item_key, e.error || "服务端拒绝了这次判定");
return;
}
- xx(f, [t.item_key]), L([t.item_key]), c(Bre(n));
+ Ex(f, [t.item_key]), L([t.item_key]), c(Fre(n));
},
onError: (e, { row: t }) => de(t.item_key, U(e))
}), me = er({
@@ -47572,7 +47572,7 @@ function oge(e) {
if (!N.current) break;
D(`正在处理 ${i} / ${t.length}`);
try {
- let t = await bx(vx(f, a, e, le(a)));
+ let t = await Tx(Cx(f, a, e, le(a)));
if (!t.ok) throw Error(t.error || "服务端未采用该项");
n.push(a.item_key);
} catch (e) {
@@ -47586,7 +47586,7 @@ function oge(e) {
};
},
onSuccess: ({ status: e, done: t, failures: n }) => {
- xx(f, t), L(t), n.forEach(([e, t]) => de(e, t)), D(""), c(`已${e === "approved" ? "通过" : "拒绝"} ${t.length} 项` + (n.length ? `,${n.length} 项未完成` : ""));
+ Ex(f, t), L(t), n.forEach(([e, t]) => de(e, t)), D(""), c(`已${e === "approved" ? "通过" : "拒绝"} ${t.length} 项` + (n.length ? `,${n.length} 项未完成` : ""));
},
onError: (e) => {
D(U(e));
@@ -47616,7 +47616,7 @@ function oge(e) {
A(e), M("");
let t = await o(e);
N.current && (A(0), M(t));
- }, ve = Wre(P.mirror, u), ye = P.genre_tags || [], be = {
+ }, ve = zre(P.mirror, u), ye = P.genre_tags || [], be = {
openItem: i,
openEntity: a,
onReveal: _e,
@@ -47641,13 +47641,13 @@ function oge(e) {
}) : void 0,
children: ve
}) : null,
- /* @__PURE__ */ (0, z.jsx)(qhe, { tags: ye }),
- /* @__PURE__ */ (0, z.jsxs)($v, {
+ /* @__PURE__ */ (0, z.jsx)(Khe, { tags: ye }),
+ /* @__PURE__ */ (0, z.jsxs)(ay, {
orientation: t ? "horizontal" : "vertical",
selectedKey: f,
onSelectionChange: (e) => {
let t = String(e);
- px(t) && fe(t);
+ vx(t) && fe(t);
},
className: "flex flex-col gap-5 review-split:flex-row-reverse review-split:items-start review-split:gap-6",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
@@ -47656,27 +47656,27 @@ function oge(e) {
children: [/* @__PURE__ */ (0, z.jsx)("h2", {
id: "reviewcategories",
children: "复核分类"
- }), /* @__PURE__ */ (0, z.jsx)(ty, {
+ }), /* @__PURE__ */ (0, z.jsx)(oy, {
"aria-labelledby": "reviewcategories",
"data-section-items": !0,
className: "flex review-split:flex-col review-split:items-stretch",
- children: Dre.map((e) => {
+ children: Sre.map((e) => {
let t = Number(P.counts[e] || 0);
- return /* @__PURE__ */ (0, z.jsxs)(ny, {
+ return /* @__PURE__ */ (0, z.jsxs)(sy, {
id: e,
- className: ige,
- children: [fx[e], t ? /* @__PURE__ */ (0, z.jsx)("span", {
+ className: rge,
+ children: [_x[e], t ? /* @__PURE__ */ (0, z.jsx)("span", {
className: "tabular-nums text-caption-1-medium text-text-secondary",
children: t.toLocaleString()
}) : null]
}, e);
})
})]
- }), /* @__PURE__ */ (0, z.jsxs)(ry, {
+ }), /* @__PURE__ */ (0, z.jsxs)(cy, {
id: f,
className: "flex min-w-0 flex-1 flex-col gap-5",
children: [
- ee.length && !I ? /* @__PURE__ */ (0, z.jsx)(Ghe, {
+ ee.length && !I ? /* @__PURE__ */ (0, z.jsx)(Whe, {
groupOptions: te,
groupBy: ne,
onGroupBy: (e) => {
@@ -47692,7 +47692,7 @@ function oge(e) {
onSelected: x,
selectedRows: ue,
metadata: F,
- approvable: ue.every((e) => hx(f, e)),
+ approvable: ue.every((e) => bx(f, e)),
busy: me.isPending,
feedback: E,
onUnifySource: ge,
@@ -47717,7 +47717,7 @@ function oge(e) {
})]
}) : null, /* @__PURE__ */ (0, z.jsx)("div", {
className: "review-grid gap-5",
- children: e.rows.map((e) => /* @__PURE__ */ (0, z.jsx)(rge, {
+ children: e.rows.map((e) => /* @__PURE__ */ (0, z.jsx)(nge, {
category: f,
row: e,
choice: le(e),
@@ -47725,7 +47725,7 @@ function oge(e) {
selected: b.has(e.item_key),
onSelect: (t, n) => x((r) => {
let i = new Set(r);
- return O.current = Pre(i, oe, O.current, e.item_key, t, n), i;
+ return O.current = kre(i, oe, O.current, e.item_key, t, n), i;
}),
locked: I,
busy: pe.isPending && pe.variables?.row.item_key === e.item_key,
@@ -47745,7 +47745,7 @@ function oge(e) {
title: "此分类没有待复核项目",
children: "可切换分类查看其他候选。"
}),
- /* @__PURE__ */ (0, z.jsx)(age, {
+ /* @__PURE__ */ (0, z.jsx)(ige, {
page: ae.page,
pages: ae.pages,
onPage: y
@@ -47758,13 +47758,9 @@ function oge(e) {
}
//#endregion
//#region src/react/scraping/scraping.ts
-var sge = "/api/scraping", cge = "/api/scraping/settings", lge = "/api/scraping/check", UF = "/api/scraping/cover", uge = "/api/scraping/amane-bridge", dge = "/api/scraping/amane-bridge/check", fge = "/api/scraping/amane-bridge/rebuild", WF = ["scraping"], GF = ["scraping", "cover"], KF = ["scraping", "amane-bridge"], qF = (e) => W(sge, e), JF = (e) => W(UF, e), YF = (e) => W(uge, e);
-async function pge(e) {
+var oge = "/api/scraping", sge = "/api/scraping/settings", cge = "/api/scraping/check", WF = "/api/scraping/cover", lge = "/api/scraping/amane-bridge", uge = "/api/scraping/amane-bridge/check", dge = "/api/scraping/amane-bridge/rebuild", GF = ["scraping"], KF = ["scraping", "cover"], qF = ["scraping", "amane-bridge"], JF = (e) => W(oge, e), YF = (e) => W(WF, e), XF = (e) => W(lge, e);
+async function fge(e) {
await Promise.all([
- X.fetchQuery({
- queryKey: WF,
- queryFn: () => qF(e)
- }),
X.fetchQuery({
queryKey: GF,
queryFn: () => JF(e)
@@ -47772,16 +47768,20 @@ async function pge(e) {
X.fetchQuery({
queryKey: KF,
queryFn: () => YF(e)
+ }),
+ X.fetchQuery({
+ queryKey: qF,
+ queryFn: () => XF(e)
})
]);
}
-function mge(e, t) {
+function pge(e, t) {
return `${t}${e.label === "来源页面" ? "" : " 高清图片"}:${e.ok ? "可连接" : "不能连接"}` + (e.width ? ` · ${e.width} × ${e.height}` : "") + (e.message ? `。${e.message}` : "");
}
//#endregion
//#region src/react/scraping/scraping-page.tsx
-var hge = [["peach", "Peach 代理"], ["direct", "直接连接"]], XF = [["paste", "粘贴 Cookie"], ["file", "导入文件"]];
-function ZF({ source: e }) {
+var mge = [["peach", "Peach 代理"], ["direct", "直接连接"]], ZF = [["paste", "粘贴 Cookie"], ["file", "导入文件"]];
+function QF({ source: e }) {
let t = [
"javten",
"fc2ppvdb",
@@ -47799,16 +47799,16 @@ function ZF({ source: e }) {
className: "size-4 shrink-0 rounded-sm object-contain"
});
}
-function gge() {
- return /* @__PURE__ */ (0, z.jsx)(ZF, { source: "github" });
+function hge() {
+ return /* @__PURE__ */ (0, z.jsx)(QF, { source: "github" });
}
-function _ge({ source: e, toast: t }) {
- let [n, r] = (0, R.useState)(e.network), [i, a] = (0, R.useState)(""), [o, s] = (0, R.useState)(""), [c, l] = (0, R.useState)(XF[0][0]), [u, d] = (0, R.useState)(""), [f, p] = (0, R.useState)(""), m = (0, R.useRef)(null);
+function gge({ source: e, toast: t }) {
+ let [n, r] = (0, R.useState)(e.network), [i, a] = (0, R.useState)(""), [o, s] = (0, R.useState)(""), [c, l] = (0, R.useState)(ZF[0][0]), [u, d] = (0, R.useState)(""), [f, p] = (0, R.useState)(""), m = (0, R.useRef)(null);
function h() {
a(""), s(""), d(""), p(""), m.current && (m.current.value = "");
}
let g = er({
- mutationFn: (t) => G(cge, {
+ mutationFn: (t) => G(sge, {
source: e.source,
network: n,
cookie: i,
@@ -47816,12 +47816,12 @@ function _ge({ source: e, toast: t }) {
revoke: t
}),
onSuccess: (e, n) => {
- X.setQueryData(WF, (t) => t && {
+ X.setQueryData(GF, (t) => t && {
...t,
sources: t.sources.map((t) => t.source === e.saved.source ? e.saved : t)
}), h(), t(n ? "Cookie 已撤销" : "来源设置已保存");
}
- }), _ = er({ mutationFn: () => G(lge, { source: e.source }) }), v = g.isPending || _.isPending, y = (e) => {
+ }), _ = er({ mutationFn: () => G(cge, { source: e.source }) }), v = g.isPending || _.isPending, y = (e) => {
e.preventDefault(), !v && (_.reset(), g.mutate(!1));
}, b = () => {
v || (_.reset(), g.mutate(!0));
@@ -47846,37 +47846,37 @@ function _ge({ source: e, toast: t }) {
}
}
let C = f || (g.error ? U(g.error) : "") || (_.error ? U(_.error) : ""), w = _.data?.results ?? [], T = n === "peach" || e.accepts_cookie || e.browser || !!C || w.length > 0;
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: e.label,
onSubmit: y,
aside: /* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 items-center gap-1",
- children: [/* @__PURE__ */ (0, z.jsx)(ZF, { source: e.source }), /* @__PURE__ */ (0, z.jsx)(Dy, {
+ children: [/* @__PURE__ */ (0, z.jsx)(QF, { source: e.source }), /* @__PURE__ */ (0, z.jsx)(My, {
href: e.login,
children: e.login
})]
}),
children: [
- /* @__PURE__ */ (0, z.jsx)(xy, { children: /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsx)(Ey, { children: /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "连接方式",
- children: /* @__PURE__ */ (0, z.jsx)(py, {
+ children: /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "连接方式",
selectedKey: n,
onSelectionChange: (e) => {
e !== null && r(String(e));
},
- children: hge.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: mge.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e,
children: t
}, e))
})
}) }),
- T ? /* @__PURE__ */ (0, z.jsxs)(Sy, {
+ T ? /* @__PURE__ */ (0, z.jsxs)(Dy, {
divided: !0,
children: [
n === "peach" ? /* @__PURE__ */ (0, z.jsx)("span", {
className: "self-start",
- children: /* @__PURE__ */ (0, z.jsx)(yy, {
+ children: /* @__PURE__ */ (0, z.jsx)(wy, {
href: "/configuration#peachProxy",
size: "small",
trailingIcon: We,
@@ -47892,20 +47892,20 @@ function _ge({ source: e, toast: t }) {
className: "text-body-2-regular text-text-secondary",
children: e.cookie_saved ? "Cookie 已保存;登录是否有效要到抓取时才知道。" : "需要登录时,任选一种方式提供 Cookie。"
}),
- /* @__PURE__ */ (0, z.jsx)($O, {
+ /* @__PURE__ */ (0, z.jsx)(GO, {
"aria-label": "提供 Cookie 的方式(二选一)",
value: c,
onChange: (e) => {
l(e), h();
},
- className: ek,
- children: XF.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(D_, {
+ className: KO,
+ children: ZF.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(O_, {
value: e,
- className: tk,
+ className: qO,
children: t
}, e))
}),
- c === "paste" ? /* @__PURE__ */ (0, z.jsx)(cy, {
+ c === "paste" ? /* @__PURE__ */ (0, z.jsx)(py, {
type: "password",
label: "Cookie",
autoComplete: "off",
@@ -47914,7 +47914,7 @@ function _ge({ source: e, toast: t }) {
}) : /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(Ey, { children: "Netscape Cookie 文件(.txt)" }),
+ /* @__PURE__ */ (0, z.jsx)(jy, { children: "Netscape Cookie 文件(.txt)" }),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center gap-3",
children: [/* @__PURE__ */ (0, z.jsx)(H, {
@@ -47940,14 +47940,14 @@ function _ge({ source: e, toast: t }) {
]
})
] }) : null,
- C ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: C }) : null,
+ C ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: C }) : null,
w.map((t) => /* @__PURE__ */ (0, z.jsx)(K, {
tone: t.ok ? "success" : "error",
- children: mge(t, e.label)
+ children: pge(t, e.label)
}, t.label))
]
}) : null,
- /* @__PURE__ */ (0, z.jsxs)(Cy, { children: [
+ /* @__PURE__ */ (0, z.jsxs)(Oy, { children: [
e.accepts_cookie && e.cookie_saved ? /* @__PURE__ */ (0, z.jsx)(H, {
variant: "secondary",
onClick: b,
@@ -47969,26 +47969,26 @@ function _ge({ source: e, toast: t }) {
]
});
}
-function vge({ toast: e }) {
- let [t, n] = (0, R.useState)(""), { running: r, outcome: i, start: a } = vO({
- queryKey: GF,
- queryFn: ({ signal: e }) => JF(e),
- start: () => G(UF, { code: t }),
+function _ge({ toast: e }) {
+ let [t, n] = (0, R.useState)(""), { running: r, outcome: i, start: a } = pO({
+ queryKey: KF,
+ queryFn: ({ signal: e }) => YF(e),
+ start: () => G(WF, { code: t }),
onFinish: (t) => {
t.status === "complete" && e(t.result || "封面采集完成");
}
}), o = (e) => {
e.preventDefault(), !(r || a.isPending || !t.trim()) && a.mutate();
}, s = a.error ? U(a.error) : i?.status === "failed" ? i.error || "采集未取得" : "";
- return /* @__PURE__ */ (0, z.jsx)(by, {
+ return /* @__PURE__ */ (0, z.jsx)(Ty, {
title: "高清封面",
onSubmit: o,
- children: /* @__PURE__ */ (0, z.jsxs)(Sy, { children: [
+ children: /* @__PURE__ */ (0, z.jsxs)(Dy, { children: [
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-end gap-2",
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "min-w-0 flex-1",
- children: /* @__PURE__ */ (0, z.jsx)(cy, {
+ children: /* @__PURE__ */ (0, z.jsx)(py, {
"aria-label": "馆藏番号",
isRequired: !0,
isDisabled: r,
@@ -48015,11 +48015,11 @@ function vge({ toast: e }) {
] })
});
}
-function yge({ toast: e }) {
- let { query: t, running: n, outcome: r, start: i } = vO({
- queryKey: KF,
- queryFn: ({ signal: e }) => YF(e),
- start: () => G(fge, {}),
+function vge({ toast: e }) {
+ let { query: t, running: n, outcome: r, start: i } = pO({
+ queryKey: qF,
+ queryFn: ({ signal: e }) => XF(e),
+ start: () => G(dge, {}),
jobOf: (e) => e.job,
withJob: (e, t) => e && {
...e,
@@ -48028,45 +48028,45 @@ function yge({ toast: e }) {
onFinish: (t) => {
t.status === "complete" && e(t.result || "amane 桥已重建");
}
- }), a = er({ mutationFn: () => G(dge, {}) }), o = t.data;
- if (!o) return t.error ? /* @__PURE__ */ (0, z.jsx)(by, {
+ }), a = er({ mutationFn: () => G(uge, {}) }), o = t.data;
+ if (!o) return t.error ? /* @__PURE__ */ (0, z.jsx)(Ty, {
title: "amane",
- children: /* @__PURE__ */ (0, z.jsx)(Sy, { children: /* @__PURE__ */ (0, z.jsx)(K, {
+ children: /* @__PURE__ */ (0, z.jsx)(Dy, { children: /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
children: U(t.error)
}) })
}) : null;
let s = n || i.isPending || a.isPending, c = i.error ? U(i.error) : a.error ? U(a.error) : r?.status === "failed" ? r.error || "重建未完成" : "";
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "amane",
- aside: /* @__PURE__ */ (0, z.jsx)(Dy, {
+ aside: /* @__PURE__ */ (0, z.jsx)(My, {
href: o.repository,
- leadingIcon: gge,
+ leadingIcon: hge,
children: o.repository
}),
children: [
- /* @__PURE__ */ (0, z.jsxs)(Oy, { children: [
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsxs)(Ny, { children: [
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "已安装版本",
children: o.installed_version || "未安装"
}),
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "上游最新版本",
children: a.data?.latest ?? "尚未检查"
}),
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "运行环境",
children: o.installed ? "已安装" : "未安装"
}),
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "内置站点",
children: o.sites.map((e) => e.label).join("、")
})
] }),
- /* @__PURE__ */ (0, z.jsxs)(Sy, {
+ /* @__PURE__ */ (0, z.jsxs)(Dy, {
divided: !0,
children: [
- /* @__PURE__ */ (0, z.jsxs)(wy, { children: [
+ /* @__PURE__ */ (0, z.jsxs)(ky, { children: [
"已安装版本:",
o.installed_version || "未安装",
"。amane(",
@@ -48086,7 +48086,7 @@ function yge({ toast: e }) {
}) : null
]
}),
- /* @__PURE__ */ (0, z.jsxs)(Cy, { children: [/* @__PURE__ */ (0, z.jsx)(H, {
+ /* @__PURE__ */ (0, z.jsxs)(Oy, { children: [/* @__PURE__ */ (0, z.jsx)(H, {
variant: "secondary",
onClick: () => {
s || a.mutate();
@@ -48103,22 +48103,22 @@ function yge({ toast: e }) {
]
});
}
-function bge({ toast: e }) {
+function yge({ toast: e }) {
let t = $n({
- queryKey: WF,
- queryFn: ({ signal: e }) => qF(e)
+ queryKey: GF,
+ queryFn: ({ signal: e }) => JF(e)
}), n = t.data;
return n ? /* @__PURE__ */ (0, z.jsxs)(ta, { children: [
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
children: "高清图片可能要经代理才能下载,先检查连接。"
}),
- /* @__PURE__ */ (0, z.jsx)(vge, { toast: e }),
- (n.sources || []).map((t) => /* @__PURE__ */ (0, z.jsx)(_ge, {
+ /* @__PURE__ */ (0, z.jsx)(_ge, { toast: e }),
+ (n.sources || []).map((t) => /* @__PURE__ */ (0, z.jsx)(gge, {
source: t,
toast: e
}, t.source)),
- /* @__PURE__ */ (0, z.jsx)(yge, { toast: e })
+ /* @__PURE__ */ (0, z.jsx)(vge, { toast: e })
] }) : /* @__PURE__ */ (0, z.jsx)(ta, { children: /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
title: "采集来源读取失败",
@@ -48127,24 +48127,24 @@ function bge({ toast: e }) {
}
//#endregion
//#region src/configuration-endpoints.ts
-var QF = "/api/configuration", xge = "/api/pick-folder", $F = ["configuration"], eI = (e) => W(QF, e);
-async function tI(e) {
+var $F = "/api/configuration", bge = "/api/pick-folder", eI = ["configuration"], tI = (e) => W($F, e);
+async function nI(e) {
await X.fetchQuery({
- queryKey: $F,
- queryFn: () => eI(e)
+ queryKey: eI,
+ queryFn: () => tI(e)
});
}
//#endregion
//#region src/configuration-copy.ts
-var Sge = "JavDB 或 MISSAV 无法访问时,可填写能访问的镜像域名,Peach 会保留人物页路径。 资料页只显示已有站点身份记录的入口;JavDB 和 MISSAV 还要求有 JAV 目录站记录。 缺少这些记录的 FC2 创作者不会显示这两个入口。", Cge = "仅填域名;留空使用默认地址";
+var xge = "JavDB 或 MISSAV 无法访问时,可填写能访问的镜像域名,Peach 会保留人物页路径。 资料页只显示已有站点身份记录的入口;JavDB 和 MISSAV 还要求有 JAV 目录站记录。 缺少这些记录的 FC2 创作者不会显示这两个入口。", Sge = "仅填域名;留空使用默认地址";
//#endregion
//#region src/react/settings/entry-links-settings.tsx
-function wge({ initial: e, receipt: t }) {
+function Cge({ initial: e, receipt: t }) {
let [n, r] = (0, R.useState)(e.sites), i = aa(), a = (e, t) => r((n) => n.map((n) => n.key === e ? {
...n,
host: t
} : n));
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "外部入口",
onSubmit: (e) => {
e.preventDefault();
@@ -48153,9 +48153,9 @@ function wge({ initial: e, receipt: t }) {
r(e.sites), t("已保存配置");
});
},
- children: [/* @__PURE__ */ (0, z.jsxs)(Sy, { children: [
- /* @__PURE__ */ (0, z.jsx)(wy, { children: Sge }),
- n.map((e) => /* @__PURE__ */ (0, z.jsx)(cy, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(Dy, { children: [
+ /* @__PURE__ */ (0, z.jsx)(ky, { children: xge }),
+ n.map((e) => /* @__PURE__ */ (0, z.jsx)(py, {
id: `entry-link-${e.key}`,
label: `${e.label} 地址`,
autoComplete: "off",
@@ -48164,10 +48164,10 @@ function wge({ initial: e, receipt: t }) {
placeholder: e.default_host,
onChange: (t) => a(e.key, t),
validationBehavior: "aria",
- hint: Cge
+ hint: Sge
}, e.key)),
- i.error ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: i.error }) : null
- ] }), /* @__PURE__ */ (0, z.jsx)(Cy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
+ i.error ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: i.error }) : null
+ ] }), /* @__PURE__ */ (0, z.jsx)(Oy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
type: "submit",
...q(i.busy === "save"),
children: "保存配置"
@@ -48176,21 +48176,21 @@ function wge({ initial: e, receipt: t }) {
}
//#endregion
//#region src/react/settings/general-settings.tsx
-function Tge({ data: e, receipt: t }) {
+function wge({ data: e, receipt: t }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-6",
- children: [e.startup ? /* @__PURE__ */ (0, z.jsx)(Ege, {
+ children: [e.startup ? /* @__PURE__ */ (0, z.jsx)(Tge, {
startup: e.startup,
receipt: t
- }) : null, e.entry_links ? /* @__PURE__ */ (0, z.jsx)(wge, {
+ }) : null, e.entry_links ? /* @__PURE__ */ (0, z.jsx)(Cge, {
initial: e.entry_links,
receipt: t
}) : null]
});
}
-function Ege({ startup: e, receipt: t }) {
+function Tge({ startup: e, receipt: t }) {
let [n, r] = (0, R.useState)(e.enabled), [i, a] = (0, R.useState)(e.silent), [o, s] = (0, R.useState)(e.desktop), c = aa(), l = e.available && !e.desktop_message;
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "开机自启",
onSubmit: (r) => {
r.preventDefault(), e.available && c.run("save", (e) => G("/api/configuration/startup", {
@@ -48200,30 +48200,30 @@ function Ege({ startup: e, receipt: t }) {
}, "POST", e), () => t("已保存配置"));
},
children: [
- /* @__PURE__ */ (0, z.jsxs)(xy, { children: [
- /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsxs)(Ey, { children: [
+ /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "开机后启动 Peach",
- children: /* @__PURE__ */ (0, z.jsx)(GN, {
+ children: /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": "开机后启动 Peach",
isSelected: n,
isDisabled: !e.available,
onChange: r
})
}),
- /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "静默启动",
description: "开机后只显示托盘图标,不打开网页;「开机后启动 Peach」打开时生效。",
- children: /* @__PURE__ */ (0, z.jsx)(GN, {
+ children: /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": "静默启动",
isSelected: i,
isDisabled: !e.available || !n,
onChange: a
})
}),
- /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "在桌面创建快捷方式",
description: e.desktop_message || "双击图标打开 Peach 网页;卸载时一并移除。",
- children: /* @__PURE__ */ (0, z.jsx)(GN, {
+ children: /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": "在桌面创建快捷方式",
isSelected: o,
isDisabled: !l,
@@ -48231,11 +48231,11 @@ function Ege({ startup: e, receipt: t }) {
})
})
] }),
- e.message || c.error ? /* @__PURE__ */ (0, z.jsxs)(Sy, {
+ e.message || c.error ? /* @__PURE__ */ (0, z.jsxs)(Dy, {
divided: !0,
- children: [e.message ? /* @__PURE__ */ (0, z.jsx)(wy, { children: e.message }) : null, c.error ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: c.error }) : null]
+ children: [e.message ? /* @__PURE__ */ (0, z.jsx)(ky, { children: e.message }) : null, c.error ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: c.error }) : null]
}) : null,
- /* @__PURE__ */ (0, z.jsx)(Cy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
+ /* @__PURE__ */ (0, z.jsx)(Oy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
type: "submit",
disabled: !e.available,
...q(c.busy === "save"),
@@ -48246,23 +48246,23 @@ function Ege({ startup: e, receipt: t }) {
}
//#endregion
//#region src/react/settings/release-updates.tsx
-var nI = /* @__PURE__ */ new Set([
+var rI = /* @__PURE__ */ new Set([
"downloading",
"verifying",
"extracting",
"preparing",
"restarting",
"installing"
-]), Dge = [
+]), Ege = [
65,
67,
90
-], rI = 120;
-function Oge({ initial: e, initialJob: t }) {
+], iI = 120;
+function Dge({ initial: e, initialJob: t }) {
let [n, r] = (0, R.useState)(e), [i, a] = (0, R.useState)(t || {
state: "idle",
progress: 0
- }), [o, s] = (0, R.useState)(""), c = aa(), l = (0, R.useRef)(!1), u = (0, R.useRef)(!0), d = nI.has(i.state);
+ }), [o, s] = (0, R.useState)(""), c = aa(), l = (0, R.useRef)(!1), u = (0, R.useRef)(!0), d = rI.has(i.state);
(0, R.useEffect)(() => (u.current = !0, () => {
u.current = !1;
}), []);
@@ -48279,7 +48279,7 @@ function Oge({ initial: e, initialJob: t }) {
(0, R.useEffect)(() => {
i.state !== "ready" || l.current || (l.current = !0, p());
}, [i.state]), (0, R.useEffect)(() => {
- let e = new AbortController(), t = nI.has(i.state) ? 1e3 : 3e4, n, o = 0, c = async () => {
+ let e = new AbortController(), t = rI.has(i.state) ? 1e3 : 3e4, n, o = 0, c = async () => {
try {
let t = await W("/api/configuration/update-status", e.signal);
if (e.signal.aborted) return;
@@ -48292,9 +48292,9 @@ function Oge({ initial: e, initialJob: t }) {
let n = await W("/api/configuration/automatic-updates", e.signal);
!e.signal.aborted && n.result && r(n.result);
} catch {
- o += 1, o >= rI && !e.signal.aborted && s("尚未连接到 Peach,请检查托盘后刷新页面。");
+ o += 1, o >= iI && !e.signal.aborted && s("尚未连接到 Peach,请检查托盘后刷新页面。");
}
- !e.signal.aborted && o < rI && (n = setTimeout(c, t));
+ !e.signal.aborted && o < iI && (n = setTimeout(c, t));
};
return n = setTimeout(c, t), () => {
e.abort(), clearTimeout(n);
@@ -48308,40 +48308,40 @@ function Oge({ initial: e, initialJob: t }) {
state: "error"
}), c.setError(U(t));
}), g = c.error || o, _ = i.state === "downloading" && i.total ? `${((i.downloaded || 0) / 1048576).toFixed(1)} / ${(i.total / 1048576).toFixed(1)} MB` : `${i.progress}%`;
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "检查更新",
children: [
- /* @__PURE__ */ (0, z.jsxs)(Oy, { children: [
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsxs)(Ny, { children: [
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "当前版本",
children: n.current_version
}),
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "安装方式",
children: n.installation
}),
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "更新通道",
children: n.channel
}),
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "最新版本",
children: n.latest_version || (n.state === "unchecked" ? "尚未检查" : "未取得")
})
] }),
- /* @__PURE__ */ (0, z.jsxs)(Sy, {
+ /* @__PURE__ */ (0, z.jsxs)(Dy, {
divided: !0,
children: [
- n.checked_at ? /* @__PURE__ */ (0, z.jsxs)(wy, { children: ["检查于 ", (/* @__PURE__ */ new Date(n.checked_at * 1e3)).toLocaleString()] }) : null,
+ n.checked_at ? /* @__PURE__ */ (0, z.jsxs)(ky, { children: ["检查于 ", (/* @__PURE__ */ new Date(n.checked_at * 1e3)).toLocaleString()] }) : null,
n.state === "available" && !g ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "info",
title: "有可用更新",
children: n.message
- }) : g || n.state === "error" ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: g || n.message }) : /* @__PURE__ */ (0, z.jsx)(wy, {
+ }) : g || n.state === "error" ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: g || n.message }) : /* @__PURE__ */ (0, z.jsx)(ky, {
role: "status",
children: n.message
}),
- i.state === "error" ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: i.message }) : null,
+ i.state === "error" ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: i.message }) : null,
i.state !== "idle" && i.state !== "error" ? /* @__PURE__ */ (0, z.jsxs)("div", {
"aria-live": "polite",
className: "flex flex-col gap-2",
@@ -48349,16 +48349,16 @@ function Oge({ initial: e, initialJob: t }) {
/* @__PURE__ */ (0, z.jsx)(ia, {
label: "更新准备进度",
value: i.progress,
- stops: Dge
+ stops: Ege
}),
- /* @__PURE__ */ (0, z.jsxs)(wy, { children: ["下载 → 校验 → 解压 → 准备安装 · ", i.message] }),
- /* @__PURE__ */ (0, z.jsx)(wy, { children: _ })
+ /* @__PURE__ */ (0, z.jsxs)(ky, { children: ["下载 → 校验 → 解压 → 准备安装 · ", i.message] }),
+ /* @__PURE__ */ (0, z.jsx)(ky, { children: _ })
]
}) : null
]
}),
- /* @__PURE__ */ (0, z.jsxs)(Cy, {
- status: /* @__PURE__ */ (0, z.jsx)(Dy, {
+ /* @__PURE__ */ (0, z.jsxs)(Oy, {
+ status: /* @__PURE__ */ (0, z.jsx)(My, {
href: n.release_url,
children: "查看发布页"
}),
@@ -48385,98 +48385,98 @@ function Oge({ initial: e, initialJob: t }) {
}
//#endregion
//#region src/react/settings/maintenance-settings.tsx
-var kge = [
+var Oge = [
["6", "每 6 小时"],
["24", "每天"],
["168", "每周"]
];
-function Age({ data: e, receipt: t, reopenTutorial: n }) {
+function kge({ data: e, receipt: t, reopenTutorial: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-6",
children: [
- e.automatic_updates ? /* @__PURE__ */ (0, z.jsx)(Mge, {
+ e.automatic_updates ? /* @__PURE__ */ (0, z.jsx)(jge, {
initial: e.automatic_updates,
receipt: t
}) : null,
- e.updates ? /* @__PURE__ */ (0, z.jsx)(Oge, {
+ e.updates ? /* @__PURE__ */ (0, z.jsx)(Dge, {
initial: e.updates,
initialJob: e.update_job
}) : null,
- /* @__PURE__ */ (0, z.jsx)(Nge, { facts: e.facts }),
- /* @__PURE__ */ (0, z.jsx)(jge, {
+ /* @__PURE__ */ (0, z.jsx)(Mge, { facts: e.facts }),
+ /* @__PURE__ */ (0, z.jsx)(Age, {
receipt: t,
reopenTutorial: n
}),
- e.uninstall ? /* @__PURE__ */ (0, z.jsx)(Pge, {
+ e.uninstall ? /* @__PURE__ */ (0, z.jsx)(Nge, {
uninstall: e.uninstall,
receipt: t
}) : null
]
});
}
-function jge({ receipt: e, reopenTutorial: t }) {
+function Age({ receipt: e, reopenTutorial: t }) {
let n = aa();
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "安装教程",
- children: [/* @__PURE__ */ (0, z.jsxs)(Sy, { children: [/* @__PURE__ */ (0, z.jsx)(wy, { children: "重新显示已关闭或跳过的安装步骤,保留已完成的记录。" }), n.error ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: n.error }) : null] }), /* @__PURE__ */ (0, z.jsx)(Cy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(Dy, { children: [/* @__PURE__ */ (0, z.jsx)(ky, { children: "重新显示已关闭或跳过的安装步骤,保留已完成的记录。" }), n.error ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: n.error }) : null] }), /* @__PURE__ */ (0, z.jsx)(Oy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
onClick: () => void n.run("reopen", () => t(), () => e("已重新打开安装教程")),
...q(n.busy === "reopen"),
children: "重新打开教程"
}) })]
});
}
-function Mge({ initial: e, receipt: t }) {
+function jge({ initial: e, receipt: t }) {
let [n, r] = (0, R.useState)(e.mode), [i, a] = (0, R.useState)(e.interval_hours), o = aa(e.error), s = (r) => {
r.preventDefault(), e.available && o.run("save", (e) => G("/api/configuration/automatic-updates", {
mode: n,
interval_hours: i
}, "POST", e), () => t("已保存配置"));
}, c = e.available ? e.download_available ? "开启后一分钟内开始检查。下载完成后,在此确认重启安装。" : "开启后一分钟内开始检查。源码运行时在发布页获取新版本。" : "自动更新需要由托盘管理的服务。";
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "自动更新",
onSubmit: s,
children: [
- /* @__PURE__ */ (0, z.jsxs)(xy, { children: [
- /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsxs)(Ey, { children: [
+ /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "自动检查新版本",
- children: /* @__PURE__ */ (0, z.jsx)(GN, {
+ children: /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": "自动检查新版本",
isSelected: n !== "off",
isDisabled: !e.available,
onChange: (e) => r(e ? "check" : "off")
})
}),
- /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "自动下载更新",
- children: /* @__PURE__ */ (0, z.jsx)(GN, {
+ children: /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": "自动下载更新",
isSelected: n === "download",
isDisabled: !e.available || !e.download_available || n === "off",
onChange: (e) => r(e ? "download" : "check")
})
}),
- /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "检查频率",
description: c,
- children: /* @__PURE__ */ (0, z.jsx)(py, {
+ children: /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "检查频率",
selectedKey: String(i),
isDisabled: !e.available,
onSelectionChange: (e) => {
e !== null && a(Number(e));
},
- children: kge.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: Oge.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e,
children: t
}, e))
})
})
] }),
- o.error ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ o.error ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
- children: /* @__PURE__ */ (0, z.jsx)(Ty, { children: o.error })
+ children: /* @__PURE__ */ (0, z.jsx)(Ay, { children: o.error })
}) : null,
- /* @__PURE__ */ (0, z.jsx)(Cy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
+ /* @__PURE__ */ (0, z.jsx)(Oy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
type: "submit",
disabled: !e.available,
...q(o.busy === "save"),
@@ -48485,19 +48485,19 @@ function Mge({ initial: e, receipt: t }) {
]
});
}
-function Nge({ facts: e }) {
- return /* @__PURE__ */ (0, z.jsx)(by, {
+function Mge({ facts: e }) {
+ return /* @__PURE__ */ (0, z.jsx)(Ty, {
title: "运行信息",
- children: /* @__PURE__ */ (0, z.jsx)(Oy, { children: e.map((e) => /* @__PURE__ */ (0, z.jsxs)(ky, {
+ children: /* @__PURE__ */ (0, z.jsx)(Ny, { children: e.map((e) => /* @__PURE__ */ (0, z.jsxs)(Py, {
term: e.term,
- children: [e.value, e.download_url ? /* @__PURE__ */ (0, z.jsx)(Dy, {
+ children: [e.value, e.download_url ? /* @__PURE__ */ (0, z.jsx)(My, {
href: e.download_url,
children: e.download_label
}) : null]
}, e.term)) })
});
}
-function Pge({ uninstall: e, receipt: t }) {
+function Nge({ uninstall: e, receipt: t }) {
let [n, r] = (0, R.useState)(!1), [i, a] = (0, R.useState)(""), o = () => void b({
title: "卸载 Peach",
danger: !0,
@@ -48511,26 +48511,26 @@ function Pge({ uninstall: e, receipt: t }) {
a(e.message);
}
}), s = i || e.message, c = [.../* @__PURE__ */ new Set([e.data_root, ...e.directories])];
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
id: "uninstallPeach",
title: "卸载 Peach",
- children: [/* @__PURE__ */ (0, z.jsxs)(Sy, { children: [
- e.available ? /* @__PURE__ */ (0, z.jsx)(wy, { children: "卸载移除 Peach 程序本身,原始媒体文件保留。" }) : null,
- /* @__PURE__ */ (0, z.jsx)(SO, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(Dy, { children: [
+ e.available ? /* @__PURE__ */ (0, z.jsx)(ky, { children: "卸载移除 Peach 程序本身,原始媒体文件保留。" }) : null,
+ /* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: n,
isDisabled: !e.full_available || !!i,
onChange: r,
children: "完全卸载:同时删除设置、本地数据库、观看记录、凭据和缓存"
}),
- /* @__PURE__ */ (0, z.jsx)(Ay, {
+ /* @__PURE__ */ (0, z.jsx)(Fy, {
summary: "数据目录",
- children: c.map((e) => /* @__PURE__ */ (0, z.jsx)(pO, {
+ children: c.map((e) => /* @__PURE__ */ (0, z.jsx)(cO, {
path: e,
className: "text-body-2-regular text-text-secondary",
onRevealed: t
}, e))
})
- ] }), /* @__PURE__ */ (0, z.jsx)(Cy, {
+ ] }), /* @__PURE__ */ (0, z.jsx)(Oy, {
status: s ? /* @__PURE__ */ (0, z.jsx)("p", {
role: i ? "status" : void 0,
children: s
@@ -48546,7 +48546,7 @@ function Pge({ uninstall: e, receipt: t }) {
}
//#endregion
//#region src/react/settings/clouddrive-guide.tsx
-var Fge = [
+var Pge = [
{
name: "机械硬盘,或内存 8 GB 以内",
cache: "10–20 GiB",
@@ -48565,32 +48565,32 @@ var Fge = [
read: "256 / 128 KB",
task: "2 个起步"
}
-], Ige = [
+], Fge = [
["cache", "缓存上限"],
["read", "读取长度(默认 / 最小)"],
["task", "同时处理视频"]
];
-function Lge() {
+function Ige() {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "@container flex flex-col gap-3",
- children: [/* @__PURE__ */ (0, z.jsxs)(wy, { children: ["先在 CloudDrive 登录网盘并挂载,开启「启动时自动挂载」。", /* @__PURE__ */ (0, z.jsx)(Dy, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(ky, { children: ["先在 CloudDrive 登录网盘并挂载,开启「启动时自动挂载」。", /* @__PURE__ */ (0, z.jsx)(My, {
href: "https://www.clouddrive2.com/help.html",
children: "挂载帮助"
- })] }), /* @__PURE__ */ (0, z.jsxs)(Ay, {
+ })] }), /* @__PURE__ */ (0, z.jsxs)(Fy, {
summary: "CloudDrive 缓存建议",
children: [
- /* @__PURE__ */ (0, z.jsx)(wy, { children: "按缓存所在硬盘和可用内存选择起步值,再根据播放表现调整。" }),
+ /* @__PURE__ */ (0, z.jsx)(ky, { children: "按缓存所在硬盘和可用内存选择起步值,再根据播放表现调整。" }),
/* @__PURE__ */ (0, z.jsx)("ul", {
"aria-label": "按缓存所在硬盘分档",
className: "flex flex-col gap-2",
- children: Fge.map((e) => /* @__PURE__ */ (0, z.jsxs)("li", {
+ children: Pge.map((e) => /* @__PURE__ */ (0, z.jsxs)("li", {
className: "flex flex-col gap-2 rounded-2lg border border-separator-border bg-background-primary-default p-3",
children: [/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-medium text-text-primary",
children: e.name
}), /* @__PURE__ */ (0, z.jsx)("dl", {
className: "inline-grid grid-cols-1 gap-2 @md:grid-cols-3",
- children: Ige.map(([t, n]) => /* @__PURE__ */ (0, z.jsxs)("div", {
+ children: Fge.map(([t, n]) => /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col",
children: [/* @__PURE__ */ (0, z.jsx)("dt", {
className: "text-caption-1-regular text-text-secondary",
@@ -48611,9 +48611,9 @@ function Lge() {
/* @__PURE__ */ (0, z.jsx)("li", { children: "Buffer Cache 占内存,磁盘缓存和文件夹缓存占硬盘,改一个管不住另外两个。" })
]
}),
- /* @__PURE__ */ (0, z.jsxs)(wy, { children: [
+ /* @__PURE__ */ (0, z.jsxs)(ky, { children: [
"三处缓存的分工、往上调的方法和这些起步值的来源在",
- /* @__PURE__ */ (0, z.jsx)(Dy, {
+ /* @__PURE__ */ (0, z.jsx)(My, {
href: "https://github.com/longmeidao/peach/blob/master/docs/CLOUDDRIVE.md",
children: "CloudDrive 配置与调优"
}),
@@ -48625,7 +48625,7 @@ function Lge() {
}
//#endregion
//#region src/react/settings/download-settings.tsx
-var Rge = "/api/configuration/downloads", zge = "/api/configuration/downloads/check", Bge = "/api/configuration/downloads/pikpak/login", Vge = "/api/configuration/downloads/pikpak/logout";
+var Lge = "/api/configuration/downloads", Rge = "/api/configuration/downloads/check", zge = "/api/configuration/downloads/folder", Bge = "/api/configuration/downloads/pikpak/login", Vge = "/api/configuration/downloads/pikpak/logout";
function Hge({ initial: e, receipt: t }) {
let [n, r] = (0, R.useState)(e);
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(Uge, {
@@ -48639,30 +48639,71 @@ function Hge({ initial: e, receipt: t }) {
})] });
}
function Uge({ state: e, settle: t, receipt: n }) {
- let [r, i] = (0, R.useState)(e.config), [a, o] = (0, R.useState)(""), [s, c] = (0, R.useState)(String(e.config.wait_hours)), [l, u] = (0, R.useState)(null), [d, f] = (0, R.useState)(""), [p, m] = (0, R.useState)(""), h = aa(), g = (e) => r.targets[e] ?? "", _ = (e, t) => i({
+ let [r, i] = (0, R.useState)(e.config), [a, o] = (0, R.useState)(""), [s, c] = (0, R.useState)(String(e.config.wait_hours)), [l, u] = (0, R.useState)(null), [d, f] = (0, R.useState)(""), [p, m] = (0, R.useState)({
+ target: null,
+ root: ""
+ }), [h, g] = (0, R.useState)(""), _ = aa(), v = (e) => r.targets[e] ?? "", y = (e, t) => i({
...r,
targets: {
...r.targets,
[e]: t
}
- });
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ }), b = (e) => {
+ e.preventDefault();
+ let l = {
+ ...r,
+ wait_hours: s,
+ token: a
+ };
+ _.run("save", (e) => G(Lge, l, "POST", e), (e) => {
+ t(e), i(e.config), c(String(e.config.wait_hours)), o(""), g(""), n("已保存配置");
+ }, (e) => g(U(e)));
+ }, x = () => {
+ let e = !r.clouddrive_address.trim(), t = !v("115").trim(), n = !r.pikpak_root, o = {
+ clouddrive_address: r.clouddrive_address,
+ token: a,
+ target: v("115"),
+ pikpak_root: r.pikpak_root
+ };
+ _.run("check", (e) => G(Rge, o, "POST", e), (r) => {
+ let a = t ? r.suggested_target : null, o = n ? r.suggested_pikpak_root : "";
+ i((t) => ({
+ ...t,
+ clouddrive_address: e && r.address ? r.address : t.clouddrive_address,
+ targets: a ? {
+ ...t.targets,
+ 115: a.path
+ } : t.targets,
+ pikpak_root: o || t.pikpak_root
+ })), u(r), f(e ? r.address : ""), m({
+ target: a,
+ root: o
+ }), g("");
+ }, (e) => g(U(e)));
+ }, S = (e) => {
+ let t = {
+ clouddrive_address: r.clouddrive_address,
+ token: a,
+ path: e,
+ pikpak_root: r.pikpak_root
+ };
+ _.run("folder", (e) => G(zge, t, "POST", e), (t) => {
+ u(t), m((t) => ({
+ ...t,
+ target: {
+ path: e,
+ exists: !0
+ }
+ })), g(""), n("已新建目录");
+ }, (e) => g(U(e)));
+ }, C = p.target && !p.target.exists && v("115") === p.target.path;
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "云下载",
- onSubmit: (e) => {
- e.preventDefault();
- let l = {
- ...r,
- wait_hours: s,
- token: a
- };
- h.run("save", (e) => G(Rge, l, "POST", e), (e) => {
- t(e), i(e.config), c(String(e.config.wait_hours)), o(""), m(""), n("已保存配置");
- }, (e) => m(U(e)));
- },
+ onSubmit: b,
children: [
- /* @__PURE__ */ (0, z.jsxs)(Sy, { children: [
- /* @__PURE__ */ (0, z.jsx)(wy, { children: "把磁力交给 115 或 PikPak 离线下载,文件落在已挂载的网盘目录,再由推送发现登记入库,不经过这台电脑。 115 每个任务扣一条离线配额(年费会员每月 1500 条、月费 200 条),被判违规的资源不重试。" }),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsxs)(Dy, { children: [
+ /* @__PURE__ */ (0, z.jsx)(ky, { children: "把磁力交给 115 或 PikPak 离线下载,文件落在已挂载的网盘目录,再由推送发现登记入库,不经过这台电脑。 115 每个任务扣一条离线配额(年费会员每月 1500 条、月费 200 条),被判违规的资源不重试。" }),
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "CloudDrive2 地址",
placeholder: "留空自动探测本机 19798 / 29798",
autoComplete: "off",
@@ -48674,7 +48715,7 @@ function Uge({ state: e, settle: t, receipt: n }) {
clouddrive_address: e
})
}),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "CloudDrive2 API 令牌",
type: "password",
autoComplete: "off",
@@ -48685,44 +48726,46 @@ function Uge({ state: e, settle: t, receipt: n }) {
isDisabled: !e.available,
onChange: o
}),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "115 目标目录",
- placeholder: "/115/云下载",
+ placeholder: "检查时按推送发现自动填写",
autoComplete: "off",
maxLength: 300,
- hint: "CloudDrive2 挂载树里的路径。这个目录要落在「推送发现」的某个云端路径前缀下面,下载完才找得到。",
- value: g("115"),
+ validationBehavior: "aria",
+ isInvalid: !!C,
+ hint: C ? "CloudDrive2 里还没有这个目录。" : "CloudDrive2 挂载树里的路径,要落在「推送发现」的某个云端路径前缀下面,下载完才找得到。留空时点「检查」,按推送发现里 115 那条前缀填上「前缀/云下载」。",
+ value: v("115"),
isDisabled: !e.available,
- onChange: (e) => _("115", e)
+ onChange: (e) => y("115", e)
}),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "PikPak 目标目录",
placeholder: "/云下载",
autoComplete: "off",
maxLength: 300,
hint: "PikPak 网盘里的路径,目录要已经存在。",
- value: g("pikpak"),
+ value: v("pikpak"),
isDisabled: !e.available,
- onChange: (e) => _("pikpak", e)
+ onChange: (e) => y("pikpak", e)
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-1",
- children: [/* @__PURE__ */ (0, z.jsx)(Ey, { children: "PikPak 根目录对应的媒体文件夹" }), e.pikpak_roots.length ? /* @__PURE__ */ (0, z.jsx)(py, {
+ children: [/* @__PURE__ */ (0, z.jsx)(jy, { children: "PikPak 根目录对应的媒体文件夹" }), e.pikpak_roots.length ? /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "PikPak 根目录对应的媒体文件夹",
selectedKey: r.pikpak_root || null,
isDisabled: !e.available,
- placeholder: "选择媒体文件夹",
+ placeholder: "选择媒体文件夹,或点检查按推送发现选",
onSelectionChange: (e) => i({
...r,
pikpak_root: e === null ? "" : String(e)
}),
- children: e.pikpak_roots.map((e) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: e.pikpak_roots.map((e) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e,
children: e
}, e))
- }) : /* @__PURE__ */ (0, z.jsx)(wy, { children: "媒体文件夹里还没有「CloudDrive · PikPak」来源。在上方添加 PikPak 的挂载目录后,这里才能选。" })]
+ }) : /* @__PURE__ */ (0, z.jsx)(ky, { children: "媒体文件夹里还没有「CloudDrive · PikPak」来源。在上方添加 PikPak 的挂载目录后,这里才能选。" })]
}),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "等待上限(小时)",
type: "number",
inputMode: "numeric",
@@ -48735,67 +48778,76 @@ function Uge({ state: e, settle: t, receipt: n }) {
] }),
l ? /* @__PURE__ */ (0, z.jsx)(Wge, {
report: l,
- detected: d
+ detected: d,
+ suggested: p,
+ create: e.available ? S : void 0,
+ creating: _.busy === "folder"
}) : null,
- p || h.error ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ h || _.error ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
- children: /* @__PURE__ */ (0, z.jsx)(Ty, { children: p || h.error })
+ children: /* @__PURE__ */ (0, z.jsx)(Ay, { children: h || _.error })
}) : null,
- /* @__PURE__ */ (0, z.jsxs)(Cy, {
+ /* @__PURE__ */ (0, z.jsxs)(Oy, {
status: e.available ? void 0 : "云下载只在账本写入端可用。",
children: [/* @__PURE__ */ (0, z.jsx)(H, {
- onClick: () => {
- let e = !r.clouddrive_address.trim(), t = {
- clouddrive_address: r.clouddrive_address,
- token: a,
- target: g("115")
- };
- h.run("check", (e) => G(zge, t, "POST", e), (t) => {
- e && t.address && i((e) => ({
- ...e,
- clouddrive_address: t.address
- })), u(t), f(e ? t.address : ""), m("");
- }, (e) => m(U(e)));
- },
+ onClick: x,
disabled: !e.available,
- ...q(h.busy === "check"),
+ ...q(_.busy === "check"),
children: "检查"
}), /* @__PURE__ */ (0, z.jsx)(H, {
type: "submit",
disabled: !e.available,
- ...q(h.busy === "save"),
+ ...q(_.busy === "save"),
children: "保存配置"
})]
})
]
});
}
-function Wge({ report: e, detected: t }) {
- return /* @__PURE__ */ (0, z.jsxs)(Sy, {
+function Wge({ report: e, detected: t, suggested: n, create: r, creating: i }) {
+ let a = n.target;
+ return /* @__PURE__ */ (0, z.jsxs)(Dy, {
divided: !0,
- children: [/* @__PURE__ */ (0, z.jsxs)(Oy, { children: [
- t ? /* @__PURE__ */ (0, z.jsx)(ky, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(Ny, { children: [
+ t ? /* @__PURE__ */ (0, z.jsx)(Py, {
term: "CloudDrive2 地址",
children: `探测到 ${t},保存配置后生效`
}) : null,
- e.permissions.length ? /* @__PURE__ */ (0, z.jsx)(ky, {
+ a?.exists ? /* @__PURE__ */ (0, z.jsx)(Py, {
+ term: "115 目标目录",
+ children: `按推送发现填入 ${a.path},保存配置后生效`
+ }) : null,
+ a && !a.exists ? /* @__PURE__ */ (0, z.jsxs)(Py, {
+ term: "115 目标目录",
+ children: [`${a.path} 不存在`, r ? /* @__PURE__ */ (0, z.jsx)(H, {
+ size: "small",
+ onClick: () => r(a.path),
+ ...q(i),
+ children: "新建这个目录"
+ }) : null]
+ }) : null,
+ n.root ? /* @__PURE__ */ (0, z.jsx)(Py, {
+ term: "PikPak 根目录",
+ children: `按推送发现填入 ${n.root},保存配置后生效`
+ }) : null,
+ e.permissions.length ? /* @__PURE__ */ (0, z.jsx)(Py, {
term: "离线权限",
children: e.missing.length ? `缺少:${e.missing.join("、")}` : "齐全"
}) : null,
- e.folder ? /* @__PURE__ */ (0, z.jsx)(ky, {
+ e.folder ? /* @__PURE__ */ (0, z.jsx)(Py, {
term: "目标目录",
children: e.folder.can_offline ? `${e.folder.path} 可以离线下载` : `${e.folder.path} 不支持离线下载`
}) : null,
- e.quota ? /* @__PURE__ */ (0, z.jsx)(ky, {
+ e.quota ? /* @__PURE__ */ (0, z.jsx)(Py, {
term: "115 离线配额",
children: `本月还剩 ${e.quota.left} 条,共 ${e.quota.total} 条`
}) : null
- ] }), e.problems.map((e) => /* @__PURE__ */ (0, z.jsx)(Ty, { children: e }, e))]
+ ] }), e.problems.map((e) => /* @__PURE__ */ (0, z.jsx)(Ay, { children: e }, e))]
});
}
function Gge({ state: e, settle: t, receipt: n }) {
let [r, i] = (0, R.useState)(""), [a, o] = (0, R.useState)(""), [s, c] = (0, R.useState)(!1), [l, u] = (0, R.useState)(""), [d, f] = (0, R.useState)(""), p = aa(), m = e.pikpak;
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "PikPak 账号",
onSubmit: (e) => {
if (e.preventDefault(), m.logged_in) return;
@@ -48813,15 +48865,15 @@ function Gge({ state: e, settle: t, receipt: n }) {
}, (e) => f(U(e)));
},
children: [
- m.logged_in ? /* @__PURE__ */ (0, z.jsxs)(Oy, { children: [/* @__PURE__ */ (0, z.jsx)(ky, {
+ m.logged_in ? /* @__PURE__ */ (0, z.jsxs)(Ny, { children: [/* @__PURE__ */ (0, z.jsx)(Py, {
term: "账号",
children: m.username || "已登录"
- }), /* @__PURE__ */ (0, z.jsx)(ky, {
+ }), /* @__PURE__ */ (0, z.jsx)(Py, {
term: "密码",
children: m.remember ? "已保存,登录过期时自动重新登录" : "未保存,登录过期后需要回到这里重新登录"
- })] }) : /* @__PURE__ */ (0, z.jsxs)(Sy, { children: [
- /* @__PURE__ */ (0, z.jsx)(wy, { children: "PikPak 没有开放接口,Peach 照 PikPak 网页端的协议直连,接口变了就会报错,那时可以先复制磁力手动添加。 账号密码只用来换登录令牌,令牌存在这台电脑上。" }),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ })] }) : /* @__PURE__ */ (0, z.jsxs)(Dy, { children: [
+ /* @__PURE__ */ (0, z.jsx)(ky, { children: "PikPak 没有开放接口,Peach 照 PikPak 网页端的协议直连,接口变了就会报错,那时可以先复制磁力手动添加。 账号密码只用来换登录令牌,令牌存在这台电脑上。" }),
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "账号",
placeholder: "邮箱或手机号",
autoComplete: "username",
@@ -48830,7 +48882,7 @@ function Gge({ state: e, settle: t, receipt: n }) {
isDisabled: !e.available,
onChange: i
}),
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "密码",
type: "password",
autoComplete: "current-password",
@@ -48839,7 +48891,7 @@ function Gge({ state: e, settle: t, receipt: n }) {
isDisabled: !e.available,
onChange: o
}),
- /* @__PURE__ */ (0, z.jsx)(SO, {
+ /* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: s,
isDisabled: !e.available,
onChange: c,
@@ -48850,7 +48902,7 @@ function Gge({ state: e, settle: t, receipt: n }) {
title: "需要人机验证",
extra: /* @__PURE__ */ (0, z.jsx)("div", {
className: "pt-2",
- children: /* @__PURE__ */ (0, z.jsx)(Dy, {
+ children: /* @__PURE__ */ (0, z.jsx)(My, {
href: l,
children: "打开 PikPak 验证页"
})
@@ -48858,11 +48910,11 @@ function Gge({ state: e, settle: t, receipt: n }) {
children: "在浏览器里完成验证后,回到这里再点一次「登录」。"
}) : null
] }),
- d || p.error ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ d || p.error ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
- children: /* @__PURE__ */ (0, z.jsx)(Ty, { children: d || p.error })
+ children: /* @__PURE__ */ (0, z.jsx)(Ay, { children: d || p.error })
}) : null,
- /* @__PURE__ */ (0, z.jsx)(Cy, { children: m.logged_in ? /* @__PURE__ */ (0, z.jsx)(H, {
+ /* @__PURE__ */ (0, z.jsx)(Oy, { children: m.logged_in ? /* @__PURE__ */ (0, z.jsx)(H, {
onClick: () => {
p.run("logout", (e) => G(Vge, {}, "POST", e), (e) => {
t(e), f(""), n("已登出 PikPak");
@@ -48882,7 +48934,7 @@ function Gge({ state: e, settle: t, receipt: n }) {
}
//#endregion
//#region src/react/settings/library-icon-picker.tsx
-var iI = [
+var aI = [
["", "自动识别"],
["hard-drive", "磁盘"],
["database", "资料库"],
@@ -48930,7 +48982,7 @@ function Kge(e) {
let t = e === "local" ? "" : _[e];
return t ? [t, "自动识别"] : ["hard-drive", "默认"];
}
-var aI = "auto";
+var oI = "auto";
function qge({ value: e, label: t, kind: n = "local", onChange: r }) {
let i = (0, R.useRef)(null), [a, o] = (0, R.useState)(!1), [s, c] = (0, R.useState)(e), [l, u] = Kge(n);
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(H, {
@@ -48946,7 +48998,7 @@ function qge({ value: e, label: t, kind: n = "local", onChange: r }) {
children: /* @__PURE__ */ (0, z.jsxs)("span", {
"data-icon-choice": !0,
className: "flex items-center gap-2",
- children: [/* @__PURE__ */ (0, z.jsx)(jy, { mark: e || l }), ((e) => e && iI.find(([t]) => t === e)?.[1] || u)(e)]
+ children: [/* @__PURE__ */ (0, z.jsx)(Iy, { mark: e || l }), ((e) => e && aI.find(([t]) => t === e)?.[1] || u)(e)]
})
}), /* @__PURE__ */ (0, z.jsx)(zh, {
triggerRef: i,
@@ -48954,8 +49006,8 @@ function qge({ value: e, label: t, kind: n = "local", onChange: r }) {
onOpenChange: o,
placement: "bottom start",
offset: 4,
- className: ly,
- children: /* @__PURE__ */ (0, z.jsxs)(Fg, {
+ className: my,
+ children: /* @__PURE__ */ (0, z.jsxs)(Ig, {
"aria-label": `${t}候选`,
className: "flex w-72 flex-col gap-3 outline-none",
children: [
@@ -48964,17 +49016,17 @@ function qge({ value: e, label: t, kind: n = "local", onChange: r }) {
className: "px-1 text-body-medium text-text-primary",
children: "选择媒体库图标"
}),
- /* @__PURE__ */ (0, z.jsx)(E_, {
+ /* @__PURE__ */ (0, z.jsx)(D_, {
"aria-label": "候选图标",
- value: s || aI,
- onChange: (e) => c(e === aI ? "" : e),
+ value: s || oI,
+ onChange: (e) => c(e === oI ? "" : e),
className: "inline-grid grid-cols-7 gap-1",
- children: iI.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(D_, {
- value: e || aI,
+ children: aI.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(O_, {
+ value: e || oI,
"aria-label": e ? t : u,
className: "flex h-10 cursor-pointer items-center justify-center rounded-lg text-foreground-icon-secondary outline-none hover:bg-dropdown-item-hover-background focus-visible:ring-2 focus-visible:ring-border-focus-ring data-selected:bg-dropdown-item-hover-background data-selected:text-text-primary",
- children: /* @__PURE__ */ (0, z.jsx)(jy, { mark: e || l })
- }, e || aI))
+ children: /* @__PURE__ */ (0, z.jsx)(Iy, { mark: e || l })
+ }, e || oI))
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex justify-end gap-2 border-t border-separator-border pt-2.5",
@@ -48998,13 +49050,13 @@ function qge({ value: e, label: t, kind: n = "local", onChange: r }) {
//#region src/react/settings/push-discovery-settings.tsx
var Jge = "/api/configuration/push-discovery", Yge = "/api/configuration/push-discovery/secret";
function Xge({ initial: e, receipt: t }) {
- let [n, r] = (0, R.useState)(e), [i, a] = (0, R.useState)(e.prefixes), [o, s] = (0, R.useState)(""), c = aa(), l = uO(), u = n.media_roots, [d, f] = (0, R.useState)(e), p = (e, n) => {
+ let [n, r] = (0, R.useState)(e), [i, a] = (0, R.useState)(e.prefixes), [o, s] = (0, R.useState)(""), c = aa(), l = aO(), u = n.media_roots, [d, f] = (0, R.useState)(e), p = (e, n) => {
r(e), f(e), a(e.prefixes), s(""), t(n);
}, m = (e, t) => a((n) => n.map((n, r) => r === e ? {
...n,
...t
} : n));
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "推送发现",
onSubmit: (e) => {
e.preventDefault();
@@ -49017,11 +49069,11 @@ function Xge({ initial: e, receipt: t }) {
c.run("save", (e) => G(Jge, t, "POST", e), (e) => p(e, "已保存配置"), (e) => s(U(e)));
},
children: [
- /* @__PURE__ */ (0, z.jsxs)(xy, { children: [
- /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsxs)(Ey, { children: [
+ /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "新文件落地就入库",
description: "打开之后不必等下一轮扫描。定期全量扫描照常进行,漏掉的由它补上。",
- children: /* @__PURE__ */ (0, z.jsx)(GN, {
+ children: /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": "新文件落地就入库",
isSelected: n.enabled,
isDisabled: !n.available,
@@ -49031,10 +49083,10 @@ function Xge({ initial: e, receipt: t }) {
})
})
}),
- /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "监视本机文件夹",
description: "订阅本地来源的文件系统事件。网盘挂载不监视,因为遍历它就是走网络。",
- children: /* @__PURE__ */ (0, z.jsx)(GN, {
+ children: /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": "监视本机文件夹",
isSelected: n.watch_local,
isDisabled: !n.available || !n.enabled,
@@ -49044,10 +49096,10 @@ function Xge({ initial: e, receipt: t }) {
})
})
}),
- /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "接收 CloudDrive2 通知",
description: "由 CloudDrive2 把网盘里的新文件推给 Peach。只接受本机与局域网发来的请求。",
- children: /* @__PURE__ */ (0, z.jsx)(GN, {
+ children: /* @__PURE__ */ (0, z.jsx)(KN, {
"aria-label": "接收 CloudDrive2 通知",
isSelected: n.cloud,
isDisabled: !n.available || !n.enabled,
@@ -49058,30 +49110,30 @@ function Xge({ initial: e, receipt: t }) {
})
})
] }),
- d.enabled ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ d.enabled ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
- children: /* @__PURE__ */ (0, z.jsxs)(Oy, { children: [d.watch_local ? /* @__PURE__ */ (0, z.jsx)(ky, {
+ children: /* @__PURE__ */ (0, z.jsxs)(Ny, { children: [d.watch_local ? /* @__PURE__ */ (0, z.jsx)(Py, {
term: "本机文件夹监视",
children: d.local_running ? d.local_roots.join("、") : d.local_message || "没有运行"
- }) : null, /* @__PURE__ */ (0, z.jsx)(ky, {
+ }) : null, /* @__PURE__ */ (0, z.jsx)(Py, {
term: "已入库",
children: `${d.queue.ingested} 个文件,队列里还有 ${d.queue.pending} 条`
})] })
}) : null,
- d.enabled && d.cloud ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ d.enabled && d.cloud ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
children: /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-3",
children: [
- /* @__PURE__ */ (0, z.jsx)(Ey, { children: "CloudDrive2 配置内容" }),
- /* @__PURE__ */ (0, z.jsx)(wy, { children: "Webhook 需要 CloudDrive2 会员;非会员的配置即使显示有效,也不会发送通知。 在「设置 → Webhooks」中添加配置,粘贴下方内容并保存。地址和密钥已填好;更换密钥后需重新复制。 Windows 桌面版若因换行问题显示「无效」,将配置保存为 .toml 文件,放入 %LOCALAPPDATA%\\CloudDrive.WinUI\\webhooks\\ 目录。" }),
+ /* @__PURE__ */ (0, z.jsx)(jy, { children: "CloudDrive2 配置内容" }),
+ /* @__PURE__ */ (0, z.jsx)(ky, { children: "Webhook 需要 CloudDrive2 会员;非会员的配置即使显示有效,也不会发送通知。 在「设置 → Webhooks」中添加配置,粘贴下方内容并保存。地址和密钥已填好;更换密钥后需重新复制。 Windows 桌面版若因换行问题显示「无效」,将配置保存为 .toml 文件,放入 %LOCALAPPDATA%\\CloudDrive.WinUI\\webhooks\\ 目录。" }),
d.config_toml ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("div", { children: /* @__PURE__ */ (0, z.jsx)(H, {
size: "small",
onClick: () => {
navigator.clipboard.writeText(d.config_toml).then(() => t("已复制 CloudDrive2 配置"), () => s("浏览器没让这一页写剪贴板,展开「查看这段配置」选中自己复制。"));
},
children: "复制配置"
- }) }), /* @__PURE__ */ (0, z.jsx)(Ay, {
+ }) }), /* @__PURE__ */ (0, z.jsx)(Fy, {
summary: "查看这段配置",
children: /* @__PURE__ */ (0, z.jsx)("div", {
className: "relative",
@@ -49092,17 +49144,17 @@ function Xge({ initial: e, receipt: t }) {
children: d.config_toml
})
})
- })] }) : /* @__PURE__ */ (0, z.jsx)(wy, { children: d.origin ? "尚未生成共享密钥,请保存配置后复制。" : "请先配置 CloudDrive2 能访问的 HTTPS 地址,再生成通知配置。HTTP 地址不接受通知写入,也不会自动转发。" })
+ })] }) : /* @__PURE__ */ (0, z.jsx)(ky, { children: d.origin ? "尚未生成共享密钥,请保存配置后复制。" : "请先配置 CloudDrive2 能访问的 HTTPS 地址,再生成通知配置。HTTP 地址不接受通知写入,也不会自动转发。" })
]
})
}) : null,
- n.enabled && n.cloud ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ n.enabled && n.cloud ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
children: /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-3",
children: [
- /* @__PURE__ */ (0, z.jsx)(Ey, { children: "云端路径前缀" }),
- /* @__PURE__ */ (0, z.jsx)(wy, { children: "左侧填写 CloudDrive2 中的目录前缀,右侧选择对应的媒体文件夹。 Peach 按此对应关系定位通知中的文件。" }),
+ /* @__PURE__ */ (0, z.jsx)(jy, { children: "云端路径前缀" }),
+ /* @__PURE__ */ (0, z.jsx)(ky, { children: "左侧填写 CloudDrive2 中的目录前缀,右侧选择对应的媒体文件夹。 Peach 按此对应关系定位通知中的文件。" }),
/* @__PURE__ */ (0, z.jsx)("div", {
role: "group",
"aria-label": "云端路径前缀",
@@ -49110,7 +49162,7 @@ function Xge({ initial: e, receipt: t }) {
children: i.map((e, t) => /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex items-start gap-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
className: "min-w-0 flex-1",
"aria-label": `云端路径前缀 ${t + 1}`,
placeholder: "/115",
@@ -49119,18 +49171,18 @@ function Xge({ initial: e, receipt: t }) {
value: e.prefix,
onChange: (e) => m(t, { prefix: e })
}),
- /* @__PURE__ */ (0, z.jsx)(py, {
+ /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": `前缀 ${t + 1} 对应的媒体根`,
selectedKey: e.root,
onSelectionChange: (e) => {
e !== null && m(t, { root: String(e) });
},
- children: u.map((e) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: u.map((e) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e,
children: e
}, e))
}),
- /* @__PURE__ */ (0, z.jsx)(fO, {
+ /* @__PURE__ */ (0, z.jsx)(sO, {
icon: Xe,
"aria-label": "移除这一条",
onClick: () => a((e) => e.filter((e, n) => n !== t))
@@ -49149,11 +49201,11 @@ function Xge({ initial: e, receipt: t }) {
]
})
}) : null,
- o || c.error ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ o || c.error ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
- children: /* @__PURE__ */ (0, z.jsx)(Ty, { children: o || c.error })
+ children: /* @__PURE__ */ (0, z.jsx)(Ay, { children: o || c.error })
}) : null,
- /* @__PURE__ */ (0, z.jsxs)(Cy, {
+ /* @__PURE__ */ (0, z.jsxs)(Oy, {
status: d.enabled && d.cloud ? "换过密钥之后,CloudDrive2 那一侧要重新贴一次配置,否则它推来的一律被拒。" : void 0,
children: [d.enabled && d.cloud ? /* @__PURE__ */ (0, z.jsx)(H, {
onClick: () => {
@@ -49188,11 +49240,11 @@ function Qge({ className: e }) {
children: /* @__PURE__ */ (0, z.jsx)("use", { href: "#i-folder-search" })
});
}
-var oI = [
+var sI = [
["local", "本地磁盘"],
["115", "CloudDrive · 115"],
["pikpak", "CloudDrive · PikPak"]
-], $ge = (e) => oI.find(([t]) => t === e)?.[1] ?? e, sI = (e) => _[e] || "database", cI = (e = "") => ({
+], $ge = (e) => sI.find(([t]) => t === e)?.[1] ?? e, cI = (e) => _[e] || "database", lI = (e = "") => ({
path: e,
location: "local",
root: "",
@@ -49200,14 +49252,14 @@ var oI = [
library_icon: ""
});
function e_e(e) {
- let t = e.media_sources?.filter((e) => oI.some(([t]) => t === e.location));
+ let t = e.media_sources?.filter((e) => sI.some(([t]) => t === e.location));
return t?.length ? t.map((e) => ({
path: e.path,
location: e.location,
root: e.root,
library: e.library || "",
library_icon: e.library_icon || ""
- })) : (e.media_dirs.length ? e.media_dirs : [""]).map((e) => cI(e));
+ })) : (e.media_dirs.length ? e.media_dirs : [""]).map((e) => lI(e));
}
var t_e = (e) => !(e instanceof Hi) || e.status !== 400 ? null : e.body?.errors ?? null;
function n_e({ data: e, receipt: t }) {
@@ -49251,14 +49303,14 @@ function r_e({ data: e, receipt: t }) {
for (; r.length <= e;) r.push("");
return r[e] = t, r;
}), E = () => {
- _(n.length), r((e) => [...e, cI()]);
+ _(n.length), r((e) => [...e, lI()]);
}, D = (e) => {
r((t) => t.filter((t, n) => n !== e)), l((t) => t.filter((t, n) => n !== e));
}, O = async (e) => {
if (!b.current) {
b.current = !0, y(e);
try {
- let { path: t } = await G(xge, { initial: n[e]?.path ?? "" });
+ let { path: t } = await G(bge, { initial: n[e]?.path ?? "" });
t && (w(e, { path: t }), T(e, ""));
} catch (t) {
T(e, U(t));
@@ -49267,7 +49319,7 @@ function r_e({ data: e, receipt: t }) {
}
}
}, k = (r) => {
- r.preventDefault(), p(""), C.run("save", (t) => G(QF, {
+ r.preventDefault(), p(""), C.run("save", (t) => G($F, {
revision: x.current,
media_dirs: n.map((e) => e.path),
...e.media_sources ? { media_sources: n } : {},
@@ -49280,14 +49332,14 @@ function r_e({ data: e, receipt: t }) {
l(t?.media_dirs ?? []), d(t?.port ?? ""), t || p(U(e));
});
};
- if (m) return /* @__PURE__ */ (0, z.jsx)(by, {
+ if (m) return /* @__PURE__ */ (0, z.jsx)(Ty, {
title: "这台电脑",
- children: /* @__PURE__ */ (0, z.jsx)(Sy, { children: /* @__PURE__ */ (0, z.jsxs)(K, {
+ children: /* @__PURE__ */ (0, z.jsx)(Dy, { children: /* @__PURE__ */ (0, z.jsxs)(K, {
tone: "success",
title: "配置已保存",
children: [
"Peach 正在重新启动。稍后自动跳转,或点击",
- /* @__PURE__ */ (0, z.jsx)(yy, {
+ /* @__PURE__ */ (0, z.jsx)(wy, {
href: m.url,
size: "small",
children: "进入馆藏"
@@ -49297,14 +49349,14 @@ function r_e({ data: e, receipt: t }) {
}) })
});
let A = n.some((e) => e.location === "115" || e.location === "pikpak"), j = A ? (e.mount_dependencies ?? []).filter((e) => !e.available) : [];
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "这台电脑",
onSubmit: k,
- children: [/* @__PURE__ */ (0, z.jsxs)(Sy, { children: [
+ children: [/* @__PURE__ */ (0, z.jsxs)(Dy, { children: [
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-3",
children: [
- /* @__PURE__ */ (0, z.jsx)(Ey, { children: "媒体文件夹" }),
+ /* @__PURE__ */ (0, z.jsx)(jy, { children: "媒体文件夹" }),
/* @__PURE__ */ (0, z.jsx)("div", {
role: "group",
"aria-label": "媒体文件夹",
@@ -49315,7 +49367,7 @@ function r_e({ data: e, receipt: t }) {
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex items-start gap-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
className: "min-w-0 flex-1",
"aria-label": `媒体文件夹 ${r + 1}`,
placeholder: "本机文件夹路径",
@@ -49328,13 +49380,13 @@ function r_e({ data: e, receipt: t }) {
isInvalid: !!c[r],
hint: c[r] || void 0
}),
- /* @__PURE__ */ (0, z.jsx)(fO, {
+ /* @__PURE__ */ (0, z.jsx)(sO, {
icon: Qge,
"aria-label": "选择文件夹",
onClick: () => void O(r),
...q(v === r)
}),
- n.length > 1 ? /* @__PURE__ */ (0, z.jsx)(fO, {
+ n.length > 1 ? /* @__PURE__ */ (0, z.jsx)(sO, {
icon: Xe,
"aria-label": "移除这个文件夹",
onClick: () => D(r)
@@ -49343,7 +49395,7 @@ function r_e({ data: e, receipt: t }) {
}), /* @__PURE__ */ (0, z.jsxs)("div", {
className: "inline-grid grid-cols-1 gap-3 @lg:grid-cols-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(py, {
label: "媒体库名称",
maxLength: 80,
placeholder: "同名文件夹归入同一个媒体库",
@@ -49352,7 +49404,7 @@ function r_e({ data: e, receipt: t }) {
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-1.5",
- children: [/* @__PURE__ */ (0, z.jsx)(Ey, { children: "媒体库图标" }), /* @__PURE__ */ (0, z.jsx)(qge, {
+ children: [/* @__PURE__ */ (0, z.jsx)(jy, { children: "媒体库图标" }), /* @__PURE__ */ (0, z.jsx)(qge, {
label: `媒体库图标 ${r + 1}`,
value: t.library_icon,
kind: t.location,
@@ -49361,20 +49413,20 @@ function r_e({ data: e, receipt: t }) {
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-1.5",
- children: [/* @__PURE__ */ (0, z.jsx)(Ey, { children: "媒体来源" }), /* @__PURE__ */ (0, z.jsx)(py, {
+ children: [/* @__PURE__ */ (0, z.jsx)(jy, { children: "媒体来源" }), /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": `媒体来源 ${r + 1}`,
selectedKey: t.location,
onSelectionChange: (e) => {
e !== null && w(r, { location: String(e) });
},
- children: oI.map(([e, t]) => /* @__PURE__ */ (0, z.jsxs)(my, {
+ children: sI.map(([e, t]) => /* @__PURE__ */ (0, z.jsxs)(yy, {
id: e,
textValue: t,
- children: [/* @__PURE__ */ (0, z.jsx)(jy, { mark: sI(e) }), t]
+ children: [/* @__PURE__ */ (0, z.jsx)(Iy, { mark: cI(e) }), t]
}, e))
})]
}),
- e.windows === !1 ? /* @__PURE__ */ (0, z.jsx)(cy, {
+ e.windows === !1 ? /* @__PURE__ */ (0, z.jsx)(py, {
label: "Windows 中的对应路径",
placeholder: "例如 B:\\",
value: t.root,
@@ -49391,18 +49443,18 @@ function r_e({ data: e, receipt: t }) {
})
]
}),
- A ? /* @__PURE__ */ (0, z.jsx)(Lge, {}) : null,
- j.map((e) => /* @__PURE__ */ (0, z.jsxs)(wy, { children: [
+ A ? /* @__PURE__ */ (0, z.jsx)(Ige, {}) : null,
+ j.map((e) => /* @__PURE__ */ (0, z.jsxs)(ky, { children: [
"未检测到 ",
e.name,
"。",
- /* @__PURE__ */ (0, z.jsxs)(Dy, {
+ /* @__PURE__ */ (0, z.jsxs)(My, {
href: e.download_url,
children: ["下载 ", e.name]
})
] }, e.name)),
- e.windows === !1 ? /* @__PURE__ */ (0, z.jsx)(wy, { children: "本机文件夹是这台电脑读取媒体的位置。Windows 中的对应路径用于匹配馆藏中已有的路径,例如 B:\\ 对应本机挂载文件夹。" }) : null,
- e.port_editable === !1 ? null : /* @__PURE__ */ (0, z.jsx)(cy, {
+ e.windows === !1 ? /* @__PURE__ */ (0, z.jsx)(ky, { children: "本机文件夹是这台电脑读取媒体的位置。Windows 中的对应路径用于匹配馆藏中已有的路径,例如 B:\\ 对应本机挂载文件夹。" }) : null,
+ e.port_editable === !1 ? null : /* @__PURE__ */ (0, z.jsx)(py, {
id: "configPort",
label: "本机访问端口",
inputMode: "numeric",
@@ -49412,7 +49464,7 @@ function r_e({ data: e, receipt: t }) {
isInvalid: !!u,
hint: u || "浏览器地址里冒号后面的数字,一般不用改。"
}),
- /* @__PURE__ */ (0, z.jsx)(SO, {
+ /* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: o,
onChange: s,
children: "保存后扫描并补全资料"
@@ -49422,7 +49474,7 @@ function r_e({ data: e, receipt: t }) {
title: "没有保存",
children: f
}) : null
- ] }), /* @__PURE__ */ (0, z.jsx)(Cy, {
+ ] }), /* @__PURE__ */ (0, z.jsx)(Oy, {
status: e.port_editable === !1 ? "保存后 Peach 会重新载入配置。" : "保存后 Peach 会重新启动,端口改了就用新地址打开。",
children: /* @__PURE__ */ (0, z.jsx)(H, {
type: "submit",
@@ -49458,19 +49510,19 @@ function i_e({ online: e }) {
}
function a_e({ data: e }) {
let t = e.media_sources, n = aa();
- return t ? /* @__PURE__ */ (0, z.jsxs)(by, {
+ return t ? /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "挂载状态",
children: [
- /* @__PURE__ */ (0, z.jsx)(Oy, { children: t.map((e, t) => /* @__PURE__ */ (0, z.jsxs)(ky, {
- term: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(jy, { mark: sI(e.location) }), $ge(e.location)] }),
+ /* @__PURE__ */ (0, z.jsx)(Ny, { children: t.map((e, t) => /* @__PURE__ */ (0, z.jsxs)(Py, {
+ term: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(Iy, { mark: cI(e.location) }), $ge(e.location)] }),
children: [e.path || "未配置挂载点", /* @__PURE__ */ (0, z.jsx)(i_e, { online: e.online })]
}, t)) }),
- n.error ? /* @__PURE__ */ (0, z.jsx)(Sy, {
+ n.error ? /* @__PURE__ */ (0, z.jsx)(Dy, {
divided: !0,
- children: /* @__PURE__ */ (0, z.jsx)(Ty, { children: n.error })
+ children: /* @__PURE__ */ (0, z.jsx)(Ay, { children: n.error })
}) : null,
- /* @__PURE__ */ (0, z.jsx)(Cy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
- onClick: () => void n.run("refresh", (e) => eI(e), (e) => X.setQueryData($F, e)),
+ /* @__PURE__ */ (0, z.jsx)(Oy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
+ onClick: () => void n.run("refresh", (e) => tI(e), (e) => X.setQueryData(eI, e)),
...q(n.busy === "refresh"),
children: "刷新挂载状态"
}) })
@@ -49506,24 +49558,24 @@ function s_e({ initial: e, receipt: t }) {
n ? p(n) : h.setError(U(e));
});
}, _ = o_e[n.mode], v = n.mode !== "locked";
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "访问密码",
onSubmit: g,
children: [/* @__PURE__ */ (0, z.jsx)("div", {
ref: m,
- children: /* @__PURE__ */ (0, z.jsxs)(Sy, { children: [
- _ ? /* @__PURE__ */ (0, z.jsx)(wy, { children: _ }) : null,
+ children: /* @__PURE__ */ (0, z.jsxs)(Dy, { children: [
+ _ ? /* @__PURE__ */ (0, z.jsx)(ky, { children: _ }) : null,
n.mode === "open" ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "warning",
title: "未设置访问密码",
children: "能连接到 Peach 的设备打开地址就能看馆藏,不需要登录。"
}) : null,
- n.mode === "password" || n.mode === "legacy" ? /* @__PURE__ */ (0, z.jsx)(SO, {
+ n.mode === "password" || n.mode === "legacy" ? /* @__PURE__ */ (0, z.jsx)(_O, {
isSelected: u,
onChange: d,
children: "关闭访问密码"
}) : null,
- n.mode === "password" ? /* @__PURE__ */ (0, z.jsx)(cy, {
+ n.mode === "password" ? /* @__PURE__ */ (0, z.jsx)(py, {
id: "access-current",
type: "password",
label: "当前访问密码",
@@ -49536,7 +49588,7 @@ function s_e({ initial: e, receipt: t }) {
isInvalid: !!f.current_password,
hint: f.current_password
}) : null,
- v ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(cy, {
+ v ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(py, {
id: "access-password",
type: "password",
label: n.mode === "password" ? "新访问密码" : "设置访问密码",
@@ -49549,7 +49601,7 @@ function s_e({ initial: e, receipt: t }) {
validationBehavior: "aria",
isInvalid: !u && !!f.password,
hint: u ? "关闭访问密码时无需填写。" : f.password || "至少 8 个字符。保存后其他设备需要重新登录。"
- }), /* @__PURE__ */ (0, z.jsx)(cy, {
+ }), /* @__PURE__ */ (0, z.jsx)(py, {
id: "access-confirm",
type: "password",
label: "确认访问密码",
@@ -49568,9 +49620,9 @@ function s_e({ initial: e, receipt: t }) {
title: "访问范围",
children: "保存后,能连接到 Peach 的设备将直接访问馆藏。"
}) : null,
- h.error ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: h.error }) : null
+ h.error ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: h.error }) : null
] })
- }), v ? /* @__PURE__ */ (0, z.jsx)(Cy, {
+ }), v ? /* @__PURE__ */ (0, z.jsx)(Oy, {
status: "保存后立即生效。",
children: /* @__PURE__ */ (0, z.jsx)(H, {
type: "submit",
@@ -49591,8 +49643,8 @@ function d_e({ revision: e, initial: t, receipt: n }) {
(0, R.useEffect)(() => {
if (r.state !== "starting") return;
let e = new AbortController(), t = window.setInterval(() => {
- eI(e.signal).then((t) => {
- e.signal.aborted || !t.tunnel || (X.setQueryData($F, t), i(t.tunnel), o(t.revision));
+ tI(e.signal).then((t) => {
+ e.signal.aborted || !t.tunnel || (X.setQueryData(eI, t), i(t.tunnel), o(t.revision));
}).catch(() => void 0);
}, c_e);
return () => {
@@ -49613,26 +49665,26 @@ function d_e({ revision: e, initial: t, receipt: n }) {
n ? m(n) : h.setError(U(e));
});
};
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
title: "Cloudflare 公网入口",
onSubmit: (e) => {
e.preventDefault(), v("save", g, () => n("已保存配置"));
},
- children: [/* @__PURE__ */ (0, z.jsxs)(Sy, { children: [
- r.named_available ? /* @__PURE__ */ (0, z.jsx)($O, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(Dy, { children: [
+ r.named_available ? /* @__PURE__ */ (0, z.jsx)(GO, {
"aria-label": "公网入口的形态(二选一)",
value: s,
isDisabled: g,
onChange: (e) => c(e),
- className: ek,
- children: l_e.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(D_, {
+ className: KO,
+ children: l_e.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(O_, {
value: e,
- className: tk,
+ className: qO,
children: t
}, e))
}) : null,
- /* @__PURE__ */ (0, z.jsx)(wy, { children: u_e[_ ? "named" : "quick"] }),
- _ ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(cy, {
+ /* @__PURE__ */ (0, z.jsx)(ky, { children: u_e[_ ? "named" : "quick"] }),
+ _ ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(py, {
id: "tunnel-hostname",
label: "公开主机名",
autoComplete: "off",
@@ -49643,7 +49695,7 @@ function d_e({ revision: e, initial: t, receipt: n }) {
validationBehavior: "aria",
isInvalid: !!p.hostname,
hint: p.hostname || "在 Cloudflare Zero Trust 里指向本机 origin 的那个主机名。"
- }), /* @__PURE__ */ (0, z.jsx)(cy, {
+ }), /* @__PURE__ */ (0, z.jsx)(py, {
id: "tunnel-token",
type: "password",
label: "隧道令牌",
@@ -49663,7 +49715,7 @@ function d_e({ revision: e, initial: t, receipt: n }) {
r.state === "running" && r.url ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "info",
title: "公网地址",
- children: /* @__PURE__ */ (0, z.jsx)(Dy, {
+ children: /* @__PURE__ */ (0, z.jsx)(My, {
href: r.url,
children: r.url
})
@@ -49673,9 +49725,9 @@ function d_e({ revision: e, initial: t, receipt: n }) {
title: "正在连接",
children: "正在等待 cloudflared 连上 Cloudflare 边缘。"
}) : null,
- r.error ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: r.error }) : null,
- h.error ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: h.error }) : null
- ] }), /* @__PURE__ */ (0, z.jsxs)(Cy, {
+ r.error ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: r.error }) : null,
+ h.error ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: h.error }) : null
+ ] }), /* @__PURE__ */ (0, z.jsxs)(Oy, {
status: r.enabled ? "服务重启时会按设置尝试恢复。" : "服务重启后保持关闭。",
children: [/* @__PURE__ */ (0, z.jsx)(H, {
onClick: () => v("toggle", !g, (e) => n(e.enabled ? "公网入口已启动" : "公网入口已停止")),
@@ -49718,7 +49770,7 @@ function p_e({ data: e, receipt: t }) {
}
function m_e({ initial: e, receipt: t }) {
let [n, r] = (0, R.useState)(e), [i, a] = (0, R.useState)(e.mode), [o, s] = (0, R.useState)(""), c = aa();
- return /* @__PURE__ */ (0, z.jsxs)(by, {
+ return /* @__PURE__ */ (0, z.jsxs)(Ty, {
id: "peachProxy",
title: "Peach 代理",
onSubmit: (e) => {
@@ -49730,25 +49782,25 @@ function m_e({ initial: e, receipt: t }) {
});
},
children: [
- /* @__PURE__ */ (0, z.jsx)(xy, { children: /* @__PURE__ */ (0, z.jsx)(_y, {
+ /* @__PURE__ */ (0, z.jsx)(Ey, { children: /* @__PURE__ */ (0, z.jsx)(Sy, {
label: "连接方式",
description: "采集来源选「Peach 代理」时共用这里的连接方式。",
- children: /* @__PURE__ */ (0, z.jsx)(py, {
+ children: /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "连接方式",
selectedKey: i,
onSelectionChange: (e) => {
e !== null && a(String(e));
},
- children: f_e.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: f_e.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e,
children: t
}, e))
})
}) }),
- i === "proxy" || n.needs_selection || c.error ? /* @__PURE__ */ (0, z.jsxs)(Sy, {
+ i === "proxy" || n.needs_selection || c.error ? /* @__PURE__ */ (0, z.jsxs)(Dy, {
divided: !0,
children: [
- i === "proxy" ? /* @__PURE__ */ (0, z.jsx)(cy, {
+ i === "proxy" ? /* @__PURE__ */ (0, z.jsx)(py, {
id: "peachProxyAddress",
type: "password",
label: "代理地址",
@@ -49762,10 +49814,10 @@ function m_e({ initial: e, receipt: t }) {
title: "需要选择连接方式",
children: "已有来源的代理地址不同,请选择公共连接方式。"
}) : null,
- c.error ? /* @__PURE__ */ (0, z.jsx)(Ty, { children: c.error }) : null
+ c.error ? /* @__PURE__ */ (0, z.jsx)(Ay, { children: c.error }) : null
]
}) : null,
- /* @__PURE__ */ (0, z.jsx)(Cy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
+ /* @__PURE__ */ (0, z.jsx)(Oy, { children: /* @__PURE__ */ (0, z.jsx)(H, {
type: "submit",
...q(c.busy === "save"),
children: "保存配置"
@@ -49777,8 +49829,8 @@ function m_e({ initial: e, receipt: t }) {
//#region src/react/settings/configuration-page.tsx
function h_e({ receipt: e, reopenTutorial: t }) {
let n = $n({
- queryKey: $F,
- queryFn: ({ signal: e }) => eI(e)
+ queryKey: eI,
+ queryFn: ({ signal: e }) => tI(e)
}), r = n.data;
if (!r) return /* @__PURE__ */ (0, z.jsx)("div", {
className: "configpage",
@@ -49799,7 +49851,7 @@ function h_e({ receipt: e, reopenTutorial: t }) {
className: "configgroup",
children: "通用"
}) : null,
- a ? /* @__PURE__ */ (0, z.jsx)(Tge, { ...i }) : null,
+ a ? /* @__PURE__ */ (0, z.jsx)(wge, { ...i }) : null,
/* @__PURE__ */ (0, z.jsx)("h2", {
className: "configgroup",
children: "媒体"
@@ -49814,7 +49866,7 @@ function h_e({ receipt: e, reopenTutorial: t }) {
className: "configgroup",
children: "更新与维护"
}),
- /* @__PURE__ */ (0, z.jsx)(Age, {
+ /* @__PURE__ */ (0, z.jsx)(kge, {
...i,
reopenTutorial: t
})
@@ -49823,14 +49875,14 @@ function h_e({ receipt: e, reopenTutorial: t }) {
}
//#endregion
//#region src/react/stats/stats.ts
-var g_e = "/api/stats", lI = ["stats"], uI = (e) => W(g_e, e);
+var g_e = "/api/stats", uI = ["stats"], dI = (e) => W(g_e, e);
async function __e(e) {
await X.fetchQuery({
- queryKey: lI,
- queryFn: () => uI(e)
+ queryKey: uI,
+ queryFn: () => dI(e)
});
}
-var dI = (e, t) => t ? Math.round(e / t * 100) : 0, v_e = (e) => e >= 3600 ? `${(e / 3600).toFixed(1)} 小时` : `${Math.round(e / 60)} 分钟`, fI = (e) => e.duration ? Math.min(e.play_seconds / e.duration, 1) * 100 : 0, pI = (e) => (e.max_reached || 0) * 100, y_e = (e) => e.kind === "online" ? "在线直接观看" : fI(e) < pI(e) - 25 ? "快进扫过" : e.o_count ? `高潮 ${e.o_count}` : "正常观看", b_e = (e) => `${e.kind === "online" ? "/follow/item/" : "/item/"}${e.id}`, x_e = (e) => Math.max(1, ...e) * 1.1, S_e = (e) => Math.max(4, Math.min(14, Math.round(90 / Math.max(1, e)))), C_e = {
+var fI = (e, t) => t ? Math.round(e / t * 100) : 0, v_e = (e) => e >= 3600 ? `${(e / 3600).toFixed(1)} 小时` : `${Math.round(e / 60)} 分钟`, pI = (e) => e.duration ? Math.min(e.play_seconds / e.duration, 1) * 100 : 0, mI = (e) => (e.max_reached || 0) * 100, y_e = (e) => e.kind === "online" ? "在线直接观看" : pI(e) < mI(e) - 25 ? "快进扫过" : e.o_count ? `高潮 ${e.o_count}` : "正常观看", b_e = (e) => `${e.kind === "online" ? "/follow/item/" : "/item/"}${e.id}`, x_e = (e) => Math.max(1, ...e) * 1.1, S_e = (e) => Math.max(4, Math.min(14, Math.round(90 / Math.max(1, e)))), C_e = {
video: "视频",
image: "图片",
illustration: "插画",
@@ -49846,10 +49898,10 @@ var dI = (e, t) => t ? Math.round(e / t * 100) : 0, v_e = (e) => e >= 3600 ? `${
短: "5–15 分钟",
中: "15–40 分钟",
长: ">40 分钟"
-}, mI = (e, t = {}) => e.map((e) => ({
+}, hI = (e, t = {}) => e.map((e) => ({
name: t[e.k] ?? e.k,
value: e.n
-})), E_e = (e) => mI(e, T_e), D_e = [
+})), E_e = (e) => hI(e, T_e), D_e = [
[
1,
1,
@@ -49889,41 +49941,41 @@ var dI = (e, t) => t ? Math.round(e / t * 100) : 0, v_e = (e) => e >= 3600 ? `${
name: r,
value: e.filter((e) => e.k >= t && e.k <= n).reduce((e, t) => e + t.n, 0)
})), k_e = /* @__PURE__ */ "dangerouslySetInnerHTML.onCopy.onCopyCapture.onCut.onCutCapture.onPaste.onPasteCapture.onCompositionEnd.onCompositionEndCapture.onCompositionStart.onCompositionStartCapture.onCompositionUpdate.onCompositionUpdateCapture.onFocus.onFocusCapture.onBlur.onBlurCapture.onChange.onChangeCapture.onBeforeInput.onBeforeInputCapture.onInput.onInputCapture.onReset.onResetCapture.onSubmit.onSubmitCapture.onInvalid.onInvalidCapture.onLoad.onLoadCapture.onError.onErrorCapture.onKeyDown.onKeyDownCapture.onKeyPress.onKeyPressCapture.onKeyUp.onKeyUpCapture.onAbort.onAbortCapture.onCanPlay.onCanPlayCapture.onCanPlayThrough.onCanPlayThroughCapture.onDurationChange.onDurationChangeCapture.onEmptied.onEmptiedCapture.onEncrypted.onEncryptedCapture.onEnded.onEndedCapture.onLoadedData.onLoadedDataCapture.onLoadedMetadata.onLoadedMetadataCapture.onLoadStart.onLoadStartCapture.onPause.onPauseCapture.onPlay.onPlayCapture.onPlaying.onPlayingCapture.onProgress.onProgressCapture.onRateChange.onRateChangeCapture.onSeeked.onSeekedCapture.onSeeking.onSeekingCapture.onStalled.onStalledCapture.onSuspend.onSuspendCapture.onTimeUpdate.onTimeUpdateCapture.onVolumeChange.onVolumeChangeCapture.onWaiting.onWaitingCapture.onAuxClick.onAuxClickCapture.onClick.onClickCapture.onContextMenu.onContextMenuCapture.onDoubleClick.onDoubleClickCapture.onDrag.onDragCapture.onDragEnd.onDragEndCapture.onDragEnter.onDragEnterCapture.onDragExit.onDragExitCapture.onDragLeave.onDragLeaveCapture.onDragOver.onDragOverCapture.onDragStart.onDragStartCapture.onDrop.onDropCapture.onMouseDown.onMouseDownCapture.onMouseEnter.onMouseLeave.onMouseMove.onMouseMoveCapture.onMouseOut.onMouseOutCapture.onMouseOver.onMouseOverCapture.onMouseUp.onMouseUpCapture.onSelect.onSelectCapture.onTouchCancel.onTouchCancelCapture.onTouchEnd.onTouchEndCapture.onTouchMove.onTouchMoveCapture.onTouchStart.onTouchStartCapture.onPointerDown.onPointerDownCapture.onPointerMove.onPointerMoveCapture.onPointerUp.onPointerUpCapture.onPointerCancel.onPointerCancelCapture.onPointerEnter.onPointerEnterCapture.onPointerLeave.onPointerLeaveCapture.onPointerOver.onPointerOverCapture.onPointerOut.onPointerOutCapture.onGotPointerCapture.onGotPointerCaptureCapture.onLostPointerCapture.onLostPointerCaptureCapture.onScroll.onScrollCapture.onWheel.onWheelCapture.onAnimationStart.onAnimationStartCapture.onAnimationEnd.onAnimationEndCapture.onAnimationIteration.onAnimationIterationCapture.onTransitionEnd.onTransitionEndCapture".split(".");
-function hI(e) {
+function gI(e) {
return typeof e == "string" && k_e.includes(e);
}
//#endregion
//#region node_modules/recharts/es6/util/svgPropertiesNoEvents.js
var A_e = /* @__PURE__ */ new Set(/* @__PURE__ */ "aria-activedescendant.aria-atomic.aria-autocomplete.aria-busy.aria-checked.aria-colcount.aria-colindex.aria-colspan.aria-controls.aria-current.aria-describedby.aria-details.aria-disabled.aria-errormessage.aria-expanded.aria-flowto.aria-haspopup.aria-hidden.aria-invalid.aria-keyshortcuts.aria-label.aria-labelledby.aria-level.aria-live.aria-modal.aria-multiline.aria-multiselectable.aria-orientation.aria-owns.aria-placeholder.aria-posinset.aria-pressed.aria-readonly.aria-relevant.aria-required.aria-roledescription.aria-rowcount.aria-rowindex.aria-rowspan.aria-selected.aria-setsize.aria-sort.aria-valuemax.aria-valuemin.aria-valuenow.aria-valuetext.className.color.height.id.lang.max.media.method.min.name.style.target.width.role.tabIndex.accentHeight.accumulate.additive.alignmentBaseline.allowReorder.alphabetic.amplitude.arabicForm.ascent.attributeName.attributeType.autoReverse.azimuth.baseFrequency.baselineShift.baseProfile.bbox.begin.bias.by.calcMode.capHeight.clip.clipPath.clipPathUnits.clipRule.colorInterpolation.colorInterpolationFilters.colorProfile.colorRendering.contentScriptType.contentStyleType.cursor.cx.cy.d.decelerate.descent.diffuseConstant.direction.display.divisor.dominantBaseline.dur.dx.dy.edgeMode.elevation.enableBackground.end.exponent.externalResourcesRequired.fill.fillOpacity.fillRule.filter.filterRes.filterUnits.floodColor.floodOpacity.focusable.fontFamily.fontSize.fontSizeAdjust.fontStretch.fontStyle.fontVariant.fontWeight.format.from.fx.fy.g1.g2.glyphName.glyphOrientationHorizontal.glyphOrientationVertical.glyphRef.gradientTransform.gradientUnits.hanging.horizAdvX.horizOriginX.href.ideographic.imageRendering.in2.in.intercept.k1.k2.k3.k4.k.kernelMatrix.kernelUnitLength.kerning.keyPoints.keySplines.keyTimes.lengthAdjust.letterSpacing.lightingColor.limitingConeAngle.local.markerEnd.markerHeight.markerMid.markerStart.markerUnits.markerWidth.mask.maskContentUnits.maskUnits.mathematical.mode.numOctaves.offset.opacity.operator.order.orient.orientation.origin.overflow.overlinePosition.overlineThickness.paintOrder.panose1.pathLength.patternContentUnits.patternTransform.patternUnits.pointerEvents.pointsAtX.pointsAtY.pointsAtZ.preserveAlpha.preserveAspectRatio.primitiveUnits.r.radius.refX.refY.renderingIntent.repeatCount.repeatDur.requiredExtensions.requiredFeatures.restart.result.rotate.rx.ry.seed.shapeRendering.slope.spacing.specularConstant.specularExponent.speed.spreadMethod.startOffset.stdDeviation.stemh.stemv.stitchTiles.stopColor.stopOpacity.strikethroughPosition.strikethroughThickness.string.stroke.strokeDasharray.strokeDashoffset.strokeLinecap.strokeLinejoin.strokeMiterlimit.strokeOpacity.strokeWidth.surfaceScale.systemLanguage.tableValues.targetX.targetY.textAnchor.textDecoration.textLength.textRendering.to.transform.u1.u2.underlinePosition.underlineThickness.unicode.unicodeBidi.unicodeRange.unitsPerEm.vAlphabetic.values.vectorEffect.version.vertAdvY.vertOriginX.vertOriginY.vHanging.vIdeographic.viewTarget.visibility.vMathematical.widths.wordSpacing.writingMode.x1.x2.x.xChannelSelector.xHeight.xlinkActuate.xlinkArcrole.xlinkHref.xlinkRole.xlinkShow.xlinkTitle.xlinkType.xmlBase.xmlLang.xmlns.xmlnsXlink.xmlSpace.y1.y2.y.yChannelSelector.z.zoomAndPan.ref.key.angle".split("."));
-function gI(e) {
+function _I(e) {
return typeof e == "string" && A_e.has(e);
}
-function _I(e) {
+function vI(e) {
return typeof e == "string" && e.startsWith("data-");
}
-function vI(e) {
+function yI(e) {
if (typeof e != "object" || !e) return {};
var t = {};
- for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && (gI(n) || _I(n)) && (t[n] = e[n]);
+ for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && (_I(n) || vI(n)) && (t[n] = e[n]);
return t;
}
-function yI(e) {
+function bI(e) {
if (e == null) return null;
if (/*#__PURE__*/ (0, R.isValidElement)(e) && typeof e.props == "object" && e.props !== null) {
var t = e.props;
- return vI(t);
+ return yI(t);
}
- return typeof e == "object" && !Array.isArray(e) ? vI(e) : null;
+ return typeof e == "object" && !Array.isArray(e) ? yI(e) : null;
}
//#endregion
//#region node_modules/recharts/es6/util/svgPropertiesAndEvents.js
-function bI(e) {
+function xI(e) {
var t = {};
- for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && (gI(n) || _I(n) || hI(n)) && (t[n] = e[n]);
+ for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && (_I(n) || vI(n) || gI(n)) && (t[n] = e[n]);
return t;
}
function j_e(e) {
- return e == null ? null : /*#__PURE__*/ (0, R.isValidElement)(e) ? bI(e.props) : typeof e == "object" && !Array.isArray(e) ? bI(e) : null;
+ return e == null ? null : /*#__PURE__*/ (0, R.isValidElement)(e) ? xI(e.props) : typeof e == "object" && !Array.isArray(e) ? xI(e) : null;
}
//#endregion
//#region node_modules/recharts/es6/container/Surface.js
@@ -49937,14 +49989,14 @@ var M_e = [
"title",
"desc"
];
-function xI() {
- return xI = Object.assign ? Object.assign.bind() : function(e) {
+function SI() {
+ return SI = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, xI.apply(null, arguments);
+ }, SI.apply(null, arguments);
}
function N_e(e, t) {
if (e == null) return {};
@@ -49964,14 +50016,14 @@ function P_e(e, t) {
}
return n;
}
-var SI = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+var CI = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
var { children: n, width: r, height: i, viewBox: a, className: o, style: s, title: c, desc: l } = e, u = N_e(e, M_e), d = a || {
width: r,
height: i,
x: 0,
y: 0
}, f = ja("recharts-surface", o);
- return /*#__PURE__*/ R.createElement("svg", xI({}, bI(u), {
+ return /*#__PURE__*/ R.createElement("svg", SI({}, xI(u), {
className: f,
width: r,
height: i,
@@ -49980,14 +50032,14 @@ var SI = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
ref: t
}), /*#__PURE__*/ R.createElement("title", null, c), /*#__PURE__*/ R.createElement("desc", null, l), n);
}), F_e = ["children", "className"];
-function CI() {
- return CI = Object.assign ? Object.assign.bind() : function(e) {
+function wI() {
+ return wI = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, CI.apply(null, arguments);
+ }, wI.apply(null, arguments);
}
function I_e(e, t) {
if (e == null) return {};
@@ -50007,39 +50059,39 @@ function L_e(e, t) {
}
return n;
}
-var wI = /*#__PURE__*/ R.forwardRef((e, t) => {
+var TI = /*#__PURE__*/ R.forwardRef((e, t) => {
var { children: n, className: r } = e, i = I_e(e, F_e), a = ja("recharts-layer", r);
- return /*#__PURE__*/ R.createElement("g", CI({ className: a }, bI(i), { ref: t }), n);
-}), TI = /*#__PURE__*/ (0, R.createContext)(null), R_e = () => (0, R.useContext)(TI);
+ return /*#__PURE__*/ R.createElement("g", wI({ className: a }, xI(i), { ref: t }), n);
+}), EI = /*#__PURE__*/ (0, R.createContext)(null), R_e = () => (0, R.useContext)(EI);
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/constant.js
-function EI(e) {
+function DI(e) {
return function() {
return e;
};
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/math.js
-var DI = Math.cos, OI = Math.sin, kI = Math.sqrt, AI = Math.PI;
-AI / 2;
-var jI = 2 * AI, MI = Math.PI, NI = 2 * MI, PI = 1e-6, z_e = NI - PI;
-function FI(e) {
+var OI = Math.cos, kI = Math.sin, AI = Math.sqrt, jI = Math.PI;
+jI / 2;
+var MI = 2 * jI, NI = Math.PI, PI = 2 * NI, FI = 1e-6, z_e = PI - FI;
+function II(e) {
this._ += e[0];
for (let t = 1, n = e.length; t < n; ++t) this._ += arguments[t] + e[t];
}
function B_e(e) {
let t = Math.floor(e);
if (!(t >= 0)) throw Error(`invalid digits: ${e}`);
- if (t > 15) return FI;
+ if (t > 15) return II;
let n = 10 ** t;
return function(e) {
this._ += e[0];
for (let t = 1, r = e.length; t < r; ++t) this._ += Math.round(arguments[t] * n) / n + e[t];
};
}
-var II = class {
+var LI = class {
constructor(e) {
- this._x0 = this._y0 = this._x1 = this._y1 = null, this._ = "", this._append = e == null ? FI : B_e(e);
+ this._x0 = this._y0 = this._x1 = this._y1 = null, this._ = "", this._append = e == null ? II : B_e(e);
}
moveTo(e, t) {
this._append`M${this._x0 = this._x1 = +e},${this._y0 = this._y1 = +t}`;
@@ -50060,18 +50112,18 @@ var II = class {
if (e = +e, t = +t, n = +n, r = +r, i = +i, i < 0) throw Error(`negative radius: ${i}`);
let a = this._x1, o = this._y1, s = n - e, c = r - t, l = a - e, u = o - t, d = l * l + u * u;
if (this._x1 === null) this._append`M${this._x1 = e},${this._y1 = t}`;
- else if (d > PI) {
- if (!(Math.abs(u * s - c * l) > PI) || !i) this._append`L${this._x1 = e},${this._y1 = t}`;
+ else if (d > FI) {
+ if (!(Math.abs(u * s - c * l) > FI) || !i) this._append`L${this._x1 = e},${this._y1 = t}`;
else {
- let f = n - a, p = r - o, m = s * s + c * c, h = f * f + p * p, g = Math.sqrt(m), _ = Math.sqrt(d), v = i * Math.tan((MI - Math.acos((m + d - h) / (2 * g * _))) / 2), y = v / _, b = v / g;
- Math.abs(y - 1) > PI && this._append`L${e + y * l},${t + y * u}`, this._append`A${i},${i},0,0,${+(u * f > l * p)},${this._x1 = e + b * s},${this._y1 = t + b * c}`;
+ let f = n - a, p = r - o, m = s * s + c * c, h = f * f + p * p, g = Math.sqrt(m), _ = Math.sqrt(d), v = i * Math.tan((NI - Math.acos((m + d - h) / (2 * g * _))) / 2), y = v / _, b = v / g;
+ Math.abs(y - 1) > FI && this._append`L${e + y * l},${t + y * u}`, this._append`A${i},${i},0,0,${+(u * f > l * p)},${this._x1 = e + b * s},${this._y1 = t + b * c}`;
}
}
}
arc(e, t, n, r, i, a) {
if (e = +e, t = +t, n = +n, a = !!a, n < 0) throw Error(`negative radius: ${n}`);
let o = n * Math.cos(r), s = n * Math.sin(r), c = e + o, l = t + s, u = 1 ^ a, d = a ? r - i : i - r;
- this._x1 === null ? this._append`M${c},${l}` : (Math.abs(this._x1 - c) > PI || Math.abs(this._y1 - l) > PI) && this._append`L${c},${l}`, n && (d < 0 && (d = d % NI + NI), d > z_e ? this._append`A${n},${n},0,1,${u},${e - o},${t - s}A${n},${n},0,1,${u},${this._x1 = c},${this._y1 = l}` : d > PI && this._append`A${n},${n},0,${+(d >= MI)},${u},${this._x1 = e + n * Math.cos(i)},${this._y1 = t + n * Math.sin(i)}`);
+ this._x1 === null ? this._append`M${c},${l}` : (Math.abs(this._x1 - c) > FI || Math.abs(this._y1 - l) > FI) && this._append`L${c},${l}`, n && (d < 0 && (d = d % PI + PI), d > z_e ? this._append`A${n},${n},0,1,${u},${e - o},${t - s}A${n},${n},0,1,${u},${this._x1 = c},${this._y1 = l}` : d > FI && this._append`A${n},${n},0,${+(d >= NI)},${u},${this._x1 = e + n * Math.cos(i)},${this._y1 = t + n * Math.sin(i)}`);
}
rect(e, t, n, r) {
this._append`M${this._x0 = this._x1 = +e},${this._y0 = this._y1 = +t}h${n = +n}v${+r}h${-n}Z`;
@@ -50080,10 +50132,10 @@ var II = class {
return this._;
}
};
-II.prototype;
+LI.prototype;
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/path.js
-function LI(e) {
+function RI(e) {
let t = 3;
return e.digits = function(n) {
if (!arguments.length) return t;
@@ -50094,18 +50146,18 @@ function LI(e) {
t = e;
}
return e;
- }, () => new II(t);
+ }, () => new LI(t);
}
Array.prototype.slice;
-function RI(e) {
+function zI(e) {
return typeof e == "object" && "length" in e ? e : Array.from(e);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/curve/linear.js
-function zI(e) {
+function BI(e) {
this._context = e;
}
-zI.prototype = {
+BI.prototype = {
areaStart: function() {
this._line = 0;
},
@@ -50128,33 +50180,33 @@ zI.prototype = {
}
}
};
-function BI(e) {
- return new zI(e);
+function VI(e) {
+ return new BI(e);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/point.js
-function VI(e) {
+function HI(e) {
return e[0];
}
-function HI(e) {
+function UI(e) {
return e[1];
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/line.js
-function UI(e, t) {
- var n = EI(!0), r = null, i = BI, a = null, o = LI(s);
- e = typeof e == "function" ? e : e === void 0 ? VI : EI(e), t = typeof t == "function" ? t : t === void 0 ? HI : EI(t);
+function WI(e, t) {
+ var n = DI(!0), r = null, i = VI, a = null, o = RI(s);
+ e = typeof e == "function" ? e : e === void 0 ? HI : DI(e), t = typeof t == "function" ? t : t === void 0 ? UI : DI(t);
function s(s) {
- var c, l = (s = RI(s)).length, u, d = !1, f;
+ var c, l = (s = zI(s)).length, u, d = !1, f;
for (r ?? (a = i(f = o())), c = 0; c <= l; ++c) !(c < l && n(u = s[c], c, s)) === d && ((d = !d) ? a.lineStart() : a.lineEnd()), d && a.point(+e(u, c, s), +t(u, c, s));
if (f) return a = null, f + "" || null;
}
return s.x = function(t) {
- return arguments.length ? (e = typeof t == "function" ? t : EI(+t), s) : e;
+ return arguments.length ? (e = typeof t == "function" ? t : DI(+t), s) : e;
}, s.y = function(e) {
- return arguments.length ? (t = typeof e == "function" ? e : EI(+e), s) : t;
+ return arguments.length ? (t = typeof e == "function" ? e : DI(+e), s) : t;
}, s.defined = function(e) {
- return arguments.length ? (n = typeof e == "function" ? e : EI(!!e), s) : n;
+ return arguments.length ? (n = typeof e == "function" ? e : DI(!!e), s) : n;
}, s.curve = function(e) {
return arguments.length ? (i = e, r != null && (a = i(r)), s) : i;
}, s.context = function(e) {
@@ -50163,11 +50215,11 @@ function UI(e, t) {
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/area.js
-function WI(e, t, n) {
- var r = null, i = EI(!0), a = null, o = BI, s = null, c = LI(l);
- e = typeof e == "function" ? e : e === void 0 ? VI : EI(+e), t = typeof t == "function" ? t : EI(t === void 0 ? 0 : +t), n = typeof n == "function" ? n : n === void 0 ? HI : EI(+n);
+function GI(e, t, n) {
+ var r = null, i = DI(!0), a = null, o = VI, s = null, c = RI(l);
+ e = typeof e == "function" ? e : e === void 0 ? HI : DI(+e), t = typeof t == "function" ? t : DI(t === void 0 ? 0 : +t), n = typeof n == "function" ? n : n === void 0 ? UI : DI(+n);
function l(l) {
- var u, d, f, p = (l = RI(l)).length, m, h = !1, g, _ = Array(p), v = Array(p);
+ var u, d, f, p = (l = zI(l)).length, m, h = !1, g, _ = Array(p), v = Array(p);
for (a ?? (s = o(g = c())), u = 0; u <= p; ++u) {
if (!(u < p && i(m = l[u], u, l)) === h) {
if (h = !h) d = u, s.areaStart(), s.lineStart();
@@ -50181,20 +50233,20 @@ function WI(e, t, n) {
if (g) return s = null, g + "" || null;
}
function u() {
- return UI().defined(i).curve(o).context(a);
+ return WI().defined(i).curve(o).context(a);
}
return l.x = function(t) {
- return arguments.length ? (e = typeof t == "function" ? t : EI(+t), r = null, l) : e;
+ return arguments.length ? (e = typeof t == "function" ? t : DI(+t), r = null, l) : e;
}, l.x0 = function(t) {
- return arguments.length ? (e = typeof t == "function" ? t : EI(+t), l) : e;
+ return arguments.length ? (e = typeof t == "function" ? t : DI(+t), l) : e;
}, l.x1 = function(e) {
- return arguments.length ? (r = e == null ? null : typeof e == "function" ? e : EI(+e), l) : r;
+ return arguments.length ? (r = e == null ? null : typeof e == "function" ? e : DI(+e), l) : r;
}, l.y = function(e) {
- return arguments.length ? (t = typeof e == "function" ? e : EI(+e), n = null, l) : t;
+ return arguments.length ? (t = typeof e == "function" ? e : DI(+e), n = null, l) : t;
}, l.y0 = function(e) {
- return arguments.length ? (t = typeof e == "function" ? e : EI(+e), l) : t;
+ return arguments.length ? (t = typeof e == "function" ? e : DI(+e), l) : t;
}, l.y1 = function(e) {
- return arguments.length ? (n = e == null ? null : typeof e == "function" ? e : EI(+e), l) : n;
+ return arguments.length ? (n = e == null ? null : typeof e == "function" ? e : DI(+e), l) : n;
}, l.lineX0 = l.lineY0 = function() {
return u().x(e).y(t);
}, l.lineY1 = function() {
@@ -50202,7 +50254,7 @@ function WI(e, t, n) {
}, l.lineX1 = function() {
return u().x(r).y(t);
}, l.defined = function(e) {
- return arguments.length ? (i = typeof e == "function" ? e : EI(!!e), l) : i;
+ return arguments.length ? (i = typeof e == "function" ? e : DI(!!e), l) : i;
}, l.curve = function(e) {
return arguments.length ? (o = e, a != null && (s = o(a)), l) : o;
}, l.context = function(e) {
@@ -50211,7 +50263,7 @@ function WI(e, t, n) {
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/curve/bump.js
-var GI = class {
+var KI = class {
constructor(e, t) {
this._context = e, this._x = t;
}
@@ -50239,69 +50291,69 @@ var GI = class {
}
};
function V_e(e) {
- return new GI(e, !0);
+ return new KI(e, !0);
}
function H_e(e) {
- return new GI(e, !1);
+ return new KI(e, !1);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/symbol/circle.js
-var KI = { draw(e, t) {
- let n = kI(t / AI);
- e.moveTo(n, 0), e.arc(0, 0, n, 0, jI);
+var qI = { draw(e, t) {
+ let n = AI(t / jI);
+ e.moveTo(n, 0), e.arc(0, 0, n, 0, MI);
} }, U_e = { draw(e, t) {
- let n = kI(t / 5) / 2;
+ let n = AI(t / 5) / 2;
e.moveTo(-3 * n, -n), e.lineTo(-n, -n), e.lineTo(-n, -3 * n), e.lineTo(n, -3 * n), e.lineTo(n, -n), e.lineTo(3 * n, -n), e.lineTo(3 * n, n), e.lineTo(n, n), e.lineTo(n, 3 * n), e.lineTo(-n, 3 * n), e.lineTo(-n, n), e.lineTo(-3 * n, n), e.closePath();
-} }, qI = kI(1 / 3), W_e = qI * 2, G_e = { draw(e, t) {
- let n = kI(t / W_e), r = n * qI;
+} }, JI = AI(1 / 3), W_e = JI * 2, G_e = { draw(e, t) {
+ let n = AI(t / W_e), r = n * JI;
e.moveTo(0, -n), e.lineTo(r, 0), e.lineTo(0, n), e.lineTo(-r, 0), e.closePath();
} }, K_e = { draw(e, t) {
- let n = kI(t), r = -n / 2;
+ let n = AI(t), r = -n / 2;
e.rect(r, r, n, n);
-} }, q_e = .8908130915292852, JI = OI(AI / 10) / OI(7 * AI / 10), J_e = OI(jI / 10) * JI, Y_e = -DI(jI / 10) * JI, X_e = { draw(e, t) {
- let n = kI(t * q_e), r = J_e * n, i = Y_e * n;
+} }, q_e = .8908130915292852, YI = kI(jI / 10) / kI(7 * jI / 10), J_e = kI(MI / 10) * YI, Y_e = -OI(MI / 10) * YI, X_e = { draw(e, t) {
+ let n = AI(t * q_e), r = J_e * n, i = Y_e * n;
e.moveTo(0, -n), e.lineTo(r, i);
for (let t = 1; t < 5; ++t) {
- let a = jI * t / 5, o = DI(a), s = OI(a);
+ let a = MI * t / 5, o = OI(a), s = kI(a);
e.lineTo(s * n, -o * n), e.lineTo(o * r - s * i, s * r + o * i);
}
e.closePath();
-} }, YI = kI(3), Z_e = { draw(e, t) {
- let n = -kI(t / (YI * 3));
- e.moveTo(0, n * 2), e.lineTo(-YI * n, -n), e.lineTo(YI * n, -n), e.closePath();
-} }, XI = -.5, ZI = kI(3) / 2, QI = 1 / kI(12), Q_e = (QI / 2 + 1) * 3, $_e = { draw(e, t) {
- let n = kI(t / Q_e), r = n / 2, i = n * QI, a = r, o = n * QI + n, s = -a, c = o;
- e.moveTo(r, i), e.lineTo(a, o), e.lineTo(s, c), e.lineTo(XI * r - ZI * i, ZI * r + XI * i), e.lineTo(XI * a - ZI * o, ZI * a + XI * o), e.lineTo(XI * s - ZI * c, ZI * s + XI * c), e.lineTo(XI * r + ZI * i, XI * i - ZI * r), e.lineTo(XI * a + ZI * o, XI * o - ZI * a), e.lineTo(XI * s + ZI * c, XI * c - ZI * s), e.closePath();
+} }, XI = AI(3), Z_e = { draw(e, t) {
+ let n = -AI(t / (XI * 3));
+ e.moveTo(0, n * 2), e.lineTo(-XI * n, -n), e.lineTo(XI * n, -n), e.closePath();
+} }, ZI = -.5, QI = AI(3) / 2, $I = 1 / AI(12), Q_e = ($I / 2 + 1) * 3, $_e = { draw(e, t) {
+ let n = AI(t / Q_e), r = n / 2, i = n * $I, a = r, o = n * $I + n, s = -a, c = o;
+ e.moveTo(r, i), e.lineTo(a, o), e.lineTo(s, c), e.lineTo(ZI * r - QI * i, QI * r + ZI * i), e.lineTo(ZI * a - QI * o, QI * a + ZI * o), e.lineTo(ZI * s - QI * c, QI * s + ZI * c), e.lineTo(ZI * r + QI * i, ZI * i - QI * r), e.lineTo(ZI * a + QI * o, ZI * o - QI * a), e.lineTo(ZI * s + QI * c, ZI * c - QI * s), e.closePath();
} };
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/symbol.js
function eve(e, t) {
- let n = null, r = LI(i);
- e = typeof e == "function" ? e : EI(e || KI), t = typeof t == "function" ? t : EI(t === void 0 ? 64 : +t);
+ let n = null, r = RI(i);
+ e = typeof e == "function" ? e : DI(e || qI), t = typeof t == "function" ? t : DI(t === void 0 ? 64 : +t);
function i() {
let i;
if (n ||= i = r(), e.apply(this, arguments).draw(n, +t.apply(this, arguments)), i) return n = null, i + "" || null;
}
return i.type = function(t) {
- return arguments.length ? (e = typeof t == "function" ? t : EI(t), i) : e;
+ return arguments.length ? (e = typeof t == "function" ? t : DI(t), i) : e;
}, i.size = function(e) {
- return arguments.length ? (t = typeof e == "function" ? e : EI(+e), i) : t;
+ return arguments.length ? (t = typeof e == "function" ? e : DI(+e), i) : t;
}, i.context = function(e) {
return arguments.length ? (n = e ?? null, i) : n;
}, i;
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/noop.js
-function $I() {}
+function eL() {}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/curve/basis.js
-function eL(e, t, n) {
+function tL(e, t, n) {
e._context.bezierCurveTo((2 * e._x0 + e._x1) / 3, (2 * e._y0 + e._y1) / 3, (e._x0 + 2 * e._x1) / 3, (e._y0 + 2 * e._y1) / 3, (e._x0 + 4 * e._x1 + t) / 6, (e._y0 + 4 * e._y1 + n) / 6);
}
-function tL(e) {
+function nL(e) {
this._context = e;
}
-tL.prototype = {
+nL.prototype = {
areaStart: function() {
this._line = 0;
},
@@ -50313,7 +50365,7 @@ tL.prototype = {
},
lineEnd: function() {
switch (this._point) {
- case 3: eL(this, this._x1, this._y1);
+ case 3: tL(this, this._x1, this._y1);
case 2: this._context.lineTo(this._x1, this._y1);
}
(this._line || this._line !== 0 && this._point === 1) && this._context.closePath(), this._line = 1 - this._line;
@@ -50327,22 +50379,22 @@ tL.prototype = {
this._point = 2;
break;
case 2: this._point = 3, this._context.lineTo((5 * this._x0 + this._x1) / 6, (5 * this._y0 + this._y1) / 6);
- default: eL(this, e, t);
+ default: tL(this, e, t);
}
this._x0 = this._x1, this._x1 = e, this._y0 = this._y1, this._y1 = t;
}
};
function tve(e) {
- return new tL(e);
+ return new nL(e);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/curve/basisClosed.js
-function nL(e) {
+function rL(e) {
this._context = e;
}
-nL.prototype = {
- areaStart: $I,
- areaEnd: $I,
+rL.prototype = {
+ areaStart: eL,
+ areaEnd: eL,
lineStart: function() {
this._x0 = this._x1 = this._x2 = this._x3 = this._x4 = this._y0 = this._y1 = this._y2 = this._y3 = this._y4 = NaN, this._point = 0;
},
@@ -50368,20 +50420,20 @@ nL.prototype = {
case 2:
this._point = 3, this._x4 = e, this._y4 = t, this._context.moveTo((this._x0 + 4 * this._x1 + e) / 6, (this._y0 + 4 * this._y1 + t) / 6);
break;
- default: eL(this, e, t);
+ default: tL(this, e, t);
}
this._x0 = this._x1, this._x1 = e, this._y0 = this._y1, this._y1 = t;
}
};
function nve(e) {
- return new nL(e);
+ return new rL(e);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/curve/basisOpen.js
-function rL(e) {
+function iL(e) {
this._context = e;
}
-rL.prototype = {
+iL.prototype = {
areaStart: function() {
this._line = 0;
},
@@ -50408,22 +50460,22 @@ rL.prototype = {
this._line ? this._context.lineTo(n, r) : this._context.moveTo(n, r);
break;
case 3: this._point = 4;
- default: eL(this, e, t);
+ default: tL(this, e, t);
}
this._x0 = this._x1, this._x1 = e, this._y0 = this._y1, this._y1 = t;
}
};
function rve(e) {
- return new rL(e);
+ return new iL(e);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/curve/linearClosed.js
-function iL(e) {
+function aL(e) {
this._context = e;
}
-iL.prototype = {
- areaStart: $I,
- areaEnd: $I,
+aL.prototype = {
+ areaStart: eL,
+ areaEnd: eL,
lineStart: function() {
this._point = 0;
},
@@ -50435,29 +50487,29 @@ iL.prototype = {
}
};
function ive(e) {
- return new iL(e);
+ return new aL(e);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/curve/monotone.js
-function aL(e) {
+function oL(e) {
return e < 0 ? -1 : 1;
}
-function oL(e, t, n) {
+function sL(e, t, n) {
var r = e._x1 - e._x0, i = t - e._x1, a = (e._y1 - e._y0) / (r || i < 0 && -0), o = (n - e._y1) / (i || r < 0 && -0), s = (a * i + o * r) / (r + i);
- return (aL(a) + aL(o)) * Math.min(Math.abs(a), Math.abs(o), .5 * Math.abs(s)) || 0;
+ return (oL(a) + oL(o)) * Math.min(Math.abs(a), Math.abs(o), .5 * Math.abs(s)) || 0;
}
-function sL(e, t) {
+function cL(e, t) {
var n = e._x1 - e._x0;
return n ? (3 * (e._y1 - e._y0) / n - t) / 2 : t;
}
-function cL(e, t, n) {
+function lL(e, t, n) {
var r = e._x0, i = e._y0, a = e._x1, o = e._y1, s = (a - r) / 3;
e._context.bezierCurveTo(r + s, i + s * t, a - s, o - s * n, a, o);
}
-function lL(e) {
+function uL(e) {
this._context = e;
}
-lL.prototype = {
+uL.prototype = {
areaStart: function() {
this._line = 0;
},
@@ -50472,7 +50524,7 @@ lL.prototype = {
case 2:
this._context.lineTo(this._x1, this._y1);
break;
- case 3: cL(this, this._t0, sL(this, this._t0));
+ case 3: lL(this, this._t0, cL(this, this._t0));
}
(this._line || this._line !== 0 && this._point === 1) && this._context.closePath(), this._line = 1 - this._line;
},
@@ -50487,24 +50539,24 @@ lL.prototype = {
this._point = 2;
break;
case 2:
- this._point = 3, cL(this, sL(this, n = oL(this, e, t)), n);
+ this._point = 3, lL(this, cL(this, n = sL(this, e, t)), n);
break;
- default: cL(this, this._t0, n = oL(this, e, t));
+ default: lL(this, this._t0, n = sL(this, e, t));
}
this._x0 = this._x1, this._x1 = e, this._y0 = this._y1, this._y1 = t, this._t0 = n;
}
}
};
-function uL(e) {
- this._context = new dL(e);
+function dL(e) {
+ this._context = new fL(e);
}
-(uL.prototype = Object.create(lL.prototype)).point = function(e, t) {
- lL.prototype.point.call(this, t, e);
+(dL.prototype = Object.create(uL.prototype)).point = function(e, t) {
+ uL.prototype.point.call(this, t, e);
};
-function dL(e) {
+function fL(e) {
this._context = e;
}
-dL.prototype = {
+fL.prototype = {
moveTo: function(e, t) {
this._context.moveTo(t, e);
},
@@ -50519,17 +50571,17 @@ dL.prototype = {
}
};
function ave(e) {
- return new lL(e);
+ return new uL(e);
}
function ove(e) {
- return new uL(e);
+ return new dL(e);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/curve/natural.js
-function fL(e) {
+function pL(e) {
this._context = e;
}
-fL.prototype = {
+pL.prototype = {
areaStart: function() {
this._line = 0;
},
@@ -50543,7 +50595,7 @@ fL.prototype = {
var e = this._x, t = this._y, n = e.length;
if (n) {
if (this._line ? this._context.lineTo(e[0], t[0]) : this._context.moveTo(e[0], t[0]), n === 2) this._context.lineTo(e[1], t[1]);
- else for (var r = pL(e), i = pL(t), a = 0, o = 1; o < n; ++a, ++o) this._context.bezierCurveTo(r[0][a], i[0][a], r[1][a], i[1][a], e[o], t[o]);
+ else for (var r = mL(e), i = mL(t), a = 0, o = 1; o < n; ++a, ++o) this._context.bezierCurveTo(r[0][a], i[0][a], r[1][a], i[1][a], e[o], t[o]);
}
(this._line || this._line !== 0 && n === 1) && this._context.closePath(), this._line = 1 - this._line, this._x = this._y = null;
},
@@ -50551,7 +50603,7 @@ fL.prototype = {
this._x.push(+e), this._y.push(+t);
}
};
-function pL(e) {
+function mL(e) {
var t, n = e.length - 1, r, i = Array(n), a = Array(n), o = Array(n);
for (i[0] = 0, a[0] = 2, o[0] = e[0] + 2 * e[1], t = 1; t < n - 1; ++t) i[t] = 1, a[t] = 4, o[t] = 4 * e[t] + 2 * e[t + 1];
for (i[n - 1] = 2, a[n - 1] = 7, o[n - 1] = 8 * e[n - 1] + e[n], t = 1; t < n; ++t) r = i[t] / a[t - 1], a[t] -= r, o[t] -= r * o[t - 1];
@@ -50560,14 +50612,14 @@ function pL(e) {
return [i, a];
}
function sve(e) {
- return new fL(e);
+ return new pL(e);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/curve/step.js
-function mL(e, t) {
+function hL(e, t) {
this._context = e, this._t = t;
}
-mL.prototype = {
+hL.prototype = {
areaStart: function() {
this._line = 0;
},
@@ -50596,22 +50648,22 @@ mL.prototype = {
}
};
function cve(e) {
- return new mL(e, .5);
+ return new hL(e, .5);
}
function lve(e) {
- return new mL(e, 0);
+ return new hL(e, 0);
}
function uve(e) {
- return new mL(e, 1);
+ return new hL(e, 1);
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/offset/none.js
-function hL(e, t) {
+function gL(e, t) {
if ((o = e.length) > 1) for (var n = 1, r, i, a = e[t[0]], o, s = a.length; n < o; ++n) for (i = a, a = e[t[n]], r = 0; r < s; ++r) a[r][1] += a[r][0] = isNaN(i[r][1]) ? i[r][0] : i[r][1];
}
//#endregion
//#region node_modules/victory-vendor/node_modules/d3-shape/src/order/none.js
-function gL(e) {
+function _L(e) {
for (var t = e.length, n = Array(t); --t >= 0;) n[t] = t;
return n;
}
@@ -50625,21 +50677,21 @@ function fve(e) {
return t.key = e, t;
}
function pve() {
- var e = EI([]), t = gL, n = hL, r = dve;
+ var e = DI([]), t = _L, n = gL, r = dve;
function i(i) {
var a = Array.from(e.apply(this, arguments), fve), o, s = a.length, c = -1, l;
for (let e of i) for (o = 0, ++c; o < s; ++o) (a[o][c] = [0, +r(e, a[o].key, c, i)]).data = e;
- for (o = 0, l = RI(t(a)); o < s; ++o) a[l[o]].index = o;
+ for (o = 0, l = zI(t(a)); o < s; ++o) a[l[o]].index = o;
return n(a, l), a;
}
return i.keys = function(t) {
- return arguments.length ? (e = typeof t == "function" ? t : EI(Array.from(t)), i) : e;
+ return arguments.length ? (e = typeof t == "function" ? t : DI(Array.from(t)), i) : e;
}, i.value = function(e) {
- return arguments.length ? (r = typeof e == "function" ? e : EI(+e), i) : r;
+ return arguments.length ? (r = typeof e == "function" ? e : DI(+e), i) : r;
}, i.order = function(e) {
- return arguments.length ? (t = e == null ? gL : typeof e == "function" ? e : EI(Array.from(e)), i) : t;
+ return arguments.length ? (t = e == null ? _L : typeof e == "function" ? e : DI(Array.from(e)), i) : t;
}, i.offset = function(e) {
- return arguments.length ? (n = e ?? hL, i) : n;
+ return arguments.length ? (n = e ?? gL, i) : n;
}, i;
}
//#endregion
@@ -50650,7 +50702,7 @@ function mve(e, t) {
for (o = n = 0; n < r; ++n) o += e[n][i][1] || 0;
if (o) for (n = 0; n < r; ++n) e[n][i][1] /= o;
}
- hL(e, t);
+ gL(e, t);
}
}
//#endregion
@@ -50661,7 +50713,7 @@ function hve(e, t) {
for (var o = 0, s = 0; o < i; ++o) s += e[o][n][1] || 0;
r[n][1] += r[n][0] = -s / 2;
}
- hL(e, t);
+ gL(e, t);
}
}
//#endregion
@@ -50678,18 +50730,18 @@ function gve(e, t) {
}
i[r - 1][1] += i[r - 1][0] = n, c && (n -= l / c);
}
- i[r - 1][1] += i[r - 1][0] = n, hL(e, t);
+ i[r - 1][1] += i[r - 1][0] = n, gL(e, t);
}
}
//#endregion
//#region node_modules/es-toolkit/dist/_internal/isUnsafeProperty.mjs
-function _L(e) {
+function vL(e) {
return e === "__proto__";
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/_internal/isDeepKey.mjs
var _ve = /\.|(\[(?:[^[\]]*|(["'])(?:(?!\2)[^\\]|\\.)*?\2)\])/;
-function vL(e) {
+function yL(e) {
switch (typeof e) {
case "number":
case "symbol": return !1;
@@ -50699,30 +50751,30 @@ function vL(e) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/_internal/toKey.mjs
-function yL(e) {
+function bL(e) {
return typeof e == "string" || typeof e == "symbol" ? e : Object.is(e?.valueOf?.(), -0) ? "-0" : String(e);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/predicate/isSymbol.mjs
-function bL(e) {
+function xL(e) {
return typeof e == "symbol" || e instanceof Symbol;
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/util/toString.mjs
function vve(e) {
- return e == null ? "" : xL(e);
+ return e == null ? "" : SL(e);
}
-function xL(e) {
+function SL(e) {
if (typeof e == "string") return e;
- if (Array.isArray(e)) return e.map(xL).join(",");
- if (bL(e)) return e.toString();
+ if (Array.isArray(e)) return e.map(SL).join(",");
+ if (xL(e)) return e.toString();
let t = e + "";
return t === "0" && Object.is(Number(e), -0) ? "-0" : t;
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/util/toPath.mjs
-function SL(e) {
- if (Array.isArray(e)) return e.map(yL);
+function CL(e) {
+ if (Array.isArray(e)) return e.map(bL);
if (typeof e == "symbol") return [e];
e = vve(e);
let t = [], n = e.length;
@@ -50752,23 +50804,23 @@ function SL(e) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/object/get.mjs
-function CL(e, t, n) {
+function wL(e, t, n) {
if (e == null) return n;
switch (typeof t) {
case "string": {
- if (_L(t)) return n;
+ if (vL(t)) return n;
let r = e[t];
- return r === void 0 ? vL(t) && !Object.hasOwn(e, t) ? CL(e, SL(t), n) : n : r;
+ return r === void 0 ? yL(t) && !Object.hasOwn(e, t) ? wL(e, CL(t), n) : n : r;
}
case "number":
case "symbol": {
- typeof t == "number" && (t = yL(t));
+ typeof t == "number" && (t = bL(t));
let r = e[t];
return r === void 0 ? n : r;
}
default: {
if (Array.isArray(t)) return yve(e, t, n);
- if (t = Object.is(t?.valueOf(), -0) ? "-0" : String(t), _L(t)) return n;
+ if (t = Object.is(t?.valueOf(), -0) ? "-0" : String(t), vL(t)) return n;
let r = e[t];
return r === void 0 ? n : r;
}
@@ -50778,7 +50830,7 @@ function yve(e, t, n) {
if (t.length === 0) return n;
let r = e;
for (let e = 0; e < t.length; e++) {
- if (r == null || _L(t[e])) return n;
+ if (r == null || vL(t[e])) return n;
r = r[t[e]];
}
return r === void 0 ? n : r;
@@ -50786,49 +50838,49 @@ function yve(e, t, n) {
//#endregion
//#region node_modules/recharts/es6/util/round.js
var bve = 4;
-function wL(e) {
+function TL(e) {
var t = 10 ** (arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : bve), n = Math.round(e * t) / t;
return Object.is(n, -0) ? 0 : n;
}
-function TL(e) {
+function EL(e) {
var t = [...arguments].slice(1);
return e.reduce((e, n, r) => {
var i = t[r - 1];
- return typeof i == "string" ? e + i + n : i === void 0 ? e + n : e + wL(i) + n;
+ return typeof i == "string" ? e + i + n : i === void 0 ? e + n : e + TL(i) + n;
}, "");
}
//#endregion
//#region node_modules/recharts/es6/util/DataUtils.js
-var EL = (e) => e === 0 ? 0 : e > 0 ? 1 : -1, DL = (e) => typeof e == "number" && e != +e, OL = (e) => typeof e == "string" && e.indexOf("%") === e.length - 1, Z = (e) => (typeof e == "number" || e instanceof Number) && !DL(e), kL = (e) => Z(e) || typeof e == "string", xve = 0, AL = (e) => {
+var DL = (e) => e === 0 ? 0 : e > 0 ? 1 : -1, OL = (e) => typeof e == "number" && e != +e, kL = (e) => typeof e == "string" && e.indexOf("%") === e.length - 1, Z = (e) => (typeof e == "number" || e instanceof Number) && !OL(e), AL = (e) => Z(e) || typeof e == "string", xve = 0, jL = (e) => {
var t = ++xve;
return `${e || ""}${t}`;
-}, jL = function(e, t) {
+}, ML = function(e, t) {
var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : 0, r = arguments.length > 3 && arguments[3] !== void 0 && arguments[3];
if (!Z(e) && typeof e != "string") return n;
var i;
- if (OL(e)) {
+ if (kL(e)) {
if (t == null) return n;
var a = e.indexOf("%");
i = t * parseFloat(e.slice(0, a)) / 100;
} else i = +e;
- return DL(i) && (i = n), r && t != null && i > t && (i = t), i;
-}, ML = (e) => {
+ return OL(i) && (i = n), r && t != null && i > t && (i = t), i;
+}, NL = (e) => {
if (!Array.isArray(e)) return !1;
for (var t = e.length, n = {}, r = 0; r < t; r++) if (!n[String(e[r])]) n[String(e[r])] = !0;
else return !0;
return !1;
};
-function NL(e, t, n) {
- return Z(e) && Z(t) ? wL(e + n * (t - e)) : t;
-}
function PL(e, t, n) {
- if (!(!e || !e.length)) return e.find((e) => e && (typeof t == "function" ? t(e) : CL(e, t)) === n);
+ return Z(e) && Z(t) ? TL(e + n * (t - e)) : t;
}
-var FL = (e) => e == null, IL = (e) => FL(e) ? e : `${e.charAt(0).toUpperCase()}${e.slice(1)}`;
-function LL(e) {
+function FL(e, t, n) {
+ if (!(!e || !e.length)) return e.find((e) => e && (typeof t == "function" ? t(e) : wL(e, t)) === n);
+}
+var IL = (e) => e == null, LL = (e) => IL(e) ? e : `${e.charAt(0).toUpperCase()}${e.slice(1)}`;
+function RL(e) {
return e != null;
}
-function RL() {}
+function zL() {}
//#endregion
//#region node_modules/recharts/es6/shape/Symbols.js
var Sve = [
@@ -50836,16 +50888,16 @@ var Sve = [
"size",
"sizeType"
];
-function zL() {
- return zL = Object.assign ? Object.assign.bind() : function(e) {
+function BL() {
+ return BL = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, zL.apply(null, arguments);
+ }, BL.apply(null, arguments);
}
-function BL(e, t) {
+function VL(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -50855,12 +50907,12 @@ function BL(e, t) {
}
return n;
}
-function VL(e) {
+function HL(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? BL(Object(n), !0).forEach(function(t) {
+ t % 2 ? VL(Object(n), !0).forEach(function(t) {
Cve(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : BL(Object(n)).forEach(function(t) {
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : VL(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
@@ -50906,15 +50958,15 @@ function Dve(e, t) {
}
return n;
}
-var HL = {
- symbolCircle: KI,
+var UL = {
+ symbolCircle: qI,
symbolCross: U_e,
symbolDiamond: G_e,
symbolSquare: K_e,
symbolStar: X_e,
symbolTriangle: Z_e,
symbolWye: $_e
-}, Ove = Math.PI / 180, kve = (e) => HL[`symbol${IL(e)}`] || KI, Ave = (e, t, n) => {
+}, Ove = Math.PI / 180, kve = (e) => UL[`symbol${LL(e)}`] || qI, Ave = (e, t, n) => {
if (t === "area") return e;
switch (n) {
case "cross": return 5 * e * e / 9;
@@ -50928,9 +50980,9 @@ var HL = {
default: return Math.PI * e * e / 4;
}
}, jve = (e, t) => {
- HL[`symbol${IL(e)}`] = t;
-}, UL = (e) => {
- var { type: t = "circle", size: n = 64, sizeType: r = "area" } = e, i = VL(VL({}, Eve(e, Sve)), {}, {
+ UL[`symbol${LL(e)}`] = t;
+}, WL = (e) => {
+ var { type: t = "circle", size: n = 64, sizeType: r = "area" } = e, i = HL(HL({}, Eve(e, Sve)), {}, {
type: t,
size: n,
sizeType: r
@@ -50939,35 +50991,35 @@ var HL = {
var o = () => {
var e = kve(a), t = eve().type(e).size(Ave(n, r, a))();
if (t !== null) return t;
- }, { className: s, cx: c, cy: l } = i, u = bI(i);
- return Z(c) && Z(l) && Z(n) ? /*#__PURE__*/ R.createElement("path", zL({}, u, {
+ }, { className: s, cx: c, cy: l } = i, u = xI(i);
+ return Z(c) && Z(l) && Z(n) ? /*#__PURE__*/ R.createElement("path", BL({}, u, {
className: ja("recharts-symbols", s),
transform: `translate(${c}, ${l})`,
d: o()
})) : null;
};
-UL.registerSymbol = jve;
+WL.registerSymbol = jve;
//#endregion
//#region node_modules/recharts/es6/util/types.js
-var WL = (e) => "radius" in e && "startAngle" in e && "endAngle" in e, GL = (e, t) => {
+var GL = (e) => "radius" in e && "startAngle" in e && "endAngle" in e, KL = (e, t) => {
if (!e || typeof e == "function" || typeof e == "boolean") return null;
var n = e;
if (/*#__PURE__*/ (0, R.isValidElement)(e) && (n = e.props), typeof n != "object" && typeof n != "function") return null;
var r = {};
return Object.keys(n).forEach((e) => {
- hI(e) && typeof n[e] == "function" && (r[e] = t || ((t) => n[e](n, t)));
+ gI(e) && typeof n[e] == "function" && (r[e] = t || ((t) => n[e](n, t)));
}), r;
-}, Mve = (e, t, n) => (r) => (e(t, n, r), null), KL = (e, t, n) => {
+}, Mve = (e, t, n) => (r) => (e(t, n, r), null), qL = (e, t, n) => {
if (e === null || typeof e != "object" && typeof e != "function") return null;
var r = null;
return Object.keys(e).forEach((i) => {
var a = e[i];
- hI(i) && typeof a == "function" && (r ||= {}, r[i] = Mve(a, t, n));
+ gI(i) && typeof a == "function" && (r ||= {}, r[i] = Mve(a, t, n));
}), r;
};
//#endregion
//#region node_modules/recharts/es6/util/resolveDefaultProps.js
-function qL(e, t) {
+function JL(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -50980,9 +51032,9 @@ function qL(e, t) {
function Nve(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? qL(Object(n), !0).forEach(function(t) {
+ t % 2 ? JL(Object(n), !0).forEach(function(t) {
Pve(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : qL(Object(n)).forEach(function(t) {
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : JL(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
@@ -51010,22 +51062,22 @@ function Ive(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function JL(e, t) {
+function YL(e, t) {
var n = Nve({}, e), r = t;
return Object.keys(t).reduce((e, t) => (e[t] === void 0 && r[t] !== void 0 && (e[t] = r[t]), e), n);
}
//#endregion
//#region node_modules/recharts/es6/component/DefaultLegendContent.js
-function YL() {
- return YL = Object.assign ? Object.assign.bind() : function(e) {
+function XL() {
+ return XL = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, YL.apply(null, arguments);
+ }, XL.apply(null, arguments);
}
-function XL(e, t) {
+function ZL(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -51035,12 +51087,12 @@ function XL(e, t) {
}
return n;
}
-function ZL(e) {
+function QL(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? XL(Object(n), !0).forEach(function(t) {
+ t % 2 ? ZL(Object(n), !0).forEach(function(t) {
Lve(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : XL(Object(n)).forEach(function(t) {
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : ZL(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
@@ -51068,7 +51120,7 @@ function zve(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var QL = 32, Bve = {
+var $L = 32, Bve = {
align: "center",
iconSize: 14,
inactiveColor: "#ccc",
@@ -51080,7 +51132,7 @@ function Vve(e) {
if (typeof e == "object" && e && "strokeDasharray" in e) return String(e.strokeDasharray);
}
function Hve(e) {
- var { data: t, iconType: n, inactiveColor: r } = e, i = QL / 2, a = QL / 6, o = QL / 3, s = t.inactive ? r : t.color, c = n ?? t.type;
+ var { data: t, iconType: n, inactiveColor: r } = e, i = $L / 2, a = $L / 6, o = $L / 3, s = t.inactive ? r : t.color, c = n ?? t.type;
if (c === "none") return null;
if (c === "plainline") return /*#__PURE__*/ R.createElement("line", {
strokeWidth: 4,
@@ -51089,7 +51141,7 @@ function Hve(e) {
strokeDasharray: Vve(t.payload),
x1: 0,
y1: i,
- x2: QL,
+ x2: $L,
y2: i,
className: "recharts-legend-icon"
});
@@ -51099,25 +51151,25 @@ function Hve(e) {
stroke: s,
d: `M0,${i}h${o}
A${a},${a},0,1,1,${2 * o},${i}
- H${QL}M${2 * o},${i}
+ H${$L}M${2 * o},${i}
A${a},${a},0,1,1,${o},${i}`,
className: "recharts-legend-icon"
});
if (c === "rect") return /*#__PURE__*/ R.createElement("path", {
stroke: "none",
fill: s,
- d: `M0,${QL / 8}h${QL}v${QL * 3 / 4}h${-QL}z`,
+ d: `M0,${$L / 8}h${$L}v${$L * 3 / 4}h${-$L}z`,
className: "recharts-legend-icon"
});
if (/*#__PURE__*/ R.isValidElement(t.legendIcon)) {
- var l = ZL({}, t);
+ var l = QL({}, t);
return delete l.legendIcon, /*#__PURE__*/ R.cloneElement(t.legendIcon, l);
}
- return /*#__PURE__*/ R.createElement(UL, {
+ return /*#__PURE__*/ R.createElement(WL, {
fill: s,
cx: i,
cy: i,
- size: QL,
+ size: $L,
sizeType: "diameter",
type: c
});
@@ -51126,8 +51178,8 @@ function Uve(e) {
var { payload: t, iconSize: n, layout: r, formatter: i, inactiveColor: a, iconType: o, labelStyle: s } = e, c = {
x: 0,
y: 0,
- width: QL,
- height: QL
+ width: $L,
+ height: $L
}, l = {
display: r === "horizontal" ? "inline-block" : "block",
marginRight: 10
@@ -51143,14 +51195,14 @@ function Uve(e) {
inactive: t.inactive
});
if (t.type === "none") return null;
- var p = typeof s == "object" ? ZL({}, s) : {};
+ var p = typeof s == "object" ? QL({}, s) : {};
p.color = t.inactive ? a : p.color || t.color;
var m = d ? d(t.value, t, r) : t.value;
- return /*#__PURE__*/ R.createElement("li", YL({
+ return /*#__PURE__*/ R.createElement("li", XL({
className: f,
style: l,
key: `legend-item-${r}`
- }, KL(e, t, r)), /*#__PURE__*/ R.createElement(SI, {
+ }, qL(e, t, r)), /*#__PURE__*/ R.createElement(CI, {
width: n,
height: n,
viewBox: c,
@@ -51167,7 +51219,7 @@ function Uve(e) {
});
}
var Wve = (e) => {
- var t = JL(e, Bve), { payload: n, layout: r, align: i } = t;
+ var t = YL(e, Bve), { payload: n, layout: r, align: i } = t;
if (!n || !n.length) return null;
var a = {
padding: 0,
@@ -51177,7 +51229,7 @@ var Wve = (e) => {
return /*#__PURE__*/ R.createElement("ul", {
className: "recharts-default-legend",
style: a
- }, /*#__PURE__*/ R.createElement(Uve, YL({}, t, { payload: n })));
+ }, /*#__PURE__*/ R.createElement(Uve, XL({}, t, { payload: n })));
};
//#endregion
//#region node_modules/es-toolkit/dist/array/uniqBy.mjs
@@ -51198,7 +51250,7 @@ function Kve(e, t) {
}
//#endregion
//#region node_modules/es-toolkit/dist/function/identity.mjs
-function $L(e) {
+function eR(e) {
return e;
}
//#endregion
@@ -51208,19 +51260,19 @@ function qve(e) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/predicate/isArrayLike.mjs
-function eR(e) {
+function tR(e) {
return e != null && typeof e != "function" && qve(e.length);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/object/property.mjs
function Jve(e) {
return function(t) {
- return CL(t, e);
+ return wL(t, e);
};
}
//#endregion
//#region node_modules/es-toolkit/dist/predicate/isPrimitive.mjs
-function tR(e) {
+function nR(e) {
return e == null || typeof e != "object" && typeof e != "function";
}
//#endregion
@@ -51235,33 +51287,33 @@ function Xve(e) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/_internal/getTag.mjs
-function nR(e) {
+function rR(e) {
return e == null ? e === void 0 ? "[object Undefined]" : "[object Null]" : Object.prototype.toString.call(e);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/_internal/tags.mjs
-var Zve = "[object RegExp]", rR = "[object String]", iR = "[object Number]", aR = "[object Boolean]", oR = "[object Arguments]", Qve = "[object Symbol]", $ve = "[object Date]", eye = "[object Map]", tye = "[object Set]", nye = "[object Array]", rye = "[object ArrayBuffer]", iye = "[object Object]", aye = "[object DataView]", oye = "[object Uint8Array]", sye = "[object Uint8ClampedArray]", cye = "[object Uint16Array]", lye = "[object Uint32Array]", uye = "[object Int8Array]", dye = "[object Int16Array]", fye = "[object Int32Array]", pye = "[object Float32Array]", mye = "[object Float64Array]", sR = typeof globalThis == "object" && globalThis || typeof window == "object" && window || typeof self == "object" && self || typeof global == "object" && global || (function() {
+var Zve = "[object RegExp]", iR = "[object String]", aR = "[object Number]", oR = "[object Boolean]", sR = "[object Arguments]", Qve = "[object Symbol]", $ve = "[object Date]", eye = "[object Map]", tye = "[object Set]", nye = "[object Array]", rye = "[object ArrayBuffer]", iye = "[object Object]", aye = "[object DataView]", oye = "[object Uint8Array]", sye = "[object Uint8ClampedArray]", cye = "[object Uint16Array]", lye = "[object Uint32Array]", uye = "[object Int8Array]", dye = "[object Int16Array]", fye = "[object Int32Array]", pye = "[object Float32Array]", mye = "[object Float64Array]", cR = typeof globalThis == "object" && globalThis || typeof window == "object" && window || typeof self == "object" && self || typeof global == "object" && global || (function() {
return this;
})();
//#endregion
//#region node_modules/es-toolkit/dist/predicate/isBuffer.mjs
function hye(e) {
- return sR.Buffer !== void 0 && sR.Buffer.isBuffer(e);
+ return cR.Buffer !== void 0 && cR.Buffer.isBuffer(e);
}
//#endregion
//#region node_modules/es-toolkit/dist/object/cloneDeepWith.mjs
function gye(e, t) {
- return cR(e, void 0, e, /* @__PURE__ */ new Map(), t);
+ return lR(e, void 0, e, /* @__PURE__ */ new Map(), t);
}
-function cR(e, t, n, r = /* @__PURE__ */ new Map(), i = void 0) {
+function lR(e, t, n, r = /* @__PURE__ */ new Map(), i = void 0) {
let a = i?.(e, t, n, r);
if (a !== void 0) return a;
- if (tR(e)) return e;
+ if (nR(e)) return e;
if (r.has(e)) return r.get(e);
if (Array.isArray(e)) {
let t = Array(e.length);
r.set(e, t);
- for (let a = 0; a < e.length; a++) t[a] = cR(e[a], a, n, r, i);
+ for (let a = 0; a < e.length; a++) t[a] = lR(e[a], a, n, r, i);
return Object.hasOwn(e, "index") && (t.index = e.index), Object.hasOwn(e, "input") && (t.input = e.input), t;
}
if (e instanceof Date) return new Date(e.getTime());
@@ -51272,71 +51324,71 @@ function cR(e, t, n, r = /* @__PURE__ */ new Map(), i = void 0) {
if (e instanceof Map) {
let t = /* @__PURE__ */ new Map();
r.set(e, t);
- for (let [a, o] of e) t.set(a, cR(o, a, n, r, i));
+ for (let [a, o] of e) t.set(a, lR(o, a, n, r, i));
return t;
}
if (e instanceof Set) {
let t = /* @__PURE__ */ new Set();
r.set(e, t);
- for (let a of e) t.add(cR(a, void 0, n, r, i));
+ for (let a of e) t.add(lR(a, void 0, n, r, i));
return t;
}
if (hye(e)) return e.subarray();
if (Yve(e)) {
let t = new (Object.getPrototypeOf(e)).constructor(e.length);
r.set(e, t);
- for (let a = 0; a < e.length; a++) t[a] = cR(e[a], a, n, r, i);
+ for (let a = 0; a < e.length; a++) t[a] = lR(e[a], a, n, r, i);
return t;
}
if (e instanceof ArrayBuffer || typeof SharedArrayBuffer < "u" && e instanceof SharedArrayBuffer) return e.slice(0);
if (e instanceof DataView) {
let t = new DataView(e.buffer.slice(0), e.byteOffset, e.byteLength);
- return r.set(e, t), lR(t, e, n, r, i), t;
+ return r.set(e, t), uR(t, e, n, r, i), t;
}
if (typeof File < "u" && e instanceof File) {
let t = new File([e], e.name, { type: e.type });
- return r.set(e, t), lR(t, e, n, r, i), t;
+ return r.set(e, t), uR(t, e, n, r, i), t;
}
if (typeof Blob < "u" && e instanceof Blob) {
let t = new Blob([e], { type: e.type });
- return r.set(e, t), lR(t, e, n, r, i), t;
+ return r.set(e, t), uR(t, e, n, r, i), t;
}
if (e instanceof Error) {
let t = structuredClone(e);
- return r.set(e, t), t.message = e.message, t.name = e.name, t.stack = e.stack, t.cause = e.cause, t.constructor = e.constructor, lR(t, e, n, r, i), t;
+ return r.set(e, t), t.message = e.message, t.name = e.name, t.stack = e.stack, t.cause = e.cause, t.constructor = e.constructor, uR(t, e, n, r, i), t;
}
if (e instanceof Boolean) {
let t = new Boolean(e.valueOf());
- return r.set(e, t), lR(t, e, n, r, i), t;
+ return r.set(e, t), uR(t, e, n, r, i), t;
}
if (e instanceof Number) {
let t = new Number(e.valueOf());
- return r.set(e, t), lR(t, e, n, r, i), t;
+ return r.set(e, t), uR(t, e, n, r, i), t;
}
if (e instanceof String) {
let t = new String(e.valueOf());
- return r.set(e, t), lR(t, e, n, r, i), t;
+ return r.set(e, t), uR(t, e, n, r, i), t;
}
if (typeof e == "object" && _ye(e)) {
let t = Object.create(Object.getPrototypeOf(e));
- return r.set(e, t), lR(t, e, n, r, i), t;
+ return r.set(e, t), uR(t, e, n, r, i), t;
}
return e;
}
-function lR(e, t, n = e, r, i) {
+function uR(e, t, n = e, r, i) {
let a = [...Object.keys(t), ...Xve(t)];
for (let o = 0; o < a.length; o++) {
let s = a[o], c = Object.getOwnPropertyDescriptor(e, s);
- (c == null || c.writable) && (e[s] = cR(t[s], s, n, r, i));
+ (c == null || c.writable) && (e[s] = lR(t[s], s, n, r, i));
}
}
function _ye(e) {
- switch (nR(e)) {
- case oR:
+ switch (rR(e)) {
+ case sR:
case nye:
case rye:
case aye:
- case aR:
+ case oR:
case $ve:
case pye:
case mye:
@@ -51344,11 +51396,11 @@ function _ye(e) {
case dye:
case fye:
case eye:
- case iR:
+ case aR:
case iye:
case Zve:
case tye:
- case rR:
+ case iR:
case Qve:
case oye:
case sye:
@@ -51360,44 +51412,44 @@ function _ye(e) {
//#endregion
//#region node_modules/es-toolkit/dist/object/cloneDeep.mjs
function vye(e) {
- return cR(e, void 0, e, /* @__PURE__ */ new Map(), void 0);
+ return lR(e, void 0, e, /* @__PURE__ */ new Map(), void 0);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/util/eq.mjs
-function uR(e, t) {
+function dR(e, t) {
return e === t || Number.isNaN(e) && Number.isNaN(t);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/predicate/isObject.mjs
-function dR(e) {
+function fR(e) {
return e !== null && (typeof e == "object" || typeof e == "function");
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/predicate/isMatchWith.mjs
-function fR(e, t, n) {
- return typeof n == "function" ? pR(e, t, function e(t, r, i, a, o, s) {
+function pR(e, t, n) {
+ return typeof n == "function" ? mR(e, t, function e(t, r, i, a, o, s) {
let c = n(t, r, i, a, o, s);
- return c === void 0 ? pR(t, r, e, s, !1) : !!c;
- }, /* @__PURE__ */ new Map(), !0) : fR(e, t, () => void 0);
+ return c === void 0 ? mR(t, r, e, s, !1) : !!c;
+ }, /* @__PURE__ */ new Map(), !0) : pR(e, t, () => void 0);
}
-function pR(e, t, n, r, i = !1) {
+function mR(e, t, n, r, i = !1) {
if (t === e) return !0;
switch (typeof t) {
case "object": return yye(e, t, n, r, i);
- case "function": return Object.keys(t).length > 0 ? pR(e, { ...t }, n, r, i) : uR(e, t);
- default: return dR(e) && i ? typeof t != "string" || t === "" : uR(e, t);
+ case "function": return Object.keys(t).length > 0 ? mR(e, { ...t }, n, r, i) : dR(e, t);
+ default: return fR(e) && i ? typeof t != "string" || t === "" : dR(e, t);
}
}
function yye(e, t, n, r, i = !1) {
if (t == null) return !0;
- if (Array.isArray(t)) return mR(e, t, n, r);
+ if (Array.isArray(t)) return hR(e, t, n, r);
if (t instanceof Map) return bye(e, t, n, r);
if (t instanceof Set) return xye(e, t, n, r);
let a = Object.keys(t);
if (e == null) return i && a.length === 0;
- if (i) tR(e) && (e = Object(e));
+ if (i) nR(e) && (e = Object(e));
else {
- let t = nR(e);
+ let t = rR(e);
if (t !== "[object Object]" && t !== "[object Arguments]") return !1;
}
if (a.length === 0) return !0;
@@ -51419,7 +51471,7 @@ function bye(e, t, n, r) {
for (let [i, a] of t.entries()) if (n(e.get(i), a, i, e, t, r) === !1) return !1;
return !0;
}
-function mR(e, t, n, r) {
+function hR(e, t, n, r) {
if (t.length === 0) return !0;
if (!Array.isArray(e)) return !1;
let i = /* @__PURE__ */ new Set();
@@ -51438,17 +51490,17 @@ function mR(e, t, n, r) {
return !0;
}
function xye(e, t, n, r) {
- return t.size === 0 || e instanceof Set && mR([...e], [...t], n, r);
+ return t.size === 0 || e instanceof Set && hR([...e], [...t], n, r);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/predicate/isMatch.mjs
-function hR(e, t) {
- return fR(e, t, () => void 0);
+function gR(e, t) {
+ return pR(e, t, () => void 0);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/predicate/matches.mjs
function Sye(e) {
- return e = vye(e), (t) => hR(t, e);
+ return e = vye(e), (t) => gR(t, e);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/object/cloneDeepWith.mjs
@@ -51457,20 +51509,20 @@ function Cye(e, t) {
let o = t?.(n, r, i, a);
if (o !== void 0) return o;
if (typeof e == "object") {
- if (nR(e) === "[object Object]" && typeof e.constructor != "function") {
+ if (rR(e) === "[object Object]" && typeof e.constructor != "function") {
let t = {};
- return a.set(e, t), lR(t, e, i, a), t;
+ return a.set(e, t), uR(t, e, i, a), t;
}
switch (Object.prototype.toString.call(e)) {
+ case aR:
case iR:
- case rR:
- case aR: {
+ case oR: {
let t = new e.constructor(e?.valueOf());
- return lR(t, e), t;
+ return uR(t, e), t;
}
- case oR: {
+ case sR: {
let t = {};
- return lR(t, e), t.length = e.length, t[Symbol.iterator] = e[Symbol.iterator], t;
+ return uR(t, e), t.length = e.length, t[Symbol.iterator] = e[Symbol.iterator], t;
}
default: return;
}
@@ -51485,7 +51537,7 @@ function wye(e) {
//#endregion
//#region node_modules/es-toolkit/dist/compat/_internal/isIndex.mjs
var Tye = /^(?:0|[1-9]\d*)$/;
-function gR(e, t = 2 ** 53 - 1) {
+function _R(e, t = 2 ** 53 - 1) {
switch (typeof e) {
case "number": return Number.isInteger(e) && e >= 0 && e < t;
case "symbol": return !1;
@@ -51495,17 +51547,17 @@ function gR(e, t = 2 ** 53 - 1) {
//#endregion
//#region node_modules/es-toolkit/dist/compat/predicate/isArguments.mjs
function Eye(e) {
- return typeof e == "object" && !!e && nR(e) === "[object Arguments]";
+ return typeof e == "object" && !!e && rR(e) === "[object Arguments]";
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/object/has.mjs
function Dye(e, t) {
let n;
- if (n = Array.isArray(t) ? t : typeof t == "string" && vL(t) && !(t in Object(e)) ? SL(t) : [t], n.length === 0) return !1;
+ if (n = Array.isArray(t) ? t : typeof t == "string" && yL(t) && !(t in Object(e)) ? CL(t) : [t], n.length === 0) return !1;
let r = e;
for (let e = 0; e < n.length; e++) {
- let t = yL(n[e]);
- if ((r == null || !Object.hasOwn(r, t)) && !((Array.isArray(r) || Eye(r)) && gR(t) && Number(t) < r.length)) return !1;
+ let t = bL(n[e]);
+ if ((r == null || !Object.hasOwn(r, t)) && !((Array.isArray(r) || Eye(r)) && _R(t) && Number(t) < r.length)) return !1;
r = r[t];
}
return !0;
@@ -51517,17 +51569,17 @@ function Oye(e, t) {
case "object":
Object.is(e?.valueOf(), -0) && (e = "-0");
break;
- case "number": e = yL(e);
+ case "number": e = bL(e);
}
return t = wye(t), function(n) {
- let r = CL(n, e);
- return r === void 0 ? Dye(n, e) : t === void 0 ? r === void 0 : hR(r, t);
+ let r = wL(n, e);
+ return r === void 0 ? Dye(n, e) : t === void 0 ? r === void 0 : gR(r, t);
};
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/util/iteratee.mjs
-function _R(e) {
- if (e == null) return $L;
+function vR(e) {
+ if (e == null) return eR;
switch (typeof e) {
case "function": return e;
case "object": return Array.isArray(e) && e.length === 2 ? Oye(e[0], e[1]) : Sye(e);
@@ -51541,13 +51593,13 @@ function kye(e) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/array/uniqBy.mjs
-function vR(e, t = $L) {
- return eR(e) ? Gve(Array.from(e), Kve(_R(t), 1)).map(kye) : [];
+function yR(e, t = eR) {
+ return tR(e) ? Gve(Array.from(e), Kve(vR(t), 1)).map(kye) : [];
}
//#endregion
//#region node_modules/recharts/es6/util/payload/getUniqPayload.js
-function yR(e, t, n) {
- return t === !0 ? vR(e, n) : typeof t == "function" ? vR(e, t) : e;
+function bR(e, t, n) {
+ return t === !0 ? yR(e, n) : typeof t == "function" ? yR(e, t) : e;
}
//#endregion
//#region node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js
@@ -51598,15 +51650,15 @@ var Aye = /* @__PURE__ */ Ee(((e) => {
};
})), jye = /* @__PURE__ */ Ee(((e, t) => {
t.exports = Aye();
-})), bR = /*#__PURE__*/ (0, R.createContext)(null), Mye = jye(), Nye = (e) => e, xR = () => {
- var e = (0, R.useContext)(bR);
+})), xR = /*#__PURE__*/ (0, R.createContext)(null), Mye = jye(), Nye = (e) => e, SR = () => {
+ var e = (0, R.useContext)(xR);
return e ? e.store.dispatch : Nye;
-}, SR = () => {}, Pye = () => SR, Fye = (e, t) => e === t;
+}, CR = () => {}, Pye = () => CR, Fye = (e, t) => e === t;
function Q(e) {
- var t = (0, R.useContext)(bR), n = (0, R.useMemo)(() => t ? (t) => {
+ var t = (0, R.useContext)(xR), n = (0, R.useMemo)(() => t ? (t) => {
if (t != null) return e(t);
- } : SR, [t, e]);
- return (0, Mye.useSyncExternalStoreWithSelector)(t ? t.subscription.addNestedSub : Pye, t ? t.store.getState : SR, t ? t.store.getState : SR, n, Fye);
+ } : CR, [t, e]);
+ return (0, Mye.useSyncExternalStoreWithSelector)(t ? t.subscription.addNestedSub : Pye, t ? t.store.getState : CR, t ? t.store.getState : CR, n, Fye);
}
//#endregion
//#region node_modules/reselect/dist/reselect.mjs
@@ -51622,7 +51674,7 @@ function Rye(e, t = "expected all items to be functions, instead received the fo
throw TypeError(`${t}[${n}]`);
}
}
-var CR = (e) => Array.isArray(e) ? e : [e];
+var wR = (e) => Array.isArray(e) ? e : [e];
function zye(e) {
let t = Array.isArray(e[0]) ? e[0] : e;
return Rye(t, "createSelector expects all input-selectors to be functions, but received the following types: "), t;
@@ -51639,8 +51691,8 @@ var Vye = class {
deref() {
return this.value;
}
-}, Hye = typeof WeakRef < "u" ? WeakRef : Vye, Uye = 0, wR = 1;
-function TR() {
+}, Hye = typeof WeakRef < "u" ? WeakRef : Vye, Uye = 0, TR = 1;
+function ER() {
return {
s: Uye,
v: void 0,
@@ -51648,8 +51700,8 @@ function TR() {
p: null
};
}
-function ER(e, t = {}) {
- let n = TR(), { resultEqualityCheck: r } = t, i, a = 0;
+function DR(e, t = {}) {
+ let n = ER(), { resultEqualityCheck: r } = t, i, a = 0;
function o() {
let t = n, { length: o } = arguments;
for (let e = 0, n = o; e < n; e++) {
@@ -51658,24 +51710,24 @@ function ER(e, t = {}) {
let e = t.o;
e === null && (t.o = e = /* @__PURE__ */ new WeakMap());
let r = e.get(n);
- r === void 0 ? (t = TR(), e.set(n, t)) : t = r;
+ r === void 0 ? (t = ER(), e.set(n, t)) : t = r;
} else {
let e = t.p;
e === null && (t.p = e = /* @__PURE__ */ new Map());
let r = e.get(n);
- r === void 0 ? (t = TR(), e.set(n, t)) : t = r;
+ r === void 0 ? (t = ER(), e.set(n, t)) : t = r;
}
}
let s = t, c;
- if (t.s === wR) c = t.v;
+ if (t.s === TR) c = t.v;
else if (c = e.apply(null, arguments), a++, r) {
let e = i?.deref?.() ?? i;
e != null && r(e, c) && (c = e, a !== 0 && a--), i = typeof c == "object" && c || typeof c == "function" ? new Hye(c) : c;
}
- return s.s = wR, s.v = c, c;
+ return s.s = TR, s.v = c, c;
}
return o.clearCache = () => {
- n = TR(), o.resetResultsCount();
+ n = ER(), o.resetResultsCount();
}, o.resultsCount = () => a, o.resetResultsCount = () => {
a = 0;
}, o;
@@ -51687,10 +51739,10 @@ function Wye(e, ...t) {
} : e, r = (...e) => {
let t = 0, r = 0, i, a = {}, o = e.pop();
typeof o == "object" && (a = o, o = e.pop()), Iye(o, `createSelector expects an output function after the inputs, but received: [${typeof o}]`);
- let { memoize: s, memoizeOptions: c = [], argsMemoize: l = ER, argsMemoizeOptions: u = [], devModeChecks: d = {} } = {
+ let { memoize: s, memoizeOptions: c = [], argsMemoize: l = DR, argsMemoizeOptions: u = [], devModeChecks: d = {} } = {
...n,
...a
- }, f = CR(c), p = CR(u), m = zye(e), h = s(function() {
+ }, f = wR(c), p = wR(u), m = zye(e), h = s(function() {
return t++, o.apply(null, arguments);
}, ...f), g = l(function() {
r++;
@@ -51716,7 +51768,7 @@ function Wye(e, ...t) {
};
return Object.assign(r, { withTypes: () => r }), r;
}
-var $ = /* @__PURE__ */ Wye(ER), Gye = Object.assign((e, t = $) => {
+var $ = /* @__PURE__ */ Wye(DR), Gye = Object.assign((e, t = $) => {
Lye(e, `createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);
let n = Object.keys(e);
return t(n.map((t) => e[t]), (...e) => e.reduce((e, t, r) => (e[n[r]] = t, e), {}));
@@ -51734,17 +51786,17 @@ function Kye(e, t = 1) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/_internal/isIterateeCall.mjs
-function DR(e, t, n) {
- return dR(n) && (typeof t == "number" && eR(n) && gR(t) && t < n.length || typeof t == "string" && t in n) ? uR(n[t], e) : !1;
+function OR(e, t, n) {
+ return fR(n) && (typeof t == "number" && tR(n) && _R(t) && t < n.length || typeof t == "string" && t in n) ? dR(n[t], e) : !1;
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/_internal/compareValues.mjs
-function OR(e) {
+function kR(e) {
return typeof e == "symbol" ? 1 : e === null ? 2 : e === void 0 ? 3 : e === e ? 0 : 4;
}
var qye = (e, t, n) => {
if (e !== t) {
- let r = OR(e), i = OR(t);
+ let r = kR(e), i = kR(t);
if (r === i && r === 0) {
if (e < t) return n === "desc" ? 1 : -1;
if (e > t) return n === "desc" ? -1 : 1;
@@ -51754,13 +51806,13 @@ var qye = (e, t, n) => {
return 0;
}, Jye = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, Yye = /^\w*$/;
function Xye(e, t) {
- return Array.isArray(e) ? !1 : typeof e == "number" || typeof e == "boolean" || e == null || bL(e) ? !0 : typeof e == "string" && (Yye.test(e) || !Jye.test(e)) || t != null && Object.hasOwn(t, e);
+ return Array.isArray(e) ? !1 : typeof e == "number" || typeof e == "boolean" || e == null || xL(e) ? !0 : typeof e == "string" && (Yye.test(e) || !Jye.test(e)) || t != null && Object.hasOwn(t, e);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/array/orderBy.mjs
function Zye(e, t, n, r) {
if (e == null) return [];
- n = r ? void 0 : n, Array.isArray(e) || (e = eR(e) ? Array.from(e) : Object.values(e)), Array.isArray(t) || (t = t == null ? [null] : [t]), t.length === 0 && (t = [null]), Array.isArray(n) || (n = n == null ? [] : [n]), n = n.map((e) => String(e));
+ n = r ? void 0 : n, Array.isArray(e) || (e = tR(e) ? Array.from(e) : Object.values(e)), Array.isArray(t) || (t = t == null ? [null] : [t]), t.length === 0 && (t = [null]), Array.isArray(n) || (n = n == null ? [] : [n]), n = n.map((e) => String(e));
let i = (e, t) => {
let n = e, r = 0;
for (; r < t.length && n != null; ++r) n = n[t[r]];
@@ -51770,7 +51822,7 @@ function Zye(e, t, n, r) {
if (t != null) return typeof e == "object" && "key" in e ? Object.hasOwn(t, e.key) ? t[e.key] : i(t, e.path) : typeof e == "function" ? e(t) : Array.isArray(e) ? i(t, e) : t[e];
}, o = t.map((e) => (Array.isArray(e) && e.length === 1 && (e = e[0]), e == null || typeof e == "function" || Array.isArray(e) || Xye(e) ? e : {
key: e,
- path: SL(e)
+ path: CL(e)
}));
return e.map((e) => ({
original: e,
@@ -51785,15 +51837,15 @@ function Zye(e, t, n, r) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/array/sortBy.mjs
-function kR(e, ...t) {
+function AR(e, ...t) {
let n = t.length;
- return n > 1 && DR(e, t[0], t[1]) ? t = [] : n > 2 && DR(t[0], t[1], t[2]) && (t = [t[0]]), Zye(e, Kye(t), ["asc"]);
+ return n > 1 && OR(e, t[0], t[1]) ? t = [] : n > 2 && OR(t[0], t[1], t[2]) && (t = [t[0]]), Zye(e, Kye(t), ["asc"]);
}
//#endregion
//#region node_modules/recharts/es6/state/selectors/legendSelectors.js
-var AR = (e) => e.legend.settings, Qye = (e) => e.legend.size, $ye = $([(e) => e.legend.payload, AR], (e, t) => {
+var jR = (e) => e.legend.settings, Qye = (e) => e.legend.size, $ye = $([(e) => e.legend.payload, jR], (e, t) => {
var { itemSorter: n } = t, r = e.flat(1);
- return n ? kR(r, n) : r;
+ return n ? AR(r, n) : r;
});
//#endregion
//#region node_modules/recharts/es6/context/legendPayloadContext.js
@@ -51802,8 +51854,8 @@ function ebe() {
}
//#endregion
//#region node_modules/recharts/es6/util/useElementOffset.js
-var jR = 1;
-function MR() {
+var MR = 1;
+function NR() {
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [], [t, n] = (0, R.useState)({
height: 0,
left: 0,
@@ -51818,7 +51870,7 @@ function MR() {
top: r.top,
width: r.width
};
- (Math.abs(i.height - t.height) > jR || Math.abs(i.left - t.left) > jR || Math.abs(i.top - t.top) > jR || Math.abs(i.width - t.width) > jR) && n({
+ (Math.abs(i.height - t.height) > MR || Math.abs(i.left - t.left) > MR || Math.abs(i.top - t.top) > MR || Math.abs(i.width - t.width) > MR) && n({
height: i.height,
left: i.left,
top: i.top,
@@ -51835,26 +51887,26 @@ function MR() {
}
//#endregion
//#region node_modules/redux/dist/redux.mjs
-function NR(e) {
+function PR(e) {
return `Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `;
}
-var PR = typeof Symbol == "function" && Symbol.observable || "@@observable", FR = () => Math.random().toString(36).substring(7).split("").join("."), IR = {
- INIT: `@@redux/INIT${/* @__PURE__ */ FR()}`,
- REPLACE: `@@redux/REPLACE${/* @__PURE__ */ FR()}`,
- PROBE_UNKNOWN_ACTION: () => `@@redux/PROBE_UNKNOWN_ACTION${FR()}`
+var FR = typeof Symbol == "function" && Symbol.observable || "@@observable", IR = () => Math.random().toString(36).substring(7).split("").join("."), LR = {
+ INIT: `@@redux/INIT${/* @__PURE__ */ IR()}`,
+ REPLACE: `@@redux/REPLACE${/* @__PURE__ */ IR()}`,
+ PROBE_UNKNOWN_ACTION: () => `@@redux/PROBE_UNKNOWN_ACTION${IR()}`
};
-function LR(e) {
+function RR(e) {
if (typeof e != "object" || !e) return !1;
let t = e;
for (; Object.getPrototypeOf(t) !== null;) t = Object.getPrototypeOf(t);
return Object.getPrototypeOf(e) === t || Object.getPrototypeOf(e) === null;
}
-function RR(e, t, n) {
- if (typeof e != "function") throw Error(NR(2));
- if (typeof t == "function" && typeof n == "function" || typeof n == "function" && typeof arguments[3] == "function") throw Error(NR(0));
+function zR(e, t, n) {
+ if (typeof e != "function") throw Error(PR(2));
+ if (typeof t == "function" && typeof n == "function" || typeof n == "function" && typeof arguments[3] == "function") throw Error(PR(0));
if (typeof t == "function" && n === void 0 && (n = t, t = void 0), n !== void 0) {
- if (typeof n != "function") throw Error(NR(1));
- return n(RR)(e, t);
+ if (typeof n != "function") throw Error(PR(1));
+ return n(zR)(e, t);
}
let r = e, i = t, a = /* @__PURE__ */ new Map(), o = a, s = 0, c = !1;
function l() {
@@ -51863,27 +51915,27 @@ function RR(e, t, n) {
}));
}
function u() {
- if (c) throw Error(NR(3));
+ if (c) throw Error(PR(3));
return i;
}
function d(e) {
- if (typeof e != "function") throw Error(NR(4));
- if (c) throw Error(NR(5));
+ if (typeof e != "function") throw Error(PR(4));
+ if (c) throw Error(PR(5));
let t = !0;
l();
let n = s++;
return o.set(n, e), function() {
if (t) {
- if (c) throw Error(NR(6));
+ if (c) throw Error(PR(6));
t = !1, l(), o.delete(n), a = null;
}
};
}
function f(e) {
- if (!LR(e)) throw Error(NR(7));
- if (e.type === void 0) throw Error(NR(8));
- if (typeof e.type != "string") throw Error(NR(17));
- if (c) throw Error(NR(9));
+ if (!RR(e)) throw Error(PR(7));
+ if (e.type === void 0) throw Error(PR(8));
+ if (typeof e.type != "string") throw Error(PR(17));
+ if (c) throw Error(PR(9));
try {
c = !0, i = r(i, e);
} finally {
@@ -51894,41 +51946,41 @@ function RR(e, t, n) {
}), e;
}
function p(e) {
- if (typeof e != "function") throw Error(NR(10));
- r = e, f({ type: IR.REPLACE });
+ if (typeof e != "function") throw Error(PR(10));
+ r = e, f({ type: LR.REPLACE });
}
function m() {
let e = d;
return {
subscribe(t) {
- if (typeof t != "object" || !t) throw Error(NR(11));
+ if (typeof t != "object" || !t) throw Error(PR(11));
function n() {
let e = t;
e.next && e.next(u());
}
return n(), { unsubscribe: e(n) };
},
- [PR]() {
+ [FR]() {
return this;
}
};
}
- return f({ type: IR.INIT }), {
+ return f({ type: LR.INIT }), {
dispatch: f,
subscribe: d,
getState: u,
replaceReducer: p,
- [PR]: m
+ [FR]: m
};
}
function tbe(e) {
Object.keys(e).forEach((t) => {
let n = e[t];
- if (n(void 0, { type: IR.INIT }) === void 0) throw Error(NR(12));
- if (n(void 0, { type: IR.PROBE_UNKNOWN_ACTION() }) === void 0) throw Error(NR(13));
+ if (n(void 0, { type: LR.INIT }) === void 0) throw Error(PR(12));
+ if (n(void 0, { type: LR.PROBE_UNKNOWN_ACTION() }) === void 0) throw Error(PR(13));
});
}
-function zR(e) {
+function BR(e) {
let t = Object.keys(e), n = {};
for (let r = 0; r < t.length; r++) {
let i = t[r];
@@ -51945,124 +51997,124 @@ function zR(e) {
let a = !1, o = {};
for (let i = 0; i < r.length; i++) {
let s = r[i], c = n[s], l = e[s], u = c(l, t);
- if (u === void 0) throw t && t.type, Error(NR(14));
+ if (u === void 0) throw t && t.type, Error(PR(14));
o[s] = u, a ||= u !== l;
}
return a ||= r.length !== Object.keys(e).length, a ? o : e;
};
}
-function BR(...e) {
+function VR(...e) {
return e.length === 0 ? (e) => e : e.length === 1 ? e[0] : e.reduce((e, t) => (...n) => e(t(...n)));
}
function nbe(...e) {
return (t) => (n, r) => {
let i = t(n, r), a = () => {
- throw Error(NR(15));
+ throw Error(PR(15));
}, o = {
getState: i.getState,
dispatch: (e, ...t) => a(e, ...t)
};
- return a = BR(...e.map((e) => e(o)))(i.dispatch), {
+ return a = VR(...e.map((e) => e(o)))(i.dispatch), {
...i,
dispatch: a
};
};
}
-function VR(e) {
- return LR(e) && "type" in e && typeof e.type == "string";
+function HR(e) {
+ return RR(e) && "type" in e && typeof e.type == "string";
}
//#endregion
//#region node_modules/@reduxjs/toolkit/node_modules/immer/dist/immer.mjs
-var HR = Symbol.for("immer-nothing"), UR = Symbol.for("immer-draftable"), WR = Symbol.for("immer-state");
-function GR(e, ...t) {
+var UR = Symbol.for("immer-nothing"), WR = Symbol.for("immer-draftable"), GR = Symbol.for("immer-state");
+function KR(e, ...t) {
throw Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`);
}
-var KR = Object, qR = KR.getPrototypeOf, JR = "constructor", YR = "prototype", XR = "configurable", ZR = "enumerable", QR = "writable", $R = "value", ez = (e) => !!e && !!e[WR];
-function tz(e) {
- return e ? rz(e) || lz(e) || !!e[UR] || !!e[JR]?.[UR] || uz(e) || dz(e) : !1;
+var qR = Object, JR = qR.getPrototypeOf, YR = "constructor", XR = "prototype", ZR = "configurable", QR = "enumerable", $R = "writable", ez = "value", tz = (e) => !!e && !!e[GR];
+function nz(e) {
+ return e ? iz(e) || uz(e) || !!e[WR] || !!e[YR]?.[WR] || dz(e) || fz(e) : !1;
}
-var rbe = KR[YR][JR].toString(), nz = /* @__PURE__ */ new WeakMap();
-function rz(e) {
- if (!e || !fz(e)) return !1;
- let t = qR(e);
- if (t === null || t === KR[YR]) return !0;
- let n = KR.hasOwnProperty.call(t, JR) && t[JR];
+var rbe = qR[XR][YR].toString(), rz = /* @__PURE__ */ new WeakMap();
+function iz(e) {
+ if (!e || !pz(e)) return !1;
+ let t = JR(e);
+ if (t === null || t === qR[XR]) return !0;
+ let n = qR.hasOwnProperty.call(t, YR) && t[YR];
if (n === Object) return !0;
- if (!pz(n)) return !1;
- let r = nz.get(n);
- return r === void 0 && (r = Function.toString.call(n), nz.set(n, r)), r === rbe;
+ if (!mz(n)) return !1;
+ let r = rz.get(n);
+ return r === void 0 && (r = Function.toString.call(n), rz.set(n, r)), r === rbe;
}
-function iz(e, t, n = !0) {
- az(e) === 0 ? (n ? Reflect.ownKeys(e) : KR.keys(e)).forEach((n) => {
+function az(e, t, n = !0) {
+ oz(e) === 0 ? (n ? Reflect.ownKeys(e) : qR.keys(e)).forEach((n) => {
t(n, e[n], e);
}) : e.forEach((n, r) => t(r, n, e));
}
-function az(e) {
- let t = e[WR];
- return t ? t.type_ : lz(e) ? 1 : uz(e) ? 2 : dz(e) ? 3 : 0;
+function oz(e) {
+ let t = e[GR];
+ return t ? t.type_ : uz(e) ? 1 : dz(e) ? 2 : fz(e) ? 3 : 0;
}
-var oz = (e, t, n = az(e)) => n === 2 ? e.has(t) : KR[YR].hasOwnProperty.call(e, t), sz = (e, t, n = az(e)) => n === 2 ? e.get(t) : e[t], cz = (e, t, n, r = az(e)) => {
+var sz = (e, t, n = oz(e)) => n === 2 ? e.has(t) : qR[XR].hasOwnProperty.call(e, t), cz = (e, t, n = oz(e)) => n === 2 ? e.get(t) : e[t], lz = (e, t, n, r = oz(e)) => {
r === 2 ? e.set(t, n) : r === 3 ? e.add(n) : e[t] = n;
};
function ibe(e, t) {
return e === t ? e !== 0 || 1 / e == 1 / t : e !== e && t !== t;
}
-var lz = Array.isArray, uz = (e) => e instanceof Map, dz = (e) => e instanceof Set, fz = (e) => typeof e == "object", pz = (e) => typeof e == "function", mz = (e) => typeof e == "boolean";
+var uz = Array.isArray, dz = (e) => e instanceof Map, fz = (e) => e instanceof Set, pz = (e) => typeof e == "object", mz = (e) => typeof e == "function", hz = (e) => typeof e == "boolean";
function abe(e) {
let t = +e;
return Number.isInteger(t) && String(t) === e;
}
-var hz = (e) => e.copy_ || e.base_, gz = (e) => e.modified_ ? e.copy_ : e.base_;
-function _z(e, t) {
- if (uz(e)) return new Map(e);
- if (dz(e)) return new Set(e);
- if (lz(e)) return Array[YR].slice.call(e);
- let n = rz(e);
+var gz = (e) => e.copy_ || e.base_, _z = (e) => e.modified_ ? e.copy_ : e.base_;
+function vz(e, t) {
+ if (dz(e)) return new Map(e);
+ if (fz(e)) return new Set(e);
+ if (uz(e)) return Array[XR].slice.call(e);
+ let n = iz(e);
if (t === !0 || t === "class_only" && !n) {
- let t = KR.getOwnPropertyDescriptors(e);
- delete t[WR];
+ let t = qR.getOwnPropertyDescriptors(e);
+ delete t[GR];
let n = Reflect.ownKeys(t);
for (let r = 0; r < n.length; r++) {
let i = n[r], a = t[i];
- a[QR] === !1 && (a[QR] = !0, a[XR] = !0), (a.get || a.set) && (t[i] = {
- [XR]: !0,
- [QR]: !0,
- [ZR]: a[ZR],
- [$R]: e[i]
+ a[$R] === !1 && (a[$R] = !0, a[ZR] = !0), (a.get || a.set) && (t[i] = {
+ [ZR]: !0,
+ [$R]: !0,
+ [QR]: a[QR],
+ [ez]: e[i]
});
}
- return KR.create(qR(e), t);
+ return qR.create(JR(e), t);
}
{
- let t = qR(e);
+ let t = JR(e);
if (t !== null && n) return { ...e };
- let r = KR.create(t);
- return KR.assign(r, e);
- }
-}
-function vz(e, t = !1) {
- return bz(e) || ez(e) || !tz(e) ? e : (az(e) > 1 && KR.defineProperties(e, {
- set: yz,
- add: yz,
- clear: yz,
- delete: yz
- }), KR.freeze(e), t && iz(e, (e, t) => {
- vz(t, !0);
+ let r = qR.create(t);
+ return qR.assign(r, e);
+ }
+}
+function yz(e, t = !1) {
+ return xz(e) || tz(e) || !nz(e) ? e : (oz(e) > 1 && qR.defineProperties(e, {
+ set: bz,
+ add: bz,
+ clear: bz,
+ delete: bz
+ }), qR.freeze(e), t && az(e, (e, t) => {
+ yz(t, !0);
}, !1), e);
}
function obe() {
- GR(2);
+ KR(2);
}
-var yz = { [$R]: obe };
-function bz(e) {
- return e === null || !fz(e) || KR.isFrozen(e);
+var bz = { [ez]: obe };
+function xz(e) {
+ return e === null || !pz(e) || qR.isFrozen(e);
}
-var xz = "MapSet", Sz = "Patches", Cz = "ArrayMethods", wz = {};
-function Tz(e) {
- let t = wz[e];
- return t || GR(0, e), t;
+var Sz = "MapSet", Cz = "Patches", wz = "ArrayMethods", Tz = {};
+function Ez(e) {
+ let t = Tz[e];
+ return t || KR(0, e), t;
}
-var Ez = (e) => !!wz[e], Dz, Oz = () => Dz, sbe = (e, t) => ({
+var Dz = (e) => !!Tz[e], Oz, kz = () => Oz, sbe = (e, t) => ({
drafts_: [],
parent_: e,
immer_: t,
@@ -52070,114 +52122,114 @@ var Ez = (e) => !!wz[e], Dz, Oz = () => Dz, sbe = (e, t) => ({
unfinalizedDrafts_: 0,
handledSet_: /* @__PURE__ */ new Set(),
processedForPatches_: /* @__PURE__ */ new Set(),
- mapSetPlugin_: Ez(xz) ? Tz(xz) : void 0,
- arrayMethodsPlugin_: Ez(Cz) ? Tz(Cz) : void 0
+ mapSetPlugin_: Dz(Sz) ? Ez(Sz) : void 0,
+ arrayMethodsPlugin_: Dz(wz) ? Ez(wz) : void 0
});
-function kz(e, t) {
- t && (e.patchPlugin_ = Tz(Sz), e.patches_ = [], e.inversePatches_ = [], e.patchListener_ = t);
-}
-function Az(e) {
- jz(e), e.drafts_.forEach(cbe), e.drafts_ = null;
+function Az(e, t) {
+ t && (e.patchPlugin_ = Ez(Cz), e.patches_ = [], e.inversePatches_ = [], e.patchListener_ = t);
}
function jz(e) {
- e === Dz && (Dz = e.parent_);
+ Mz(e), e.drafts_.forEach(cbe), e.drafts_ = null;
}
-var Mz = (e) => Dz = sbe(Dz, e);
+function Mz(e) {
+ e === Oz && (Oz = e.parent_);
+}
+var Nz = (e) => Oz = sbe(Oz, e);
function cbe(e) {
- let t = e[WR];
+ let t = e[GR];
t.type_ === 0 || t.type_ === 1 ? t.revoke_() : t.revoked_ = !0;
}
-function Nz(e, t) {
+function Pz(e, t) {
t.unfinalizedDrafts_ = t.drafts_.length;
let n = t.drafts_[0];
if (e !== void 0 && e !== n) {
- n[WR].modified_ && (Az(t), GR(4)), tz(e) && (e = Pz(t, e));
+ n[GR].modified_ && (jz(t), KR(4)), nz(e) && (e = Fz(t, e));
let { patchPlugin_: r } = t;
- r && r.generateReplacementPatches_(n[WR].base_, e, t);
- } else e = Pz(t, n);
- return lbe(t, e, !0), Az(t), t.patches_ && t.patchListener_(t.patches_, t.inversePatches_), e === HR ? void 0 : e;
-}
-function Pz(e, t) {
- if (bz(t)) return t;
- let n = t[WR];
- if (!n) return zz(t, e.handledSet_, e);
- if (!Iz(n, e)) return t;
+ r && r.generateReplacementPatches_(n[GR].base_, e, t);
+ } else e = Fz(t, n);
+ return lbe(t, e, !0), jz(t), t.patches_ && t.patchListener_(t.patches_, t.inversePatches_), e === UR ? void 0 : e;
+}
+function Fz(e, t) {
+ if (xz(t)) return t;
+ let n = t[GR];
+ if (!n) return Bz(t, e.handledSet_, e);
+ if (!Lz(n, e)) return t;
if (!n.modified_) return n.base_;
if (!n.finalized_) {
let { callbacks_: t } = n;
if (t) for (; t.length > 0;) t.pop()(e);
- Rz(n, e);
+ zz(n, e);
}
return n.copy_;
}
function lbe(e, t, n = !1) {
- !e.parent_ && e.immer_.autoFreeze_ && e.canAutoFreeze_ && vz(t, n);
+ !e.parent_ && e.immer_.autoFreeze_ && e.canAutoFreeze_ && yz(t, n);
}
-function Fz(e) {
+function Iz(e) {
e.finalized_ = !0, e.scope_.unfinalizedDrafts_--;
}
-var Iz = (e, t) => e.scope_ === t, ube = [];
-function Lz(e, t, n, r) {
- let i = hz(e), a = e.type_;
- if (r !== void 0 && sz(i, r, a) === t) {
- cz(i, r, n, a);
+var Lz = (e, t) => e.scope_ === t, ube = [];
+function Rz(e, t, n, r) {
+ let i = gz(e), a = e.type_;
+ if (r !== void 0 && cz(i, r, a) === t) {
+ lz(i, r, n, a);
return;
}
if (!e.draftLocations_) {
let t = e.draftLocations_ = /* @__PURE__ */ new Map();
- iz(i, (e, n) => {
- if (ez(n)) {
+ az(i, (e, n) => {
+ if (tz(n)) {
let r = t.get(n) || [];
r.push(e), t.set(n, r);
}
});
}
let o = e.draftLocations_.get(t) ?? ube;
- for (let e of o) cz(i, e, n, a);
+ for (let e of o) lz(i, e, n, a);
}
function dbe(e, t, n) {
e.callbacks_.push(function(r) {
let i = t;
- if (!i || !Iz(i, r)) return;
+ if (!i || !Lz(i, r)) return;
r.mapSetPlugin_?.fixSetContents(i);
- let a = gz(i);
- Lz(e, i.draft_ ?? i, a, n), Rz(i, r);
+ let a = _z(i);
+ Rz(e, i.draft_ ?? i, a, n), zz(i, r);
});
}
-function Rz(e, t) {
+function zz(e, t) {
if (e.modified_ && !e.finalized_ && (e.type_ === 3 || e.type_ === 1 && e.allIndicesReassigned_ || (e.assigned_?.size ?? 0) > 0)) {
let { patchPlugin_: n } = t;
if (n) {
let r = n.getPath(e);
r && n.generatePatches_(e, r, t);
}
- Fz(e);
+ Iz(e);
}
}
function fbe(e, t, n) {
let { scope_: r } = e;
- if (ez(n)) {
- let i = n[WR];
- Iz(i, r) && i.callbacks_.push(function() {
- Gz(e), Lz(e, n, gz(i), t);
+ if (tz(n)) {
+ let i = n[GR];
+ Lz(i, r) && i.callbacks_.push(function() {
+ Kz(e), Rz(e, n, _z(i), t);
});
- } else tz(n) && e.callbacks_.push(function() {
- let i = hz(e);
- e.type_ === 3 ? i.has(n) && zz(n, r.handledSet_, r) : sz(i, t, e.type_) === n && r.drafts_.length > 1 && (e.assigned_.get(t) ?? !1) === !0 && e.copy_ && zz(sz(e.copy_, t, e.type_), r.handledSet_, r);
+ } else nz(n) && e.callbacks_.push(function() {
+ let i = gz(e);
+ e.type_ === 3 ? i.has(n) && Bz(n, r.handledSet_, r) : cz(i, t, e.type_) === n && r.drafts_.length > 1 && (e.assigned_.get(t) ?? !1) === !0 && e.copy_ && Bz(cz(e.copy_, t, e.type_), r.handledSet_, r);
});
}
-function zz(e, t, n) {
- return !n.immer_.autoFreeze_ && n.unfinalizedDrafts_ < 1 || ez(e) || t.has(e) || !tz(e) || bz(e) ? e : (t.add(e), iz(e, (r, i) => {
- if (ez(i)) {
- let t = i[WR];
- Iz(t, n) && (cz(e, r, gz(t), e.type_), Fz(t));
- } else tz(i) && zz(i, t, n);
+function Bz(e, t, n) {
+ return !n.immer_.autoFreeze_ && n.unfinalizedDrafts_ < 1 || tz(e) || t.has(e) || !nz(e) || xz(e) ? e : (t.add(e), az(e, (r, i) => {
+ if (tz(i)) {
+ let t = i[GR];
+ Lz(t, n) && (lz(e, r, _z(t), e.type_), Iz(t));
+ } else nz(i) && Bz(i, t, n);
}), e);
}
function pbe(e, t) {
- let n = lz(e), r = {
+ let n = uz(e), r = {
type_: +!!n,
- scope_: t ? t.scope_ : Oz(),
+ scope_: t ? t.scope_ : kz(),
modified_: !1,
finalized_: !1,
assigned_: void 0,
@@ -52188,108 +52240,108 @@ function pbe(e, t) {
revoke_: null,
isManual_: !1,
callbacks_: void 0
- }, i = r, a = Bz;
- n && (i = [r], a = Vz);
+ }, i = r, a = Vz;
+ n && (i = [r], a = Hz);
let { revoke: o, proxy: s } = Proxy.revocable(i, a);
return r.draft_ = s, r.revoke_ = o, [s, r];
}
-var Bz = {
+var Vz = {
get(e, t) {
- if (t === WR) return e;
+ if (t === GR) return e;
let n = e.scope_.arrayMethodsPlugin_, r = e.type_ === 1 && typeof t == "string";
if (r && n?.isArrayOperationMethod(t)) return n.createMethodInterceptor(e, t);
- let i = hz(e);
- if (!oz(i, t, e.type_)) return hbe(e, i, t);
+ let i = gz(e);
+ if (!sz(i, t, e.type_)) return hbe(e, i, t);
let a = i[t];
- if (e.finalized_ || !tz(a) || r && e.operationMethod && n?.isMutatingArrayMethod(e.operationMethod) && abe(t)) return a;
- if (a === Hz(e.base_, t) || mbe(e, t, a)) {
- Gz(e);
- let n = e.type_ === 1 ? +t : t, r = Kz(e.scope_, a, e, n);
+ if (e.finalized_ || !nz(a) || r && e.operationMethod && n?.isMutatingArrayMethod(e.operationMethod) && abe(t)) return a;
+ if (a === Uz(e.base_, t) || mbe(e, t, a)) {
+ Kz(e);
+ let n = e.type_ === 1 ? +t : t, r = qz(e.scope_, a, e, n);
return e.copy_[n] = r;
}
return a;
},
has(e, t) {
- return t in hz(e);
+ return t in gz(e);
},
ownKeys(e) {
- return Reflect.ownKeys(hz(e));
+ return Reflect.ownKeys(gz(e));
},
set(e, t, n) {
- let r = Uz(hz(e), t);
+ let r = Wz(gz(e), t);
if (r?.set) return r.set.call(e.draft_, n), !0;
if (!e.modified_) {
- let r = Hz(hz(e), t), i = r?.[WR];
+ let r = Uz(gz(e), t), i = r?.[GR];
if (i && i.base_ === n) return e.copy_[t] = n, e.assigned_.set(t, !1), !0;
- if (ibe(n, r) && (n !== void 0 || oz(e.base_, t, e.type_))) return !0;
- Gz(e), Wz(e);
+ if (ibe(n, r) && (n !== void 0 || sz(e.base_, t, e.type_))) return !0;
+ Kz(e), Gz(e);
}
- return e.copy_[t] === n && (n !== void 0 || oz(e.copy_, t, e.type_)) || Number.isNaN(n) && Number.isNaN(e.copy_[t]) ? !0 : (e.copy_[t] = n, e.assigned_.set(t, !0), fbe(e, t, n), !0);
+ return e.copy_[t] === n && (n !== void 0 || sz(e.copy_, t, e.type_)) || Number.isNaN(n) && Number.isNaN(e.copy_[t]) ? !0 : (e.copy_[t] = n, e.assigned_.set(t, !0), fbe(e, t, n), !0);
},
deleteProperty(e, t) {
- return Gz(e), Hz(e.base_, t) !== void 0 || t in e.base_ ? (e.assigned_.set(t, !1), Wz(e)) : e.assigned_.delete(t), e.copy_ && delete e.copy_[t], !0;
+ return Kz(e), Uz(e.base_, t) !== void 0 || t in e.base_ ? (e.assigned_.set(t, !1), Gz(e)) : e.assigned_.delete(t), e.copy_ && delete e.copy_[t], !0;
},
getOwnPropertyDescriptor(e, t) {
- let n = hz(e), r = Reflect.getOwnPropertyDescriptor(n, t);
+ let n = gz(e), r = Reflect.getOwnPropertyDescriptor(n, t);
return r && {
- [QR]: !0,
- [XR]: e.type_ !== 1 || t !== "length",
- [ZR]: r[ZR],
- [$R]: n[t]
+ [$R]: !0,
+ [ZR]: e.type_ !== 1 || t !== "length",
+ [QR]: r[QR],
+ [ez]: n[t]
};
},
defineProperty() {
- GR(11);
+ KR(11);
},
getPrototypeOf(e) {
- return qR(e.base_);
+ return JR(e.base_);
},
setPrototypeOf() {
- GR(12);
+ KR(12);
}
-}, Vz = {};
-for (let e in Bz) {
- let t = Bz[e];
- Vz[e] = function() {
+}, Hz = {};
+for (let e in Vz) {
+ let t = Vz[e];
+ Hz[e] = function() {
let e = arguments;
return e[0] = e[0][0], t.apply(this, e);
};
}
-Vz.deleteProperty = function(e, t) {
- return Vz.set.call(this, e, t, void 0);
-}, Vz.set = function(e, t, n) {
- return Bz.set.call(this, e[0], t, n, e[0]);
+Hz.deleteProperty = function(e, t) {
+ return Hz.set.call(this, e, t, void 0);
+}, Hz.set = function(e, t, n) {
+ return Vz.set.call(this, e[0], t, n, e[0]);
};
-function Hz(e, t) {
- let n = e[WR];
- return (n ? hz(n) : e)[t];
+function Uz(e, t) {
+ let n = e[GR];
+ return (n ? gz(n) : e)[t];
}
function mbe(e, t, n) {
- return e.type_ !== 1 || !e.allIndicesReassigned_ || e.assigned_?.get(t) || !tz(n) || n[WR] ? !1 : e.baseRefs_.has(n);
+ return e.type_ !== 1 || !e.allIndicesReassigned_ || e.assigned_?.get(t) || !nz(n) || n[GR] ? !1 : e.baseRefs_.has(n);
}
function hbe(e, t, n) {
- let r = Uz(t, n);
- return r ? $R in r ? r[$R] : r.get?.call(e.draft_) : void 0;
+ let r = Wz(t, n);
+ return r ? ez in r ? r[ez] : r.get?.call(e.draft_) : void 0;
}
-function Uz(e, t) {
+function Wz(e, t) {
if (!(t in e)) return;
- let n = qR(e);
+ let n = JR(e);
for (; n;) {
let e = Object.getOwnPropertyDescriptor(n, t);
if (e) return e;
- n = qR(n);
+ n = JR(n);
}
}
-function Wz(e) {
- e.modified_ || (e.modified_ = !0, e.parent_ && Wz(e.parent_));
-}
function Gz(e) {
- e.copy_ ||= (e.assigned_ = /* @__PURE__ */ new Map(), _z(e.base_, e.scope_.immer_.useStrictShallowCopy_));
+ e.modified_ || (e.modified_ = !0, e.parent_ && Gz(e.parent_));
+}
+function Kz(e) {
+ e.copy_ ||= (e.assigned_ = /* @__PURE__ */ new Map(), vz(e.base_, e.scope_.immer_.useStrictShallowCopy_));
}
var gbe = class {
constructor(e) {
this.autoFreeze_ = !0, this.useStrictShallowCopy_ = !1, this.useStrictIteration_ = !1, this.produce = (e, t, n) => {
- if (pz(e) && !pz(t)) {
+ if (mz(e) && !mz(t)) {
let n = t;
t = e;
let r = this;
@@ -52297,30 +52349,30 @@ var gbe = class {
return r.produce(e, (e) => t.call(this, e, ...i));
};
}
- pz(t) || GR(6), n !== void 0 && !pz(n) && GR(7);
+ mz(t) || KR(6), n !== void 0 && !mz(n) && KR(7);
let r;
- if (tz(e)) {
- let i = Mz(this), a = Kz(i, e, void 0), o = !0;
+ if (nz(e)) {
+ let i = Nz(this), a = qz(i, e, void 0), o = !0;
try {
r = t(a), o = !1;
} finally {
- o ? Az(i) : jz(i);
+ o ? jz(i) : Mz(i);
}
- return kz(i, n), Nz(r, i);
+ return Az(i, n), Pz(r, i);
}
- if (!e || !fz(e)) {
- if (r = t(e), r === void 0 && (r = e), r === HR && (r = void 0), this.autoFreeze_ && vz(r, !0), n) {
+ if (!e || !pz(e)) {
+ if (r = t(e), r === void 0 && (r = e), r === UR && (r = void 0), this.autoFreeze_ && yz(r, !0), n) {
let t = [], i = [];
- Tz(Sz).generateReplacementPatches_(e, r, {
+ Ez(Cz).generateReplacementPatches_(e, r, {
patches_: t,
inversePatches_: i
}), n(t, i);
}
return r;
}
- GR(1, e);
+ KR(1, e);
}, this.produceWithPatches = (e, t) => {
- if (pz(e)) return (t, ...n) => this.produceWithPatches(t, (t) => e(t, ...n));
+ if (mz(e)) return (t, ...n) => this.produceWithPatches(t, (t) => e(t, ...n));
let n, r;
return [
this.produce(e, t, (e, t) => {
@@ -52329,18 +52381,18 @@ var gbe = class {
n,
r
];
- }, mz(e?.autoFreeze) && this.setAutoFreeze(e.autoFreeze), mz(e?.useStrictShallowCopy) && this.setUseStrictShallowCopy(e.useStrictShallowCopy), mz(e?.useStrictIteration) && this.setUseStrictIteration(e.useStrictIteration);
+ }, hz(e?.autoFreeze) && this.setAutoFreeze(e.autoFreeze), hz(e?.useStrictShallowCopy) && this.setUseStrictShallowCopy(e.useStrictShallowCopy), hz(e?.useStrictIteration) && this.setUseStrictIteration(e.useStrictIteration);
}
createDraft(e) {
- tz(e) || GR(8), ez(e) && (e = qz(e));
- let t = Mz(this), n = Kz(t, e, void 0);
- return n[WR].isManual_ = !0, jz(t), n;
+ nz(e) || KR(8), tz(e) && (e = Jz(e));
+ let t = Nz(this), n = qz(t, e, void 0);
+ return n[GR].isManual_ = !0, Mz(t), n;
}
finishDraft(e, t) {
- let n = e && e[WR];
- (!n || !n.isManual_) && GR(9);
+ let n = e && e[GR];
+ (!n || !n.isManual_) && KR(9);
let { scope_: r } = n;
- return kz(r, t), Nz(void 0, r);
+ return Az(r, t), Pz(void 0, r);
}
setAutoFreeze(e) {
this.autoFreeze_ = e;
@@ -52364,48 +52416,48 @@ var gbe = class {
}
}
n > -1 && (t = t.slice(n + 1));
- let r = Tz(Sz).applyPatches_;
- return ez(e) ? r(e, t) : this.produce(e, (e) => r(e, t));
+ let r = Ez(Cz).applyPatches_;
+ return tz(e) ? r(e, t) : this.produce(e, (e) => r(e, t));
}
};
-function Kz(e, t, n, r) {
- let [i, a] = uz(t) ? Tz(xz).proxyMap_(t, n) : dz(t) ? Tz(xz).proxySet_(t, n) : pbe(t, n);
- return (n?.scope_ ?? Oz()).drafts_.push(i), a.callbacks_ = n?.callbacks_ ?? [], a.key_ = r, n && r !== void 0 ? dbe(n, a, r) : a.callbacks_.push(function(e) {
+function qz(e, t, n, r) {
+ let [i, a] = dz(t) ? Ez(Sz).proxyMap_(t, n) : fz(t) ? Ez(Sz).proxySet_(t, n) : pbe(t, n);
+ return (n?.scope_ ?? kz()).drafts_.push(i), a.callbacks_ = n?.callbacks_ ?? [], a.key_ = r, n && r !== void 0 ? dbe(n, a, r) : a.callbacks_.push(function(e) {
e.mapSetPlugin_?.fixSetContents(a);
let { patchPlugin_: t } = e;
a.modified_ && t && t.generatePatches_(a, [], e);
}), i;
}
-function qz(e) {
- return ez(e) || GR(10, e), Jz(e);
-}
function Jz(e) {
- if (!tz(e) || bz(e)) return e;
- let t = e[WR], n, r = !0;
+ return tz(e) || KR(10, e), Yz(e);
+}
+function Yz(e) {
+ if (!nz(e) || xz(e)) return e;
+ let t = e[GR], n, r = !0;
if (t) {
if (!t.modified_) return t.base_;
- t.finalized_ = !0, n = _z(e, t.scope_.immer_.useStrictShallowCopy_), r = t.scope_.immer_.shouldUseStrictIteration();
- } else n = _z(e, !0);
- return iz(n, (e, t) => {
- cz(n, e, Jz(t));
+ t.finalized_ = !0, n = vz(e, t.scope_.immer_.useStrictShallowCopy_), r = t.scope_.immer_.shouldUseStrictIteration();
+ } else n = vz(e, !0);
+ return az(n, (e, t) => {
+ lz(n, e, Yz(t));
}, r), t && (t.finalized_ = !1), n;
}
globalThis.Iterator?.from;
-var Yz = new gbe().produce;
+var Xz = new gbe().produce;
//#endregion
//#region node_modules/redux-thunk/dist/redux-thunk.mjs
-function Xz(e) {
+function Zz(e) {
return ({ dispatch: t, getState: n }) => (r) => (i) => typeof i == "function" ? i(t, n, e) : r(i);
}
-var _be = Xz(), vbe = Xz, ybe = typeof window < "u" && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ ? window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ : function() {
- if (arguments.length !== 0) return typeof arguments[0] == "object" ? BR : BR.apply(null, arguments);
+var _be = Zz(), vbe = Zz, ybe = typeof window < "u" && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ ? window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ : function() {
+ if (arguments.length !== 0) return typeof arguments[0] == "object" ? VR : VR.apply(null, arguments);
};
typeof window < "u" && window.__REDUX_DEVTOOLS_EXTENSION__ && window.__REDUX_DEVTOOLS_EXTENSION__;
-function Zz(e, t) {
+function Qz(e, t) {
function n(...n) {
if (t) {
let r = t(...n);
- if (!r) throw Error(LB(0));
+ if (!r) throw Error(RB(0));
return {
type: e,
payload: r.payload,
@@ -52418,9 +52470,9 @@ function Zz(e, t) {
payload: n[0]
};
}
- return n.toString = () => `${e}`, n.type = e, n.match = (t) => VR(t) && t.type === e, n;
+ return n.toString = () => `${e}`, n.type = e, n.match = (t) => HR(t) && t.type === e, n;
}
-var Qz = class e extends Array {
+var $z = class e extends Array {
constructor(...t) {
super(...t), Object.setPrototypeOf(this, e.prototype);
}
@@ -52434,29 +52486,29 @@ var Qz = class e extends Array {
return t.length === 1 && Array.isArray(t[0]) ? new e(...t[0].concat(this)) : new e(...t.concat(this));
}
};
-function $z(e) {
- return tz(e) ? Yz(e, () => {}) : e;
+function eB(e) {
+ return nz(e) ? Xz(e, () => {}) : e;
}
-function eB(e, t, n) {
+function tB(e, t, n) {
return e.has(t) ? e.get(t) : e.set(t, n(t)).get(t);
}
function bbe(e) {
return typeof e == "boolean";
}
var xbe = () => function(e) {
- let { thunk: t = !0, immutableCheck: n = !0, serializableCheck: r = !0, actionCreatorCheck: i = !0 } = e ?? {}, a = new Qz();
+ let { thunk: t = !0, immutableCheck: n = !0, serializableCheck: r = !0, actionCreatorCheck: i = !0 } = e ?? {}, a = new $z();
return t && (bbe(t) ? a.push(_be) : a.push(vbe(t.extraArgument))), a;
-}, tB = "RTK_autoBatch", nB = () => (e) => ({
+}, nB = "RTK_autoBatch", rB = () => (e) => ({
payload: e,
- meta: { [tB]: !0 }
-}), rB = (e) => (t) => {
+ meta: { [nB]: !0 }
+}), iB = (e) => (t) => {
setTimeout(t, e);
}, Sbe = (e, t) => (n) => {
let r = !1, i = () => {
r || (r = !0, cancelAnimationFrame(a), clearTimeout(o), n());
}, a = e(i), o = setTimeout(i, t);
-}, iB = (e = { type: "raf" }) => (t) => (...n) => {
- let r = t(...n), i = !0, a = !1, o = !1, s = /* @__PURE__ */ new Set(), c = e.type === "tick" ? queueMicrotask : e.type === "raf" ? typeof window < "u" && window.requestAnimationFrame ? Sbe(window.requestAnimationFrame, 100) : rB(10) : e.type === "callback" ? e.queueNotification : rB(e.timeout), l = () => {
+}, aB = (e = { type: "raf" }) => (t) => (...n) => {
+ let r = t(...n), i = !0, a = !1, o = !1, s = /* @__PURE__ */ new Set(), c = e.type === "tick" ? queueMicrotask : e.type === "raf" ? typeof window < "u" && window.requestAnimationFrame ? Sbe(window.requestAnimationFrame, 100) : iB(10) : e.type === "callback" ? e.queueNotification : iB(e.timeout), l = () => {
o = !1, a && (a = !1, s.forEach((e) => e()));
};
return Object.assign({}, r, {
@@ -52468,37 +52520,37 @@ var xbe = () => function(e) {
},
dispatch(e) {
try {
- return i = !e?.meta?.[tB], a = !i, a && (o || (o = !0, c(l))), r.dispatch(e);
+ return i = !e?.meta?.[nB], a = !i, a && (o || (o = !0, c(l))), r.dispatch(e);
} finally {
i = !0;
}
}
});
}, Cbe = (e) => function(t) {
- let { autoBatch: n = !0 } = t ?? {}, r = new Qz(e);
- return n && r.push(iB(typeof n == "object" ? n : void 0)), r;
+ let { autoBatch: n = !0 } = t ?? {}, r = new $z(e);
+ return n && r.push(aB(typeof n == "object" ? n : void 0)), r;
};
function wbe(e) {
let t = xbe(), { reducer: n = void 0, middleware: r, devTools: i = !0, duplicateMiddlewareCheck: a = !0, preloadedState: o = void 0, enhancers: s = void 0 } = e || {}, c;
if (typeof n == "function") c = n;
- else if (LR(n)) c = zR(n);
- else throw Error(LB(1));
+ else if (RR(n)) c = BR(n);
+ else throw Error(RB(1));
let l;
l = typeof r == "function" ? r(t) : t();
- let u = BR;
+ let u = VR;
i && (u = ybe({
trace: !1,
...typeof i == "object" && i
}));
let d = Cbe(nbe(...l)), f = typeof s == "function" ? s(d) : d(), p = u(...f);
- return RR(c, o, p);
+ return zR(c, o, p);
}
-function aB(e) {
+function oB(e) {
let t = {}, n = [], r, i = {
addCase(e, n) {
let r = typeof e == "string" ? e : e.type;
- if (!r) throw Error(LB(28));
- if (r in t) throw Error(LB(29));
+ if (!r) throw Error(RB(28));
+ if (r in t) throw Error(RB(29));
return t[r] = n, i;
},
addAsyncThunk(e, r) {
@@ -52527,21 +52579,21 @@ function Tbe(e) {
return typeof e == "function";
}
function Ebe(e, t) {
- let [n, r, i] = aB(t), a;
- if (Tbe(e)) a = () => $z(e());
+ let [n, r, i] = oB(t), a;
+ if (Tbe(e)) a = () => eB(e());
else {
- let t = $z(e);
+ let t = eB(e);
a = () => t;
}
function o(e = a(), t) {
let o = [n[t.type], ...r.filter(({ matcher: e }) => e(t)).map(({ reducer: e }) => e)];
return o.filter((e) => !!e).length === 0 && (o = [i]), o.reduce((e, n) => {
if (n) {
- if (ez(e)) {
+ if (tz(e)) {
let r = n(e, t);
return r === void 0 ? e : r;
}
- if (tz(e)) return Yz(e, (e) => n(e, t));
+ if (nz(e)) return Xz(e, (e) => n(e, t));
{
let r = n(e, t);
if (r === void 0) {
@@ -52568,7 +52620,7 @@ function jbe({ creators: e } = {}) {
let t = e?.asyncThunk?.[kbe];
return function(e) {
let { name: n, reducerPath: r = n } = e;
- if (!n) throw Error(LB(11));
+ if (!n) throw Error(RB(11));
let i = (typeof e.reducers == "function" ? e.reducers(Nbe()) : e.reducers) || {}, a = Object.keys(i), o = {
sliceCaseReducersByName: {},
sliceCaseReducersByType: {},
@@ -52577,8 +52629,8 @@ function jbe({ creators: e } = {}) {
}, s = {
addCase(e, t) {
let n = typeof e == "string" ? e : e.type;
- if (!n) throw Error(LB(12));
- if (n in o.sliceCaseReducersByType) throw Error(LB(13));
+ if (!n) throw Error(RB(12));
+ if (n in o.sliceCaseReducersByType) throw Error(RB(13));
return o.sliceCaseReducersByType[n] = t, s;
},
addMatcher(e, t) {
@@ -52603,7 +52655,7 @@ function jbe({ creators: e } = {}) {
Fbe(a) ? Lbe(o, a, s, t) : Pbe(o, a, s);
});
function c() {
- let [t = {}, n = [], r = void 0] = typeof e.extraReducers == "function" ? aB(e.extraReducers) : [e.extraReducers], i = {
+ let [t = {}, n = [], r = void 0] = typeof e.extraReducers == "function" ? oB(e.extraReducers) : [e.extraReducers], i = {
...t,
...o.sliceCaseReducersByType
};
@@ -52624,12 +52676,12 @@ function jbe({ creators: e } = {}) {
function h(t, n = !1) {
function r(e) {
let i = e[t];
- return i === void 0 && n && (i = eB(d, r, m)), i;
+ return i === void 0 && n && (i = tB(d, r, m)), i;
}
function i(t = l) {
- return eB(eB(u, n, () => /* @__PURE__ */ new WeakMap()), t, () => {
+ return tB(tB(u, n, () => /* @__PURE__ */ new WeakMap()), t, () => {
let r = {};
- for (let [i, a] of Object.entries(e.selectors ?? {})) r[i] = Mbe(a, t, () => eB(d, t, m), n);
+ for (let [i, a] of Object.entries(e.selectors ?? {})) r[i] = Mbe(a, t, () => tB(d, t, m), n);
return r;
});
}
@@ -52670,7 +52722,7 @@ function Mbe(e, t, n, r) {
}
return i.unwrapped = e, i;
}
-var oB = /* @__PURE__ */ jbe();
+var sB = /* @__PURE__ */ jbe();
function Nbe() {
function e(e, t) {
return {
@@ -52698,10 +52750,10 @@ function Nbe() {
function Pbe({ type: e, reducerName: t, createNotation: n }, r, i) {
let a, o;
if ("reducer" in r) {
- if (n && !Ibe(r)) throw Error(LB(17));
+ if (n && !Ibe(r)) throw Error(RB(17));
a = r.reducer, o = r.prepare;
} else a = r;
- i.addCase(e, a).exposeCaseReducer(t, a).exposeAction(t, o ? Zz(e, o) : Zz(e));
+ i.addCase(e, a).exposeCaseReducer(t, a).exposeAction(t, o ? Qz(e, o) : Qz(e));
}
function Fbe(e) {
return e._reducerDefinitionType === "asyncThunk";
@@ -52710,39 +52762,39 @@ function Ibe(e) {
return e._reducerDefinitionType === "reducerWithPrepare";
}
function Lbe({ type: e, reducerName: t }, n, r, i) {
- if (!i) throw Error(LB(18));
+ if (!i) throw Error(RB(18));
let { payloadCreator: a, fulfilled: o, pending: s, rejected: c, settled: l, options: u } = n, d = i(e, a, u);
r.exposeAction(t, d), o && r.addCase(d.fulfilled, o), s && r.addCase(d.pending, s), c && r.addCase(d.rejected, c), l && r.addMatcher(d.settled, l), r.exposeCaseReducer(t, {
- fulfilled: o || sB,
- pending: s || sB,
- rejected: c || sB,
- settled: l || sB
+ fulfilled: o || cB,
+ pending: s || cB,
+ rejected: c || cB,
+ settled: l || cB
});
}
-function sB() {}
-var Rbe = "task", cB = "listener", lB = "completed", uB = "cancelled", zbe = `task-${uB}`, Bbe = `task-${lB}`, dB = `${cB}-${uB}`, Vbe = `${cB}-${lB}`, fB = class {
+function cB() {}
+var Rbe = "task", lB = "listener", uB = "completed", dB = "cancelled", zbe = `task-${dB}`, Bbe = `task-${uB}`, fB = `${lB}-${dB}`, Vbe = `${lB}-${uB}`, pB = class {
constructor(e) {
- this.code = e, this.message = `${Rbe} ${uB} (reason: ${e})`;
+ this.code = e, this.message = `${Rbe} ${dB} (reason: ${e})`;
}
code;
name = "TaskAbortError";
message;
-}, pB = (e, t) => {
- if (typeof e != "function") throw TypeError(LB(32));
-}, mB = () => {}, hB = (e, t = mB) => (e.catch(t), e), gB = (e, t) => (e.addEventListener("abort", t, { once: !0 }), () => e.removeEventListener("abort", t)), _B = (e) => {
- if (e.aborted) throw new fB(e.reason);
+}, mB = (e, t) => {
+ if (typeof e != "function") throw TypeError(RB(32));
+}, hB = () => {}, gB = (e, t = hB) => (e.catch(t), e), _B = (e, t) => (e.addEventListener("abort", t, { once: !0 }), () => e.removeEventListener("abort", t)), vB = (e) => {
+ if (e.aborted) throw new pB(e.reason);
};
-function vB(e, t) {
- let n = mB;
+function yB(e, t) {
+ let n = hB;
return new Promise((r, i) => {
- let a = () => i(new fB(e.reason));
+ let a = () => i(new pB(e.reason));
if (e.aborted) {
a();
return;
}
- n = gB(e, a), t.finally(() => n()).then(r, i);
+ n = _B(e, a), t.finally(() => n()).then(r, i);
}).finally(() => {
- n = mB;
+ n = hB;
});
}
var Hbe = async (e, t) => {
@@ -52753,40 +52805,40 @@ var Hbe = async (e, t) => {
};
} catch (e) {
return {
- status: e instanceof fB ? "cancelled" : "rejected",
+ status: e instanceof pB ? "cancelled" : "rejected",
error: e
};
} finally {
t?.();
}
-}, yB = (e) => (t) => hB(vB(e, t).then((t) => (_B(e), t))), bB = (e) => {
- let t = yB(e);
+}, bB = (e) => (t) => gB(yB(e, t).then((t) => (vB(e), t))), xB = (e) => {
+ let t = bB(e);
return (e) => t(new Promise((t) => setTimeout(t, e)));
-}, { assign: xB } = Object, SB = {}, CB = "listenerMiddleware", wB = (e, t) => {
- let n = (t) => gB(e, () => t.abort(e.reason));
+}, { assign: SB } = Object, CB = {}, wB = "listenerMiddleware", TB = (e, t) => {
+ let n = (t) => _B(e, () => t.abort(e.reason));
return (r, i) => {
- pB(r, "taskExecutor");
+ mB(r, "taskExecutor");
let a = new AbortController();
n(a);
let o = Hbe(async () => {
- _B(e), _B(a.signal);
+ vB(e), vB(a.signal);
let t = await r({
- pause: yB(a.signal),
- delay: bB(a.signal),
+ pause: bB(a.signal),
+ delay: xB(a.signal),
signal: a.signal
});
- return _B(a.signal), t;
+ return vB(a.signal), t;
}, () => a.abort(Bbe));
- return i?.autoJoin && t.push(o.catch(mB)), {
- result: yB(e)(o),
+ return i?.autoJoin && t.push(o.catch(hB)), {
+ result: bB(e)(o),
cancel() {
a.abort(zbe);
}
};
};
-}, TB = (e, t) => {
+}, EB = (e, t) => {
let n = async (n, r) => {
- _B(t);
+ vB(t);
let i = () => {}, a = [new Promise((t, r) => {
let a = e({
predicate: n,
@@ -52804,26 +52856,26 @@ var Hbe = async (e, t) => {
})];
r != null && a.push(new Promise((e) => setTimeout(e, r, null)));
try {
- let e = await vB(t, Promise.race(a));
- return _B(t), e;
+ let e = await yB(t, Promise.race(a));
+ return vB(t), e;
} finally {
i();
}
};
- return ((e, t) => hB(n(e, t)));
-}, EB = (e) => {
+ return ((e, t) => gB(n(e, t)));
+}, DB = (e) => {
let { type: t, actionCreator: n, matcher: r, predicate: i, effect: a } = e;
- if (t) i = Zz(t).match;
+ if (t) i = Qz(t).match;
else if (n) t = n.type, i = n.match;
else if (r) i = r;
- else if (!i) throw Error(LB(21));
- return pB(a, "options.listener"), {
+ else if (!i) throw Error(RB(21));
+ return mB(a, "options.listener"), {
predicate: i,
type: t,
effect: a
};
-}, DB = /* @__PURE__ */ xB((e) => {
- let { type: t, predicate: n, effect: r } = EB(e);
+}, OB = /* @__PURE__ */ SB((e) => {
+ let { type: t, predicate: n, effect: r } = DB(e);
return {
id: Obe(),
effect: r,
@@ -52831,20 +52883,20 @@ var Hbe = async (e, t) => {
predicate: n,
pending: /* @__PURE__ */ new Set(),
unsubscribe: () => {
- throw Error(LB(22));
+ throw Error(RB(22));
}
};
-}, { withTypes: () => DB }), OB = (e, t) => {
- let { type: n, effect: r, predicate: i } = EB(t);
+}, { withTypes: () => OB }), kB = (e, t) => {
+ let { type: n, effect: r, predicate: i } = DB(t);
return Array.from(e.values()).find((e) => (typeof n == "string" ? e.type === n : e.predicate === i) && e.effect === r);
-}, kB = (e) => {
+}, AB = (e) => {
e.pending.forEach((e) => {
- e.abort(dB);
+ e.abort(fB);
});
-}, AB = (e, t) => () => {
- for (let e of t.keys()) kB(e);
+}, jB = (e, t) => () => {
+ for (let e of t.keys()) AB(e);
e.clear();
-}, jB = (e, t, n) => {
+}, MB = (e, t, n) => {
try {
e(t, n);
} catch (e) {
@@ -52852,74 +52904,74 @@ var Hbe = async (e, t) => {
throw e;
}, 0);
}
-}, MB = /* @__PURE__ */ xB(/* @__PURE__ */ Zz(`${CB}/add`), { withTypes: () => MB }), NB = /* @__PURE__ */ Zz(`${CB}/removeAll`), PB = /* @__PURE__ */ xB(/* @__PURE__ */ Zz(`${CB}/remove`), { withTypes: () => PB }), FB = (...e) => {
- console.error(`${CB}/error`, ...e);
-}, IB = (e = {}) => {
+}, NB = /* @__PURE__ */ SB(/* @__PURE__ */ Qz(`${wB}/add`), { withTypes: () => NB }), PB = /* @__PURE__ */ Qz(`${wB}/removeAll`), FB = /* @__PURE__ */ SB(/* @__PURE__ */ Qz(`${wB}/remove`), { withTypes: () => FB }), IB = (...e) => {
+ console.error(`${wB}/error`, ...e);
+}, LB = (e = {}) => {
let t = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Map(), r = (e) => {
let t = n.get(e) ?? 0;
n.set(e, t + 1);
}, i = (e) => {
let t = n.get(e) ?? 1;
t === 1 ? n.delete(e) : n.set(e, t - 1);
- }, { extra: a, onError: o = FB } = e;
- pB(o, "onError");
+ }, { extra: a, onError: o = IB } = e;
+ mB(o, "onError");
let s = (e) => (e.unsubscribe = () => t.delete(e.id), t.set(e.id, e), (t) => {
- e.unsubscribe(), t?.cancelActive && kB(e);
+ e.unsubscribe(), t?.cancelActive && AB(e);
}), c = ((e) => {
- let n = OB(t, e) ?? DB(e);
+ let n = kB(t, e) ?? OB(e);
return s(n);
});
- xB(c, { withTypes: () => c });
+ SB(c, { withTypes: () => c });
let l = (e) => {
- let n = OB(t, e);
- return n && (n.unsubscribe(), e.cancelActive && kB(n)), !!n;
+ let n = kB(t, e);
+ return n && (n.unsubscribe(), e.cancelActive && AB(n)), !!n;
};
- xB(l, { withTypes: () => l });
+ SB(l, { withTypes: () => l });
let u = async (e, n, s, l) => {
- let u = new AbortController(), d = TB(c, u.signal), f = [];
+ let u = new AbortController(), d = EB(c, u.signal), f = [];
try {
- e.pending.add(u), r(e), await Promise.resolve(e.effect(n, xB({}, s, {
+ e.pending.add(u), r(e), await Promise.resolve(e.effect(n, SB({}, s, {
getOriginalState: l,
condition: (e, t) => d(e, t).then(Boolean),
take: d,
- delay: bB(u.signal),
- pause: yB(u.signal),
+ delay: xB(u.signal),
+ pause: bB(u.signal),
extra: a,
signal: u.signal,
- fork: wB(u.signal, f),
+ fork: TB(u.signal, f),
unsubscribe: e.unsubscribe,
subscribe: () => {
t.set(e.id, e);
},
cancelActiveListeners: () => {
e.pending.forEach((e, t, n) => {
- e !== u && (e.abort(dB), n.delete(e));
+ e !== u && (e.abort(fB), n.delete(e));
});
},
cancel: () => {
- u.abort(dB), e.pending.delete(u);
+ u.abort(fB), e.pending.delete(u);
},
throwIfCancelled: () => {
- _B(u.signal);
+ vB(u.signal);
}
})));
} catch (e) {
- e instanceof fB || jB(o, e, { raisedBy: "effect" });
+ e instanceof pB || MB(o, e, { raisedBy: "effect" });
} finally {
await Promise.all(f), u.abort(Vbe), i(e), e.pending.delete(u);
}
- }, d = AB(t, n);
+ }, d = jB(t, n);
return {
middleware: (e) => (n) => (r) => {
- if (!VR(r)) return n(r);
- if (MB.match(r)) return c(r.payload);
- if (NB.match(r)) {
+ if (!HR(r)) return n(r);
+ if (NB.match(r)) return c(r.payload);
+ if (PB.match(r)) {
d();
return;
}
- if (PB.match(r)) return l(r.payload);
+ if (FB.match(r)) return l(r.payload);
let i = e.getState(), a = () => {
- if (i === SB) throw Error(LB(23));
+ if (i === CB) throw Error(RB(23));
return i;
}, s;
try {
@@ -52930,13 +52982,13 @@ var Hbe = async (e, t) => {
try {
s = t.predicate(r, n, i);
} catch (e) {
- s = !1, jB(o, e, { raisedBy: "predicate" });
+ s = !1, MB(o, e, { raisedBy: "predicate" });
}
s && u(t, r, e, a);
}
}
} finally {
- i = SB;
+ i = CB;
}
return s;
},
@@ -52945,12 +52997,12 @@ var Hbe = async (e, t) => {
clearListeners: d
};
};
-function LB(e) {
+function RB(e) {
return `Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `;
}
//#endregion
//#region node_modules/recharts/es6/state/layoutSlice.js
-var RB = oB({
+var zB = sB({
name: "chartLayout",
initialState: {
layoutType: "horizontal",
@@ -52978,23 +53030,23 @@ var RB = oB({
e.scale = t.payload;
}
}
-}), { setMargin: zB, setLayout: BB, setChartSize: VB, setScale: HB } = RB.actions, UB = RB.reducer;
+}), { setMargin: BB, setLayout: VB, setChartSize: HB, setScale: UB } = zB.actions, WB = zB.reducer;
//#endregion
//#region node_modules/recharts/es6/util/getSliced.js
-function WB(e, t, n) {
+function GB(e, t, n) {
return Array.isArray(e) && e && t + n !== 0 ? e.slice(t, n + 1) : e;
}
//#endregion
//#region node_modules/recharts/es6/util/isWellBehavedNumber.js
-function GB(e) {
+function KB(e) {
return Number.isFinite(e);
}
-function KB(e) {
+function qB(e) {
return typeof e == "number" && e > 0 && Number.isFinite(e);
}
//#endregion
//#region node_modules/recharts/es6/util/ChartUtils.js
-function qB(e, t) {
+function JB(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -53004,30 +53056,30 @@ function qB(e, t) {
}
return n;
}
-function JB(e) {
+function YB(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? qB(Object(n), !0).forEach(function(t) {
- YB(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : qB(Object(n)).forEach(function(t) {
+ t % 2 ? JB(Object(n), !0).forEach(function(t) {
+ XB(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : JB(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function YB(e, t, n) {
- return (t = XB(t)) in e ? Object.defineProperty(e, t, {
+function XB(e, t, n) {
+ return (t = ZB(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function XB(e) {
- var t = ZB(e, "string");
+function ZB(e) {
+ var t = QB(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function ZB(e, t) {
+function QB(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -53037,63 +53089,63 @@ function ZB(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function QB(e, t, n) {
- return FL(e) || FL(t) ? n : kL(t) ? CL(e, t, n) : typeof t == "function" ? t(e) : n;
+function $B(e, t, n) {
+ return IL(e) || IL(t) ? n : AL(t) ? wL(e, t, n) : typeof t == "function" ? t(e) : n;
}
-var $B = (e, t, n) => {
+var eV = (e, t, n) => {
if (t && n) {
var { width: r, height: i } = n, { align: a, verticalAlign: o, layout: s } = t;
- if ((s === "vertical" || s === "horizontal" && o === "middle") && a !== "center" && Z(e[a])) return JB(JB({}, e), {}, { [a]: e[a] + (r || 0) });
- if ((s === "horizontal" || s === "vertical" && a === "center") && o !== "middle" && Z(e[o])) return JB(JB({}, e), {}, { [o]: e[o] + (i || 0) });
+ if ((s === "vertical" || s === "horizontal" && o === "middle") && a !== "center" && Z(e[a])) return YB(YB({}, e), {}, { [a]: e[a] + (r || 0) });
+ if ((s === "horizontal" || s === "vertical" && a === "center") && o !== "middle" && Z(e[o])) return YB(YB({}, e), {}, { [o]: e[o] + (i || 0) });
}
return e;
-}, eV = (e, t) => e === "horizontal" && t === "xAxis" || e === "vertical" && t === "yAxis" || e === "centric" && t === "angleAxis" || e === "radial" && t === "radiusAxis", tV = (e, t, n, r) => {
+}, tV = (e, t) => e === "horizontal" && t === "xAxis" || e === "vertical" && t === "yAxis" || e === "centric" && t === "angleAxis" || e === "radial" && t === "radiusAxis", nV = (e, t, n, r) => {
if (r) return e.map((e) => e.coordinate);
var i, a, o = e.map((e) => (e.coordinate === t && (i = !0), e.coordinate === n && (a = !0), e.coordinate));
return i || o.push(t), a || o.push(n), o;
-}, nV = (e, t, n) => {
+}, rV = (e, t, n) => {
if (!e) return null;
var { duplicateDomain: r, type: i, range: a, scale: o, realScaleType: s, isCategorical: c, categoricalDomain: l, tickCount: u, ticks: d, niceTicks: f, axisType: p } = e;
if (!o) return null;
var m = s === "scaleBand" && o.bandwidth ? o.bandwidth() / 2 : 2, h = (t || n) && i === "category" && o.bandwidth ? o.bandwidth() / m : 0;
- return h = p === "angleAxis" && a && a.length >= 2 ? EL(a[0] - a[1]) * 2 * h : h, t && (d || f) ? (d || f || []).map((e, t) => {
+ return h = p === "angleAxis" && a && a.length >= 2 ? DL(a[0] - a[1]) * 2 * h : h, t && (d || f) ? (d || f || []).map((e, t) => {
var n = r ? r.indexOf(e) : e, i = o.map(n);
- return GB(i) ? {
+ return KB(i) ? {
coordinate: i + h,
value: e,
offset: h,
index: t
} : null;
- }).filter(LL) : c && l ? l.map((e, t) => {
+ }).filter(RL) : c && l ? l.map((e, t) => {
var n = o.map(e);
- return GB(n) ? {
+ return KB(n) ? {
coordinate: n + h,
value: e,
index: t,
offset: h
} : null;
- }).filter(LL) : o.ticks && !n && u != null ? o.ticks(u).map((e, t) => {
+ }).filter(RL) : o.ticks && !n && u != null ? o.ticks(u).map((e, t) => {
var n = o.map(e);
- return GB(n) ? {
+ return KB(n) ? {
coordinate: n + h,
value: e,
index: t,
offset: h
} : null;
- }).filter(LL) : o.domain().map((e, t) => {
+ }).filter(RL) : o.domain().map((e, t) => {
var n = o.map(e);
- return GB(n) ? {
+ return KB(n) ? {
coordinate: n + h,
value: r ? r[e] : e,
index: t,
offset: h
} : null;
- }).filter(LL);
-}, rV = (e, t) => {
+ }).filter(RL);
+}, iV = (e, t) => {
if (!t || t.length !== 2 || !Z(t[0]) || !Z(t[1])) return e;
var n = Math.min(t[0], t[1]), r = Math.max(t[0], t[1]), i = [e[0], e[1]];
return (!Z(e[0]) || e[0] < n) && (i[0] = n), (!Z(e[1]) || e[1] > r) && (i[1] = r), i[0] > r && (i[0] = r), i[1] < n && (i[1] = n), i;
-}, iV = {
+}, aV = {
sign: (e) => {
var t = e.length;
if (!(t <= 0)) {
@@ -53101,14 +53153,14 @@ var $B = (e, t, n) => {
if (!(n == null || n <= 0)) for (var r = 0; r < n; ++r) for (var i = 0, a = 0, o = 0; o < t; ++o) {
var s = e[o]?.[r];
if (s != null) {
- var c = s[1], l = s[0], u = DL(c) ? l : c;
+ var c = s[1], l = s[0], u = OL(c) ? l : c;
u >= 0 ? (s[0] = i, i += u, s[1] = i) : (s[0] = a, a += u, s[1] = a);
}
}
}
},
expand: mve,
- none: hL,
+ none: gL,
silhouette: hve,
wiggle: gve,
positive: (e) => {
@@ -53118,70 +53170,70 @@ var $B = (e, t, n) => {
if (!(n == null || n <= 0)) for (var r = 0; r < n; ++r) for (var i = 0, a = 0; a < t; ++a) {
var o = e[a]?.[r];
if (o != null) {
- var s = DL(o[1]) ? o[0] : o[1];
+ var s = OL(o[1]) ? o[0] : o[1];
s >= 0 ? (o[0] = i, i += s, o[1] = i) : (o[0] = 0, o[1] = 0);
}
}
}
}
-}, aV = (e, t, n) => {
- var r = iV[n] ?? hL, i = pve().keys(t).value((e, t) => Number(QB(e, t, 0))).order(gL).offset(r)(e);
+}, oV = (e, t, n) => {
+ var r = aV[n] ?? gL, i = pve().keys(t).value((e, t) => Number($B(e, t, 0))).order(_L).offset(r)(e);
return i.forEach((n, r) => {
n.forEach((n, i) => {
- var a = QB(e[i], t[r], 0);
+ var a = $B(e[i], t[r], 0);
Array.isArray(a) && a.length === 2 && Z(a[0]) && Z(a[1]) && (n[0] = a[0], n[1] = a[1]);
});
}), i;
};
-function oV(e) {
+function sV(e) {
return e == null ? void 0 : String(e);
}
-function sV(e) {
+function cV(e) {
var { axis: t, ticks: n, bandSize: r, entry: i, index: a, dataKey: o } = e;
if (t.type === "category") {
- if (!t.allowDuplicatedCategory && t.dataKey && !FL(i[t.dataKey])) {
- var s = PL(n, "value", i[t.dataKey]);
+ if (!t.allowDuplicatedCategory && t.dataKey && !IL(i[t.dataKey])) {
+ var s = FL(n, "value", i[t.dataKey]);
if (s) return s.coordinate + r / 2;
}
return n != null && n[a] ? n[a].coordinate + r / 2 : null;
}
- var c = QB(i, FL(o) ? t.dataKey : o), l = t.scale.map(c);
+ var c = $B(i, IL(o) ? t.dataKey : o), l = t.scale.map(c);
return Z(l) ? l : null;
}
-var cV = (e) => {
+var lV = (e) => {
var { axis: t, ticks: n, offset: r, bandSize: i, entry: a, index: o } = e;
if (t.type === "category") return n[o] ? n[o].coordinate + r : null;
- var s = QB(a, t.dataKey, t.scale.domain()[o]);
- if (FL(s)) return null;
+ var s = $B(a, t.dataKey, t.scale.domain()[o]);
+ if (IL(s)) return null;
var c = t.scale.map(s);
return Z(c) ? c - i / 2 + r : null;
-}, lV = (e) => {
+}, uV = (e) => {
var { numericAxis: t } = e, n = t.scale.domain();
if (t.type === "number") {
var r = Math.min(n[0], n[1]), i = Math.max(n[0], n[1]);
return r <= 0 && i >= 0 ? 0 : i < 0 ? i : r;
}
return n[0];
-}, uV = (e) => {
+}, dV = (e) => {
var t = e.flat(2).filter(Z);
return [Math.min(...t), Math.max(...t)];
-}, dV = (e) => [e[0] === Infinity ? 0 : e[0], e[1] === -Infinity ? 0 : e[1]], fV = (e, t, n) => {
- if (e != null) return dV(Object.keys(e).reduce((r, i) => {
+}, fV = (e) => [e[0] === Infinity ? 0 : e[0], e[1] === -Infinity ? 0 : e[1]], pV = (e, t, n) => {
+ if (e != null) return fV(Object.keys(e).reduce((r, i) => {
var a = e[i];
if (!a) return r;
var { stackedData: o } = a, s = o.reduce((e, r) => {
- var i = uV(WB(r, t, n));
- return !GB(i[0]) || !GB(i[1]) ? e : [Math.min(e[0], i[0]), Math.max(e[1], i[1])];
+ var i = dV(GB(r, t, n));
+ return !KB(i[0]) || !KB(i[1]) ? e : [Math.min(e[0], i[0]), Math.max(e[1], i[1])];
}, [Infinity, -Infinity]);
return [Math.min(s[0], r[0]), Math.max(s[1], r[1])];
}, [Infinity, -Infinity]));
-}, pV = /^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/, mV = /^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/, hV = (e, t, n) => {
+}, mV = /^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/, hV = /^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/, gV = (e, t, n) => {
if (e && e.scale && e.scale.bandwidth) {
var r = e.scale.bandwidth();
if (!n || r > 0) return r;
}
if (e && t && t.length >= 2) {
- for (var i = kR(t, (e) => e.coordinate), a = Infinity, o = 1, s = i.length; o < s; o++) {
+ for (var i = AR(t, (e) => e.coordinate), a = Infinity, o = 1, s = i.length; o < s; o++) {
var c = i[o], l = i[o - 1];
a = Math.min((c?.coordinate || 0) - (l?.coordinate || 0), a);
}
@@ -53189,26 +53241,26 @@ var cV = (e) => {
}
return n ? void 0 : 0;
};
-function gV(e) {
+function _V(e) {
var { tooltipEntrySettings: t, dataKey: n, payload: r, value: i, name: a } = e;
- return JB(JB({}, t), {}, {
+ return YB(YB({}, t), {}, {
dataKey: n,
payload: r,
value: i,
name: a
});
}
-function _V(e, t) {
+function vV(e, t) {
if (e) return String(e);
if (typeof t == "string") return t;
}
-var vV = (e, t) => {
+var yV = (e, t) => {
if (t === "horizontal") return e.relativeX;
if (t === "vertical") return e.relativeY;
-}, yV = (e, t) => t === "centric" ? e.angle : e.radius, bV = (e) => e.layout.width, xV = (e) => e.layout.height, SV = (e) => e.layout.scale, CV = (e) => e.layout.margin, wV = $((e) => e.cartesianAxis.xAxis, (e) => Object.values(e)), TV = $((e) => e.cartesianAxis.yAxis, (e) => Object.values(e)), EV = "data-recharts-item-index";
+}, bV = (e, t) => t === "centric" ? e.angle : e.radius, xV = (e) => e.layout.width, SV = (e) => e.layout.height, CV = (e) => e.layout.scale, wV = (e) => e.layout.margin, TV = $((e) => e.cartesianAxis.xAxis, (e) => Object.values(e)), EV = $((e) => e.cartesianAxis.yAxis, (e) => Object.values(e)), DV = "data-recharts-item-index";
//#endregion
//#region node_modules/recharts/es6/state/selectors/selectChartOffsetInternal.js
-function DV(e, t) {
+function OV(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -53218,30 +53270,30 @@ function DV(e, t) {
}
return n;
}
-function OV(e) {
+function kV(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? DV(Object(n), !0).forEach(function(t) {
- kV(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : DV(Object(n)).forEach(function(t) {
+ t % 2 ? OV(Object(n), !0).forEach(function(t) {
+ AV(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : OV(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function kV(e, t, n) {
- return (t = AV(t)) in e ? Object.defineProperty(e, t, {
+function AV(e, t, n) {
+ return (t = jV(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function AV(e) {
- var t = jV(e, "string");
+function jV(e) {
+ var t = MV(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function jV(e, t) {
+function MV(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -53251,58 +53303,58 @@ function jV(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var MV = (e) => e.brush.height;
-function NV(e) {
- return TV(e).reduce((e, t) => t.orientation === "left" && !t.mirror && !t.hide ? e + (typeof t.width == "number" ? t.width : 60) : e, 0);
-}
+var NV = (e) => e.brush.height;
function PV(e) {
- return TV(e).reduce((e, t) => t.orientation === "right" && !t.mirror && !t.hide ? e + (typeof t.width == "number" ? t.width : 60) : e, 0);
+ return EV(e).reduce((e, t) => t.orientation === "left" && !t.mirror && !t.hide ? e + (typeof t.width == "number" ? t.width : 60) : e, 0);
}
function FV(e) {
- return wV(e).reduce((e, t) => t.orientation === "top" && !t.mirror && !t.hide ? e + t.height : e, 0);
+ return EV(e).reduce((e, t) => t.orientation === "right" && !t.mirror && !t.hide ? e + (typeof t.width == "number" ? t.width : 60) : e, 0);
}
function IV(e) {
- return wV(e).reduce((e, t) => t.orientation === "bottom" && !t.mirror && !t.hide ? e + t.height : e, 0);
+ return TV(e).reduce((e, t) => t.orientation === "top" && !t.mirror && !t.hide ? e + t.height : e, 0);
+}
+function LV(e) {
+ return TV(e).reduce((e, t) => t.orientation === "bottom" && !t.mirror && !t.hide ? e + t.height : e, 0);
}
-var LV = $([
- bV,
+var RV = $([
xV,
- CV,
- MV,
+ SV,
+ wV,
NV,
PV,
FV,
IV,
- AR,
+ LV,
+ jR,
Qye
], (e, t, n, r, i, a, o, s, c, l) => {
var u = {
left: (n.left || 0) + i,
right: (n.right || 0) + a
- }, d = OV(OV({}, {
+ }, d = kV(kV({}, {
top: (n.top || 0) + o,
bottom: (n.bottom || 0) + s
}), u), f = d.bottom;
- d.bottom += r, d = $B(d, c, l);
+ d.bottom += r, d = eV(d, c, l);
var p = e - d.left - d.right, m = t - d.top - d.bottom;
- return OV(OV({ brushBottom: f }, d), {}, {
+ return kV(kV({ brushBottom: f }, d), {}, {
width: Math.max(p, 0),
height: Math.max(m, 0)
});
-}), RV = $(LV, (e) => ({
+}), zV = $(RV, (e) => ({
x: e.left,
y: e.top,
width: e.width,
height: e.height
-})), zV = $(bV, xV, (e, t) => ({
+})), BV = $(xV, SV, (e, t) => ({
x: 0,
y: 0,
width: e,
height: t
-})), BV = /*#__PURE__*/ (0, R.createContext)(null), VV = () => (0, R.useContext)(BV) != null, HV = (e) => e.brush, UV = $([
- HV,
- LV,
- CV
+})), VV = /*#__PURE__*/ (0, R.createContext)(null), HV = () => (0, R.useContext)(VV) != null, UV = (e) => e.brush, WV = $([
+ UV,
+ RV,
+ wV
], (e, t, n) => ({
height: e.height,
x: Z(e.x) ? e.x : t.left,
@@ -53311,7 +53363,7 @@ var LV = $([
}));
//#endregion
//#region node_modules/es-toolkit/dist/function/debounce.mjs
-function WV(e, t, { signal: n, edges: r } = {}) {
+function GV(e, t, { signal: n, edges: r } = {}) {
let i, a = null, o = r != null && r.includes("leading"), s = r == null || r.includes("trailing"), c = () => {
a !== null && (e.apply(i, a), i = void 0, a = null);
}, l = () => {
@@ -53336,11 +53388,11 @@ function WV(e, t, { signal: n, edges: r } = {}) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/function/debounce.mjs
-function GV(e, t = 0, n = {}) {
+function KV(e, t = 0, n = {}) {
typeof n != "object" && (n = {});
let { leading: r = !1, trailing: i = !0, maxWait: a } = n, o = [, ,];
r && (o[0] = "leading"), i && (o[1] = "trailing");
- let s, c = null, l = WV(function(...t) {
+ let s, c = null, l = GV(function(...t) {
s = e.apply(this, t), c = null;
}, t, { edges: o }), u = function(...t) {
return a != null && (c === null && (c = Date.now()), Date.now() - c >= a) ? ((r || i) && (s = e.apply(this, t)), c = Date.now(), l.cancel(), l.schedule(), s) : (l.apply(this, t), s);
@@ -53349,9 +53401,9 @@ function GV(e, t = 0, n = {}) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/function/throttle.mjs
-function KV(e, t = 0, n = {}) {
+function qV(e, t = 0, n = {}) {
let { leading: r = !0, trailing: i = !0 } = n;
- return GV(e, t, {
+ return KV(e, t, {
leading: r,
maxWait: t,
trailing: i
@@ -53359,7 +53411,7 @@ function KV(e, t = 0, n = {}) {
}
//#endregion
//#region node_modules/recharts/es6/util/LogUtils.js
-var qV = function(e, t) {
+var JV = function(e, t) {
var n = [...arguments].slice(2);
if (typeof console < "u" && console.warn && (t === void 0 && console.warn("LogUtils requires an error message argument"), !e)) {
if (t === void 0) console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");
@@ -53368,7 +53420,7 @@ var qV = function(e, t) {
console.warn(t.replace(/%s/g, () => n[r++]));
}
}
-}, JV = {
+}, YV = {
width: "100%",
height: "100%",
debounce: 0,
@@ -53377,45 +53429,45 @@ var qV = function(e, t) {
width: -1,
height: -1
}
-}, YV = (e, t, n) => {
- var { width: r = JV.width, height: i = JV.height, aspect: a, maxHeight: o } = n, s = OL(r) ? e : Number(r), c = OL(i) ? t : Number(i);
+}, XV = (e, t, n) => {
+ var { width: r = YV.width, height: i = YV.height, aspect: a, maxHeight: o } = n, s = kL(r) ? e : Number(r), c = kL(i) ? t : Number(i);
return a && a > 0 && (s ? c = s / a : c && (s = c * a), o && c != null && c > o && (c = o)), {
calculatedWidth: s,
calculatedHeight: c
};
-}, XV = {
+}, ZV = {
width: 0,
height: 0,
overflow: "visible"
-}, ZV = {
+}, QV = {
width: 0,
overflowX: "visible"
-}, QV = {
+}, $V = {
height: 0,
overflowY: "visible"
-}, $V = {}, eH = (e) => {
- var { width: t, height: n } = e, r = OL(t), i = OL(n);
- return r && i ? XV : r ? ZV : i ? QV : $V;
+}, eH = {}, tH = (e) => {
+ var { width: t, height: n } = e, r = kL(t), i = kL(n);
+ return r && i ? ZV : r ? QV : i ? $V : eH;
};
-function tH(e) {
+function nH(e) {
var { width: t, height: n, aspect: r } = e, i = t, a = n;
- return i === void 0 && a === void 0 ? (i = JV.width, a = JV.height) : i === void 0 ? i = r && r > 0 ? void 0 : JV.width : a === void 0 && (a = r && r > 0 ? void 0 : JV.height), {
+ return i === void 0 && a === void 0 ? (i = YV.width, a = YV.height) : i === void 0 ? i = r && r > 0 ? void 0 : YV.width : a === void 0 && (a = r && r > 0 ? void 0 : YV.height), {
width: i,
height: a
};
}
//#endregion
//#region node_modules/recharts/es6/component/ResponsiveContainer.js
-function nH() {
- return nH = Object.assign ? Object.assign.bind() : function(e) {
+function rH() {
+ return rH = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, nH.apply(null, arguments);
+ }, rH.apply(null, arguments);
}
-function rH(e, t) {
+function iH(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -53425,30 +53477,30 @@ function rH(e, t) {
}
return n;
}
-function iH(e) {
+function aH(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? rH(Object(n), !0).forEach(function(t) {
- aH(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : rH(Object(n)).forEach(function(t) {
+ t % 2 ? iH(Object(n), !0).forEach(function(t) {
+ oH(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : iH(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function aH(e, t, n) {
- return (t = oH(t)) in e ? Object.defineProperty(e, t, {
+function oH(e, t, n) {
+ return (t = sH(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function oH(e) {
- var t = sH(e, "string");
+function sH(e) {
+ var t = cH(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function sH(e, t) {
+function cH(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -53458,19 +53510,19 @@ function sH(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var cH = /*#__PURE__*/ (0, R.createContext)(JV.initialDimension);
-function lH(e) {
- return KB(e.width) && KB(e.height);
-}
+var lH = /*#__PURE__*/ (0, R.createContext)(YV.initialDimension);
function uH(e) {
+ return qB(e.width) && qB(e.height);
+}
+function dH(e) {
var { children: t, width: n, height: r } = e, i = (0, R.useMemo)(() => ({
width: n,
height: r
}), [n, r]);
- return lH(i) ? /*#__PURE__*/ R.createElement(cH.Provider, { value: i }, t) : null;
+ return uH(i) ? /*#__PURE__*/ R.createElement(lH.Provider, { value: i }, t) : null;
}
-var dH = () => (0, R.useContext)(cH), fH = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var { aspect: n, initialDimension: r = JV.initialDimension, width: i, height: a, minWidth: o = JV.minWidth, minHeight: s, maxHeight: c, children: l, debounce: u = JV.debounce, id: d, className: f, onResize: p, style: m = {} } = e, h = (0, R.useRef)(null), g = (0, R.useRef)();
+var fH = () => (0, R.useContext)(lH), pH = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var { aspect: n, initialDimension: r = YV.initialDimension, width: i, height: a, minWidth: o = YV.minWidth, minHeight: s, maxHeight: c, children: l, debounce: u = YV.debounce, id: d, className: f, onResize: p, style: m = {} } = e, h = (0, R.useRef)(null), g = (0, R.useRef)();
g.current = p, (0, R.useImperativeHandle)(t, () => h.current);
var [_, v] = (0, R.useState)({
containerWidth: r.width,
@@ -53485,7 +53537,7 @@ var dH = () => (0, R.useContext)(cH), fH = /*#__PURE__*/ (0, R.forwardRef)((e, t
});
}, []);
(0, R.useEffect)(() => {
- if (h.current == null || typeof ResizeObserver > "u") return RL;
+ if (h.current == null || typeof ResizeObserver > "u") return zL;
var e = (e) => {
var t, n = e[0];
if (n != null) {
@@ -53493,7 +53545,7 @@ var dH = () => (0, R.useContext)(cH), fH = /*#__PURE__*/ (0, R.forwardRef)((e, t
y(r, i), (t = g.current) == null || t.call(g, r, i);
}
};
- u > 0 && (e = KV(e, u, {
+ u > 0 && (e = qV(e, u, {
trailing: !0,
leading: !1
}));
@@ -53503,17 +53555,17 @@ var dH = () => (0, R.useContext)(cH), fH = /*#__PURE__*/ (0, R.forwardRef)((e, t
};
}, [y, u]);
var { containerWidth: b, containerHeight: x } = _;
- qV(!n || n > 0, "The aspect(%s) must be greater than zero.", n);
- var { calculatedWidth: S, calculatedHeight: C } = YV(b, x, {
+ JV(!n || n > 0, "The aspect(%s) must be greater than zero.", n);
+ var { calculatedWidth: S, calculatedHeight: C } = XV(b, x, {
width: i,
height: a,
aspect: n,
maxHeight: c
});
- return qV(S != null && S > 0 || C != null && C > 0, "The width(%s) and height(%s) of chart should be greater than 0,\n please check the style of container, or the props width(%s) and height(%s),\n or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the\n height and width.", S, C, i, a, o, s, n), /*#__PURE__*/ R.createElement("div", {
+ return JV(S != null && S > 0 || C != null && C > 0, "The width(%s) and height(%s) of chart should be greater than 0,\n please check the style of container, or the props width(%s) and height(%s),\n or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the\n height and width.", S, C, i, a, o, s, n), /*#__PURE__*/ R.createElement("div", {
id: d ? `${d}` : void 0,
className: ja("recharts-responsive-container", f),
- style: iH(iH({}, m), {}, {
+ style: aH(aH({}, m), {}, {
width: i,
height: a,
minWidth: o,
@@ -53521,30 +53573,30 @@ var dH = () => (0, R.useContext)(cH), fH = /*#__PURE__*/ (0, R.forwardRef)((e, t
maxHeight: c
}),
ref: h
- }, /*#__PURE__*/ R.createElement("div", { style: eH({
+ }, /*#__PURE__*/ R.createElement("div", { style: tH({
width: i,
height: a
- }) }, /*#__PURE__*/ R.createElement(uH, {
+ }) }, /*#__PURE__*/ R.createElement(dH, {
width: S,
height: C
}, l)));
-}), pH = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var n = dH();
- if (KB(n.width) && KB(n.height)) return e.children;
- var { width: r, height: i } = tH({
+}), mH = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var n = fH();
+ if (qB(n.width) && qB(n.height)) return e.children;
+ var { width: r, height: i } = nH({
width: e.width,
height: e.height,
aspect: e.aspect
- }), { calculatedWidth: a, calculatedHeight: o } = YV(void 0, void 0, {
+ }), { calculatedWidth: a, calculatedHeight: o } = XV(void 0, void 0, {
width: r,
height: i,
aspect: e.aspect,
maxHeight: e.maxHeight
});
- return Z(a) && Z(o) ? /*#__PURE__*/ R.createElement(uH, {
+ return Z(a) && Z(o) ? /*#__PURE__*/ R.createElement(dH, {
width: a,
height: o
- }, e.children) : /*#__PURE__*/ R.createElement(fH, nH({}, e, {
+ }, e.children) : /*#__PURE__*/ R.createElement(pH, rH({}, e, {
width: r,
height: i,
ref: t
@@ -53552,7 +53604,7 @@ var dH = () => (0, R.useContext)(cH), fH = /*#__PURE__*/ (0, R.forwardRef)((e, t
});
//#endregion
//#region node_modules/recharts/es6/context/chartLayoutContext.js
-function mH(e) {
+function hH(e) {
if (e) return {
x: e.x,
y: e.y,
@@ -53562,15 +53614,15 @@ function mH(e) {
height: e.height
};
}
-var hH = () => {
- var e = VV(), t = Q(RV), n = Q(UV), r = Q(HV)?.padding;
+var gH = () => {
+ var e = HV(), t = Q(zV), n = Q(WV), r = Q(UV)?.padding;
return !e || !n || !r ? t : {
width: n.width - r.left - r.right,
height: n.height - r.top - r.bottom,
x: r.left,
y: r.top
};
-}, gH = {
+}, _H = {
top: 0,
bottom: 0,
left: 0,
@@ -53578,16 +53630,16 @@ var hH = () => {
width: 0,
height: 0,
brushBottom: 0
-}, _H = () => Q(LV) ?? gH, vH = () => Q(bV), yH = () => Q(xV), bH = () => Q((e) => e.layout.margin), xH = (e) => e.layout.layoutType, SH = () => Q(xH), CH = () => {
- var e = SH();
+}, vH = () => Q(RV) ?? _H, yH = () => Q(xV), bH = () => Q(SV), xH = () => Q((e) => e.layout.margin), SH = (e) => e.layout.layoutType, CH = () => Q(SH), wH = () => {
+ var e = CH();
if (e === "horizontal" || e === "vertical") return e;
-}, wH = (e) => {
+}, TH = (e) => {
var t = e.layout.layoutType;
if (t === "centric" || t === "radial") return t;
-}, TH = () => Q(wH), EH = () => SH() !== void 0, DH = (e) => {
- var t = xR(), n = VV(), { width: r, height: i } = e, a = dH(), o = r, s = i;
+}, EH = () => Q(TH), DH = () => CH() !== void 0, OH = (e) => {
+ var t = SR(), n = HV(), { width: r, height: i } = e, a = fH(), o = r, s = i;
return a && (o = a.width > 0 ? a.width : r, s = a.height > 0 ? a.height : i), (0, R.useEffect)(() => {
- !n && KB(o) && KB(s) && t(VB({
+ !n && qB(o) && qB(s) && t(HB({
width: o,
height: s
}));
@@ -53597,64 +53649,64 @@ var hH = () => {
o,
s
]), null;
-}, OH = Symbol.for("immer-nothing"), kH = Symbol.for("immer-draftable"), AH = Symbol.for("immer-state");
-function jH(e, ...t) {
+}, kH = Symbol.for("immer-nothing"), AH = Symbol.for("immer-draftable"), jH = Symbol.for("immer-state");
+function MH(e, ...t) {
throw Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`);
}
-var MH = Object.getPrototypeOf;
-function NH(e) {
- return !!e && !!e[AH];
-}
+var NH = Object.getPrototypeOf;
function PH(e) {
- return e ? LH(e) || Array.isArray(e) || !!e[kH] || !!e.constructor?.[kH] || UH(e) || WH(e) : !1;
+ return !!e && !!e[jH];
+}
+function FH(e) {
+ return e ? RH(e) || Array.isArray(e) || !!e[AH] || !!e.constructor?.[AH] || WH(e) || GH(e) : !1;
}
-var FH = Object.prototype.constructor.toString(), IH = /* @__PURE__ */ new WeakMap();
-function LH(e) {
+var IH = Object.prototype.constructor.toString(), LH = /* @__PURE__ */ new WeakMap();
+function RH(e) {
if (!e || typeof e != "object") return !1;
let t = Object.getPrototypeOf(e);
if (t === null || t === Object.prototype) return !0;
let n = Object.hasOwnProperty.call(t, "constructor") && t.constructor;
if (n === Object) return !0;
if (typeof n != "function") return !1;
- let r = IH.get(n);
- return r === void 0 && (r = Function.toString.call(n), IH.set(n, r)), r === FH;
+ let r = LH.get(n);
+ return r === void 0 && (r = Function.toString.call(n), LH.set(n, r)), r === IH;
}
-function RH(e, t, n = !0) {
- zH(e) === 0 ? (n ? Reflect.ownKeys(e) : Object.keys(e)).forEach((n) => {
+function zH(e, t, n = !0) {
+ BH(e) === 0 ? (n ? Reflect.ownKeys(e) : Object.keys(e)).forEach((n) => {
t(n, e[n], e);
}) : e.forEach((n, r) => t(r, n, e));
}
-function zH(e) {
- let t = e[AH];
- return t ? t.type_ : Array.isArray(e) ? 1 : UH(e) ? 2 : WH(e) ? 3 : 0;
+function BH(e) {
+ let t = e[jH];
+ return t ? t.type_ : Array.isArray(e) ? 1 : WH(e) ? 2 : GH(e) ? 3 : 0;
}
-function BH(e, t) {
- return zH(e) === 2 ? e.has(t) : Object.prototype.hasOwnProperty.call(e, t);
+function VH(e, t) {
+ return BH(e) === 2 ? e.has(t) : Object.prototype.hasOwnProperty.call(e, t);
}
-function VH(e, t, n) {
- let r = zH(e);
+function HH(e, t, n) {
+ let r = BH(e);
r === 2 ? e.set(t, n) : r === 3 ? e.add(n) : e[t] = n;
}
-function HH(e, t) {
+function UH(e, t) {
return e === t ? e !== 0 || 1 / e == 1 / t : e !== e && t !== t;
}
-function UH(e) {
+function WH(e) {
return e instanceof Map;
}
-function WH(e) {
+function GH(e) {
return e instanceof Set;
}
-function GH(e) {
+function KH(e) {
return e.copy_ || e.base_;
}
-function KH(e, t) {
- if (UH(e)) return new Map(e);
- if (WH(e)) return new Set(e);
+function qH(e, t) {
+ if (WH(e)) return new Map(e);
+ if (GH(e)) return new Set(e);
if (Array.isArray(e)) return Array.prototype.slice.call(e);
- let n = LH(e);
+ let n = RH(e);
if (t === !0 || t === "class_only" && !n) {
let t = Object.getOwnPropertyDescriptors(e);
- delete t[AH];
+ delete t[jH];
let n = Reflect.ownKeys(t);
for (let r = 0; r < n.length; r++) {
let i = n[r], a = t[i];
@@ -53665,40 +53717,40 @@ function KH(e, t) {
value: e[i]
});
}
- return Object.create(MH(e), t);
+ return Object.create(NH(e), t);
}
{
- let t = MH(e);
+ let t = NH(e);
if (t !== null && n) return { ...e };
let r = Object.create(t);
return Object.assign(r, e);
}
}
-function qH(e, t = !1) {
- return XH(e) || NH(e) || !PH(e) ? e : (zH(e) > 1 && Object.defineProperties(e, {
- set: YH,
- add: YH,
- clear: YH,
- delete: YH
- }), Object.freeze(e), t && Object.values(e).forEach((e) => qH(e, !0)), e);
+function JH(e, t = !1) {
+ return ZH(e) || PH(e) || !FH(e) ? e : (BH(e) > 1 && Object.defineProperties(e, {
+ set: XH,
+ add: XH,
+ clear: XH,
+ delete: XH
+ }), Object.freeze(e), t && Object.values(e).forEach((e) => JH(e, !0)), e);
}
-function JH() {
- jH(2);
+function YH() {
+ MH(2);
}
-var YH = { value: JH };
-function XH(e) {
+var XH = { value: YH };
+function ZH(e) {
return typeof e != "object" || !e || Object.isFrozen(e);
}
-var ZH = {};
-function QH(e) {
- let t = ZH[e];
- return t || jH(0, e), t;
+var QH = {};
+function $H(e) {
+ let t = QH[e];
+ return t || MH(0, e), t;
}
-var $H;
-function eU() {
- return $H;
+var eU;
+function tU() {
+ return eU;
}
-function tU(e, t) {
+function nU(e, t) {
return {
drafts_: [],
parent_: e,
@@ -53707,62 +53759,62 @@ function tU(e, t) {
unfinalizedDrafts_: 0
};
}
-function nU(e, t) {
- t && (QH("Patches"), e.patches_ = [], e.inversePatches_ = [], e.patchListener_ = t);
-}
-function rU(e) {
- iU(e), e.drafts_.forEach(oU), e.drafts_ = null;
+function rU(e, t) {
+ t && ($H("Patches"), e.patches_ = [], e.inversePatches_ = [], e.patchListener_ = t);
}
function iU(e) {
- e === $H && ($H = e.parent_);
+ aU(e), e.drafts_.forEach(sU), e.drafts_ = null;
}
function aU(e) {
- return $H = tU($H, e);
+ e === eU && (eU = e.parent_);
}
function oU(e) {
- let t = e[AH];
+ return eU = nU(eU, e);
+}
+function sU(e) {
+ let t = e[jH];
t.type_ === 0 || t.type_ === 1 ? t.revoke_() : t.revoked_ = !0;
}
-function sU(e, t) {
+function cU(e, t) {
t.unfinalizedDrafts_ = t.drafts_.length;
let n = t.drafts_[0];
- return e !== void 0 && e !== n ? (n[AH].modified_ && (rU(t), jH(4)), PH(e) && (e = cU(t, e), t.parent_ || uU(t, e)), t.patches_ && QH("Patches").generateReplacementPatches_(n[AH].base_, e, t.patches_, t.inversePatches_)) : e = cU(t, n, []), rU(t), t.patches_ && t.patchListener_(t.patches_, t.inversePatches_), e === OH ? void 0 : e;
+ return e !== void 0 && e !== n ? (n[jH].modified_ && (iU(t), MH(4)), FH(e) && (e = lU(t, e), t.parent_ || dU(t, e)), t.patches_ && $H("Patches").generateReplacementPatches_(n[jH].base_, e, t.patches_, t.inversePatches_)) : e = lU(t, n, []), iU(t), t.patches_ && t.patchListener_(t.patches_, t.inversePatches_), e === kH ? void 0 : e;
}
-function cU(e, t, n) {
- if (XH(t)) return t;
- let r = e.immer_.shouldUseStrictIteration(), i = t[AH];
- if (!i) return RH(t, (r, a) => lU(e, i, t, r, a, n), r), t;
+function lU(e, t, n) {
+ if (ZH(t)) return t;
+ let r = e.immer_.shouldUseStrictIteration(), i = t[jH];
+ if (!i) return zH(t, (r, a) => uU(e, i, t, r, a, n), r), t;
if (i.scope_ !== e) return t;
- if (!i.modified_) return uU(e, i.base_, !0), i.base_;
+ if (!i.modified_) return dU(e, i.base_, !0), i.base_;
if (!i.finalized_) {
i.finalized_ = !0, i.scope_.unfinalizedDrafts_--;
let t = i.copy_, a = t, o = !1;
- i.type_ === 3 && (a = new Set(t), t.clear(), o = !0), RH(a, (r, a) => lU(e, i, t, r, a, n, o), r), uU(e, t, !1), n && e.patches_ && QH("Patches").generatePatches_(i, n, e.patches_, e.inversePatches_);
+ i.type_ === 3 && (a = new Set(t), t.clear(), o = !0), zH(a, (r, a) => uU(e, i, t, r, a, n, o), r), dU(e, t, !1), n && e.patches_ && $H("Patches").generatePatches_(i, n, e.patches_, e.inversePatches_);
}
return i.copy_;
}
-function lU(e, t, n, r, i, a, o) {
+function uU(e, t, n, r, i, a, o) {
if (i == null || typeof i != "object" && !o) return;
- let s = XH(i);
+ let s = ZH(i);
if (!(s && !o)) {
- if (NH(i)) {
- let o = cU(e, i, a && t && t.type_ !== 3 && !BH(t.assigned_, r) ? a.concat(r) : void 0);
- if (VH(n, r, o), NH(o)) e.canAutoFreeze_ = !1;
+ if (PH(i)) {
+ let o = lU(e, i, a && t && t.type_ !== 3 && !VH(t.assigned_, r) ? a.concat(r) : void 0);
+ if (HH(n, r, o), PH(o)) e.canAutoFreeze_ = !1;
else return;
} else o && n.add(i);
- if (PH(i) && !s) {
+ if (FH(i) && !s) {
if (!e.immer_.autoFreeze_ && e.unfinalizedDrafts_ < 1 || t && t.base_ && t.base_[r] === i && s) return;
- cU(e, i), (!t || !t.scope_.parent_) && typeof r != "symbol" && (UH(n) ? n.has(r) : Object.prototype.propertyIsEnumerable.call(n, r)) && uU(e, i);
+ lU(e, i), (!t || !t.scope_.parent_) && typeof r != "symbol" && (WH(n) ? n.has(r) : Object.prototype.propertyIsEnumerable.call(n, r)) && dU(e, i);
}
}
}
-function uU(e, t, n = !1) {
- !e.parent_ && e.immer_.autoFreeze_ && e.canAutoFreeze_ && qH(t, n);
+function dU(e, t, n = !1) {
+ !e.parent_ && e.immer_.autoFreeze_ && e.canAutoFreeze_ && JH(t, n);
}
-function dU(e, t) {
+function Ube(e, t) {
let n = Array.isArray(e), r = {
type_: +!!n,
- scope_: t ? t.scope_ : eU(),
+ scope_: t ? t.scope_ : tU(),
modified_: !1,
finalized_: !1,
assigned_: {},
@@ -53779,25 +53831,25 @@ function dU(e, t) {
}
var fU = {
get(e, t) {
- if (t === AH) return e;
- let n = GH(e);
- if (!BH(n, t)) return Ube(e, n, t);
+ if (t === jH) return e;
+ let n = KH(e);
+ if (!VH(n, t)) return Wbe(e, n, t);
let r = n[t];
- return e.finalized_ || !PH(r) ? r : r === mU(e.base_, t) ? (_U(e), e.copy_[t] = vU(r, e)) : r;
+ return e.finalized_ || !FH(r) ? r : r === mU(e.base_, t) ? (_U(e), e.copy_[t] = vU(r, e)) : r;
},
has(e, t) {
- return t in GH(e);
+ return t in KH(e);
},
ownKeys(e) {
- return Reflect.ownKeys(GH(e));
+ return Reflect.ownKeys(KH(e));
},
set(e, t, n) {
- let r = hU(GH(e), t);
+ let r = hU(KH(e), t);
if (r?.set) return r.set.call(e.draft_, n), !0;
if (!e.modified_) {
- let r = mU(GH(e), t), i = r?.[AH];
+ let r = mU(KH(e), t), i = r?.[jH];
if (i && i.base_ === n) return e.copy_[t] = n, e.assigned_[t] = !1, !0;
- if (HH(n, r) && (n !== void 0 || BH(e.base_, t))) return !0;
+ if (UH(n, r) && (n !== void 0 || VH(e.base_, t))) return !0;
_U(e), gU(e);
}
return e.copy_[t] === n && (n !== void 0 || t in e.copy_) || Number.isNaN(n) && Number.isNaN(e.copy_[t]) ? !0 : (e.copy_[t] = n, e.assigned_[t] = !0, !0);
@@ -53806,7 +53858,7 @@ var fU = {
return mU(e.base_, t) !== void 0 || t in e.base_ ? (e.assigned_[t] = !1, _U(e), gU(e)) : delete e.assigned_[t], e.copy_ && delete e.copy_[t], !0;
},
getOwnPropertyDescriptor(e, t) {
- let n = GH(e), r = Reflect.getOwnPropertyDescriptor(n, t);
+ let n = KH(e), r = Reflect.getOwnPropertyDescriptor(n, t);
return r && {
writable: !0,
configurable: e.type_ !== 1 || t !== "length",
@@ -53815,16 +53867,16 @@ var fU = {
};
},
defineProperty() {
- jH(11);
+ MH(11);
},
getPrototypeOf(e) {
- return MH(e.base_);
+ return NH(e.base_);
},
setPrototypeOf() {
- jH(12);
+ MH(12);
}
}, pU = {};
-RH(fU, (e, t) => {
+zH(fU, (e, t) => {
pU[e] = function() {
return arguments[0] = arguments[0][0], t.apply(this, arguments);
};
@@ -53834,29 +53886,29 @@ RH(fU, (e, t) => {
return fU.set.call(this, e[0], t, n, e[0]);
};
function mU(e, t) {
- let n = e[AH];
- return (n ? GH(n) : e)[t];
+ let n = e[jH];
+ return (n ? KH(n) : e)[t];
}
-function Ube(e, t, n) {
+function Wbe(e, t, n) {
let r = hU(t, n);
return r ? "value" in r ? r.value : r.get?.call(e.draft_) : void 0;
}
function hU(e, t) {
if (!(t in e)) return;
- let n = MH(e);
+ let n = NH(e);
for (; n;) {
let e = Object.getOwnPropertyDescriptor(n, t);
if (e) return e;
- n = MH(n);
+ n = NH(n);
}
}
function gU(e) {
e.modified_ || (e.modified_ = !0, e.parent_ && gU(e.parent_));
}
function _U(e) {
- e.copy_ ||= KH(e.base_, e.scope_.immer_.useStrictShallowCopy_);
+ e.copy_ ||= qH(e.base_, e.scope_.immer_.useStrictShallowCopy_);
}
-var Wbe = class {
+var Gbe = class {
constructor(e) {
this.autoFreeze_ = !0, this.useStrictShallowCopy_ = !1, this.useStrictIteration_ = !0, this.produce = (e, t, n) => {
if (typeof e == "function" && typeof t != "function") {
@@ -53867,25 +53919,25 @@ var Wbe = class {
return r.produce(e, (e) => t.call(this, e, ...i));
};
}
- typeof t != "function" && jH(6), n !== void 0 && typeof n != "function" && jH(7);
+ typeof t != "function" && MH(6), n !== void 0 && typeof n != "function" && MH(7);
let r;
- if (PH(e)) {
- let i = aU(this), a = vU(e, void 0), o = !0;
+ if (FH(e)) {
+ let i = oU(this), a = vU(e, void 0), o = !0;
try {
r = t(a), o = !1;
} finally {
- o ? rU(i) : iU(i);
+ o ? iU(i) : aU(i);
}
- return nU(i, n), sU(r, i);
+ return rU(i, n), cU(r, i);
}
if (!e || typeof e != "object") {
- if (r = t(e), r === void 0 && (r = e), r === OH && (r = void 0), this.autoFreeze_ && qH(r, !0), n) {
+ if (r = t(e), r === void 0 && (r = e), r === kH && (r = void 0), this.autoFreeze_ && JH(r, !0), n) {
let t = [], i = [];
- QH("Patches").generateReplacementPatches_(e, r, t, i), n(t, i);
+ $H("Patches").generateReplacementPatches_(e, r, t, i), n(t, i);
}
return r;
}
- jH(1, e);
+ MH(1, e);
}, this.produceWithPatches = (e, t) => {
if (typeof e == "function") return (t, ...n) => this.produceWithPatches(t, (t) => e(t, ...n));
let n, r;
@@ -53899,15 +53951,15 @@ var Wbe = class {
}, typeof e?.autoFreeze == "boolean" && this.setAutoFreeze(e.autoFreeze), typeof e?.useStrictShallowCopy == "boolean" && this.setUseStrictShallowCopy(e.useStrictShallowCopy), typeof e?.useStrictIteration == "boolean" && this.setUseStrictIteration(e.useStrictIteration);
}
createDraft(e) {
- PH(e) || jH(8), NH(e) && (e = Gbe(e));
- let t = aU(this), n = vU(e, void 0);
- return n[AH].isManual_ = !0, iU(t), n;
+ FH(e) || MH(8), PH(e) && (e = Kbe(e));
+ let t = oU(this), n = vU(e, void 0);
+ return n[jH].isManual_ = !0, aU(t), n;
}
finishDraft(e, t) {
- let n = e && e[AH];
- (!n || !n.isManual_) && jH(9);
+ let n = e && e[jH];
+ (!n || !n.isManual_) && MH(9);
let { scope_: r } = n;
- return nU(r, t), sU(void 0, r);
+ return rU(r, t), cU(void 0, r);
}
setAutoFreeze(e) {
this.autoFreeze_ = e;
@@ -53931,35 +53983,35 @@ var Wbe = class {
}
}
n > -1 && (t = t.slice(n + 1));
- let r = QH("Patches").applyPatches_;
- return NH(e) ? r(e, t) : this.produce(e, (e) => r(e, t));
+ let r = $H("Patches").applyPatches_;
+ return PH(e) ? r(e, t) : this.produce(e, (e) => r(e, t));
}
};
function vU(e, t) {
- let n = UH(e) ? QH("MapSet").proxyMap_(e, t) : WH(e) ? QH("MapSet").proxySet_(e, t) : dU(e, t);
- return (t ? t.scope_ : eU()).drafts_.push(n), n;
+ let n = WH(e) ? $H("MapSet").proxyMap_(e, t) : GH(e) ? $H("MapSet").proxySet_(e, t) : Ube(e, t);
+ return (t ? t.scope_ : tU()).drafts_.push(n), n;
}
-function Gbe(e) {
- return NH(e) || jH(10, e), yU(e);
+function Kbe(e) {
+ return PH(e) || MH(10, e), yU(e);
}
function yU(e) {
- if (!PH(e) || XH(e)) return e;
- let t = e[AH], n, r = !0;
+ if (!FH(e) || ZH(e)) return e;
+ let t = e[jH], n, r = !0;
if (t) {
if (!t.modified_) return t.base_;
- t.finalized_ = !0, n = KH(e, t.scope_.immer_.useStrictShallowCopy_), r = t.scope_.immer_.shouldUseStrictIteration();
- } else n = KH(e, !0);
- return RH(n, (e, t) => {
- VH(n, e, yU(t));
+ t.finalized_ = !0, n = qH(e, t.scope_.immer_.useStrictShallowCopy_), r = t.scope_.immer_.shouldUseStrictIteration();
+ } else n = qH(e, !0);
+ return zH(n, (e, t) => {
+ HH(n, e, yU(t));
}, r), t && (t.finalized_ = !1), n;
}
-new Wbe().produce;
+new Gbe().produce;
function bU(e) {
return e;
}
//#endregion
//#region node_modules/recharts/es6/state/legendSlice.js
-var xU = oB({
+var xU = sB({
name: "legend",
initialState: {
settings: {
@@ -53985,41 +54037,41 @@ var xU = oB({
reducer(e, t) {
e.payload.push(bU(t.payload));
},
- prepare: nB()
+ prepare: rB()
},
replaceLegendPayload: {
reducer(e, t) {
- var { prev: n, next: r } = t.payload, i = qz(e).payload.indexOf(bU(n));
+ var { prev: n, next: r } = t.payload, i = Jz(e).payload.indexOf(bU(n));
i > -1 && (e.payload[i] = bU(r));
},
- prepare: nB()
+ prepare: rB()
},
removeLegendPayload: {
reducer(e, t) {
- var n = qz(e).payload.indexOf(bU(t.payload));
+ var n = Jz(e).payload.indexOf(bU(t.payload));
n > -1 && e.payload.splice(n, 1);
},
- prepare: nB()
+ prepare: rB()
}
}
-}), { setLegendSize: SU, setLegendSettings: Kbe, addLegendPayload: CU, replaceLegendPayload: wU, removeLegendPayload: TU } = xU.actions, qbe = xU.reducer, Jbe = /* @__PURE__ */ Ee(((e) => {
+}), { setLegendSize: SU, setLegendSettings: qbe, addLegendPayload: CU, replaceLegendPayload: wU, removeLegendPayload: TU } = xU.actions, Jbe = xU.reducer, Ybe = /* @__PURE__ */ Ee(((e) => {
var t = Pe();
t.useSyncExternalStore, t.useRef, t.useEffect, t.useMemo, t.useDebugValue;
}));
(/* @__PURE__ */ Ee(((e, t) => {
- t.exports = Jbe();
+ t.exports = Ybe();
})))();
-function Ybe(e) {
+function Xbe(e) {
e();
}
-function Xbe() {
+function Zbe() {
let e = null, t = null;
return {
clear() {
e = null, t = null;
},
notify() {
- Ybe(() => {
+ Xbe(() => {
let t = e;
for (; t;) t.callback(), t = t.next;
});
@@ -54045,7 +54097,7 @@ var EU = {
notify() {},
get: () => []
};
-function Zbe(e, t) {
+function Qbe(e, t) {
let n, r = EU, i = 0, a = !1;
function o(e) {
u();
@@ -54064,7 +54116,7 @@ function Zbe(e, t) {
return a;
}
function u() {
- i++, n || (n = t ? t.addNestedSub(c) : e.subscribe(c), r = Xbe());
+ i++, n || (n = t ? t.addNestedSub(c) : e.subscribe(c), r = Zbe());
}
function d() {
i--, n && i === 0 && (n(), n = void 0, r.clear(), r = EU);
@@ -54086,11 +54138,11 @@ function Zbe(e, t) {
};
return m;
}
-var Qbe = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, $be = typeof navigator < "u" && navigator.product === "ReactNative", exe = Qbe || $be ? R.useLayoutEffect : R.useEffect;
+var $be = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, exe = typeof navigator < "u" && navigator.product === "ReactNative", txe = $be || exe ? R.useLayoutEffect : R.useEffect;
function DU(e, t) {
return e === t ? e !== 0 || t !== 0 || 1 / e == 1 / t : e !== e && t !== t;
}
-function txe(e, t) {
+function nxe(e, t) {
if (DU(e, t)) return !0;
if (typeof e != "object" || !e || typeof t != "object" || !t) return !1;
let n = Object.keys(e), r = Object.keys(t);
@@ -54098,32 +54150,32 @@ function txe(e, t) {
for (let r = 0; r < n.length; r++) if (!Object.prototype.hasOwnProperty.call(t, n[r]) || !DU(e[n[r]], t[n[r]])) return !1;
return !0;
}
-var nxe = /* @__PURE__ */ Symbol.for("react-redux-context"), rxe = typeof globalThis < "u" ? globalThis : {};
-function ixe() {
+var rxe = /* @__PURE__ */ Symbol.for("react-redux-context"), ixe = typeof globalThis < "u" ? globalThis : {};
+function axe() {
if (!R.createContext) return {};
- let e = rxe[nxe] ??= /* @__PURE__ */ new Map(), t = e.get(R.createContext);
+ let e = ixe[rxe] ??= /* @__PURE__ */ new Map(), t = e.get(R.createContext);
return t || (t = R.createContext(null), e.set(R.createContext, t)), t;
}
-var axe = /* @__PURE__ */ ixe();
-function oxe(e) {
+var oxe = /* @__PURE__ */ axe();
+function sxe(e) {
let { children: t, context: n, serverState: r, store: i } = e, a = R.useMemo(() => {
- let e = Zbe(i);
+ let e = Qbe(i);
return {
store: i,
subscription: e,
getServerState: r ? () => r : void 0
};
}, [i, r]), o = R.useMemo(() => i.getState(), [i]);
- exe(() => {
+ txe(() => {
let { subscription: e } = a;
return e.onStateChange = e.notifyNestedSubs, e.trySubscribe(), o !== i.getState() && e.notifyNestedSubs(), () => {
e.tryUnsubscribe(), e.onStateChange = void 0;
};
}, [a, o]);
- let s = n || axe;
+ let s = n || oxe;
return /* @__PURE__ */ R.createElement(s.Provider, { value: a }, t);
}
-var sxe = oxe, cxe = /* @__PURE__ */ new Set([
+var cxe = sxe, lxe = /* @__PURE__ */ new Set([
"axisLine",
"tickLine",
"activeBar",
@@ -54146,19 +54198,19 @@ var sxe = oxe, cxe = /* @__PURE__ */ new Set([
"radius",
"throttledEvents"
]);
-function lxe(e, t) {
+function uxe(e, t) {
return e == null && t == null ? !0 : typeof e == "number" && typeof t == "number" ? e === t || e !== e && t !== t : e === t;
}
function OU(e, t) {
- for (var n of /* @__PURE__ */ new Set([...Object.keys(e), ...Object.keys(t)])) if (cxe.has(n)) {
+ for (var n of /* @__PURE__ */ new Set([...Object.keys(e), ...Object.keys(t)])) if (lxe.has(n)) {
if (e[n] == null && t[n] == null) continue;
- if (!txe(e[n], t[n])) return !1;
- } else if (!lxe(e[n], t[n])) return !1;
+ if (!nxe(e[n], t[n])) return !1;
+ } else if (!uxe(e[n], t[n])) return !1;
return !0;
}
//#endregion
//#region node_modules/recharts/es6/component/Legend.js
-var uxe = ["contextPayload"];
+var dxe = ["contextPayload"];
function kU() {
return kU = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
@@ -54182,26 +54234,26 @@ function jU(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? AU(Object(n), !0).forEach(function(t) {
- dxe(e, t, n[t]);
+ fxe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : AU(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function dxe(e, t, n) {
- return (t = fxe(t)) in e ? Object.defineProperty(e, t, {
+function fxe(e, t, n) {
+ return (t = pxe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function fxe(e) {
- var t = pxe(e, "string");
+function pxe(e) {
+ var t = mxe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function pxe(e, t) {
+function mxe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -54211,16 +54263,16 @@ function pxe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function mxe(e, t) {
+function hxe(e, t) {
if (e == null) return {};
- var n, r, i = hxe(e, t);
+ var n, r, i = gxe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function hxe(e, t) {
+function gxe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -54229,25 +54281,25 @@ function hxe(e, t) {
}
return n;
}
-function gxe(e) {
+function _xe(e) {
return e.value;
}
-function _xe(e) {
- var { contextPayload: t } = e, n = mxe(e, uxe), r = yR(t, e.payloadUniqBy, gxe), i = jU(jU({}, n), {}, { payload: r });
+function vxe(e) {
+ var { contextPayload: t } = e, n = hxe(e, dxe), r = bR(t, e.payloadUniqBy, _xe), i = jU(jU({}, n), {}, { payload: r });
return /*#__PURE__*/ R.isValidElement(e.content) ? /*#__PURE__*/ R.cloneElement(e.content, i) : typeof e.content == "function" ? /*#__PURE__*/ R.createElement(e.content, i) : /*#__PURE__*/ R.createElement(Wve, i);
}
-function vxe(e, t, n, r, i, a) {
+function yxe(e, t, n, r, i, a) {
var { layout: o, align: s, verticalAlign: c } = t, l, u;
return (!e || (e.left === void 0 || e.left === null) && (e.right === void 0 || e.right === null)) && (l = s === "center" && o === "vertical" ? { left: ((r || 0) - a.width) / 2 } : s === "right" ? { right: n && n.right || 0 } : { left: n && n.left || 0 }), (!e || (e.top === void 0 || e.top === null) && (e.bottom === void 0 || e.bottom === null)) && (u = c === "middle" ? { top: ((i || 0) - a.height) / 2 } : c === "bottom" ? { bottom: n && n.bottom || 0 } : { top: n && n.top || 0 }), jU(jU({}, l), u);
}
-function yxe(e) {
- var t = xR();
+function bxe(e) {
+ var t = SR();
return (0, R.useEffect)(() => {
- t(Kbe(e));
+ t(qbe(e));
}, [t, e]), null;
}
-function bxe(e) {
- var t = xR();
+function xxe(e) {
+ var t = SR();
return (0, R.useEffect)(() => (t(SU(e)), () => {
t(SU({
width: 0,
@@ -54255,10 +54307,10 @@ function bxe(e) {
}));
}), [t, e]), null;
}
-function xxe(e, t, n, r) {
+function Sxe(e, t, n, r) {
return e === "vertical" && t != null ? { height: t } : e === "horizontal" ? { width: n || r } : null;
}
-var Sxe = {
+var Cxe = {
align: "center",
iconSize: 14,
inactiveColor: "#ccc",
@@ -54266,28 +54318,28 @@ var Sxe = {
layout: "horizontal",
verticalAlign: "bottom"
};
-function Cxe(e) {
- var t = JL(e, Sxe), n = ebe(), r = R_e(), i = bH(), { width: a, height: o, wrapperStyle: s, portal: c } = t, [l, u] = MR([n]), d = vH(), f = yH();
+function wxe(e) {
+ var t = YL(e, Cxe), n = ebe(), r = R_e(), i = xH(), { width: a, height: o, wrapperStyle: s, portal: c } = t, [l, u] = NR([n]), d = yH(), f = bH();
if (d == null || f == null) return null;
- var p = d - (i?.left || 0) - (i?.right || 0), m = xxe(t.layout, o, a, p), h = c ? s : jU(jU({
+ var p = d - (i?.left || 0) - (i?.right || 0), m = Sxe(t.layout, o, a, p), h = c ? s : jU(jU({
position: "absolute",
width: m?.width || a || "auto",
height: m?.height || o || "auto"
- }, vxe(s, t, i, d, f, l)), s), g = c ?? r;
+ }, yxe(s, t, i, d, f, l)), s), g = c ?? r;
if (g == null || n == null) return null;
var _ = /*#__PURE__*/ R.createElement("div", {
className: "recharts-legend-wrapper",
style: h,
ref: u
- }, /*#__PURE__*/ R.createElement(yxe, {
+ }, /*#__PURE__*/ R.createElement(bxe, {
layout: t.layout,
align: t.align,
verticalAlign: t.verticalAlign,
itemSorter: t.itemSorter
- }), !c && /*#__PURE__*/ R.createElement(bxe, {
+ }), !c && /*#__PURE__*/ R.createElement(xxe, {
width: l.width,
height: l.height
- }), /*#__PURE__*/ R.createElement(_xe, kU({}, t, m, {
+ }), /*#__PURE__*/ R.createElement(vxe, kU({}, t, m, {
margin: i,
chartWidth: d,
chartHeight: f,
@@ -54295,7 +54347,7 @@ function Cxe(e) {
})));
return /*#__PURE__*/ (0, ze.createPortal)(_, g);
}
-var MU = /*#__PURE__*/ R.memo(Cxe, OU);
+var MU = /*#__PURE__*/ R.memo(wxe, OU);
MU.displayName = "Legend";
//#endregion
//#region node_modules/recharts/es6/component/DefaultTooltipContent.js
@@ -54322,26 +54374,26 @@ function FU(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? PU(Object(n), !0).forEach(function(t) {
- wxe(e, t, n[t]);
+ Txe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : PU(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function wxe(e, t, n) {
- return (t = Txe(t)) in e ? Object.defineProperty(e, t, {
+function Txe(e, t, n) {
+ return (t = Exe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function Txe(e) {
- var t = Exe(e, "string");
+function Exe(e) {
+ var t = Dxe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function Exe(e, t) {
+function Dxe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -54351,8 +54403,8 @@ function Exe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function Dxe(e) {
- return Array.isArray(e) && kL(e[0]) && kL(e[1]) ? e.join(" ~ ") : e;
+function Oxe(e) {
+ return Array.isArray(e) && AL(e[0]) && AL(e[1]) ? e.join(" ~ ") : e;
}
var IU = {
separator: " : ",
@@ -54372,18 +54424,18 @@ var IU = {
labelStyle: {},
accessibilityLayer: !1
};
-function Oxe(e, t) {
- return t == null ? e : kR(e, t);
+function kxe(e, t) {
+ return t == null ? e : AR(e, t);
}
-var kxe = (e) => {
+var Axe = (e) => {
var { separator: t = IU.separator, contentStyle: n, itemStyle: r, labelStyle: i = IU.labelStyle, payload: a, formatter: o, itemSorter: s, wrapperClassName: c, labelClassName: l, label: u, labelFormatter: d, accessibilityLayer: f = IU.accessibilityLayer } = e, p = () => {
if (a && a.length) {
var e = {
padding: 0,
margin: 0
- }, n = Oxe(a, s).map((e, n) => {
+ }, n = kxe(a, s).map((e, n) => {
if (e.type === "none") return null;
- var i = e.formatter || o || Dxe, { value: s, name: c } = e, l = s, u = c;
+ var i = e.formatter || o || Oxe, { value: s, name: c } = e, l = s, u = c;
if (i) {
var d = i(s, c, e, n, a);
if (Array.isArray(d)) [l, u] = d;
@@ -54395,7 +54447,7 @@ var kxe = (e) => {
className: "recharts-tooltip-item",
key: `tooltip-item-${n}`,
style: f
- }, kL(u) ? /*#__PURE__*/ R.createElement("span", { className: "recharts-tooltip-item-name" }, u) : null, kL(u) ? /*#__PURE__*/ R.createElement("span", { className: "recharts-tooltip-item-separator" }, t) : null, /*#__PURE__*/ R.createElement("span", { className: "recharts-tooltip-item-value" }, l), /*#__PURE__*/ R.createElement("span", { className: "recharts-tooltip-item-unit" }, e.unit || ""));
+ }, AL(u) ? /*#__PURE__*/ R.createElement("span", { className: "recharts-tooltip-item-name" }, u) : null, AL(u) ? /*#__PURE__*/ R.createElement("span", { className: "recharts-tooltip-item-separator" }, t) : null, /*#__PURE__*/ R.createElement("span", { className: "recharts-tooltip-item-value" }, l), /*#__PURE__*/ R.createElement("span", { className: "recharts-tooltip-item-unit" }, e.unit || ""));
});
return /*#__PURE__*/ R.createElement("ul", {
className: "recharts-tooltip-item-list",
@@ -54403,7 +54455,7 @@ var kxe = (e) => {
}, n);
}
return null;
- }, m = FU(FU({}, IU.contentStyle), n), h = FU({ margin: 0 }, i), g = !FL(u), _ = g ? u : "", v = ja("recharts-default-tooltip", c), y = ja("recharts-tooltip-label", l);
+ }, m = FU(FU({}, IU.contentStyle), n), h = FU({ margin: 0 }, i), g = !IL(u), _ = g ? u : "", v = ja("recharts-default-tooltip", c), y = ja("recharts-tooltip-label", l);
g && d && a != null && (_ = d(u, a));
var b = f ? {
role: "status",
@@ -54416,8 +54468,8 @@ var kxe = (e) => {
className: y,
style: h
}, /*#__PURE__*/ R.isValidElement(_) ? _ : `${_}`), p());
-}, LU = "recharts-tooltip-wrapper", Axe = { visibility: "hidden" };
-function jxe(e) {
+}, LU = "recharts-tooltip-wrapper", jxe = { visibility: "hidden" };
+function Mxe(e) {
var { coordinate: t, translateX: n, translateY: r } = e;
return ja(LU, {
[`${LU}-right`]: Z(n) && t && Z(t.x) && n >= t.x,
@@ -54434,11 +54486,11 @@ function RU(e) {
var f = c[r];
return f == null ? 0 : o[r] ? Math.max(u < f ? d : u, f) : l == null ? 0 : d + s > f + l ? Math.max(u, f) : Math.max(d, f);
}
-function Mxe(e) {
+function Nxe(e) {
var { translateX: t, translateY: n, useTranslate3d: r } = e;
return { transform: r ? `translate3d(${t}px, ${n}px, 0)` : `translate(${t}px, ${n}px)` };
}
-function Nxe(e) {
+function Pxe(e) {
var { allowEscapeViewBox: t, coordinate: n, offsetTop: r, offsetLeft: i, position: a, reverseDirection: o, tooltipBox: s, useTranslate3d: c, viewBox: l } = e, u, d, f;
return s.height > 0 && s.width > 0 && n ? (d = RU({
allowEscapeViewBox: t,
@@ -54460,13 +54512,13 @@ function Nxe(e) {
tooltipDimension: s.height,
viewBox: l,
viewBoxDimension: l.height
- }), u = Mxe({
+ }), u = Nxe({
translateX: d,
translateY: f,
useTranslate3d: c
- })) : u = Axe, {
+ })) : u = jxe, {
cssProperties: u,
- cssClasses: jxe({
+ cssClasses: Mxe({
translateX: d,
translateY: f,
coordinate: n
@@ -54508,26 +54560,26 @@ function HU(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? VU(Object(n), !0).forEach(function(t) {
- Pxe(e, t, n[t]);
+ Fxe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : VU(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function Pxe(e, t, n) {
- return (t = Fxe(t)) in e ? Object.defineProperty(e, t, {
+function Fxe(e, t, n) {
+ return (t = Ixe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function Fxe(e) {
- var t = Ixe(e, "string");
+function Ixe(e) {
+ var t = Lxe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function Ixe(e, t) {
+function Lxe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -54537,10 +54589,10 @@ function Ixe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function Lxe(e) {
+function Rxe(e) {
if (!(e.prefersReducedMotion && e.isAnimationActive === "auto") && e.isAnimationActive && e.active) return `transform ${e.animationDuration}ms ${e.animationEasing}`;
}
-function Rxe(e) {
+function zxe(e) {
var t = BU(), [n, r] = R.useState(() => ({
dismissed: !1,
dismissedAtCoordinate: {
@@ -54562,7 +54614,7 @@ function Rxe(e) {
document.removeEventListener("keydown", t);
};
}, [e.coordinate?.x, e.coordinate?.y]), n.dismissed && ((e.coordinate?.x ?? 0) !== n.dismissedAtCoordinate.x || (e.coordinate?.y ?? 0) !== n.dismissedAtCoordinate.y) && r(HU(HU({}, n), {}, { dismissed: !1 }));
- var { cssClasses: i, cssProperties: a } = Nxe({
+ var { cssClasses: i, cssProperties: a } = Pxe({
allowEscapeViewBox: e.allowEscapeViewBox,
coordinate: e.coordinate,
offsetLeft: typeof e.offset == "number" ? e.offset : e.offset.x,
@@ -54575,7 +54627,7 @@ function Rxe(e) {
},
useTranslate3d: e.useTranslate3d,
viewBox: e.viewBox
- }), o = HU(HU({}, e.hasPortalFromProps ? {} : HU(HU({ transition: Lxe({
+ }), o = HU(HU({}, e.hasPortalFromProps ? {} : HU(HU({ transition: Rxe({
prefersReducedMotion: t,
isAnimationActive: e.isAnimationActive,
active: e.active,
@@ -54595,7 +54647,7 @@ function Rxe(e) {
ref: e.innerRef
}, e.children);
}
-var zxe = /*#__PURE__*/ R.memo(Rxe), UU = () => Q((e) => e.rootProps.accessibilityLayer) ?? !0;
+var Bxe = /*#__PURE__*/ R.memo(zxe), UU = () => Q((e) => e.rootProps.accessibilityLayer) ?? !0;
//#endregion
//#region node_modules/recharts/es6/shape/Curve.js
function WU() {
@@ -54621,26 +54673,26 @@ function KU(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? GU(Object(n), !0).forEach(function(t) {
- Bxe(e, t, n[t]);
+ Vxe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : GU(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function Bxe(e, t, n) {
- return (t = Vxe(t)) in e ? Object.defineProperty(e, t, {
+function Vxe(e, t, n) {
+ return (t = Hxe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function Vxe(e) {
- var t = Hxe(e, "string");
+function Hxe(e) {
+ var t = Uxe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function Hxe(e, t) {
+function Uxe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -54657,33 +54709,33 @@ var qU = {
curveBumpX: V_e,
curveBumpY: H_e,
curveLinearClosed: ive,
- curveLinear: BI,
+ curveLinear: VI,
curveMonotoneX: ave,
curveMonotoneY: ove,
curveNatural: sve,
curveStep: cve,
curveStepAfter: uve,
curveStepBefore: lve
-}, JU = (e) => GB(e.x) && GB(e.y), YU = (e) => e.base != null && JU(e.base) && JU(e), XU = (e) => e.x, ZU = (e) => e.y, Uxe = (e, t) => {
+}, JU = (e) => KB(e.x) && KB(e.y), YU = (e) => e.base != null && JU(e.base) && JU(e), XU = (e) => e.x, ZU = (e) => e.y, Wxe = (e, t) => {
if (typeof e == "function") return e;
- var n = `curve${IL(e)}`;
+ var n = `curve${LL(e)}`;
if ((n === "curveMonotone" || n === "curveBump") && t) {
var r = qU[`${n}${t === "vertical" ? "Y" : "X"}`];
if (r) return r;
}
- return qU[n] || BI;
+ return qU[n] || VI;
}, QU = {
connectNulls: !1,
type: "linear"
-}, Wxe = (e) => {
- var { type: t = QU.type, points: n = [], baseLine: r, layout: i, connectNulls: a = QU.connectNulls } = e, o = Uxe(t, i), s = a ? n.filter(JU) : n;
+}, Gxe = (e) => {
+ var { type: t = QU.type, points: n = [], baseLine: r, layout: i, connectNulls: a = QU.connectNulls } = e, o = Wxe(t, i), s = a ? n.filter(JU) : n;
if (Array.isArray(r)) {
var c, l = n.map((e, t) => KU(KU({}, e), {}, { base: r[t] }));
- return c = i === "vertical" ? WI().y(ZU).x1(XU).x0((e) => e.base.x) : WI().x(XU).y1(ZU).y0((e) => e.base.y), c.defined(YU).curve(o)(a ? l.filter(YU) : l);
+ return c = i === "vertical" ? GI().y(ZU).x1(XU).x0((e) => e.base.x) : GI().x(XU).y1(ZU).y0((e) => e.base.y), c.defined(YU).curve(o)(a ? l.filter(YU) : l);
}
- return (i === "vertical" && Z(r) ? WI().y(ZU).x1(XU).x0(r) : Z(r) ? WI().x(XU).y1(ZU).y0(r) : UI().x(XU).y(ZU)).defined(JU).curve(o)(s);
+ return (i === "vertical" && Z(r) ? GI().y(ZU).x1(XU).x0(r) : Z(r) ? GI().x(XU).y1(ZU).y0(r) : WI().x(XU).y(ZU)).defined(JU).curve(o)(s);
}, $U = (e) => {
- var { className: t, points: n, path: r, pathRef: i } = e, a = SH();
+ var { className: t, points: n, path: r, pathRef: i } = e, a = CH();
if ((!n || !n.length) && !r) return null;
var o = {
type: e.type,
@@ -54691,13 +54743,13 @@ var qU = {
baseLine: e.baseLine,
layout: e.layout || a,
connectNulls: e.connectNulls
- }, s = n && n.length ? Wxe(o) : r;
- return /*#__PURE__*/ R.createElement("path", WU({}, vI(e), GL(e), {
+ }, s = n && n.length ? Gxe(o) : r;
+ return /*#__PURE__*/ R.createElement("path", WU({}, yI(e), KL(e), {
className: ja("recharts-curve", t),
d: s === null ? void 0 : s,
ref: i
}));
-}, Gxe = [
+}, Kxe = [
"x",
"y",
"top",
@@ -54725,30 +54777,30 @@ function tW(e, t) {
}
return n;
}
-function Kxe(e) {
+function qxe(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? tW(Object(n), !0).forEach(function(t) {
- qxe(e, t, n[t]);
+ Jxe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : tW(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function qxe(e, t, n) {
- return (t = Jxe(t)) in e ? Object.defineProperty(e, t, {
+function Jxe(e, t, n) {
+ return (t = Yxe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function Jxe(e) {
- var t = Yxe(e, "string");
+function Yxe(e) {
+ var t = Xxe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function Yxe(e, t) {
+function Xxe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -54758,16 +54810,16 @@ function Yxe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function Xxe(e, t) {
+function Zxe(e, t) {
if (e == null) return {};
- var n, r, i = Zxe(e, t);
+ var n, r, i = Qxe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function Zxe(e, t) {
+function Qxe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -54776,8 +54828,8 @@ function Zxe(e, t) {
}
return n;
}
-var Qxe = (e, t, n, r, i, a) => `M${e},${i}v${r}M${a},${t}h${n}`, $xe = (e) => {
- var { x: t = 0, y: n = 0, top: r = 0, left: i = 0, width: a = 0, height: o = 0, className: s } = e, c = Xxe(e, Gxe), l = Kxe({
+var $xe = (e, t, n, r, i, a) => `M${e},${i}v${r}M${a},${t}h${n}`, eSe = (e) => {
+ var { x: t = 0, y: n = 0, top: r = 0, left: i = 0, width: a = 0, height: o = 0, className: s } = e, c = Zxe(e, Kxe), l = qxe({
x: t,
y: n,
top: r,
@@ -54785,14 +54837,14 @@ var Qxe = (e, t, n, r, i, a) => `M${e},${i}v${r}M${a},${t}h${n}`, $xe = (e) => {
width: a,
height: o
}, c);
- return !Z(t) || !Z(n) || !Z(a) || !Z(o) || !Z(r) || !Z(i) ? null : /*#__PURE__*/ R.createElement("path", eW({}, bI(l), {
+ return !Z(t) || !Z(n) || !Z(a) || !Z(o) || !Z(r) || !Z(i) ? null : /*#__PURE__*/ R.createElement("path", eW({}, xI(l), {
className: ja("recharts-cross", s),
- d: Qxe(t, n, a, o, r, i)
+ d: $xe(t, n, a, o, r, i)
}));
};
//#endregion
//#region node_modules/recharts/es6/util/cursor/getCursorRectangle.js
-function eSe(e, t, n, r) {
+function tSe(e, t, n, r) {
var i = r / 2;
return {
stroke: "none",
@@ -54819,26 +54871,26 @@ function rW(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? nW(Object(n), !0).forEach(function(t) {
- tSe(e, t, n[t]);
+ nSe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : nW(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function tSe(e, t, n) {
- return (t = nSe(t)) in e ? Object.defineProperty(e, t, {
+function nSe(e, t, n) {
+ return (t = rSe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function nSe(e) {
- var t = rSe(e, "string");
+function rSe(e) {
+ var t = iSe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function rSe(e, t) {
+function iSe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -54848,7 +54900,7 @@ function rSe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var iSe = (e) => e.replace(/([A-Z])/g, (e) => `-${e.toLowerCase()}`), iW = (e, t, n) => e.map((e) => `${iSe(e)} ${t}ms ${n}`).join(","), aSe = (e, t) => [Object.keys(e), Object.keys(t)].reduce((e, t) => e.filter((e) => t.includes(e))), aW = (e, t) => Object.keys(t).reduce((n, r) => rW(rW({}, n), {}, { [r]: e(r, t[r]) }), {});
+var aSe = (e) => e.replace(/([A-Z])/g, (e) => `-${e.toLowerCase()}`), iW = (e, t, n) => e.map((e) => `${aSe(e)} ${t}ms ${n}`).join(","), oSe = (e, t) => [Object.keys(e), Object.keys(t)].reduce((e, t) => e.filter((e) => t.includes(e))), aW = (e, t) => Object.keys(t).reduce((n, r) => rW(rW({}, n), {}, { [r]: e(r, t[r]) }), {});
//#endregion
//#region node_modules/recharts/es6/animation/configUpdate.js
function oW(e, t) {
@@ -54865,26 +54917,26 @@ function sW(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? oW(Object(n), !0).forEach(function(t) {
- oSe(e, t, n[t]);
+ sSe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : oW(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function oSe(e, t, n) {
- return (t = sSe(t)) in e ? Object.defineProperty(e, t, {
+function sSe(e, t, n) {
+ return (t = cSe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function sSe(e) {
- var t = cSe(e, "string");
+function cSe(e) {
+ var t = lSe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function cSe(e, t) {
+function lSe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -54913,7 +54965,7 @@ var cW = (e, t, n) => e + (t - e) * n, lW = (e) => {
from: cW(t.from, r[e].from, n)
}) : t, t) : uW(e, r, n - 1);
};
-function lSe(e, t, n, r, i, a) {
+function uSe(e, t, n, r, i, a) {
var o, s = r.reduce((n, r) => sW(sW({}, n), {}, { [r]: {
from: e[r],
velocity: 0,
@@ -54928,7 +54980,7 @@ function lSe(e, t, n, r, i, a) {
(e = u) == null || e();
});
}
-function uSe(e, t, n, r, i, a, o) {
+function dSe(e, t, n, r, i, a, o) {
var s = null, c = i.reduce((n, r) => {
var i = e[r], a = t[r];
return i == null || a == null ? n : sW(sW({}, n), {}, { [r]: [i, a] });
@@ -54946,15 +54998,15 @@ function uSe(e, t, n, r, i, a, o) {
(e = s) == null || e();
});
}
-var dSe = (e, t, n, r, i, a) => {
- var o = aSe(e, t);
- return n == null ? () => (i(sW(sW({}, e), t)), () => {}) : n.isStepper === !0 ? lSe(e, t, n, o, i, a) : uSe(e, t, n, r, o, i, a);
+var fSe = (e, t, n, r, i, a) => {
+ var o = oSe(e, t);
+ return n == null ? () => (i(sW(sW({}, e), t)), () => {}) : n.isStepper === !0 ? uSe(e, t, n, o, i, a) : dSe(e, t, n, r, o, i, a);
}, dW = (e, t) => [
0,
3 * e,
3 * t - 6 * e,
3 * e - 3 * t + 1
-], fW = (e, t) => e.map((e, n) => e * t ** n).reduce((e, t) => e + t), pW = (e, t) => (n) => fW(dW(e, t), n), fSe = (e, t) => (n) => fW([...dW(e, t).map((e, t) => e * t).slice(1), 0], n), pSe = (e) => {
+], fW = (e, t) => e.map((e, n) => e * t ** n).reduce((e, t) => e + t), pW = (e, t) => (n) => fW(dW(e, t), n), pSe = (e, t) => (n) => fW([...dW(e, t).map((e, t) => e * t).slice(1), 0], n), mSe = (e) => {
var t, n = e.split("(");
if (n.length !== 2 || n[0] !== "cubic-bezier") return null;
var r = (t = n[1]) == null || (t = t.split(")")[0]) == null ? void 0 : t.split(",");
@@ -54966,7 +55018,7 @@ var dSe = (e, t, n, r, i, a) => {
i[2],
i[3]
];
-}, mSe = function() {
+}, hSe = function() {
var e = [...arguments];
if (e.length === 1) switch (e[0]) {
case "linear": return [
@@ -55000,7 +55052,7 @@ var dSe = (e, t, n, r, i, a) => {
1
];
default:
- var t = pSe(e[0]);
+ var t = mSe(e[0]);
if (t) return t;
}
return e.length === 4 ? e : [
@@ -55009,8 +55061,8 @@ var dSe = (e, t, n, r, i, a) => {
1,
1
];
-}, hSe = (e, t, n, r) => {
- var i = pW(e, n), a = pW(t, r), o = fSe(e, n), s = (e) => e > 1 ? 1 : e < 0 ? 0 : e, c = (e) => {
+}, gSe = (e, t, n, r) => {
+ var i = pW(e, n), a = pW(t, r), o = pSe(e, n), s = (e) => e > 1 ? 1 : e < 0 ? 0 : e, c = (e) => {
for (var t = e > 1 ? 1 : e, n = t, r = 0; r < 8; ++r) {
var c = i(n) - t, l = o(n);
if (Math.abs(c - t) < 1e-4 || l < 1e-4) return a(n);
@@ -55020,28 +55072,28 @@ var dSe = (e, t, n, r, i, a) => {
};
return c.isStepper = !1, c;
}, mW = function() {
- return hSe(...mSe(...arguments));
-}, gSe = function() {
+ return gSe(...hSe(...arguments));
+}, _Se = function() {
var { stiff: e = 100, damping: t = 8, dt: n = 17 } = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, r = (r, i, a) => {
var o = a + (-(r - i) * e - a * t) * n / 1e3, s = a * n / 1e3 + r;
return Math.abs(s - i) < 1e-4 && Math.abs(o) < 1e-4 ? [i, 0] : [s, o];
};
return r.isStepper = !0, r.dt = n, r;
-}, _Se = (e) => {
+}, vSe = (e) => {
if (typeof e == "string") switch (e) {
case "ease":
case "ease-in-out":
case "ease-out":
case "ease-in":
case "linear": return mW(e);
- case "spring": return gSe();
+ case "spring": return _Se();
default: if (e.split("(")[0] === "cubic-bezier") return mW(e);
}
return typeof e == "function" ? e : null;
};
//#endregion
//#region node_modules/recharts/es6/animation/AnimationManager.js
-function vSe(e) {
+function ySe(e) {
var t, n = () => null, r = !1, i = null, a = (o) => {
if (!r) {
if (Array.isArray(o)) {
@@ -55072,7 +55124,7 @@ function vSe(e) {
}
//#endregion
//#region node_modules/recharts/es6/animation/timeoutController.js
-var ySe = class {
+var bSe = class {
setTimeout(e) {
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0, n = performance.now(), r = null, i = (a) => {
a - n >= t ? e(a) : typeof requestAnimationFrame == "function" && (r = requestAnimationFrame(i));
@@ -55084,14 +55136,14 @@ var ySe = class {
};
//#endregion
//#region node_modules/recharts/es6/animation/createDefaultAnimationManager.js
-function bSe() {
- return vSe(new ySe());
+function xSe() {
+ return ySe(new bSe());
}
//#endregion
//#region node_modules/recharts/es6/animation/useAnimationManager.js
-var xSe = /*#__PURE__*/ (0, R.createContext)(bSe);
-function SSe(e, t) {
- var n = (0, R.useContext)(xSe);
+var SSe = /*#__PURE__*/ (0, R.createContext)(xSe);
+function CSe(e, t) {
+ var n = (0, R.useContext)(SSe);
return (0, R.useMemo)(() => t ?? n(e), [
e,
t,
@@ -55100,7 +55152,7 @@ function SSe(e, t) {
}
//#endregion
//#region node_modules/recharts/es6/animation/JavascriptAnimate.js
-var CSe = {
+var wSe = {
begin: 0,
duration: 1e3,
easing: "ease",
@@ -55110,12 +55162,12 @@ var CSe = {
onAnimationStart: () => {}
}, hW = { t: 0 }, gW = { t: 1 };
function _W(e) {
- var t = JL(e, CSe), { isActive: n, canBegin: r, duration: i, easing: a, begin: o, onAnimationEnd: s, onAnimationStart: c, children: l } = t, u = BU(), d = n === "auto" ? !zU.isSsr && !u : n, f = SSe(t.animationId, t.animationManager), [p, m] = (0, R.useState)(d ? hW : gW), h = (0, R.useRef)(null);
+ var t = YL(e, wSe), { isActive: n, canBegin: r, duration: i, easing: a, begin: o, onAnimationEnd: s, onAnimationStart: c, children: l } = t, u = BU(), d = n === "auto" ? !zU.isSsr && !u : n, f = CSe(t.animationId, t.animationManager), [p, m] = (0, R.useState)(d ? hW : gW), h = (0, R.useRef)(null);
return (0, R.useEffect)(() => {
d || m(gW);
}, [d]), (0, R.useEffect)(() => {
- if (!d || !r) return RL;
- var e = dSe(hW, gW, _Se(a), i, m, f.getTimeoutController());
+ if (!d || !r) return zL;
+ var e = fSe(hW, gW, vSe(a), i, m, f.getTimeoutController());
return f.start([
c,
o,
@@ -55141,12 +55193,12 @@ function _W(e) {
//#endregion
//#region node_modules/recharts/es6/util/useAnimationId.js
function vW(e) {
- var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "animation-", n = (0, R.useRef)(AL(t)), r = (0, R.useRef)(e);
- return r.current !== e && (n.current = AL(t), r.current = e), n.current;
+ var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "animation-", n = (0, R.useRef)(jL(t)), r = (0, R.useRef)(e);
+ return r.current !== e && (n.current = jL(t), r.current = e), n.current;
}
//#endregion
//#region node_modules/recharts/es6/shape/Rectangle.js
-var wSe = ["radius"], TSe = ["radius"], ESe, DSe, OSe, kSe, ASe, jSe, MSe, NSe, PSe, FSe;
+var TSe = ["radius"], ESe = ["radius"], DSe, OSe, kSe, ASe, jSe, MSe, NSe, PSe, FSe, ISe;
function yW(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
@@ -55161,26 +55213,26 @@ function bW(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? yW(Object(n), !0).forEach(function(t) {
- ISe(e, t, n[t]);
+ LSe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : yW(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function ISe(e, t, n) {
- return (t = LSe(t)) in e ? Object.defineProperty(e, t, {
+function LSe(e, t, n) {
+ return (t = RSe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function LSe(e) {
- var t = RSe(e, "string");
+function RSe(e) {
+ var t = zSe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function RSe(e, t) {
+function zSe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -55201,14 +55253,14 @@ function xW() {
}
function SW(e, t) {
if (e == null) return {};
- var n, r, i = zSe(e, t);
+ var n, r, i = BSe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function zSe(e, t) {
+function BSe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -55221,7 +55273,7 @@ function CW(e, t) {
return t ||= e.slice(0), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } }));
}
var wW = (e, t, n, r, i) => {
- var a = wL(n), o = wL(r), s = Math.min(Math.abs(a) / 2, Math.abs(o) / 2), c = o >= 0 ? 1 : -1, l = a >= 0 ? 1 : -1, u = +(o >= 0 && a >= 0 || o < 0 && a < 0), d;
+ var a = TL(n), o = TL(r), s = Math.min(Math.abs(a) / 2, Math.abs(o) / 2), c = o >= 0 ? 1 : -1, l = a >= 0 ? 1 : -1, u = +(o >= 0 && a >= 0 || o < 0 && a < 0), d;
if (s > 0 && Array.isArray(i)) {
for (var f = [
0,
@@ -55232,44 +55284,44 @@ var wW = (e, t, n, r, i) => {
var h = i[p] ?? 0;
f[p] = h > s ? s : h;
}
- d = TL(ESe ||= CW([
+ d = EL(DSe ||= CW([
"M",
",",
""
- ]), e, t + c * f[0]), f[0] > 0 && (d += TL(DSe ||= CW([
+ ]), e, t + c * f[0]), f[0] > 0 && (d += EL(OSe ||= CW([
"A ",
",",
",0,0,",
",",
",",
""
- ]), f[0], f[0], u, e + l * f[0], t)), d += TL(OSe ||= CW([
+ ]), f[0], f[0], u, e + l * f[0], t)), d += EL(kSe ||= CW([
"L ",
",",
""
- ]), e + n - l * f[1], t), f[1] > 0 && (d += TL(kSe ||= CW([
+ ]), e + n - l * f[1], t), f[1] > 0 && (d += EL(ASe ||= CW([
"A ",
",",
",0,0,",
",\n ",
",",
""
- ]), f[1], f[1], u, e + n, t + c * f[1])), d += TL(ASe ||= CW([
+ ]), f[1], f[1], u, e + n, t + c * f[1])), d += EL(jSe ||= CW([
"L ",
",",
""
- ]), e + n, t + r - c * f[2]), f[2] > 0 && (d += TL(jSe ||= CW([
+ ]), e + n, t + r - c * f[2]), f[2] > 0 && (d += EL(MSe ||= CW([
"A ",
",",
",0,0,",
",\n ",
",",
""
- ]), f[2], f[2], u, e + n - l * f[2], t + r)), d += TL(MSe ||= CW([
+ ]), f[2], f[2], u, e + n - l * f[2], t + r)), d += EL(NSe ||= CW([
"L ",
",",
""
- ]), e + l * f[3], t + r), f[3] > 0 && (d += TL(NSe ||= CW([
+ ]), e + l * f[3], t + r), f[3] > 0 && (d += EL(PSe ||= CW([
"A ",
",",
",0,0,",
@@ -55279,8 +55331,8 @@ var wW = (e, t, n, r, i) => {
]), f[3], f[3], u, e, t + r - c * f[3])), d += "Z";
} else if (s > 0 && i === +i && i > 0) {
var g = Math.min(s, i);
- d = TL(PSe ||= CW(/* @__PURE__ */ "M .,.\n A .,.,0,0,.,.,.\n L .,.\n A .,.,0,0,.,.,.\n L .,.\n A .,.,0,0,.,.,.\n L .,.\n A .,.,0,0,.,.,. Z".split(".")), e, t + c * g, g, g, u, e + l * g, t, e + n - l * g, t, g, g, u, e + n, t + c * g, e + n, t + r - c * g, g, g, u, e + n - l * g, t + r, e + l * g, t + r, g, g, u, e, t + r - c * g);
- } else d = TL(FSe ||= CW([
+ d = EL(FSe ||= CW(/* @__PURE__ */ "M .,.\n A .,.,0,0,.,.,.\n L .,.\n A .,.,0,0,.,.,.\n L .,.\n A .,.,0,0,.,.,.\n L .,.\n A .,.,0,0,.,.,. Z".split(".")), e, t + c * g, g, g, u, e + l * g, t, e + n - l * g, t, g, g, u, e + n, t + c * g, e + n, t + r - c * g, g, g, u, e + n - l * g, t + r, e + l * g, t + r, g, g, u, e, t + r - c * g);
+ } else d = EL(ISe ||= CW([
"M ",
",",
" h ",
@@ -55301,7 +55353,7 @@ var wW = (e, t, n, r, i) => {
animationDuration: 1500,
animationEasing: "ease"
}, EW = (e) => {
- var t = JL(e, TW), n = (0, R.useRef)(null), [r, i] = (0, R.useState)(-1);
+ var t = YL(e, TW), n = (0, R.useRef)(null), [r, i] = (0, R.useState)(-1);
(0, R.useEffect)(() => {
if (n.current && n.current.getTotalLength) try {
var e = n.current.getTotalLength();
@@ -55324,12 +55376,12 @@ var wW = (e, t, n, r, i) => {
if (a !== +a || o !== +o || s !== +s || c !== +c || s === 0 || c === 0) return null;
var x = ja("recharts-rectangle", u);
if (!h) {
- var S = bI(t), { radius: C } = S, w = SW(S, wSe);
+ var S = xI(t), { radius: C } = S, w = SW(S, TSe);
return /*#__PURE__*/ R.createElement("path", xW({}, w, {
- x: wL(a),
- y: wL(o),
- width: wL(s),
- height: wL(c),
+ x: TL(a),
+ y: TL(o),
+ width: TL(s),
+ height: TL(c),
radius: typeof l == "number" ? l : void 0,
className: x,
d: wW(a, o, s, c, l)
@@ -55345,12 +55397,12 @@ var wW = (e, t, n, r, i) => {
isActive: h,
begin: p
}, (e) => {
- var r = NL(T, s, e), i = NL(E, c, e), u = NL(D, a, e), d = NL(O, o, e);
+ var r = PL(T, s, e), i = PL(E, c, e), u = PL(D, a, e), d = PL(O, o, e);
n.current && (g.current = r, _.current = i, v.current = u, y.current = d);
var f = m ? e > 0 ? {
transition: j,
strokeDasharray: A
- } : { strokeDasharray: k } : { strokeDasharray: A }, p = bI(t), { radius: h } = p, b = SW(p, TSe);
+ } : { strokeDasharray: k } : { strokeDasharray: A }, p = xI(t), { radius: h } = p, b = SW(p, ESe);
return /*#__PURE__*/ R.createElement("path", xW({}, b, {
radius: typeof l == "number" ? l : void 0,
className: x,
@@ -55376,26 +55428,26 @@ function OW(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? DW(Object(n), !0).forEach(function(t) {
- BSe(e, t, n[t]);
+ VSe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : DW(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function BSe(e, t, n) {
- return (t = VSe(t)) in e ? Object.defineProperty(e, t, {
+function VSe(e, t, n) {
+ return (t = HSe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function VSe(e) {
- var t = HSe(e, "string");
+function HSe(e) {
+ var t = USe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function HSe(e, t) {
+function USe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -55405,10 +55457,10 @@ function HSe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var kW = Math.PI / 180, AW = (e) => e * Math.PI / 180, USe = (e) => e * 180 / Math.PI, jW = (e, t, n, r) => ({
+var kW = Math.PI / 180, AW = (e) => e * Math.PI / 180, WSe = (e) => e * 180 / Math.PI, jW = (e, t, n, r) => ({
x: e + Math.cos(-kW * r) * n,
y: t + Math.sin(-kW * r) * n
-}), WSe = function(e, t) {
+}), GSe = function(e, t) {
var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {
top: 0,
right: 0,
@@ -55419,11 +55471,11 @@ var kW = Math.PI / 180, AW = (e) => e * Math.PI / 180, USe = (e) => e * 180 / Ma
brushBottom: 0
};
return Math.min(Math.abs(e - (n.left || 0) - (n.right || 0)), Math.abs(t - (n.top || 0) - (n.bottom || 0))) / 2;
-}, GSe = (e, t) => {
+}, KSe = (e, t) => {
var { x: n, y: r } = e, { x: i, y: a } = t;
return Math.sqrt((n - i) ** 2 + (r - a) ** 2);
-}, KSe = (e, t) => {
- var { x: n, y: r } = e, { cx: i, cy: a } = t, o = GSe({
+}, qSe = (e, t) => {
+ var { x: n, y: r } = e, { cx: i, cy: a } = t, o = KSe({
x: n,
y: r
}, {
@@ -55437,25 +55489,25 @@ var kW = Math.PI / 180, AW = (e) => e * Math.PI / 180, USe = (e) => e * 180 / Ma
var s = (n - i) / o, c = Math.acos(s);
return r > a && (c = 2 * Math.PI - c), {
radius: o,
- angle: USe(c),
+ angle: WSe(c),
angleInRadian: c
};
-}, qSe = (e) => {
+}, JSe = (e) => {
var { startAngle: t, endAngle: n } = e, r = Math.floor(t / 360), i = Math.floor(n / 360), a = Math.min(r, i);
return {
startAngle: t - a * 360,
endAngle: n - a * 360
};
-}, JSe = (e, t) => {
+}, YSe = (e, t) => {
var { startAngle: n, endAngle: r } = t, i = Math.floor(n / 360), a = Math.floor(r / 360);
return e + Math.min(i, a) * 360;
-}, YSe = (e, t) => {
- var { relativeX: n, relativeY: r } = e, { radius: i, angle: a } = KSe({
+}, XSe = (e, t) => {
+ var { relativeX: n, relativeY: r } = e, { radius: i, angle: a } = qSe({
x: n,
y: r
}, t), { innerRadius: o, outerRadius: s } = t;
if (i < o || i > s || i === 0) return null;
- var { startAngle: c, endAngle: l } = qSe(t), u = a, d;
+ var { startAngle: c, endAngle: l } = JSe(t), u = a, d;
if (c <= l) {
for (; u > l;) u -= 360;
for (; u < c;) u += 360;
@@ -55467,7 +55519,7 @@ var kW = Math.PI / 180, AW = (e) => e * Math.PI / 180, USe = (e) => e * 180 / Ma
}
return d ? OW(OW({}, t), {}, {
radius: i,
- angle: JSe(u, t)
+ angle: YSe(u, t)
}) : null;
};
//#endregion
@@ -55485,7 +55537,7 @@ function MW(e) {
}
//#endregion
//#region node_modules/recharts/es6/shape/Sector.js
-var XSe, ZSe, QSe, $Se, eCe, tCe, nCe;
+var ZSe, QSe, $Se, eCe, tCe, nCe, rCe;
function NW() {
return NW = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
@@ -55498,7 +55550,7 @@ function NW() {
function PW(e, t) {
return t ||= e.slice(0), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } }));
}
-var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) => {
+var iCe = (e, t) => DL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) => {
var { cx: t, cy: n, radius: r, angle: i, sign: a, isExternal: o, cornerRadius: s, cornerIsExternal: c } = e, l = s * (o ? 1 : -1) + r, u = Math.asin(s / l) / kW, d = c ? i : i + a * u, f = jW(t, n, l, d), p = jW(t, n, r, d), m = c ? i - a * u : i;
return {
center: f,
@@ -55507,7 +55559,7 @@ var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) =>
theta: u
};
}, IW = (e) => {
- var { cx: t, cy: n, innerRadius: r, outerRadius: i, startAngle: a, endAngle: o } = e, s = rCe(a, o), c = a + s, l = jW(t, n, i, a), u = jW(t, n, i, c), d = TL(XSe ||= PW([
+ var { cx: t, cy: n, innerRadius: r, outerRadius: i, startAngle: a, endAngle: o } = e, s = iCe(a, o), c = a + s, l = jW(t, n, i, a), u = jW(t, n, i, c), d = EL(ZSe ||= PW([
"M ",
",",
"\n A ",
@@ -55520,7 +55572,7 @@ var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) =>
]), l.x, l.y, i, i, +(Math.abs(s) > 180), +(a > c), u.x, u.y);
if (r > 0) {
var f = jW(t, n, r, a), p = jW(t, n, r, c);
- d += TL(ZSe ||= PW([
+ d += EL(QSe ||= PW([
"L ",
",",
"\n A ",
@@ -55531,14 +55583,14 @@ var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) =>
",",
" Z"
]), p.x, p.y, r, r, +(Math.abs(s) > 180), +(a <= c), f.x, f.y);
- } else d += TL(QSe ||= PW([
+ } else d += EL($Se ||= PW([
"L ",
",",
" Z"
]), t, n);
return d;
-}, iCe = (e) => {
- var { cx: t, cy: n, innerRadius: r, outerRadius: i, cornerRadius: a, forceCornerRadius: o, cornerIsExternal: s, startAngle: c, endAngle: l } = e, u = EL(l - c), { circleTangency: d, lineTangency: f, theta: p } = FW({
+}, aCe = (e) => {
+ var { cx: t, cy: n, innerRadius: r, outerRadius: i, cornerRadius: a, forceCornerRadius: o, cornerIsExternal: s, startAngle: c, endAngle: l } = e, u = DL(l - c), { circleTangency: d, lineTangency: f, theta: p } = FW({
cx: t,
cy: n,
radius: i,
@@ -55555,7 +55607,7 @@ var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) =>
cornerRadius: a,
cornerIsExternal: s
}), _ = s ? Math.abs(c - l) : Math.abs(c - l) - p - g;
- if (_ < 0) return o ? TL($Se ||= PW([
+ if (_ < 0) return o ? EL(eCe ||= PW([
"M ",
",",
"\n a",
@@ -55573,7 +55625,7 @@ var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) =>
startAngle: c,
endAngle: l
});
- var v = TL(eCe ||= PW([
+ var v = EL(tCe ||= PW([
"M ",
",",
"\n A",
@@ -55615,7 +55667,7 @@ var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) =>
cornerIsExternal: s
}), T = s ? Math.abs(c - l) : Math.abs(c - l) - x - w;
if (T < 0 && a === 0) return `${v}L${t},${n}Z`;
- v += TL(tCe ||= PW([
+ v += EL(nCe ||= PW([
"L",
",",
"\n A",
@@ -55636,13 +55688,13 @@ var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) =>
",",
"Z"
]), C.x, C.y, a, a, +(u < 0), S.x, S.y, r, r, +(T > 180), +(u > 0), y.x, y.y, a, a, +(u < 0), b.x, b.y);
- } else v += TL(nCe ||= PW([
+ } else v += EL(rCe ||= PW([
"L",
",",
"Z"
]), t, n);
return v;
-}, aCe = {
+}, oCe = {
cx: 0,
cy: 0,
innerRadius: 0,
@@ -55653,9 +55705,9 @@ var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) =>
forceCornerRadius: !1,
cornerIsExternal: !1
}, LW = (e) => {
- var t = JL(e, aCe), { cx: n, cy: r, innerRadius: i, outerRadius: a, cornerRadius: o, forceCornerRadius: s, cornerIsExternal: c, startAngle: l, endAngle: u, className: d } = t;
+ var t = YL(e, oCe), { cx: n, cy: r, innerRadius: i, outerRadius: a, cornerRadius: o, forceCornerRadius: s, cornerIsExternal: c, startAngle: l, endAngle: u, className: d } = t;
if (a < i || l === u) return null;
- var f = ja("recharts-sector", d), p = a - i, m = jL(o, p, 0, !0), h = m > 0 && Math.abs(l - u) < 360 ? iCe({
+ var f = ja("recharts-sector", d), p = a - i, m = ML(o, p, 0, !0), h = m > 0 && Math.abs(l - u) < 360 ? aCe({
cx: n,
cy: r,
innerRadius: i,
@@ -55673,14 +55725,14 @@ var rCe = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 359.999), FW = (e) =>
startAngle: l,
endAngle: u
});
- return /*#__PURE__*/ R.createElement("path", NW({}, bI(t), {
+ return /*#__PURE__*/ R.createElement("path", NW({}, xI(t), {
className: f,
d: h
}));
};
//#endregion
//#region node_modules/recharts/es6/util/cursor/getCursorPoints.js
-function oCe(e, t, n) {
+function sCe(e, t, n) {
if (e === "horizontal") return [{
x: t.x,
y: n.top
@@ -55695,7 +55747,7 @@ function oCe(e, t, n) {
x: n.left + n.width,
y: t.y
}];
- if (WL(t)) {
+ if (GL(t)) {
if (e === "centric") {
var { cx: r, cy: i, innerRadius: a, outerRadius: o, angle: s } = t, c = jW(r, i, a, s), l = jW(r, i, o, s);
return [{
@@ -55711,18 +55763,18 @@ function oCe(e, t, n) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/util/toNumber.mjs
-function sCe(e) {
- return bL(e) ? NaN : Number(e);
+function cCe(e) {
+ return xL(e) ? NaN : Number(e);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/util/toFinite.mjs
function RW(e) {
- return e ? (e = sCe(e), e === Infinity || e === -Infinity ? (e < 0 ? -1 : 1) * Number.MAX_VALUE : e === e ? e : 0) : e === 0 ? e : 0;
+ return e ? (e = cCe(e), e === Infinity || e === -Infinity ? (e < 0 ? -1 : 1) * Number.MAX_VALUE : e === e ? e : 0) : e === 0 ? e : 0;
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/math/range.mjs
function zW(e, t, n) {
- n && typeof n != "number" && DR(e, t, n) && (t = n = void 0), e = RW(e), t === void 0 ? (t = e, e = 0) : t = RW(t), n = n === void 0 ? e < t ? 1 : -1 : RW(n);
+ n && typeof n != "number" && OR(e, t, n) && (t = n = void 0), e = RW(e), t === void 0 ? (t = e, e = 0) : t = RW(t), n = n === void 0 ? e < t ? 1 : -1 : RW(n);
let r = Math.max(Math.ceil((t - e) / (n || 1)), 0), i = Array(r);
for (let t = 0; t < r; t++) i[t] = e, e += n;
return i;
@@ -55743,7 +55795,7 @@ var BW = (e) => e.chartData, VW = $([BW], (e) => {
function WW(e) {
if (Array.isArray(e) && e.length === 2) {
var [t, n] = e;
- if (GB(t) && GB(n)) return !0;
+ if (KB(t) && KB(n)) return !0;
}
return !1;
}
@@ -55753,15 +55805,15 @@ function GW(e, t, n) {
function KW(e, t) {
if (t && typeof e != "function" && Array.isArray(e) && e.length === 2) {
var [n, r] = e, i, a;
- if (GB(n)) i = n;
+ if (KB(n)) i = n;
else if (typeof n == "function") return;
- if (GB(r)) a = r;
+ if (KB(r)) a = r;
else if (typeof r == "function") return;
var o = [i, a];
if (WW(o)) return o;
}
}
-function cCe(e, t, n) {
+function lCe(e, t, n) {
if (!(!n && t == null)) {
if (typeof e == "function" && t != null) try {
var r = e(t, n);
@@ -55774,8 +55826,8 @@ function cCe(e, t, n) {
else if (typeof i == "function") try {
t != null && (o = i(t?.[0]));
} catch {}
- else if (typeof i == "string" && pV.test(i)) {
- var c = pV.exec(i);
+ else if (typeof i == "string" && mV.test(i)) {
+ var c = mV.exec(i);
if (c == null || c[1] == null || t == null) o = void 0;
else {
var l = +c[1];
@@ -55787,8 +55839,8 @@ function cCe(e, t, n) {
else if (typeof a == "function") try {
t != null && (s = a(t?.[1]));
} catch {}
- else if (typeof a == "string" && mV.test(a)) {
- var u = mV.exec(a);
+ else if (typeof a == "string" && hV.test(a)) {
+ var u = hV.exec(a);
if (u == null || u[1] == null || t == null) s = void 0;
else {
var d = +u[1];
@@ -56208,7 +56260,7 @@ var XW = (e) => {
}
var u = r[c] ?? 1, d = new qW.default(u).mul(o);
return t ? d : new qW.default(Math.ceil(d.toNumber()));
-}, lCe = (e, t, n) => {
+}, uCe = (e, t, n) => {
var r = new qW.default(1), i = new qW.default(e);
if (!i.isint() && n) {
var a = Math.abs(e);
@@ -56237,7 +56289,7 @@ var XW = (e) => {
var l = c === Infinity ? [s, ...Array(r - 1).fill(Infinity)] : [...Array(r - 1).fill(-Infinity), c];
return t > n ? l.reverse() : l;
}
- if (s === c) return lCe(s, r, i);
+ if (s === c) return uCe(s, r, i);
var { step: u, tickMin: d, tickMax: f } = $W(s, c, o, i, 0, a === "snap125" ? QW : ZW), p = YW(d, f.add(new qW.default(.1).mul(u)), u);
return t > n ? p.reverse() : p;
}, tG = function(e, t) {
@@ -56246,7 +56298,7 @@ var XW = (e) => {
if (o === s) return [o];
var c = a === "snap125" ? QW : ZW, l = Math.max(t, 2), u = c(new qW.default(s).sub(o).div(l - 1), i, 0), d = [...YW(new qW.default(o), new qW.default(s), u), s];
return i === !1 && (d = d.map((e) => Math.round(e))), n > r ? d.reverse() : d;
-}, nG = (e) => e.rootProps.maxBarSize, rG = (e) => e.rootProps.barGap, iG = (e) => e.rootProps.barCategoryGap, aG = (e) => e.rootProps.barSize, oG = (e) => e.rootProps.stackOffset, sG = (e) => e.rootProps.reverseStackOrder, cG = (e) => e.options.chartName, lG = (e) => e.rootProps.syncId, uG = (e) => e.rootProps.syncMethod, dG = (e) => e.options.eventEmitter, uCe = (e) => e.rootProps.baseValue, fG = {
+}, nG = (e) => e.rootProps.maxBarSize, rG = (e) => e.rootProps.barGap, iG = (e) => e.rootProps.barCategoryGap, aG = (e) => e.rootProps.barSize, oG = (e) => e.rootProps.stackOffset, sG = (e) => e.rootProps.reverseStackOrder, cG = (e) => e.options.chartName, lG = (e) => e.rootProps.syncId, uG = (e) => e.rootProps.syncMethod, dG = (e) => e.options.eventEmitter, dCe = (e) => e.rootProps.baseValue, fG = {
grid: -100,
barBackground: -50,
area: 100,
@@ -56308,7 +56360,7 @@ var XW = (e) => {
//#region node_modules/recharts/es6/util/getAxisTypeBasedOnLayout.js
function gG(e, t, n) {
if (n !== "auto") return n;
- if (e != null) return eV(e, t) ? "category" : "number";
+ if (e != null) return tV(e, t) ? "category" : "number";
}
//#endregion
//#region node_modules/recharts/es6/state/selectors/polarAxisSelectors.js
@@ -56326,26 +56378,26 @@ function vG(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? _G(Object(n), !0).forEach(function(t) {
- dCe(e, t, n[t]);
+ fCe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : _G(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function dCe(e, t, n) {
- return (t = fCe(t)) in e ? Object.defineProperty(e, t, {
+function fCe(e, t, n) {
+ return (t = pCe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function fCe(e) {
- var t = pCe(e, "string");
+function pCe(e) {
+ var t = mCe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function pCe(e, t) {
+function mCe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -56391,45 +56443,45 @@ var yG = {
niceTicks: "auto"
}, xG = $([(e, t) => {
if (t != null) return e.polarAxis.angleAxis[t];
-}, wH], (e, t) => {
+}, TH], (e, t) => {
if (e != null) return e;
var n = gG(t, "angleAxis", yG.type) ?? "category";
return vG(vG({}, yG), {}, { type: n });
-}), SG = $([(e, t) => e.polarAxis.radiusAxis[t], wH], (e, t) => {
+}), SG = $([(e, t) => e.polarAxis.radiusAxis[t], TH], (e, t) => {
if (e != null) return e;
var n = gG(t, "radiusAxis", bG.type) ?? "category";
return vG(vG({}, bG), {}, { type: n });
}), CG = (e) => e.polarOptions, wG = $([
- bV,
xV,
- LV
-], WSe), TG = $([CG, wG], (e, t) => {
- if (e != null) return jL(e.innerRadius, t, 0);
+ SV,
+ RV
+], GSe), TG = $([CG, wG], (e, t) => {
+ if (e != null) return ML(e.innerRadius, t, 0);
}), EG = $([CG, wG], (e, t) => {
- if (e != null) return jL(e.outerRadius, t, t * .8);
+ if (e != null) return ML(e.outerRadius, t, t * .8);
}), DG = $([CG], (e) => {
if (e == null) return [0, 0];
var { startAngle: t, endAngle: n } = e;
return [t, n];
-}), mCe = $([xG, DG], hG), OG = $([
+}), hCe = $([xG, DG], hG), OG = $([
wG,
TG,
EG
], (e, t, n) => {
if (e != null && t != null && n != null) return [t, n];
-}), hCe = $([SG, OG], hG), kG = $([
- xH,
+}), gCe = $([SG, OG], hG), kG = $([
+ SH,
CG,
TG,
EG,
- bV,
- xV
+ xV,
+ SV
], (e, t, n, r, i, a) => {
if (!(e !== "centric" && e !== "radial" || t == null || n == null || r == null)) {
var { cx: o, cy: s, startAngle: c, endAngle: l } = t;
return {
- cx: jL(o, i, i / 2),
- cy: jL(s, a, a / 2),
+ cx: ML(o, i, i / 2),
+ cy: ML(s, a, a / 2),
innerRadius: n,
outerRadius: r,
startAngle: c,
@@ -56452,7 +56504,7 @@ function NG(e, t, n) {
if (t != null && t.length !== 0) {
var n = MG(e);
t.forEach((t, r) => {
- var s = a == null || i ? r : String(QB(t, a, null)), c = QB(t, e.dataKey, 0), l = o.has(s) ? o.get(s) : {};
+ var s = a == null || i ? r : String($B(t, a, null)), c = $B(t, e.dataKey, 0), l = o.has(s) ? o.get(s) : {};
Object.assign(l, { [n]: c }), o.set(s, l);
});
}
@@ -56471,7 +56523,7 @@ var FG = (e, t) => e === t ? !0 : e == null || t == null ? !1 : e[0] === t[0] &&
function IG(e, t) {
return Array.isArray(e) && Array.isArray(t) && e.length === 0 && t.length === 0 ? !0 : e === t;
}
-function gCe(e, t) {
+function _Ce(e, t) {
if (e.length === t.length) {
for (var n = 0; n < e.length; n++) if (e[n] !== t[n]) return !1;
return !0;
@@ -56481,7 +56533,7 @@ function gCe(e, t) {
//#endregion
//#region node_modules/recharts/es6/state/selectors/selectTooltipAxisType.js
var LG = (e) => {
- var t = xH(e);
+ var t = SH(e);
return t === "horizontal" ? "xAxis" : t === "vertical" ? "yAxis" : t === "centric" ? "angleAxis" : "radiusAxis";
}, RG = (e) => e.tooltip.settings.axisId;
//#endregion
@@ -56533,7 +56585,7 @@ var BG = (e, t) => {
if (!WW(t)) {
for (var n, r, i = 0; i < t.length; i++) {
var a = t[i];
- GB(a) && ((n === void 0 || a < n) && (n = a), (r === void 0 || a > r) && (r = a));
+ KB(a) && ((n === void 0 || a < n) && (n = a), (r === void 0 || a > r) && (r = a));
}
return n !== void 0 && r !== void 0 ? [n, r] : void 0;
}
@@ -56550,7 +56602,7 @@ function VG(e, t) {
//#region node_modules/d3-array/src/bisector.js
function HG(e) {
let t = e, n = e;
- e.length === 1 && (t = (t, n) => e(t) - n, n = _Ce(e));
+ e.length === 1 && (t = (t, n) => e(t) - n, n = vCe(e));
function r(e, t, r, i) {
for (r ??= 0, i ??= e.length; r < i;) {
let a = r + i >>> 1;
@@ -56576,7 +56628,7 @@ function HG(e) {
right: i
};
}
-function _Ce(e) {
+function vCe(e) {
return (t, n) => VG(e(t), n);
}
//#endregion
@@ -56584,7 +56636,7 @@ function _Ce(e) {
function UG(e) {
return e === null ? NaN : +e;
}
-function* vCe(e, t) {
+function* yCe(e, t) {
if (t === void 0) for (let t of e) t != null && (t = +t) >= t && (yield t);
else {
let n = -1;
@@ -56598,7 +56650,7 @@ WG.left, HG(UG).center;
//#endregion
//#region node_modules/internmap/src/index.js
var KG = class extends Map {
- constructor(e, t = xCe) {
+ constructor(e, t = SCe) {
if (super(), Object.defineProperties(this, {
_intern: { value: /* @__PURE__ */ new Map() },
_key: { value: t }
@@ -56611,25 +56663,25 @@ var KG = class extends Map {
return super.has(qG(this, e));
}
set(e, t) {
- return super.set(yCe(this, e), t);
+ return super.set(bCe(this, e), t);
}
delete(e) {
- return super.delete(bCe(this, e));
+ return super.delete(xCe(this, e));
}
};
function qG({ _intern: e, _key: t }, n) {
let r = t(n);
return e.has(r) ? e.get(r) : n;
}
-function yCe({ _intern: e, _key: t }, n) {
+function bCe({ _intern: e, _key: t }, n) {
let r = t(n);
return e.has(r) ? e.get(r) : (e.set(r, n), n);
}
-function bCe({ _intern: e, _key: t }, n) {
+function xCe({ _intern: e, _key: t }, n) {
let r = t(n);
return e.has(r) && (n = e.get(n), e.delete(r)), n;
}
-function xCe(e) {
+function SCe(e) {
return typeof e == "object" && e ? e.valueOf() : e;
}
//#endregion
@@ -56702,15 +56754,15 @@ function rK(e, t, n) {
}
//#endregion
//#region node_modules/d3-array/src/quantile.js
-function SCe(e, t, n) {
- if (e = Float64Array.from(vCe(e, n)), r = e.length) {
+function CCe(e, t, n) {
+ if (e = Float64Array.from(yCe(e, n)), r = e.length) {
if ((t = +t) <= 0 || r < 2) return tK(e);
if (t >= 1) return eK(e);
var r, i = (r - 1) * t, a = Math.floor(i), o = eK(nK(e, a).subarray(0, a + 1));
return o + (tK(e.subarray(a + 1)) - o) * (i - a);
}
}
-function CCe(e, t, n = UG) {
+function wCe(e, t, n = UG) {
if (r = e.length) {
if ((t = +t) <= 0 || r < 2) return +n(e[0], 0, e);
if (t >= 1) return +n(e[r - 1], r - 1, e);
@@ -56720,7 +56772,7 @@ function CCe(e, t, n = UG) {
}
//#endregion
//#region node_modules/d3-array/src/range.js
-function wCe(e, t, n) {
+function TCe(e, t, n) {
e = +e, t = +t, n = (i = arguments.length) < 2 ? (t = e, e = 0, 1) : i < 3 ? 1 : +n;
for (var r = -1, i = Math.max(0, Math.ceil((t - e) / n)) | 0, a = Array(i); ++r < i;) a[r] = e + r * n;
return a;
@@ -56792,7 +56844,7 @@ function lK() {
function d() {
var e = t().length, d = i < r, f = d ? i : r, p = d ? r : i;
a = (p - f) / Math.max(1, e - c + l * 2), s && (a = Math.floor(a)), f += (p - f - a * (e - c)) * u, o = a * (1 - c), s && (f = Math.round(f), o = Math.round(o));
- var m = wCe(e).map(function(e) {
+ var m = TCe(e).map(function(e) {
return f + a * e;
});
return n(d ? m.reverse() : m);
@@ -56827,7 +56879,7 @@ function uK(e) {
return uK(t());
}, e;
}
-function TCe() {
+function ECe() {
return uK(lK.apply(null, arguments).paddingInner(1));
}
//#endregion
@@ -56843,7 +56895,7 @@ function fK(e, t) {
//#endregion
//#region node_modules/d3-color/src/color.js
function pK() {}
-var mK = .7, hK = 1 / mK, gK = "\\s*([+-]?\\d+)\\s*", _K = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*", vK = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*", ECe = /^#([0-9a-f]{3,8})$/, DCe = RegExp(`^rgb\\(${gK},${gK},${gK}\\)$`), OCe = RegExp(`^rgb\\(${vK},${vK},${vK}\\)$`), kCe = RegExp(`^rgba\\(${gK},${gK},${gK},${_K}\\)$`), ACe = RegExp(`^rgba\\(${vK},${vK},${vK},${_K}\\)$`), jCe = RegExp(`^hsl\\(${_K},${vK},${vK}\\)$`), MCe = RegExp(`^hsla\\(${_K},${vK},${vK},${_K}\\)$`), yK = {
+var mK = .7, hK = 1 / mK, gK = "\\s*([+-]?\\d+)\\s*", _K = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*", vK = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*", DCe = /^#([0-9a-f]{3,8})$/, OCe = RegExp(`^rgb\\(${gK},${gK},${gK}\\)$`), kCe = RegExp(`^rgb\\(${vK},${vK},${vK}\\)$`), ACe = RegExp(`^rgba\\(${gK},${gK},${gK},${_K}\\)$`), jCe = RegExp(`^rgba\\(${vK},${vK},${vK},${_K}\\)$`), MCe = RegExp(`^hsl\\(${_K},${vK},${vK}\\)$`), NCe = RegExp(`^hsla\\(${_K},${vK},${vK},${_K}\\)$`), yK = {
aliceblue: 15792383,
antiquewhite: 16444375,
aqua: 65535,
@@ -57002,18 +57054,18 @@ dK(pK, SK, {
},
hex: bK,
formatHex: bK,
- formatHex8: NCe,
- formatHsl: PCe,
+ formatHex8: PCe,
+ formatHsl: FCe,
formatRgb: xK,
toString: xK
});
function bK() {
return this.rgb().formatHex();
}
-function NCe() {
+function PCe() {
return this.rgb().formatHex8();
}
-function PCe() {
+function FCe() {
return NK(this).formatHsl();
}
function xK() {
@@ -57021,7 +57073,7 @@ function xK() {
}
function SK(e) {
var t, n;
- return e = (e + "").trim().toLowerCase(), (t = ECe.exec(e)) ? (n = t[1].length, t = parseInt(t[1], 16), n === 6 ? CK(t) : n === 3 ? new EK(t >> 8 & 15 | t >> 4 & 240, t >> 4 & 15 | t & 240, (t & 15) << 4 | t & 15, 1) : n === 8 ? wK(t >> 24 & 255, t >> 16 & 255, t >> 8 & 255, (t & 255) / 255) : n === 4 ? wK(t >> 12 & 15 | t >> 8 & 240, t >> 8 & 15 | t >> 4 & 240, t >> 4 & 15 | t & 240, ((t & 15) << 4 | t & 15) / 255) : null) : (t = DCe.exec(e)) ? new EK(t[1], t[2], t[3], 1) : (t = OCe.exec(e)) ? new EK(t[1] * 255 / 100, t[2] * 255 / 100, t[3] * 255 / 100, 1) : (t = kCe.exec(e)) ? wK(t[1], t[2], t[3], t[4]) : (t = ACe.exec(e)) ? wK(t[1] * 255 / 100, t[2] * 255 / 100, t[3] * 255 / 100, t[4]) : (t = jCe.exec(e)) ? MK(t[1], t[2] / 100, t[3] / 100, 1) : (t = MCe.exec(e)) ? MK(t[1], t[2] / 100, t[3] / 100, t[4]) : yK.hasOwnProperty(e) ? CK(yK[e]) : e === "transparent" ? new EK(NaN, NaN, NaN, 0) : null;
+ return e = (e + "").trim().toLowerCase(), (t = DCe.exec(e)) ? (n = t[1].length, t = parseInt(t[1], 16), n === 6 ? CK(t) : n === 3 ? new EK(t >> 8 & 15 | t >> 4 & 240, t >> 4 & 15 | t & 240, (t & 15) << 4 | t & 15, 1) : n === 8 ? wK(t >> 24 & 255, t >> 16 & 255, t >> 8 & 255, (t & 255) / 255) : n === 4 ? wK(t >> 12 & 15 | t >> 8 & 240, t >> 8 & 15 | t >> 4 & 240, t >> 4 & 15 | t & 240, ((t & 15) << 4 | t & 15) / 255) : null) : (t = OCe.exec(e)) ? new EK(t[1], t[2], t[3], 1) : (t = kCe.exec(e)) ? new EK(t[1] * 255 / 100, t[2] * 255 / 100, t[3] * 255 / 100, 1) : (t = ACe.exec(e)) ? wK(t[1], t[2], t[3], t[4]) : (t = jCe.exec(e)) ? wK(t[1] * 255 / 100, t[2] * 255 / 100, t[3] * 255 / 100, t[4]) : (t = MCe.exec(e)) ? MK(t[1], t[2] / 100, t[3] / 100, 1) : (t = NCe.exec(e)) ? MK(t[1], t[2] / 100, t[3] / 100, t[4]) : yK.hasOwnProperty(e) ? CK(yK[e]) : e === "transparent" ? new EK(NaN, NaN, NaN, 0) : null;
}
function CK(e) {
return new EK(e >> 16 & 255, e >> 8 & 255, e & 255, 1);
@@ -57029,11 +57081,11 @@ function CK(e) {
function wK(e, t, n, r) {
return r <= 0 && (e = t = n = NaN), new EK(e, t, n, r);
}
-function FCe(e) {
+function ICe(e) {
return e instanceof pK || (e = SK(e)), e ? (e = e.rgb(), new EK(e.r, e.g, e.b, e.opacity)) : new EK();
}
function TK(e, t, n, r) {
- return arguments.length === 1 ? FCe(e) : new EK(e, t, n, r ?? 1);
+ return arguments.length === 1 ? ICe(e) : new EK(e, t, n, r ?? 1);
}
function EK(e, t, n, r) {
this.r = +e, this.g = +t, this.b = +n, this.opacity = +r;
@@ -57056,14 +57108,14 @@ dK(EK, TK, fK(pK, {
},
hex: DK,
formatHex: DK,
- formatHex8: ICe,
+ formatHex8: LCe,
formatRgb: OK,
toString: OK
}));
function DK() {
return `#${jK(this.r)}${jK(this.g)}${jK(this.b)}`;
}
-function ICe() {
+function LCe() {
return `#${jK(this.r)}${jK(this.g)}${jK(this.b)}${jK((isNaN(this.opacity) ? 1 : this.opacity) * 255)}`;
}
function OK() {
@@ -57090,13 +57142,13 @@ function NK(e) {
var t = e.r / 255, n = e.g / 255, r = e.b / 255, i = Math.min(t, n, r), a = Math.max(t, n, r), o = NaN, s = a - i, c = (a + i) / 2;
return s ? (o = t === a ? (n - r) / s + (n < r) * 6 : n === a ? (r - t) / s + 2 : (t - n) / s + 4, s /= c < .5 ? a + i : 2 - a - i, o *= 60) : s = c > 0 && c < 1 ? 0 : o, new PK(o, s, c, e.opacity);
}
-function LCe(e, t, n, r) {
+function RCe(e, t, n, r) {
return arguments.length === 1 ? NK(e) : new PK(e, t, n, r ?? 1);
}
function PK(e, t, n, r) {
this.h = +e, this.s = +t, this.l = +n, this.opacity = +r;
}
-dK(PK, LCe, fK(pK, {
+dK(PK, RCe, fK(pK, {
brighter(e) {
return e = e == null ? hK : hK ** +e, new PK(this.h, this.s, this.l * e, this.opacity);
},
@@ -57132,29 +57184,29 @@ function LK(e, t, n) {
var RK = (e) => () => e;
//#endregion
//#region node_modules/d3-interpolate/src/color.js
-function RCe(e, t) {
+function zCe(e, t) {
return function(n) {
return e + n * t;
};
}
-function zCe(e, t, n) {
+function BCe(e, t, n) {
return e **= +n, t = t ** +n - e, n = 1 / n, function(r) {
return (e + r * t) ** +n;
};
}
-function BCe(e) {
+function VCe(e) {
return (e = +e) == 1 ? zK : function(t, n) {
- return n - t ? zCe(t, n, e) : RK(isNaN(t) ? n : t);
+ return n - t ? BCe(t, n, e) : RK(isNaN(t) ? n : t);
};
}
function zK(e, t) {
var n = t - e;
- return n ? RCe(e, n) : RK(isNaN(e) ? t : e);
+ return n ? zCe(e, n) : RK(isNaN(e) ? t : e);
}
//#endregion
//#region node_modules/d3-interpolate/src/rgb.js
var BK = (function e(t) {
- var n = BCe(t);
+ var n = VCe(t);
function r(e, t) {
var r = n((e = TK(e)).r, (t = TK(t)).r), i = n(e.g, t.g), a = n(e.b, t.b), o = zK(e.opacity, t.opacity);
return function(t) {
@@ -57165,7 +57217,7 @@ var BK = (function e(t) {
})(1);
//#endregion
//#region node_modules/d3-interpolate/src/numberArray.js
-function VCe(e, t) {
+function HCe(e, t) {
t ||= [];
var n = e ? Math.min(t.length, e.length) : 0, r = t.slice(), i;
return function(a) {
@@ -57173,12 +57225,12 @@ function VCe(e, t) {
return r;
};
}
-function HCe(e) {
+function UCe(e) {
return ArrayBuffer.isView(e) && !(e instanceof DataView);
}
//#endregion
//#region node_modules/d3-interpolate/src/array.js
-function UCe(e, t) {
+function WCe(e, t) {
var n = t ? t.length : 0, r = e ? Math.min(n, e.length) : 0, i = Array(r), a = Array(n), o;
for (o = 0; o < r; ++o) i[o] = WK(e[o], t[o]);
for (; o < n; ++o) a[o] = t[o];
@@ -57189,7 +57241,7 @@ function UCe(e, t) {
}
//#endregion
//#region node_modules/d3-interpolate/src/date.js
-function WCe(e, t) {
+function GCe(e, t) {
var n = /* @__PURE__ */ new Date();
return e = +e, t = +t, function(r) {
return n.setTime(e * (1 - r) + t * r), n;
@@ -57204,7 +57256,7 @@ function VK(e, t) {
}
//#endregion
//#region node_modules/d3-interpolate/src/object.js
-function GCe(e, t) {
+function KCe(e, t) {
var n = {}, r = {}, i;
for (i in (typeof e != "object" || !e) && (e = {}), (typeof t != "object" || !t) && (t = {}), t) i in e ? n[i] = WK(e[i], t[i]) : r[i] = t[i];
return function(e) {
@@ -57215,23 +57267,23 @@ function GCe(e, t) {
//#endregion
//#region node_modules/d3-interpolate/src/string.js
var HK = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g, UK = new RegExp(HK.source, "g");
-function KCe(e) {
+function qCe(e) {
return function() {
return e;
};
}
-function qCe(e) {
+function JCe(e) {
return function(t) {
return e(t) + "";
};
}
-function JCe(e, t) {
+function YCe(e, t) {
var n = HK.lastIndex = UK.lastIndex = 0, r, i, a, o = -1, s = [], c = [];
for (e += "", t += ""; (r = HK.exec(e)) && (i = UK.exec(t));) (a = i.index) > n && (a = t.slice(n, a), s[o] ? s[o] += a : s[++o] = a), (r = r[0]) === (i = i[0]) ? s[o] ? s[o] += i : s[++o] = i : (s[++o] = null, c.push({
i: o,
x: VK(r, i)
})), n = UK.lastIndex;
- return n < t.length && (a = t.slice(n), s[o] ? s[o] += a : s[++o] = a), s.length < 2 ? c[0] ? qCe(c[0].x) : KCe(t) : (t = c.length, function(e) {
+ return n < t.length && (a = t.slice(n), s[o] ? s[o] += a : s[++o] = a), s.length < 2 ? c[0] ? JCe(c[0].x) : qCe(t) : (t = c.length, function(e) {
for (var n = 0, r; n < t; ++n) s[(r = c[n]).i] = r.x(e);
return s.join("");
});
@@ -57240,7 +57292,7 @@ function JCe(e, t) {
//#region node_modules/d3-interpolate/src/value.js
function WK(e, t) {
var n = typeof t, r;
- return t == null || n === "boolean" ? RK(t) : (n === "number" ? VK : n === "string" ? (r = SK(t)) ? (t = r, BK) : JCe : t instanceof SK ? BK : t instanceof Date ? WCe : HCe(t) ? VCe : Array.isArray(t) ? UCe : typeof t.valueOf != "function" && typeof t.toString != "function" || isNaN(t) ? GCe : VK)(e, t);
+ return t == null || n === "boolean" ? RK(t) : (n === "number" ? VK : n === "string" ? (r = SK(t)) ? (t = r, BK) : YCe : t instanceof SK ? BK : t instanceof Date ? GCe : UCe(t) ? HCe : Array.isArray(t) ? WCe : typeof t.valueOf != "function" && typeof t.toString != "function" || isNaN(t) ? KCe : VK)(e, t);
}
//#endregion
//#region node_modules/d3-interpolate/src/round.js
@@ -57251,7 +57303,7 @@ function GK(e, t) {
}
//#endregion
//#region node_modules/d3-interpolate/src/piecewise.js
-function YCe(e, t) {
+function XCe(e, t) {
t === void 0 && (t = e, e = WK);
for (var n = 0, r = t.length - 1, i = t[0], a = Array(r < 0 ? 0 : r); n < r;) a[n] = e(i, i = t[++n]);
return function(e) {
@@ -57261,7 +57313,7 @@ function YCe(e, t) {
}
//#endregion
//#region node_modules/d3-scale/src/constant.js
-function XCe(e) {
+function ZCe(e) {
return function() {
return e;
};
@@ -57280,21 +57332,21 @@ function JK(e) {
function YK(e, t) {
return (t -= e = +e) ? function(n) {
return (n - e) / t;
- } : XCe(isNaN(t) ? NaN : .5);
+ } : ZCe(isNaN(t) ? NaN : .5);
}
-function ZCe(e, t) {
+function QCe(e, t) {
var n;
return e > t && (n = e, e = t, t = n), function(n) {
return Math.max(e, Math.min(t, n));
};
}
-function QCe(e, t, n) {
+function $Ce(e, t, n) {
var r = e[0], i = e[1], a = t[0], o = t[1];
return i < r ? (r = YK(i, r), a = n(o, a)) : (r = YK(r, i), a = n(a, o)), function(e) {
return a(r(e));
};
}
-function $Ce(e, t, n) {
+function ewe(e, t, n) {
var r = Math.min(e.length, t.length) - 1, i = Array(r), a = Array(r), o = -1;
for (e[r] < e[0] && (e = e.slice().reverse(), t = t.slice().reverse()); ++o < r;) i[o] = YK(e[o], e[o + 1]), a[o] = n(t[o], t[o + 1]);
return function(t) {
@@ -57309,7 +57361,7 @@ function ZK() {
var e = qK, t = qK, n = WK, r, i, a, o = JK, s, c, l;
function u() {
var n = Math.min(e.length, t.length);
- return o !== JK && (o = ZCe(e[0], e[n - 1])), s = n > 2 ? $Ce : QCe, c = l = null, d;
+ return o !== JK && (o = QCe(e[0], e[n - 1])), s = n > 2 ? ewe : $Ce, c = l = null, d;
}
function d(i) {
return i == null || isNaN(i = +i) ? a : (c ||= s(e.map(r), t, n))(r(o(i)));
@@ -57337,7 +57389,7 @@ function QK() {
}
//#endregion
//#region node_modules/d3-format/src/formatDecimal.js
-function ewe(e) {
+function twe(e) {
return Math.abs(e = Math.round(e)) >= 1e21 ? e.toLocaleString("en").replace(/,/g, "") : e.toString(10);
}
function $K(e, t) {
@@ -57352,7 +57404,7 @@ function eq(e) {
}
//#endregion
//#region node_modules/d3-format/src/formatGroup.js
-function twe(e, t) {
+function nwe(e, t) {
return function(n, r) {
for (var i = n.length, a = [], o = 0, s = e[0], c = 0; i > 0 && s > 0 && (c + s + 1 > r && (s = Math.max(1, r - c)), a.push(n.substring(i -= s, i + s)), !((c += s + 1) > r));) s = e[o = (o + 1) % e.length];
return a.reverse().join(t);
@@ -57360,7 +57412,7 @@ function twe(e, t) {
}
//#endregion
//#region node_modules/d3-format/src/formatNumerals.js
-function nwe(e) {
+function rwe(e) {
return function(t) {
return t.replace(/[0-9]/g, function(t) {
return e[+t];
@@ -57369,9 +57421,9 @@ function nwe(e) {
}
//#endregion
//#region node_modules/d3-format/src/formatSpecifier.js
-var rwe = /^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;
+var iwe = /^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;
function tq(e) {
- if (!(t = rwe.exec(e))) throw Error("invalid format: " + e);
+ if (!(t = iwe.exec(e))) throw Error("invalid format: " + e);
var t;
return new nq({
fill: t[1],
@@ -57395,7 +57447,7 @@ nq.prototype.toString = function() {
};
//#endregion
//#region node_modules/d3-format/src/formatTrim.js
-function iwe(e) {
+function awe(e) {
out: for (var t = e.length, n = 1, r = -1, i; n < t; ++n) switch (e[n]) {
case ".":
r = i = n;
@@ -57412,7 +57464,7 @@ function iwe(e) {
//#endregion
//#region node_modules/d3-format/src/formatPrefixAuto.js
var rq;
-function awe(e, t) {
+function owe(e, t) {
var n = $K(e, t);
if (!n) return rq = void 0, e.toPrecision(t);
var r = n[0], i = n[1], a = i - (rq = Math.max(-8, Math.min(8, Math.floor(i / 3))) * 3) + 1, o = r.length;
@@ -57432,14 +57484,14 @@ var aq = {
"%": (e, t) => (e * 100).toFixed(t),
b: (e) => Math.round(e).toString(2),
c: (e) => e + "",
- d: ewe,
+ d: twe,
e: (e, t) => e.toExponential(t),
f: (e, t) => e.toFixed(t),
g: (e, t) => e.toPrecision(t),
o: (e) => Math.round(e).toString(8),
p: (e, t) => iq(e * 100, t),
r: iq,
- s: awe,
+ s: owe,
X: (e) => Math.round(e).toString(16).toUpperCase(),
x: (e) => Math.round(e).toString(16)
};
@@ -57469,8 +57521,8 @@ var sq = Array.prototype.map, cq = [
"Z",
"Y"
];
-function owe(e) {
- var t = e.grouping === void 0 || e.thousands === void 0 ? oq : twe(sq.call(e.grouping, Number), e.thousands + ""), n = e.currency === void 0 ? "" : e.currency[0] + "", r = e.currency === void 0 ? "" : e.currency[1] + "", i = e.decimal === void 0 ? "." : e.decimal + "", a = e.numerals === void 0 ? oq : nwe(sq.call(e.numerals, String)), o = e.percent === void 0 ? "%" : e.percent + "", s = e.minus === void 0 ? "−" : e.minus + "", c = e.nan === void 0 ? "NaN" : e.nan + "";
+function swe(e) {
+ var t = e.grouping === void 0 || e.thousands === void 0 ? oq : nwe(sq.call(e.grouping, Number), e.thousands + ""), n = e.currency === void 0 ? "" : e.currency[0] + "", r = e.currency === void 0 ? "" : e.currency[1] + "", i = e.decimal === void 0 ? "." : e.decimal + "", a = e.numerals === void 0 ? oq : rwe(sq.call(e.numerals, String)), o = e.percent === void 0 ? "%" : e.percent + "", s = e.minus === void 0 ? "−" : e.minus + "", c = e.nan === void 0 ? "NaN" : e.nan + "";
function l(e, l) {
e = tq(e);
var u = e.fill, d = e.align, f = e.sign, p = e.symbol, m = e.zero, h = e.width, g = e.comma, _ = e.precision, v = e.trim, y = e.type;
@@ -57483,7 +57535,7 @@ function owe(e) {
else {
e = +e;
var w = e < 0 || 1 / e < 0;
- if (e = isNaN(e) ? c : S(Math.abs(e), _), v && (e = iwe(e)), w && +e == 0 && f !== "+" && (w = !1), n = (w ? f === "(" ? f : s : f === "-" || f === "(" ? "" : f) + n, r = (y === "s" && !isNaN(e) && rq !== void 0 ? cq[8 + rq / 3] : "") + r + (w && f === "(" ? ")" : ""), C) {
+ if (e = isNaN(e) ? c : S(Math.abs(e), _), v && (e = awe(e)), w && +e == 0 && f !== "+" && (w = !1), n = (w ? f === "(" ? f : s : f === "-" || f === "(" ? "" : f) + n, r = (y === "s" && !isNaN(e) && rq !== void 0 ? cq[8 + rq / 3] : "") + r + (w && f === "(" ? ")" : ""), C) {
for (o = -1, l = e.length; ++o < l;) if (p = e.charCodeAt(o), 48 > p || p > 57) {
r = (p === 46 ? i + e.slice(o + 1) : e.slice(o)) + r, e = e.slice(0, o);
break;
@@ -57524,27 +57576,27 @@ function owe(e) {
//#endregion
//#region node_modules/d3-format/src/defaultLocale.js
var lq, uq, dq;
-swe({
+cwe({
thousands: ",",
grouping: [3],
currency: ["$", ""]
});
-function swe(e) {
- return lq = owe(e), uq = lq.format, dq = lq.formatPrefix, lq;
+function cwe(e) {
+ return lq = swe(e), uq = lq.format, dq = lq.formatPrefix, lq;
}
//#endregion
//#region node_modules/d3-format/src/precisionFixed.js
-function cwe(e) {
+function lwe(e) {
return Math.max(0, -eq(Math.abs(e)));
}
//#endregion
//#region node_modules/d3-format/src/precisionPrefix.js
-function lwe(e, t) {
+function uwe(e, t) {
return Math.max(0, Math.max(-8, Math.min(8, Math.floor(eq(t) / 3))) * 3 - eq(Math.abs(e)));
}
//#endregion
//#region node_modules/d3-format/src/precisionRound.js
-function uwe(e, t) {
+function dwe(e, t) {
return e = Math.abs(e), t = Math.abs(t) - e, Math.max(0, eq(t) - eq(e)) + 1;
}
//#endregion
@@ -57554,16 +57606,16 @@ function fq(e, t, n, r) {
switch (r = tq(r ?? ",f"), r.type) {
case "s":
var o = Math.max(Math.abs(e), Math.abs(t));
- return r.precision == null && !isNaN(a = lwe(i, o)) && (r.precision = a), dq(r, o);
+ return r.precision == null && !isNaN(a = uwe(i, o)) && (r.precision = a), dq(r, o);
case "":
case "e":
case "g":
case "p":
case "r":
- r.precision == null && !isNaN(a = uwe(i, Math.max(Math.abs(e), Math.abs(t)))) && (r.precision = a - (r.type === "e"));
+ r.precision == null && !isNaN(a = dwe(i, Math.max(Math.abs(e), Math.abs(t)))) && (r.precision = a - (r.type === "e"));
break;
case "f":
- case "%": r.precision == null && !isNaN(a = cwe(i)) && (r.precision = a - (r.type === "%") * 2);
+ case "%": r.precision == null && !isNaN(a = lwe(i)) && (r.precision = a - (r.type === "%") * 2);
}
return uq(r);
}
@@ -57626,19 +57678,19 @@ function _q(e) {
function vq(e) {
return Math.exp(e);
}
-function dwe(e) {
- return -Math.log(-e);
-}
function fwe(e) {
- return -Math.exp(-e);
+ return -Math.log(-e);
}
function pwe(e) {
- return isFinite(e) ? +("1e" + e) : e < 0 ? 0 : e;
+ return -Math.exp(-e);
}
function mwe(e) {
- return e === 10 ? pwe : e === Math.E ? Math.exp : (t) => e ** +t;
+ return isFinite(e) ? +("1e" + e) : e < 0 ? 0 : e;
}
function hwe(e) {
+ return e === 10 ? mwe : e === Math.E ? Math.exp : (t) => e ** +t;
+}
+function gwe(e) {
return e === Math.E ? Math.log : e === 10 && Math.log10 || e === 2 && Math.log2 || (e = Math.log(e), (t) => Math.log(t) / e);
}
function yq(e) {
@@ -57647,7 +57699,7 @@ function yq(e) {
function bq(e) {
let t = e(_q, vq), n = t.domain, r = 10, i, a;
function o() {
- return i = hwe(r), a = mwe(r), n()[0] < 0 ? (i = yq(i), a = yq(a), e(dwe, fwe)) : e(_q, vq), t;
+ return i = gwe(r), a = hwe(r), n()[0] < 0 ? (i = yq(i), a = yq(a), e(fwe, pwe)) : e(_q, vq), t;
}
return t.base = function(e) {
return arguments.length ? (r = +e, o()) : r;
@@ -57717,16 +57769,16 @@ function Eq(e) {
return t < 0 ? -((-t) ** +e) : t ** +e;
};
}
-function gwe(e) {
+function _we(e) {
return e < 0 ? -Math.sqrt(-e) : Math.sqrt(e);
}
-function _we(e) {
+function vwe(e) {
return e < 0 ? -e * e : e * e;
}
function Dq(e) {
var t = e(JK, JK), n = 1;
function r() {
- return n === 1 ? e(JK, JK) : n === .5 ? e(gwe, _we) : e(Eq(n), Eq(1 / n));
+ return n === 1 ? e(JK, JK) : n === .5 ? e(_we, vwe) : e(Eq(n), Eq(1 / n));
}
return t.exponent = function(e) {
return arguments.length ? (n = +e, r()) : n;
@@ -57738,7 +57790,7 @@ function Oq() {
return XK(e, Oq()).exponent(e.exponent());
}, aK.apply(e, arguments), e;
}
-function vwe() {
+function ywe() {
return Oq.apply(null, arguments).exponent(.5);
}
//#endregion
@@ -57746,13 +57798,13 @@ function vwe() {
function kq(e) {
return Math.sign(e) * e * e;
}
-function ywe(e) {
+function bwe(e) {
return Math.sign(e) * Math.sqrt(Math.abs(e));
}
function Aq() {
var e = QK(), t = [0, 1], n = !1, r;
function i(t) {
- var i = ywe(e(t));
+ var i = bwe(e(t));
return isNaN(i) ? r : n ? Math.round(i) : i;
}
return i.invert = function(t) {
@@ -57779,7 +57831,7 @@ function jq() {
var e = [], t = [], n = [], r;
function i() {
var r = 0, i = Math.max(1, t.length);
- for (n = Array(i - 1); ++r < i;) n[r - 1] = CCe(e, r / i);
+ for (n = Array(i - 1); ++r < i;) n[r - 1] = wCe(e, r / i);
return a;
}
function a(e) {
@@ -57948,8 +58000,8 @@ function $q(e) {
e.setDate(e.getDate() + t * 7);
}, (e, t) => (t - e - (t.getTimezoneOffset() - e.getTimezoneOffset()) * zq) / Hq);
}
-var eJ = $q(0), tJ = $q(1), bwe = $q(2), xwe = $q(3), nJ = $q(4), Swe = $q(5), Cwe = $q(6);
-eJ.range, tJ.range, bwe.range, xwe.range, nJ.range, Swe.range, Cwe.range;
+var eJ = $q(0), tJ = $q(1), xwe = $q(2), Swe = $q(3), nJ = $q(4), Cwe = $q(5), wwe = $q(6);
+eJ.range, tJ.range, xwe.range, Swe.range, nJ.range, Cwe.range, wwe.range;
function rJ(e) {
return Iq((t) => {
t.setUTCDate(t.getUTCDate() - (t.getUTCDay() + 7 - e) % 7), t.setUTCHours(0, 0, 0, 0);
@@ -57957,8 +58009,8 @@ function rJ(e) {
e.setUTCDate(e.getUTCDate() + t * 7);
}, (e, t) => (t - e) / Hq);
}
-var iJ = rJ(0), aJ = rJ(1), wwe = rJ(2), Twe = rJ(3), oJ = rJ(4), Ewe = rJ(5), Dwe = rJ(6);
-iJ.range, aJ.range, wwe.range, Twe.range, oJ.range, Ewe.range, Dwe.range;
+var iJ = rJ(0), aJ = rJ(1), Twe = rJ(2), Ewe = rJ(3), oJ = rJ(4), Dwe = rJ(5), Owe = rJ(6);
+iJ.range, aJ.range, Twe.range, Ewe.range, oJ.range, Dwe.range, Owe.range;
//#endregion
//#region node_modules/d3-time/src/month.js
var sJ = Iq((e) => {
@@ -58105,7 +58157,7 @@ function dJ(e, t, n, r, i, a) {
}
return [s, c];
}
-var [Owe, kwe] = dJ(uJ, cJ, iJ, Qq, Yq, qq), [Awe, jwe] = dJ(lJ, sJ, eJ, Xq, Jq, Kq);
+var [kwe, Awe] = dJ(uJ, cJ, iJ, Qq, Yq, qq), [jwe, Mwe] = dJ(lJ, sJ, eJ, Xq, Jq, Kq);
//#endregion
//#region node_modules/d3-time-format/src/locale.js
function fJ(e) {
@@ -58133,7 +58185,7 @@ function mJ(e, t, n) {
L: 0
};
}
-function Mwe(e) {
+function Nwe(e) {
var t = e.dateTime, n = e.date, r = e.time, i = e.periods, a = e.days, o = e.shortDays, s = e.months, c = e.shortMonths, l = vJ(i), u = yJ(i), d = vJ(a), f = yJ(a), p = vJ(o), m = yJ(o), h = vJ(s), g = yJ(s), _ = vJ(c), v = yJ(c), y = {
a: N,
A: P,
@@ -58142,30 +58194,30 @@ function Mwe(e) {
c: null,
d: wJ,
e: wJ,
- f: tTe,
- g: dTe,
- G: pTe,
- H: Qwe,
- I: $we,
- j: eTe,
+ f: nTe,
+ g: fTe,
+ G: mTe,
+ H: $we,
+ I: eTe,
+ j: tTe,
L: TJ,
- m: nTe,
- M: rTe,
+ m: rTe,
+ M: iTe,
p: I,
q: te,
Q: jJ,
s: MJ,
- S: iTe,
- u: aTe,
- U: oTe,
- V: sTe,
- w: cTe,
- W: lTe,
+ S: aTe,
+ u: oTe,
+ U: sTe,
+ V: cTe,
+ w: lTe,
+ W: uTe,
x: null,
X: null,
- y: uTe,
- Y: fTe,
- Z: mTe,
+ y: dTe,
+ Y: pTe,
+ Z: hTe,
"%": AJ
}, b = {
a: ne,
@@ -58175,30 +58227,30 @@ function Mwe(e) {
c: null,
d: DJ,
e: DJ,
- f: vTe,
- g: OTe,
- G: ATe,
- H: hTe,
- I: gTe,
- j: _Te,
+ f: yTe,
+ g: kTe,
+ G: jTe,
+ H: gTe,
+ I: _Te,
+ j: vTe,
L: OJ,
- m: yTe,
- M: bTe,
+ m: bTe,
+ M: xTe,
p: oe,
q: se,
Q: jJ,
s: MJ,
- S: xTe,
- u: STe,
- U: CTe,
- V: wTe,
- w: TTe,
- W: ETe,
+ S: STe,
+ u: CTe,
+ U: wTe,
+ V: TTe,
+ w: ETe,
+ W: DTe,
x: null,
X: null,
- y: DTe,
- Y: kTe,
- Z: jTe,
+ y: OTe,
+ Y: ATe,
+ Z: MTe,
"%": AJ
}, x = {
a: E,
@@ -58208,31 +58260,31 @@ function Mwe(e) {
c: A,
d: SJ,
e: SJ,
- f: Jwe,
+ f: Ywe,
g: xJ,
G: bJ,
H: CJ,
I: CJ,
- j: Wwe,
- L: qwe,
- m: Uwe,
- M: Gwe,
+ j: Gwe,
+ L: Jwe,
+ m: Wwe,
+ M: Kwe,
p: T,
- q: Hwe,
- Q: Xwe,
- s: Zwe,
- S: Kwe,
- u: Lwe,
- U: Rwe,
- V: zwe,
- w: Iwe,
- W: Bwe,
+ q: Uwe,
+ Q: Zwe,
+ s: Qwe,
+ S: qwe,
+ u: Rwe,
+ U: zwe,
+ V: Bwe,
+ w: Lwe,
+ W: Vwe,
x: j,
X: M,
y: xJ,
Y: bJ,
- Z: Vwe,
- "%": Ywe
+ Z: Hwe,
+ "%": Xwe
};
y.x = S(n, y), y.X = S(r, y), y.c = S(t, y), b.x = S(n, b), b.X = S(r, b), b.c = S(t, b);
function S(e, t) {
@@ -58360,37 +58412,37 @@ var hJ = {
"-": "",
_: " ",
0: "0"
-}, gJ = /^\s*\d+/, Nwe = /^%/, Pwe = /[\\^$*+?|[\]().{}]/g;
+}, gJ = /^\s*\d+/, Pwe = /^%/, Fwe = /[\\^$*+?|[\]().{}]/g;
function _J(e, t, n) {
var r = e < 0 ? "-" : "", i = (r ? -e : e) + "", a = i.length;
return r + (a < n ? Array(n - a + 1).join(t) + i : i);
}
-function Fwe(e) {
- return e.replace(Pwe, "\\$&");
+function Iwe(e) {
+ return e.replace(Fwe, "\\$&");
}
function vJ(e) {
- return RegExp("^(?:" + e.map(Fwe).join("|") + ")", "i");
+ return RegExp("^(?:" + e.map(Iwe).join("|") + ")", "i");
}
function yJ(e) {
return new Map(e.map((e, t) => [e.toLowerCase(), t]));
}
-function Iwe(e, t, n) {
+function Lwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 1));
return r ? (e.w = +r[0], n + r[0].length) : -1;
}
-function Lwe(e, t, n) {
+function Rwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 1));
return r ? (e.u = +r[0], n + r[0].length) : -1;
}
-function Rwe(e, t, n) {
+function zwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 2));
return r ? (e.U = +r[0], n + r[0].length) : -1;
}
-function zwe(e, t, n) {
+function Bwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 2));
return r ? (e.V = +r[0], n + r[0].length) : -1;
}
-function Bwe(e, t, n) {
+function Vwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 2));
return r ? (e.W = +r[0], n + r[0].length) : -1;
}
@@ -58402,15 +58454,15 @@ function xJ(e, t, n) {
var r = gJ.exec(t.slice(n, n + 2));
return r ? (e.y = +r[0] + (+r[0] > 68 ? 1900 : 2e3), n + r[0].length) : -1;
}
-function Vwe(e, t, n) {
+function Hwe(e, t, n) {
var r = /^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n, n + 6));
return r ? (e.Z = r[1] ? 0 : -(r[2] + (r[3] || "00")), n + r[0].length) : -1;
}
-function Hwe(e, t, n) {
+function Uwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 1));
return r ? (e.q = r[0] * 3 - 3, n + r[0].length) : -1;
}
-function Uwe(e, t, n) {
+function Wwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 2));
return r ? (e.m = r[0] - 1, n + r[0].length) : -1;
}
@@ -58418,7 +58470,7 @@ function SJ(e, t, n) {
var r = gJ.exec(t.slice(n, n + 2));
return r ? (e.d = +r[0], n + r[0].length) : -1;
}
-function Wwe(e, t, n) {
+function Gwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 3));
return r ? (e.m = 0, e.d = +r[0], n + r[0].length) : -1;
}
@@ -58426,159 +58478,159 @@ function CJ(e, t, n) {
var r = gJ.exec(t.slice(n, n + 2));
return r ? (e.H = +r[0], n + r[0].length) : -1;
}
-function Gwe(e, t, n) {
+function Kwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 2));
return r ? (e.M = +r[0], n + r[0].length) : -1;
}
-function Kwe(e, t, n) {
+function qwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 2));
return r ? (e.S = +r[0], n + r[0].length) : -1;
}
-function qwe(e, t, n) {
+function Jwe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 3));
return r ? (e.L = +r[0], n + r[0].length) : -1;
}
-function Jwe(e, t, n) {
+function Ywe(e, t, n) {
var r = gJ.exec(t.slice(n, n + 6));
return r ? (e.L = Math.floor(r[0] / 1e3), n + r[0].length) : -1;
}
-function Ywe(e, t, n) {
- var r = Nwe.exec(t.slice(n, n + 1));
+function Xwe(e, t, n) {
+ var r = Pwe.exec(t.slice(n, n + 1));
return r ? n + r[0].length : -1;
}
-function Xwe(e, t, n) {
+function Zwe(e, t, n) {
var r = gJ.exec(t.slice(n));
return r ? (e.Q = +r[0], n + r[0].length) : -1;
}
-function Zwe(e, t, n) {
+function Qwe(e, t, n) {
var r = gJ.exec(t.slice(n));
return r ? (e.s = +r[0], n + r[0].length) : -1;
}
function wJ(e, t) {
return _J(e.getDate(), t, 2);
}
-function Qwe(e, t) {
+function $we(e, t) {
return _J(e.getHours(), t, 2);
}
-function $we(e, t) {
+function eTe(e, t) {
return _J(e.getHours() % 12 || 12, t, 2);
}
-function eTe(e, t) {
+function tTe(e, t) {
return _J(1 + Xq.count(lJ(e), e), t, 3);
}
function TJ(e, t) {
return _J(e.getMilliseconds(), t, 3);
}
-function tTe(e, t) {
+function nTe(e, t) {
return TJ(e, t) + "000";
}
-function nTe(e, t) {
+function rTe(e, t) {
return _J(e.getMonth() + 1, t, 2);
}
-function rTe(e, t) {
+function iTe(e, t) {
return _J(e.getMinutes(), t, 2);
}
-function iTe(e, t) {
+function aTe(e, t) {
return _J(e.getSeconds(), t, 2);
}
-function aTe(e) {
+function oTe(e) {
var t = e.getDay();
return t === 0 ? 7 : t;
}
-function oTe(e, t) {
+function sTe(e, t) {
return _J(eJ.count(lJ(e) - 1, e), t, 2);
}
function EJ(e) {
var t = e.getDay();
return t >= 4 || t === 0 ? nJ(e) : nJ.ceil(e);
}
-function sTe(e, t) {
+function cTe(e, t) {
return e = EJ(e), _J(nJ.count(lJ(e), e) + (lJ(e).getDay() === 4), t, 2);
}
-function cTe(e) {
+function lTe(e) {
return e.getDay();
}
-function lTe(e, t) {
+function uTe(e, t) {
return _J(tJ.count(lJ(e) - 1, e), t, 2);
}
-function uTe(e, t) {
+function dTe(e, t) {
return _J(e.getFullYear() % 100, t, 2);
}
-function dTe(e, t) {
+function fTe(e, t) {
return e = EJ(e), _J(e.getFullYear() % 100, t, 2);
}
-function fTe(e, t) {
+function pTe(e, t) {
return _J(e.getFullYear() % 1e4, t, 4);
}
-function pTe(e, t) {
+function mTe(e, t) {
var n = e.getDay();
return e = n >= 4 || n === 0 ? nJ(e) : nJ.ceil(e), _J(e.getFullYear() % 1e4, t, 4);
}
-function mTe(e) {
+function hTe(e) {
var t = e.getTimezoneOffset();
return (t > 0 ? "-" : (t *= -1, "+")) + _J(t / 60 | 0, "0", 2) + _J(t % 60, "0", 2);
}
function DJ(e, t) {
return _J(e.getUTCDate(), t, 2);
}
-function hTe(e, t) {
+function gTe(e, t) {
return _J(e.getUTCHours(), t, 2);
}
-function gTe(e, t) {
+function _Te(e, t) {
return _J(e.getUTCHours() % 12 || 12, t, 2);
}
-function _Te(e, t) {
+function vTe(e, t) {
return _J(1 + Zq.count(uJ(e), e), t, 3);
}
function OJ(e, t) {
return _J(e.getUTCMilliseconds(), t, 3);
}
-function vTe(e, t) {
+function yTe(e, t) {
return OJ(e, t) + "000";
}
-function yTe(e, t) {
+function bTe(e, t) {
return _J(e.getUTCMonth() + 1, t, 2);
}
-function bTe(e, t) {
+function xTe(e, t) {
return _J(e.getUTCMinutes(), t, 2);
}
-function xTe(e, t) {
+function STe(e, t) {
return _J(e.getUTCSeconds(), t, 2);
}
-function STe(e) {
+function CTe(e) {
var t = e.getUTCDay();
return t === 0 ? 7 : t;
}
-function CTe(e, t) {
+function wTe(e, t) {
return _J(iJ.count(uJ(e) - 1, e), t, 2);
}
function kJ(e) {
var t = e.getUTCDay();
return t >= 4 || t === 0 ? oJ(e) : oJ.ceil(e);
}
-function wTe(e, t) {
+function TTe(e, t) {
return e = kJ(e), _J(oJ.count(uJ(e), e) + (uJ(e).getUTCDay() === 4), t, 2);
}
-function TTe(e) {
+function ETe(e) {
return e.getUTCDay();
}
-function ETe(e, t) {
+function DTe(e, t) {
return _J(aJ.count(uJ(e) - 1, e), t, 2);
}
-function DTe(e, t) {
+function OTe(e, t) {
return _J(e.getUTCFullYear() % 100, t, 2);
}
-function OTe(e, t) {
+function kTe(e, t) {
return e = kJ(e), _J(e.getUTCFullYear() % 100, t, 2);
}
-function kTe(e, t) {
+function ATe(e, t) {
return _J(e.getUTCFullYear() % 1e4, t, 4);
}
-function ATe(e, t) {
+function jTe(e, t) {
var n = e.getUTCDay();
return e = n >= 4 || n === 0 ? oJ(e) : oJ.ceil(e), _J(e.getUTCFullYear() % 1e4, t, 4);
}
-function jTe() {
+function MTe() {
return "+0000";
}
function AJ() {
@@ -58593,7 +58645,7 @@ function MJ(e) {
//#endregion
//#region node_modules/d3-time-format/src/defaultLocale.js
var NJ, PJ, FJ;
-MTe({
+NTe({
dateTime: "%x, %X",
date: "%-m/%-d/%Y",
time: "%-I:%M:%S %p",
@@ -58645,15 +58697,15 @@ MTe({
"Dec"
]
});
-function MTe(e) {
- return NJ = Mwe(e), PJ = NJ.format, NJ.parse, FJ = NJ.utcFormat, NJ.utcParse, NJ;
+function NTe(e) {
+ return NJ = Nwe(e), PJ = NJ.format, NJ.parse, FJ = NJ.utcFormat, NJ.utcParse, NJ;
}
//#endregion
//#region node_modules/d3-scale/src/time.js
-function NTe(e) {
+function PTe(e) {
return new Date(e);
}
-function PTe(e) {
+function FTe(e) {
return e instanceof Date ? +e : +/* @__PURE__ */ new Date(+e);
}
function IJ(e, t, n, r, i, a, o, s, c, l) {
@@ -58664,7 +58716,7 @@ function IJ(e, t, n, r, i, a, o, s, c, l) {
return u.invert = function(e) {
return new Date(d(e));
}, u.domain = function(e) {
- return arguments.length ? f(Array.from(e, PTe)) : f().map(NTe);
+ return arguments.length ? f(Array.from(e, FTe)) : f().map(PTe);
}, u.ticks = function(t) {
var n = f();
return e(n[0], n[n.length - 1], t ?? 10);
@@ -58677,13 +58729,13 @@ function IJ(e, t, n, r, i, a, o, s, c, l) {
return XK(u, IJ(e, t, n, r, i, a, o, s, c, l));
}, u;
}
-function FTe() {
- return aK.apply(IJ(Awe, jwe, lJ, sJ, eJ, Xq, Jq, Kq, Gq, PJ).domain([new Date(2e3, 0, 1), new Date(2e3, 0, 2)]), arguments);
+function ITe() {
+ return aK.apply(IJ(jwe, Mwe, lJ, sJ, eJ, Xq, Jq, Kq, Gq, PJ).domain([new Date(2e3, 0, 1), new Date(2e3, 0, 2)]), arguments);
}
//#endregion
//#region node_modules/d3-scale/src/utcTime.js
-function ITe() {
- return aK.apply(IJ(Owe, kwe, uJ, cJ, iJ, Zq, Yq, qq, Gq, FJ).domain([Date.UTC(2e3, 0, 1), Date.UTC(2e3, 0, 2)]), arguments);
+function LTe() {
+ return aK.apply(IJ(kwe, Awe, uJ, cJ, iJ, Zq, Yq, qq, Gq, FJ).domain([Date.UTC(2e3, 0, 1), Date.UTC(2e3, 0, 2)]), arguments);
}
//#endregion
//#region node_modules/d3-scale/src/sequential.js
@@ -58738,7 +58790,7 @@ function HJ() {
return RJ(e, HJ()).exponent(e.exponent());
}, oK.apply(e, arguments);
}
-function LTe() {
+function RTe() {
return HJ.apply(null, arguments).exponent(.5);
}
//#endregion
@@ -58758,7 +58810,7 @@ function UJ() {
}, n.range = function() {
return e.map((n, r) => t(r / (e.length - 1)));
}, n.quantiles = function(t) {
- return Array.from({ length: t + 1 }, (n, r) => SCe(e, r / t));
+ return Array.from({ length: t + 1 }, (n, r) => CCe(e, r / t));
}, n.copy = function() {
return UJ(t).domain(e);
}, oK.apply(n, arguments);
@@ -58784,7 +58836,7 @@ function WJ() {
function m(e) {
return function(t) {
var n, r, i;
- return arguments.length ? ([n, r, i] = t, l = YCe(e, [
+ return arguments.length ? ([n, r, i] = t, l = XCe(e, [
n,
r,
i
@@ -58829,7 +58881,7 @@ function JJ() {
return RJ(e, JJ()).exponent(e.exponent());
}, oK.apply(e, arguments);
}
-function RTe() {
+function zTe() {
return JJ.apply(null, arguments).exponent(.5);
}
//#endregion
@@ -58839,14 +58891,14 @@ var YJ = /* @__PURE__ */ De({
scaleDiverging: () => GJ,
scaleDivergingLog: () => KJ,
scaleDivergingPow: () => JJ,
- scaleDivergingSqrt: () => RTe,
+ scaleDivergingSqrt: () => zTe,
scaleDivergingSymlog: () => qJ,
scaleIdentity: () => hq,
scaleImplicit: () => sK,
scaleLinear: () => mq,
scaleLog: () => xq,
scaleOrdinal: () => cK,
- scalePoint: () => TCe,
+ scalePoint: () => ECe,
scalePow: () => Oq,
scaleQuantile: () => jq,
scaleQuantize: () => Mq,
@@ -58855,26 +58907,26 @@ var YJ = /* @__PURE__ */ De({
scaleSequentialLog: () => BJ,
scaleSequentialPow: () => HJ,
scaleSequentialQuantile: () => UJ,
- scaleSequentialSqrt: () => LTe,
+ scaleSequentialSqrt: () => RTe,
scaleSequentialSymlog: () => VJ,
- scaleSqrt: () => vwe,
+ scaleSqrt: () => ywe,
scaleSymlog: () => Tq,
scaleThreshold: () => Nq,
- scaleTime: () => FTe,
- scaleUtc: () => ITe,
+ scaleTime: () => ITe,
+ scaleUtc: () => LTe,
tickFormat: () => fq
});
//#endregion
//#region node_modules/recharts/es6/state/selectors/combiners/combineConfiguredScale.js
-function zTe(e) {
+function BTe(e) {
if (e in YJ) return YJ[e]();
- var t = `scale${IL(e)}`;
+ var t = `scale${LL(e)}`;
if (t in YJ) return YJ[t]();
}
function XJ(e, t, n) {
if (typeof e == "function") return e.copy().domain(t).range(n);
if (e != null) {
- var r = zTe(e);
+ var r = BTe(e);
if (r != null) return r.domain(t).range(n), r;
}
}
@@ -58883,22 +58935,22 @@ function ZJ(e, t, n, r) {
}
//#endregion
//#region node_modules/recharts/es6/state/selectors/combiners/combineRealScaleType.js
-function BTe(e) {
- return `scale${IL(e)}`;
-}
function VTe(e) {
- return BTe(e) in YJ;
+ return `scale${LL(e)}`;
+}
+function HTe(e) {
+ return VTe(e) in YJ;
}
var QJ = (e, t, n) => {
if (e != null) {
var { scale: r, type: i } = e;
if (r === "auto") return i === "category" && n && (n.indexOf("LineChart") >= 0 || n.indexOf("AreaChart") >= 0 || n.indexOf("ComposedChart") >= 0 && !t) ? "point" : i === "category" ? "band" : "linear";
- if (typeof r == "string") return VTe(r) ? r : "point";
+ if (typeof r == "string") return HTe(r) ? r : "point";
}
};
//#endregion
//#region node_modules/recharts/es6/util/scale/createCategoricalInverse.js
-function HTe(e, t) {
+function UTe(e, t) {
for (var n = 0, r = e.length, i = e[0] < e[e.length - 1]; n < r;) {
var a = Math.floor((n + r) / 2);
(i ? e[a] < t : e[a] > t) ? n = a + 1 : r = a;
@@ -58909,7 +58961,7 @@ function $J(e, t) {
if (e) {
var n = t ?? e.domain(), r = n.map((t) => e(t) ?? 0), i = e.range();
if (!(n.length === 0 || i.length < 2)) return (e) => {
- var t = HTe(r, e);
+ var t = UTe(r, e);
if (t <= 0) return n[0];
if (t >= n.length) return n[n.length - 1];
var i = r[t - 1] ?? 0, a = r[t] ?? 0;
@@ -58919,7 +58971,7 @@ function $J(e, t) {
}
//#endregion
//#region node_modules/recharts/es6/state/selectors/combiners/combineInverseScaleFunction.js
-function UTe(e) {
+function WTe(e) {
if (e != null) return "invert" in e && typeof e.invert == "function" ? e.invert.bind(e) : $J(e, void 0);
}
//#endregion
@@ -58938,26 +58990,26 @@ function tY(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? eY(Object(n), !0).forEach(function(t) {
- WTe(e, t, n[t]);
+ GTe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : eY(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function WTe(e, t, n) {
- return (t = GTe(t)) in e ? Object.defineProperty(e, t, {
+function GTe(e, t, n) {
+ return (t = KTe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function GTe(e) {
- var t = KTe(e, "string");
+function KTe(e) {
+ var t = qTe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function KTe(e, t) {
+function qTe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -59025,7 +59077,7 @@ var nY = [0, "auto"], rY = {
unit: void 0,
niceTicks: "auto",
width: 60
-}, sY = (e, t) => e.cartesianAxis.yAxis[t], cY = (e, t) => sY(e, t) ?? oY, qTe = {
+}, sY = (e, t) => e.cartesianAxis.yAxis[t], cY = (e, t) => sY(e, t) ?? oY, JTe = {
domain: [0, "auto"],
includeHidden: !1,
reversed: !1,
@@ -59038,7 +59090,7 @@ var nY = [0, "auto"], rY = {
scale: "auto",
type: "number",
unit: ""
-}, lY = (e, t) => e.cartesianAxis.zAxis[t] ?? qTe, uY = (e, t, n) => {
+}, lY = (e, t) => e.cartesianAxis.zAxis[t] ?? JTe, uY = (e, t, n) => {
switch (t) {
case "xAxis": return aY(e, n);
case "yAxis": return cY(e, n);
@@ -59047,7 +59099,7 @@ var nY = [0, "auto"], rY = {
case "radiusAxis": return SG(e, n);
default: throw Error(`Unexpected axis type: ${t}`);
}
-}, JTe = (e, t, n) => {
+}, YTe = (e, t, n) => {
switch (t) {
case "xAxis": return aY(e, n);
case "yAxis": return cY(e, n);
@@ -59074,22 +59126,22 @@ function pY(e, t) {
}
};
}
-var mY = (e) => e.graphicalItems.cartesianItems, YTe = $([AG, jG], pY), hY = (e, t, n) => e.filter(n).filter((e) => t?.includeHidden === !0 || !e.hide), gY = $([
+var mY = (e) => e.graphicalItems.cartesianItems, XTe = $([AG, jG], pY), hY = (e, t, n) => e.filter(n).filter((e) => t?.includeHidden === !0 || !e.hide), gY = $([
mY,
uY,
- YTe
-], hY, { memoizeOptions: { resultEqualityCheck: IG } }), _Y = $([gY], (e) => e.filter((e) => e.type === "area" || e.type === "bar").filter(PG)), vY = (e) => e.filter((e) => !("stackId" in e) || e.stackId === void 0), XTe = $([gY], vY), yY = (e) => e.map((e) => e.data).filter(Boolean).flat(1), ZTe = $([gY], yY, { memoizeOptions: { resultEqualityCheck: IG } }), bY = (e, t) => {
+ XTe
+], hY, { memoizeOptions: { resultEqualityCheck: IG } }), _Y = $([gY], (e) => e.filter((e) => e.type === "area" || e.type === "bar").filter(PG)), vY = (e) => e.filter((e) => !("stackId" in e) || e.stackId === void 0), ZTe = $([gY], vY), yY = (e) => e.map((e) => e.data).filter(Boolean).flat(1), QTe = $([gY], yY, { memoizeOptions: { resultEqualityCheck: IG } }), bY = (e, t) => {
var { chartData: n = [], dataStartIndex: r, dataEndIndex: i } = t;
return e.length > 0 ? e : n.slice(r, i + 1);
-}, xY = $([ZTe, HW], bY), SY = (e, t, n) => t?.dataKey == null ? n.length > 0 ? n.map((e) => e.dataKey).flatMap((t) => e.map((e) => ({ value: QB(e, t) }))) : e.map((e) => ({ value: e })) : e.map((e) => ({ value: QB(e, t.dataKey) })), CY = $([
+}, xY = $([QTe, HW], bY), SY = (e, t, n) => t?.dataKey == null ? n.length > 0 ? n.map((e) => e.dataKey).flatMap((t) => e.map((e) => ({ value: $B(e, t) }))) : e.map((e) => ({ value: e })) : e.map((e) => ({ value: $B(e, t.dataKey) })), CY = $([
xY,
uY,
gY
], SY);
function wY(e) {
- if (kL(e) || e instanceof Date) {
+ if (AL(e) || e instanceof Date) {
var t = Number(e);
- if (GB(t)) return t;
+ if (KB(t)) return t;
}
}
function TY(e) {
@@ -59101,13 +59153,13 @@ function TY(e) {
if (n != null) return [n, n];
}
function EY(e) {
- return e.map(wY).filter(LL);
+ return e.map(wY).filter(RL);
}
-function QTe(e, t) {
+function $Te(e, t) {
var n = wY(e), r = wY(t);
return n == null && r == null ? 0 : n == null ? -1 : r == null ? 1 : n - r;
}
-var $Te = $([CY], (e) => e?.map((e) => e.value).sort(QTe));
+var eEe = $([CY], (e) => e?.map((e) => e.value).sort($Te));
function DY(e, t) {
switch (e) {
case "xAxis": return t.direction === "x";
@@ -59115,13 +59167,13 @@ function DY(e, t) {
default: return !1;
}
}
-function eEe(e, t, n) {
- return !n || typeof t != "number" || DL(t) || !n.length ? [] : EY(n.flatMap((n) => {
- var r = QB(e, n.dataKey), i, a;
- if (Array.isArray(r) ? [i, a] = r : i = a = r, !(!GB(i) || !GB(a))) return [t - i, t + a];
+function tEe(e, t, n) {
+ return !n || typeof t != "number" || OL(t) || !n.length ? [] : EY(n.flatMap((n) => {
+ var r = $B(e, n.dataKey), i, a;
+ if (Array.isArray(r) ? [i, a] = r : i = a = r, !(!KB(i) || !KB(a))) return [t - i, t + a];
}));
}
-var OY = (e) => dY(e, LG(e), RG(e)), kY = $([OY], (e) => e?.dataKey), tEe = $([
+var OY = (e) => dY(e, LG(e), RG(e)), kY = $([OY], (e) => e?.dataKey), nEe = $([
_Y,
HW,
OY
@@ -59134,22 +59186,22 @@ var OY = (e) => dY(e, LG(e), RG(e)), kY = $([OY], (e) => e?.dataKey), tEe = $([
return Object.fromEntries(Object.entries(i).map((t) => {
var [i, a] = t, o = r ? [...a].reverse() : a;
return [i, {
- stackedData: aV(e, o.map(MG), n),
+ stackedData: oV(e, o.map(MG), n),
graphicalItems: o
}];
}));
}, jY = $([
- tEe,
+ nEe,
_Y,
oG,
sG
], AY), MY = (e, t, n, r) => {
var { dataStartIndex: i, dataEndIndex: a } = t;
if (r == null && n !== "zAxis") {
- var o = fV(e, i, a);
+ var o = pV(e, i, a);
if (o == null || o[0] !== 0 || o[1] !== 0) return o;
}
-}, nEe = $([uY], (e) => e.allowDataOverflow), NY = (e) => {
+}, rEe = $([uY], (e) => e.allowDataOverflow), NY = (e) => {
if (e == null || !("domain" in e)) return nY;
if (e.domain != null) return e.domain;
if ("ticks" in e && e.ticks != null) {
@@ -59160,12 +59212,12 @@ var OY = (e) => dY(e, LG(e), RG(e)), kY = $([OY], (e) => e?.dataKey), tEe = $([
if (e.type === "category") return e.ticks.map(String);
}
return e?.domain ?? nY;
-}, PY = $([uY], NY), FY = $([PY, nEe], KW), rEe = $([
+}, PY = $([uY], NY), FY = $([PY, rEe], KW), iEe = $([
jY,
BW,
AG,
FY
-], MY, { memoizeOptions: { resultEqualityCheck: FG } }), IY = (e) => e.errorBars, iEe = (e, t, n) => e.flatMap((e) => t[e.id]).filter(Boolean).filter((e) => DY(n, e)), LY = function() {
+], MY, { memoizeOptions: { resultEqualityCheck: FG } }), IY = (e) => e.errorBars, aEe = (e, t, n) => e.flatMap((e) => t[e.id]).filter(Boolean).filter((e) => DY(n, e)), LY = function() {
var e = [...arguments].filter(Boolean);
if (e.length !== 0) {
var t = e.flat();
@@ -59175,7 +59227,7 @@ var OY = (e) => dY(e, LG(e), RG(e)), kY = $([OY], (e) => e?.dataKey), tEe = $([
var a, o;
if (n.length > 0 && e.forEach((e) => {
n.forEach((n) => {
- var s = r[n.id]?.filter((e) => DY(i, e)), c = QB(e, t.dataKey ?? n.dataKey), l = eEe(e, c, s);
+ var s = r[n.id]?.filter((e) => DY(i, e)), c = $B(e, t.dataKey ?? n.dataKey), l = tEe(e, c, s);
if (l.length >= 2) {
var u = Math.min(...l), d = Math.max(...l);
(a == null || u < a) && (a = u), (o == null || d > o) && (o = d);
@@ -59184,32 +59236,32 @@ var OY = (e) => dY(e, LG(e), RG(e)), kY = $([OY], (e) => e?.dataKey), tEe = $([
f != null && (a = a == null ? f[0] : Math.min(a, f[0]), o = o == null ? f[1] : Math.max(o, f[1]));
});
}), t?.dataKey != null && e.forEach((e) => {
- var n = TY(QB(e, t.dataKey));
+ var n = TY($B(e, t.dataKey));
n != null && (a = a == null ? n[0] : Math.min(a, n[0]), o = o == null ? n[1] : Math.max(o, n[1]));
- }), GB(a) && GB(o)) return [a, o];
-}, aEe = $([
+ }), KB(a) && KB(o)) return [a, o];
+}, oEe = $([
xY,
uY,
- XTe,
+ ZTe,
IY,
AG
], RY, { memoizeOptions: { resultEqualityCheck: FG } });
-function oEe(e) {
+function sEe(e) {
var { value: t } = e;
- if (kL(t) || t instanceof Date) return t;
+ if (AL(t) || t instanceof Date) return t;
}
-var sEe = (e, t, n) => {
- var r = e.map(oEe).filter((e) => e != null);
- return n && (t.dataKey == null || t.allowDuplicatedCategory && ML(r)) ? zW(0, e.length) : t.allowDuplicatedCategory ? r : Array.from(new Set(r));
-}, zY = (e) => e.referenceElements.dots, BY = (e, t, n) => e.filter((e) => e.ifOverflow === "extendDomain").filter((e) => t === "xAxis" ? e.xAxisId === n : e.yAxisId === n), cEe = $([
+var cEe = (e, t, n) => {
+ var r = e.map(sEe).filter((e) => e != null);
+ return n && (t.dataKey == null || t.allowDuplicatedCategory && NL(r)) ? zW(0, e.length) : t.allowDuplicatedCategory ? r : Array.from(new Set(r));
+}, zY = (e) => e.referenceElements.dots, BY = (e, t, n) => e.filter((e) => e.ifOverflow === "extendDomain").filter((e) => t === "xAxis" ? e.xAxisId === n : e.yAxisId === n), lEe = $([
zY,
AG,
jG
-], BY), VY = (e) => e.referenceElements.areas, lEe = $([
+], BY), VY = (e) => e.referenceElements.areas, uEe = $([
VY,
AG,
jG
-], BY), HY = (e) => e.referenceElements.lines, uEe = $([
+], BY), HY = (e) => e.referenceElements.lines, dEe = $([
HY,
AG,
jG
@@ -59218,49 +59270,49 @@ var sEe = (e, t, n) => {
var n = EY(e.map((e) => t === "xAxis" ? e.x : e.y));
if (n.length !== 0) return [Math.min(...n), Math.max(...n)];
}
-}, dEe = $(cEe, AG, UY), WY = (e, t) => {
+}, fEe = $(lEe, AG, UY), WY = (e, t) => {
if (e != null) {
var n = EY(e.flatMap((e) => [t === "xAxis" ? e.x1 : e.y1, t === "xAxis" ? e.x2 : e.y2]));
if (n.length !== 0) return [Math.min(...n), Math.max(...n)];
}
-}, fEe = $([lEe, AG], WY);
-function pEe(e) {
+}, pEe = $([uEe, AG], WY);
+function mEe(e) {
if (e.x != null) return EY([e.x]);
var t = e.segment?.map((e) => e.x);
return t == null || t.length === 0 ? [] : EY(t);
}
-function mEe(e) {
+function hEe(e) {
if (e.y != null) return EY([e.y]);
var t = e.segment?.map((e) => e.y);
return t == null || t.length === 0 ? [] : EY(t);
}
var GY = (e, t) => {
if (e != null) {
- var n = e.flatMap((e) => t === "xAxis" ? pEe(e) : mEe(e));
+ var n = e.flatMap((e) => t === "xAxis" ? mEe(e) : hEe(e));
if (n.length !== 0) return [Math.min(...n), Math.max(...n)];
}
-}, hEe = $(dEe, $([uEe, AG], GY), fEe, (e, t, n) => LY(e, n, t)), KY = (e, t, n, r, i, a, o, s) => n ?? cCe(t, o === "vertical" && s === "xAxis" || o === "horizontal" && s === "yAxis" ? LY(r, a, i) : LY(a, i), e.allowDataOverflow), gEe = $([
+}, gEe = $(fEe, $([dEe, AG], GY), pEe, (e, t, n) => LY(e, n, t)), KY = (e, t, n, r, i, a, o, s) => n ?? lCe(t, o === "vertical" && s === "xAxis" || o === "horizontal" && s === "yAxis" ? LY(r, a, i) : LY(a, i), e.allowDataOverflow), _Ee = $([
uY,
PY,
FY,
- rEe,
- aEe,
- hEe,
- xH,
+ iEe,
+ oEe,
+ gEe,
+ SH,
AG
-], KY, { memoizeOptions: { resultEqualityCheck: FG } }), _Ee = [0, 1], qY = (e, t, n, r, i, a, o) => {
+], KY, { memoizeOptions: { resultEqualityCheck: FG } }), vEe = [0, 1], qY = (e, t, n, r, i, a, o) => {
if (e != null && n != null && n.length !== 0 || o !== void 0) {
- var { dataKey: s, type: c } = e, l = eV(t, a);
- return l && s == null ? zW(0, n?.length ?? 0) : c === "category" ? sEe(r, e, l) : i === "expand" ? _Ee : o;
+ var { dataKey: s, type: c } = e, l = tV(t, a);
+ return l && s == null ? zW(0, n?.length ?? 0) : c === "category" ? cEe(r, e, l) : i === "expand" ? vEe : o;
}
}, JY = $([
uY,
- xH,
+ SH,
xY,
CY,
oG,
AG,
- gEe
+ _Ee
], qY), YY = $([
uY,
fY,
@@ -59288,7 +59340,7 @@ var GY = (e, t) => {
return [Math.min(i, a), Math.max(o, s)];
}
return t;
-}, vEe = $([
+}, yEe = $([
uY,
JY,
ZY,
@@ -59308,22 +59360,22 @@ var GY = (e, t) => {
}
return n / o;
}
-}), xH, iG, LV, (e, t, n, r, i) => i, (e, t, n, r, i) => {
- if (!GB(e)) return 0;
+}), SH, iG, RV, (e, t, n, r, i) => i, (e, t, n, r, i) => {
+ if (!KB(e)) return 0;
var a = t === "vertical" ? r.height : r.width;
if (i === "gap") return e * a / 2;
if (i === "no-gap") {
- var o = jL(n, e * a), s = e * a / 2;
+ var o = ML(n, e * a), s = e * a / 2;
return s - o - (s - o) / a * o;
}
return 0;
-}), yEe = (e, t, n) => {
+}), bEe = (e, t, n) => {
var r = aY(e, t);
return r == null || typeof r.padding != "string" ? 0 : $Y(e, "xAxis", t, n, r.padding);
-}, bEe = (e, t, n) => {
+}, xEe = (e, t, n) => {
var r = cY(e, t);
return r == null || typeof r.padding != "string" ? 0 : $Y(e, "yAxis", t, n, r.padding);
-}, xEe = $(aY, yEe, (e, t) => {
+}, SEe = $(aY, bEe, (e, t) => {
if (e == null) return {
left: 0,
right: 0
@@ -59336,7 +59388,7 @@ var GY = (e, t) => {
left: (n.left ?? 0) + t,
right: (n.right ?? 0) + t
};
-}), SEe = $(cY, bEe, (e, t) => {
+}), CEe = $(cY, xEe, (e, t) => {
if (e == null) return {
top: 0,
bottom: 0
@@ -59349,29 +59401,29 @@ var GY = (e, t) => {
top: (n.top ?? 0) + t,
bottom: (n.bottom ?? 0) + t
};
-}), CEe = $([
- LV,
- xEe,
+}), wEe = $([
+ RV,
+ SEe,
+ WV,
UV,
- HV,
(e, t, n) => n
], (e, t, n, r, i) => {
var { padding: a } = r;
return i ? [a.left, n.width - a.right] : [e.left + t.left, e.left + e.width - t.right];
-}), wEe = $([
- LV,
- xH,
- SEe,
+}), TEe = $([
+ RV,
+ SH,
+ CEe,
+ WV,
UV,
- HV,
(e, t, n) => n
], (e, t, n, r, i, a) => {
var { padding: o } = i;
return a ? [r.height - o.bottom, o.top] : t === "horizontal" ? [e.top + e.height - n.bottom, e.top + n.top] : [e.top + n.top, e.top + e.height - n.bottom];
}), eX = (e, t, n, r) => {
switch (t) {
- case "xAxis": return CEe(e, n, r);
- case "yAxis": return wEe(e, n, r);
+ case "xAxis": return wEe(e, n, r);
+ case "yAxis": return TEe(e, n, r);
case "zAxis": return lY(e, n)?.range;
case "angleAxis": return DG(e);
case "radiusAxis": return OG(e, n);
@@ -59380,67 +59432,67 @@ var GY = (e, t) => {
}, tX = $([uY, eX], hG), nX = $([
uY,
YY,
- $([YY, vEe], BG),
+ $([YY, yEe], BG),
tX
], ZJ), rX = (e, t, n, r) => {
if (n != null && n.dataKey != null) {
var { type: i, scale: a } = n;
- if (eV(e, r) && (i === "number" || a !== "auto")) return t.map((e) => e.value);
+ if (tV(e, r) && (i === "number" || a !== "auto")) return t.map((e) => e.value);
}
}, iX = $([
- xH,
+ SH,
CY,
dY,
AG
], rX), aX = $([nX], zG);
-$([nX], UTe), $([nX, $Te], $J), $([
+$([nX], WTe), $([nX, eEe], $J), $([
gY,
IY,
AG
-], iEe);
+], aEe);
function oX(e, t) {
return e.id < t.id ? -1 : +(e.id > t.id);
}
-var sX = (e, t) => t, cX = (e, t, n) => n, TEe = $(wV, sX, cX, (e, t, n) => e.filter((e) => e.orientation === t).filter((e) => e.mirror === n).sort(oX)), EEe = $(TV, sX, cX, (e, t, n) => e.filter((e) => e.orientation === t).filter((e) => e.mirror === n).sort(oX)), lX = (e, t) => ({
+var sX = (e, t) => t, cX = (e, t, n) => n, EEe = $(TV, sX, cX, (e, t, n) => e.filter((e) => e.orientation === t).filter((e) => e.mirror === n).sort(oX)), DEe = $(EV, sX, cX, (e, t, n) => e.filter((e) => e.orientation === t).filter((e) => e.mirror === n).sort(oX)), lX = (e, t) => ({
width: e.width,
height: t.height
-}), DEe = (e, t) => ({
+}), OEe = (e, t) => ({
width: typeof t.width == "number" ? t.width : 60,
height: e.height
-}), uX = $(LV, aY, lX), OEe = (e, t, n) => {
+}), uX = $(RV, aY, lX), kEe = (e, t, n) => {
switch (t) {
case "top": return e.top;
case "bottom": return n - e.bottom;
default: return 0;
}
-}, kEe = (e, t, n) => {
+}, AEe = (e, t, n) => {
switch (t) {
case "left": return e.left;
case "right": return n - e.right;
default: return 0;
}
-}, AEe = $(xV, LV, TEe, sX, cX, (e, t, n, r, i) => {
+}, jEe = $(SV, RV, EEe, sX, cX, (e, t, n, r, i) => {
var a = {}, o;
return n.forEach((n) => {
var s = lX(t, n);
- o ??= OEe(t, r, e);
+ o ??= kEe(t, r, e);
var c = r === "top" && !i || r === "bottom" && i;
a[n.id] = o - Number(c) * s.height, o += (c ? -1 : 1) * s.height;
}), a;
-}), jEe = $(bV, LV, EEe, sX, cX, (e, t, n, r, i) => {
+}), MEe = $(xV, RV, DEe, sX, cX, (e, t, n, r, i) => {
var a = {}, o;
return n.forEach((n) => {
- var s = DEe(t, n);
- o ??= kEe(t, r, e);
+ var s = OEe(t, n);
+ o ??= AEe(t, r, e);
var c = r === "left" && !i || r === "right" && i;
a[n.id] = o - Number(c) * s.width, o += (c ? -1 : 1) * s.width;
}), a;
-}), MEe = $([
- LV,
+}), NEe = $([
+ RV,
aY,
(e, t) => {
var n = aY(e, t);
- if (n != null) return AEe(e, n.orientation, n.mirror);
+ if (n != null) return jEe(e, n.orientation, n.mirror);
},
(e, t) => t
], (e, t, n, r) => {
@@ -59454,12 +59506,12 @@ var sX = (e, t) => t, cX = (e, t, n) => n, TEe = $(wV, sX, cX, (e, t, n) => e.fi
y: i
};
}
-}), NEe = $([
- LV,
+}), PEe = $([
+ RV,
cY,
(e, t) => {
var n = cY(e, t);
- if (n != null) return jEe(e, n.orientation, n.mirror);
+ if (n != null) return MEe(e, n.orientation, n.mirror);
},
(e, t) => t
], (e, t, n, r) => {
@@ -59473,7 +59525,7 @@ var sX = (e, t) => t, cX = (e, t, n) => n, TEe = $(wV, sX, cX, (e, t, n) => e.fi
y: e.top
};
}
-}), dX = $(LV, cY, (e, t) => ({
+}), dX = $(RV, cY, (e, t) => ({
width: typeof t.width == "number" ? t.width : 60,
height: e.height
})), fX = (e, t, n) => {
@@ -59484,17 +59536,17 @@ var sX = (e, t) => t, cX = (e, t, n) => n, TEe = $(wV, sX, cX, (e, t, n) => e.fi
}
}, pX = (e, t, n, r) => {
if (n != null) {
- var { allowDuplicatedCategory: i, type: a, dataKey: o } = n, s = eV(e, r), c = t.map((e) => e.value);
- if (o && s && a === "category" && i && ML(c)) return c;
+ var { allowDuplicatedCategory: i, type: a, dataKey: o } = n, s = tV(e, r), c = t.map((e) => e.value);
+ if (o && s && a === "category" && i && NL(c)) return c;
}
}, mX = $([
- xH,
+ SH,
CY,
uY,
AG
], pX), hX = $([
- xH,
- JTe,
+ SH,
+ YTe,
YY,
aX,
mX,
@@ -59504,7 +59556,7 @@ var sX = (e, t) => t, cX = (e, t, n) => n, TEe = $(wV, sX, cX, (e, t, n) => e.fi
AG
], (e, t, n, r, i, a, o, s, c) => {
if (t != null) {
- var l = eV(e, c);
+ var l = tV(e, c);
return {
angle: t.angle,
interval: t.interval,
@@ -59528,45 +59580,45 @@ var sX = (e, t) => t, cX = (e, t, n) => n, TEe = $(wV, sX, cX, (e, t, n) => e.fi
}
}), gX = (e, t, n, r, i, a, o, s, c) => {
if (t != null && r != null) {
- var l = eV(e, c), { type: u, ticks: d, tickCount: f } = t, p = n === "scaleBand" && typeof r.bandwidth == "function" ? r.bandwidth() / 2 : 2, m = u === "category" && r.bandwidth ? r.bandwidth() / p : 0;
- m = c === "angleAxis" && a != null && a.length >= 2 ? EL(a[0] - a[1]) * 2 * m : m;
+ var l = tV(e, c), { type: u, ticks: d, tickCount: f } = t, p = n === "scaleBand" && typeof r.bandwidth == "function" ? r.bandwidth() / 2 : 2, m = u === "category" && r.bandwidth ? r.bandwidth() / p : 0;
+ m = c === "angleAxis" && a != null && a.length >= 2 ? DL(a[0] - a[1]) * 2 * m : m;
var h = d || i;
return h ? h.map((e, t) => {
var n = o ? o.indexOf(e) : e, i = r.map(n);
- return GB(i) ? {
+ return KB(i) ? {
index: t,
coordinate: i + m,
value: e,
offset: m
} : null;
- }).filter(LL) : l && s ? s.map((e, t) => {
+ }).filter(RL) : l && s ? s.map((e, t) => {
var n = r.map(e);
- return GB(n) ? {
+ return KB(n) ? {
coordinate: n + m,
value: e,
index: t,
offset: m
} : null;
- }).filter(LL) : r.ticks ? r.ticks(f).map((e, t) => {
+ }).filter(RL) : r.ticks ? r.ticks(f).map((e, t) => {
var n = r.map(e);
- return GB(n) ? {
+ return KB(n) ? {
coordinate: n + m,
value: e,
index: t,
offset: m
} : null;
- }).filter(LL) : r.domain().map((e, t) => {
+ }).filter(RL) : r.domain().map((e, t) => {
var n = r.map(e);
- return GB(n) ? {
+ return KB(n) ? {
coordinate: n + m,
value: o ? o[e] : e,
index: t,
offset: m
} : null;
- }).filter(LL);
+ }).filter(RL);
}
}, _X = $([
- xH,
+ SH,
dY,
YY,
aX,
@@ -59577,35 +59629,35 @@ var sX = (e, t) => t, cX = (e, t, n) => n, TEe = $(wV, sX, cX, (e, t, n) => e.fi
AG
], gX), vX = (e, t, n, r, i, a, o) => {
if (t != null && n != null && r != null && r[0] !== r[1]) {
- var s = eV(e, o), { tickCount: c } = t, l = 0;
- return l = o === "angleAxis" && r?.length >= 2 ? EL(r[0] - r[1]) * 2 * l : l, s && a ? a.map((e, t) => {
+ var s = tV(e, o), { tickCount: c } = t, l = 0;
+ return l = o === "angleAxis" && r?.length >= 2 ? DL(r[0] - r[1]) * 2 * l : l, s && a ? a.map((e, t) => {
var r = n.map(e);
- return GB(r) ? {
+ return KB(r) ? {
coordinate: r + l,
value: e,
index: t,
offset: l
} : null;
- }).filter(LL) : n.ticks ? n.ticks(c).map((e, t) => {
+ }).filter(RL) : n.ticks ? n.ticks(c).map((e, t) => {
var r = n.map(e);
- return GB(r) ? {
+ return KB(r) ? {
coordinate: r + l,
value: e,
index: t,
offset: l
} : null;
- }).filter(LL) : n.domain().map((e, t) => {
+ }).filter(RL) : n.domain().map((e, t) => {
var r = n.map(e);
- return GB(r) ? {
+ return KB(r) ? {
coordinate: r + l,
value: i ? i[e] : e,
index: t,
offset: l
} : null;
- }).filter(LL);
+ }).filter(RL);
}
}, yX = $([
- xH,
+ SH,
dY,
aX,
eX,
@@ -59623,10 +59675,10 @@ $((e, t, n) => lY(e, n), $([$([
], ZJ)], zG), (e, t) => {
if (e != null && t != null) return tY(tY({}, e), {}, { scale: t });
});
-var PEe = $([
- xH,
- wV,
- TV
+var FEe = $([
+ SH,
+ TV,
+ EV
], (e, t, n) => {
switch (e) {
case "horizontal": return t.some((e) => e.reversed) ? "right-to-left" : "left-to-right";
@@ -59657,21 +59709,21 @@ function CX(e, t, n) {
function wX(e, t) {
return CX(t, xX(e), SX(e));
}
-function FEe(e) {
+function IEe(e) {
return Q((t) => wX(t, e));
}
//#endregion
//#region node_modules/recharts/es6/state/selectors/combiners/combineActiveLabel.js
var TX = (e, t) => {
var n, r = Number(t);
- if (!(DL(r) || t == null)) return r >= 0 ? e == null || (n = e[r]) == null ? void 0 : n.value : void 0;
-}, IEe = (e) => e.tooltip.settings, EX = {
+ if (!(OL(r) || t == null)) return r >= 0 ? e == null || (n = e[r]) == null ? void 0 : n.value : void 0;
+}, LEe = (e) => e.tooltip.settings, EX = {
active: !1,
index: null,
dataKey: void 0,
graphicalItemId: void 0,
coordinate: void 0
-}, DX = oB({
+}, DX = sB({
name: "tooltip",
initialState: {
itemInteraction: {
@@ -59706,21 +59758,21 @@ var TX = (e, t) => {
reducer(e, t) {
e.tooltipItemPayloads.push(bU(t.payload));
},
- prepare: nB()
+ prepare: rB()
},
replaceTooltipEntrySettings: {
reducer(e, t) {
- var { prev: n, next: r } = t.payload, i = qz(e).tooltipItemPayloads.indexOf(bU(n));
+ var { prev: n, next: r } = t.payload, i = Jz(e).tooltipItemPayloads.indexOf(bU(n));
i > -1 && (e.tooltipItemPayloads[i] = bU(r));
},
- prepare: nB()
+ prepare: rB()
},
removeTooltipEntrySettings: {
reducer(e, t) {
- var n = qz(e).tooltipItemPayloads.indexOf(bU(t.payload));
+ var n = Jz(e).tooltipItemPayloads.indexOf(bU(t.payload));
n > -1 && e.tooltipItemPayloads.splice(n, 1);
},
- prepare: nB()
+ prepare: rB()
},
setTooltipSettingsState(e, t) {
e.settings = t.payload;
@@ -59750,7 +59802,7 @@ var TX = (e, t) => {
e.keyboardInteraction.active = t.payload.active, e.keyboardInteraction.index = t.payload.activeIndex, e.keyboardInteraction.coordinate = t.payload.activeCoordinate;
}
}
-}), { addTooltipEntrySettings: LEe, replaceTooltipEntrySettings: REe, removeTooltipEntrySettings: zEe, setTooltipSettingsState: BEe, setActiveMouseOverItemIndex: OX, mouseLeaveItem: VEe, mouseLeaveChart: kX, setActiveClickItemIndex: HEe, setMouseOverAxisIndex: AX, setMouseClickAxisIndex: UEe, setSyncInteraction: jX, setKeyboardInteraction: MX } = DX.actions, WEe = DX.reducer;
+}), { addTooltipEntrySettings: REe, replaceTooltipEntrySettings: zEe, removeTooltipEntrySettings: BEe, setTooltipSettingsState: VEe, setActiveMouseOverItemIndex: OX, mouseLeaveItem: HEe, mouseLeaveChart: kX, setActiveClickItemIndex: UEe, setMouseOverAxisIndex: AX, setMouseClickAxisIndex: WEe, setSyncInteraction: jX, setKeyboardInteraction: MX } = DX.actions, GEe = DX.reducer;
//#endregion
//#region node_modules/recharts/es6/state/selectors/combiners/combineTooltipInteractionState.js
function NX(e, t) {
@@ -59767,26 +59819,26 @@ function PX(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? NX(Object(n), !0).forEach(function(t) {
- GEe(e, t, n[t]);
+ KEe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : NX(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function GEe(e, t, n) {
- return (t = KEe(t)) in e ? Object.defineProperty(e, t, {
+function KEe(e, t, n) {
+ return (t = qEe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function KEe(e) {
- var t = qEe(e, "string");
+function qEe(e) {
+ var t = JEe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function qEe(e, t) {
+function JEe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -59796,21 +59848,21 @@ function qEe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function JEe(e, t, n) {
+function YEe(e, t, n) {
return t === "axis" ? n === "click" ? e.axisInteraction.click : e.axisInteraction.hover : n === "click" ? e.itemInteraction.click : e.itemInteraction.hover;
}
-function YEe(e) {
+function XEe(e) {
return e.index != null;
}
var FX = (e, t, n, r) => {
if (t == null) return EX;
- var i = JEe(e, t, n);
+ var i = YEe(e, t, n);
if (i == null) return EX;
if (i.active) return i;
if (e.keyboardInteraction.active) return e.keyboardInteraction;
if (e.syncInteraction.active && e.syncInteraction.index != null) return e.syncInteraction;
var a = e.settings.active === !0;
- if (YEe(i)) {
+ if (XEe(i)) {
if (a) return PX(PX({}, i), {}, { active: !0 });
} else if (r != null) return {
active: !0,
@@ -59823,7 +59875,7 @@ var FX = (e, t, n, r) => {
};
//#endregion
//#region node_modules/recharts/es6/state/selectors/combiners/combineActiveTooltipIndex.js
-function XEe(e) {
+function ZEe(e) {
if (typeof e == "number") return Number.isFinite(e) ? e : void 0;
if (e instanceof Date) {
var t = e.valueOf();
@@ -59832,24 +59884,24 @@ function XEe(e) {
var n = Number(e);
return Number.isFinite(n) ? n : void 0;
}
-function ZEe(e, t) {
- var n = XEe(e), r = t[0], i = t[1];
+function QEe(e, t) {
+ var n = ZEe(e), r = t[0], i = t[1];
return n !== void 0 && n >= Math.min(r, i) && n <= Math.max(r, i);
}
-function QEe(e, t, n) {
+function $Ee(e, t, n) {
if (n == null || t == null) return !0;
- var r = QB(e, t);
- return r == null || !WW(n) || ZEe(r, n);
+ var r = $B(e, t);
+ return r == null || !WW(n) || QEe(r, n);
}
var IX = (e, t, n, r) => {
var i = e?.index;
if (i == null) return null;
var a = Number(i);
- if (!GB(a)) return i;
+ if (!KB(a)) return i;
var o = 0, s = Infinity;
t.length > 0 && (s = t.length - 1);
var c = Math.max(o, Math.min(a, s)), l = t[c];
- return l == null || QEe(l, n, r) ? String(c) : null;
+ return l == null || $Ee(l, n, r) ? String(c) : null;
}, LX = (e, t, n, r, i, a, o) => {
if (a != null) {
var s = o[0]?.getPosition(a);
@@ -59893,26 +59945,26 @@ function HX(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? VX(Object(n), !0).forEach(function(t) {
- $Ee(e, t, n[t]);
+ eDe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : VX(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function $Ee(e, t, n) {
- return (t = eDe(t)) in e ? Object.defineProperty(e, t, {
+function eDe(e, t, n) {
+ return (t = tDe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function eDe(e) {
- var t = tDe(e, "string");
+function tDe(e) {
+ var t = nDe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function tDe(e, t) {
+function nDe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -59922,57 +59974,57 @@ function tDe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function nDe(e) {
+function rDe(e) {
if (typeof e == "string" || typeof e == "number") return e;
}
-function rDe(e) {
+function iDe(e) {
if (typeof e == "string" || typeof e == "number" || typeof e == "boolean") return e;
}
-function iDe(e) {
+function aDe(e) {
if (typeof e == "string" || typeof e == "number") return e;
if (typeof e == "function") return (t) => e(t);
}
function UX(e) {
if (typeof e == "string") return e;
}
-function aDe(e) {
+function oDe(e) {
if (!(typeof e != "object" || !e)) return {
- name: "name" in e ? nDe(e.name) : void 0,
- unit: "unit" in e ? rDe(e.unit) : void 0,
- dataKey: "dataKey" in e ? iDe(e.dataKey) : void 0,
+ name: "name" in e ? rDe(e.name) : void 0,
+ unit: "unit" in e ? iDe(e.unit) : void 0,
+ dataKey: "dataKey" in e ? aDe(e.dataKey) : void 0,
payload: "payload" in e ? e.payload : void 0,
color: "color" in e ? UX(e.color) : void 0,
fill: "fill" in e ? UX(e.fill) : void 0
};
}
-function oDe(e, t) {
+function sDe(e, t) {
return e ?? t;
}
var WX = (e, t, n, r, i, a, o) => {
if (t != null && a != null) {
var { chartData: s, computedData: c, dataStartIndex: l, dataEndIndex: u } = n;
return e.reduce((e, n) => {
- var { dataDefinedOnItem: d, settings: f } = n, p = oDe(d, s), m = Array.isArray(p) ? WB(p, l, u) : p, h = f?.dataKey ?? r, g = f?.nameKey, _ = r && Array.isArray(m) && !Array.isArray(m[0]) && o === "axis" ? PL(m, r, i) : a(m, t, c, g);
+ var { dataDefinedOnItem: d, settings: f } = n, p = sDe(d, s), m = Array.isArray(p) ? GB(p, l, u) : p, h = f?.dataKey ?? r, g = f?.nameKey, _ = r && Array.isArray(m) && !Array.isArray(m[0]) && o === "axis" ? FL(m, r, i) : a(m, t, c, g);
return Array.isArray(_) ? _.forEach((t) => {
- var n = aDe(t), r = n?.name, i = n?.dataKey, a = n?.payload, o = HX(HX({}, f), {}, {
+ var n = oDe(t), r = n?.name, i = n?.dataKey, a = n?.payload, o = HX(HX({}, f), {}, {
name: r,
unit: n?.unit,
color: n?.color ?? f?.color,
fill: n?.fill ?? f?.fill
});
- e.push(gV({
+ e.push(_V({
tooltipEntrySettings: o,
dataKey: i,
payload: a,
- value: QB(a, i),
+ value: $B(a, i),
name: r == null ? void 0 : String(r)
}));
- }) : e.push(gV({
+ }) : e.push(_V({
tooltipEntrySettings: f,
dataKey: h,
payload: _,
- value: QB(_, h),
- name: QB(_, g) ?? f?.name
+ value: $B(_, h),
+ name: $B(_, g) ?? f?.name
})), e;
}, []);
}
@@ -59984,17 +60036,17 @@ var WX = (e, t, n, r, i, a, o) => {
$([(e) => e.graphicalItems.cartesianItems, (e) => e.graphicalItems.polarItems], (e, t) => [...e, ...t]),
OY,
$([LG, RG], pY)
-], hY, { memoizeOptions: { resultEqualityCheck: IG } }), sDe = $([KX], (e) => e.filter(PG)), qX = $([$([KX], yY, { memoizeOptions: { resultEqualityCheck: IG } }), BW], bY), cDe = $([
- sDe,
+], hY, { memoizeOptions: { resultEqualityCheck: IG } }), cDe = $([KX], (e) => e.filter(PG)), qX = $([$([KX], yY, { memoizeOptions: { resultEqualityCheck: IG } }), BW], bY), lDe = $([
+ cDe,
BW,
OY
], NG), JX = $([
qX,
OY,
KX
-], SY), YX = $([OY], NY), XX = $([YX, $([OY], (e) => e.allowDataOverflow)], KW), lDe = $([
+], SY), YX = $([OY], NY), XX = $([YX, $([OY], (e) => e.allowDataOverflow)], KW), uDe = $([
$([
- cDe,
+ lDe,
$([KX], (e) => e.filter(PG)),
oG,
sG
@@ -60002,23 +60054,23 @@ var WX = (e, t, n, r, i, a, o) => {
BW,
LG,
XX
-], MY), uDe = $([
+], MY), dDe = $([
qX,
OY,
$([KX], vY),
IY,
LG
-], RY, { memoizeOptions: { resultEqualityCheck: FG } }), dDe = $([$([
+], RY, { memoizeOptions: { resultEqualityCheck: FG } }), fDe = $([$([
zY,
LG,
RG
-], BY), LG], UY), fDe = $([$([
+], BY), LG], UY), pDe = $([$([
VY,
LG,
RG
], BY), LG], WY), ZX = $([
OY,
- xH,
+ SH,
qX,
JX,
oG,
@@ -60027,21 +60079,21 @@ var WX = (e, t, n, r, i, a, o) => {
OY,
YX,
XX,
- lDe,
uDe,
+ dDe,
$([
- dDe,
+ fDe,
$([$([
HY,
LG,
RG
], BY), LG], GY),
- fDe
+ pDe
], LY),
- xH,
+ SH,
LG
], KY)
-], qY), pDe = $([
+], qY), mDe = $([
OY,
ZX,
$([
@@ -60053,22 +60105,22 @@ var WX = (e, t, n, r, i, a, o) => {
], QY), QX = (e) => eX(e, LG(e), RG(e), !1), $X = $([OY, QX], hG), eZ = $([$([
OY,
GX,
- pDe,
+ mDe,
$X
], ZJ)], zG), tZ = $([
- xH,
+ SH,
OY,
GX,
eZ,
QX,
$([
- xH,
+ SH,
JX,
OY,
LG
], pX),
$([
- xH,
+ SH,
JX,
OY,
LG
@@ -60076,32 +60128,32 @@ var WX = (e, t, n, r, i, a, o) => {
LG
], (e, t, n, r, i, a, o, s) => {
if (t) {
- var { type: c } = t, l = eV(e, s);
+ var { type: c } = t, l = tV(e, s);
if (r) {
var u = n === "scaleBand" && r.bandwidth ? r.bandwidth() / 2 : 2, d = c === "category" && r.bandwidth ? r.bandwidth() / u : 0;
- return d = s === "angleAxis" && i != null && i?.length >= 2 ? EL(i[0] - i[1]) * 2 * d : d, l && o ? o.map((e, t) => {
+ return d = s === "angleAxis" && i != null && i?.length >= 2 ? DL(i[0] - i[1]) * 2 * d : d, l && o ? o.map((e, t) => {
var n = r.map(e);
- return GB(n) ? {
+ return KB(n) ? {
coordinate: n + d,
value: e,
index: t,
offset: d
} : null;
- }).filter(LL) : r.domain().map((e, t) => {
+ }).filter(RL) : r.domain().map((e, t) => {
var n = r.map(e);
- return GB(n) ? {
+ return KB(n) ? {
coordinate: n + d,
value: a ? a[e] : e,
index: t,
offset: d
} : null;
- }).filter(LL);
+ }).filter(RL);
}
}
}), nZ = $([
xX,
SX,
- IEe
+ LEe
], (e, t, n) => CX(n.shared, e, t)), rZ = (e) => e.tooltip.settings.trigger, iZ = (e) => e.tooltip.settings.defaultIndex, aZ = $([
BX,
nZ,
@@ -60114,22 +60166,22 @@ var WX = (e, t, n, r, i, a, o) => {
ZX
], IX), sZ = $([tZ, oZ], TX), cZ = $([aZ], (e) => {
if (e) return e.dataKey;
-}), mDe = $([aZ], (e) => {
+}), hDe = $([aZ], (e) => {
if (e) return e.graphicalItemId;
}), lZ = $([
BX,
nZ,
rZ,
iZ
-], RX), hDe = $([aZ, $([
- bV,
+], RX), gDe = $([aZ, $([
xV,
- xH,
- LV,
+ SV,
+ SH,
+ RV,
tZ,
iZ,
lZ
-], LX)], (e, t) => e != null && e.coordinate ? e.coordinate : t), gDe = $([aZ], (e) => e?.active ?? !1), _De = $([$([
+], LX)], (e, t) => e != null && e.coordinate ? e.coordinate : t), _De = $([aZ], (e) => e?.active ?? !1), vDe = $([$([
lZ,
oZ,
BW,
@@ -60159,26 +60211,26 @@ function dZ(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? uZ(Object(n), !0).forEach(function(t) {
- vDe(e, t, n[t]);
+ yDe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : uZ(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function vDe(e, t, n) {
- return (t = yDe(t)) in e ? Object.defineProperty(e, t, {
+function yDe(e, t, n) {
+ return (t = bDe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function yDe(e) {
- var t = bDe(e, "string");
+function bDe(e) {
+ var t = xDe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function bDe(e, t) {
+function xDe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -60188,9 +60240,9 @@ function bDe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var xDe = () => Q(OY), SDe = () => {
- var e = xDe(), t = Q(tZ), n = Q(eZ);
- return hV(!e || !n ? void 0 : dZ(dZ({}, e), {}, { scale: n }), t);
+var SDe = () => Q(OY), CDe = () => {
+ var e = SDe(), t = Q(tZ), n = Q(eZ);
+ return gV(!e || !n ? void 0 : dZ(dZ({}, e), {}, { scale: n }), t);
};
//#endregion
//#region node_modules/recharts/es6/util/getActiveCoordinate.js
@@ -60208,26 +60260,26 @@ function pZ(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? fZ(Object(n), !0).forEach(function(t) {
- CDe(e, t, n[t]);
+ wDe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : fZ(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function CDe(e, t, n) {
- return (t = wDe(t)) in e ? Object.defineProperty(e, t, {
+function wDe(e, t, n) {
+ return (t = TDe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function wDe(e) {
- var t = TDe(e, "string");
+function TDe(e) {
+ var t = EDe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function TDe(e, t) {
+function EDe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -60237,7 +60289,7 @@ function TDe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var EDe = (e, t, n, r) => {
+var DDe = (e, t, n, r) => {
var i = t.find((e) => e && e.index === n);
if (i) {
if (e === "horizontal") return {
@@ -60253,7 +60305,7 @@ var EDe = (e, t, n, r) => {
x: 0,
y: 0
};
-}, DDe = (e, t, n, r) => {
+}, ODe = (e, t, n, r) => {
var i = t.find((e) => e && e.index === n);
if (i) {
if (e === "centric") {
@@ -60283,7 +60335,7 @@ var EDe = (e, t, n, r) => {
y: 0
};
};
-function ODe(e, t) {
+function kDe(e, t) {
var { relativeX: n, relativeY: r } = e;
return n >= t.left && n <= t.left + t.width && r >= t.top && r <= t.top + t.height;
}
@@ -60293,9 +60345,9 @@ var mZ = (e, t, n, r, i) => {
if (r === "angleAxis" && i != null && Math.abs(Math.abs(i[1] - i[0]) - 360) <= 1e-6) for (var o = 0; o < a; o++) {
var s = o > 0 ? n[o - 1]?.coordinate : n[a - 1]?.coordinate, c = n[o]?.coordinate, l = o >= a - 1 ? n[0]?.coordinate : n[o + 1]?.coordinate, u = void 0;
if (s != null && c != null && l != null) {
- if (EL(c - s) !== EL(l - c)) {
+ if (DL(c - s) !== DL(l - c)) {
var d = [];
- if (EL(l - c) === EL(i[1] - i[0])) {
+ if (DL(l - c) === DL(i[1] - i[0])) {
u = l;
var f = c + i[1] - i[0];
d[0] = Math.min(f, (f + s) / 2), d[1] = Math.max(f, (f + s) / 2);
@@ -60320,7 +60372,7 @@ var mZ = (e, t, n, r, i) => {
}
}
return -1;
-}, hZ = () => Q(cG), gZ = (e, t) => t, _Z = (e, t, n) => n, vZ = (e, t, n, r) => r, kDe = $(tZ, (e) => kR(e, (e) => e.coordinate)), yZ = $([
+}, hZ = () => Q(cG), gZ = (e, t) => t, _Z = (e, t, n) => n, vZ = (e, t, n, r) => r, ADe = $(tZ, (e) => AR(e, (e) => e.coordinate)), yZ = $([
BX,
gZ,
_Z,
@@ -60330,7 +60382,7 @@ var mZ = (e, t, n, r, i) => {
qX,
kY,
ZX
-], IX), ADe = (e, t, n) => {
+], IX), jDe = (e, t, n) => {
if (t != null) {
var r = BX(e);
return t === "axis" ? n === "hover" ? r.axisInteraction.hover.dataKey : r.axisInteraction.click.dataKey : n === "hover" ? r.itemInteraction.hover.dataKey : r.itemInteraction.click.dataKey;
@@ -60341,14 +60393,14 @@ var mZ = (e, t, n, r, i) => {
_Z,
vZ
], RX), SZ = $([
- bV,
xV,
- xH,
- LV,
+ SV,
+ SH,
+ RV,
tZ,
vZ,
xZ
-], LX), jDe = $([yZ, SZ], (e, t) => e.coordinate ?? t), CZ = $([tZ, bZ], TX), MDe = $([
+], LX), MDe = $([yZ, SZ], (e, t) => e.coordinate ?? t), CZ = $([tZ, bZ], TX), NDe = $([
xZ,
bZ,
BW,
@@ -60356,39 +60408,39 @@ var mZ = (e, t, n, r, i) => {
CZ,
zX,
gZ
-], WX), NDe = $([yZ, bZ], (e, t) => ({
+], WX), PDe = $([yZ, bZ], (e, t) => ({
isActive: e.active && t != null,
activeIndex: t
-})), PDe = (e, t, n, r, i, a, o) => {
- if (!(!e || !n || !r || !i) && ODe(e, o)) {
- var s = mZ(vV(e, t), a, i, n, r), c = EDe(t, i, s, e);
+})), FDe = (e, t, n, r, i, a, o) => {
+ if (!(!e || !n || !r || !i) && kDe(e, o)) {
+ var s = mZ(yV(e, t), a, i, n, r), c = DDe(t, i, s, e);
return {
activeIndex: String(s),
activeCoordinate: c
};
}
-}, FDe = (e, t, n, r, i, a, o) => {
+}, IDe = (e, t, n, r, i, a, o) => {
if (!(!e || !r || !i || !a || !n)) {
- var s = YSe(e, n);
+ var s = XSe(e, n);
if (s) {
- var c = mZ(yV(s, t), o, a, r, i), l = DDe(t, a, c, s);
+ var c = mZ(bV(s, t), o, a, r, i), l = ODe(t, a, c, s);
return {
activeIndex: String(c),
activeCoordinate: l
};
}
}
-}, IDe = (e, t, n, r, i, a, o, s) => {
- if (!(!e || !t || !r || !i || !a)) return t === "horizontal" || t === "vertical" ? PDe(e, t, r, i, a, o, s) : FDe(e, t, n, r, i, a, o);
-}, LDe = $((e) => e.zIndex.zIndexMap, (e, t) => t, (e, t, n) => n, (e, t, n) => {
+}, LDe = (e, t, n, r, i, a, o, s) => {
+ if (!(!e || !t || !r || !i || !a)) return t === "horizontal" || t === "vertical" ? FDe(e, t, r, i, a, o, s) : IDe(e, t, n, r, i, a, o);
+}, RDe = $((e) => e.zIndex.zIndexMap, (e, t) => t, (e, t, n) => n, (e, t, n) => {
if (t != null) {
var r = e[t];
if (r != null) return n ? r.panoramaElement : r.element;
}
-}), RDe = $((e) => e.zIndex.zIndexMap, (e) => {
+}), zDe = $((e) => e.zIndex.zIndexMap, (e) => {
var t = Object.keys(e).map((e) => parseInt(e, 10)).concat(Object.values(fG));
return Array.from(new Set(t)).sort((e, t) => e - t);
-}, { memoizeOptions: { resultEqualityCheck: gCe } });
+}, { memoizeOptions: { resultEqualityCheck: _Ce } });
//#endregion
//#region node_modules/recharts/es6/state/zIndexSlice.js
function wZ(e, t) {
@@ -60405,26 +60457,26 @@ function TZ(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? wZ(Object(n), !0).forEach(function(t) {
- zDe(e, t, n[t]);
+ BDe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : wZ(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function zDe(e, t, n) {
- return (t = BDe(t)) in e ? Object.defineProperty(e, t, {
+function BDe(e, t, n) {
+ return (t = VDe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function BDe(e) {
- var t = VDe(e, "string");
+function VDe(e) {
+ var t = HDe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function VDe(e, t) {
+function HDe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -60434,17 +60486,17 @@ function VDe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var HDe = { zIndexMap: Object.values(fG).reduce((e, t) => TZ(TZ({}, e), {}, { [t]: {
+var UDe = { zIndexMap: Object.values(fG).reduce((e, t) => TZ(TZ({}, e), {}, { [t]: {
element: void 0,
panoramaElement: void 0,
consumers: 0
-} }), {}) }, UDe = new Set(Object.values(fG));
-function WDe(e) {
- return UDe.has(e);
+} }), {}) }, WDe = new Set(Object.values(fG));
+function GDe(e) {
+ return WDe.has(e);
}
-var EZ = oB({
+var EZ = sB({
name: "zIndex",
- initialState: HDe,
+ initialState: UDe,
reducers: {
registerZIndexPortal: {
reducer: (e, t) => {
@@ -60455,14 +60507,14 @@ var EZ = oB({
panoramaElement: void 0
};
},
- prepare: nB()
+ prepare: rB()
},
unregisterZIndexPortal: {
reducer: (e, t) => {
var { zIndex: n } = t.payload;
- e.zIndexMap[n] && (--e.zIndexMap[n].consumers, e.zIndexMap[n].consumers <= 0 && !WDe(n) && delete e.zIndexMap[n]);
+ e.zIndexMap[n] && (--e.zIndexMap[n].consumers, e.zIndexMap[n].consumers <= 0 && !GDe(n) && delete e.zIndexMap[n]);
},
- prepare: nB()
+ prepare: rB()
},
registerZIndexPortalElement: {
reducer: (e, t) => {
@@ -60473,29 +60525,29 @@ var EZ = oB({
panoramaElement: i ? bU(r) : void 0
};
},
- prepare: nB()
+ prepare: rB()
},
unregisterZIndexPortalElement: {
reducer: (e, t) => {
var { zIndex: n } = t.payload;
e.zIndexMap[n] && (t.payload.isPanorama ? e.zIndexMap[n].panoramaElement = void 0 : e.zIndexMap[n].element = void 0);
},
- prepare: nB()
+ prepare: rB()
}
}
-}), { registerZIndexPortal: GDe, unregisterZIndexPortal: KDe, registerZIndexPortalElement: qDe, unregisterZIndexPortalElement: JDe } = EZ.actions, YDe = EZ.reducer;
+}), { registerZIndexPortal: KDe, unregisterZIndexPortal: qDe, registerZIndexPortalElement: JDe, unregisterZIndexPortalElement: YDe } = EZ.actions, XDe = EZ.reducer;
//#endregion
//#region node_modules/recharts/es6/zIndex/ZIndexLayer.js
function DZ(e) {
- var { zIndex: t, children: n } = e, r = EH() && t !== void 0 && t !== 0, i = VV(), a = xR();
- (0, R.useLayoutEffect)(() => r ? (a(GDe({ zIndex: t })), () => {
- a(KDe({ zIndex: t }));
- }) : RL, [
+ var { zIndex: t, children: n } = e, r = DH() && t !== void 0 && t !== 0, i = HV(), a = SR();
+ (0, R.useLayoutEffect)(() => r ? (a(KDe({ zIndex: t })), () => {
+ a(qDe({ zIndex: t }));
+ }) : zL, [
a,
t,
r
]);
- var o = Q((e) => LDe(e, t, i));
+ var o = Q((e) => RDe(e, t, i));
return r ? o ? /*#__PURE__*/ (0, ze.createPortal)(n, o) : null : n;
}
//#endregion
@@ -60523,26 +60575,26 @@ function AZ(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? kZ(Object(n), !0).forEach(function(t) {
- XDe(e, t, n[t]);
+ ZDe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : kZ(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function XDe(e, t, n) {
- return (t = ZDe(t)) in e ? Object.defineProperty(e, t, {
+function ZDe(e, t, n) {
+ return (t = QDe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function ZDe(e) {
- var t = QDe(e, "string");
+function QDe(e) {
+ var t = $De(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function QDe(e, t) {
+function $De(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -60552,17 +60604,17 @@ function QDe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function $De(e) {
+function eOe(e) {
var { cursor: t, cursorComp: n, cursorProps: r } = e;
return /*#__PURE__*/ (0, R.isValidElement)(t) ? /*#__PURE__*/ (0, R.cloneElement)(t, r) : /*#__PURE__*/ (0, R.createElement)(n, r);
}
-function eOe(e) {
+function tOe(e) {
var { coordinate: t, payload: n, index: r, offset: i, tooltipAxisBandSize: a, layout: o, cursor: s, tooltipEventType: c, chartName: l } = e, u = t, d = n, f = r;
if (!s || !u || l !== "ScatterChart" && c !== "axis") return null;
var p, m, h;
- if (l === "ScatterChart") p = u, m = $xe, h = fG.cursorLine;
- else if (l === "BarChart") p = eSe(o, u, i, a), m = EW, h = fG.cursorRectangle;
- else if (o === "radial" && WL(u)) {
+ if (l === "ScatterChart") p = u, m = eSe, h = fG.cursorLine;
+ else if (l === "BarChart") p = tSe(o, u, i, a), m = EW, h = fG.cursorRectangle;
+ else if (o === "radial" && GL(u)) {
var { cx: g, cy: _, radius: v, startAngle: y, endAngle: b } = MW(u);
p = {
cx: g,
@@ -60572,24 +60624,24 @@ function eOe(e) {
innerRadius: v,
outerRadius: v
}, m = LW, h = fG.cursorLine;
- } else p = { points: oCe(o, u, i) }, m = $U, h = fG.cursorLine;
+ } else p = { points: sCe(o, u, i) }, m = $U, h = fG.cursorLine;
var x = typeof s == "object" && "className" in s ? s.className : void 0, S = AZ(AZ(AZ(AZ({
stroke: "#ccc",
pointerEvents: "none"
- }, i), p), yI(s)), {}, {
+ }, i), p), bI(s)), {}, {
payload: d,
payloadIndex: f,
className: ja("recharts-tooltip-cursor", x)
});
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: e.zIndex ?? h }, /*#__PURE__*/ R.createElement($De, {
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: e.zIndex ?? h }, /*#__PURE__*/ R.createElement(eOe, {
cursor: s,
cursorComp: m,
cursorProps: S
}));
}
-function tOe(e) {
- var t = SDe(), n = _H(), r = SH(), i = hZ();
- return t == null || n == null || r == null || i == null ? null : /*#__PURE__*/ R.createElement(eOe, OZ({}, e, {
+function nOe(e) {
+ var t = CDe(), n = vH(), r = CH(), i = hZ();
+ return t == null || n == null || r == null || i == null ? null : /*#__PURE__*/ R.createElement(tOe, OZ({}, e, {
offset: n,
layout: r,
tooltipAxisBandSize: t,
@@ -60598,7 +60650,7 @@ function tOe(e) {
}
//#endregion
//#region node_modules/recharts/es6/context/tooltipPortalContext.js
-var jZ = /*#__PURE__*/ (0, R.createContext)(null), nOe = () => (0, R.useContext)(jZ), rOe = (/* @__PURE__ */ ke((/* @__PURE__ */ Ee(((e, t) => {
+var jZ = /*#__PURE__*/ (0, R.createContext)(null), rOe = () => (0, R.useContext)(jZ), iOe = (/* @__PURE__ */ ke((/* @__PURE__ */ Ee(((e, t) => {
var n = Object.prototype.hasOwnProperty, r = "~";
function i() {}
Object.create && (i.prototype = Object.create(null), new i().__proto__ || (r = !1));
@@ -60685,12 +60737,12 @@ var jZ = /*#__PURE__*/ (0, R.createContext)(null), nOe = () => (0, R.useContext)
var t;
return e ? (t = r ? r + e : e, this._events[t] && s(this, t)) : (this._events = new i(), this._eventsCount = 0), this;
}, c.prototype.off = c.prototype.removeListener, c.prototype.addListener = c.prototype.on, c.prefixed = r, c.EventEmitter = c, t !== void 0 && (t.exports = c);
-})))(), 1)).default, MZ = new rOe(), NZ = "recharts.syncEvent.tooltip", PZ = "recharts.syncEvent.brush", FZ = (e, t) => {
+})))(), 1)).default, MZ = new iOe(), NZ = "recharts.syncEvent.tooltip", PZ = "recharts.syncEvent.brush", FZ = (e, t) => {
if (t && Array.isArray(e)) {
var n = Number.parseInt(t, 10);
- if (!DL(n)) return e[n];
+ if (!OL(n)) return e[n];
}
-}, IZ = oB({
+}, IZ = sB({
name: "options",
initialState: {
chartName: "",
@@ -60701,13 +60753,13 @@ var jZ = /*#__PURE__*/ (0, R.createContext)(null), nOe = () => (0, R.useContext)
reducers: { createEventEmitter: (e) => {
e.eventEmitter ??= Symbol("rechartsEventEmitter");
} }
-}), iOe = IZ.reducer, { createEventEmitter: aOe } = IZ.actions;
+}), aOe = IZ.reducer, { createEventEmitter: oOe } = IZ.actions;
//#endregion
//#region node_modules/recharts/es6/synchronisation/syncSelectors.js
-function oOe(e) {
+function sOe(e) {
return e.tooltip.syncInteraction;
}
-var LZ = oB({
+var LZ = sB({
name: "chartData",
initialState: {
chartData: void 0,
@@ -60731,7 +60783,7 @@ var LZ = oB({
n != null && (e.dataStartIndex = n), r != null && (e.dataEndIndex = r);
}
}
-}), { setChartData: RZ, setDataStartEndIndexes: sOe, setComputedData: cOe } = LZ.actions, lOe = LZ.reducer, uOe = ["x", "y"];
+}), { setChartData: RZ, setDataStartEndIndexes: cOe, setComputedData: lOe } = LZ.actions, uOe = LZ.reducer, dOe = ["x", "y"];
function zZ(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
@@ -60746,26 +60798,26 @@ function BZ(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? zZ(Object(n), !0).forEach(function(t) {
- dOe(e, t, n[t]);
+ fOe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : zZ(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function dOe(e, t, n) {
- return (t = fOe(t)) in e ? Object.defineProperty(e, t, {
+function fOe(e, t, n) {
+ return (t = pOe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function fOe(e) {
- var t = pOe(e, "string");
+function pOe(e) {
+ var t = mOe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function pOe(e, t) {
+function mOe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -60775,16 +60827,16 @@ function pOe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function mOe(e, t) {
+function hOe(e, t) {
if (e == null) return {};
- var n, r, i = hOe(e, t);
+ var n, r, i = gOe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function hOe(e, t) {
+function gOe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -60793,16 +60845,16 @@ function hOe(e, t) {
}
return n;
}
-function gOe() {
- var e = Q(lG), t = Q(dG), n = xR(), r = Q(uG), i = Q(tZ), a = SH(), o = hH(), s = Q((e) => e.rootProps.className);
+function _Oe() {
+ var e = Q(lG), t = Q(dG), n = SR(), r = Q(uG), i = Q(tZ), a = CH(), o = gH(), s = Q((e) => e.rootProps.className);
(0, R.useEffect)(() => {
- if (e == null) return RL;
+ if (e == null) return zL;
var s = (s, c, l) => {
if (t !== l && e === s) {
if (r === "index") {
var u;
if (o && c != null && (u = c.payload) != null && u.coordinate && c.payload.sourceViewBox) {
- var d = c.payload.coordinate, { x: f, y: p } = d, m = mOe(d, uOe), { x: h, y: g, width: _, height: v } = c.payload.sourceViewBox, y = BZ(BZ({}, m), {}, {
+ var d = c.payload.coordinate, { x: f, y: p } = d, m = hOe(d, dOe), { x: h, y: g, width: _, height: v } = c.payload.sourceViewBox, y = BZ(BZ({}, m), {}, {
x: o.x + (_ ? (f - h) / _ : 0) * o.width,
y: o.y + (v ? (p - g) / v : 0) * o.height
});
@@ -60863,12 +60915,12 @@ function gOe() {
o
]);
}
-function _Oe() {
- var e = Q(lG), t = Q(dG), n = xR();
+function vOe() {
+ var e = Q(lG), t = Q(dG), n = SR();
(0, R.useEffect)(() => {
- if (e == null) return RL;
+ if (e == null) return zL;
var r = (r, i, a) => {
- t !== a && e === r && n(sOe(i));
+ t !== a && e === r && n(cOe(i));
};
return MZ.on(PZ, r), () => {
MZ.off(PZ, r);
@@ -60879,14 +60931,14 @@ function _Oe() {
e
]);
}
-function vOe() {
- var e = xR();
+function yOe() {
+ var e = SR();
(0, R.useEffect)(() => {
- e(aOe());
- }, [e]), gOe(), _Oe();
+ e(oOe());
+ }, [e]), _Oe(), vOe();
}
-function yOe(e, t, n, r, i, a) {
- var o = Q((n) => ADe(n, e, t)), s = Q(mDe), c = Q(dG), l = Q(lG), u = Q(uG), d = Q(oOe)?.active, f = hH();
+function bOe(e, t, n, r, i, a) {
+ var o = Q((n) => jDe(n, e, t)), s = Q(hDe), c = Q(dG), l = Q(lG), u = Q(uG), d = Q(sOe)?.active, f = gH();
(0, R.useEffect)(() => {
if (!d && l != null && c != null) {
var e = jX({
@@ -60930,26 +60982,26 @@ function HZ(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? VZ(Object(n), !0).forEach(function(t) {
- bOe(e, t, n[t]);
+ xOe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : VZ(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function bOe(e, t, n) {
- return (t = xOe(t)) in e ? Object.defineProperty(e, t, {
+function xOe(e, t, n) {
+ return (t = SOe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function xOe(e) {
- var t = SOe(e, "string");
+function SOe(e) {
+ var t = COe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function SOe(e, t) {
+function COe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -60959,13 +61011,13 @@ function SOe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function COe(e) {
+function wOe(e) {
return e.dataKey;
}
-function wOe(e, t) {
- return /*#__PURE__*/ R.isValidElement(e) ? /*#__PURE__*/ R.cloneElement(e, t) : typeof e == "function" ? /*#__PURE__*/ R.createElement(e, t) : /*#__PURE__*/ R.createElement(kxe, t);
+function TOe(e, t) {
+ return /*#__PURE__*/ R.isValidElement(e) ? /*#__PURE__*/ R.cloneElement(e, t) : typeof e == "function" ? /*#__PURE__*/ R.createElement(e, t) : /*#__PURE__*/ R.createElement(Axe, t);
}
-var UZ = [], TOe = {
+var UZ = [], EOe = {
allowEscapeViewBox: {
x: !1,
y: !1
@@ -60991,10 +61043,10 @@ var UZ = [], TOe = {
useTranslate3d: !1,
wrapperStyle: {}
};
-function EOe(e) {
- var t = JL(e, TOe), { active: n, allowEscapeViewBox: r, animationDuration: i, animationEasing: a, content: o, filterNull: s, isAnimationActive: c, offset: l, payloadUniqBy: u, position: d, reverseDirection: f, useTranslate3d: p, wrapperStyle: m, cursor: h, shared: g, trigger: _, defaultIndex: v, portal: y, axisId: b } = t, x = xR(), S = typeof v == "number" ? String(v) : v;
+function DOe(e) {
+ var t = YL(e, EOe), { active: n, allowEscapeViewBox: r, animationDuration: i, animationEasing: a, content: o, filterNull: s, isAnimationActive: c, offset: l, payloadUniqBy: u, position: d, reverseDirection: f, useTranslate3d: p, wrapperStyle: m, cursor: h, shared: g, trigger: _, defaultIndex: v, portal: y, axisId: b } = t, x = SR(), S = typeof v == "number" ? String(v) : v;
(0, R.useEffect)(() => {
- x(BEe({
+ x(VEe({
shared: g,
trigger: _,
axisId: b,
@@ -61009,12 +61061,12 @@ function EOe(e) {
n,
S
]);
- var C = hH(), w = UU(), T = FEe(g), { activeIndex: E, isActive: D } = Q((e) => NDe(e, T, _, S)) ?? {}, O = Q((e) => MDe(e, T, _, S)), k = Q((e) => CZ(e, T, _, S)), A = Q((e) => jDe(e, T, _, S)), j = O, M = nOe(), N = n ?? D ?? !1, [P, ee] = MR([j, N]), F = T === "axis" ? k : void 0;
- yOe(T, _, A, F, E, N);
+ var C = gH(), w = UU(), T = IEe(g), { activeIndex: E, isActive: D } = Q((e) => PDe(e, T, _, S)) ?? {}, O = Q((e) => NDe(e, T, _, S)), k = Q((e) => CZ(e, T, _, S)), A = Q((e) => MDe(e, T, _, S)), j = O, M = rOe(), N = n ?? D ?? !1, [P, ee] = NR([j, N]), F = T === "axis" ? k : void 0;
+ bOe(T, _, A, F, E, N);
var I = y ?? M;
if (I == null || C == null || T == null) return null;
var te = j ?? UZ;
- N || (te = UZ), s && te.length && (te = yR(te.filter((e) => e.value != null && (e.hide !== !0 || t.includeHidden)), u, COe));
+ N || (te = UZ), s && te.length && (te = bR(te.filter((e) => e.value != null && (e.hide !== !0 || t.includeHidden)), u, wOe));
var ne = te.length > 0, re = HZ(HZ({}, t), {}, {
payload: te,
label: F,
@@ -61022,7 +61074,7 @@ function EOe(e) {
activeIndex: E,
coordinate: A,
accessibilityLayer: w
- }), ie = /*#__PURE__*/ R.createElement(zxe, {
+ }), ie = /*#__PURE__*/ R.createElement(Bxe, {
allowEscapeViewBox: r,
animationDuration: i,
animationEasing: a,
@@ -61039,8 +61091,8 @@ function EOe(e) {
lastBoundingBox: P,
innerRef: ee,
hasPortalFromProps: !!y
- }, wOe(o, re));
- return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ (0, ze.createPortal)(ie, I), N && /*#__PURE__*/ R.createElement(tOe, {
+ }, TOe(o, re));
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ (0, ze.createPortal)(ie, I), N && /*#__PURE__*/ R.createElement(nOe, {
cursor: h,
tooltipEventType: T,
coordinate: A,
@@ -61054,19 +61106,19 @@ var WZ = (e) => null;
WZ.displayName = "Cell";
//#endregion
//#region node_modules/recharts/es6/util/LRUCache.js
-function DOe(e, t, n) {
- return (t = OOe(t)) in e ? Object.defineProperty(e, t, {
+function OOe(e, t, n) {
+ return (t = kOe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function OOe(e) {
- var t = kOe(e, "string");
+function kOe(e) {
+ var t = AOe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function kOe(e, t) {
+function AOe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -61076,9 +61128,9 @@ function kOe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var AOe = class {
+var jOe = class {
constructor(e) {
- DOe(this, "cache", /* @__PURE__ */ new Map()), this.maxSize = e;
+ OOe(this, "cache", /* @__PURE__ */ new Map()), this.maxSize = e;
}
get(e) {
var t = this.cache.get(e);
@@ -61111,30 +61163,30 @@ function GZ(e, t) {
}
return n;
}
-function jOe(e) {
+function MOe(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? GZ(Object(n), !0).forEach(function(t) {
- MOe(e, t, n[t]);
+ NOe(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : GZ(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function MOe(e, t, n) {
- return (t = NOe(t)) in e ? Object.defineProperty(e, t, {
+function NOe(e, t, n) {
+ return (t = POe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function NOe(e) {
- var t = POe(e, "string");
+function POe(e) {
+ var t = FOe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function POe(e, t) {
+function FOe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -61144,10 +61196,10 @@ function POe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var KZ = jOe({}, {
+var KZ = MOe({}, {
cacheSize: 2e3,
enableCache: !0
-}), qZ = new AOe(KZ.cacheSize), FOe = {
+}), qZ = new jOe(KZ.cacheSize), IOe = {
position: "absolute",
top: "-20000px",
left: 0,
@@ -61156,13 +61208,13 @@ var KZ = jOe({}, {
border: "none",
whiteSpace: "pre"
}, JZ = "recharts_measurement_span";
-function IOe(e, t) {
+function LOe(e, t) {
return `${e}|${t.fontSize || ""}|${t.fontFamily || ""}|${t.fontWeight || ""}|${t.fontStyle || ""}|${t.letterSpacing || ""}|${t.textTransform || ""}`;
}
var YZ = (e, t) => {
try {
var n = document.getElementById(JZ);
- n || (n = document.createElement("span"), n.setAttribute("id", JZ), n.setAttribute("aria-hidden", "true"), document.body.appendChild(n)), Object.assign(n.style, FOe, t), n.textContent = `${e}`;
+ n || (n = document.createElement("span"), n.setAttribute("id", JZ), n.setAttribute("aria-hidden", "true"), document.body.appendChild(n)), Object.assign(n.style, IOe, t), n.textContent = `${e}`;
var r = n.getBoundingClientRect();
return {
width: r.width,
@@ -61181,24 +61233,24 @@ var YZ = (e, t) => {
height: 0
};
if (!KZ.enableCache) return YZ(e, t);
- var n = IOe(e, t), r = qZ.get(n);
+ var n = LOe(e, t), r = qZ.get(n);
if (r) return r;
var i = YZ(e, t);
return qZ.set(n, i), i;
}, ZZ;
-function LOe(e, t, n) {
- return (t = ROe(t)) in e ? Object.defineProperty(e, t, {
+function ROe(e, t, n) {
+ return (t = zOe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function ROe(e) {
- var t = zOe(e, "string");
+function zOe(e) {
+ var t = BOe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function zOe(e, t) {
+function BOe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -61208,7 +61260,7 @@ function zOe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var QZ = /(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/, $Z = /(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/, BOe = /^(px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q)$/, VOe = /(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/, HOe = {
+var QZ = /(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/, $Z = /(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/, VOe = /^(px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q)$/, HOe = /(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/, UOe = {
cm: 96 / 2.54,
mm: 96 / 25.4,
pt: 96 / 72,
@@ -61216,7 +61268,7 @@ var QZ = /(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/, $Z = /(
in: 96,
Q: 96 / 101.6,
px: 1
-}, UOe = [
+}, WOe = [
"cm",
"mm",
"pt",
@@ -61225,20 +61277,20 @@ var QZ = /(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/, $Z = /(
"Q",
"px"
];
-function WOe(e) {
- return UOe.includes(e);
+function GOe(e) {
+ return WOe.includes(e);
}
var eQ = "NaN";
-function GOe(e, t) {
- return e * HOe[t];
+function KOe(e, t) {
+ return e * UOe[t];
}
var tQ = class e {
static parse(t) {
- var [, n, r] = VOe.exec(t) ?? [];
+ var [, n, r] = HOe.exec(t) ?? [];
return n == null ? e.NaN : new e(parseFloat(n), r ?? "");
}
constructor(e, t) {
- this.num = e, this.unit = t, this.num = e, this.unit = t, DL(e) && (this.unit = ""), t !== "" && !BOe.test(t) && (this.num = NaN, this.unit = ""), WOe(t) && (this.num = GOe(e, t), this.unit = "px");
+ this.num = e, this.unit = t, this.num = e, this.unit = t, OL(e) && (this.unit = ""), t !== "" && !VOe.test(t) && (this.num = NaN, this.unit = ""), GOe(t) && (this.num = KOe(e, t), this.unit = "px");
}
add(t) {
return this.unit === t.unit ? new e(this.num + t.num, this.unit) : new e(NaN, "");
@@ -61256,10 +61308,10 @@ var tQ = class e {
return `${this.num}${this.unit}`;
}
isNaN() {
- return DL(this.num);
+ return OL(this.num);
}
};
-ZZ = tQ, LOe(tQ, "NaN", new ZZ(NaN, ""));
+ZZ = tQ, ROe(tQ, "NaN", new ZZ(NaN, ""));
function nQ(e) {
if (e == null || e.includes(eQ)) return eQ;
for (var t = e; t.includes("*") || t.includes("/");) {
@@ -61275,31 +61327,31 @@ function nQ(e) {
return t;
}
var rQ = /\(([^()]*)\)/;
-function KOe(e) {
+function qOe(e) {
for (var t = e, n; (n = rQ.exec(t)) != null;) {
var [, r] = n;
t = t.replace(rQ, nQ(r));
}
return t;
}
-function qOe(e) {
+function JOe(e) {
var t = e.replace(/\s+/g, "");
- return t = KOe(t), t = nQ(t), t;
+ return t = qOe(t), t = nQ(t), t;
}
-function JOe(e) {
+function YOe(e) {
try {
- return qOe(e);
+ return JOe(e);
} catch {
return eQ;
}
}
function iQ(e) {
- var t = JOe(e.slice(5, -1));
+ var t = YOe(e.slice(5, -1));
return t === eQ ? "" : t;
}
//#endregion
//#region node_modules/recharts/es6/component/Text.js
-var YOe = [
+var XOe = [
"x",
"y",
"lineHeight",
@@ -61308,7 +61360,7 @@ var YOe = [
"scaleToFit",
"textAnchor",
"verticalAnchor"
-], XOe = [
+], ZOe = [
"dx",
"dy",
"angle",
@@ -61326,14 +61378,14 @@ function aQ() {
}
function oQ(e, t) {
if (e == null) return {};
- var n, r, i = ZOe(e, t);
+ var n, r, i = QOe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function ZOe(e, t) {
+function QOe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -61346,7 +61398,7 @@ var sQ = /[ \f\n\r\t\v\u2028\u2029]+/, cQ = (e) => {
var { children: t, breakAll: n, style: r } = e;
try {
var i = [];
- return FL(t) || (i = n ? t.toString().split("") : t.toString().split(sQ)), {
+ return IL(t) || (i = n ? t.toString().split("") : t.toString().split(sQ)), {
wordsWithComputedWidth: i.map((e) => ({
word: e,
width: XZ(e, r).width
@@ -61360,8 +61412,8 @@ var sQ = /[ \f\n\r\t\v\u2028\u2029]+/, cQ = (e) => {
function lQ(e) {
return e === "start" || e === "middle" || e === "end" || e === "inherit";
}
-function QOe(e) {
- return FL(e) || typeof e == "string" || typeof e == "number" || typeof e == "boolean";
+function $Oe(e) {
+ return IL(e) || typeof e == "string" || typeof e == "number" || typeof e == "boolean";
}
var uQ = (e, t, n, r) => e.reduce((e, i) => {
var { word: a, width: o } = i, s = e[e.length - 1];
@@ -61374,16 +61426,16 @@ var uQ = (e, t, n, r) => e.reduce((e, i) => {
e.push(c);
}
return e;
-}, []), dQ = (e) => e.reduce((e, t) => e.width > t.width ? e : t), $Oe = "…", fQ = (e, t, n, r, i, a, o, s) => {
+}, []), dQ = (e) => e.reduce((e, t) => e.width > t.width ? e : t), eke = "…", fQ = (e, t, n, r, i, a, o, s) => {
var c = cQ({
breakAll: n,
style: r,
- children: e.slice(0, t) + $Oe
+ children: e.slice(0, t) + eke
});
if (!c) return [!1, []];
var l = uQ(c.wordsWithComputedWidth, a, o, s);
return [l.length > i || dQ(l).width > Number(a), l];
-}, eke = (e, t, n, r, i) => {
+}, tke = (e, t, n, r, i) => {
var { maxLines: a, children: o, style: s, breakAll: c } = e, l = Z(a), u = String(o), d = uQ(t, r, n, i);
if (!l || i || !(d.length > a || dQ(d).width > Number(r))) return d;
for (var f = 0, p = u.length - 1, m = 0, h; f <= p && m <= u.length - 1;) {
@@ -61396,9 +61448,9 @@ var uQ = (e, t, n, r) => e.reduce((e, i) => {
}
return h || d;
}, pQ = (e) => [{
- words: FL(e) ? [] : e.toString().split(sQ),
+ words: IL(e) ? [] : e.toString().split(sQ),
width: void 0
-}], tke = (e) => {
+}], nke = (e) => {
var { width: t, scaleToFit: n, children: r, style: i, breakAll: a, maxLines: o } = e;
if ((t || n) && !zU.isSsr) {
var s, c, l = cQ({
@@ -61410,7 +61462,7 @@ var uQ = (e, t, n, r) => e.reduce((e, i) => {
var { wordsWithComputedWidth: u, spaceWidth: d } = l;
s = u, c = d;
} else return pQ(r);
- return eke({
+ return tke({
breakAll: a,
children: r,
maxLines: o,
@@ -61418,7 +61470,7 @@ var uQ = (e, t, n, r) => e.reduce((e, i) => {
}, s, c, t, !!n);
}
return pQ(r);
-}, mQ = "#808080", nke = {
+}, mQ = "#808080", rke = {
angle: 0,
breakAll: !1,
capHeight: "0.71em",
@@ -61430,7 +61482,7 @@ var uQ = (e, t, n, r) => e.reduce((e, i) => {
x: 0,
y: 0
}, hQ = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var n = JL(e, nke), { x: r, y: i, lineHeight: a, capHeight: o, fill: s, scaleToFit: c, textAnchor: l, verticalAnchor: u } = n, d = oQ(n, YOe), f = (0, R.useMemo)(() => tke({
+ var n = YL(e, rke), { x: r, y: i, lineHeight: a, capHeight: o, fill: s, scaleToFit: c, textAnchor: l, verticalAnchor: u } = n, d = oQ(n, XOe), f = (0, R.useMemo)(() => nke({
breakAll: d.breakAll,
children: d.children,
maxLines: d.maxLines,
@@ -61444,10 +61496,10 @@ var uQ = (e, t, n, r) => e.reduce((e, i) => {
c,
d.style,
d.width
- ]), { dx: p, dy: m, angle: h, className: g, breakAll: _ } = d, v = oQ(d, XOe);
- if (!kL(r) || !kL(i) || f.length === 0) return null;
+ ]), { dx: p, dy: m, angle: h, className: g, breakAll: _ } = d, v = oQ(d, ZOe);
+ if (!AL(r) || !AL(i) || f.length === 0) return null;
var y = Number(r) + (Z(p) ? p : 0), b = Number(i) + (Z(m) ? m : 0);
- if (!GB(y) || !GB(b)) return null;
+ if (!KB(y) || !KB(b)) return null;
var x;
switch (u) {
case "start":
@@ -61463,7 +61515,7 @@ var uQ = (e, t, n, r) => e.reduce((e, i) => {
var w = C.width, { width: T } = d;
S.push(`scale(${Z(T) && Z(w) ? T / w : 1})`);
}
- return h && S.push(`rotate(${h}, ${y}, ${b})`), S.length && (v.transform = S.join(" ")), /*#__PURE__*/ R.createElement("text", aQ({}, bI(v), {
+ return h && S.push(`rotate(${h}, ${y}, ${b})`), S.length && (v.transform = S.join(" ")), /*#__PURE__*/ R.createElement("text", aQ({}, xI(v), {
ref: t,
x: y,
y: b,
@@ -61496,26 +61548,26 @@ function _Q(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? gQ(Object(n), !0).forEach(function(t) {
- rke(e, t, n[t]);
+ ike(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : gQ(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function rke(e, t, n) {
- return (t = ike(t)) in e ? Object.defineProperty(e, t, {
+function ike(e, t, n) {
+ return (t = ake(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function ike(e) {
- var t = ake(e, "string");
+function ake(e) {
+ var t = oke(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function ake(e, t) {
+function oke(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -61525,8 +61577,8 @@ function ake(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var oke = (e) => {
- var { viewBox: t, position: n, offset: r = 0, parentViewBox: i, clamp: a } = e, { x: o, y: s, height: c, upperWidth: l, lowerWidth: u } = mH(t), d = o, f = o + (l - u) / 2, p = (d + f) / 2, m = (l + u) / 2, h = d + l / 2, g = c >= 0 ? 1 : -1, _ = g * r, v = g > 0 ? "end" : "start", y = g > 0 ? "start" : "end", b = l >= 0 ? 1 : -1, x = b * r, S = b > 0 ? "end" : "start", C = b > 0 ? "start" : "end", w = i;
+var ske = (e) => {
+ var { viewBox: t, position: n, offset: r = 0, parentViewBox: i, clamp: a } = e, { x: o, y: s, height: c, upperWidth: l, lowerWidth: u } = hH(t), d = o, f = o + (l - u) / 2, p = (d + f) / 2, m = (l + u) / 2, h = d + l / 2, g = c >= 0 ? 1 : -1, _ = g * r, v = g > 0 ? "end" : "start", y = g > 0 ? "start" : "end", b = l >= 0 ? 1 : -1, x = b * r, S = b > 0 ? "end" : "start", C = b > 0 ? "start" : "end", w = i;
if (n === "top") {
var T = {
x: d + l / 2,
@@ -61607,9 +61659,9 @@ var oke = (e) => {
y: s + c - _,
horizontalAnchor: S,
verticalAnchor: v
- }, k) : n && typeof n == "object" && (Z(n.x) || OL(n.x)) && (Z(n.y) || OL(n.y)) ? _Q({
- x: o + jL(n.x, m),
- y: s + jL(n.y, c),
+ }, k) : n && typeof n == "object" && (Z(n.x) || kL(n.x)) && (Z(n.y) || kL(n.y)) ? _Q({
+ x: o + ML(n.x, m),
+ y: s + ML(n.y, c),
horizontalAnchor: "end",
verticalAnchor: "end"
}, k) : _Q({
@@ -61618,17 +61670,17 @@ var oke = (e) => {
horizontalAnchor: "middle",
verticalAnchor: "middle"
}, k);
-}, ske = ["labelRef"], cke = ["content"];
+}, cke = ["labelRef"], lke = ["content"];
function vQ(e, t) {
if (e == null) return {};
- var n, r, i = lke(e, t);
+ var n, r, i = uke(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function lke(e, t) {
+function uke(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -61651,26 +61703,26 @@ function bQ(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
t % 2 ? yQ(Object(n), !0).forEach(function(t) {
- uke(e, t, n[t]);
+ dke(e, t, n[t]);
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : yQ(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function uke(e, t, n) {
- return (t = xQ(t)) in e ? Object.defineProperty(e, t, {
+function dke(e, t, n) {
+ return (t = fke(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function xQ(e) {
- var t = dke(e, "string");
+function fke(e) {
+ var t = pke(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function dke(e, t) {
+function pke(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -61680,16 +61732,16 @@ function dke(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function SQ() {
- return SQ = Object.assign ? Object.assign.bind() : function(e) {
+function xQ() {
+ return xQ = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, SQ.apply(null, arguments);
+ }, xQ.apply(null, arguments);
}
-var CQ = /*#__PURE__*/ (0, R.createContext)(null), wQ = (e) => {
+var SQ = /*#__PURE__*/ (0, R.createContext)(null), CQ = (e) => {
var { x: t, y: n, upperWidth: r, lowerWidth: i, width: a, height: o, children: s } = e, c = (0, R.useMemo)(() => ({
x: t,
y: n,
@@ -61705,11 +61757,11 @@ var CQ = /*#__PURE__*/ (0, R.createContext)(null), wQ = (e) => {
a,
o
]);
- return /*#__PURE__*/ R.createElement(CQ.Provider, { value: c }, s);
-}, TQ = () => {
- var e = (0, R.useContext)(CQ), t = hH();
- return e || (t ? mH(t) : void 0);
-}, EQ = /*#__PURE__*/ (0, R.createContext)(null), fke = (e) => {
+ return /*#__PURE__*/ R.createElement(SQ.Provider, { value: c }, s);
+}, wQ = () => {
+ var e = (0, R.useContext)(SQ), t = gH();
+ return e || (t ? hH(t) : void 0);
+}, TQ = /*#__PURE__*/ (0, R.createContext)(null), mke = (e) => {
var { cx: t, cy: n, innerRadius: r, outerRadius: i, startAngle: a, endAngle: o, clockWise: s, children: c } = e, l = (0, R.useMemo)(() => ({
cx: t,
cy: n,
@@ -61727,15 +61779,15 @@ var CQ = /*#__PURE__*/ (0, R.createContext)(null), wQ = (e) => {
o,
s
]);
- return /*#__PURE__*/ R.createElement(EQ.Provider, { value: l }, c);
-}, DQ = () => {
- var e = (0, R.useContext)(EQ), t = Q(kG);
+ return /*#__PURE__*/ R.createElement(TQ.Provider, { value: l }, c);
+}, EQ = () => {
+ var e = (0, R.useContext)(TQ), t = Q(kG);
return e || t;
-}, pke = (e) => {
- var { value: t, formatter: n } = e, r = FL(e.children) ? t : e.children;
+}, hke = (e) => {
+ var { value: t, formatter: n } = e, r = IL(e.children) ? t : e.children;
return typeof n == "function" ? n(r) : r;
-}, OQ = (e) => e != null && typeof e == "function", mke = (e, t) => EL(t - e) * Math.min(Math.abs(t - e), 360), hke = (e, t, n, r, i) => {
- var { offset: a, className: o } = e, { cx: s, cy: c, innerRadius: l, outerRadius: u, startAngle: d, endAngle: f, clockWise: p } = i, m = (l + u) / 2, h = mke(d, f), g = h >= 0 ? 1 : -1, _, v;
+}, DQ = (e) => e != null && typeof e == "function", gke = (e, t) => DL(t - e) * Math.min(Math.abs(t - e), 360), _ke = (e, t, n, r, i) => {
+ var { offset: a, className: o } = e, { cx: s, cy: c, innerRadius: l, outerRadius: u, startAngle: d, endAngle: f, clockWise: p } = i, m = (l + u) / 2, h = gke(d, f), g = h >= 0 ? 1 : -1, _, v;
switch (t) {
case "insideStart":
_ = d + g * a, v = p;
@@ -61751,15 +61803,15 @@ var CQ = /*#__PURE__*/ (0, R.createContext)(null), wQ = (e) => {
v = h <= 0 ? v : !v;
var y = jW(s, c, m, _), b = jW(s, c, m, _ + (v ? 1 : -1) * 359), x = `M${y.x},${y.y}
A${m},${m},0,1,${+!v},
- ${b.x},${b.y}`, S = FL(e.id) ? AL("recharts-radial-line-") : e.id;
- return /*#__PURE__*/ R.createElement("text", SQ({}, r, {
+ ${b.x},${b.y}`, S = IL(e.id) ? jL("recharts-radial-line-") : e.id;
+ return /*#__PURE__*/ R.createElement("text", xQ({}, r, {
dominantBaseline: "central",
className: ja("recharts-radial-bar-label", o)
}), /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement("path", {
id: S,
d: x
})), /*#__PURE__*/ R.createElement("textPath", { xlinkHref: `#${S}` }, n));
-}, gke = (e, t, n) => {
+}, vke = (e, t, n) => {
var { cx: r, cy: i, innerRadius: a, outerRadius: o, startAngle: s, endAngle: c } = e, l = (s + c) / 2;
if (n === "outside") {
var { x: u, y: d } = jW(r, i, o + t, l);
@@ -61795,15 +61847,15 @@ var CQ = /*#__PURE__*/ (0, R.createContext)(null), wQ = (e) => {
textAnchor: "middle",
verticalAnchor: "middle"
};
-}, kQ = (e) => e != null && "cx" in e && Z(e.cx), _ke = {
+}, OQ = (e) => e != null && "cx" in e && Z(e.cx), yke = {
angle: 0,
offset: 5,
zIndex: fG.label,
position: "middle",
textBreakAll: !1
};
-function vke(e) {
- if (!kQ(e)) return e;
+function bke(e) {
+ if (!OQ(e)) return e;
var { cx: t, cy: n, outerRadius: r } = e, i = r * 2;
return {
x: t - r,
@@ -61814,29 +61866,29 @@ function vke(e) {
height: i
};
}
-function AQ(e) {
- var t = JL(e, _ke), { viewBox: n, parentViewBox: r, position: i, value: a, children: o, content: s, className: c = "", textBreakAll: l, labelRef: u } = t, d = DQ(), f = TQ(), p = n == null ? i === "center" ? f : d ?? f : kQ(n) ? n : mH(n), m, h, g = vke(p);
- if (!p || FL(a) && FL(o) && !/*#__PURE__*/ (0, R.isValidElement)(s) && typeof s != "function") return null;
+function kQ(e) {
+ var t = YL(e, yke), { viewBox: n, parentViewBox: r, position: i, value: a, children: o, content: s, className: c = "", textBreakAll: l, labelRef: u } = t, d = EQ(), f = wQ(), p = n == null ? i === "center" ? f : d ?? f : OQ(n) ? n : hH(n), m, h, g = bke(p);
+ if (!p || IL(a) && IL(o) && !/*#__PURE__*/ (0, R.isValidElement)(s) && typeof s != "function") return null;
var _ = bQ(bQ({}, t), {}, { viewBox: p });
if (/*#__PURE__*/ (0, R.isValidElement)(s)) {
- var { labelRef: v } = _, y = vQ(_, ske);
+ var { labelRef: v } = _, y = vQ(_, cke);
return /*#__PURE__*/ (0, R.cloneElement)(s, y);
}
if (typeof s == "function") {
- var { content: b } = _, x = vQ(_, cke);
+ var { content: b } = _, x = vQ(_, lke);
if (m = /*#__PURE__*/ (0, R.createElement)(s, x), /*#__PURE__*/ (0, R.isValidElement)(m)) return m;
- } else m = pke(t);
- var S = bI(t);
- if (kQ(p)) {
- if (i === "insideStart" || i === "insideEnd" || i === "end") return hke(t, i, m, S, p);
- h = gke(p, t.offset, t.position);
+ } else m = hke(t);
+ var S = xI(t);
+ if (OQ(p)) {
+ if (i === "insideStart" || i === "insideEnd" || i === "end") return _ke(t, i, m, S, p);
+ h = vke(p, t.offset, t.position);
} else {
if (!g) return null;
- var C = oke({
+ var C = ske({
viewBox: g,
position: i,
offset: t.offset,
- parentViewBox: kQ(r) ? void 0 : r,
+ parentViewBox: OQ(r) ? void 0 : r,
clamp: !0
});
h = bQ(bQ({
@@ -61846,7 +61898,7 @@ function AQ(e) {
verticalAnchor: C.verticalAnchor
}, C.width === void 0 ? {} : { width: C.width }), C.height === void 0 ? {} : { height: C.height });
}
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: t.zIndex }, /*#__PURE__*/ R.createElement(hQ, SQ({
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: t.zIndex }, /*#__PURE__*/ R.createElement(hQ, xQ({
ref: u,
className: ja("recharts-label", c)
}, S, h, {
@@ -61854,60 +61906,60 @@ function AQ(e) {
breakAll: l
}), m));
}
-AQ.displayName = "Label";
-var jQ = (e, t, n) => {
+kQ.displayName = "Label";
+var AQ = (e, t, n) => {
if (!e) return null;
var r = {
viewBox: t,
labelRef: n
};
- return e === !0 ? /*#__PURE__*/ R.createElement(AQ, SQ({ key: "label-implicit" }, r)) : kL(e) ? /*#__PURE__*/ R.createElement(AQ, SQ({
+ return e === !0 ? /*#__PURE__*/ R.createElement(kQ, xQ({ key: "label-implicit" }, r)) : AL(e) ? /*#__PURE__*/ R.createElement(kQ, xQ({
key: "label-implicit",
value: e
- }, r)) : /*#__PURE__*/ (0, R.isValidElement)(e) ? e.type === AQ ? /*#__PURE__*/ (0, R.cloneElement)(e, bQ({ key: "label-implicit" }, r)) : /*#__PURE__*/ R.createElement(AQ, SQ({
+ }, r)) : /*#__PURE__*/ (0, R.isValidElement)(e) ? e.type === kQ ? /*#__PURE__*/ (0, R.cloneElement)(e, bQ({ key: "label-implicit" }, r)) : /*#__PURE__*/ R.createElement(kQ, xQ({
key: "label-implicit",
content: e
- }, r)) : OQ(e) ? /*#__PURE__*/ R.createElement(AQ, SQ({
+ }, r)) : DQ(e) ? /*#__PURE__*/ R.createElement(kQ, xQ({
key: "label-implicit",
content: e
- }, r)) : e && typeof e == "object" ? /*#__PURE__*/ R.createElement(AQ, SQ({}, e, { key: "label-implicit" }, r)) : null;
+ }, r)) : e && typeof e == "object" ? /*#__PURE__*/ R.createElement(kQ, xQ({}, e, { key: "label-implicit" }, r)) : null;
};
-function MQ(e) {
+function jQ(e) {
var { label: t, labelRef: n } = e;
- return jQ(t, TQ(), n) || null;
+ return AQ(t, wQ(), n) || null;
}
-function yke(e) {
+function xke(e) {
var { label: t } = e;
- return jQ(t, DQ()) || null;
+ return AQ(t, EQ()) || null;
}
//#endregion
//#region node_modules/recharts/es6/component/LabelList.js
-var bke = ["valueAccessor"], xke = [
+var Ske = ["valueAccessor"], Cke = [
"dataKey",
"clockWise",
"id",
"textBreakAll",
"zIndex"
];
-function NQ() {
- return NQ = Object.assign ? Object.assign.bind() : function(e) {
+function MQ() {
+ return MQ = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, NQ.apply(null, arguments);
+ }, MQ.apply(null, arguments);
}
-function PQ(e, t) {
+function NQ(e, t) {
if (e == null) return {};
- var n, r, i = Ske(e, t);
+ var n, r, i = wke(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function Ske(e, t) {
+function wke(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -61916,21 +61968,21 @@ function Ske(e, t) {
}
return n;
}
-var Cke = (e) => {
+var Tke = (e) => {
var t = Array.isArray(e.value) ? e.value[e.value.length - 1] : e.value;
- if (QOe(t)) return t;
-}, FQ = /*#__PURE__*/ (0, R.createContext)(void 0), IQ = FQ.Provider, LQ = /*#__PURE__*/ (0, R.createContext)(void 0), wke = LQ.Provider;
-function Tke() {
- return (0, R.useContext)(FQ);
-}
-function Eke() {
- return (0, R.useContext)(LQ);
-}
-function RQ(e) {
- var { valueAccessor: t = Cke } = e, n = PQ(e, bke), { dataKey: r, clockWise: i, id: a, textBreakAll: o, zIndex: s } = n, c = PQ(n, xke), l = Tke(), u = Eke(), d = l || u;
- return !d || !d.length ? null : /*#__PURE__*/ R.createElement(DZ, { zIndex: s ?? fG.label }, /*#__PURE__*/ R.createElement(wI, { className: "recharts-label-list" }, d.map((e, i) => {
- var s = FL(r) ? t(e, i) : QB(e.payload, r), l = FL(a) ? {} : { id: `${a}-${i}` };
- return /*#__PURE__*/ R.createElement(AQ, NQ({ key: `label-${i}` }, bI(e), c, l, {
+ if ($Oe(t)) return t;
+}, PQ = /*#__PURE__*/ (0, R.createContext)(void 0), FQ = PQ.Provider, IQ = /*#__PURE__*/ (0, R.createContext)(void 0), Eke = IQ.Provider;
+function Dke() {
+ return (0, R.useContext)(PQ);
+}
+function Oke() {
+ return (0, R.useContext)(IQ);
+}
+function LQ(e) {
+ var { valueAccessor: t = Tke } = e, n = NQ(e, Ske), { dataKey: r, clockWise: i, id: a, textBreakAll: o, zIndex: s } = n, c = NQ(n, Cke), l = Dke(), u = Oke(), d = l || u;
+ return !d || !d.length ? null : /*#__PURE__*/ R.createElement(DZ, { zIndex: s ?? fG.label }, /*#__PURE__*/ R.createElement(TI, { className: "recharts-label-list" }, d.map((e, i) => {
+ var s = IL(r) ? t(e, i) : $B(e.payload, r), l = IL(a) ? {} : { id: `${a}-${i}` };
+ return /*#__PURE__*/ R.createElement(kQ, MQ({ key: `label-${i}` }, xI(e), c, l, {
fill: n.fill ?? e.fill,
parentViewBox: e.parentViewBox,
value: s,
@@ -61941,41 +61993,41 @@ function RQ(e) {
}));
})));
}
-RQ.displayName = "LabelList";
-function zQ(e) {
+LQ.displayName = "LabelList";
+function RQ(e) {
var { label: t } = e;
- return t ? t === !0 ? /*#__PURE__*/ R.createElement(RQ, { key: "labelList-implicit" }) : /*#__PURE__*/ R.isValidElement(t) || OQ(t) ? /*#__PURE__*/ R.createElement(RQ, {
+ return t ? t === !0 ? /*#__PURE__*/ R.createElement(LQ, { key: "labelList-implicit" }) : /*#__PURE__*/ R.isValidElement(t) || DQ(t) ? /*#__PURE__*/ R.createElement(LQ, {
key: "labelList-implicit",
content: t
- }) : typeof t == "object" ? /*#__PURE__*/ R.createElement(RQ, NQ({ key: "labelList-implicit" }, t, { type: String(t.type) })) : null : null;
+ }) : typeof t == "object" ? /*#__PURE__*/ R.createElement(LQ, MQ({ key: "labelList-implicit" }, t, { type: String(t.type) })) : null : null;
}
//#endregion
//#region node_modules/recharts/es6/shape/Polygon.js
-var Dke = [
+var kke = [
"points",
"className",
"baseLinePoints",
"connectNulls"
-], Oke;
-function BQ() {
- return BQ = Object.assign ? Object.assign.bind() : function(e) {
+], Ake;
+function zQ() {
+ return zQ = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, BQ.apply(null, arguments);
+ }, zQ.apply(null, arguments);
}
-function kke(e, t) {
+function jke(e, t) {
if (e == null) return {};
- var n, r, i = Ake(e, t);
+ var n, r, i = Mke(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function Ake(e, t) {
+function Mke(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -61984,23 +62036,23 @@ function Ake(e, t) {
}
return n;
}
-function jke(e, t) {
+function Nke(e, t) {
return t ||= e.slice(0), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } }));
}
-var VQ = (e) => e != null && e.x === +e.x && e.y === +e.y, Mke = function() {
+var BQ = (e) => e != null && e.x === +e.x && e.y === +e.y, Pke = function() {
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [], t = [[]];
e.forEach((e) => {
var n = t[t.length - 1];
- VQ(e) ? n && n.push(e) : n && n.length > 0 && t.push([]);
+ BQ(e) ? n && n.push(e) : n && n.length > 0 && t.push([]);
});
var n = e[0], r = t[t.length - 1];
- VQ(n) && r && r.push(n);
+ BQ(n) && r && r.push(n);
var i = t[t.length - 1];
return i && i.length <= 0 && (t = t.slice(0, -1)), t;
-}, HQ = (e, t) => {
- var n = Mke(e);
+}, VQ = (e, t) => {
+ var n = Pke(e);
t && (n = [n.reduce((e, t) => [...e, ...t], [])]);
- var r = n.map((e) => e.reduce((e, t, n) => TL(Oke ||= jke([
+ var r = n.map((e) => e.reduce((e, t, n) => EL(Ake ||= Nke([
"",
"",
"",
@@ -62008,29 +62060,29 @@ var VQ = (e) => e != null && e.x === +e.x && e.y === +e.y, Mke = function() {
""
]), e, n === 0 ? "M" : "L", t.x, t.y), "")).join("");
return n.length === 1 ? `${r}Z` : r;
-}, Nke = (e, t, n) => {
- var r = HQ(e, n);
- return `${r.slice(-1) === "Z" ? r.slice(0, -1) : r}L${HQ(Array.from(t).reverse(), n).slice(1)}`;
-}, UQ = (e) => {
- var { points: t, className: n, baseLinePoints: r, connectNulls: i } = e, a = kke(e, Dke);
+}, Fke = (e, t, n) => {
+ var r = VQ(e, n);
+ return `${r.slice(-1) === "Z" ? r.slice(0, -1) : r}L${VQ(Array.from(t).reverse(), n).slice(1)}`;
+}, HQ = (e) => {
+ var { points: t, className: n, baseLinePoints: r, connectNulls: i } = e, a = jke(e, kke);
if (!t || !t.length) return null;
var o = ja("recharts-polygon", n);
if (r && r.length) {
- var s = a.stroke && a.stroke !== "none", c = Nke(t, r, i);
- return /*#__PURE__*/ R.createElement("g", { className: o }, /*#__PURE__*/ R.createElement("path", BQ({}, bI(a), {
+ var s = a.stroke && a.stroke !== "none", c = Fke(t, r, i);
+ return /*#__PURE__*/ R.createElement("g", { className: o }, /*#__PURE__*/ R.createElement("path", zQ({}, xI(a), {
fill: c.slice(-1) === "Z" ? a.fill : "none",
stroke: "none",
d: c
- })), s ? /*#__PURE__*/ R.createElement("path", BQ({}, bI(a), {
+ })), s ? /*#__PURE__*/ R.createElement("path", zQ({}, xI(a), {
fill: "none",
- d: HQ(t, i)
- })) : null, s ? /*#__PURE__*/ R.createElement("path", BQ({}, bI(a), {
+ d: VQ(t, i)
+ })) : null, s ? /*#__PURE__*/ R.createElement("path", zQ({}, xI(a), {
fill: "none",
- d: HQ(r, i)
+ d: VQ(r, i)
})) : null);
}
- var l = HQ(t, i);
- return /*#__PURE__*/ R.createElement("path", BQ({}, bI(a), {
+ var l = VQ(t, i);
+ return /*#__PURE__*/ R.createElement("path", zQ({}, xI(a), {
fill: l.slice(-1) === "Z" ? a.fill : "none",
className: o,
d: l
@@ -62038,111 +62090,111 @@ var VQ = (e) => e != null && e.x === +e.x && e.y === +e.y, Mke = function() {
};
//#endregion
//#region node_modules/recharts/es6/shape/Dot.js
-function WQ() {
- return WQ = Object.assign ? Object.assign.bind() : function(e) {
+function UQ() {
+ return UQ = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, WQ.apply(null, arguments);
+ }, UQ.apply(null, arguments);
}
-var GQ = (e) => {
+var WQ = (e) => {
var { cx: t, cy: n, r, className: i } = e, a = ja("recharts-dot", i);
- return Z(t) && Z(n) && Z(r) ? /*#__PURE__*/ R.createElement("circle", WQ({}, vI(e), GL(e), {
+ return Z(t) && Z(n) && Z(r) ? /*#__PURE__*/ R.createElement("circle", UQ({}, yI(e), KL(e), {
className: a,
cx: t,
cy: n,
r
})) : null;
-}, KQ = (e) => e.graphicalItems.polarItems, qQ = $([
- KQ,
+}, GQ = (e) => e.graphicalItems.polarItems, KQ = $([
+ GQ,
uY,
$([AG, jG], pY)
-], hY), JQ = $([$([qQ], yY), VW], bY), YQ = $([
- JQ,
+], hY), qQ = $([$([KQ], yY), VW], bY), JQ = $([
+ qQ,
uY,
- qQ
+ KQ
], SY);
$([
- JQ,
+ qQ,
uY,
- qQ
+ KQ
], (e, t, n) => n.length > 0 ? e.flatMap((e) => n.flatMap((n) => ({
- value: QB(e, t.dataKey ?? n.dataKey),
+ value: $B(e, t.dataKey ?? n.dataKey),
errorDomain: []
}))).filter(Boolean) : t?.dataKey == null ? e.map((e) => ({
value: e,
errorDomain: []
})) : e.map((e) => ({
- value: QB(e, t.dataKey),
+ value: $B(e, t.dataKey),
errorDomain: []
})));
-var XQ = () => void 0, ZQ = $([
+var YQ = () => void 0, XQ = $([
uY,
- xH,
+ SH,
+ qQ,
JQ,
- YQ,
oG,
AG,
$([
uY,
PY,
FY,
- XQ,
+ YQ,
$([
- JQ,
- uY,
qQ,
+ uY,
+ KQ,
IY,
AG
], RY),
- XQ,
- xH,
+ YQ,
+ SH,
AG
], KY)
-], qY), QQ = $([
- ZQ,
+], qY), ZQ = $([
+ XQ,
dY,
YY
-], XY), Pke = $([YY, $([
+], XY), Ike = $([YY, $([
uY,
+ XQ,
ZQ,
- QQ,
AG
-], QY)], BG), $Q = (e, t, n) => {
+], QY)], BG), QQ = (e, t, n) => {
switch (t) {
case "angleAxis": return xG(e, n);
case "radiusAxis": return SG(e, n);
default: throw Error(`Unexpected axis type: ${t}`);
}
-}, e$ = (e, t, n) => {
+}, $Q = (e, t, n) => {
switch (t) {
- case "angleAxis": return mCe(e, n);
- case "radiusAxis": return hCe(e, n);
+ case "angleAxis": return hCe(e, n);
+ case "radiusAxis": return gCe(e, n);
default: throw Error(`Unexpected axis type: ${t}`);
}
-}, t$ = $([$([
- $Q,
+}, e$ = $([$([
+ QQ,
YY,
- Pke,
- e$
-], ZJ)], zG), n$ = $([
- xH,
- YQ,
+ Ike,
+ $Q
+], ZJ)], zG), t$ = $([
+ SH,
+ JQ,
dY,
AG
-], rX), r$ = $([
- xH,
- $Q,
- YY,
- t$,
+], rX), n$ = $([
+ SH,
QQ,
+ YY,
e$,
+ ZQ,
+ $Q,
mX,
- n$,
+ t$,
AG
-], gX), Fke = $([r$], (e) => {
+], gX), Lke = $([n$], (e) => {
if (e) {
var t = /* @__PURE__ */ new Map();
return e.forEach((e) => {
@@ -62150,19 +62202,19 @@ var XQ = () => void 0, ZQ = $([
t.has(n) || t.set(n, e);
}), Array.from(t.values());
}
-}), Ike = $([
- xH,
- $Q,
- t$,
+}), Rke = $([
+ SH,
+ QQ,
e$,
+ $Q,
mX,
- n$,
+ t$,
AG
-], vX), Lke = $([(e, t) => r$(e, "angleAxis", t, !1)], (e) => {
+], vX), zke = $([(e, t) => n$(e, "angleAxis", t, !1)], (e) => {
if (e) return e.map((e) => e.coordinate);
-}), Rke = $([(e, t) => r$(e, "radiusAxis", t, !1)], (e) => {
+}), Bke = $([(e, t) => n$(e, "radiusAxis", t, !1)], (e) => {
if (e) return e.map((e) => e.coordinate);
-}), zke = [
+}), Vke = [
"gridType",
"radialLines",
"angleAxisId",
@@ -62175,16 +62227,16 @@ var XQ = () => void 0, ZQ = $([
"polarRadius",
"zIndex"
];
-function Bke(e, t) {
+function Hke(e, t) {
if (e == null) return {};
- var n, r, i = Vke(e, t);
+ var n, r, i = Uke(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function Vke(e, t) {
+function Uke(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -62193,16 +62245,16 @@ function Vke(e, t) {
}
return n;
}
-function i$() {
- return i$ = Object.assign ? Object.assign.bind() : function(e) {
+function r$() {
+ return r$ = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, i$.apply(null, arguments);
+ }, r$.apply(null, arguments);
}
-function a$(e, t) {
+function i$(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -62212,30 +62264,30 @@ function a$(e, t) {
}
return n;
}
-function o$(e) {
+function a$(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? a$(Object(n), !0).forEach(function(t) {
- Hke(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : a$(Object(n)).forEach(function(t) {
+ t % 2 ? i$(Object(n), !0).forEach(function(t) {
+ Wke(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : i$(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function Hke(e, t, n) {
- return (t = Uke(t)) in e ? Object.defineProperty(e, t, {
+function Wke(e, t, n) {
+ return (t = Gke(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function Uke(e) {
- var t = Wke(e, "string");
+function Gke(e) {
+ var t = Kke(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function Wke(e, t) {
+function Kke(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -62245,69 +62297,69 @@ function Wke(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var Gke = (e, t, n, r) => {
+var qke = (e, t, n, r) => {
var i = "";
return r.forEach((r, a) => {
var o = jW(t, n, e, r);
i += a ? `L ${o.x},${o.y}` : `M ${o.x},${o.y}`;
}), i += "Z", i;
-}, Kke = (e) => {
+}, Jke = (e) => {
var { cx: t, cy: n, innerRadius: r, outerRadius: i, polarAngles: a, radialLines: o } = e;
if (!a || !a.length || !o) return null;
- var s = o$({ stroke: "#ccc" }, vI(e));
+ var s = a$({ stroke: "#ccc" }, yI(e));
return /*#__PURE__*/ R.createElement("g", { className: "recharts-polar-grid-angle" }, a.map((e) => {
var a = jW(t, n, r, e), o = jW(t, n, i, e);
- return /*#__PURE__*/ R.createElement("line", i$({ key: `line-${e}` }, s, {
+ return /*#__PURE__*/ R.createElement("line", r$({ key: `line-${e}` }, s, {
x1: a.x,
y1: a.y,
x2: o.x,
y2: o.y
}));
}));
-}, s$ = (e) => {
- var { cx: t, cy: n, radius: r } = e, i = o$({
+}, o$ = (e) => {
+ var { cx: t, cy: n, radius: r } = e, i = a$({
stroke: "#ccc",
fill: "none"
- }, vI(e));
- return /*#__PURE__*/ R.createElement("circle", i$({}, i, {
+ }, yI(e));
+ return /*#__PURE__*/ R.createElement("circle", r$({}, i, {
className: ja("recharts-polar-grid-concentric-circle", e.className),
cx: t,
cy: n,
r
}));
-}, c$ = (e) => {
- var { radius: t } = e, n = o$({
+}, s$ = (e) => {
+ var { radius: t } = e, n = a$({
stroke: "#ccc",
fill: "none"
- }, vI(e));
- return /*#__PURE__*/ R.createElement("path", i$({}, n, {
+ }, yI(e));
+ return /*#__PURE__*/ R.createElement("path", r$({}, n, {
className: ja("recharts-polar-grid-concentric-polygon", e.className),
- d: Gke(t, e.cx, e.cy, e.polarAngles)
+ d: qke(t, e.cx, e.cy, e.polarAngles)
}));
-}, qke = (e) => {
+}, Yke = (e) => {
var { polarRadius: t, gridType: n } = e;
if (!t || !t.length) return null;
var r = Math.max(...t), i = e.fill && e.fill !== "none";
- return /*#__PURE__*/ R.createElement("g", { className: "recharts-polar-grid-concentric" }, i && n === "circle" && /*#__PURE__*/ R.createElement(s$, i$({}, e, { radius: r })), i && n !== "circle" && /*#__PURE__*/ R.createElement(c$, i$({}, e, { radius: r })), t.map((t, r) => {
+ return /*#__PURE__*/ R.createElement("g", { className: "recharts-polar-grid-concentric" }, i && n === "circle" && /*#__PURE__*/ R.createElement(o$, r$({}, e, { radius: r })), i && n !== "circle" && /*#__PURE__*/ R.createElement(s$, r$({}, e, { radius: r })), t.map((t, r) => {
var i = r;
- return n === "circle" ? /*#__PURE__*/ R.createElement(s$, i$({ key: i }, e, {
+ return n === "circle" ? /*#__PURE__*/ R.createElement(o$, r$({ key: i }, e, {
fill: "none",
radius: t
- })) : /*#__PURE__*/ R.createElement(c$, i$({ key: i }, e, {
+ })) : /*#__PURE__*/ R.createElement(s$, r$({ key: i }, e, {
fill: "none",
radius: t
}));
}));
-}, Jke = {
+}, Xke = {
angleAxisId: 0,
radiusAxisId: 0,
gridType: "polygon",
radialLines: !0,
zIndex: fG.grid
-}, l$ = (e) => {
- var t = JL(e, Jke), { gridType: n, radialLines: r, angleAxisId: i, radiusAxisId: a, cx: o, cy: s, innerRadius: c, outerRadius: l, polarAngles: u, polarRadius: d, zIndex: f } = t, p = Bke(t, zke), m = Q(kG), h = Q((e) => Lke(e, i)), g = Q((e) => Rke(e, a)), _ = Array.isArray(u) ? u : h, v = Array.isArray(d) ? d : g;
+}, c$ = (e) => {
+ var t = YL(e, Xke), { gridType: n, radialLines: r, angleAxisId: i, radiusAxisId: a, cx: o, cy: s, innerRadius: c, outerRadius: l, polarAngles: u, polarRadius: d, zIndex: f } = t, p = Hke(t, Vke), m = Q(kG), h = Q((e) => zke(e, i)), g = Q((e) => Bke(e, a)), _ = Array.isArray(u) ? u : h, v = Array.isArray(d) ? d : g;
if (_ == null || v == null) return null;
- var y = o$({
+ var y = a$({
cx: m?.cx ?? o ?? 0,
cy: m?.cy ?? s ?? 0,
innerRadius: m?.innerRadius ?? c ?? 0,
@@ -62316,13 +62368,13 @@ var Gke = (e, t, n, r) => {
polarRadius: v,
zIndex: f
}, p), { outerRadius: b } = y;
- return b <= 0 ? null : /*#__PURE__*/ R.createElement(DZ, { zIndex: y.zIndex }, /*#__PURE__*/ R.createElement("g", { className: "recharts-polar-grid" }, /*#__PURE__*/ R.createElement(qke, i$({
+ return b <= 0 ? null : /*#__PURE__*/ R.createElement(DZ, { zIndex: y.zIndex }, /*#__PURE__*/ R.createElement("g", { className: "recharts-polar-grid" }, /*#__PURE__*/ R.createElement(Yke, r$({
gridType: n,
radialLines: r
}, y, {
polarAngles: _,
polarRadius: v
- })), /*#__PURE__*/ R.createElement(Kke, i$({
+ })), /*#__PURE__*/ R.createElement(Jke, r$({
gridType: n,
radialLines: r
}, y, {
@@ -62330,19 +62382,19 @@ var Gke = (e, t, n, r) => {
polarRadius: v
}))));
};
-l$.displayName = "PolarGrid";
+c$.displayName = "PolarGrid";
//#endregion
//#region node_modules/es-toolkit/dist/compat/_internal/toArray.mjs
-function u$(e) {
+function l$(e) {
return Array.isArray(e) ? e : Array.from(e);
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/math/maxBy.mjs
-function Yke(e, t = $L) {
+function Zke(e, t = eR) {
if (e == null) return;
- let n = u$(e);
+ let n = l$(e);
if (n.length === 0) return;
- let r = _R(t), i, a;
+ let r = vR(t), i, a;
for (let e = 0; e < n.length; e++) {
let t = n[e], o = r(t, e, n);
o == null || Number.isNaN(o) || typeof o == "symbol" || (a === void 0 || o > a) && (a = o, i = t);
@@ -62351,11 +62403,11 @@ function Yke(e, t = $L) {
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/math/minBy.mjs
-function Xke(e, t = $L) {
+function Qke(e, t = eR) {
if (e == null) return;
- let n = u$(e);
+ let n = l$(e);
if (n.length === 0) return;
- let r = _R(t), i, a;
+ let r = vR(t), i, a;
for (let e = 0; e < n.length; e++) {
let t = n[e], o = r(t, e, n);
o == null || Number.isNaN(o) || typeof o == "symbol" || (a === void 0 || o < a) && (a = o, i = t);
@@ -62364,7 +62416,7 @@ function Xke(e, t = $L) {
}
//#endregion
//#region node_modules/recharts/es6/state/polarAxisSlice.js
-var d$ = oB({
+var u$ = sB({
name: "polarAxis",
initialState: {
radiusAxis: {},
@@ -62384,35 +62436,35 @@ var d$ = oB({
delete e.angleAxis[t.payload.id];
}
}
-}), { addRadiusAxis: Zke, removeRadiusAxis: Qke, addAngleAxis: $ke, removeAngleAxis: eAe } = d$.actions, tAe = d$.reducer;
+}), { addRadiusAxis: $ke, removeRadiusAxis: eAe, addAngleAxis: tAe, removeAngleAxis: nAe } = u$.actions, rAe = u$.reducer;
//#endregion
//#region node_modules/recharts/es6/util/getClassNameFromUnknown.js
-function f$(e) {
+function d$(e) {
return e && typeof e == "object" && "className" in e && typeof e.className == "string" ? e.className : "";
}
//#endregion
//#region node_modules/recharts/es6/polar/PolarRadiusAxis.js
-var nAe = ["type"], rAe = [
+var iAe = ["type"], aAe = [
"cx",
"cy",
"angle",
"axisLine"
-], iAe = [
+], oAe = [
"angle",
"tickFormatter",
"stroke",
"tick"
];
-function p$() {
- return p$ = Object.assign ? Object.assign.bind() : function(e) {
+function f$() {
+ return f$ = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, p$.apply(null, arguments);
+ }, f$.apply(null, arguments);
}
-function m$(e, t) {
+function p$(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -62422,30 +62474,30 @@ function m$(e, t) {
}
return n;
}
-function h$(e) {
+function m$(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? m$(Object(n), !0).forEach(function(t) {
- aAe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : m$(Object(n)).forEach(function(t) {
+ t % 2 ? p$(Object(n), !0).forEach(function(t) {
+ sAe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : p$(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function aAe(e, t, n) {
- return (t = oAe(t)) in e ? Object.defineProperty(e, t, {
+function sAe(e, t, n) {
+ return (t = cAe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function oAe(e) {
- var t = sAe(e, "string");
+function cAe(e) {
+ var t = lAe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function sAe(e, t) {
+function lAe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -62455,16 +62507,16 @@ function sAe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function g$(e, t) {
+function h$(e, t) {
if (e == null) return {};
- var n, r, i = cAe(e, t);
+ var n, r, i = uAe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function cAe(e, t) {
+function uAe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -62473,20 +62525,20 @@ function cAe(e, t) {
}
return n;
}
-var lAe = "radiusAxis";
-function uAe(e) {
- var t = xR(), n = TH(), r = (0, R.useMemo)(() => {
- var { type: t } = e, r = g$(e, nAe), i = gG(n, "radiusAxis", t);
- if (i != null) return h$(h$({}, r), {}, { type: i });
+var dAe = "radiusAxis";
+function fAe(e) {
+ var t = SR(), n = EH(), r = (0, R.useMemo)(() => {
+ var { type: t } = e, r = h$(e, iAe), i = gG(n, "radiusAxis", t);
+ if (i != null) return m$(m$({}, r), {}, { type: i });
}, [e, n]);
- return (0, R.useEffect)(() => r == null ? RL : (t(Zke(r)), () => {
- t(Qke(r));
+ return (0, R.useEffect)(() => r == null ? zL : (t($ke(r)), () => {
+ t(eAe(r));
}), [t, r]), null;
}
-var dAe = (e, t, n, r) => {
+var pAe = (e, t, n, r) => {
var { coordinate: i } = e;
return jW(n, r, i, t);
-}, fAe = (e) => {
+}, mAe = (e) => {
var t;
switch (e) {
case "left":
@@ -62498,49 +62550,49 @@ var dAe = (e, t, n, r) => {
default: t = "middle";
}
return t;
-}, pAe = (e, t, n, r) => {
- var i = Yke(r, (e) => e.coordinate || 0);
+}, hAe = (e, t, n, r) => {
+ var i = Zke(r, (e) => e.coordinate || 0);
return {
cx: t,
cy: n,
startAngle: e,
endAngle: e,
- innerRadius: Xke(r, (e) => e.coordinate || 0)?.coordinate || 0,
+ innerRadius: Qke(r, (e) => e.coordinate || 0)?.coordinate || 0,
outerRadius: i?.coordinate || 0,
clockWise: !1
};
-}, mAe = (e, t) => {
- var { cx: n, cy: r, angle: i, axisLine: a } = e, o = g$(e, rAe), s = t.reduce((e, t) => [Math.min(e[0], t.coordinate), Math.max(e[1], t.coordinate)], [Infinity, -Infinity]), c = jW(n, r, s[0], i), l = jW(n, r, s[1], i), u = h$(h$(h$({}, vI(o)), {}, { fill: "none" }, vI(a)), {}, {
+}, gAe = (e, t) => {
+ var { cx: n, cy: r, angle: i, axisLine: a } = e, o = h$(e, aAe), s = t.reduce((e, t) => [Math.min(e[0], t.coordinate), Math.max(e[1], t.coordinate)], [Infinity, -Infinity]), c = jW(n, r, s[0], i), l = jW(n, r, s[1], i), u = m$(m$(m$({}, yI(o)), {}, { fill: "none" }, yI(a)), {}, {
x1: c.x,
y1: c.y,
x2: l.x,
y2: l.y
});
- return /*#__PURE__*/ R.createElement("line", p$({ className: "recharts-polar-radius-axis-line" }, u));
-}, hAe = (e, t, n) => /*#__PURE__*/ R.isValidElement(e) ? /*#__PURE__*/ R.cloneElement(e, t) : typeof e == "function" ? e(t) : /*#__PURE__*/ R.createElement(hQ, p$({}, t, { className: "recharts-polar-radius-axis-tick-value" }), n), gAe = (e, t) => {
- var { angle: n, tickFormatter: r, stroke: i, tick: a } = e, o = g$(e, iAe), s = fAe(e.orientation), c = vI(o), l = yI(a), u = t.map((t, o) => {
- var u = dAe(t, e.angle, e.cx, e.cy), d = h$(h$(h$(h$({
+ return /*#__PURE__*/ R.createElement("line", f$({ className: "recharts-polar-radius-axis-line" }, u));
+}, _Ae = (e, t, n) => /*#__PURE__*/ R.isValidElement(e) ? /*#__PURE__*/ R.cloneElement(e, t) : typeof e == "function" ? e(t) : /*#__PURE__*/ R.createElement(hQ, f$({}, t, { className: "recharts-polar-radius-axis-tick-value" }), n), vAe = (e, t) => {
+ var { angle: n, tickFormatter: r, stroke: i, tick: a } = e, o = h$(e, oAe), s = mAe(e.orientation), c = yI(o), l = bI(a), u = t.map((t, o) => {
+ var u = pAe(t, e.angle, e.cx, e.cy), d = m$(m$(m$(m$({
textAnchor: s,
transform: `rotate(${90 - n}, ${u.x}, ${u.y})`
}, c), {}, {
stroke: "none",
fill: i
}, l), {}, { index: o }, u), {}, { payload: t });
- return /*#__PURE__*/ R.createElement(wI, p$({
- className: ja("recharts-polar-radius-axis-tick", f$(a)),
+ return /*#__PURE__*/ R.createElement(TI, f$({
+ className: ja("recharts-polar-radius-axis-tick", d$(a)),
key: `tick-${t.coordinate}`
- }, KL(e, t, o)), hAe(a, d, r ? r(t.value, o) : t.value));
+ }, qL(e, t, o)), _Ae(a, d, r ? r(t.value, o) : t.value));
});
- return /*#__PURE__*/ R.createElement(wI, { className: "recharts-polar-radius-axis-ticks" }, u);
-}, _Ae = (e) => {
- var { radiusAxisId: t } = e, n = Q(kG), r = Q((e) => t$(e, "radiusAxis", t)), i = Q((e) => r$(e, "radiusAxis", t, !1));
+ return /*#__PURE__*/ R.createElement(TI, { className: "recharts-polar-radius-axis-ticks" }, u);
+}, yAe = (e) => {
+ var { radiusAxisId: t } = e, n = Q(kG), r = Q((e) => e$(e, "radiusAxis", t)), i = Q((e) => n$(e, "radiusAxis", t, !1));
if (n == null || !i || !i.length || r == null) return null;
- var a = h$(h$({}, e), {}, { scale: r }, n), { tick: o, axisLine: s } = a;
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: a.zIndex }, /*#__PURE__*/ R.createElement(wI, { className: ja("recharts-polar-radius-axis", lAe, a.className) }, s && mAe(a, i), o && gAe(a, i), /*#__PURE__*/ R.createElement(fke, pAe(a.angle, a.cx, a.cy, i), /*#__PURE__*/ R.createElement(yke, { label: a.label }), a.children)));
+ var a = m$(m$({}, e), {}, { scale: r }, n), { tick: o, axisLine: s } = a;
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: a.zIndex }, /*#__PURE__*/ R.createElement(TI, { className: ja("recharts-polar-radius-axis", dAe, a.className) }, s && gAe(a, i), o && vAe(a, i), /*#__PURE__*/ R.createElement(mke, hAe(a.angle, a.cx, a.cy, i), /*#__PURE__*/ R.createElement(xke, { label: a.label }), a.children)));
};
-function _$(e) {
- var t = JL(e, mG);
- return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(uAe, {
+function g$(e) {
+ var t = YL(e, mG);
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(fAe, {
domain: t.domain,
id: t.radiusAxisId,
scale: t.scale,
@@ -62557,22 +62609,22 @@ function _$(e) {
ticks: t.ticks,
tickCount: t.tickCount,
tick: t.tick
- }), /*#__PURE__*/ R.createElement(_Ae, t));
+ }), /*#__PURE__*/ R.createElement(yAe, t));
}
-_$.displayName = "PolarRadiusAxis";
+g$.displayName = "PolarRadiusAxis";
//#endregion
//#region node_modules/recharts/es6/polar/PolarAngleAxis.js
-var vAe = ["children", "type"], yAe = ["ref"];
-function v$() {
- return v$ = Object.assign ? Object.assign.bind() : function(e) {
+var bAe = ["children", "type"], xAe = ["ref"];
+function _$() {
+ return _$ = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, v$.apply(null, arguments);
+ }, _$.apply(null, arguments);
}
-function y$(e, t) {
+function v$(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -62582,30 +62634,30 @@ function y$(e, t) {
}
return n;
}
-function b$(e) {
+function y$(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? y$(Object(n), !0).forEach(function(t) {
- bAe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : y$(Object(n)).forEach(function(t) {
+ t % 2 ? v$(Object(n), !0).forEach(function(t) {
+ SAe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : v$(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function bAe(e, t, n) {
- return (t = xAe(t)) in e ? Object.defineProperty(e, t, {
+function SAe(e, t, n) {
+ return (t = CAe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function xAe(e) {
- var t = SAe(e, "string");
+function CAe(e) {
+ var t = wAe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function SAe(e, t) {
+function wAe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -62615,16 +62667,16 @@ function SAe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function x$(e, t) {
+function b$(e, t) {
if (e == null) return {};
- var n, r, i = CAe(e, t);
+ var n, r, i = TAe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function CAe(e, t) {
+function TAe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -62633,17 +62685,17 @@ function CAe(e, t) {
}
return n;
}
-var S$ = 1e-5, wAe = Math.cos(AW(45)), TAe = "angleAxis";
-function EAe(e) {
- var t = xR(), n = TH(), r = (0, R.useMemo)(() => {
- var { children: t, type: r } = e, i = x$(e, vAe), a = gG(n, "angleAxis", r);
- if (a != null) return b$(b$({}, i), {}, { type: a });
+var x$ = 1e-5, EAe = Math.cos(AW(45)), DAe = "angleAxis";
+function OAe(e) {
+ var t = SR(), n = EH(), r = (0, R.useMemo)(() => {
+ var { children: t, type: r } = e, i = b$(e, bAe), a = gG(n, "angleAxis", r);
+ if (a != null) return y$(y$({}, i), {}, { type: a });
}, [e, n]), i = r === Q((e) => xG(e, r?.id));
- return (0, R.useEffect)(() => r == null ? RL : (t($ke(r)), () => {
- t(eAe(r));
+ return (0, R.useEffect)(() => r == null ? zL : (t(tAe(r)), () => {
+ t(nAe(r));
}), [t, r]), i ? e.children : null;
}
-var DAe = (e, t) => {
+var kAe = (e, t) => {
var { cx: n, cy: r, radius: i, orientation: a, tickSize: o } = t, s = o || 8, c = jW(n, r, i, e.coordinate), l = jW(n, r, i + (a === "inner" ? -1 : 1) * s, e.coordinate);
return {
x1: c.x,
@@ -62651,29 +62703,29 @@ var DAe = (e, t) => {
x2: l.x,
y2: l.y
};
-}, OAe = (e, t) => {
+}, AAe = (e, t) => {
var n = Math.cos(AW(-e.coordinate));
- return n > S$ ? t === "outer" ? "start" : "end" : n < -S$ ? t === "outer" ? "end" : "start" : "middle";
-}, kAe = (e) => {
+ return n > x$ ? t === "outer" ? "start" : "end" : n < -x$ ? t === "outer" ? "end" : "start" : "middle";
+}, jAe = (e) => {
var t = Math.cos(AW(-e.coordinate)), n = Math.sin(AW(-e.coordinate));
- return Math.abs(t) <= wAe ? n > 0 ? "start" : "end" : "middle";
-}, AAe = (e) => {
+ return Math.abs(t) <= EAe ? n > 0 ? "start" : "end" : "middle";
+}, MAe = (e) => {
var { cx: t, cy: n, radius: r, axisLineType: i, axisLine: a, ticks: o } = e;
if (!a) return null;
- var s = b$(b$({}, vI(e)), {}, { fill: "none" }, vI(a));
- if (i === "circle") return /*#__PURE__*/ R.createElement(GQ, v$({ className: "recharts-polar-angle-axis-line" }, s, {
+ var s = y$(y$({}, yI(e)), {}, { fill: "none" }, yI(a));
+ if (i === "circle") return /*#__PURE__*/ R.createElement(WQ, _$({ className: "recharts-polar-angle-axis-line" }, s, {
cx: t,
cy: n,
r
}));
var c = o.map((e) => jW(t, n, r, e.coordinate));
- return /*#__PURE__*/ R.createElement(UQ, v$({ className: "recharts-polar-angle-axis-line" }, s, { points: c }));
-}, jAe = (e) => {
+ return /*#__PURE__*/ R.createElement(HQ, _$({ className: "recharts-polar-angle-axis-line" }, s, { points: c }));
+}, NAe = (e) => {
var { tick: t, tickProps: n, value: r } = e;
- return t ? /*#__PURE__*/ R.isValidElement(t) ? /*#__PURE__*/ R.cloneElement(t, n) : typeof t == "function" ? t(n) : /*#__PURE__*/ R.createElement(hQ, v$({}, n, { className: "recharts-polar-angle-axis-tick-value" }), r) : null;
-}, MAe = (e) => {
- var { tick: t, tickLine: n, tickFormatter: r, stroke: i, ticks: a } = e, o = vI(e), { ref: s } = o, c = x$(o, yAe), l = yI(t), u = b$(b$({}, c), {}, { fill: "none" }, vI(n)), d = a.map((a, o) => {
- var s = DAe(a, e), d = OAe(a, e.orientation), f = kAe(a), p = b$(b$(b$({}, c), {}, {
+ return t ? /*#__PURE__*/ R.isValidElement(t) ? /*#__PURE__*/ R.cloneElement(t, n) : typeof t == "function" ? t(n) : /*#__PURE__*/ R.createElement(hQ, _$({}, n, { className: "recharts-polar-angle-axis-tick-value" }), r) : null;
+}, PAe = (e) => {
+ var { tick: t, tickLine: n, tickFormatter: r, stroke: i, ticks: a } = e, o = yI(e), { ref: s } = o, c = b$(o, xAe), l = bI(t), u = y$(y$({}, c), {}, { fill: "none" }, yI(n)), d = a.map((a, o) => {
+ var s = kAe(a, e), d = AAe(a, e.orientation), f = jAe(a), p = y$(y$(y$({}, c), {}, {
textAnchor: d,
verticalAnchor: f,
stroke: "none",
@@ -62684,28 +62736,28 @@ var DAe = (e, t) => {
x: s.x2,
y: s.y2
});
- return /*#__PURE__*/ R.createElement(wI, v$({
- className: ja("recharts-polar-angle-axis-tick", f$(t)),
+ return /*#__PURE__*/ R.createElement(TI, _$({
+ className: ja("recharts-polar-angle-axis-tick", d$(t)),
key: `tick-${a.coordinate}`
- }, KL(e, a, o)), n && /*#__PURE__*/ R.createElement("line", v$({ className: "recharts-polar-angle-axis-tick-line" }, u, s)), /*#__PURE__*/ R.createElement(jAe, {
+ }, qL(e, a, o)), n && /*#__PURE__*/ R.createElement("line", _$({ className: "recharts-polar-angle-axis-tick-line" }, u, s)), /*#__PURE__*/ R.createElement(NAe, {
tick: t,
tickProps: p,
value: r ? r(a.value, o) : a.value
}));
});
- return /*#__PURE__*/ R.createElement(wI, { className: "recharts-polar-angle-axis-ticks" }, d);
-}, NAe = (e) => {
- var { angleAxisId: t } = e, n = Q(kG), r = Q((e) => t$(e, "angleAxis", t)), i = VV(), a = Q((e) => Fke(e, "angleAxis", t, i));
+ return /*#__PURE__*/ R.createElement(TI, { className: "recharts-polar-angle-axis-ticks" }, d);
+}, FAe = (e) => {
+ var { angleAxisId: t } = e, n = Q(kG), r = Q((e) => e$(e, "angleAxis", t)), i = HV(), a = Q((e) => Lke(e, "angleAxis", t, i));
if (n == null || !a || !a.length || r == null) return null;
- var o = b$(b$(b$({}, e), {}, { scale: r }, n), {}, {
+ var o = y$(y$(y$({}, e), {}, { scale: r }, n), {}, {
radius: n.outerRadius,
ticks: a
});
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: o.zIndex }, /*#__PURE__*/ R.createElement(wI, { className: ja("recharts-polar-angle-axis", TAe, o.className) }, /*#__PURE__*/ R.createElement(AAe, o), /*#__PURE__*/ R.createElement(MAe, o)));
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: o.zIndex }, /*#__PURE__*/ R.createElement(TI, { className: ja("recharts-polar-angle-axis", DAe, o.className) }, /*#__PURE__*/ R.createElement(MAe, o), /*#__PURE__*/ R.createElement(PAe, o)));
};
-function C$(e) {
- var t = JL(e, pG);
- return /*#__PURE__*/ R.createElement(EAe, {
+function S$(e) {
+ var t = YL(e, pG);
+ return /*#__PURE__*/ R.createElement(OAe, {
id: t.angleAxisId,
scale: t.scale,
type: t.type,
@@ -62722,12 +62774,12 @@ function C$(e) {
ticks: t.ticks,
tick: t.tick,
domain: t.domain
- }, /*#__PURE__*/ R.createElement(NAe, t));
+ }, /*#__PURE__*/ R.createElement(FAe, t));
}
-C$.displayName = "PolarAngleAxis";
+S$.displayName = "PolarAngleAxis";
//#endregion
//#region node_modules/react-is/cjs/react-is.production.js
-var PAe = /* @__PURE__ */ Ee(((e) => {
+var IAe = /* @__PURE__ */ Ee(((e) => {
var t = Symbol.for("react.transitional.element"), n = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), i = Symbol.for("react.strict_mode"), a = Symbol.for("react.profiler"), o = Symbol.for("react.consumer"), s = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), l = Symbol.for("react.suspense"), u = Symbol.for("react.suspense_list"), d = Symbol.for("react.memo"), f = Symbol.for("react.lazy"), p = Symbol.for("react.view_transition");
function m(e) {
if (typeof e == "object" && e) {
@@ -62756,26 +62808,26 @@ var PAe = /* @__PURE__ */ Ee(((e) => {
e.isFragment = function(e) {
return m(e) === r;
};
-})), FAe = (/* @__PURE__ */ Ee(((e, t) => {
- t.exports = PAe();
-})))(), w$ = (e) => typeof e == "string" ? e : e ? e.displayName || e.name || "Component" : "", T$ = null, E$ = null, D$ = (e) => {
- if (e === T$ && Array.isArray(E$)) return E$;
+})), LAe = (/* @__PURE__ */ Ee(((e, t) => {
+ t.exports = IAe();
+})))(), C$ = (e) => typeof e == "string" ? e : e ? e.displayName || e.name || "Component" : "", w$ = null, T$ = null, E$ = (e) => {
+ if (e === w$ && Array.isArray(T$)) return T$;
var t = [];
return R.Children.forEach(e, (e) => {
- FL(e) || ((0, FAe.isFragment)(e) ? t = t.concat(D$(e.props.children)) : t.push(e));
- }), E$ = t, T$ = e, t;
+ IL(e) || ((0, LAe.isFragment)(e) ? t = t.concat(E$(e.props.children)) : t.push(e));
+ }), T$ = t, w$ = e, t;
};
-function O$(e, t) {
+function D$(e, t) {
var n = [], r = [];
- return r = Array.isArray(t) ? t.map((e) => w$(e)) : [w$(t)], D$(e).forEach((e) => {
- var t = CL(e, "type.displayName") || CL(e, "type.name");
+ return r = Array.isArray(t) ? t.map((e) => C$(e)) : [C$(t)], E$(e).forEach((e) => {
+ var t = wL(e, "type.displayName") || wL(e, "type.name");
t && r.indexOf(t) !== -1 && n.push(e);
}), n;
}
-var k$ = (e) => e && typeof e == "object" && "clipDot" in e ? !!e.clipDot : !0;
+var O$ = (e) => e && typeof e == "object" && "clipDot" in e ? !!e.clipDot : !0;
//#endregion
//#region node_modules/es-toolkit/dist/compat/predicate/isPlainObject.mjs
-function IAe(e) {
+function RAe(e) {
if (typeof e != "object" || !e) return !1;
if (Object.getPrototypeOf(e) === null) return !0;
if (Object.prototype.toString.call(e) !== "[object Object]") {
@@ -62788,8 +62840,8 @@ function IAe(e) {
}
//#endregion
//#region node_modules/recharts/es6/shape/Trapezoid.js
-var LAe, RAe, zAe, BAe, VAe;
-function A$(e, t) {
+var zAe, BAe, VAe, HAe, UAe;
+function k$(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -62799,30 +62851,30 @@ function A$(e, t) {
}
return n;
}
-function j$(e) {
+function A$(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? A$(Object(n), !0).forEach(function(t) {
- HAe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : A$(Object(n)).forEach(function(t) {
+ t % 2 ? k$(Object(n), !0).forEach(function(t) {
+ WAe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : k$(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function HAe(e, t, n) {
- return (t = UAe(t)) in e ? Object.defineProperty(e, t, {
+function WAe(e, t, n) {
+ return (t = GAe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function UAe(e) {
- var t = WAe(e, "string");
+function GAe(e) {
+ var t = KAe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function WAe(e, t) {
+function KAe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -62832,42 +62884,42 @@ function WAe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function M$() {
- return M$ = Object.assign ? Object.assign.bind() : function(e) {
+function j$() {
+ return j$ = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, M$.apply(null, arguments);
+ }, j$.apply(null, arguments);
}
-function N$(e, t) {
+function M$(e, t) {
return t ||= e.slice(0), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } }));
}
-var P$ = (e, t, n, r, i) => {
- var a = n - r, o = TL(LAe ||= N$([
+var N$ = (e, t, n, r, i) => {
+ var a = n - r, o = EL(zAe ||= M$([
"M ",
",",
""
]), e, t);
- return o += TL(RAe ||= N$([
+ return o += EL(BAe ||= M$([
"L ",
",",
""
- ]), e + n, t), o += TL(zAe ||= N$([
+ ]), e + n, t), o += EL(VAe ||= M$([
"L ",
",",
""
- ]), e + n - a / 2, t + i), o += TL(BAe ||= N$([
+ ]), e + n - a / 2, t + i), o += EL(HAe ||= M$([
"L ",
",",
""
- ]), e + n - a / 2 - r, t + i), o += TL(VAe ||= N$([
+ ]), e + n - a / 2 - r, t + i), o += EL(UAe ||= M$([
"L ",
",",
" Z"
]), e, t), o;
-}, GAe = {
+}, qAe = {
x: 0,
y: 0,
upperWidth: 0,
@@ -62877,8 +62929,8 @@ var P$ = (e, t, n, r, i) => {
animationBegin: 0,
animationDuration: 1500,
animationEasing: "ease"
-}, KAe = (e) => {
- var t = JL(e, GAe), { x: n, y: r, upperWidth: i, lowerWidth: a, height: o, className: s } = t, { animationEasing: c, animationDuration: l, animationBegin: u, isUpdateAnimationActive: d } = t, f = (0, R.useRef)(null), [p, m] = (0, R.useState)(-1), h = (0, R.useRef)(i), g = (0, R.useRef)(a), _ = (0, R.useRef)(o), v = (0, R.useRef)(n), y = (0, R.useRef)(r), b = vW(e, "trapezoid-");
+}, JAe = (e) => {
+ var t = YL(e, qAe), { x: n, y: r, upperWidth: i, lowerWidth: a, height: o, className: s } = t, { animationEasing: c, animationDuration: l, animationBegin: u, isUpdateAnimationActive: d } = t, f = (0, R.useRef)(null), [p, m] = (0, R.useState)(-1), h = (0, R.useRef)(i), g = (0, R.useRef)(a), _ = (0, R.useRef)(o), v = (0, R.useRef)(n), y = (0, R.useRef)(r), b = vW(e, "trapezoid-");
if ((0, R.useEffect)(() => {
if (f.current && f.current.getTotalLength) try {
var e = f.current.getTotalLength();
@@ -62886,9 +62938,9 @@ var P$ = (e, t, n, r, i) => {
} catch {}
}, []), n !== +n || r !== +r || i !== +i || a !== +a || o !== +o || i === 0 && a === 0 || o === 0) return null;
var x = ja("recharts-trapezoid", s);
- if (!d) return /*#__PURE__*/ R.createElement("g", null, /*#__PURE__*/ R.createElement("path", M$({}, bI(t), {
+ if (!d) return /*#__PURE__*/ R.createElement("g", null, /*#__PURE__*/ R.createElement("path", j$({}, xI(t), {
className: x,
- d: P$(n, r, i, a, o)
+ d: N$(n, r, i, a, o)
})));
var S = h.current, C = g.current, w = _.current, T = v.current, E = y.current, D = `0px ${p === -1 ? 1 : p}px`, O = `${p}px ${p}px`, k = iW(["strokeDasharray"], l, c);
return /*#__PURE__*/ R.createElement(_W, {
@@ -62900,35 +62952,35 @@ var P$ = (e, t, n, r, i) => {
isActive: d,
begin: u
}, (e) => {
- var s = NL(S, i, e), c = NL(C, a, e), l = NL(w, o, e), u = NL(T, n, e), d = NL(E, r, e);
+ var s = PL(S, i, e), c = PL(C, a, e), l = PL(w, o, e), u = PL(T, n, e), d = PL(E, r, e);
f.current && (h.current = s, g.current = c, _.current = l, v.current = u, y.current = d);
var p = e > 0 ? {
transition: k,
strokeDasharray: O
} : { strokeDasharray: D };
- return /*#__PURE__*/ R.createElement("path", M$({}, bI(t), {
+ return /*#__PURE__*/ R.createElement("path", j$({}, xI(t), {
className: x,
- d: P$(u, d, s, c, l),
+ d: N$(u, d, s, c, l),
ref: f,
- style: j$(j$({}, p), t.style)
+ style: A$(A$({}, p), t.style)
}));
});
-}, qAe = [
+}, YAe = [
"option",
"shapeType",
"activeClassName",
"inActiveClassName"
];
-function JAe(e, t) {
+function XAe(e, t) {
if (e == null) return {};
- var n, r, i = YAe(e, t);
+ var n, r, i = ZAe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function YAe(e, t) {
+function ZAe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -62937,7 +62989,7 @@ function YAe(e, t) {
}
return n;
}
-function F$(e, t) {
+function P$(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -62947,30 +62999,30 @@ function F$(e, t) {
}
return n;
}
-function I$(e) {
+function F$(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? F$(Object(n), !0).forEach(function(t) {
- XAe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : F$(Object(n)).forEach(function(t) {
+ t % 2 ? P$(Object(n), !0).forEach(function(t) {
+ QAe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : P$(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function XAe(e, t, n) {
- return (t = ZAe(t)) in e ? Object.defineProperty(e, t, {
+function QAe(e, t, n) {
+ return (t = $Ae(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function ZAe(e) {
- var t = QAe(e, "string");
+function $Ae(e) {
+ var t = eje(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function QAe(e, t) {
+function eje(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -62980,51 +63032,51 @@ function QAe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function $Ae(e, t) {
- return I$(I$({}, t), e);
+function tje(e, t) {
+ return F$(F$({}, t), e);
}
-function eje(e, t) {
+function nje(e, t) {
return e === "symbols";
}
-function L$(e) {
+function I$(e) {
var { shapeType: t, elementProps: n } = e;
switch (t) {
case "rectangle": return /*#__PURE__*/ R.createElement(EW, n);
- case "trapezoid": return /*#__PURE__*/ R.createElement(KAe, n);
+ case "trapezoid": return /*#__PURE__*/ R.createElement(JAe, n);
case "sector": return /*#__PURE__*/ R.createElement(LW, n);
case "symbols":
- if (eje(t, n)) return /*#__PURE__*/ R.createElement(UL, n);
+ if (nje(t, n)) return /*#__PURE__*/ R.createElement(WL, n);
break;
case "curve": return /*#__PURE__*/ R.createElement($U, n);
default: return null;
}
}
-function tje(e) {
+function rje(e) {
return /*#__PURE__*/ (0, R.isValidElement)(e) ? e.props : e;
}
-function R$(e) {
- var { option: t, shapeType: n, activeClassName: r = "recharts-active-shape", inActiveClassName: i = "recharts-shape" } = e, a = JAe(e, qAe), o;
- if (/*#__PURE__*/ (0, R.isValidElement)(t)) o = /*#__PURE__*/ (0, R.cloneElement)(t, I$(I$({}, a), tje(t)));
+function L$(e) {
+ var { option: t, shapeType: n, activeClassName: r = "recharts-active-shape", inActiveClassName: i = "recharts-shape" } = e, a = XAe(e, YAe), o;
+ if (/*#__PURE__*/ (0, R.isValidElement)(t)) o = /*#__PURE__*/ (0, R.cloneElement)(t, F$(F$({}, a), rje(t)));
else if (typeof t == "function") o = t(a, a.index);
- else if (IAe(t) && typeof t != "boolean") {
- var s = $Ae(t, a);
- o = /*#__PURE__*/ R.createElement(L$, {
+ else if (RAe(t) && typeof t != "boolean") {
+ var s = tje(t, a);
+ o = /*#__PURE__*/ R.createElement(I$, {
shapeType: n,
elementProps: s
});
} else {
var c = a;
- o = /*#__PURE__*/ R.createElement(L$, {
+ o = /*#__PURE__*/ R.createElement(I$, {
shapeType: n,
elementProps: c
});
}
- return a.isActive ? /*#__PURE__*/ R.createElement(wI, { className: r }, o) : /*#__PURE__*/ R.createElement(wI, { className: i }, o);
+ return a.isActive ? /*#__PURE__*/ R.createElement(TI, { className: r }, o) : /*#__PURE__*/ R.createElement(TI, { className: i }, o);
}
//#endregion
//#region node_modules/recharts/es6/context/tooltipContext.js
-var z$ = (e, t, n) => {
- var r = xR();
+var R$ = (e, t, n) => {
+ var r = SR();
return (i, a) => (o) => {
e?.(i, a, o), r(OX({
activeIndex: String(a),
@@ -63033,15 +63085,15 @@ var z$ = (e, t, n) => {
activeGraphicalItemId: n
}));
};
-}, B$ = (e) => {
- var t = xR();
+}, z$ = (e) => {
+ var t = SR();
return (n, r) => (i) => {
- e?.(n, r, i), t(VEe());
+ e?.(n, r, i), t(HEe());
};
-}, V$ = (e, t, n) => {
- var r = xR();
+}, B$ = (e, t, n) => {
+ var r = SR();
return (i, a) => (o) => {
- e?.(i, a, o), r(HEe({
+ e?.(i, a, o), r(UEe({
activeIndex: String(a),
activeDataKey: t,
activeCoordinate: i.tooltipPosition,
@@ -63051,10 +63103,10 @@ var z$ = (e, t, n) => {
};
//#endregion
//#region node_modules/recharts/es6/state/SetTooltipEntrySettings.js
-function H$(e) {
- var { tooltipEntrySettings: t } = e, n = xR(), r = VV(), i = (0, R.useRef)(null);
+function V$(e) {
+ var { tooltipEntrySettings: t } = e, n = SR(), r = HV(), i = (0, R.useRef)(null);
return (0, R.useLayoutEffect)(() => {
- r || (i.current === null ? n(LEe(t)) : i.current !== t && n(REe({
+ r || (i.current === null ? n(REe(t)) : i.current !== t && n(zEe({
prev: i.current,
next: t
})), i.current = t);
@@ -63063,13 +63115,13 @@ function H$(e) {
n,
r
]), (0, R.useLayoutEffect)(() => () => {
- i.current &&= (n(zEe(i.current)), null);
+ i.current &&= (n(BEe(i.current)), null);
}, [n]), null;
}
//#endregion
//#region node_modules/recharts/es6/state/SetLegendPayload.js
-function U$(e) {
- var { legendPayload: t } = e, n = xR(), r = VV(), i = (0, R.useRef)(null);
+function H$(e) {
+ var { legendPayload: t } = e, n = SR(), r = HV(), i = (0, R.useRef)(null);
return (0, R.useLayoutEffect)(() => {
r || (i.current === null ? n(CU(t)) : i.current !== t && n(wU({
prev: i.current,
@@ -63083,8 +63135,8 @@ function U$(e) {
i.current &&= (n(TU(i.current)), null);
}, [n]), null;
}
-function W$(e) {
- var { legendPayload: t } = e, n = xR(), r = Q(xH), i = (0, R.useRef)(null);
+function U$(e) {
+ var { legendPayload: t } = e, n = SR(), r = Q(SH), i = (0, R.useRef)(null);
return (0, R.useLayoutEffect)(() => {
(r === "centric" || r === "radial") && (i.current === null ? n(CU(t)) : i.current !== t && n(wU({
prev: i.current,
@@ -63100,22 +63152,22 @@ function W$(e) {
}
//#endregion
//#region node_modules/recharts/es6/util/useId.js
-var nje = R.useId ?? (() => {
- var [e] = R.useState(() => AL("uid-"));
+var ije = R.useId ?? (() => {
+ var [e] = R.useState(() => jL("uid-"));
return e;
});
//#endregion
//#region node_modules/recharts/es6/util/useUniqueId.js
-function rje(e, t) {
- var n = nje();
+function aje(e, t) {
+ var n = ije();
return t || (e ? `${e}-${n}` : n);
}
//#endregion
//#region node_modules/recharts/es6/context/RegisterGraphicalItemId.js
-var ije = /*#__PURE__*/ (0, R.createContext)(void 0), G$ = (e) => {
- var { id: t, type: n, children: r } = e, i = rje(`recharts-${n}`, t);
- return /*#__PURE__*/ R.createElement(ije.Provider, { value: i }, r(i));
-}, K$ = oB({
+var oje = /*#__PURE__*/ (0, R.createContext)(void 0), W$ = (e) => {
+ var { id: t, type: n, children: r } = e, i = aje(`recharts-${n}`, t);
+ return /*#__PURE__*/ R.createElement(oje.Provider, { value: i }, r(i));
+}, G$ = sB({
name: "graphicalItems",
initialState: {
cartesianItems: [],
@@ -63126,78 +63178,78 @@ var ije = /*#__PURE__*/ (0, R.createContext)(void 0), G$ = (e) => {
reducer(e, t) {
e.cartesianItems.push(bU(t.payload));
},
- prepare: nB()
+ prepare: rB()
},
replaceCartesianGraphicalItem: {
reducer(e, t) {
- var { prev: n, next: r } = t.payload, i = qz(e).cartesianItems.indexOf(bU(n));
+ var { prev: n, next: r } = t.payload, i = Jz(e).cartesianItems.indexOf(bU(n));
i > -1 && (e.cartesianItems[i] = bU(r));
},
- prepare: nB()
+ prepare: rB()
},
removeCartesianGraphicalItem: {
reducer(e, t) {
- var n = qz(e).cartesianItems.indexOf(bU(t.payload));
+ var n = Jz(e).cartesianItems.indexOf(bU(t.payload));
n > -1 && e.cartesianItems.splice(n, 1);
},
- prepare: nB()
+ prepare: rB()
},
addPolarGraphicalItem: {
reducer(e, t) {
e.polarItems.push(bU(t.payload));
},
- prepare: nB()
+ prepare: rB()
},
removePolarGraphicalItem: {
reducer(e, t) {
- var n = qz(e).polarItems.indexOf(bU(t.payload));
+ var n = Jz(e).polarItems.indexOf(bU(t.payload));
n > -1 && e.polarItems.splice(n, 1);
},
- prepare: nB()
+ prepare: rB()
},
replacePolarGraphicalItem: {
reducer(e, t) {
- var { prev: n, next: r } = t.payload, i = qz(e).polarItems.indexOf(bU(n));
+ var { prev: n, next: r } = t.payload, i = Jz(e).polarItems.indexOf(bU(n));
i > -1 && (e.polarItems[i] = bU(r));
},
- prepare: nB()
+ prepare: rB()
}
}
-}), { addCartesianGraphicalItem: aje, replaceCartesianGraphicalItem: oje, removeCartesianGraphicalItem: sje, addPolarGraphicalItem: cje, removePolarGraphicalItem: lje, replacePolarGraphicalItem: uje } = K$.actions, dje = K$.reducer, q$ = /*#__PURE__*/ (0, R.memo)((e) => {
- var t = xR(), n = (0, R.useRef)(null);
+}), { addCartesianGraphicalItem: sje, replaceCartesianGraphicalItem: cje, removeCartesianGraphicalItem: lje, addPolarGraphicalItem: uje, removePolarGraphicalItem: dje, replacePolarGraphicalItem: fje } = G$.actions, pje = G$.reducer, K$ = /*#__PURE__*/ (0, R.memo)((e) => {
+ var t = SR(), n = (0, R.useRef)(null);
return (0, R.useLayoutEffect)(() => {
- n.current === null ? t(aje(e)) : n.current !== e && t(oje({
+ n.current === null ? t(sje(e)) : n.current !== e && t(cje({
prev: n.current,
next: e
})), n.current = e;
}, [t, e]), (0, R.useLayoutEffect)(() => () => {
- n.current &&= (t(sje(n.current)), null);
+ n.current &&= (t(lje(n.current)), null);
}, [t]), null;
-}), J$ = /*#__PURE__*/ (0, R.memo)((e) => {
- var t = xR(), n = (0, R.useRef)(null);
+}), q$ = /*#__PURE__*/ (0, R.memo)((e) => {
+ var t = SR(), n = (0, R.useRef)(null);
return (0, R.useLayoutEffect)(() => {
- n.current === null ? t(cje(e)) : n.current !== e && t(uje({
+ n.current === null ? t(uje(e)) : n.current !== e && t(fje({
prev: n.current,
next: e
})), n.current = e;
}, [t, e]), (0, R.useLayoutEffect)(() => () => {
- n.current &&= (t(lje(n.current)), null);
+ n.current &&= (t(dje(n.current)), null);
}, [t]), null;
});
//#endregion
//#region node_modules/es-toolkit/dist/array/last.mjs
-function fje(e) {
+function mje(e) {
return e[e.length - 1];
}
//#endregion
//#region node_modules/es-toolkit/dist/compat/array/last.mjs
-function pje(e) {
- if (!(!eR(e) || e.length === 0)) return fje(u$(e));
+function hje(e) {
+ if (!(!tR(e) || e.length === 0)) return mje(l$(e));
}
//#endregion
//#region node_modules/recharts/es6/component/Dots.js
-var mje = ["points"];
-function Y$(e, t) {
+var gje = ["points"];
+function J$(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -63207,30 +63259,30 @@ function Y$(e, t) {
}
return n;
}
-function X$(e) {
+function Y$(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? Y$(Object(n), !0).forEach(function(t) {
- hje(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : Y$(Object(n)).forEach(function(t) {
+ t % 2 ? J$(Object(n), !0).forEach(function(t) {
+ _je(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : J$(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function hje(e, t, n) {
- return (t = gje(t)) in e ? Object.defineProperty(e, t, {
+function _je(e, t, n) {
+ return (t = vje(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function gje(e) {
- var t = _je(e, "string");
+function vje(e) {
+ var t = yje(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function _je(e, t) {
+function yje(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -63240,25 +63292,25 @@ function _je(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function Z$() {
- return Z$ = Object.assign ? Object.assign.bind() : function(e) {
+function X$() {
+ return X$ = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, Z$.apply(null, arguments);
+ }, X$.apply(null, arguments);
}
-function vje(e, t) {
+function bje(e, t) {
if (e == null) return {};
- var n, r, i = yje(e, t);
+ var n, r, i = xje(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function yje(e, t) {
+function xje(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -63267,21 +63319,21 @@ function yje(e, t) {
}
return n;
}
-function bje(e) {
+function Sje(e) {
var { option: t, dotProps: n, className: r } = e;
if (/*#__PURE__*/ (0, R.isValidElement)(t)) return /*#__PURE__*/ (0, R.cloneElement)(t, n);
if (typeof t == "function") return t(n);
- var i = ja(r, typeof t == "boolean" ? "" : t.className), a = n ?? {}, { points: o } = a, s = vje(a, mje);
- return /*#__PURE__*/ R.createElement(GQ, Z$({}, s, { className: i }));
+ var i = ja(r, typeof t == "boolean" ? "" : t.className), a = n ?? {}, { points: o } = a, s = bje(a, gje);
+ return /*#__PURE__*/ R.createElement(WQ, X$({}, s, { className: i }));
}
-function xje(e, t) {
+function Cje(e, t) {
return e == null ? !1 : t ? !0 : e.length === 1;
}
-function Q$(e) {
+function Z$(e) {
var { points: t, dot: n, className: r, dotClassName: i, dataKey: a, baseProps: o, needClip: s, clipPathId: c, zIndex: l = fG.scatter } = e;
- if (!xje(t, n)) return null;
- var u = k$(n), d = j_e(n), f = t.map((e, r) => {
- var s = X$(X$(X$({ r: 3 }, o), d), {}, {
+ if (!Cje(t, n)) return null;
+ var u = O$(n), d = j_e(n), f = t.map((e, r) => {
+ var s = Y$(Y$(Y$({ r: 3 }, o), d), {}, {
index: r,
cx: e.x ?? void 0,
cy: e.y ?? void 0,
@@ -63290,18 +63342,18 @@ function Q$(e) {
payload: e.payload,
points: t
});
- return /*#__PURE__*/ R.createElement(bje, {
+ return /*#__PURE__*/ R.createElement(Sje, {
key: `dot-${r}`,
option: n,
dotProps: s,
className: i
});
}), p = {};
- return s && c != null && (p.clipPath = `url(#clipPath-${u ? "" : "dots-"}${c})`), /*#__PURE__*/ R.createElement(DZ, { zIndex: l }, /*#__PURE__*/ R.createElement(wI, Z$({ className: r }, p), f));
+ return s && c != null && (p.clipPath = `url(#clipPath-${u ? "" : "dots-"}${c})`), /*#__PURE__*/ R.createElement(DZ, { zIndex: l }, /*#__PURE__*/ R.createElement(TI, X$({ className: r }, p), f));
}
//#endregion
//#region node_modules/recharts/es6/state/cartesianAxisSlice.js
-function $$(e, t) {
+function Q$(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -63311,30 +63363,30 @@ function $$(e, t) {
}
return n;
}
-function e1(e) {
+function $$(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? $$(Object(n), !0).forEach(function(t) {
- Sje(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : $$(Object(n)).forEach(function(t) {
+ t % 2 ? Q$(Object(n), !0).forEach(function(t) {
+ wje(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : Q$(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function Sje(e, t, n) {
- return (t = Cje(t)) in e ? Object.defineProperty(e, t, {
+function wje(e, t, n) {
+ return (t = Tje(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function Cje(e) {
- var t = wje(e, "string");
+function Tje(e) {
+ var t = Eje(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function wje(e, t) {
+function Eje(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -63344,7 +63396,7 @@ function wje(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var t1 = oB({
+var e1 = sB({
name: "cartesianAxis",
initialState: {
xAxis: {},
@@ -63356,58 +63408,58 @@ var t1 = oB({
reducer(e, t) {
e.xAxis[t.payload.id] = bU(t.payload);
},
- prepare: nB()
+ prepare: rB()
},
replaceXAxis: {
reducer(e, t) {
var { prev: n, next: r } = t.payload;
e.xAxis[n.id] !== void 0 && (n.id !== r.id && delete e.xAxis[n.id], e.xAxis[r.id] = bU(r));
},
- prepare: nB()
+ prepare: rB()
},
removeXAxis: {
reducer(e, t) {
delete e.xAxis[t.payload.id];
},
- prepare: nB()
+ prepare: rB()
},
addYAxis: {
reducer(e, t) {
e.yAxis[t.payload.id] = bU(t.payload);
},
- prepare: nB()
+ prepare: rB()
},
replaceYAxis: {
reducer(e, t) {
var { prev: n, next: r } = t.payload;
e.yAxis[n.id] !== void 0 && (n.id !== r.id && delete e.yAxis[n.id], e.yAxis[r.id] = bU(r));
},
- prepare: nB()
+ prepare: rB()
},
removeYAxis: {
reducer(e, t) {
delete e.yAxis[t.payload.id];
},
- prepare: nB()
+ prepare: rB()
},
addZAxis: {
reducer(e, t) {
e.zAxis[t.payload.id] = bU(t.payload);
},
- prepare: nB()
+ prepare: rB()
},
replaceZAxis: {
reducer(e, t) {
var { prev: n, next: r } = t.payload;
e.zAxis[n.id] !== void 0 && (n.id !== r.id && delete e.zAxis[n.id], e.zAxis[r.id] = bU(r));
},
- prepare: nB()
+ prepare: rB()
},
removeZAxis: {
reducer(e, t) {
delete e.zAxis[t.payload.id];
},
- prepare: nB()
+ prepare: rB()
},
updateYAxisWidth(e, t) {
var { id: n, width: r } = t.payload, i = e.yAxis[n];
@@ -63415,22 +63467,22 @@ var t1 = oB({
var a = i.widthHistory || [];
if (a.length === 3 && a[0] === a[2] && r === a[1] && r !== i.width && Math.abs(r - (a[0] ?? 0)) <= 1) return;
var o = [...a, r].slice(-3);
- e.yAxis[n] = e1(e1({}, i), {}, {
+ e.yAxis[n] = $$($$({}, i), {}, {
width: r,
widthHistory: o
});
}
}
}
-}), { addXAxis: Tje, replaceXAxis: Eje, removeXAxis: Dje, addYAxis: Oje, replaceYAxis: kje, removeYAxis: Aje, addZAxis: jje, replaceZAxis: Mje, removeZAxis: Nje, updateYAxisWidth: Pje } = t1.actions, Fje = t1.reducer, Ije = $([
- $([LV], (e) => ({
+}), { addXAxis: Dje, replaceXAxis: Oje, removeXAxis: kje, addYAxis: Aje, replaceYAxis: jje, removeYAxis: Mje, addZAxis: Nje, replaceZAxis: Pje, removeZAxis: Fje, updateYAxisWidth: Ije } = e1.actions, Lje = e1.reducer, Rje = $([
+ $([RV], (e) => ({
top: e.top,
bottom: e.bottom,
left: e.left,
right: e.right
})),
- bV,
- xV
+ xV,
+ SV
], (e, t, n) => {
if (!(!e || t == null || n == null)) return {
x: e.left,
@@ -63438,10 +63490,10 @@ var t1 = oB({
width: Math.max(0, t - e.left - e.right),
height: Math.max(0, n - e.top - e.bottom)
};
-}), n1 = () => Q(Ije), Lje = () => Q(_De);
+}), t1 = () => Q(Rje), zje = () => Q(vDe);
//#endregion
//#region node_modules/recharts/es6/component/ActivePoints.js
-function r1(e, t) {
+function n1(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -63451,30 +63503,30 @@ function r1(e, t) {
}
return n;
}
-function i1(e) {
+function r1(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? r1(Object(n), !0).forEach(function(t) {
- Rje(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : r1(Object(n)).forEach(function(t) {
+ t % 2 ? n1(Object(n), !0).forEach(function(t) {
+ Bje(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : n1(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function Rje(e, t, n) {
- return (t = zje(t)) in e ? Object.defineProperty(e, t, {
+function Bje(e, t, n) {
+ return (t = Vje(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function zje(e) {
- var t = Bje(e, "string");
+function Vje(e) {
+ var t = Hje(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function Bje(e, t) {
+function Hje(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -63484,10 +63536,10 @@ function Bje(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var Vje = (e) => {
+var Uje = (e) => {
var { point: t, childIndex: n, mainColor: r, activeDot: i, dataKey: a, clipPath: o } = e;
if (i === !1 || t.x == null || t.y == null) return null;
- var s = i1(i1(i1({}, {
+ var s = r1(r1(r1({}, {
index: n,
dataKey: a,
cx: t.x,
@@ -63498,17 +63550,17 @@ var Vje = (e) => {
stroke: "#fff",
payload: t.payload,
value: t.value
- }), yI(i)), GL(i)), c = /*#__PURE__*/ (0, R.isValidElement)(i) ? /*#__PURE__*/ (0, R.cloneElement)(i, s) : typeof i == "function" ? i(s) : /*#__PURE__*/ R.createElement(GQ, s);
- return /*#__PURE__*/ R.createElement(wI, {
+ }), bI(i)), KL(i)), c = /*#__PURE__*/ (0, R.isValidElement)(i) ? /*#__PURE__*/ (0, R.cloneElement)(i, s) : typeof i == "function" ? i(s) : /*#__PURE__*/ R.createElement(WQ, s);
+ return /*#__PURE__*/ R.createElement(TI, {
className: "recharts-active-dot",
clipPath: o
}, c);
};
-function a1(e) {
- var { points: t, mainColor: n, activeDot: r, itemDataKey: i, clipPath: a, zIndex: o = fG.activeDot } = e, s = Q(oZ), c = Lje();
+function i1(e) {
+ var { points: t, mainColor: n, activeDot: r, itemDataKey: i, clipPath: a, zIndex: o = fG.activeDot } = e, s = Q(oZ), c = zje();
if (t == null || c == null) return null;
var l = t.find((e) => c.includes(e.payload));
- return FL(l) ? null : /*#__PURE__*/ R.createElement(DZ, { zIndex: o }, /*#__PURE__*/ R.createElement(Vje, {
+ return IL(l) ? null : /*#__PURE__*/ R.createElement(DZ, { zIndex: o }, /*#__PURE__*/ R.createElement(Uje, {
point: l,
childIndex: Number(s),
mainColor: n,
@@ -63519,7 +63571,7 @@ function a1(e) {
}
//#endregion
//#region node_modules/recharts/es6/state/selectors/radarSelectors.js
-function o1(e, t) {
+function a1(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -63529,30 +63581,30 @@ function o1(e, t) {
}
return n;
}
-function s1(e) {
+function o1(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? o1(Object(n), !0).forEach(function(t) {
- Hje(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : o1(Object(n)).forEach(function(t) {
+ t % 2 ? a1(Object(n), !0).forEach(function(t) {
+ Wje(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : a1(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function Hje(e, t, n) {
- return (t = Uje(t)) in e ? Object.defineProperty(e, t, {
+function Wje(e, t, n) {
+ return (t = Gje(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function Uje(e) {
- var t = Wje(e, "string");
+function Gje(e) {
+ var t = Kje(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function Wje(e, t) {
+function Kje(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -63562,15 +63614,15 @@ function Wje(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var c1 = (e, t) => t$(e, "radiusAxis", t), Gje = $([c1], (e) => {
+var s1 = (e, t) => e$(e, "radiusAxis", t), qje = $([s1], (e) => {
if (e != null) return { scale: e };
-}), Kje = $([SG, c1], (e, t) => {
- if (e != null && t != null) return s1(s1({}, e), {}, { scale: t });
-}), qje = (e, t, n, r) => r$(e, "radiusAxis", t, r), l1 = (e, t, n) => xG(e, n), u1 = (e, t, n) => t$(e, "angleAxis", n), Jje = $([l1, u1], (e, t) => {
- if (e != null && t != null) return s1(s1({}, e), {}, { scale: t });
-}), Yje = (e, t, n, r) => r$(e, "angleAxis", n, r), Xje = $([
+}), Jje = $([SG, s1], (e, t) => {
+ if (e != null && t != null) return o1(o1({}, e), {}, { scale: t });
+}), Yje = (e, t, n, r) => n$(e, "radiusAxis", t, r), c1 = (e, t, n) => xG(e, n), l1 = (e, t, n) => e$(e, "angleAxis", n), Xje = $([c1, l1], (e, t) => {
+ if (e != null && t != null) return o1(o1({}, e), {}, { scale: t });
+}), Zje = (e, t, n, r) => n$(e, "angleAxis", n, r), Qje = $([
+ c1,
l1,
- u1,
kG
], (e, t, n) => {
if (n != null && t != null) return {
@@ -63580,40 +63632,40 @@ var c1 = (e, t) => t$(e, "radiusAxis", t), Gje = $([c1], (e) => {
cx: n.cx,
cy: n.cy
};
-}), Zje = (e, t, n, r, i) => i, Qje = $([
- xH,
- Kje,
- qje,
+}), $je = (e, t, n, r, i) => i, eMe = $([
+ SH,
Jje,
- Yje
-], (e, t, n, r, i) => eV(e, "radiusAxis") ? hV(t, n, !1) : hV(r, i, !1)), $je = $([
- Gje,
+ Yje,
Xje,
+ Zje
+], (e, t, n, r, i) => tV(e, "radiusAxis") ? gV(t, n, !1) : gV(r, i, !1)), tMe = $([
+ qje,
+ Qje,
VW,
- $([KQ, Zje], (e, t) => {
+ $([GQ, $je], (e, t) => {
if (e != null) return e.find((e) => e.type === "radar" && t === e.id)?.dataKey;
}),
- Qje
+ eMe
], (e, t, n, r, i) => {
var { chartData: a, dataStartIndex: o, dataEndIndex: s } = n;
- if (e != null && t != null && a != null && i != null && r != null) return lMe({
+ if (e != null && t != null && a != null && i != null && r != null) return dMe({
radiusAxis: e,
angleAxis: t,
displayedData: a.slice(o, s + 1),
dataKey: r,
bandSize: i
});
-}), eMe = ["id"];
-function d1() {
- return d1 = Object.assign ? Object.assign.bind() : function(e) {
+}), nMe = ["id"];
+function u1() {
+ return u1 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, d1.apply(null, arguments);
+ }, u1.apply(null, arguments);
}
-function f1(e, t) {
+function d1(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -63623,30 +63675,30 @@ function f1(e, t) {
}
return n;
}
-function p1(e) {
+function f1(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? f1(Object(n), !0).forEach(function(t) {
- tMe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : f1(Object(n)).forEach(function(t) {
+ t % 2 ? d1(Object(n), !0).forEach(function(t) {
+ rMe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : d1(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function tMe(e, t, n) {
- return (t = nMe(t)) in e ? Object.defineProperty(e, t, {
+function rMe(e, t, n) {
+ return (t = iMe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function nMe(e) {
- var t = rMe(e, "string");
+function iMe(e) {
+ var t = aMe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function rMe(e, t) {
+function aMe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -63656,16 +63708,16 @@ function rMe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function iMe(e, t) {
+function oMe(e, t) {
if (e == null) return {};
- var n, r, i = aMe(e, t);
+ var n, r, i = sMe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function aMe(e, t) {
+function sMe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -63674,42 +63726,42 @@ function aMe(e, t) {
}
return n;
}
-function m1(e, t) {
+function p1(e, t) {
return e && e !== "none" ? e : t;
}
-var oMe = (e) => {
+var cMe = (e) => {
var { dataKey: t, name: n, stroke: r, fill: i, legendType: a, hide: o } = e;
return [{
inactive: o,
dataKey: t,
type: a,
- color: m1(r, i),
- value: _V(n, t),
+ color: p1(r, i),
+ value: vV(n, t),
payload: e
}];
-}, sMe = /*#__PURE__*/ R.memo((e) => {
+}, lMe = /*#__PURE__*/ R.memo((e) => {
var { dataKey: t, stroke: n, strokeWidth: r, fill: i, name: a, hide: o, tooltipType: s, id: c } = e, l = {
dataDefinedOnItem: void 0,
- getPosition: RL,
+ getPosition: zL,
settings: {
stroke: n,
strokeWidth: r,
fill: i,
nameKey: void 0,
dataKey: t,
- name: _V(a, t),
+ name: vV(a, t),
hide: o,
type: s,
- color: m1(n, i),
+ color: p1(n, i),
unit: "",
graphicalItemId: c
}
};
- return /*#__PURE__*/ R.createElement(H$, { tooltipEntrySettings: l });
+ return /*#__PURE__*/ R.createElement(V$, { tooltipEntrySettings: l });
});
-function cMe(e) {
- var { points: t, props: n } = e, { dot: r, dataKey: i } = n, { id: a } = n, o = vI(iMe(n, eMe));
- return /*#__PURE__*/ R.createElement(Q$, {
+function uMe(e) {
+ var { points: t, props: n } = e, { dot: r, dataKey: i } = n, { id: a } = n, o = yI(oMe(n, nMe));
+ return /*#__PURE__*/ R.createElement(Z$, {
points: t,
dot: r,
className: "recharts-radar-dots",
@@ -63718,11 +63770,11 @@ function cMe(e) {
baseProps: o
});
}
-function lMe(e) {
+function dMe(e) {
var { radiusAxis: t, angleAxis: n, displayedData: r, dataKey: i, bandSize: a } = e, { cx: o, cy: s } = n, c = !1, l = [], u = n.type === "number" ? 0 : a ?? 0;
r.forEach((e, r) => {
- var a = QB(e, n.dataKey, r), d = QB(e, i), f = (n.scale.map(a) ?? 0) + u, p = Array.isArray(d) ? pje(d) : d, m = FL(p) ? 0 : t.scale.map(p) ?? 0;
- Array.isArray(d) && d.length >= 2 && (c = !0), l.push(p1(p1({}, jW(o, s, m, f)), {}, {
+ var a = $B(e, n.dataKey, r), d = $B(e, i), f = (n.scale.map(a) ?? 0) + u, p = Array.isArray(d) ? hje(d) : d, m = IL(p) ? 0 : t.scale.map(p) ?? 0;
+ Array.isArray(d) && d.length >= 2 && (c = !0), l.push(f1(f1({}, jW(o, s, m, f)), {}, {
name: a,
value: d,
cx: o,
@@ -63735,8 +63787,8 @@ function lMe(e) {
var d = [];
return c && l.forEach((e) => {
if (Array.isArray(e.value)) {
- var n = e.value[0], r = FL(n) ? 0 : t.scale.map(n) ?? 0;
- d.push(p1(p1({}, e), {}, { radius: r }, jW(o, s, r, e.angle)));
+ var n = e.value[0], r = IL(n) ? 0 : t.scale.map(n) ?? 0;
+ d.push(f1(f1({}, e), {}, { radius: r }, jW(o, s, r, e.angle)));
} else d.push(e);
}), {
points: l,
@@ -63744,7 +63796,7 @@ function lMe(e) {
baseLinePoints: d
};
}
-function uMe(e) {
+function fMe(e) {
var { showLabels: t, points: n, children: r } = e, i = n.map((e) => {
var t = {
x: e.x,
@@ -63754,7 +63806,7 @@ function uMe(e) {
upperWidth: 0,
height: 0
};
- return p1(p1({}, t), {}, {
+ return f1(f1({}, t), {}, {
value: e.value ?? "",
payload: e.payload,
parentViewBox: void 0,
@@ -63762,12 +63814,12 @@ function uMe(e) {
fill: void 0
});
});
- return /*#__PURE__*/ R.createElement(IQ, { value: t ? i : void 0 }, r);
+ return /*#__PURE__*/ R.createElement(FQ, { value: t ? i : void 0 }, r);
}
-function dMe(e) {
+function pMe(e) {
var { points: t, baseLinePoints: n, props: r } = e;
if (t == null) return null;
- var { shape: i, isRange: a, connectNulls: o } = r, s = /*#__PURE__*/ R.isValidElement(i) ? /*#__PURE__*/ R.cloneElement(i, p1(p1({}, r), {}, { points: t })) : typeof i == "function" ? i(p1(p1({}, r), {}, { points: t })) : /*#__PURE__*/ R.createElement(UQ, d1({}, bI(r), {
+ var { shape: i, isRange: a, connectNulls: o } = r, s = /*#__PURE__*/ R.isValidElement(i) ? /*#__PURE__*/ R.cloneElement(i, f1(f1({}, r), {}, { points: t })) : typeof i == "function" ? i(f1(f1({}, r), {}, { points: t })) : /*#__PURE__*/ R.createElement(HQ, u1({}, xI(r), {
onMouseEnter: (e) => {
var { onMouseEnter: t } = r;
t && t(r, e);
@@ -63780,28 +63832,28 @@ function dMe(e) {
baseLinePoints: a ? n : void 0,
connectNulls: o
}));
- return /*#__PURE__*/ R.createElement(wI, { className: "recharts-radar-polygon" }, s, /*#__PURE__*/ R.createElement(cMe, {
+ return /*#__PURE__*/ R.createElement(TI, { className: "recharts-radar-polygon" }, s, /*#__PURE__*/ R.createElement(uMe, {
props: r,
points: t
}));
}
-var h1 = (e, t, n) => (r, i) => {
+var m1 = (e, t, n) => (r, i) => {
var a = e && e[Math.floor(i * t)];
- return a ? p1(p1({}, r), {}, {
- x: NL(a.x, r.x, n),
- y: NL(a.y, r.y, n)
- }) : p1(p1({}, r), {}, {
- x: NL(r.cx, r.x, n),
- y: NL(r.cy, r.y, n)
+ return a ? f1(f1({}, r), {}, {
+ x: PL(a.x, r.x, n),
+ y: PL(a.y, r.y, n)
+ }) : f1(f1({}, r), {}, {
+ x: PL(r.cx, r.x, n),
+ y: PL(r.cy, r.y, n)
});
};
-function fMe(e) {
+function mMe(e) {
var { props: t, previousPointsRef: n, previousBaseLinePointsRef: r } = e, { points: i, baseLinePoints: a, isAnimationActive: o, animationBegin: s, animationDuration: c, animationEasing: l, onAnimationEnd: u, onAnimationStart: d } = t, f = n.current, p = r.current, m = f ? f.length / i.length : 1, h = p ? p.length / a.length : 1, g = vW(t, "recharts-radar-"), [_, v] = (0, R.useState)(!1), y = !_, b = (0, R.useCallback)(() => {
typeof u == "function" && u(), v(!1);
}, [u]), x = (0, R.useCallback)(() => {
typeof d == "function" && d(), v(!0);
}, [d]);
- return /*#__PURE__*/ R.createElement(uMe, {
+ return /*#__PURE__*/ R.createElement(fMe, {
showLabels: y,
points: i
}, /*#__PURE__*/ R.createElement(_W, {
@@ -63814,23 +63866,23 @@ function fMe(e) {
onAnimationEnd: b,
onAnimationStart: x
}, (e) => {
- var o = e === 1 ? i : i.map(h1(f, m, e)), s = e === 1 ? a : a?.map(h1(p, h, e));
- return e > 0 && (n.current = o, r.current = s), /*#__PURE__*/ R.createElement(dMe, {
+ var o = e === 1 ? i : i.map(m1(f, m, e)), s = e === 1 ? a : a?.map(m1(p, h, e));
+ return e > 0 && (n.current = o, r.current = s), /*#__PURE__*/ R.createElement(pMe, {
points: o,
baseLinePoints: s,
props: t
});
- }), /*#__PURE__*/ R.createElement(zQ, { label: t.label }), t.children);
+ }), /*#__PURE__*/ R.createElement(RQ, { label: t.label }), t.children);
}
-function pMe(e) {
+function hMe(e) {
var t = (0, R.useRef)(void 0), n = (0, R.useRef)(void 0);
- return /*#__PURE__*/ R.createElement(fMe, {
+ return /*#__PURE__*/ R.createElement(mMe, {
props: e,
previousPointsRef: t,
previousBaseLinePointsRef: n
});
}
-var mMe = {
+var gMe = {
activeDot: !0,
angleAxisId: 0,
animationBegin: 0,
@@ -63844,31 +63896,31 @@ var mMe = {
radiusAxisId: 0,
zIndex: fG.area
};
-function hMe(e) {
+function _Me(e) {
var { hide: t, className: n, points: r } = e;
if (t) return null;
var i = ja("recharts-radar", n);
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: e.zIndex }, /*#__PURE__*/ R.createElement(wI, { className: i }, /*#__PURE__*/ R.createElement(pMe, e)), /*#__PURE__*/ R.createElement(a1, {
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: e.zIndex }, /*#__PURE__*/ R.createElement(TI, { className: i }, /*#__PURE__*/ R.createElement(hMe, e)), /*#__PURE__*/ R.createElement(i1, {
points: r,
- mainColor: m1(e.stroke, e.fill),
+ mainColor: p1(e.stroke, e.fill),
itemDataKey: e.dataKey,
activeDot: e.activeDot
}));
}
-function gMe(e) {
- var t = VV(), n = Q((n) => $je(n, e.radiusAxisId, e.angleAxisId, t, e.id));
- return n?.points == null ? null : /*#__PURE__*/ R.createElement(hMe, d1({}, e, {
+function vMe(e) {
+ var t = HV(), n = Q((n) => tMe(n, e.radiusAxisId, e.angleAxisId, t, e.id));
+ return n?.points == null ? null : /*#__PURE__*/ R.createElement(_Me, u1({}, e, {
points: n?.points,
baseLinePoints: n?.baseLinePoints,
isRange: n?.isRange
}));
}
-function g1(e) {
- var t = JL(e, mMe);
- return /*#__PURE__*/ R.createElement(G$, {
+function h1(e) {
+ var t = YL(e, gMe);
+ return /*#__PURE__*/ R.createElement(W$, {
id: t.id,
type: "radar"
- }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(J$, {
+ }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(q$, {
type: "radar",
id: e,
data: void 0,
@@ -63876,7 +63928,7 @@ function g1(e) {
hide: t.hide,
angleAxisId: t.angleAxisId,
radiusAxisId: t.radiusAxisId
- }), /*#__PURE__*/ R.createElement(W$, { legendPayload: oMe(t) }), /*#__PURE__*/ R.createElement(sMe, {
+ }), /*#__PURE__*/ R.createElement(U$, { legendPayload: cMe(t) }), /*#__PURE__*/ R.createElement(lMe, {
dataKey: t.dataKey,
stroke: t.stroke,
strokeWidth: t.strokeWidth,
@@ -63885,32 +63937,32 @@ function g1(e) {
hide: t.hide,
tooltipType: t.tooltipType,
id: e
- }), /*#__PURE__*/ R.createElement(gMe, d1({}, t, { id: e }))));
+ }), /*#__PURE__*/ R.createElement(vMe, u1({}, t, { id: e }))));
}
-g1.displayName = "Radar";
+h1.displayName = "Radar";
//#endregion
//#region node_modules/recharts/es6/util/RadialBarUtils.js
-function _1() {
- return _1 = Object.assign ? Object.assign.bind() : function(e) {
+function g1() {
+ return g1 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, _1.apply(null, arguments);
+ }, g1.apply(null, arguments);
}
-function v1(e) {
+function _1(e) {
return typeof e == "string" ? parseInt(e, 10) : e;
}
-function y1(e) {
- return /*#__PURE__*/ R.createElement(R$, _1({ shapeType: "sector" }, e));
+function v1(e) {
+ return /*#__PURE__*/ R.createElement(L$, g1({ shapeType: "sector" }, e));
}
//#endregion
//#region node_modules/recharts/es6/state/selectors/combiners/combineBarSizeList.js
-var b1 = (e, t, n) => {
+var y1 = (e, t, n) => {
var r = n ?? e;
- if (!FL(r)) return jL(r, t, 0);
-}, x1 = (e, t, n) => {
+ if (!IL(r)) return ML(r, t, 0);
+}, b1 = (e, t, n) => {
var r = {}, i = e.filter(PG), a = e.filter((e) => e.stackId == null), o = i.reduce((e, t) => {
var n = e[t.stackId];
return n ??= [], n.push(t), e[t.stackId] = n, e;
@@ -63919,18 +63971,18 @@ var b1 = (e, t, n) => {
return {
stackId: r,
dataKeys: i.map((e) => e.dataKey),
- barSize: b1(t, n, i[0]?.barSize)
+ barSize: y1(t, n, i[0]?.barSize)
};
}), c = a.map((e) => ({
stackId: void 0,
dataKeys: [e.dataKey].filter((e) => e != null),
- barSize: b1(t, n, e.barSize)
+ barSize: y1(t, n, e.barSize)
}));
return [...s, ...c];
};
//#endregion
//#region node_modules/recharts/es6/state/selectors/combiners/combineAllBarPositions.js
-function S1(e, t) {
+function x1(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -63940,30 +63992,30 @@ function S1(e, t) {
}
return n;
}
-function C1(e) {
+function S1(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? S1(Object(n), !0).forEach(function(t) {
- _Me(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : S1(Object(n)).forEach(function(t) {
+ t % 2 ? x1(Object(n), !0).forEach(function(t) {
+ yMe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : x1(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function _Me(e, t, n) {
- return (t = vMe(t)) in e ? Object.defineProperty(e, t, {
+function yMe(e, t, n) {
+ return (t = bMe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function vMe(e) {
- var t = yMe(e, "string");
+function bMe(e) {
+ var t = xMe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function yMe(e, t) {
+function xMe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -63973,11 +64025,11 @@ function yMe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function bMe(e, t, n, r, i) {
+function SMe(e, t, n, r, i) {
var a = r.length;
if (!(a < 1)) {
- var o = jL(e, n, 0, !0), s, c = [];
- if (GB(r[0]?.barSize)) {
+ var o = ML(e, n, 0, !0), s, c = [];
+ if (KB(r[0]?.barSize)) {
var l = !1, u = n / a, d = r.reduce((e, t) => e + (t.barSize || 0), 0);
d += (a - 1) * o, d >= n && (d -= (a - 1) * o, o = 0), d >= n && u > 0 && (l = !0, u *= .9, d = a * u);
var f = {
@@ -63996,11 +64048,11 @@ function bMe(e, t, n, r, i) {
return f = n.position, r;
}, c);
} else {
- var p = jL(t, n, 0, !0);
+ var p = ML(t, n, 0, !0);
n - 2 * p - (a - 1) * o <= 0 && (o = 0);
var m = (n - 2 * p - (a - 1) * o) / a;
m > 1 && (m >>= 0);
- var h = GB(i) ? Math.min(m, i) : m;
+ var h = KB(i) ? Math.min(m, i) : m;
s = r.reduce((e, t, n) => [...e, {
stackId: t.stackId,
dataKeys: t.dataKeys,
@@ -64013,10 +64065,10 @@ function bMe(e, t, n, r, i) {
return s;
}
}
-var w1 = (e, t, n, r, i, a, o) => {
- var s = FL(o) ? t : o, c = bMe(n, r, i === a ? a : i, e, s);
- return i !== a && c != null && (c = c.map((e) => C1(C1({}, e), {}, { position: C1(C1({}, e.position), {}, { offset: e.position.offset - i / 2 }) }))), c;
-}, T1 = (e, t) => {
+var C1 = (e, t, n, r, i, a, o) => {
+ var s = IL(o) ? t : o, c = SMe(n, r, i === a ? a : i, e, s);
+ return i !== a && c != null && (c = c.map((e) => S1(S1({}, e), {}, { position: S1(S1({}, e.position), {}, { offset: e.position.offset - i / 2 }) }))), c;
+}, w1 = (e, t) => {
var n = MG(t);
if (!(!e || n == null || t == null)) {
var { stackId: r } = t;
@@ -64028,7 +64080,7 @@ var w1 = (e, t, n, r, i, a, o) => {
}
}
}
-}, E1 = (e, t) => {
+}, T1 = (e, t) => {
if (e != null && t != null) {
var n = e.find((e) => e.stackId === t.stackId && t.dataKey != null && e.dataKeys.includes(t.dataKey));
if (n != null) return n.position;
@@ -64036,7 +64088,7 @@ var w1 = (e, t, n, r, i, a, o) => {
};
//#endregion
//#region node_modules/recharts/es6/state/selectors/radialBarSelectors.js
-function D1(e, t) {
+function E1(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -64046,30 +64098,30 @@ function D1(e, t) {
}
return n;
}
-function O1(e) {
+function D1(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? D1(Object(n), !0).forEach(function(t) {
- xMe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : D1(Object(n)).forEach(function(t) {
+ t % 2 ? E1(Object(n), !0).forEach(function(t) {
+ CMe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : E1(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function xMe(e, t, n) {
- return (t = SMe(t)) in e ? Object.defineProperty(e, t, {
+function CMe(e, t, n) {
+ return (t = wMe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function SMe(e) {
- var t = CMe(e, "string");
+function wMe(e) {
+ var t = TMe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function CMe(e, t) {
+function TMe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -64079,81 +64131,81 @@ function CMe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var k1 = $([(e, t) => SG(e, t), (e, t) => t$(e, "radiusAxis", t)], (e, t) => {
- if (e != null && t != null) return O1(O1({}, e), {}, { scale: t });
-}), A1 = (e, t) => Ike(e, "radiusAxis", t, !1), j1 = $([(e, t, n) => xG(e, n), (e, t, n) => t$(e, "angleAxis", n)], (e, t) => {
- if (e != null && t != null) return O1(O1({}, e), {}, { scale: t });
-}), M1 = (e, t, n) => r$(e, "angleAxis", n, !1), N1 = $([KQ, (e, t, n, r) => r], (e, t) => {
+var O1 = $([(e, t) => SG(e, t), (e, t) => e$(e, "radiusAxis", t)], (e, t) => {
+ if (e != null && t != null) return D1(D1({}, e), {}, { scale: t });
+}), k1 = (e, t) => Rke(e, "radiusAxis", t, !1), A1 = $([(e, t, n) => xG(e, n), (e, t, n) => e$(e, "angleAxis", n)], (e, t) => {
+ if (e != null && t != null) return D1(D1({}, e), {}, { scale: t });
+}), j1 = (e, t, n) => n$(e, "angleAxis", n, !1), M1 = $([GQ, (e, t, n, r) => r], (e, t) => {
if (e.some((e) => e.type === "radialBar" && t.dataKey === e.dataKey && t.stackId === e.stackId)) return t;
-}), P1 = $([
- xH,
+}), N1 = $([
+ SH,
+ O1,
k1,
A1,
- j1,
- M1
-], (e, t, n, r, i) => eV(e, "radiusAxis") ? hV(t, n, !1) : hV(r, i, !1)), wMe = $([
- j1,
- k1,
- xH
+ j1
+], (e, t, n, r, i) => tV(e, "radiusAxis") ? gV(t, n, !1) : gV(r, i, !1)), EMe = $([
+ A1,
+ O1,
+ SH
], (e, t, n) => {
var r = n === "radial" ? e : t;
- if (r != null && r.scale != null) return lV({ numericAxis: r });
-}), TMe = (e, t, n, r, i) => i, EMe = (e, t, n, r, i) => n, DMe = (e, t, n, r, i) => t, F1 = (e, t, n, r, i) => r.maxBarSize, I1 = (e) => e.type === "radialBar", OMe = $([$([
+ if (r != null && r.scale != null) return uV({ numericAxis: r });
+}), DMe = (e, t, n, r, i) => i, OMe = (e, t, n, r, i) => n, kMe = (e, t, n, r, i) => t, P1 = (e, t, n, r, i) => r.maxBarSize, F1 = (e) => e.type === "radialBar", AMe = $([$([
$([
$([
- xH,
- KQ,
- EMe,
- DMe
- ], (e, t, n, r) => t.filter((t) => e === "centric" ? t.angleAxisId === n : t.radiusAxisId === r).filter((e) => e.hide === !1).filter(I1)),
+ SH,
+ GQ,
+ OMe,
+ kMe
+ ], (e, t, n, r) => t.filter((t) => e === "centric" ? t.angleAxisId === n : t.radiusAxisId === r).filter((e) => e.hide === !1).filter(F1)),
aG,
() => void 0
- ], x1),
+ ], b1),
nG,
rG,
iG,
$([
- xH,
+ SH,
nG,
+ A1,
j1,
- M1,
+ O1,
k1,
- A1,
- F1
+ P1
], (e, t, n, r, i, a, o) => {
- var s = FL(o) ? t : o;
- return e === "centric" ? hV(n, r, !0) ?? s ?? 0 : hV(i, a, !0) ?? s ?? 0;
+ var s = IL(o) ? t : o;
+ return e === "centric" ? gV(n, r, !0) ?? s ?? 0 : gV(i, a, !0) ?? s ?? 0;
}),
- P1,
- F1
-], w1), N1], E1), L1 = $([qQ], (e) => e.filter(I1).filter(PG)), R1 = $([
+ N1,
+ P1
+], C1), M1], T1), I1 = $([KQ], (e) => e.filter(F1).filter(PG)), L1 = $([
$([
- L1,
+ I1,
VW,
OY
], NG),
- L1,
+ I1,
oG,
sG
-], AY), kMe = $([
+], AY), jMe = $([
+ A1,
j1,
- M1,
+ O1,
k1,
- A1,
BW,
+ M1,
N1,
- P1,
- xH,
- wMe,
+ SH,
+ EMe,
kG,
- TMe,
- OMe,
- $([(e, t, n) => xH(e) === "centric" ? R1(e, "radiusAxis", t) : R1(e, "angleAxis", n), N1], T1)
+ DMe,
+ AMe,
+ $([(e, t, n) => SH(e) === "centric" ? L1(e, "radiusAxis", t) : L1(e, "angleAxis", n), M1], w1)
], (e, t, n, r, i, a, o, s, c, l, u, d, f) => {
var { chartData: p, dataStartIndex: m, dataEndIndex: h } = i;
if (a == null || n == null || e == null || p == null || o == null || d == null || s !== "centric" && s !== "radial" || r == null || l == null) return [];
var { dataKey: g, minPointSize: _ } = a, { cx: v, cy: y, startAngle: b, endAngle: x } = l;
- return KMe({
+ return JMe({
angleAxis: e,
angleAxisTicks: t,
bandSize: o,
@@ -64174,7 +64226,7 @@ var k1 = $([(e, t) => SG(e, t), (e, t) => t$(e, "radiusAxis", t)], (e, t) => {
stackedDomain: f ? (s === "centric" ? n : e).scale.domain() : null,
startAngle: b
});
-}), AMe = $([VW, (e, t) => t], (e, t) => {
+}), MMe = $([VW, (e, t) => t], (e, t) => {
var { chartData: n, dataStartIndex: r, dataEndIndex: i } = e;
if (n == null) return [];
var a = n.slice(r, i + 1);
@@ -64187,31 +64239,31 @@ var k1 = $([(e, t) => SG(e, t), (e, t) => t$(e, "radiusAxis", t)], (e, t) => {
});
//#endregion
//#region node_modules/recharts/es6/zIndex/getZIndexFromUnknown.js
-function z1(e, t) {
- return e && typeof e == "object" && "zIndex" in e && typeof e.zIndex == "number" && GB(e.zIndex) ? e.zIndex : t;
+function R1(e, t) {
+ return e && typeof e == "object" && "zIndex" in e && typeof e.zIndex == "number" && KB(e.zIndex) ? e.zIndex : t;
}
//#endregion
//#region node_modules/recharts/es6/polar/RadialBar.js
-var jMe = [
+var NMe = [
"shape",
"activeShape",
"cornerRadius",
"id"
-], MMe = [
+], PMe = [
"onMouseEnter",
"onClick",
"onMouseLeave"
-], NMe = ["value", "background"];
-function B1() {
- return B1 = Object.assign ? Object.assign.bind() : function(e) {
+], FMe = ["value", "background"];
+function z1() {
+ return z1 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, B1.apply(null, arguments);
+ }, z1.apply(null, arguments);
}
-function V1(e, t) {
+function B1(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -64221,30 +64273,30 @@ function V1(e, t) {
}
return n;
}
-function H1(e) {
+function V1(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? V1(Object(n), !0).forEach(function(t) {
- PMe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : V1(Object(n)).forEach(function(t) {
+ t % 2 ? B1(Object(n), !0).forEach(function(t) {
+ IMe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : B1(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function PMe(e, t, n) {
- return (t = FMe(t)) in e ? Object.defineProperty(e, t, {
+function IMe(e, t, n) {
+ return (t = LMe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function FMe(e) {
- var t = IMe(e, "string");
+function LMe(e) {
+ var t = RMe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function IMe(e, t) {
+function RMe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -64254,16 +64306,16 @@ function IMe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function U1(e, t) {
+function H1(e, t) {
if (e == null) return {};
- var n, r, i = LMe(e, t);
+ var n, r, i = zMe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function LMe(e, t) {
+function zMe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -64272,8 +64324,8 @@ function LMe(e, t) {
}
return n;
}
-var W1 = [];
-function RMe(e) {
+var U1 = [];
+function BMe(e) {
var { showLabels: t, sectors: n, children: r } = e, i = n.map((e) => ({
value: e.value,
payload: e.payload,
@@ -64290,15 +64342,15 @@ function RMe(e) {
},
fill: e.fill
}));
- return /*#__PURE__*/ R.createElement(wke, { value: t ? i : void 0 }, r);
+ return /*#__PURE__*/ R.createElement(Eke, { value: t ? i : void 0 }, r);
}
-function zMe(e) {
- var { sectors: t, allOtherRadialBarProps: n, showLabels: r } = e, { shape: i, activeShape: a, cornerRadius: o, id: s } = n, c = U1(n, jMe), l = vI(c), u = Q(oZ), { onMouseEnter: d, onClick: f, onMouseLeave: p } = n, m = U1(n, MMe), h = z$(d, n.dataKey, s), g = B$(p), _ = V$(f, n.dataKey, s);
- return t == null ? null : /*#__PURE__*/ R.createElement(RMe, {
+function VMe(e) {
+ var { sectors: t, allOtherRadialBarProps: n, showLabels: r } = e, { shape: i, activeShape: a, cornerRadius: o, id: s } = n, c = H1(n, NMe), l = yI(c), u = Q(oZ), { onMouseEnter: d, onClick: f, onMouseLeave: p } = n, m = H1(n, PMe), h = R$(d, n.dataKey, s), g = z$(p), _ = B$(f, n.dataKey, s);
+ return t == null ? null : /*#__PURE__*/ R.createElement(BMe, {
showLabels: r,
sectors: t
}, t.map((e, t) => {
- var n = !!(a && u === String(t)), r = h(e, t), s = g(e, t), d = _(e, t), f = H1(H1(H1(H1({}, l), {}, { cornerRadius: v1(o) }, e), KL(m, e, t)), {}, {
+ var n = !!(a && u === String(t)), r = h(e, t), s = g(e, t), d = _(e, t), f = V1(V1(V1(V1({}, l), {}, { cornerRadius: _1(o) }, e), qL(m, e, t)), {}, {
onMouseEnter: r,
onMouseLeave: s,
onClick: d,
@@ -64312,10 +64364,10 @@ function zMe(e) {
return n ? /*#__PURE__*/ R.createElement(DZ, {
zIndex: fG.activeBar,
key: `sector-${e.cx}-${e.cy}-${e.innerRadius}-${e.outerRadius}-${e.startAngle}-${e.endAngle}-${t}`
- }, /*#__PURE__*/ R.createElement(y1, f)) : /*#__PURE__*/ R.createElement(y1, B1({ key: `sector-${e.cx}-${e.cy}-${e.innerRadius}-${e.outerRadius}-${e.startAngle}-${e.endAngle}-${t}` }, f));
- }), /*#__PURE__*/ R.createElement(zQ, { label: n.label }), n.children);
+ }, /*#__PURE__*/ R.createElement(v1, f)) : /*#__PURE__*/ R.createElement(v1, z1({ key: `sector-${e.cx}-${e.cy}-${e.innerRadius}-${e.outerRadius}-${e.startAngle}-${e.endAngle}-${t}` }, f));
+ }), /*#__PURE__*/ R.createElement(RQ, { label: n.label }), n.children);
}
-function BMe(e) {
+function HMe(e) {
var { props: t, previousSectorsRef: n } = e, { sectors: r, isAnimationActive: i, animationBegin: a, animationDuration: o, animationEasing: s, onAnimationEnd: c, onAnimationStart: l } = t, u = vW(t, "recharts-radialbar-"), d = n.current, [f, p] = (0, R.useState)(!1), m = (0, R.useCallback)(() => {
typeof c == "function" && c(), p(!1);
}, [c]), h = (0, R.useCallback)(() => {
@@ -64331,37 +64383,37 @@ function BMe(e) {
onAnimationEnd: m,
key: u
}, (e) => {
- var i = e === 1 ? r : (r ?? W1).map((t, n) => {
+ var i = e === 1 ? r : (r ?? U1).map((t, n) => {
var r = d && d[n];
- if (r) return H1(H1({}, t), {}, {
- startAngle: NL(r.startAngle, t.startAngle, e),
- endAngle: NL(r.endAngle, t.endAngle, e)
+ if (r) return V1(V1({}, t), {}, {
+ startAngle: PL(r.startAngle, t.startAngle, e),
+ endAngle: PL(r.endAngle, t.endAngle, e)
});
var { endAngle: i, startAngle: a } = t;
- return H1(H1({}, t), {}, { endAngle: NL(a, i, e) });
+ return V1(V1({}, t), {}, { endAngle: PL(a, i, e) });
});
- return e > 0 && (n.current = i ?? null), /*#__PURE__*/ R.createElement(zMe, {
- sectors: i ?? W1,
+ return e > 0 && (n.current = i ?? null), /*#__PURE__*/ R.createElement(VMe, {
+ sectors: i ?? U1,
allOtherRadialBarProps: t,
showLabels: !f
});
});
}
-function VMe(e) {
+function UMe(e) {
var t = (0, R.useRef)(null);
- return /*#__PURE__*/ R.createElement(BMe, {
+ return /*#__PURE__*/ R.createElement(HMe, {
props: e,
previousSectorsRef: t
});
}
-function HMe(e) {
- var t = Q((t) => AMe(t, e.legendType));
- return /*#__PURE__*/ R.createElement(W$, { legendPayload: t ?? [] });
+function WMe(e) {
+ var t = Q((t) => MMe(t, e.legendType));
+ return /*#__PURE__*/ R.createElement(U$, { legendPayload: t ?? [] });
}
-var UMe = /*#__PURE__*/ R.memo((e) => {
+var GMe = /*#__PURE__*/ R.memo((e) => {
var { dataKey: t, sectors: n, stroke: r, strokeWidth: i, name: a, hide: o, fill: s, tooltipType: c, id: l } = e, u = {
dataDefinedOnItem: n,
- getPosition: RL,
+ getPosition: zL,
settings: {
graphicalItemId: l,
stroke: r,
@@ -64369,45 +64421,45 @@ var UMe = /*#__PURE__*/ R.memo((e) => {
fill: s,
nameKey: void 0,
dataKey: t,
- name: _V(a, t),
+ name: vV(a, t),
hide: o,
type: c,
color: s,
unit: ""
}
};
- return /*#__PURE__*/ R.createElement(H$, { tooltipEntrySettings: u });
-}), WMe = class extends R.PureComponent {
+ return /*#__PURE__*/ R.createElement(V$, { tooltipEntrySettings: u });
+}), KMe = class extends R.PureComponent {
renderBackground(e) {
if (e == null) return null;
- var { cornerRadius: t } = this.props, n = yI(this.props.background);
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: z1(this.props.background, fG.barBackground) }, e.map((e, r) => {
- var { value: i, background: a } = e, o = U1(e, NMe);
+ var { cornerRadius: t } = this.props, n = bI(this.props.background);
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: R1(this.props.background, fG.barBackground) }, e.map((e, r) => {
+ var { value: i, background: a } = e, o = H1(e, FMe);
if (!a) return null;
- var s = H1(H1(H1(H1(H1({ cornerRadius: v1(t) }, o), {}, { fill: "#eee" }, a), n), KL(this.props, e, r)), {}, {
+ var s = V1(V1(V1(V1(V1({ cornerRadius: _1(t) }, o), {}, { fill: "#eee" }, a), n), qL(this.props, e, r)), {}, {
index: r,
className: ja("recharts-radial-bar-background-sector", String(n?.className)),
option: a,
isActive: !1
});
- return /*#__PURE__*/ R.createElement(y1, B1({ key: `background-${o.cx}-${o.cy}-${o.innerRadius}-${o.outerRadius}-${o.startAngle}-${o.endAngle}-${r}` }, s));
+ return /*#__PURE__*/ R.createElement(v1, z1({ key: `background-${o.cx}-${o.cy}-${o.innerRadius}-${o.outerRadius}-${o.startAngle}-${o.endAngle}-${r}` }, s));
}));
}
render() {
var { hide: e, sectors: t, className: n, background: r } = this.props;
if (e) return null;
var i = ja("recharts-area", n);
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: this.props.zIndex }, /*#__PURE__*/ R.createElement(wI, { className: i }, r && /*#__PURE__*/ R.createElement(wI, { className: "recharts-radial-bar-background" }, this.renderBackground(t)), /*#__PURE__*/ R.createElement(wI, { className: "recharts-radial-bar-sectors" }, /*#__PURE__*/ R.createElement(VMe, this.props))));
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: this.props.zIndex }, /*#__PURE__*/ R.createElement(TI, { className: i }, r && /*#__PURE__*/ R.createElement(TI, { className: "recharts-radial-bar-background" }, this.renderBackground(t)), /*#__PURE__*/ R.createElement(TI, { className: "recharts-radial-bar-sectors" }, /*#__PURE__*/ R.createElement(UMe, this.props))));
}
};
-function GMe(e) {
- var t = R.useMemo(() => O$(e.children, WZ), [e.children]), n = R.useMemo(() => ({
+function qMe(e) {
+ var t = R.useMemo(() => D$(e.children, WZ), [e.children]), n = R.useMemo(() => ({
data: void 0,
hide: !1,
id: e.id,
dataKey: e.dataKey,
minPointSize: e.minPointSize,
- stackId: oV(e.stackId),
+ stackId: sV(e.stackId),
maxBarSize: e.maxBarSize,
barSize: e.barSize,
type: "radialBar",
@@ -64422,8 +64474,8 @@ function GMe(e) {
e.barSize,
e.angleAxisId,
e.radiusAxisId
- ]), r = Q((r) => kMe(r, e.radiusAxisId, e.angleAxisId, n, t)) ?? W1;
- return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(UMe, {
+ ]), r = Q((r) => jMe(r, e.radiusAxisId, e.angleAxisId, n, t)) ?? U1;
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(GMe, {
dataKey: e.dataKey,
sectors: r,
stroke: e.stroke,
@@ -64433,9 +64485,9 @@ function GMe(e) {
fill: e.fill,
tooltipType: e.tooltipType,
id: e.id
- }), /*#__PURE__*/ R.createElement(WMe, B1({}, e, { sectors: r })));
+ }), /*#__PURE__*/ R.createElement(KMe, z1({}, e, { sectors: r })));
}
-var G1 = {
+var W1 = {
angleAxisId: 0,
animationBegin: 0,
animationDuration: 1500,
@@ -64452,12 +64504,12 @@ var G1 = {
radiusAxisId: 0,
zIndex: fG.bar
};
-function KMe(e) {
+function JMe(e) {
var { displayedData: t, stackedData: n, dataStartIndex: r, stackedDomain: i, dataKey: a, baseValue: o, layout: s, radiusAxis: c, radiusAxisTicks: l, bandSize: u, pos: d, angleAxis: f, minPointSize: p, cx: m, cy: h, angleAxisTicks: g, cells: _, startAngle: v, endAngle: y } = e;
- return g == null || l == null ? W1 : (t ?? []).map((e, t) => {
+ return g == null || l == null ? U1 : (t ?? []).map((e, t) => {
var b, x, S, C, w, T;
- if (n ? b = rV(n[r + t], i) : (b = QB(e, a), Array.isArray(b) || (b = [o, b])), s === "radial") {
- if (C = f.scale.map(b[0]) ?? v, w = f.scale.map(b[1]) ?? y, x = cV({
+ if (n ? b = iV(n[r + t], i) : (b = $B(e, a), Array.isArray(b) || (b = [o, b])), s === "radial") {
+ if (C = f.scale.map(b[0]) ?? v, w = f.scale.map(b[1]) ?? y, x = lV({
axis: c,
ticks: l,
bandSize: u,
@@ -64468,7 +64520,7 @@ function KMe(e) {
S = x + d.size;
var E = w - C;
if (Math.abs(p) > 0 && Math.abs(E) < Math.abs(p)) {
- var D = EL(E || p) * (Math.abs(p) - Math.abs(E));
+ var D = DL(E || p) * (Math.abs(p) - Math.abs(E));
w += D;
}
T = { background: {
@@ -64480,7 +64532,7 @@ function KMe(e) {
endAngle: y
} };
}
- } else if (x = c.scale.map(b[0]), S = c.scale.map(b[1]), C = cV({
+ } else if (x = c.scale.map(b[0]), S = c.scale.map(b[1]), C = lV({
axis: f,
ticks: g,
bandSize: u,
@@ -64491,11 +64543,11 @@ function KMe(e) {
w = C + d.size;
var O = S - x;
if (Math.abs(p) > 0 && Math.abs(O) < Math.abs(p)) {
- var k = EL(O || p) * (Math.abs(p) - Math.abs(O));
+ var k = DL(O || p) * (Math.abs(p) - Math.abs(O));
S += k;
}
}
- return H1(H1(H1({}, e), T), {}, {
+ return V1(V1(V1({}, e), T), {}, {
payload: e,
value: n ? b : b[1],
cx: m,
@@ -64507,30 +64559,30 @@ function KMe(e) {
}, _ && _[t] && _[t].props);
});
}
-function K1(e) {
- var t = JL(e, G1);
- return /*#__PURE__*/ R.createElement(G$, {
+function G1(e) {
+ var t = YL(e, W1);
+ return /*#__PURE__*/ R.createElement(W$, {
id: t.id,
type: "radialBar"
- }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(J$, {
+ }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(q$, {
type: "radialBar",
id: e,
data: void 0,
dataKey: t.dataKey,
- hide: t.hide ?? G1.hide,
- angleAxisId: t.angleAxisId ?? G1.angleAxisId,
- radiusAxisId: t.radiusAxisId ?? G1.radiusAxisId,
- stackId: oV(t.stackId),
+ hide: t.hide ?? W1.hide,
+ angleAxisId: t.angleAxisId ?? W1.angleAxisId,
+ radiusAxisId: t.radiusAxisId ?? W1.radiusAxisId,
+ stackId: sV(t.stackId),
barSize: t.barSize,
minPointSize: t.minPointSize,
maxBarSize: t.maxBarSize
- }), /*#__PURE__*/ R.createElement(HMe, t), /*#__PURE__*/ R.createElement(GMe, B1({}, t, { id: e }))));
+ }), /*#__PURE__*/ R.createElement(WMe, t), /*#__PURE__*/ R.createElement(qMe, z1({}, t, { id: e }))));
}
-K1.displayName = "RadialBar";
+G1.displayName = "RadialBar";
//#endregion
//#region node_modules/recharts/es6/context/chartDataContext.js
-var q1 = (e) => {
- var { chartData: t } = e, n = xR(), r = VV();
+var K1 = (e) => {
+ var { chartData: t } = e, n = SR(), r = HV();
return (0, R.useEffect)(() => r ? () => {} : (n(RZ(t)), () => {
n(RZ(void 0));
}), [
@@ -64538,7 +64590,7 @@ var q1 = (e) => {
n,
r
]), null;
-}, J1 = {
+}, q1 = {
x: 0,
y: 0,
width: 0,
@@ -64549,13 +64601,13 @@ var q1 = (e) => {
bottom: 0,
left: 0
}
-}, Y1 = oB({
+}, J1 = sB({
name: "brush",
- initialState: J1,
+ initialState: q1,
reducers: { setBrushSettings(e, t) {
- return t.payload == null ? J1 : t.payload;
+ return t.payload == null ? q1 : t.payload;
} }
-}), { setBrushSettings: qMe } = Y1.actions, JMe = Y1.reducer, YMe = (e, t) => {
+}), { setBrushSettings: YMe } = J1.actions, XMe = J1.reducer, ZMe = (e, t) => {
var { x: n, y: r } = e, { x: i, y: a } = t;
return {
x: Math.min(n, i),
@@ -64563,9 +64615,9 @@ var q1 = (e) => {
width: Math.abs(i - n),
height: Math.abs(a - r)
};
-}, XMe = (e) => {
+}, QMe = (e) => {
var { x1: t, y1: n, x2: r, y2: i } = e;
- return YMe({
+ return ZMe({
x: t,
y: n
}, {
@@ -64573,13 +64625,13 @@ var q1 = (e) => {
y: i
});
};
-function ZMe(e) {
+function $Me(e) {
return (e % 180 + 180) % 180;
}
-var QMe = function(e) {
- var { width: t, height: n } = e, r = ZMe(arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0) * Math.PI / 180, i = Math.atan(n / t), a = r > i && r < Math.PI - i ? n / Math.sin(r) : t / Math.cos(r);
+var eNe = function(e) {
+ var { width: t, height: n } = e, r = $Me(arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0) * Math.PI / 180, i = Math.atan(n / t), a = r > i && r < Math.PI - i ? n / Math.sin(r) : t / Math.cos(r);
return Math.abs(a);
-}, X1 = oB({
+}, Y1 = sB({
name: "referenceElements",
initialState: {
dots: [],
@@ -64591,35 +64643,35 @@ var QMe = function(e) {
e.dots.push(t.payload);
},
removeDot: (e, t) => {
- var n = qz(e).dots.findIndex((e) => e === t.payload);
+ var n = Jz(e).dots.findIndex((e) => e === t.payload);
n !== -1 && e.dots.splice(n, 1);
},
addArea: (e, t) => {
e.areas.push(t.payload);
},
removeArea: (e, t) => {
- var n = qz(e).areas.findIndex((e) => e === t.payload);
+ var n = Jz(e).areas.findIndex((e) => e === t.payload);
n !== -1 && e.areas.splice(n, 1);
},
addLine: (e, t) => {
e.lines.push(bU(t.payload));
},
removeLine: (e, t) => {
- var n = qz(e).lines.findIndex((e) => e === t.payload);
+ var n = Jz(e).lines.findIndex((e) => e === t.payload);
n !== -1 && e.lines.splice(n, 1);
}
}
-}), { addDot: $Me, removeDot: eNe, addArea: tNe, removeArea: nNe, addLine: rNe, removeLine: iNe } = X1.actions, aNe = X1.reducer, Z1 = /*#__PURE__*/ (0, R.createContext)(void 0), oNe = (e) => {
- var { children: t } = e, [n] = (0, R.useState)(`${AL("recharts")}-clip`), r = n1();
+}), { addDot: tNe, removeDot: nNe, addArea: rNe, removeArea: iNe, addLine: aNe, removeLine: oNe } = Y1.actions, sNe = Y1.reducer, X1 = /*#__PURE__*/ (0, R.createContext)(void 0), cNe = (e) => {
+ var { children: t } = e, [n] = (0, R.useState)(`${jL("recharts")}-clip`), r = t1();
if (r == null) return null;
var { x: i, y: a, width: o, height: s } = r;
- return /*#__PURE__*/ R.createElement(Z1.Provider, { value: n }, /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement("clipPath", { id: n }, /*#__PURE__*/ R.createElement("rect", {
+ return /*#__PURE__*/ R.createElement(X1.Provider, { value: n }, /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement("clipPath", { id: n }, /*#__PURE__*/ R.createElement("rect", {
x: i,
y: a,
height: s,
width: o
}))), t);
-}, sNe = () => (0, R.useContext)(Z1), cNe = class {
+}, lNe = () => (0, R.useContext)(X1), uNe = class {
constructor(e) {
var { x: t, y: n } = e;
this.xAxisScale = t, this.yAxisScale = n;
@@ -64645,7 +64697,7 @@ var QMe = function(e) {
};
//#endregion
//#region node_modules/recharts/es6/cartesian/ReferenceLine.js
-function Q1(e, t) {
+function Z1(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -64655,30 +64707,30 @@ function Q1(e, t) {
}
return n;
}
-function $1(e) {
+function Q1(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? Q1(Object(n), !0).forEach(function(t) {
- lNe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : Q1(Object(n)).forEach(function(t) {
+ t % 2 ? Z1(Object(n), !0).forEach(function(t) {
+ dNe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : Z1(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function lNe(e, t, n) {
- return (t = uNe(t)) in e ? Object.defineProperty(e, t, {
+function dNe(e, t, n) {
+ return (t = fNe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function uNe(e) {
- var t = dNe(e, "string");
+function fNe(e) {
+ var t = pNe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function dNe(e, t) {
+function pNe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -64688,27 +64740,27 @@ function dNe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function e0() {
- return e0 = Object.assign ? Object.assign.bind() : function(e) {
+function $1() {
+ return $1 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, e0.apply(null, arguments);
+ }, $1.apply(null, arguments);
}
-var fNe = (e, t) => {
+var mNe = (e, t) => {
var n;
if (/*#__PURE__*/ R.isValidElement(e)) n = /*#__PURE__*/ R.cloneElement(e, t);
else if (typeof e == "function") n = e(t);
else {
- if (!GB(t.x1) || !GB(t.y1) || !GB(t.x2) || !GB(t.y2)) return null;
- n = /*#__PURE__*/ R.createElement("line", e0({}, t, { className: "recharts-reference-line-line" }));
+ if (!KB(t.x1) || !KB(t.y1) || !KB(t.x2) || !KB(t.y2)) return null;
+ n = /*#__PURE__*/ R.createElement("line", $1({}, t, { className: "recharts-reference-line-line" }));
}
return n;
-}, pNe = (e, t, n, r, i, a) => {
+}, hNe = (e, t, n, r, i, a) => {
var { x: o, width: s } = a, c = i.map(e, { position: n });
- if (!GB(c) || t === "discard" && !i.isInRange(c)) return null;
+ if (!KB(c) || t === "discard" && !i.isInRange(c)) return null;
var l = [{
x: o + s,
y: c
@@ -64717,9 +64769,9 @@ var fNe = (e, t) => {
y: c
}];
return r === "left" ? l.reverse() : l;
-}, mNe = (e, t, n, r, i, a) => {
+}, gNe = (e, t, n, r, i, a) => {
var { y: o, height: s } = a, c = i.map(e, { position: n });
- if (!GB(c) || t === "discard" && !i.isInRange(c)) return null;
+ if (!KB(c) || t === "discard" && !i.isInRange(c)) return null;
var l = [{
x: c,
y: o + s
@@ -64728,7 +64780,7 @@ var fNe = (e, t) => {
y: o
}];
return r === "top" ? l.reverse() : l;
-}, hNe = (e, t, n, r) => {
+}, _Ne = (e, t, n, r) => {
var i = [r.mapWithFallback(e[0], {
position: n,
fallback: "rangeMin"
@@ -64737,43 +64789,43 @@ var fNe = (e, t) => {
fallback: "rangeMax"
})];
return t === "discard" && i.some((e) => !r.isInRange(e)) ? null : i;
-}, gNe = (e, t, n, r, i, a, o) => {
- var { x: s, y: c, segment: l, ifOverflow: u } = o, d = kL(s);
- return kL(c) ? pNe(c, u, r, a, t, n) : d ? mNe(s, u, r, i, e, n) : l != null && l.length === 2 ? hNe(l, u, r, new cNe({
+}, vNe = (e, t, n, r, i, a, o) => {
+ var { x: s, y: c, segment: l, ifOverflow: u } = o, d = AL(s);
+ return AL(c) ? hNe(c, u, r, a, t, n) : d ? gNe(s, u, r, i, e, n) : l != null && l.length === 2 ? _Ne(l, u, r, new uNe({
x: e,
y: t
})) : null;
};
-function _Ne(e) {
- var t = xR();
- return (0, R.useEffect)(() => (t(rNe(e)), () => {
- t(iNe(e));
+function yNe(e) {
+ var t = SR();
+ return (0, R.useEffect)(() => (t(aNe(e)), () => {
+ t(oNe(e));
})), null;
}
-function vNe(e) {
- var { xAxisId: t, yAxisId: n, shape: r, className: i, ifOverflow: a } = e, o = VV(), s = sNe(), c = Q((e) => aY(e, t)), l = Q((e) => cY(e, n)), u = Q((e) => aX(e, "xAxis", t, o)), d = Q((e) => aX(e, "yAxis", n, o)), f = hH();
+function bNe(e) {
+ var { xAxisId: t, yAxisId: n, shape: r, className: i, ifOverflow: a } = e, o = HV(), s = lNe(), c = Q((e) => aY(e, t)), l = Q((e) => cY(e, n)), u = Q((e) => aX(e, "xAxis", t, o)), d = Q((e) => aX(e, "yAxis", n, o)), f = gH();
if (!s || !f || c == null || l == null || u == null || d == null) return null;
- var p = gNe(u, d, f, e.position, c.orientation, l.orientation, e);
+ var p = vNe(u, d, f, e.position, c.orientation, l.orientation, e);
if (!p) return null;
var m = p[0], h = p[1];
if (m == null || h == null) return null;
- var { x: g, y: _ } = m, { x: v, y } = h, b = $1($1({ clipPath: a === "hidden" ? `url(#${s})` : void 0 }, bI(e)), {}, {
+ var { x: g, y: _ } = m, { x: v, y } = h, b = Q1(Q1({ clipPath: a === "hidden" ? `url(#${s})` : void 0 }, xI(e)), {}, {
x1: g,
y1: _,
x2: v,
y2: y
- }), x = XMe({
+ }), x = QMe({
x1: g,
y1: _,
x2: v,
y2: y
});
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: e.zIndex }, /*#__PURE__*/ R.createElement(wI, { className: ja("recharts-reference-line", i) }, fNe(r, b), /*#__PURE__*/ R.createElement(wQ, e0({}, x, {
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: e.zIndex }, /*#__PURE__*/ R.createElement(TI, { className: ja("recharts-reference-line", i) }, mNe(r, b), /*#__PURE__*/ R.createElement(CQ, $1({}, x, {
lowerWidth: x.width,
upperWidth: x.width
- }), /*#__PURE__*/ R.createElement(MQ, { label: e.label }), e.children)));
+ }), /*#__PURE__*/ R.createElement(jQ, { label: e.label }), e.children)));
}
-var yNe = {
+var xNe = {
ifOverflow: "discard",
xAxisId: 0,
yAxisId: 0,
@@ -64785,21 +64837,21 @@ var yNe = {
position: "middle",
zIndex: fG.line
};
-function t0(e) {
- var t = JL(e, yNe);
- return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(_Ne, {
+function e0(e) {
+ var t = YL(e, xNe);
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(yNe, {
yAxisId: t.yAxisId,
xAxisId: t.xAxisId,
ifOverflow: t.ifOverflow,
x: t.x,
y: t.y,
segment: t.segment
- }), /*#__PURE__*/ R.createElement(vNe, t));
+ }), /*#__PURE__*/ R.createElement(bNe, t));
}
-t0.displayName = "ReferenceLine";
+e0.displayName = "ReferenceLine";
//#endregion
//#region node_modules/recharts/es6/util/getEveryNth.js
-function n0(e, t) {
+function t0(e, t) {
if (t < 1) return [];
if (t === 1) return e;
for (var n = [], r = 0; r < e.length; r += t) {
@@ -64810,13 +64862,13 @@ function n0(e, t) {
}
//#endregion
//#region node_modules/recharts/es6/util/TickUtils.js
-function bNe(e, t, n) {
- return QMe({
+function SNe(e, t, n) {
+ return eNe({
width: e.width + t.width,
height: e.height + t.height
}, n);
}
-function xNe(e, t, n) {
+function CNe(e, t, n) {
var r = n === "width", { x: i, y: a, width: o, height: s } = e;
return t === 1 ? {
start: r ? i : a,
@@ -64826,33 +64878,33 @@ function xNe(e, t, n) {
end: r ? i : a
};
}
-function r0(e, t, n, r, i) {
+function n0(e, t, n, r, i) {
if (e * t < e * r || e * t > e * i) return !1;
var a = n();
return e * (t - e * a / 2 - r) >= 0 && e * (t + e * a / 2 - i) <= 0;
}
-function SNe(e, t) {
- return n0(e, t + 1);
+function wNe(e, t) {
+ return t0(e, t + 1);
}
//#endregion
//#region node_modules/recharts/es6/cartesian/getEquidistantTicks.js
-function CNe(e, t, n, r, i) {
+function TNe(e, t, n, r, i) {
for (var a = (r || []).slice(), { start: o, end: s } = t, c = 0, l = 1, u = o, d = function() {
var t = r?.[c];
- if (t === void 0) return { v: n0(r, l) };
- var a = c, d, f = () => (d === void 0 && (d = n(t, a)), d), p = t.coordinate, m = c === 0 || r0(e, p, f, u, s);
+ if (t === void 0) return { v: t0(r, l) };
+ var a = c, d, f = () => (d === void 0 && (d = n(t, a)), d), p = t.coordinate, m = c === 0 || n0(e, p, f, u, s);
m || (c = 0, u = o, l += 1), m && (u = p + e * (f() / 2 + i), c += l);
}, f; l <= a.length;) if (f = d(), f) return f.v;
return [];
}
-function wNe(e, t, n, r, i) {
+function ENe(e, t, n, r, i) {
var a = (r || []).slice().length;
if (a === 0) return [];
for (var { start: o, end: s } = t, c = 1; c <= a; c++) {
for (var l = (a - 1) % c, u = o, d = !0, f = function() {
var t = r[m];
if (t == null) return 0;
- var a = m, o, c = () => (o === void 0 && (o = n(t, a)), o), f = t.coordinate, p = m === l || r0(e, f, c, u, s);
+ var a = m, o, c = () => (o === void 0 && (o = n(t, a)), o), f = t.coordinate, p = m === l || n0(e, f, c, u, s);
if (!p) return d = !1, 1;
p && (u = f + e * (c() / 2 + i));
}, p, m = l; m < a && (p = f(), p === 0 || p !== 1); m += c);
@@ -64868,7 +64920,7 @@ function wNe(e, t, n, r, i) {
}
//#endregion
//#region node_modules/recharts/es6/cartesian/getTicks.js
-function i0(e, t) {
+function r0(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -64878,30 +64930,30 @@ function i0(e, t) {
}
return n;
}
-function a0(e) {
+function i0(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? i0(Object(n), !0).forEach(function(t) {
- TNe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : i0(Object(n)).forEach(function(t) {
+ t % 2 ? r0(Object(n), !0).forEach(function(t) {
+ DNe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : r0(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function TNe(e, t, n) {
- return (t = ENe(t)) in e ? Object.defineProperty(e, t, {
+function DNe(e, t, n) {
+ return (t = ONe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function ENe(e) {
- var t = DNe(e, "string");
+function ONe(e) {
+ var t = kNe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function DNe(e, t) {
+function kNe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -64911,26 +64963,26 @@ function DNe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function ONe(e, t, n, r, i) {
+function ANe(e, t, n, r, i) {
for (var a = (r || []).slice(), o = a.length, { start: s } = t, { end: c } = t, l = function(t) {
var r = a[t];
if (r == null) return 1;
var l = r, u, d = () => (u === void 0 && (u = n(r, t)), u);
if (t === o - 1) {
var f = e * (l.coordinate + e * d() / 2 - c);
- a[t] = l = a0(a0({}, l), {}, { tickCoord: f > 0 ? l.coordinate - f * e : l.coordinate });
- } else a[t] = l = a0(a0({}, l), {}, { tickCoord: l.coordinate });
- l.tickCoord != null && r0(e, l.tickCoord, d, s, c) && (c = l.tickCoord - e * (d() / 2 + i), a[t] = a0(a0({}, l), {}, { isShow: !0 }));
+ a[t] = l = i0(i0({}, l), {}, { tickCoord: f > 0 ? l.coordinate - f * e : l.coordinate });
+ } else a[t] = l = i0(i0({}, l), {}, { tickCoord: l.coordinate });
+ l.tickCoord != null && n0(e, l.tickCoord, d, s, c) && (c = l.tickCoord - e * (d() / 2 + i), a[t] = i0(i0({}, l), {}, { isShow: !0 }));
}, u = o - 1; u >= 0; u--) if (l(u)) continue;
return a;
}
-function kNe(e, t, n, r, i, a) {
+function jNe(e, t, n, r, i, a) {
var o = (r || []).slice(), s = o.length, { start: c, end: l } = t;
if (a) {
var u = r[s - 1];
if (u != null) {
var d = n(u, s - 1), f = e * (u.coordinate + e * d / 2 - l);
- o[s - 1] = u = a0(a0({}, u), {}, { tickCoord: f > 0 ? u.coordinate - f * e : u.coordinate }), u.tickCoord != null && r0(e, u.tickCoord, () => d, c, l) && (l = u.tickCoord - e * (d / 2 + i), o[s - 1] = a0(a0({}, u), {}, { isShow: !0 }));
+ o[s - 1] = u = i0(i0({}, u), {}, { tickCoord: f > 0 ? u.coordinate - f * e : u.coordinate }), u.tickCoord != null && n0(e, u.tickCoord, () => d, c, l) && (l = u.tickCoord - e * (d / 2 + i), o[s - 1] = i0(i0({}, u), {}, { isShow: !0 }));
}
}
for (var p = a ? s - 1 : s, m = function(t) {
@@ -64939,16 +64991,16 @@ function kNe(e, t, n, r, i, a) {
var a = r, s, u = () => (s === void 0 && (s = n(r, t)), s);
if (t === 0) {
var d = e * (a.coordinate - e * u() / 2 - c);
- o[t] = a = a0(a0({}, a), {}, { tickCoord: d < 0 ? a.coordinate - d * e : a.coordinate });
- } else o[t] = a = a0(a0({}, a), {}, { tickCoord: a.coordinate });
- a.tickCoord != null && r0(e, a.tickCoord, u, c, l) && (c = a.tickCoord + e * (u() / 2 + i), o[t] = a0(a0({}, a), {}, { isShow: !0 }));
+ o[t] = a = i0(i0({}, a), {}, { tickCoord: d < 0 ? a.coordinate - d * e : a.coordinate });
+ } else o[t] = a = i0(i0({}, a), {}, { tickCoord: a.coordinate });
+ a.tickCoord != null && n0(e, a.tickCoord, u, c, l) && (c = a.tickCoord + e * (u() / 2 + i), o[t] = i0(i0({}, a), {}, { isShow: !0 }));
}, h = 0; h < p; h++) if (m(h)) continue;
return o;
}
-function o0(e, t, n) {
+function a0(e, t, n) {
var { tick: r, ticks: i, viewBox: a, minTickGap: o, orientation: s, interval: c, tickFormatter: l, unit: u, angle: d } = e;
if (!i || !i.length || !r) return [];
- if (Z(c) || zU.isSsr) return SNe(i, Z(c) ? c : 0) ?? [];
+ if (Z(c) || zU.isSsr) return wNe(i, Z(c) ? c : 0) ?? [];
var f = [], p = s === "top" || s === "bottom" ? "width" : "height", m = u && p === "width" ? XZ(u, {
fontSize: t,
letterSpacing: n
@@ -64957,19 +65009,19 @@ function o0(e, t, n) {
height: 0
}, h = (e, r) => {
var i = typeof l == "function" ? l(e.value, r) : e.value;
- return p === "width" ? bNe(XZ(i, {
+ return p === "width" ? SNe(XZ(i, {
fontSize: t,
letterSpacing: n
}), m, d) : XZ(i, {
fontSize: t,
letterSpacing: n
})[p];
- }, g = i[0], _ = i[1], v = i.length >= 2 && g != null && _ != null ? EL(_.coordinate - g.coordinate) : 1, y = xNe(a, v, p);
- return c === "equidistantPreserveStart" ? CNe(v, y, h, i, o) : c === "equidistantPreserveEnd" ? wNe(v, y, h, i, o) : (f = c === "preserveStart" || c === "preserveStartEnd" ? kNe(v, y, h, i, o, c === "preserveStartEnd") : ONe(v, y, h, i, o), f.filter((e) => e.isShow));
+ }, g = i[0], _ = i[1], v = i.length >= 2 && g != null && _ != null ? DL(_.coordinate - g.coordinate) : 1, y = CNe(a, v, p);
+ return c === "equidistantPreserveStart" ? TNe(v, y, h, i, o) : c === "equidistantPreserveEnd" ? ENe(v, y, h, i, o) : (f = c === "preserveStart" || c === "preserveStartEnd" ? jNe(v, y, h, i, o, c === "preserveStartEnd") : ANe(v, y, h, i, o), f.filter((e) => e.isShow));
}
//#endregion
//#region node_modules/recharts/es6/util/YAxisUtils.js
-var ANe = (e) => {
+var MNe = (e) => {
var { ticks: t, label: n, labelGapWithTick: r = 5, tickSize: i = 0, tickMargin: a = 0 } = e, o = 0;
if (t) {
Array.from(t).forEach((e) => {
@@ -64982,7 +65034,7 @@ var ANe = (e) => {
return Math.round(l);
}
return 0;
-}, s0 = oB({
+}, o0 = sB({
name: "renderedTicks",
initialState: {
xAxis: {},
@@ -64998,7 +65050,7 @@ var ANe = (e) => {
delete e[n][r];
}
}
-}), { setRenderedTicks: jNe, removeRenderedTicks: MNe } = s0.actions, NNe = s0.reducer, PNe = [
+}), { setRenderedTicks: NNe, removeRenderedTicks: PNe } = o0.actions, FNe = o0.reducer, INe = [
"axisLine",
"width",
"height",
@@ -65008,16 +65060,16 @@ var ANe = (e) => {
"axisType",
"axisId"
];
-function FNe(e, t) {
+function LNe(e, t) {
if (e == null) return {};
- var n, r, i = INe(e, t);
+ var n, r, i = RNe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function INe(e, t) {
+function RNe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -65026,16 +65078,16 @@ function INe(e, t) {
}
return n;
}
-function c0() {
- return c0 = Object.assign ? Object.assign.bind() : function(e) {
+function s0() {
+ return s0 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, c0.apply(null, arguments);
+ }, s0.apply(null, arguments);
}
-function l0(e, t) {
+function c0(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -65045,30 +65097,30 @@ function l0(e, t) {
}
return n;
}
-function u0(e) {
+function l0(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? l0(Object(n), !0).forEach(function(t) {
- LNe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : l0(Object(n)).forEach(function(t) {
+ t % 2 ? c0(Object(n), !0).forEach(function(t) {
+ zNe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : c0(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function LNe(e, t, n) {
- return (t = RNe(t)) in e ? Object.defineProperty(e, t, {
+function zNe(e, t, n) {
+ return (t = BNe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function RNe(e) {
- var t = zNe(e, "string");
+function BNe(e) {
+ var t = VNe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function zNe(e, t) {
+function VNe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -65078,7 +65130,7 @@ function zNe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var d0 = {
+var u0 = {
x: 0,
y: 0,
width: 0,
@@ -65102,13 +65154,13 @@ var d0 = {
interval: "preserveEnd",
zIndex: fG.axis
};
-function BNe(e) {
+function HNe(e) {
var { x: t, y: n, width: r, height: i, orientation: a, mirror: o, axisLine: s, otherSvgProps: c } = e;
if (!s) return null;
- var l = u0(u0(u0({}, c), vI(s)), {}, { fill: "none" });
+ var l = l0(l0(l0({}, c), yI(s)), {}, { fill: "none" });
if (a === "top" || a === "bottom") {
var u = +(a === "top" && !o || a === "bottom" && o);
- l = u0(u0({}, l), {}, {
+ l = l0(l0({}, l), {}, {
x1: t,
y1: n + u * i,
x2: t + r,
@@ -65116,16 +65168,16 @@ function BNe(e) {
});
} else {
var d = +(a === "left" && !o || a === "right" && o);
- l = u0(u0({}, l), {}, {
+ l = l0(l0({}, l), {}, {
x1: t + d * r,
y1: n,
x2: t + d * r,
y2: n + i
});
}
- return /*#__PURE__*/ R.createElement("line", c0({}, l, { className: ja("recharts-cartesian-axis-line", CL(s, "className")) }));
+ return /*#__PURE__*/ R.createElement("line", s0({}, l, { className: ja("recharts-cartesian-axis-line", wL(s, "className")) }));
}
-function VNe(e, t, n, r, i, a, o, s, c) {
+function UNe(e, t, n, r, i, a, o, s, c) {
var l, u, d, f, p, m, h = s ? -1 : 1, g = e.tickSize || o, _ = Z(e.tickCoord) ? e.tickCoord : e.coordinate;
switch (a) {
case "top":
@@ -65152,14 +65204,14 @@ function VNe(e, t, n, r, i, a, o, s, c) {
}
};
}
-function HNe(e, t) {
+function WNe(e, t) {
switch (e) {
case "left": return t ? "start" : "end";
case "right": return t ? "end" : "start";
default: return "middle";
}
}
-function UNe(e, t) {
+function GNe(e, t) {
switch (e) {
case "left":
case "right": return "middle";
@@ -65167,19 +65219,19 @@ function UNe(e, t) {
default: return t ? "end" : "start";
}
}
-function WNe(e) {
+function KNe(e) {
var { option: t, tickProps: n, value: r } = e, i, a = ja(n.className, "recharts-cartesian-axis-tick-value");
- if (/*#__PURE__*/ R.isValidElement(t)) i = /*#__PURE__*/ R.cloneElement(t, u0(u0({}, n), {}, { className: a }));
- else if (typeof t == "function") i = t(u0(u0({}, n), {}, { className: a }));
+ if (/*#__PURE__*/ R.isValidElement(t)) i = /*#__PURE__*/ R.cloneElement(t, l0(l0({}, n), {}, { className: a }));
+ else if (typeof t == "function") i = t(l0(l0({}, n), {}, { className: a }));
else {
var o = "recharts-cartesian-axis-tick-value";
- typeof t != "boolean" && (o = ja(o, f$(t))), i = /*#__PURE__*/ R.createElement(hQ, c0({}, n, { className: o }), r);
+ typeof t != "boolean" && (o = ja(o, d$(t))), i = /*#__PURE__*/ R.createElement(hQ, s0({}, n, { className: o }), r);
}
return i;
}
-function GNe(e) {
- var { ticks: t, axisType: n, axisId: r } = e, i = xR();
- return (0, R.useEffect)(() => r == null || n == null ? RL : (i(jNe({
+function qNe(e) {
+ var { ticks: t, axisType: n, axisId: r } = e, i = SR();
+ return (0, R.useEffect)(() => r == null || n == null ? zL : (i(NNe({
ticks: t.map((e) => ({
value: e.value,
coordinate: e.coordinate,
@@ -65189,7 +65241,7 @@ function GNe(e) {
axisId: r,
axisType: n
})), () => {
- i(MNe({
+ i(PNe({
axisId: r,
axisType: n
}));
@@ -65200,17 +65252,17 @@ function GNe(e) {
n
]), null;
}
-var KNe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var { ticks: n = [], tick: r, tickLine: i, stroke: a, tickFormatter: o, unit: s, padding: c, tickTextProps: l, orientation: u, mirror: d, x: f, y: p, width: m, height: h, tickSize: g, tickMargin: _, fontSize: v, letterSpacing: y, getTicksConfig: b, events: x, axisType: S, axisId: C } = e, w = o0(u0(u0({}, b), {}, { ticks: n }), v, y), T = vI(b), E = yI(r), D = lQ(T.textAnchor) ? T.textAnchor : HNe(u, d), O = UNe(u, d), k = {};
+var JNe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var { ticks: n = [], tick: r, tickLine: i, stroke: a, tickFormatter: o, unit: s, padding: c, tickTextProps: l, orientation: u, mirror: d, x: f, y: p, width: m, height: h, tickSize: g, tickMargin: _, fontSize: v, letterSpacing: y, getTicksConfig: b, events: x, axisType: S, axisId: C } = e, w = a0(l0(l0({}, b), {}, { ticks: n }), v, y), T = yI(b), E = bI(r), D = lQ(T.textAnchor) ? T.textAnchor : WNe(u, d), O = GNe(u, d), k = {};
typeof i == "object" && (k = i);
- var A = u0(u0({}, T), {}, { fill: "none" }, k), j = w.map((e) => u0({ entry: e }, VNe(e, f, p, m, h, u, g, d, _))), M = j.map((e) => {
+ var A = l0(l0({}, T), {}, { fill: "none" }, k), j = w.map((e) => l0({ entry: e }, UNe(e, f, p, m, h, u, g, d, _))), M = j.map((e) => {
var { entry: t, line: n } = e;
- return /*#__PURE__*/ R.createElement(wI, {
+ return /*#__PURE__*/ R.createElement(TI, {
className: "recharts-cartesian-axis-tick",
key: `tick-${t.value}-${t.coordinate}-${t.tickCoord}`
- }, i && /*#__PURE__*/ R.createElement("line", c0({}, A, n, { className: ja("recharts-cartesian-axis-tick-line", CL(i, "className")) })));
+ }, i && /*#__PURE__*/ R.createElement("line", s0({}, A, n, { className: ja("recharts-cartesian-axis-tick-line", wL(i, "className")) })));
}), N = j.map((e, t) => {
- var { entry: n, tick: i } = e, u = u0(u0({}, u0(u0(u0(u0({ verticalAnchor: O }, T), {}, {
+ var { entry: n, tick: i } = e, u = l0(l0({}, l0(l0(l0(l0({ verticalAnchor: O }, T), {}, {
textAnchor: D,
stroke: "none",
fill: a
@@ -65221,16 +65273,16 @@ var KNe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
tickFormatter: o,
padding: c
}, l), {}, { angle: l?.angle ?? T.angle ?? 0 })), E);
- return /*#__PURE__*/ R.createElement(wI, c0({
+ return /*#__PURE__*/ R.createElement(TI, s0({
className: "recharts-cartesian-axis-tick-label",
key: `tick-label-${n.value}-${n.coordinate}-${n.tickCoord}`
- }, KL(x, n, t)), r && /*#__PURE__*/ R.createElement(WNe, {
+ }, qL(x, n, t)), r && /*#__PURE__*/ R.createElement(KNe, {
option: r,
tickProps: u,
value: `${typeof o == "function" ? o(n.value, t) : n.value}${s || ""}`
}));
});
- return /*#__PURE__*/ R.createElement("g", { className: `recharts-cartesian-axis-ticks recharts-${S}-ticks` }, /*#__PURE__*/ R.createElement(GNe, {
+ return /*#__PURE__*/ R.createElement("g", { className: `recharts-cartesian-axis-ticks recharts-${S}-ticks` }, /*#__PURE__*/ R.createElement(qNe, {
ticks: w,
axisId: C,
axisType: S
@@ -65238,9 +65290,9 @@ var KNe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
className: `recharts-cartesian-axis-tick-labels recharts-${S}-tick-labels`,
ref: t
}, N)), M.length > 0 && /*#__PURE__*/ R.createElement("g", { className: `recharts-cartesian-axis-tick-lines recharts-${S}-tick-lines` }, M));
-}), qNe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var { axisLine: n, width: r, height: i, className: a, hide: o, ticks: s, axisType: c, axisId: l } = e, u = FNe(e, PNe), [d, f] = (0, R.useState)(""), [p, m] = (0, R.useState)(""), h = (0, R.useRef)(null);
- (0, R.useImperativeHandle)(t, () => ({ getCalculatedWidth: () => ANe({
+}), YNe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var { axisLine: n, width: r, height: i, className: a, hide: o, ticks: s, axisType: c, axisId: l } = e, u = LNe(e, INe), [d, f] = (0, R.useState)(""), [p, m] = (0, R.useState)(""), h = (0, R.useRef)(null);
+ (0, R.useImperativeHandle)(t, () => ({ getCalculatedWidth: () => MNe({
ticks: h.current,
label: e.labelRef?.current,
labelGapWithTick: 5,
@@ -65258,7 +65310,7 @@ var KNe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
}
}
}, [d, p]);
- return o || r != null && r <= 0 || i != null && i <= 0 ? null : /*#__PURE__*/ R.createElement(DZ, { zIndex: e.zIndex }, /*#__PURE__*/ R.createElement(wI, { className: ja("recharts-cartesian-axis", a) }, /*#__PURE__*/ R.createElement(BNe, {
+ return o || r != null && r <= 0 || i != null && i <= 0 ? null : /*#__PURE__*/ R.createElement(DZ, { zIndex: e.zIndex }, /*#__PURE__*/ R.createElement(TI, { className: ja("recharts-cartesian-axis", a) }, /*#__PURE__*/ R.createElement(HNe, {
x: e.x,
y: e.y,
width: r,
@@ -65266,8 +65318,8 @@ var KNe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
orientation: e.orientation,
mirror: e.mirror,
axisLine: n,
- otherSvgProps: vI(e)
- }), /*#__PURE__*/ R.createElement(KNe, {
+ otherSvgProps: yI(e)
+ }), /*#__PURE__*/ R.createElement(JNe, {
ref: g,
axisType: c,
events: u,
@@ -65291,32 +65343,32 @@ var KNe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
x: e.x,
y: e.y,
axisId: l
- }), /*#__PURE__*/ R.createElement(wQ, {
+ }), /*#__PURE__*/ R.createElement(CQ, {
x: e.x,
y: e.y,
width: e.width,
height: e.height,
lowerWidth: e.width,
upperWidth: e.width
- }, /*#__PURE__*/ R.createElement(MQ, {
+ }, /*#__PURE__*/ R.createElement(jQ, {
label: e.label,
labelRef: e.labelRef
}), e.children)));
-}), f0 = /*#__PURE__*/ R.forwardRef((e, t) => {
- var n = JL(e, d0);
- return /*#__PURE__*/ R.createElement(qNe, c0({}, n, { ref: t }));
+}), d0 = /*#__PURE__*/ R.forwardRef((e, t) => {
+ var n = YL(e, u0);
+ return /*#__PURE__*/ R.createElement(YNe, s0({}, n, { ref: t }));
});
-f0.displayName = "CartesianAxis";
+d0.displayName = "CartesianAxis";
//#endregion
//#region node_modules/recharts/es6/cartesian/CartesianGrid.js
-var JNe = [
+var XNe = [
"x1",
"y1",
"x2",
"y2",
"key"
-], YNe = ["offset"], XNe = ["xAxisId", "yAxisId"], ZNe = ["xAxisId", "yAxisId"];
-function p0(e, t) {
+], ZNe = ["offset"], QNe = ["xAxisId", "yAxisId"], $Ne = ["xAxisId", "yAxisId"];
+function f0(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -65326,30 +65378,30 @@ function p0(e, t) {
}
return n;
}
-function m0(e) {
+function p0(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? p0(Object(n), !0).forEach(function(t) {
- QNe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : p0(Object(n)).forEach(function(t) {
+ t % 2 ? f0(Object(n), !0).forEach(function(t) {
+ ePe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : f0(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function QNe(e, t, n) {
- return (t = $Ne(t)) in e ? Object.defineProperty(e, t, {
+function ePe(e, t, n) {
+ return (t = tPe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function $Ne(e) {
- var t = ePe(e, "string");
+function tPe(e) {
+ var t = nPe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function ePe(e, t) {
+function nPe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -65359,25 +65411,25 @@ function ePe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function h0() {
- return h0 = Object.assign ? Object.assign.bind() : function(e) {
+function m0() {
+ return m0 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, h0.apply(null, arguments);
+ }, m0.apply(null, arguments);
}
-function g0(e, t) {
+function h0(e, t) {
if (e == null) return {};
- var n, r, i = tPe(e, t);
+ var n, r, i = rPe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function tPe(e, t) {
+function rPe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -65386,7 +65438,7 @@ function tPe(e, t) {
}
return n;
}
-var nPe = (e) => {
+var iPe = (e) => {
var { fill: t } = e;
if (!t || t === "none") return null;
var { fillOpacity: n, x: r, y: i, width: a, height: o, ry: s } = e;
@@ -65402,13 +65454,13 @@ var nPe = (e) => {
className: "recharts-cartesian-grid-bg"
});
};
-function _0(e) {
+function g0(e) {
var { option: t, lineItemProps: n } = e, r;
if (/*#__PURE__*/ R.isValidElement(t)) r = /*#__PURE__*/ R.cloneElement(t, n);
else if (typeof t == "function") r = t(n);
else {
- var { x1: i, y1: a, x2: o, y2: s, key: c } = n, l = vI(g0(n, JNe)) ?? {}, { offset: u } = l, d = g0(l, YNe);
- r = /*#__PURE__*/ R.createElement("line", h0({}, d, {
+ var { x1: i, y1: a, x2: o, y2: s, key: c } = n, l = yI(h0(n, XNe)) ?? {}, { offset: u } = l, d = h0(l, ZNe);
+ r = /*#__PURE__*/ R.createElement("line", m0({}, d, {
x1: i,
y1: a,
x2: o,
@@ -65419,11 +65471,11 @@ function _0(e) {
}
return r;
}
-function rPe(e) {
+function aPe(e) {
var { x: t, width: n, horizontal: r = !0, horizontalPoints: i } = e;
if (!r || !i || !i.length) return null;
- var { xAxisId: a, yAxisId: o } = e, s = g0(e, XNe), c = i.map((e, i) => {
- var a = m0(m0({}, s), {}, {
+ var { xAxisId: a, yAxisId: o } = e, s = h0(e, QNe), c = i.map((e, i) => {
+ var a = p0(p0({}, s), {}, {
x1: t,
y1: e,
x2: t + n,
@@ -65431,7 +65483,7 @@ function rPe(e) {
key: `line-${i}`,
index: i
});
- return /*#__PURE__*/ R.createElement(_0, {
+ return /*#__PURE__*/ R.createElement(g0, {
key: `line-${i}`,
option: r,
lineItemProps: a
@@ -65439,11 +65491,11 @@ function rPe(e) {
});
return /*#__PURE__*/ R.createElement("g", { className: "recharts-cartesian-grid-horizontal" }, c);
}
-function iPe(e) {
+function oPe(e) {
var { y: t, height: n, vertical: r = !0, verticalPoints: i } = e;
if (!r || !i || !i.length) return null;
- var { xAxisId: a, yAxisId: o } = e, s = g0(e, ZNe), c = i.map((e, i) => {
- var a = m0(m0({}, s), {}, {
+ var { xAxisId: a, yAxisId: o } = e, s = h0(e, $Ne), c = i.map((e, i) => {
+ var a = p0(p0({}, s), {}, {
x1: e,
y1: t,
x2: e,
@@ -65451,7 +65503,7 @@ function iPe(e) {
key: `line-${i}`,
index: i
});
- return /*#__PURE__*/ R.createElement(_0, {
+ return /*#__PURE__*/ R.createElement(g0, {
option: r,
lineItemProps: a,
key: `line-${i}`
@@ -65459,7 +65511,7 @@ function iPe(e) {
});
return /*#__PURE__*/ R.createElement("g", { className: "recharts-cartesian-grid-vertical" }, c);
}
-function aPe(e) {
+function sPe(e) {
var { horizontalFill: t, fillOpacity: n, x: r, y: i, width: a, height: o, horizontalPoints: s, horizontal: c = !0 } = e;
if (!c || !t || !t.length || s == null) return null;
var l = s.map((e) => Math.round(e + i - i)).sort((e, t) => e - t);
@@ -65482,7 +65534,7 @@ function aPe(e) {
});
return /*#__PURE__*/ R.createElement("g", { className: "recharts-cartesian-gridstripes-horizontal" }, u);
}
-function oPe(e) {
+function cPe(e) {
var { vertical: t = !0, verticalFill: n, fillOpacity: r, x: i, y: a, width: o, height: s, verticalPoints: c } = e;
if (!t || !n || !n.length) return null;
var l = c.map((e) => Math.round(e + i - i)).sort((e, t) => e - t);
@@ -65505,10 +65557,10 @@ function oPe(e) {
});
return /*#__PURE__*/ R.createElement("g", { className: "recharts-cartesian-gridstripes-vertical" }, u);
}
-var sPe = (e, t) => {
+var lPe = (e, t) => {
var { xAxis: n, width: r, height: i, offset: a } = e;
- return tV(o0(m0(m0(m0({}, d0), n), {}, {
- ticks: nV(n, !0),
+ return nV(a0(p0(p0(p0({}, u0), n), {}, {
+ ticks: rV(n, !0),
viewBox: {
x: 0,
y: 0,
@@ -65516,10 +65568,10 @@ var sPe = (e, t) => {
height: i
}
})), a.left, a.left + a.width, t);
-}, cPe = (e, t) => {
+}, uPe = (e, t) => {
var { yAxis: n, width: r, height: i, offset: a } = e;
- return tV(o0(m0(m0(m0({}, d0), n), {}, {
- ticks: nV(n, !0),
+ return nV(a0(p0(p0(p0({}, u0), n), {}, {
+ ticks: rV(n, !0),
viewBox: {
x: 0,
y: 0,
@@ -65527,7 +65579,7 @@ var sPe = (e, t) => {
height: i
}
})), a.top, a.top + a.height, t);
-}, lPe = {
+}, dPe = {
horizontal: !0,
vertical: !0,
horizontalPoints: [],
@@ -65541,34 +65593,34 @@ var sPe = (e, t) => {
syncWithTicks: !1,
zIndex: fG.grid
};
-function v0(e) {
- var t = vH(), n = yH(), r = _H(), i = m0(m0({}, JL(e, lPe)), {}, {
+function _0(e) {
+ var t = yH(), n = bH(), r = vH(), i = p0(p0({}, YL(e, dPe)), {}, {
x: Z(e.x) ? e.x : r.left,
y: Z(e.y) ? e.y : r.top,
width: Z(e.width) ? e.width : r.width,
height: Z(e.height) ? e.height : r.height
- }), { xAxisId: a, yAxisId: o, x: s, y: c, width: l, height: u, syncWithTicks: d, horizontalValues: f, verticalValues: p } = i, m = VV(), h = Q((e) => hX(e, "xAxis", a, m)), g = Q((e) => hX(e, "yAxis", o, m));
- if (!KB(l) || !KB(u) || !Z(s) || !Z(c)) return null;
- var _ = i.verticalCoordinatesGenerator || sPe, v = i.horizontalCoordinatesGenerator || cPe, { horizontalPoints: y, verticalPoints: b } = i;
+ }), { xAxisId: a, yAxisId: o, x: s, y: c, width: l, height: u, syncWithTicks: d, horizontalValues: f, verticalValues: p } = i, m = HV(), h = Q((e) => hX(e, "xAxis", a, m)), g = Q((e) => hX(e, "yAxis", o, m));
+ if (!qB(l) || !qB(u) || !Z(s) || !Z(c)) return null;
+ var _ = i.verticalCoordinatesGenerator || lPe, v = i.horizontalCoordinatesGenerator || uPe, { horizontalPoints: y, verticalPoints: b } = i;
if ((!y || !y.length) && typeof v == "function") {
var x = f && f.length, S = v({
- yAxis: g ? m0(m0({}, g), {}, { ticks: x ? f : g.ticks }) : void 0,
+ yAxis: g ? p0(p0({}, g), {}, { ticks: x ? f : g.ticks }) : void 0,
width: t ?? l,
height: n ?? u,
offset: r
}, x ? !0 : d);
- qV(Array.isArray(S), `horizontalCoordinatesGenerator should return Array but instead it returned [${typeof S}]`), Array.isArray(S) && (y = S);
+ JV(Array.isArray(S), `horizontalCoordinatesGenerator should return Array but instead it returned [${typeof S}]`), Array.isArray(S) && (y = S);
}
if ((!b || !b.length) && typeof _ == "function") {
var C = p && p.length, w = _({
- xAxis: h ? m0(m0({}, h), {}, { ticks: C ? p : h.ticks }) : void 0,
+ xAxis: h ? p0(p0({}, h), {}, { ticks: C ? p : h.ticks }) : void 0,
width: t ?? l,
height: n ?? u,
offset: r
}, C ? !0 : d);
- qV(Array.isArray(w), `verticalCoordinatesGenerator should return Array but instead it returned [${typeof w}]`), Array.isArray(w) && (b = w);
+ JV(Array.isArray(w), `verticalCoordinatesGenerator should return Array but instead it returned [${typeof w}]`), Array.isArray(w) && (b = w);
}
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: i.zIndex }, /*#__PURE__*/ R.createElement("g", { className: "recharts-cartesian-grid" }, /*#__PURE__*/ R.createElement(nPe, {
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: i.zIndex }, /*#__PURE__*/ R.createElement("g", { className: "recharts-cartesian-grid" }, /*#__PURE__*/ R.createElement(iPe, {
fill: i.fill,
fillOpacity: i.fillOpacity,
x: i.x,
@@ -65576,22 +65628,22 @@ function v0(e) {
width: i.width,
height: i.height,
ry: i.ry
- }), /*#__PURE__*/ R.createElement(aPe, h0({}, i, { horizontalPoints: y })), /*#__PURE__*/ R.createElement(oPe, h0({}, i, { verticalPoints: b })), /*#__PURE__*/ R.createElement(rPe, h0({}, i, {
+ }), /*#__PURE__*/ R.createElement(sPe, m0({}, i, { horizontalPoints: y })), /*#__PURE__*/ R.createElement(cPe, m0({}, i, { verticalPoints: b })), /*#__PURE__*/ R.createElement(aPe, m0({}, i, {
offset: r,
horizontalPoints: y,
xAxis: h,
yAxis: g
- })), /*#__PURE__*/ R.createElement(iPe, h0({}, i, {
+ })), /*#__PURE__*/ R.createElement(oPe, m0({}, i, {
offset: r,
verticalPoints: b,
xAxis: h,
yAxis: g
}))));
}
-v0.displayName = "CartesianGrid";
+_0.displayName = "CartesianGrid";
//#endregion
//#region node_modules/recharts/es6/state/errorBarSlice.js
-var y0 = oB({
+var v0 = sB({
name: "errorBars",
initialState: {},
reducers: {
@@ -65608,17 +65660,17 @@ var y0 = oB({
e[n] && (e[n] = e[n].filter((e) => e.dataKey !== r.dataKey || e.direction !== r.direction));
}
}
-}), { addErrorBar: uPe, replaceErrorBar: dPe, removeErrorBar: fPe } = y0.actions, pPe = y0.reducer, mPe = ["children"];
-function hPe(e, t) {
+}), { addErrorBar: fPe, replaceErrorBar: pPe, removeErrorBar: mPe } = v0.actions, hPe = v0.reducer, gPe = ["children"];
+function _Pe(e, t) {
if (e == null) return {};
- var n, r, i = gPe(e, t);
+ var n, r, i = vPe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function gPe(e, t) {
+function vPe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -65627,7 +65679,7 @@ function gPe(e, t) {
}
return n;
}
-var _Pe = /*#__PURE__*/ (0, R.createContext)({
+var yPe = /*#__PURE__*/ (0, R.createContext)({
data: [],
xAxisId: "xAxis-0",
yAxisId: "yAxis-0",
@@ -65638,13 +65690,13 @@ var _Pe = /*#__PURE__*/ (0, R.createContext)({
}),
errorBarOffset: 0
});
-function b0(e) {
- var { children: t } = e, n = hPe(e, mPe);
- return /*#__PURE__*/ R.createElement(_Pe.Provider, { value: n }, t);
+function y0(e) {
+ var { children: t } = e, n = _Pe(e, gPe);
+ return /*#__PURE__*/ R.createElement(yPe.Provider, { value: n }, t);
}
//#endregion
//#region node_modules/recharts/es6/cartesian/GraphicalItemClipPath.js
-function x0(e, t) {
+function b0(e, t) {
var n = Q((t) => aY(t, e)), r = Q((e) => cY(e, t)), i = n?.allowDataOverflow ?? rY.allowDataOverflow, a = r?.allowDataOverflow ?? oY.allowDataOverflow;
return {
needClip: i || a,
@@ -65652,8 +65704,8 @@ function x0(e, t) {
needClipY: a
};
}
-function S0(e) {
- var { xAxisId: t, yAxisId: n, clipPathId: r } = e, i = n1(), { needClipX: a, needClipY: o, needClip: s } = x0(t, n);
+function x0(e) {
+ var { xAxisId: t, yAxisId: n, clipPathId: r } = e, i = t1(), { needClipX: a, needClipY: o, needClip: s } = b0(t, n);
if (!s || !i) return null;
var { x: c, y: l, width: u, height: d } = i;
return /*#__PURE__*/ R.createElement("clipPath", { id: `clipPath-${r}` }, /*#__PURE__*/ R.createElement("rect", {
@@ -65665,30 +65717,30 @@ function S0(e) {
}
//#endregion
//#region node_modules/recharts/es6/state/selectors/lineSelectors.js
-var C0 = (e, t, n, r) => bX(e, "xAxis", t, r), w0 = (e, t, n, r) => yX(e, "xAxis", t, r), T0 = (e, t, n, r) => bX(e, "yAxis", n, r), E0 = (e, t, n, r) => yX(e, "yAxis", n, r), vPe = $([
- xH,
- C0,
- T0,
+var S0 = (e, t, n, r) => bX(e, "xAxis", t, r), C0 = (e, t, n, r) => yX(e, "xAxis", t, r), w0 = (e, t, n, r) => bX(e, "yAxis", n, r), T0 = (e, t, n, r) => yX(e, "yAxis", n, r), bPe = $([
+ SH,
+ S0,
w0,
- E0
-], (e, t, n, r, i) => eV(e, "xAxis") ? hV(t, r, !1) : hV(n, i, !1)), yPe = (e, t, n, r, i) => i;
-function bPe(e) {
+ C0,
+ T0
+], (e, t, n, r, i) => tV(e, "xAxis") ? gV(t, r, !1) : gV(n, i, !1)), xPe = (e, t, n, r, i) => i;
+function SPe(e) {
return e.type === "line";
}
-var xPe = $([
- xH,
+var CPe = $([
+ SH,
+ S0,
+ w0,
C0,
T0,
- w0,
- E0,
- $([mY, yPe], (e, t) => e.filter(bPe).find((e) => e.id === t)),
- vPe,
+ $([mY, xPe], (e, t) => e.filter(SPe).find((e) => e.id === t)),
+ bPe,
HW
], (e, t, n, r, i, a, o, s) => {
var { chartData: c, dataStartIndex: l, dataEndIndex: u } = s;
if (!(a == null || t == null || n == null || r == null || i == null || r.length === 0 || i.length === 0 || o == null || e !== "horizontal" && e !== "vertical")) {
var { dataKey: d, data: f } = a, p = f != null && f.length > 0 ? f : c?.slice(l, u + 1);
- if (p != null) return VPe({
+ if (p != null) return UPe({
layout: e,
xAxis: t,
yAxis: n,
@@ -65702,8 +65754,8 @@ var xPe = $([
});
//#endregion
//#region node_modules/recharts/es6/util/getRadiusAndStrokeWidthFromDot.js
-function D0(e) {
- var t = yI(e), n = 3, r = 2;
+function E0(e) {
+ var t = bI(e), n = 3, r = 2;
if (t != null) {
var { r: i, strokeWidth: a } = t, o = Number(i), s = Number(a);
return (Number.isNaN(o) || o < 0) && (o = n), (Number.isNaN(s) || s < 0) && (s = r), {
@@ -65718,13 +65770,13 @@ function D0(e) {
}
//#endregion
//#region node_modules/recharts/es6/cartesian/Line.js
-var SPe = ["id"], CPe = [
+var wPe = ["id"], TPe = [
"type",
"layout",
"connectNulls",
"needClip",
"shape"
-], wPe = [
+], EPe = [
"activeDot",
"animateNewValues",
"animationBegin",
@@ -65740,16 +65792,16 @@ var SPe = ["id"], CPe = [
"yAxisId",
"id"
];
-function O0() {
- return O0 = Object.assign ? Object.assign.bind() : function(e) {
+function D0() {
+ return D0 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, O0.apply(null, arguments);
+ }, D0.apply(null, arguments);
}
-function k0(e, t) {
+function O0(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -65759,30 +65811,30 @@ function k0(e, t) {
}
return n;
}
-function A0(e) {
+function k0(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? k0(Object(n), !0).forEach(function(t) {
- TPe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : k0(Object(n)).forEach(function(t) {
+ t % 2 ? O0(Object(n), !0).forEach(function(t) {
+ DPe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : O0(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function TPe(e, t, n) {
- return (t = EPe(t)) in e ? Object.defineProperty(e, t, {
+function DPe(e, t, n) {
+ return (t = OPe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function EPe(e) {
- var t = DPe(e, "string");
+function OPe(e) {
+ var t = kPe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function DPe(e, t) {
+function kPe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -65792,16 +65844,16 @@ function DPe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function j0(e, t) {
+function A0(e, t) {
if (e == null) return {};
- var n, r, i = OPe(e, t);
+ var n, r, i = APe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function OPe(e, t) {
+function APe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -65810,27 +65862,27 @@ function OPe(e, t) {
}
return n;
}
-var kPe = (e) => {
+var jPe = (e) => {
var { dataKey: t, name: n, stroke: r, legendType: i, hide: a } = e;
return [{
inactive: a,
dataKey: t,
type: i,
color: r,
- value: _V(n, t),
+ value: vV(n, t),
payload: e
}];
-}, APe = /*#__PURE__*/ R.memo((e) => {
+}, MPe = /*#__PURE__*/ R.memo((e) => {
var { dataKey: t, data: n, stroke: r, strokeWidth: i, fill: a, name: o, hide: s, unit: c, tooltipType: l, id: u } = e, d = {
dataDefinedOnItem: n,
- getPosition: RL,
+ getPosition: zL,
settings: {
stroke: r,
strokeWidth: i,
fill: a,
dataKey: t,
nameKey: void 0,
- name: _V(o, t),
+ name: vV(o, t),
hide: s,
type: l,
color: r,
@@ -65838,15 +65890,15 @@ var kPe = (e) => {
graphicalItemId: u
}
};
- return /*#__PURE__*/ R.createElement(H$, { tooltipEntrySettings: d });
-}), M0 = (e, t) => `${t}px ${e}px`;
-function jPe(e, t) {
+ return /*#__PURE__*/ R.createElement(V$, { tooltipEntrySettings: d });
+}), j0 = (e, t) => `${t}px ${e}px`;
+function NPe(e, t) {
for (var n = e.length % 2 == 0 ? e : [...e, 0], r = [], i = 0; i < t; ++i) r.push(...n);
return r;
}
-var MPe = (e, t, n) => {
+var PPe = (e, t, n) => {
var r = n.reduce((e, t) => e + t, 0);
- if (!r) return M0(t, e);
+ if (!r) return j0(t, e);
for (var i = Math.floor(e / r), a = e % r, o = [], s = 0, c = 0; s < n.length; c += (l = n[s]) ?? 0, ++s) {
var l, u = n[s];
if (u != null && c + u > a) {
@@ -65856,14 +65908,14 @@ var MPe = (e, t, n) => {
}
var d = o.length % 2 == 0 ? [0, t] : [t];
return [
- ...jPe(n, i),
+ ...NPe(n, i),
...o,
...d
].map((e) => `${e}px`).join(", ");
};
-function NPe(e) {
- var { clipPathId: t, points: n, props: r } = e, { dot: i, dataKey: a, needClip: o } = r, { id: s } = r, c = vI(j0(r, SPe));
- return /*#__PURE__*/ R.createElement(Q$, {
+function FPe(e) {
+ var { clipPathId: t, points: n, props: r } = e, { dot: i, dataKey: a, needClip: o } = r, { id: s } = r, c = yI(A0(r, wPe));
+ return /*#__PURE__*/ R.createElement(Z$, {
points: n,
dot: i,
className: "recharts-line-dots",
@@ -65874,7 +65926,7 @@ function NPe(e) {
clipPathId: t
});
}
-function PPe(e) {
+function IPe(e) {
var { showLabels: t, children: n, points: r } = e, i = (0, R.useMemo)(() => r?.map((e) => {
var t = {
x: e.x ?? 0,
@@ -65884,7 +65936,7 @@ function PPe(e) {
upperWidth: 0,
height: 0
};
- return A0(A0({}, t), {}, {
+ return k0(k0({}, t), {}, {
value: e.value,
payload: e.payload,
viewBox: t,
@@ -65892,10 +65944,10 @@ function PPe(e) {
fill: void 0
});
}), [r]);
- return /*#__PURE__*/ R.createElement(IQ, { value: t ? i : void 0 }, n);
+ return /*#__PURE__*/ R.createElement(FQ, { value: t ? i : void 0 }, n);
}
-function N0(e) {
- var { clipPathId: t, pathRef: n, points: r, strokeDasharray: i, props: a } = e, { type: o, layout: s, connectNulls: c, needClip: l, shape: u } = a, d = A0(A0({}, bI(j0(a, CPe))), {}, {
+function M0(e) {
+ var { clipPathId: t, pathRef: n, points: r, strokeDasharray: i, props: a } = e, { type: o, layout: s, connectNulls: c, needClip: l, shape: u } = a, d = k0(k0({}, xI(A0(a, TPe))), {}, {
fill: "none",
className: "recharts-line-curve",
clipPath: l ? `url(#clipPath-${t})` : void 0,
@@ -65905,31 +65957,31 @@ function N0(e) {
connectNulls: c,
strokeDasharray: i ?? a.strokeDasharray
});
- return /*#__PURE__*/ R.createElement(R.Fragment, null, r?.length > 1 && /*#__PURE__*/ R.createElement(R$, O0({
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, r?.length > 1 && /*#__PURE__*/ R.createElement(L$, D0({
shapeType: "curve",
option: u
- }, d, { pathRef: n })), /*#__PURE__*/ R.createElement(NPe, {
+ }, d, { pathRef: n })), /*#__PURE__*/ R.createElement(FPe, {
points: r,
clipPathId: t,
props: a
}));
}
-function FPe(e) {
+function LPe(e) {
try {
return e && e.getTotalLength && e.getTotalLength() || 0;
} catch {
return 0;
}
}
-function IPe(e) {
+function RPe(e) {
var { clipPathId: t, props: n, pathRef: r, previousPointsRef: i, longestAnimatedLengthRef: a } = e, { points: o, strokeDasharray: s, isAnimationActive: c, animationBegin: l, animationDuration: u, animationEasing: d, animateNewValues: f, width: p, height: m, onAnimationEnd: h, onAnimationStart: g } = n, _ = i.current, v = vW(o, "recharts-line-"), y = (0, R.useRef)(v), [b, x] = (0, R.useState)(!1), S = !b, C = (0, R.useCallback)(() => {
typeof h == "function" && h(), x(!1);
}, [h]), w = (0, R.useCallback)(() => {
typeof g == "function" && g(), x(!0);
- }, [g]), T = FPe(r.current), E = (0, R.useRef)(0);
+ }, [g]), T = LPe(r.current), E = (0, R.useRef)(0);
y.current !== v && (E.current = a.current, y.current = v);
var D = E.current;
- return /*#__PURE__*/ R.createElement(PPe, {
+ return /*#__PURE__*/ R.createElement(IPe, {
points: o,
showLabels: S
}, n.children, /*#__PURE__*/ R.createElement(_W, {
@@ -65942,26 +65994,26 @@ function IPe(e) {
onAnimationStart: w,
key: v
}, (e) => {
- var l = NL(D, T + D, e), u = Math.min(l, T), d = c ? s ? MPe(u, T, `${s}`.split(/[,\s]+/gim).map((e) => parseFloat(e))) : M0(T, u) : s == null ? void 0 : String(s);
+ var l = PL(D, T + D, e), u = Math.min(l, T), d = c ? s ? PPe(u, T, `${s}`.split(/[,\s]+/gim).map((e) => parseFloat(e))) : j0(T, u) : s == null ? void 0 : String(s);
if (e > 0 && T > 0 && (i.current = o, a.current = Math.max(a.current, u)), _) {
var h = _.length / o.length, g = e === 1 ? o : o.map((t, n) => {
var r = Math.floor(n * h);
if (_[r]) {
var i = _[r];
- return A0(A0({}, t), {}, {
- x: NL(i.x, t.x, e),
- y: NL(i.y, t.y, e)
+ return k0(k0({}, t), {}, {
+ x: PL(i.x, t.x, e),
+ y: PL(i.y, t.y, e)
});
}
- return f ? A0(A0({}, t), {}, {
- x: NL(p * 2, t.x, e),
- y: NL(m / 2, t.y, e)
- }) : A0(A0({}, t), {}, {
+ return f ? k0(k0({}, t), {}, {
+ x: PL(p * 2, t.x, e),
+ y: PL(m / 2, t.y, e)
+ }) : k0(k0({}, t), {}, {
x: t.x,
y: t.y
});
});
- return i.current = g, /*#__PURE__*/ R.createElement(N0, {
+ return i.current = g, /*#__PURE__*/ R.createElement(M0, {
props: n,
points: g,
clipPathId: t,
@@ -65969,18 +66021,18 @@ function IPe(e) {
strokeDasharray: d
});
}
- return /*#__PURE__*/ R.createElement(N0, {
+ return /*#__PURE__*/ R.createElement(M0, {
props: n,
points: o,
clipPathId: t,
pathRef: r,
strokeDasharray: d
});
- }), /*#__PURE__*/ R.createElement(zQ, { label: n.label }));
+ }), /*#__PURE__*/ R.createElement(RQ, { label: n.label }));
}
-function LPe(e) {
+function zPe(e) {
var { clipPathId: t, props: n } = e, r = (0, R.useRef)(null), i = (0, R.useRef)(0), a = (0, R.useRef)(null);
- return /*#__PURE__*/ R.createElement(IPe, {
+ return /*#__PURE__*/ R.createElement(RPe, {
props: n,
clipPathId: t,
previousPointsRef: r,
@@ -65988,17 +66040,17 @@ function LPe(e) {
pathRef: a
});
}
-var RPe = (e, t) => ({
+var BPe = (e, t) => ({
x: e.x ?? void 0,
y: e.y ?? void 0,
value: e.value,
- errorVal: QB(e.payload, t)
-}), zPe = class extends R.Component {
+ errorVal: $B(e.payload, t)
+}), VPe = class extends R.Component {
render() {
var { hide: e, dot: t, points: n, className: r, xAxisId: i, yAxisId: a, top: o, left: s, width: c, height: l, id: u, needClip: d, zIndex: f } = this.props;
if (e) return null;
- var p = ja("recharts-line", r), m = u, { r: h, strokeWidth: g } = D0(t), _ = k$(t), v = h * 2 + g, y = d ? `url(#clipPath-${_ ? "" : "dots-"}${m})` : void 0;
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: f }, /*#__PURE__*/ R.createElement(wI, { className: p }, d && /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement(S0, {
+ var p = ja("recharts-line", r), m = u, { r: h, strokeWidth: g } = E0(t), _ = O$(t), v = h * 2 + g, y = d ? `url(#clipPath-${_ ? "" : "dots-"}${m})` : void 0;
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: f }, /*#__PURE__*/ R.createElement(TI, { className: p }, d && /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement(x0, {
clipPathId: m,
xAxisId: i,
yAxisId: a
@@ -66007,16 +66059,16 @@ var RPe = (e, t) => ({
y: o - v / 2,
width: c + v,
height: l + v
- }))), /*#__PURE__*/ R.createElement(b0, {
+ }))), /*#__PURE__*/ R.createElement(y0, {
xAxisId: i,
yAxisId: a,
data: n,
- dataPointFormatter: RPe,
+ dataPointFormatter: BPe,
errorBarOffset: 0
- }, /*#__PURE__*/ R.createElement(LPe, {
+ }, /*#__PURE__*/ R.createElement(zPe, {
props: this.props,
clipPathId: m
- }))), /*#__PURE__*/ R.createElement(a1, {
+ }))), /*#__PURE__*/ R.createElement(i1, {
activeDot: this.props.activeDot,
points: n,
mainColor: this.props.stroke,
@@ -66024,7 +66076,7 @@ var RPe = (e, t) => ({
clipPath: y
}));
}
-}, P0 = {
+}, N0 = {
activeDot: !0,
animateNewValues: !0,
animationBegin: 0,
@@ -66044,11 +66096,11 @@ var RPe = (e, t) => ({
zIndex: fG.line,
type: "linear"
};
-function BPe(e) {
- var t = JL(e, P0), { activeDot: n, animateNewValues: r, animationBegin: i, animationDuration: a, animationEasing: o, connectNulls: s, dot: c, hide: l, isAnimationActive: u, label: d, legendType: f, xAxisId: p, yAxisId: m, id: h } = t, g = j0(t, wPe), { needClip: _ } = x0(p, m), v = n1(), y = SH(), b = VV(), x = Q((e) => xPe(e, p, m, b, h));
+function HPe(e) {
+ var t = YL(e, N0), { activeDot: n, animateNewValues: r, animationBegin: i, animationDuration: a, animationEasing: o, connectNulls: s, dot: c, hide: l, isAnimationActive: u, label: d, legendType: f, xAxisId: p, yAxisId: m, id: h } = t, g = A0(t, EPe), { needClip: _ } = b0(p, m), v = t1(), y = CH(), b = HV(), x = Q((e) => CPe(e, p, m, b, h));
if (y !== "horizontal" && y !== "vertical" || x == null || v == null) return null;
var { height: S, width: C, x: w, y: T } = v;
- return /*#__PURE__*/ R.createElement(zPe, O0({}, g, {
+ return /*#__PURE__*/ R.createElement(VPe, D0({}, g, {
id: h,
connectNulls: s,
dot: c,
@@ -66072,23 +66124,23 @@ function BPe(e) {
needClip: _
}));
}
-function VPe(e) {
+function UPe(e) {
var { layout: t, xAxis: n, yAxis: r, xAxisTicks: i, yAxisTicks: a, dataKey: o, bandSize: s, displayedData: c } = e;
return c.map((e, c) => {
- var l = QB(e, o);
+ var l = $B(e, o);
if (t === "horizontal") return {
- x: sV({
+ x: cV({
axis: n,
ticks: i,
bandSize: s,
entry: e,
index: c
}),
- y: (FL(l) ? null : r.scale.map(l)) ?? null,
+ y: (IL(l) ? null : r.scale.map(l)) ?? null,
value: l,
payload: e
};
- var u = FL(l) ? null : n.scale.map(l), d = sV({
+ var u = IL(l) ? null : n.scale.map(l), d = cV({
axis: r,
ticks: a,
bandSize: s,
@@ -66103,12 +66155,12 @@ function VPe(e) {
};
}).filter(Boolean);
}
-function HPe(e) {
- var t = JL(e, P0), n = VV();
- return /*#__PURE__*/ R.createElement(G$, {
+function WPe(e) {
+ var t = YL(e, N0), n = HV();
+ return /*#__PURE__*/ R.createElement(W$, {
id: t.id,
type: "line"
- }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(U$, { legendPayload: kPe(t) }), /*#__PURE__*/ R.createElement(APe, {
+ }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(H$, { legendPayload: jPe(t) }), /*#__PURE__*/ R.createElement(MPe, {
dataKey: t.dataKey,
data: t.data,
stroke: t.stroke,
@@ -66119,7 +66171,7 @@ function HPe(e) {
unit: t.unit,
tooltipType: t.tooltipType,
id: e
- }), /*#__PURE__*/ R.createElement(q$, {
+ }), /*#__PURE__*/ R.createElement(K$, {
type: "line",
id: e,
data: t.data,
@@ -66129,33 +66181,33 @@ function HPe(e) {
dataKey: t.dataKey,
hide: t.hide,
isPanorama: n
- }), /*#__PURE__*/ R.createElement(BPe, O0({}, t, { id: e }))));
+ }), /*#__PURE__*/ R.createElement(HPe, D0({}, t, { id: e }))));
}
-var F0 = /*#__PURE__*/ R.memo(HPe, OU);
-F0.displayName = "Line";
+var P0 = /*#__PURE__*/ R.memo(WPe, OU);
+P0.displayName = "Line";
//#endregion
//#region node_modules/recharts/es6/state/selectors/graphicalItemSelectors.js
-function I0(e, t) {
+function F0(e, t) {
return e.graphicalItems.cartesianItems.find((e) => e.id === t)?.xAxisId ?? 0;
}
-function L0(e, t) {
+function I0(e, t) {
return e.graphicalItems.cartesianItems.find((e) => e.id === t)?.yAxisId ?? 0;
}
//#endregion
//#region node_modules/recharts/es6/state/selectors/areaSelectors.js
-var R0 = (e, t, n) => bX(e, "xAxis", I0(e, t), n), z0 = (e, t, n) => yX(e, "xAxis", I0(e, t), n), B0 = (e, t, n) => bX(e, "yAxis", L0(e, t), n), V0 = (e, t, n) => yX(e, "yAxis", L0(e, t), n), UPe = $([
- xH,
+var L0 = (e, t, n) => bX(e, "xAxis", F0(e, t), n), R0 = (e, t, n) => yX(e, "xAxis", F0(e, t), n), z0 = (e, t, n) => bX(e, "yAxis", I0(e, t), n), B0 = (e, t, n) => yX(e, "yAxis", I0(e, t), n), GPe = $([
+ SH,
+ L0,
+ z0,
R0,
- B0,
+ B0
+], (e, t, n, r, i) => tV(e, "xAxis") ? gV(t, r, !1) : gV(n, i, !1)), V0 = $([mY, (e, t) => t], (e, t) => e.filter((e) => e.type === "area").find((e) => e.id === t)), H0 = (e) => tV(SH(e), "xAxis") ? "yAxis" : "xAxis", KPe = (e, t) => H0(e) === "yAxis" ? I0(e, t) : F0(e, t), qPe = $([
+ SH,
+ L0,
z0,
- V0
-], (e, t, n, r, i) => eV(e, "xAxis") ? hV(t, r, !1) : hV(n, i, !1)), H0 = $([mY, (e, t) => t], (e, t) => e.filter((e) => e.type === "area").find((e) => e.id === t)), U0 = (e) => eV(xH(e), "xAxis") ? "yAxis" : "xAxis", WPe = (e, t) => U0(e) === "yAxis" ? L0(e, t) : I0(e, t), GPe = $([
- xH,
R0,
B0,
- z0,
- V0,
- $([H0, (e, t, n) => jY(e, U0(e), WPe(e, t), n)], (e, t) => {
+ $([V0, (e, t, n) => jY(e, H0(e), KPe(e, t), n)], (e, t) => {
if (e != null && t != null) {
var { stackId: n } = e, r = MG(e);
if (n != null && r != null) {
@@ -66165,14 +66217,14 @@ var R0 = (e, t, n) => bX(e, "xAxis", I0(e, t), n), z0 = (e, t, n) => yX(e, "xAxi
}
}),
UW,
- UPe,
- H0,
- uCe
+ GPe,
+ V0,
+ dCe
], (e, t, n, r, i, a, o, s, c, l) => {
var { chartData: u, dataStartIndex: d, dataEndIndex: f } = o;
if (!(c == null || e !== "horizontal" && e !== "vertical" || t == null || n == null || r == null || i == null || r.length === 0 || i.length === 0 || s == null)) {
var { data: p } = c, m = p && p.length > 0 ? p : u?.slice(d, f + 1);
- if (m != null) return dFe({
+ if (m != null) return pFe({
layout: e,
xAxis: t,
yAxis: n,
@@ -66186,7 +66238,7 @@ var R0 = (e, t, n) => bX(e, "xAxis", I0(e, t), n), z0 = (e, t, n) => yX(e, "xAxi
bandSize: s
});
}
-}), KPe = ["id"], qPe = [
+}), JPe = ["id"], YPe = [
"activeDot",
"animationBegin",
"animationDuration",
@@ -66202,25 +66254,25 @@ var R0 = (e, t, n) => bX(e, "xAxis", I0(e, t), n), z0 = (e, t, n) => yX(e, "xAxi
"xAxisId",
"yAxisId"
];
-function W0() {
- return W0 = Object.assign ? Object.assign.bind() : function(e) {
+function U0() {
+ return U0 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, W0.apply(null, arguments);
+ }, U0.apply(null, arguments);
}
-function G0(e, t) {
+function W0(e, t) {
if (e == null) return {};
- var n, r, i = JPe(e, t);
+ var n, r, i = XPe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function JPe(e, t) {
+function XPe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -66229,7 +66281,7 @@ function JPe(e, t) {
}
return n;
}
-function K0(e, t) {
+function G0(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -66239,30 +66291,30 @@ function K0(e, t) {
}
return n;
}
-function q0(e) {
+function K0(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? K0(Object(n), !0).forEach(function(t) {
- YPe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : K0(Object(n)).forEach(function(t) {
+ t % 2 ? G0(Object(n), !0).forEach(function(t) {
+ ZPe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : G0(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function YPe(e, t, n) {
- return (t = XPe(t)) in e ? Object.defineProperty(e, t, {
+function ZPe(e, t, n) {
+ return (t = QPe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function XPe(e) {
- var t = ZPe(e, "string");
+function QPe(e) {
+ var t = $Pe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function ZPe(e, t) {
+function $Pe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -66272,42 +66324,42 @@ function ZPe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function J0(e, t) {
+function q0(e, t) {
return e && e !== "none" ? e : t;
}
-var QPe = (e) => {
+var eFe = (e) => {
var { dataKey: t, name: n, stroke: r, fill: i, legendType: a, hide: o } = e;
return [{
inactive: o,
dataKey: t,
type: a,
- color: J0(r, i),
- value: _V(n, t),
+ color: q0(r, i),
+ value: vV(n, t),
payload: e
}];
-}, $Pe = /*#__PURE__*/ R.memo((e) => {
+}, tFe = /*#__PURE__*/ R.memo((e) => {
var { dataKey: t, data: n, stroke: r, strokeWidth: i, fill: a, name: o, hide: s, unit: c, tooltipType: l, id: u } = e, d = {
dataDefinedOnItem: n,
- getPosition: RL,
+ getPosition: zL,
settings: {
stroke: r,
strokeWidth: i,
fill: a,
dataKey: t,
nameKey: void 0,
- name: _V(o, t),
+ name: vV(o, t),
hide: s,
type: l,
- color: J0(r, a),
+ color: q0(r, a),
unit: c,
graphicalItemId: u
}
};
- return /*#__PURE__*/ R.createElement(H$, { tooltipEntrySettings: d });
+ return /*#__PURE__*/ R.createElement(V$, { tooltipEntrySettings: d });
});
-function eFe(e) {
- var { clipPathId: t, points: n, props: r } = e, { needClip: i, dot: a, dataKey: o } = r, s = vI(r);
- return /*#__PURE__*/ R.createElement(Q$, {
+function nFe(e) {
+ var { clipPathId: t, points: n, props: r } = e, { needClip: i, dot: a, dataKey: o } = r, s = yI(r);
+ return /*#__PURE__*/ R.createElement(Z$, {
points: n,
dot: a,
className: "recharts-area-dots",
@@ -66318,7 +66370,7 @@ function eFe(e) {
clipPathId: t
});
}
-function tFe(e) {
+function rFe(e) {
var { showLabels: t, children: n, points: r } = e, i = r.map((e) => {
var t = {
x: e.x ?? 0,
@@ -66328,7 +66380,7 @@ function tFe(e) {
upperWidth: 0,
height: 0
};
- return q0(q0({}, t), {}, {
+ return K0(K0({}, t), {}, {
value: e.value,
payload: e.payload,
parentViewBox: void 0,
@@ -66336,11 +66388,11 @@ function tFe(e) {
fill: void 0
});
});
- return /*#__PURE__*/ R.createElement(IQ, { value: t ? i : void 0 }, n);
+ return /*#__PURE__*/ R.createElement(FQ, { value: t ? i : void 0 }, n);
}
-function Y0(e) {
- var { points: t, baseLine: n, needClip: r, clipPathId: i, props: a } = e, { layout: o, type: s, stroke: c, connectNulls: l, isRange: u } = a, { id: d } = a, f = G0(a, KPe), p = vI(f), m = bI(f);
- return /*#__PURE__*/ R.createElement(R.Fragment, null, t?.length > 1 && /*#__PURE__*/ R.createElement(wI, { clipPath: r ? `url(#clipPath-${i})` : void 0 }, /*#__PURE__*/ R.createElement($U, W0({}, m, {
+function J0(e) {
+ var { points: t, baseLine: n, needClip: r, clipPathId: i, props: a } = e, { layout: o, type: s, stroke: c, connectNulls: l, isRange: u } = a, { id: d } = a, f = W0(a, JPe), p = yI(f), m = xI(f);
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, t?.length > 1 && /*#__PURE__*/ R.createElement(TI, { clipPath: r ? `url(#clipPath-${i})` : void 0 }, /*#__PURE__*/ R.createElement($U, U0({}, m, {
id: d,
points: t,
connectNulls: l,
@@ -66349,29 +66401,29 @@ function Y0(e) {
layout: o,
stroke: "none",
className: "recharts-area-area"
- })), c !== "none" && /*#__PURE__*/ R.createElement($U, W0({}, p, {
+ })), c !== "none" && /*#__PURE__*/ R.createElement($U, U0({}, p, {
className: "recharts-area-curve",
layout: o,
type: s,
connectNulls: l,
fill: "none",
points: t
- })), c !== "none" && u && Array.isArray(n) && /*#__PURE__*/ R.createElement($U, W0({}, p, {
+ })), c !== "none" && u && Array.isArray(n) && /*#__PURE__*/ R.createElement($U, U0({}, p, {
className: "recharts-area-curve",
layout: o,
type: s,
connectNulls: l,
fill: "none",
points: n
- }))), /*#__PURE__*/ R.createElement(eFe, {
+ }))), /*#__PURE__*/ R.createElement(nFe, {
points: t,
props: f,
clipPathId: i
}));
}
-function nFe(e) {
+function iFe(e) {
var { alpha: t, baseLine: n, points: r, strokeWidth: i } = e, a = r[0]?.y, o = r[r.length - 1]?.y;
- if (!GB(a) || !GB(o)) return null;
+ if (!KB(a) || !KB(o)) return null;
var s = t * Math.abs(a - o), c = Math.max(...r.map((e) => e.x || 0));
return Z(n) ? c = Math.max(n, c) : n && Array.isArray(n) && n.length && (c = Math.max(...n.map((e) => e.x || 0), c)), Z(c) ? /*#__PURE__*/ R.createElement("rect", {
x: 0,
@@ -66380,9 +66432,9 @@ function nFe(e) {
height: Math.floor(s)
}) : null;
}
-function rFe(e) {
+function aFe(e) {
var { alpha: t, baseLine: n, points: r, strokeWidth: i } = e, a = r[0]?.x, o = r[r.length - 1]?.x;
- if (!GB(a) || !GB(o)) return null;
+ if (!KB(a) || !KB(o)) return null;
var s = t * Math.abs(a - o), c = Math.max(...r.map((e) => e.y || 0));
return Z(n) ? c = Math.max(n, c) : n && Array.isArray(n) && n.length && (c = Math.max(...n.map((e) => e.y || 0), c)), Z(c) ? /*#__PURE__*/ R.createElement("rect", {
x: a < o ? a : a - s,
@@ -66391,32 +66443,32 @@ function rFe(e) {
height: Math.floor(c + (i ? parseInt(`${i}`, 10) : 1))
}) : null;
}
-function iFe(e) {
+function oFe(e) {
var { alpha: t, layout: n, points: r, baseLine: i, strokeWidth: a } = e;
- return n === "vertical" ? /*#__PURE__*/ R.createElement(nFe, {
+ return n === "vertical" ? /*#__PURE__*/ R.createElement(iFe, {
alpha: t,
points: r,
baseLine: i,
strokeWidth: a
- }) : /*#__PURE__*/ R.createElement(rFe, {
+ }) : /*#__PURE__*/ R.createElement(aFe, {
alpha: t,
points: r,
baseLine: i,
strokeWidth: a
});
}
-function aFe(e) {
+function sFe(e) {
var { needClip: t, clipPathId: n, props: r, previousPointsRef: i, previousBaselineRef: a } = e, { points: o, baseLine: s, isAnimationActive: c, animationBegin: l, animationDuration: u, animationEasing: d, onAnimationStart: f, onAnimationEnd: p } = r, m = vW((0, R.useMemo)(() => ({
points: o,
baseLine: s
- }), [o, s]), "recharts-area-"), h = CH(), [g, _] = (0, R.useState)(!1), v = !g, y = (0, R.useCallback)(() => {
+ }), [o, s]), "recharts-area-"), h = wH(), [g, _] = (0, R.useState)(!1), v = !g, y = (0, R.useCallback)(() => {
typeof p == "function" && p(), _(!1);
}, [p]), b = (0, R.useCallback)(() => {
typeof f == "function" && f(), _(!0);
}, [f]);
if (h == null) return null;
var x = i.current, S = a.current;
- return /*#__PURE__*/ R.createElement(tFe, {
+ return /*#__PURE__*/ R.createElement(rFe, {
showLabels: v,
points: o
}, r.children, /*#__PURE__*/ R.createElement(_W, {
@@ -66434,24 +66486,24 @@ function aFe(e) {
var r = Math.floor(n * l);
if (x[r]) {
var i = x[r];
- return q0(q0({}, t), {}, {
- x: NL(i.x, t.x, e),
- y: NL(i.y, t.y, e)
+ return K0(K0({}, t), {}, {
+ x: PL(i.x, t.x, e),
+ y: PL(i.y, t.y, e)
});
}
return t;
- }), d = Z(s) ? NL(S, s, e) : FL(s) || DL(s) ? NL(S, 0, e) : s.map((t, n) => {
+ }), d = Z(s) ? PL(S, s, e) : IL(s) || OL(s) ? PL(S, 0, e) : s.map((t, n) => {
var r = Math.floor(n * l);
if (Array.isArray(S) && S[r]) {
var i = S[r];
- return q0(q0({}, t), {}, {
- x: NL(i.x, t.x, e),
- y: NL(i.y, t.y, e)
+ return K0(K0({}, t), {}, {
+ x: PL(i.x, t.x, e),
+ y: PL(i.y, t.y, e)
});
}
return t;
});
- return e > 0 && (i.current = u, a.current = d), /*#__PURE__*/ R.createElement(Y0, {
+ return e > 0 && (i.current = u, a.current = d), /*#__PURE__*/ R.createElement(J0, {
points: u,
baseLine: d,
needClip: t,
@@ -66459,24 +66511,24 @@ function aFe(e) {
props: r
});
}
- return e > 0 && (i.current = o, a.current = s), /*#__PURE__*/ R.createElement(wI, null, c && /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement("clipPath", { id: `animationClipPath-${n}` }, /*#__PURE__*/ R.createElement(iFe, {
+ return e > 0 && (i.current = o, a.current = s), /*#__PURE__*/ R.createElement(TI, null, c && /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement("clipPath", { id: `animationClipPath-${n}` }, /*#__PURE__*/ R.createElement(oFe, {
alpha: e,
points: o,
baseLine: s,
layout: h,
strokeWidth: r.strokeWidth
- }))), /*#__PURE__*/ R.createElement(wI, { clipPath: `url(#animationClipPath-${n})` }, /*#__PURE__*/ R.createElement(Y0, {
+ }))), /*#__PURE__*/ R.createElement(TI, { clipPath: `url(#animationClipPath-${n})` }, /*#__PURE__*/ R.createElement(J0, {
points: o,
baseLine: s,
needClip: t,
clipPathId: n,
props: r
})));
- }), /*#__PURE__*/ R.createElement(zQ, { label: r.label }));
+ }), /*#__PURE__*/ R.createElement(RQ, { label: r.label }));
}
-function oFe(e) {
+function cFe(e) {
var { needClip: t, clipPathId: n, props: r } = e, i = (0, R.useRef)(null), a = (0, R.useRef)();
- return /*#__PURE__*/ R.createElement(aFe, {
+ return /*#__PURE__*/ R.createElement(sFe, {
needClip: t,
clipPathId: n,
props: r,
@@ -66484,12 +66536,12 @@ function oFe(e) {
previousBaselineRef: a
});
}
-var sFe = class extends R.PureComponent {
+var lFe = class extends R.PureComponent {
render() {
var { hide: e, dot: t, points: n, className: r, top: i, left: a, needClip: o, xAxisId: s, yAxisId: c, width: l, height: u, id: d, baseLine: f, zIndex: p } = this.props;
if (e) return null;
- var m = ja("recharts-area", r), h = d, { r: g, strokeWidth: _ } = D0(t), v = k$(t), y = g * 2 + _, b = o ? `url(#clipPath-${v ? "" : "dots-"}${h})` : void 0;
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: p }, /*#__PURE__*/ R.createElement(wI, { className: m }, o && /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement(S0, {
+ var m = ja("recharts-area", r), h = d, { r: g, strokeWidth: _ } = E0(t), v = O$(t), y = g * 2 + _, b = o ? `url(#clipPath-${v ? "" : "dots-"}${h})` : void 0;
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: p }, /*#__PURE__*/ R.createElement(TI, { className: m }, o && /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement(x0, {
clipPathId: h,
xAxisId: s,
yAxisId: c
@@ -66498,25 +66550,25 @@ var sFe = class extends R.PureComponent {
y: i - y / 2,
width: l + y,
height: u + y
- }))), /*#__PURE__*/ R.createElement(oFe, {
+ }))), /*#__PURE__*/ R.createElement(cFe, {
needClip: o,
clipPathId: h,
props: this.props
- })), /*#__PURE__*/ R.createElement(a1, {
+ })), /*#__PURE__*/ R.createElement(i1, {
points: n,
- mainColor: J0(this.props.stroke, this.props.fill),
+ mainColor: q0(this.props.stroke, this.props.fill),
itemDataKey: this.props.dataKey,
activeDot: this.props.activeDot,
clipPath: b
- }), this.props.isRange && Array.isArray(f) && /*#__PURE__*/ R.createElement(a1, {
+ }), this.props.isRange && Array.isArray(f) && /*#__PURE__*/ R.createElement(i1, {
points: f,
- mainColor: J0(this.props.stroke, this.props.fill),
+ mainColor: q0(this.props.stroke, this.props.fill),
itemDataKey: this.props.dataKey,
activeDot: this.props.activeDot,
clipPath: b
}));
}
-}, cFe = {
+}, uFe = {
activeDot: !0,
animationBegin: 0,
animationDuration: 1500,
@@ -66536,11 +66588,11 @@ var sFe = class extends R.PureComponent {
yAxisId: 0,
zIndex: fG.area
};
-function lFe(e) {
- var { activeDot: t, animationBegin: n, animationDuration: r, animationEasing: i, connectNulls: a, dot: o, fill: s, fillOpacity: c, hide: l, isAnimationActive: u, legendType: d, stroke: f, xAxisId: p, yAxisId: m } = e, h = G0(e, qPe), g = SH(), _ = hZ(), { needClip: v } = x0(p, m), y = VV(), { points: b, isRange: x, baseLine: S } = Q((t) => GPe(t, e.id, y)) ?? {}, C = n1();
+function dFe(e) {
+ var { activeDot: t, animationBegin: n, animationDuration: r, animationEasing: i, connectNulls: a, dot: o, fill: s, fillOpacity: c, hide: l, isAnimationActive: u, legendType: d, stroke: f, xAxisId: p, yAxisId: m } = e, h = W0(e, YPe), g = CH(), _ = hZ(), { needClip: v } = b0(p, m), y = HV(), { points: b, isRange: x, baseLine: S } = Q((t) => qPe(t, e.id, y)) ?? {}, C = t1();
if (g !== "horizontal" && g !== "vertical" || C == null || _ !== "AreaChart" && _ !== "ComposedChart") return null;
var { height: w, width: T, x: E, y: D } = C;
- return !b || !b.length ? null : /*#__PURE__*/ R.createElement(sFe, W0({}, h, {
+ return !b || !b.length ? null : /*#__PURE__*/ R.createElement(lFe, U0({}, h, {
activeDot: t,
animationBegin: n,
animationDuration: r,
@@ -66566,7 +66618,7 @@ function lFe(e) {
yAxisId: m
}));
}
-var uFe = (e, t, n, r, i) => {
+var fFe = (e, t, n, r, i) => {
var a = n ?? t;
if (Z(a)) return a;
var o = e === "horizontal" ? i : r, s = o.scale.domain();
@@ -66576,17 +66628,17 @@ var uFe = (e, t, n, r, i) => {
}
return a === "dataMin" ? s[0] : a === "dataMax" ? s[1] : s[0];
};
-function dFe(e) {
- var { areaSettings: { connectNulls: t, baseValue: n, dataKey: r }, stackedData: i, layout: a, chartBaseValue: o, xAxis: s, yAxis: c, displayedData: l, dataStartIndex: u, xAxisTicks: d, yAxisTicks: f, bandSize: p } = e, m = i && i.length, h = uFe(a, o, n, s, c), g = a === "horizontal", _ = !1, v = l.map((e, n) => {
+function pFe(e) {
+ var { areaSettings: { connectNulls: t, baseValue: n, dataKey: r }, stackedData: i, layout: a, chartBaseValue: o, xAxis: s, yAxis: c, displayedData: l, dataStartIndex: u, xAxisTicks: d, yAxisTicks: f, bandSize: p } = e, m = i && i.length, h = fFe(a, o, n, s, c), g = a === "horizontal", _ = !1, v = l.map((e, n) => {
var a;
if (m) a = i[u + n];
else {
- var o = QB(e, r);
+ var o = $B(e, r);
Array.isArray(o) ? (a = o, _ = !0) : a = [h, o];
}
- var l = a?.[1] ?? null, v = l == null || m && !t && QB(e, r) == null;
+ var l = a?.[1] ?? null, v = l == null || m && !t && $B(e, r) == null;
return g ? {
- x: sV({
+ x: cV({
axis: s,
ticks: d,
bandSize: p,
@@ -66598,7 +66650,7 @@ function dFe(e) {
payload: e
} : {
x: v ? null : s.scale.map(l) ?? null,
- y: sV({
+ y: cV({
axis: c,
ticks: f,
bandSize: p,
@@ -66626,12 +66678,12 @@ function dFe(e) {
isRange: _
};
}
-function fFe(e) {
- var t = JL(e, cFe), n = VV();
- return /*#__PURE__*/ R.createElement(G$, {
+function mFe(e) {
+ var t = YL(e, uFe), n = HV();
+ return /*#__PURE__*/ R.createElement(W$, {
id: t.id,
type: "area"
- }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(U$, { legendPayload: QPe(t) }), /*#__PURE__*/ R.createElement($Pe, {
+ }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(H$, { legendPayload: eFe(t) }), /*#__PURE__*/ R.createElement(tFe, {
dataKey: t.dataKey,
data: t.data,
stroke: t.stroke,
@@ -66642,7 +66694,7 @@ function fFe(e) {
unit: t.unit,
tooltipType: t.tooltipType,
id: e
- }), /*#__PURE__*/ R.createElement(q$, {
+ }), /*#__PURE__*/ R.createElement(K$, {
type: "area",
id: e,
data: t.data,
@@ -66650,115 +66702,115 @@ function fFe(e) {
xAxisId: t.xAxisId,
yAxisId: t.yAxisId,
zAxisId: 0,
- stackId: oV(t.stackId),
+ stackId: sV(t.stackId),
hide: t.hide,
barSize: void 0,
baseValue: t.baseValue,
isPanorama: n,
connectNulls: t.connectNulls
- }), /*#__PURE__*/ R.createElement(lFe, W0({}, t, { id: e }))));
+ }), /*#__PURE__*/ R.createElement(dFe, U0({}, t, { id: e }))));
}
-var X0 = /*#__PURE__*/ R.memo(fFe, OU);
-X0.displayName = "Area";
+var Y0 = /*#__PURE__*/ R.memo(mFe, OU);
+Y0.displayName = "Area";
//#endregion
//#region node_modules/tiny-invariant/dist/esm/tiny-invariant.js
-var pFe = "Invariant failed";
-function mFe(e, t) {
- if (!e) throw Error(pFe);
+var hFe = "Invariant failed";
+function gFe(e, t) {
+ if (!e) throw Error(hFe);
}
//#endregion
//#region node_modules/recharts/es6/util/BarUtils.js
-function Z0() {
- return Z0 = Object.assign ? Object.assign.bind() : function(e) {
+function X0() {
+ return X0 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, Z0.apply(null, arguments);
+ }, X0.apply(null, arguments);
}
-function Q0(e) {
- return /*#__PURE__*/ R.createElement(R$, Z0({
+function Z0(e) {
+ return /*#__PURE__*/ R.createElement(L$, X0({
shapeType: "rectangle",
activeClassName: "recharts-active-bar",
inActiveClassName: "recharts-inactive-bar"
}, e));
}
-var hFe = function(e) {
+var _Fe = function(e) {
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
return (n, r) => {
if (Z(e)) return e;
- var i = Z(n) || FL(n);
- return i ? e(n, r) : (!i && mFe(!1, `minPointSize callback function received a value with type of ${typeof n}. Currently only numbers or null/undefined are supported.`), t);
+ var i = Z(n) || IL(n);
+ return i ? e(n, r) : (!i && gFe(!1, `minPointSize callback function received a value with type of ${typeof n}. Currently only numbers or null/undefined are supported.`), t);
};
-}, gFe = (e, t, n) => n, $0 = $([mY, (e, t) => t], (e, t) => e.filter((e) => e.type === "bar").find((e) => e.id === t)), _Fe = $([$0], (e) => e?.maxBarSize), vFe = (e, t, n, r) => r, yFe = $([
- xH,
+}, vFe = (e, t, n) => n, Q0 = $([mY, (e, t) => t], (e, t) => e.filter((e) => e.type === "bar").find((e) => e.id === t)), yFe = $([Q0], (e) => e?.maxBarSize), bFe = (e, t, n, r) => r, xFe = $([
+ SH,
mY,
+ F0,
I0,
- L0,
- gFe
-], (e, t, n, r, i) => t.filter((t) => e === "horizontal" ? t.xAxisId === n : t.yAxisId === r).filter((e) => e.isPanorama === i).filter((e) => e.hide === !1).filter((e) => e.type === "bar")), bFe = (e, t, n) => {
- var r = xH(e), i = I0(e, t), a = L0(e, t);
+ vFe
+], (e, t, n, r, i) => t.filter((t) => e === "horizontal" ? t.xAxisId === n : t.yAxisId === r).filter((e) => e.isPanorama === i).filter((e) => e.hide === !1).filter((e) => e.type === "bar")), SFe = (e, t, n) => {
+ var r = SH(e), i = F0(e, t), a = I0(e, t);
if (i != null && a != null) return r === "horizontal" ? jY(e, "yAxis", a, n) : jY(e, "xAxis", i, n);
-}, xFe = $([
- yFe,
+}, CFe = $([
+ xFe,
aG,
(e, t) => {
- var n = xH(e), r = I0(e, t), i = L0(e, t);
+ var n = SH(e), r = F0(e, t), i = I0(e, t);
if (r != null && i != null) return n === "horizontal" ? fX(e, "xAxis", r) : fX(e, "yAxis", i);
}
-], x1), SFe = (e, t, n) => {
- var r = $0(e, t);
+], b1), wFe = (e, t, n) => {
+ var r = Q0(e, t);
if (r == null) return 0;
- var i = I0(e, t), a = L0(e, t);
+ var i = F0(e, t), a = I0(e, t);
if (i == null || a == null) return 0;
- var o = xH(e), s = nG(e), { maxBarSize: c } = r, l = FL(c) ? s : c, u, d;
- return o === "horizontal" ? (u = bX(e, "xAxis", i, n), d = yX(e, "xAxis", i, n)) : (u = bX(e, "yAxis", a, n), d = yX(e, "yAxis", a, n)), hV(u, d, !0) ?? l ?? 0;
-}, e2 = (e, t, n) => {
- var r = xH(e), i = I0(e, t), a = L0(e, t);
+ var o = SH(e), s = nG(e), { maxBarSize: c } = r, l = IL(c) ? s : c, u, d;
+ return o === "horizontal" ? (u = bX(e, "xAxis", i, n), d = yX(e, "xAxis", i, n)) : (u = bX(e, "yAxis", a, n), d = yX(e, "yAxis", a, n)), gV(u, d, !0) ?? l ?? 0;
+}, $0 = (e, t, n) => {
+ var r = SH(e), i = F0(e, t), a = I0(e, t);
if (i != null && a != null) {
var o, s;
- return r === "horizontal" ? (o = bX(e, "xAxis", i, n), s = yX(e, "xAxis", i, n)) : (o = bX(e, "yAxis", a, n), s = yX(e, "yAxis", a, n)), hV(o, s);
+ return r === "horizontal" ? (o = bX(e, "xAxis", i, n), s = yX(e, "xAxis", i, n)) : (o = bX(e, "yAxis", a, n), s = yX(e, "yAxis", a, n)), gV(o, s);
}
-}, CFe = $([
- LV,
- zV,
+}, TFe = $([
+ RV,
+ BV,
(e, t, n) => {
- var r = I0(e, t);
+ var r = F0(e, t);
if (r != null) return bX(e, "xAxis", r, n);
},
(e, t, n) => {
- var r = L0(e, t);
+ var r = I0(e, t);
if (r != null) return bX(e, "yAxis", r, n);
},
(e, t, n) => {
- var r = I0(e, t);
+ var r = F0(e, t);
if (r != null) return yX(e, "xAxis", r, n);
},
(e, t, n) => {
- var r = L0(e, t);
+ var r = I0(e, t);
if (r != null) return yX(e, "yAxis", r, n);
},
$([$([
- xFe,
+ CFe,
nG,
rG,
iG,
- SFe,
- e2,
- _Fe
- ], w1), $0], E1),
- xH,
+ wFe,
+ $0,
+ yFe
+ ], C1), Q0], T1),
+ SH,
UW,
- e2,
- $([bFe, $0], T1),
$0,
- vFe
+ $([SFe, Q0], w1),
+ Q0,
+ bFe
], (e, t, n, r, i, a, o, s, c, l, u, d, f) => {
var { chartData: p, dataStartIndex: m, dataEndIndex: h } = c;
if (!(d == null || o == null || t == null || s !== "horizontal" && s !== "vertical" || n == null || r == null || i == null || a == null || l == null)) {
var { data: g } = d, _ = g != null && g.length > 0 ? g : p?.slice(m, h + 1);
- if (_ != null) return ZFe({
+ if (_ != null) return $Fe({
layout: s,
barSettings: d,
pos: o,
@@ -66775,26 +66827,26 @@ var hFe = function(e) {
dataStartIndex: m
});
}
-}), wFe = ["index"];
-function t2() {
- return t2 = Object.assign ? Object.assign.bind() : function(e) {
+}), EFe = ["index"];
+function e2() {
+ return e2 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, t2.apply(null, arguments);
+ }, e2.apply(null, arguments);
}
-function TFe(e, t) {
+function DFe(e, t) {
if (e == null) return {};
- var n, r, i = EFe(e, t);
+ var n, r, i = OFe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function EFe(e, t) {
+function OFe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -66803,45 +66855,45 @@ function EFe(e, t) {
}
return n;
}
-var n2 = /*#__PURE__*/ (0, R.createContext)(void 0), DFe = (e) => {
- var t = (0, R.useContext)(n2);
+var t2 = /*#__PURE__*/ (0, R.createContext)(void 0), kFe = (e) => {
+ var t = (0, R.useContext)(t2);
if (t != null) return t.stackId;
- if (e != null) return oV(e);
-}, OFe = (e, t) => `recharts-bar-stack-clip-path-${e}-${t}`, kFe = (e) => {
- var t = (0, R.useContext)(n2);
+ if (e != null) return sV(e);
+}, AFe = (e, t) => `recharts-bar-stack-clip-path-${e}-${t}`, jFe = (e) => {
+ var t = (0, R.useContext)(t2);
if (t != null) {
var { stackId: n } = t;
- return `url(#${OFe(n, e)})`;
+ return `url(#${AFe(n, e)})`;
}
-}, r2 = (e) => {
- var { index: t } = e, n = TFe(e, wFe), r = kFe(t);
- return /*#__PURE__*/ R.createElement(wI, t2({
+}, n2 = (e) => {
+ var { index: t } = e, n = DFe(e, EFe), r = jFe(t);
+ return /*#__PURE__*/ R.createElement(TI, e2({
className: "recharts-bar-stack-layer",
clipPath: r
}, n));
-}, AFe = [
+}, MFe = [
"onMouseEnter",
"onMouseLeave",
"onClick"
-], jFe = [
+], NFe = [
"value",
"background",
"tooltipPosition"
-], MFe = ["id"], NFe = [
+], PFe = ["id"], FFe = [
"onMouseEnter",
"onClick",
"onMouseLeave"
];
-function i2() {
- return i2 = Object.assign ? Object.assign.bind() : function(e) {
+function r2() {
+ return r2 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, i2.apply(null, arguments);
+ }, r2.apply(null, arguments);
}
-function a2(e, t) {
+function i2(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -66851,30 +66903,30 @@ function a2(e, t) {
}
return n;
}
-function o2(e) {
+function a2(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? a2(Object(n), !0).forEach(function(t) {
- PFe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : a2(Object(n)).forEach(function(t) {
+ t % 2 ? i2(Object(n), !0).forEach(function(t) {
+ IFe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : i2(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function PFe(e, t, n) {
- return (t = FFe(t)) in e ? Object.defineProperty(e, t, {
+function IFe(e, t, n) {
+ return (t = LFe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function FFe(e) {
- var t = IFe(e, "string");
+function LFe(e) {
+ var t = RFe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function IFe(e, t) {
+function RFe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -66884,16 +66936,16 @@ function IFe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function s2(e, t) {
+function o2(e, t) {
if (e == null) return {};
- var n, r, i = LFe(e, t);
+ var n, r, i = zFe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function LFe(e, t) {
+function zFe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -66902,27 +66954,27 @@ function LFe(e, t) {
}
return n;
}
-var RFe = (e) => {
+var BFe = (e) => {
var { dataKey: t, name: n, fill: r, legendType: i, hide: a } = e;
return [{
inactive: a,
dataKey: t,
type: i,
color: r,
- value: _V(n, t),
+ value: vV(n, t),
payload: e
}];
-}, zFe = /*#__PURE__*/ R.memo((e) => {
+}, VFe = /*#__PURE__*/ R.memo((e) => {
var { dataKey: t, stroke: n, strokeWidth: r, fill: i, name: a, hide: o, unit: s, tooltipType: c, id: l } = e, u = {
dataDefinedOnItem: void 0,
- getPosition: RL,
+ getPosition: zL,
settings: {
stroke: n,
strokeWidth: r,
fill: i,
dataKey: t,
nameKey: void 0,
- name: _V(a, t),
+ name: vV(a, t),
hide: o,
type: c,
color: i,
@@ -66930,19 +66982,19 @@ var RFe = (e) => {
graphicalItemId: l
}
};
- return /*#__PURE__*/ R.createElement(H$, { tooltipEntrySettings: u });
+ return /*#__PURE__*/ R.createElement(V$, { tooltipEntrySettings: u });
});
-function BFe(e) {
- var t = Q(oZ), { data: n, dataKey: r, background: i, allOtherBarProps: a } = e, { onMouseEnter: o, onMouseLeave: s, onClick: c } = a, l = s2(a, AFe), u = z$(o, r, a.id), d = B$(s), f = V$(c, r, a.id);
+function HFe(e) {
+ var t = Q(oZ), { data: n, dataKey: r, background: i, allOtherBarProps: a } = e, { onMouseEnter: o, onMouseLeave: s, onClick: c } = a, l = o2(a, MFe), u = R$(o, r, a.id), d = z$(s), f = B$(c, r, a.id);
if (!i || n == null) return null;
- var p = yI(i);
- return /*#__PURE__*/ R.createElement(DZ, { zIndex: z1(i, fG.barBackground) }, n.map((e, n) => {
- var { value: a, background: o, tooltipPosition: s } = e, c = s2(e, jFe);
+ var p = bI(i);
+ return /*#__PURE__*/ R.createElement(DZ, { zIndex: R1(i, fG.barBackground) }, n.map((e, n) => {
+ var { value: a, background: o, tooltipPosition: s } = e, c = o2(e, NFe);
if (!o) return null;
- var m = u(e, n), h = d(e, n), g = f(e, n), _ = o2(o2(o2(o2(o2({
+ var m = u(e, n), h = d(e, n), g = f(e, n), _ = a2(a2(a2(a2(a2({
option: i,
isActive: String(n) === t
- }, c), {}, { fill: "#eee" }, o), p), KL(l, e, n)), {}, {
+ }, c), {}, { fill: "#eee" }, o), p), qL(l, e, n)), {}, {
onMouseEnter: m,
onMouseLeave: h,
onClick: g,
@@ -66950,10 +67002,10 @@ function BFe(e) {
index: n,
className: "recharts-bar-background-rectangle"
});
- return /*#__PURE__*/ R.createElement(Q0, i2({ key: `background-bar-${n}` }, _));
+ return /*#__PURE__*/ R.createElement(Z0, r2({ key: `background-bar-${n}` }, _));
}));
}
-function VFe(e) {
+function UFe(e) {
var { showLabels: t, children: n, rects: r } = e, i = r?.map((e) => {
var t = {
x: e.x,
@@ -66963,7 +67015,7 @@ function VFe(e) {
upperWidth: e.width,
height: e.height
};
- return o2(o2({}, t), {}, {
+ return a2(a2({}, t), {}, {
value: e.value,
payload: e.payload,
parentViewBox: e.parentViewBox,
@@ -66971,9 +67023,9 @@ function VFe(e) {
fill: e.fill
});
});
- return /*#__PURE__*/ R.createElement(IQ, { value: t ? i : void 0 }, n);
+ return /*#__PURE__*/ R.createElement(FQ, { value: t ? i : void 0 }, n);
}
-function HFe(e) {
+function WFe(e) {
var { shape: t, activeBar: n, baseProps: r, entry: i, index: a, dataKey: o } = e, s = Q(oZ), c = Q(cZ), l = n && String(i.originalDataIndex) === s && (c == null || o === c), [u, d] = (0, R.useState)(!1), [f, p] = (0, R.useState)(!1);
(0, R.useEffect)(() => {
var e;
@@ -66985,42 +67037,42 @@ function HFe(e) {
}, [l]);
var m = (0, R.useCallback)(() => {
l || d(!1);
- }, [l]), h = l && f, g = l || u, _ = l ? n === !0 ? t : n : t, v = /*#__PURE__*/ R.createElement(Q0, i2({}, r, { name: String(r.name) }, i, {
+ }, [l]), h = l && f, g = l || u, _ = l ? n === !0 ? t : n : t, v = /*#__PURE__*/ R.createElement(Z0, r2({}, r, { name: String(r.name) }, i, {
isActive: h,
option: _,
index: a,
dataKey: o,
onTransitionEnd: m
}));
- return g ? /*#__PURE__*/ R.createElement(DZ, { zIndex: fG.activeBar }, /*#__PURE__*/ R.createElement(r2, { index: i.originalDataIndex }, v)) : v;
+ return g ? /*#__PURE__*/ R.createElement(DZ, { zIndex: fG.activeBar }, /*#__PURE__*/ R.createElement(n2, { index: i.originalDataIndex }, v)) : v;
}
-function UFe(e) {
+function GFe(e) {
var { shape: t, baseProps: n, entry: r, index: i, dataKey: a } = e;
- return /*#__PURE__*/ R.createElement(Q0, i2({}, n, { name: String(n.name) }, r, {
+ return /*#__PURE__*/ R.createElement(Z0, r2({}, n, { name: String(n.name) }, r, {
isActive: !1,
option: t,
index: i,
dataKey: a
}));
}
-function WFe(e) {
- var { data: t, props: n } = e, r = vI(n) ?? {}, { id: i } = r, a = s2(r, MFe), { shape: o, dataKey: s, activeBar: c } = n, { onMouseEnter: l, onClick: u, onMouseLeave: d } = n, f = s2(n, NFe), p = z$(l, s, i), m = B$(d), h = V$(u, s, i);
- return t ? /*#__PURE__*/ R.createElement(R.Fragment, null, t.map((e, t) => /*#__PURE__*/ R.createElement(r2, i2({
+function KFe(e) {
+ var { data: t, props: n } = e, r = yI(n) ?? {}, { id: i } = r, a = o2(r, PFe), { shape: o, dataKey: s, activeBar: c } = n, { onMouseEnter: l, onClick: u, onMouseLeave: d } = n, f = o2(n, FFe), p = R$(l, s, i), m = z$(d), h = B$(u, s, i);
+ return t ? /*#__PURE__*/ R.createElement(R.Fragment, null, t.map((e, t) => /*#__PURE__*/ R.createElement(n2, r2({
index: e.originalDataIndex,
key: `rectangle-${e?.x}-${e?.y}-${e?.value}-${t}`,
className: "recharts-bar-rectangle"
- }, KL(f, e, t), {
+ }, qL(f, e, t), {
onMouseEnter: p(e, t),
onMouseLeave: m(e, t),
onClick: h(e, t)
- }), c ? /*#__PURE__*/ R.createElement(HFe, {
+ }), c ? /*#__PURE__*/ R.createElement(WFe, {
shape: o,
activeBar: c,
baseProps: a,
entry: e,
index: t,
dataKey: s
- }) : /*#__PURE__*/ R.createElement(UFe, {
+ }) : /*#__PURE__*/ R.createElement(GFe, {
shape: o,
baseProps: a,
entry: e,
@@ -67028,13 +67080,13 @@ function WFe(e) {
dataKey: s
})))) : null;
}
-function GFe(e) {
+function qFe(e) {
var { props: t, previousRectanglesRef: n } = e, { data: r, layout: i, isAnimationActive: a, animationBegin: o, animationDuration: s, animationEasing: c, onAnimationEnd: l, onAnimationStart: u } = t, d = n.current, f = vW(t, "recharts-bar-"), [p, m] = (0, R.useState)(!1), h = !p, g = (0, R.useCallback)(() => {
typeof l == "function" && l(), m(!1);
}, [l]), _ = (0, R.useCallback)(() => {
typeof u == "function" && u(), m(!0);
}, [u]);
- return /*#__PURE__*/ R.createElement(VFe, {
+ return /*#__PURE__*/ R.createElement(UFe, {
showLabels: h,
rects: r
}, /*#__PURE__*/ R.createElement(_W, {
@@ -67049,69 +67101,69 @@ function GFe(e) {
}, (e) => {
var a = e === 1 ? r : r?.map((t, n) => {
var r = d && d[n];
- if (r) return o2(o2({}, t), {}, {
- x: NL(r.x, t.x, e),
- y: NL(r.y, t.y, e),
- width: NL(r.width, t.width, e),
- height: NL(r.height, t.height, e)
+ if (r) return a2(a2({}, t), {}, {
+ x: PL(r.x, t.x, e),
+ y: PL(r.y, t.y, e),
+ width: PL(r.width, t.width, e),
+ height: PL(r.height, t.height, e)
});
if (i === "horizontal") {
- var a = NL(0, t.height, e), o = NL(t.stackedBarStart, t.y, e);
- return o2(o2({}, t), {}, {
+ var a = PL(0, t.height, e), o = PL(t.stackedBarStart, t.y, e);
+ return a2(a2({}, t), {}, {
y: o,
height: a
});
}
- var s = NL(0, t.width, e), c = NL(t.stackedBarStart, t.x, e);
- return o2(o2({}, t), {}, {
+ var s = PL(0, t.width, e), c = PL(t.stackedBarStart, t.x, e);
+ return a2(a2({}, t), {}, {
width: s,
x: c
});
});
- return e > 0 && (n.current = a ?? null), a == null ? null : /*#__PURE__*/ R.createElement(wI, null, /*#__PURE__*/ R.createElement(WFe, {
+ return e > 0 && (n.current = a ?? null), a == null ? null : /*#__PURE__*/ R.createElement(TI, null, /*#__PURE__*/ R.createElement(KFe, {
props: t,
data: a
}));
- }), /*#__PURE__*/ R.createElement(zQ, { label: t.label }), t.children);
+ }), /*#__PURE__*/ R.createElement(RQ, { label: t.label }), t.children);
}
-function KFe(e) {
+function JFe(e) {
var t = (0, R.useRef)(null);
- return /*#__PURE__*/ R.createElement(GFe, {
+ return /*#__PURE__*/ R.createElement(qFe, {
previousRectanglesRef: t,
props: e
});
}
-var c2 = 0, qFe = (e, t) => {
+var s2 = 0, YFe = (e, t) => {
var n = Array.isArray(e.value) ? e.value[1] : e.value;
return {
x: e.x,
y: e.y,
value: n,
- errorVal: QB(e, t)
+ errorVal: $B(e, t)
};
-}, JFe = class extends R.PureComponent {
+}, XFe = class extends R.PureComponent {
render() {
var { hide: e, data: t, dataKey: n, className: r, xAxisId: i, yAxisId: a, needClip: o, background: s, id: c } = this.props;
if (e || t == null) return null;
var l = ja("recharts-bar", r), u = c;
- return /*#__PURE__*/ R.createElement(wI, {
+ return /*#__PURE__*/ R.createElement(TI, {
className: l,
id: c
- }, o && /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement(S0, {
+ }, o && /*#__PURE__*/ R.createElement("defs", null, /*#__PURE__*/ R.createElement(x0, {
clipPathId: u,
xAxisId: i,
yAxisId: a
- })), /*#__PURE__*/ R.createElement(wI, {
+ })), /*#__PURE__*/ R.createElement(TI, {
className: "recharts-bar-rectangles",
clipPath: o ? `url(#clipPath-${u})` : void 0
- }, /*#__PURE__*/ R.createElement(BFe, {
+ }, /*#__PURE__*/ R.createElement(HFe, {
data: t,
dataKey: n,
background: s,
allOtherBarProps: this.props
- }), /*#__PURE__*/ R.createElement(KFe, this.props)));
+ }), /*#__PURE__*/ R.createElement(JFe, this.props)));
}
-}, YFe = {
+}, ZFe = {
activeBar: !1,
animationBegin: 0,
animationDuration: 400,
@@ -67121,22 +67173,22 @@ var c2 = 0, qFe = (e, t) => {
isAnimationActive: "auto",
label: !1,
legendType: "rect",
- minPointSize: c2,
+ minPointSize: s2,
xAxisId: 0,
yAxisId: 0,
zIndex: fG.bar
};
-function XFe(e) {
- var { xAxisId: t, yAxisId: n, hide: r, legendType: i, minPointSize: a, activeBar: o, animationBegin: s, animationDuration: c, animationEasing: l, isAnimationActive: u } = e, { needClip: d } = x0(t, n), f = SH(), p = VV(), m = O$(e.children, WZ), h = Q((t) => CFe(t, e.id, p, m));
+function QFe(e) {
+ var { xAxisId: t, yAxisId: n, hide: r, legendType: i, minPointSize: a, activeBar: o, animationBegin: s, animationDuration: c, animationEasing: l, isAnimationActive: u } = e, { needClip: d } = b0(t, n), f = CH(), p = HV(), m = D$(e.children, WZ), h = Q((t) => TFe(t, e.id, p, m));
if (f !== "vertical" && f !== "horizontal") return null;
var g, _ = h?.[0];
- return g = _ == null || _.height == null || _.width == null ? 0 : f === "vertical" ? _.height / 2 : _.width / 2, /*#__PURE__*/ R.createElement(b0, {
+ return g = _ == null || _.height == null || _.width == null ? 0 : f === "vertical" ? _.height / 2 : _.width / 2, /*#__PURE__*/ R.createElement(y0, {
xAxisId: t,
yAxisId: n,
data: h,
- dataPointFormatter: qFe,
+ dataPointFormatter: YFe,
errorBarOffset: g
- }, /*#__PURE__*/ R.createElement(JFe, i2({}, e, {
+ }, /*#__PURE__*/ R.createElement(XFe, r2({}, e, {
layout: f,
needClip: d,
data: h,
@@ -67152,20 +67204,20 @@ function XFe(e) {
isAnimationActive: u
})));
}
-function ZFe(e) {
- var { layout: t, barSettings: { dataKey: n, minPointSize: r, hasCustomShape: i }, pos: a, bandSize: o, xAxis: s, yAxis: c, xAxisTicks: l, yAxisTicks: u, stackedData: d, displayedData: f, offset: p, cells: m, parentViewBox: h, dataStartIndex: g } = e, _ = t === "horizontal" ? c : s, v = d ? _.scale.domain() : null, y = lV({ numericAxis: _ }), b = _.scale.map(y);
+function $Fe(e) {
+ var { layout: t, barSettings: { dataKey: n, minPointSize: r, hasCustomShape: i }, pos: a, bandSize: o, xAxis: s, yAxis: c, xAxisTicks: l, yAxisTicks: u, stackedData: d, displayedData: f, offset: p, cells: m, parentViewBox: h, dataStartIndex: g } = e, _ = t === "horizontal" ? c : s, v = d ? _.scale.domain() : null, y = uV({ numericAxis: _ }), b = _.scale.map(y);
return f.map((e, f) => {
var _, x, S, C, w, T;
if (d) {
var E = d[f + g];
if (E == null) return null;
- _ = rV(E, v);
- } else _ = QB(e, n), Array.isArray(_) || (_ = [y, _]);
- var D = hFe(r, c2)(_[1], f);
+ _ = iV(E, v);
+ } else _ = $B(e, n), Array.isArray(_) || (_ = [y, _]);
+ var D = _Fe(r, s2)(_[1], f);
if (t === "horizontal") {
var O = c.scale.map(_[0]), k = c.scale.map(_[1]);
if (O == null || k == null) return null;
- x = cV({
+ x = lV({
axis: s,
ticks: l,
bandSize: o,
@@ -67174,19 +67226,19 @@ function ZFe(e) {
index: f
}), S = k ?? O ?? void 0, C = a.size;
var A = O - k;
- if (w = DL(A) ? 0 : A, T = {
+ if (w = OL(A) ? 0 : A, T = {
x,
y: p.top,
width: C,
height: p.height
}, Math.abs(D) > 0 && Math.abs(w) < Math.abs(D)) {
- var j = EL(w || D) * (Math.abs(D) - Math.abs(w));
+ var j = DL(w || D) * (Math.abs(D) - Math.abs(w));
S -= j, w += j;
}
} else {
var M = s.scale.map(_[0]), N = s.scale.map(_[1]);
if (M == null || N == null) return null;
- if (x = M, S = cV({
+ if (x = M, S = lV({
axis: c,
ticks: u,
bandSize: o,
@@ -67199,11 +67251,11 @@ function ZFe(e) {
width: p.width,
height: w
}, Math.abs(D) > 0 && Math.abs(C) < Math.abs(D)) {
- var P = EL(C || D) * (Math.abs(D) - Math.abs(C));
+ var P = DL(C || D) * (Math.abs(D) - Math.abs(C));
C += P;
}
}
- return x == null || S == null || C == null || w == null || !i && (C === 0 || w === 0) ? null : o2(o2({}, e), {}, {
+ return x == null || S == null || C == null || w == null || !i && (C === 0 || w === 0) ? null : a2(a2({}, e), {}, {
stackedBarStart: b,
x,
y: S,
@@ -67221,12 +67273,12 @@ function ZFe(e) {
}, m && m[f] && m[f].props);
}).filter(Boolean);
}
-function QFe(e) {
- var t = JL(e, YFe), n = DFe(t.stackId), r = VV();
- return /*#__PURE__*/ R.createElement(G$, {
+function eIe(e) {
+ var t = YL(e, ZFe), n = kFe(t.stackId), r = HV();
+ return /*#__PURE__*/ R.createElement(W$, {
id: t.id,
type: "bar"
- }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(U$, { legendPayload: RFe(t) }), /*#__PURE__*/ R.createElement(zFe, {
+ }, (e) => /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(H$, { legendPayload: BFe(t) }), /*#__PURE__*/ R.createElement(VFe, {
dataKey: t.dataKey,
stroke: t.stroke,
strokeWidth: t.strokeWidth,
@@ -67236,7 +67288,7 @@ function QFe(e) {
unit: t.unit,
tooltipType: t.tooltipType,
id: e
- }), /*#__PURE__*/ R.createElement(q$, {
+ }), /*#__PURE__*/ R.createElement(K$, {
type: "bar",
id: e,
data: void 0,
@@ -67251,23 +67303,23 @@ function QFe(e) {
maxBarSize: t.maxBarSize,
isPanorama: r,
hasCustomShape: t.shape != null
- }), /*#__PURE__*/ R.createElement(DZ, { zIndex: t.zIndex }, /*#__PURE__*/ R.createElement(XFe, i2({}, t, { id: e })))));
+ }), /*#__PURE__*/ R.createElement(DZ, { zIndex: t.zIndex }, /*#__PURE__*/ R.createElement(QFe, r2({}, t, { id: e })))));
}
-var l2 = /*#__PURE__*/ R.memo(QFe, OU);
-l2.displayName = "Bar";
+var c2 = /*#__PURE__*/ R.memo(eIe, OU);
+c2.displayName = "Bar";
//#endregion
//#region node_modules/recharts/es6/util/axisPropsAreEqual.js
-var $Fe = ["domain", "range"], eIe = ["domain", "range"];
-function u2(e, t) {
+var tIe = ["domain", "range"], nIe = ["domain", "range"];
+function l2(e, t) {
if (e == null) return {};
- var n, r, i = tIe(e, t);
+ var n, r, i = rIe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function tIe(e, t) {
+function rIe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -67276,31 +67328,31 @@ function tIe(e, t) {
}
return n;
}
-function d2(e, t) {
+function u2(e, t) {
return e === t ? !0 : Array.isArray(e) && e.length === 2 && Array.isArray(t) && t.length === 2 ? e[0] === t[0] && e[1] === t[1] : !1;
}
-function f2(e, t) {
+function d2(e, t) {
if (e === t) return !0;
- var { domain: n, range: r } = e, i = u2(e, $Fe), { domain: a, range: o } = t, s = u2(t, eIe);
- return !d2(n, a) || !d2(r, o) ? !1 : OU(i, s);
+ var { domain: n, range: r } = e, i = l2(e, tIe), { domain: a, range: o } = t, s = l2(t, nIe);
+ return !u2(n, a) || !u2(r, o) ? !1 : OU(i, s);
}
//#endregion
//#region node_modules/recharts/es6/cartesian/XAxis.js
-var nIe = ["type"], rIe = [
+var iIe = ["type"], aIe = [
"dangerouslySetInnerHTML",
"ticks",
"scale"
-], iIe = ["id", "scale"];
-function p2() {
- return p2 = Object.assign ? Object.assign.bind() : function(e) {
+], oIe = ["id", "scale"];
+function f2() {
+ return f2 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, p2.apply(null, arguments);
+ }, f2.apply(null, arguments);
}
-function m2(e, t) {
+function p2(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -67310,30 +67362,30 @@ function m2(e, t) {
}
return n;
}
-function h2(e) {
+function m2(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? m2(Object(n), !0).forEach(function(t) {
- aIe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : m2(Object(n)).forEach(function(t) {
+ t % 2 ? p2(Object(n), !0).forEach(function(t) {
+ sIe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : p2(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function aIe(e, t, n) {
- return (t = oIe(t)) in e ? Object.defineProperty(e, t, {
+function sIe(e, t, n) {
+ return (t = cIe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function oIe(e) {
- var t = sIe(e, "string");
+function cIe(e) {
+ var t = lIe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function sIe(e, t) {
+function lIe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -67343,16 +67395,16 @@ function sIe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function g2(e, t) {
+function h2(e, t) {
if (e == null) return {};
- var n, r, i = cIe(e, t);
+ var n, r, i = uIe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function cIe(e, t) {
+function uIe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -67361,24 +67413,24 @@ function cIe(e, t) {
}
return n;
}
-function lIe(e) {
- var t = xR(), n = (0, R.useRef)(null), r = CH(), { type: i } = e, a = g2(e, nIe), o = gG(r, "xAxis", i), s = (0, R.useMemo)(() => {
- if (o != null) return h2(h2({}, a), {}, { type: o });
+function dIe(e) {
+ var t = SR(), n = (0, R.useRef)(null), r = wH(), { type: i } = e, a = h2(e, iIe), o = gG(r, "xAxis", i), s = (0, R.useMemo)(() => {
+ if (o != null) return m2(m2({}, a), {}, { type: o });
}, [a, o]);
return (0, R.useLayoutEffect)(() => {
- s != null && (n.current === null ? t(Tje(s)) : n.current !== s && t(Eje({
+ s != null && (n.current === null ? t(Dje(s)) : n.current !== s && t(Oje({
prev: n.current,
next: s
})), n.current = s);
}, [s, t]), (0, R.useLayoutEffect)(() => () => {
- n.current &&= (t(Dje(n.current)), null);
+ n.current &&= (t(kje(n.current)), null);
}, [t]), null;
}
-var uIe = (e) => {
- var { xAxisId: t, className: n } = e, r = Q(zV), i = VV(), a = "xAxis", o = Q((e) => _X(e, a, t, i)), s = Q((e) => uX(e, t)), c = Q((e) => MEe(e, t)), l = Q((e) => iY(e, t));
+var fIe = (e) => {
+ var { xAxisId: t, className: n } = e, r = Q(BV), i = HV(), a = "xAxis", o = Q((e) => _X(e, a, t, i)), s = Q((e) => uX(e, t)), c = Q((e) => NEe(e, t)), l = Q((e) => iY(e, t));
if (s == null || c == null || l == null) return null;
- var { dangerouslySetInnerHTML: u, ticks: d, scale: f } = e, p = g2(e, rIe), { id: m, scale: h } = l, g = g2(l, iIe);
- return /*#__PURE__*/ R.createElement(f0, p2({}, p, g, {
+ var { dangerouslySetInnerHTML: u, ticks: d, scale: f } = e, p = h2(e, aIe), { id: m, scale: h } = l, g = h2(l, oIe);
+ return /*#__PURE__*/ R.createElement(d0, f2({}, p, g, {
x: c.x,
y: c.y,
width: s.width,
@@ -67389,12 +67441,12 @@ var uIe = (e) => {
axisType: a,
axisId: t
}));
-}, dIe = {
+}, pIe = {
allowDataOverflow: rY.allowDataOverflow,
allowDecimals: rY.allowDecimals,
allowDuplicatedCategory: rY.allowDuplicatedCategory,
angle: rY.angle,
- axisLine: d0.axisLine,
+ axisLine: u0.axisLine,
height: rY.height,
hide: !1,
includeHidden: rY.includeHidden,
@@ -67408,14 +67460,14 @@ var uIe = (e) => {
scale: rY.scale,
tick: rY.tick,
tickCount: rY.tickCount,
- tickLine: d0.tickLine,
- tickSize: d0.tickSize,
+ tickLine: u0.tickLine,
+ tickSize: u0.tickSize,
type: rY.type,
niceTicks: rY.niceTicks,
xAxisId: 0
-}, _2 = /*#__PURE__*/ R.memo((e) => {
- var t = JL(e, dIe);
- return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(lIe, {
+}, g2 = /*#__PURE__*/ R.memo((e) => {
+ var t = YL(e, pIe);
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(dIe, {
allowDataOverflow: t.allowDataOverflow,
allowDecimals: t.allowDecimals,
allowDuplicatedCategory: t.allowDuplicatedCategory,
@@ -67441,26 +67493,26 @@ var uIe = (e) => {
type: t.type,
unit: t.unit,
niceTicks: t.niceTicks
- }), /*#__PURE__*/ R.createElement(uIe, t));
-}, f2);
-_2.displayName = "XAxis";
+ }), /*#__PURE__*/ R.createElement(fIe, t));
+}, d2);
+g2.displayName = "XAxis";
//#endregion
//#region node_modules/recharts/es6/cartesian/YAxis.js
-var fIe = ["type"], pIe = [
+var mIe = ["type"], hIe = [
"dangerouslySetInnerHTML",
"ticks",
"scale"
-], mIe = ["id", "scale"];
-function v2() {
- return v2 = Object.assign ? Object.assign.bind() : function(e) {
+], gIe = ["id", "scale"];
+function _2() {
+ return _2 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, v2.apply(null, arguments);
+ }, _2.apply(null, arguments);
}
-function y2(e, t) {
+function v2(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -67470,30 +67522,30 @@ function y2(e, t) {
}
return n;
}
-function b2(e) {
+function y2(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? y2(Object(n), !0).forEach(function(t) {
- hIe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : y2(Object(n)).forEach(function(t) {
+ t % 2 ? v2(Object(n), !0).forEach(function(t) {
+ _Ie(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : v2(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function hIe(e, t, n) {
- return (t = gIe(t)) in e ? Object.defineProperty(e, t, {
+function _Ie(e, t, n) {
+ return (t = vIe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function gIe(e) {
- var t = _Ie(e, "string");
+function vIe(e) {
+ var t = yIe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function _Ie(e, t) {
+function yIe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -67503,16 +67555,16 @@ function _Ie(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function x2(e, t) {
+function b2(e, t) {
if (e == null) return {};
- var n, r, i = vIe(e, t);
+ var n, r, i = bIe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function vIe(e, t) {
+function bIe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -67521,27 +67573,27 @@ function vIe(e, t) {
}
return n;
}
-function yIe(e) {
- var t = xR(), n = (0, R.useRef)(null), r = CH(), { type: i } = e, a = x2(e, fIe), o = gG(r, "yAxis", i), s = (0, R.useMemo)(() => {
- if (o != null) return b2(b2({}, a), {}, { type: o });
+function xIe(e) {
+ var t = SR(), n = (0, R.useRef)(null), r = wH(), { type: i } = e, a = b2(e, mIe), o = gG(r, "yAxis", i), s = (0, R.useMemo)(() => {
+ if (o != null) return y2(y2({}, a), {}, { type: o });
}, [o, a]);
return (0, R.useLayoutEffect)(() => {
- s != null && (n.current === null ? t(Oje(s)) : n.current !== s && t(kje({
+ s != null && (n.current === null ? t(Aje(s)) : n.current !== s && t(jje({
prev: n.current,
next: s
})), n.current = s);
}, [s, t]), (0, R.useLayoutEffect)(() => () => {
- n.current &&= (t(Aje(n.current)), null);
+ n.current &&= (t(Mje(n.current)), null);
}, [t]), null;
}
-function bIe(e) {
- var { yAxisId: t, className: n, width: r, label: i } = e, a = (0, R.useRef)(null), o = (0, R.useRef)(null), s = Q(zV), c = VV(), l = xR(), u = "yAxis", d = Q((e) => dX(e, t)), f = Q((e) => NEe(e, t)), p = Q((e) => _X(e, u, t, c)), m = Q((e) => sY(e, t));
+function SIe(e) {
+ var { yAxisId: t, className: n, width: r, label: i } = e, a = (0, R.useRef)(null), o = (0, R.useRef)(null), s = Q(BV), c = HV(), l = SR(), u = "yAxis", d = Q((e) => dX(e, t)), f = Q((e) => PEe(e, t)), p = Q((e) => _X(e, u, t, c)), m = Q((e) => sY(e, t));
if ((0, R.useLayoutEffect)(() => {
- if (!(r !== "auto" || !d || OQ(i) || /*#__PURE__*/ (0, R.isValidElement)(i) || m == null)) {
+ if (!(r !== "auto" || !d || DQ(i) || /*#__PURE__*/ (0, R.isValidElement)(i) || m == null)) {
var e = a.current;
if (e) {
var n = e.getCalculatedWidth();
- Math.round(d.width) !== Math.round(n) && l(Pje({
+ Math.round(d.width) !== Math.round(n) && l(Ije({
id: t,
width: n
}));
@@ -67556,8 +67608,8 @@ function bIe(e) {
r,
m
]), d == null || f == null || m == null) return null;
- var { dangerouslySetInnerHTML: h, ticks: g, scale: _ } = e, v = x2(e, pIe), { id: y, scale: b } = m, x = x2(m, mIe);
- return /*#__PURE__*/ R.createElement(f0, v2({}, v, x, {
+ var { dangerouslySetInnerHTML: h, ticks: g, scale: _ } = e, v = b2(e, hIe), { id: y, scale: b } = m, x = b2(m, gIe);
+ return /*#__PURE__*/ R.createElement(d0, _2({}, v, x, {
ref: a,
labelRef: o,
x: f.x,
@@ -67572,12 +67624,12 @@ function bIe(e) {
axisId: t
}));
}
-var xIe = {
+var CIe = {
allowDataOverflow: oY.allowDataOverflow,
allowDecimals: oY.allowDecimals,
allowDuplicatedCategory: oY.allowDuplicatedCategory,
angle: oY.angle,
- axisLine: d0.axisLine,
+ axisLine: u0.axisLine,
hide: !1,
includeHidden: oY.includeHidden,
interval: oY.interval,
@@ -67590,15 +67642,15 @@ var xIe = {
scale: oY.scale,
tick: oY.tick,
tickCount: oY.tickCount,
- tickLine: d0.tickLine,
- tickSize: d0.tickSize,
+ tickLine: u0.tickLine,
+ tickSize: u0.tickSize,
type: oY.type,
niceTicks: oY.niceTicks,
width: oY.width,
yAxisId: 0
-}, S2 = /*#__PURE__*/ R.memo((e) => {
- var t = JL(e, xIe);
- return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(yIe, {
+}, x2 = /*#__PURE__*/ R.memo((e) => {
+ var t = YL(e, CIe);
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(xIe, {
interval: t.interval,
id: t.yAxisId,
scale: t.scale,
@@ -67624,27 +67676,27 @@ var xIe = {
tick: t.tick,
tickFormatter: t.tickFormatter,
niceTicks: t.niceTicks
- }), /*#__PURE__*/ R.createElement(bIe, t));
-}, f2);
-S2.displayName = "YAxis";
-var C2 = $([
+ }), /*#__PURE__*/ R.createElement(SIe, t));
+}, d2);
+x2.displayName = "YAxis";
+var S2 = $([
(e, t) => t,
- xH,
+ SH,
kG,
LG,
$X,
tZ,
- kDe,
- LV
-], IDe);
+ ADe,
+ RV
+], LDe);
//#endregion
//#region node_modules/recharts/es6/util/getRelativeCoordinate.js
-function SIe(e) {
+function wIe(e) {
return "getBBox" in e.currentTarget && typeof e.currentTarget.getBBox == "function";
}
-function w2(e) {
+function C2(e) {
var t = e.currentTarget.getBoundingClientRect(), n, r;
- if (SIe(e)) {
+ if (wIe(e)) {
var i = e.currentTarget.getBBox();
n = i.width > 0 ? t.width / i.width : 1, r = i.height > 0 ? t.height / i.height : 1;
} else {
@@ -67659,55 +67711,55 @@ function w2(e) {
}
//#endregion
//#region node_modules/recharts/es6/state/mouseEventsMiddleware.js
-var T2 = Zz("mouseClick"), E2 = IB();
-E2.startListening({
- actionCreator: T2,
+var w2 = Qz("mouseClick"), T2 = LB();
+T2.startListening({
+ actionCreator: w2,
effect: (e, t) => {
- var n = e.payload, r = C2(t.getState(), w2(n));
- r?.activeIndex != null && t.dispatch(UEe({
+ var n = e.payload, r = S2(t.getState(), C2(n));
+ r?.activeIndex != null && t.dispatch(WEe({
activeIndex: r.activeIndex,
activeDataKey: void 0,
activeCoordinate: r.activeCoordinate
}));
}
});
-var D2 = Zz("mouseMove"), O2 = IB(), k2 = null, A2 = null, j2 = null;
-O2.startListening({
- actionCreator: D2,
+var E2 = Qz("mouseMove"), D2 = LB(), O2 = null, k2 = null, A2 = null;
+D2.startListening({
+ actionCreator: E2,
effect: (e, t) => {
var n = e.payload, { throttleDelay: r, throttledEvents: i } = t.getState().eventSettings, a = i === "all" || i?.includes("mousemove");
- k2 !== null && (cancelAnimationFrame(k2), k2 = null), A2 !== null && (typeof r != "number" || !a) && (clearTimeout(A2), A2 = null), j2 = w2(n);
+ O2 !== null && (cancelAnimationFrame(O2), O2 = null), k2 !== null && (typeof r != "number" || !a) && (clearTimeout(k2), k2 = null), A2 = C2(n);
var o = () => {
var e = t.getState(), n = wX(e, e.tooltip.settings.shared);
- if (!j2) {
- k2 = null, A2 = null;
+ if (!A2) {
+ O2 = null, k2 = null;
return;
}
if (n === "axis") {
- var r = C2(e, j2);
+ var r = S2(e, A2);
r?.activeIndex == null ? t.dispatch(kX()) : t.dispatch(AX({
activeIndex: r.activeIndex,
activeDataKey: void 0,
activeCoordinate: r.activeCoordinate
}));
}
- k2 = null, A2 = null;
+ O2 = null, k2 = null;
};
if (!a) {
o();
return;
}
- r === "raf" ? k2 = requestAnimationFrame(o) : typeof r == "number" && A2 === null && (A2 = setTimeout(o, r));
+ r === "raf" ? O2 = requestAnimationFrame(o) : typeof r == "number" && k2 === null && (k2 = setTimeout(o, r));
}
});
//#endregion
//#region node_modules/recharts/es6/state/reduxDevtoolsJsonStringifyReplacer.js
-function CIe(e, t) {
+function TIe(e, t) {
return t instanceof HTMLElement ? `HTMLElement <${t.tagName} class="${t.className}">` : t === window ? "global.window" : e === "children" && typeof t == "object" && t ? "<<CHILDREN>>" : t;
}
//#endregion
//#region node_modules/recharts/es6/state/rootPropsSlice.js
-var M2 = {
+var j2 = {
accessibilityLayer: !0,
barCategoryGap: "10%",
barGap: 4,
@@ -67719,28 +67771,28 @@ var M2 = {
syncMethod: "index",
baseValue: void 0,
reverseStackOrder: !1
-}, N2 = oB({
+}, M2 = sB({
name: "rootProps",
- initialState: M2,
+ initialState: j2,
reducers: { updateOptions: (e, t) => {
- e.accessibilityLayer = t.payload.accessibilityLayer, e.barCategoryGap = t.payload.barCategoryGap, e.barGap = t.payload.barGap ?? M2.barGap, e.barSize = t.payload.barSize, e.maxBarSize = t.payload.maxBarSize, e.stackOffset = t.payload.stackOffset, e.syncId = t.payload.syncId, e.syncMethod = t.payload.syncMethod, e.className = t.payload.className, e.baseValue = t.payload.baseValue, e.reverseStackOrder = t.payload.reverseStackOrder;
+ e.accessibilityLayer = t.payload.accessibilityLayer, e.barCategoryGap = t.payload.barCategoryGap, e.barGap = t.payload.barGap ?? j2.barGap, e.barSize = t.payload.barSize, e.maxBarSize = t.payload.maxBarSize, e.stackOffset = t.payload.stackOffset, e.syncId = t.payload.syncId, e.syncMethod = t.payload.syncMethod, e.className = t.payload.className, e.baseValue = t.payload.baseValue, e.reverseStackOrder = t.payload.reverseStackOrder;
} }
-}), wIe = N2.reducer, { updateOptions: TIe } = N2.actions, P2 = oB({
+}), EIe = M2.reducer, { updateOptions: DIe } = M2.actions, N2 = sB({
name: "polarOptions",
initialState: null,
reducers: { updatePolarOptions: (e, t) => e === null ? t.payload : (e.startAngle = t.payload.startAngle, e.endAngle = t.payload.endAngle, e.cx = t.payload.cx, e.cy = t.payload.cy, e.innerRadius = t.payload.innerRadius, e.outerRadius = t.payload.outerRadius, e) }
-}), { updatePolarOptions: EIe } = P2.actions, DIe = P2.reducer, F2 = Zz("keyDown"), I2 = Zz("focus"), L2 = Zz("blur"), R2 = IB(), z2 = null, B2 = null, V2 = null;
-R2.startListening({
- actionCreator: F2,
+}), { updatePolarOptions: OIe } = N2.actions, kIe = N2.reducer, P2 = Qz("keyDown"), F2 = Qz("focus"), I2 = Qz("blur"), L2 = LB(), R2 = null, z2 = null, B2 = null;
+L2.startListening({
+ actionCreator: P2,
effect: (e, t) => {
- V2 = e.payload, z2 !== null && (cancelAnimationFrame(z2), z2 = null);
+ B2 = e.payload, R2 !== null && (cancelAnimationFrame(R2), R2 = null);
var { throttleDelay: n, throttledEvents: r } = t.getState().eventSettings, i = r === "all" || r.includes("keydown");
- B2 !== null && (typeof n != "number" || !i) && (clearTimeout(B2), B2 = null);
+ z2 !== null && (typeof n != "number" || !i) && (clearTimeout(z2), z2 = null);
var a = () => {
try {
var e = t.getState();
if (e.rootProps.accessibilityLayer === !1) return;
- var { keyboardInteraction: n } = e.tooltip, r = V2;
+ var { keyboardInteraction: n } = e.tooltip, r = B2;
if (r !== "ArrowRight" && r !== "ArrowLeft" && r !== "Enter") return;
var i = IX(n, qX(e), kY(e), ZX(e)), a = i == null ? -1 : Number(i);
if (!Number.isFinite(a) || a < 0) return;
@@ -67754,7 +67806,7 @@ R2.startListening({
}));
return;
}
- var c = PEe(e) === "left-to-right" ? 1 : -1, l = a + (r === "ArrowRight" ? 1 : -1) * c;
+ var c = FEe(e) === "left-to-right" ? 1 : -1, l = a + (r === "ArrowRight" ? 1 : -1) * c;
if (o == null || l >= o.length || l < 0) return;
var u = SZ(e, "axis", "hover", String(l));
t.dispatch(MX({
@@ -67763,19 +67815,19 @@ R2.startListening({
activeCoordinate: u
}));
} finally {
- z2 = null, B2 = null;
+ R2 = null, z2 = null;
}
};
if (!i) {
a();
return;
}
- n === "raf" ? z2 = requestAnimationFrame(a) : typeof n == "number" && B2 === null && (a(), V2 = null, B2 = setTimeout(() => {
- V2 ? a() : (B2 = null, z2 = null);
+ n === "raf" ? R2 = requestAnimationFrame(a) : typeof n == "number" && z2 === null && (a(), B2 = null, z2 = setTimeout(() => {
+ B2 ? a() : (z2 = null, R2 = null);
}, n));
}
-}), R2.startListening({
- actionCreator: I2,
+}), L2.startListening({
+ actionCreator: F2,
effect: (e, t) => {
var n = t.getState();
if (n.rootProps.accessibilityLayer !== !1) {
@@ -67790,8 +67842,8 @@ R2.startListening({
}
}
}
-}), R2.startListening({
- actionCreator: L2,
+}), L2.startListening({
+ actionCreator: I2,
effect: (e, t) => {
var n = t.getState();
if (n.rootProps.accessibilityLayer !== !1) {
@@ -67806,7 +67858,7 @@ R2.startListening({
});
//#endregion
//#region node_modules/recharts/es6/util/createEventProxy.js
-function H2(e) {
+function V2(e) {
e.persist();
var { currentTarget: t } = e;
return new Proxy(e, { get: (e, n) => {
@@ -67817,36 +67869,36 @@ function H2(e) {
}
//#endregion
//#region node_modules/recharts/es6/state/externalEventsMiddleware.js
-var U2 = Zz("externalEvent"), W2 = IB(), G2 = /* @__PURE__ */ new Map(), K2 = /* @__PURE__ */ new Map(), q2 = /* @__PURE__ */ new Map();
-W2.startListening({
- actionCreator: U2,
+var H2 = Qz("externalEvent"), U2 = LB(), W2 = /* @__PURE__ */ new Map(), G2 = /* @__PURE__ */ new Map(), K2 = /* @__PURE__ */ new Map();
+U2.startListening({
+ actionCreator: H2,
effect: (e, t) => {
var { handler: n, reactEvent: r } = e.payload;
if (n != null) {
- var i = r.type, a = H2(r);
- q2.set(i, {
+ var i = r.type, a = V2(r);
+ K2.set(i, {
handler: n,
reactEvent: a
});
- var o = G2.get(i);
- o !== void 0 && (cancelAnimationFrame(o), G2.delete(i));
- var { throttleDelay: s, throttledEvents: c } = t.getState().eventSettings, l = c, u = l === "all" || l?.includes(i), d = K2.get(i);
- d !== void 0 && (typeof s != "number" || !u) && (clearTimeout(d), K2.delete(i));
+ var o = W2.get(i);
+ o !== void 0 && (cancelAnimationFrame(o), W2.delete(i));
+ var { throttleDelay: s, throttledEvents: c } = t.getState().eventSettings, l = c, u = l === "all" || l?.includes(i), d = G2.get(i);
+ d !== void 0 && (typeof s != "number" || !u) && (clearTimeout(d), G2.delete(i));
var f = () => {
- var e = q2.get(i);
+ var e = K2.get(i);
try {
if (!e) return;
var { handler: n, reactEvent: r } = e, a = t.getState(), o = {
- activeCoordinate: hDe(a),
+ activeCoordinate: gDe(a),
activeDataKey: cZ(a),
activeIndex: oZ(a),
activeLabel: sZ(a),
activeTooltipIndex: oZ(a),
- isTooltipActive: gDe(a)
+ isTooltipActive: _De(a)
};
n && n(o, r);
} finally {
- G2.delete(i), K2.delete(i), q2.delete(i);
+ W2.delete(i), G2.delete(i), K2.delete(i);
}
};
if (!u) {
@@ -67855,18 +67907,18 @@ W2.startListening({
}
if (s === "raf") {
var p = requestAnimationFrame(f);
- G2.set(i, p);
+ W2.set(i, p);
} else if (typeof s == "number") {
- if (!K2.has(i)) {
+ if (!G2.has(i)) {
f();
var m = setTimeout(f, s);
- K2.set(i, m);
+ G2.set(i, m);
}
} else f();
}
}
});
-var OIe = $([
+var AIe = $([
$([BX], (e) => e.tooltipItemPayloads),
(e, t) => t,
(e, t, n) => n
@@ -67878,42 +67930,42 @@ var OIe = $([
if (i != null) return i(t);
}
}
-}), J2 = Zz("touchMove"), Y2 = IB(), X2 = null, Z2 = null, Q2 = null, $2 = null;
-Y2.startListening({
- actionCreator: J2,
+}), q2 = Qz("touchMove"), J2 = LB(), Y2 = null, X2 = null, Z2 = null, Q2 = null;
+J2.startListening({
+ actionCreator: q2,
effect: (e, t) => {
var n = e.payload;
if (n.touches != null && n.touches.length !== 0) {
- $2 = H2(n);
+ Q2 = V2(n);
var { throttleDelay: r, throttledEvents: i } = t.getState().eventSettings, a = i === "all" || i.includes("touchmove");
- X2 !== null && (cancelAnimationFrame(X2), X2 = null), Z2 !== null && (typeof r != "number" || !a) && (clearTimeout(Z2), Z2 = null), Q2 = Array.from(n.touches).map((e) => w2({
+ Y2 !== null && (cancelAnimationFrame(Y2), Y2 = null), X2 !== null && (typeof r != "number" || !a) && (clearTimeout(X2), X2 = null), Z2 = Array.from(n.touches).map((e) => C2({
clientX: e.clientX,
clientY: e.clientY,
currentTarget: n.currentTarget
}));
var o = () => {
- if ($2 != null) {
+ if (Q2 != null) {
var e = t.getState(), n = wX(e, e.tooltip.settings.shared);
if (n === "axis") {
- var r = Q2?.[0];
+ var r = Z2?.[0];
if (r == null) {
- X2 = null, Z2 = null;
+ Y2 = null, X2 = null;
return;
}
- var i = C2(e, r);
+ var i = S2(e, r);
i?.activeIndex != null && t.dispatch(AX({
activeIndex: i.activeIndex,
activeDataKey: void 0,
activeCoordinate: i.activeCoordinate
}));
} else if (n === "item") {
- var a = $2.touches[0];
+ var a = Q2.touches[0];
if (document.elementFromPoint == null || a == null) return;
var o = document.elementFromPoint(a.clientX, a.clientY);
if (!o || !o.getAttribute) return;
- var s = o.getAttribute(EV), c = o.getAttribute("data-recharts-item-id") ?? void 0, l = KX(e).find((e) => e.id === c);
+ var s = o.getAttribute(DV), c = o.getAttribute("data-recharts-item-id") ?? void 0, l = KX(e).find((e) => e.id === c);
if (s == null || l == null || c == null) return;
- var { dataKey: u } = l, d = OIe(e, s, c);
+ var { dataKey: u } = l, d = AIe(e, s, c);
t.dispatch(OX({
activeDataKey: u,
activeIndex: s,
@@ -67921,22 +67973,22 @@ Y2.startListening({
activeGraphicalItemId: c
}));
}
- X2 = null, Z2 = null;
+ Y2 = null, X2 = null;
}
};
if (!a) {
o();
return;
}
- r === "raf" ? X2 = requestAnimationFrame(o) : typeof r == "number" && Z2 === null && (o(), $2 = null, Z2 = setTimeout(() => {
- $2 ? o() : (Z2 = null, X2 = null);
+ r === "raf" ? Y2 = requestAnimationFrame(o) : typeof r == "number" && X2 === null && (o(), Q2 = null, X2 = setTimeout(() => {
+ Q2 ? o() : (X2 = null, Y2 = null);
}, r));
}
}
});
//#endregion
//#region node_modules/recharts/es6/state/eventSettingsSlice.js
-var e4 = {
+var $2 = {
throttleDelay: "raf",
throttledEvents: [
"mousemove",
@@ -67945,33 +67997,33 @@ var e4 = {
"scroll",
"wheel"
]
-}, t4 = oB({
+}, e4 = sB({
name: "eventSettings",
- initialState: e4,
+ initialState: $2,
reducers: { setEventSettings: (e, t) => {
t.payload.throttleDelay != null && (e.throttleDelay = t.payload.throttleDelay), t.payload.throttledEvents != null && (e.throttledEvents = bU(t.payload.throttledEvents));
} }
-}), { setEventSettings: kIe } = t4.actions, AIe = t4.reducer, jIe = zR({
- brush: JMe,
- cartesianAxis: Fje,
- chartData: lOe,
- errorBars: pPe,
- eventSettings: AIe,
- graphicalItems: dje,
- layout: UB,
- legend: qbe,
- options: iOe,
- polarAxis: tAe,
- polarOptions: DIe,
- referenceElements: aNe,
- renderedTicks: NNe,
- rootProps: wIe,
- tooltip: WEe,
- zIndex: YDe
-}), MIe = function(e) {
+}), { setEventSettings: jIe } = e4.actions, MIe = e4.reducer, NIe = BR({
+ brush: XMe,
+ cartesianAxis: Lje,
+ chartData: uOe,
+ errorBars: hPe,
+ eventSettings: MIe,
+ graphicalItems: pje,
+ layout: WB,
+ legend: Jbe,
+ options: aOe,
+ polarAxis: rAe,
+ polarOptions: kIe,
+ referenceElements: sNe,
+ renderedTicks: FNe,
+ rootProps: EIe,
+ tooltip: GEe,
+ zIndex: XDe
+}), PIe = function(e) {
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "Chart";
return wbe({
- reducer: jIe,
+ reducer: NIe,
preloadedState: e,
middleware: (e) => e({
serializableCheck: !1,
@@ -67981,40 +68033,40 @@ var e4 = {
"production"
].includes("es6")
}).concat([
- E2.middleware,
- O2.middleware,
- R2.middleware,
- W2.middleware,
- Y2.middleware
+ T2.middleware,
+ D2.middleware,
+ L2.middleware,
+ U2.middleware,
+ J2.middleware
]),
enhancers: (e) => {
var t = e;
- return typeof e == "function" && (t = e()), t.concat(iB({ type: "raf" }));
+ return typeof e == "function" && (t = e()), t.concat(aB({ type: "raf" }));
},
devTools: zU.devToolsEnabled && {
- serialize: { replacer: CIe },
+ serialize: { replacer: TIe },
name: `recharts-${t}`
}
});
};
//#endregion
//#region node_modules/recharts/es6/state/RechartsStoreProvider.js
-function n4(e) {
- var { preloadedState: t, children: n, reduxStoreName: r } = e, i = VV(), a = (0, R.useRef)(null);
+function t4(e) {
+ var { preloadedState: t, children: n, reduxStoreName: r } = e, i = HV(), a = (0, R.useRef)(null);
if (i) return n;
- a.current ??= MIe(t, r);
- var o = bR;
- return /*#__PURE__*/ R.createElement(sxe, {
+ a.current ??= PIe(t, r);
+ var o = xR;
+ return /*#__PURE__*/ R.createElement(cxe, {
context: o,
store: a.current
}, n);
}
//#endregion
//#region node_modules/recharts/es6/state/ReportMainChartProps.js
-function NIe(e) {
- var { layout: t, margin: n } = e, r = xR(), i = VV();
+function FIe(e) {
+ var { layout: t, margin: n } = e, r = SR(), i = HV();
return (0, R.useEffect)(() => {
- i || (r(BB(t)), r(zB(n)));
+ i || (r(VB(t)), r(BB(n)));
}, [
r,
i,
@@ -68022,31 +68074,31 @@ function NIe(e) {
n
]), null;
}
-var r4 = /*#__PURE__*/ (0, R.memo)(NIe, OU);
+var n4 = /*#__PURE__*/ (0, R.memo)(FIe, OU);
//#endregion
//#region node_modules/recharts/es6/state/ReportChartProps.js
-function i4(e) {
- var t = xR();
+function r4(e) {
+ var t = SR();
return (0, R.useEffect)(() => {
- t(TIe(e));
+ t(DIe(e));
}, [t, e]), null;
}
-var a4 = /*#__PURE__*/ (0, R.memo)((e) => {
- var t = xR();
+var i4 = /*#__PURE__*/ (0, R.memo)((e) => {
+ var t = SR();
return (0, R.useEffect)(() => {
- t(kIe(e));
+ t(jIe(e));
}, [t, e]), null;
}, OU);
//#endregion
//#region node_modules/recharts/es6/zIndex/ZIndexPortal.js
-function o4(e) {
- var { zIndex: t, isPanorama: n } = e, r = (0, R.useRef)(null), i = xR();
- return (0, R.useLayoutEffect)(() => (r.current && i(qDe({
+function a4(e) {
+ var { zIndex: t, isPanorama: n } = e, r = (0, R.useRef)(null), i = SR();
+ return (0, R.useLayoutEffect)(() => (r.current && i(JDe({
zIndex: t,
element: r.current,
isPanorama: n
})), () => {
- i(JDe({
+ i(YDe({
zIndex: t,
isPanorama: n
}));
@@ -68060,15 +68112,15 @@ function o4(e) {
className: `recharts-zIndex-layer_${t}`
});
}
-function s4(e) {
- var { children: t, isPanorama: n } = e, r = Q(RDe);
+function o4(e) {
+ var { children: t, isPanorama: n } = e, r = Q(zDe);
if (!r || r.length === 0) return t;
var i = r.filter((e) => e < 0), a = r.filter((e) => e > 0);
- return /*#__PURE__*/ R.createElement(R.Fragment, null, i.map((e) => /*#__PURE__*/ R.createElement(o4, {
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, i.map((e) => /*#__PURE__*/ R.createElement(a4, {
key: e,
zIndex: e,
isPanorama: n
- })), t, a.map((e) => /*#__PURE__*/ R.createElement(o4, {
+ })), t, a.map((e) => /*#__PURE__*/ R.createElement(a4, {
key: e,
zIndex: e,
isPanorama: n
@@ -68076,17 +68128,17 @@ function s4(e) {
}
//#endregion
//#region node_modules/recharts/es6/container/RootSurface.js
-var PIe = ["children"];
-function FIe(e, t) {
+var IIe = ["children"];
+function LIe(e, t) {
if (e == null) return {};
- var n, r, i = IIe(e, t);
+ var n, r, i = RIe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function IIe(e, t) {
+function RIe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -68095,55 +68147,55 @@ function IIe(e, t) {
}
return n;
}
-function c4() {
- return c4 = Object.assign ? Object.assign.bind() : function(e) {
+function s4() {
+ return s4 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, c4.apply(null, arguments);
+ }, s4.apply(null, arguments);
}
-var LIe = {
+var zIe = {
width: "100%",
height: "100%",
display: "block"
-}, RIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var n = vH(), r = yH(), i = UU();
- if (!KB(n) || !KB(r)) return null;
+}, BIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var n = yH(), r = bH(), i = UU();
+ if (!qB(n) || !qB(r)) return null;
var { children: a, otherAttributes: o, title: s, desc: c } = e, l, u;
- return o != null && (l = typeof o.tabIndex == "number" ? o.tabIndex : i ? 0 : void 0, u = typeof o.role == "string" ? o.role : i ? "application" : void 0), /*#__PURE__*/ R.createElement(SI, c4({}, o, {
+ return o != null && (l = typeof o.tabIndex == "number" ? o.tabIndex : i ? 0 : void 0, u = typeof o.role == "string" ? o.role : i ? "application" : void 0), /*#__PURE__*/ R.createElement(CI, s4({}, o, {
title: s,
desc: c,
role: u,
tabIndex: l,
width: n,
height: r,
- style: LIe,
+ style: zIe,
ref: t
}), a);
-}), zIe = (e) => {
- var { children: t } = e, n = Q(UV);
+}), VIe = (e) => {
+ var { children: t } = e, n = Q(WV);
if (!n) return null;
var { width: r, height: i, y: a, x: o } = n;
- return /*#__PURE__*/ R.createElement(SI, {
+ return /*#__PURE__*/ R.createElement(CI, {
width: r,
height: i,
x: o,
y: a
}, t);
-}, l4 = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var { children: n } = e, r = FIe(e, PIe);
- return VV() ? /*#__PURE__*/ R.createElement(zIe, null, /*#__PURE__*/ R.createElement(s4, { isPanorama: !0 }, n)) : /*#__PURE__*/ R.createElement(RIe, c4({ ref: t }, r), /*#__PURE__*/ R.createElement(s4, { isPanorama: !1 }, n));
+}, c4 = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var { children: n } = e, r = LIe(e, IIe);
+ return HV() ? /*#__PURE__*/ R.createElement(VIe, null, /*#__PURE__*/ R.createElement(o4, { isPanorama: !0 }, n)) : /*#__PURE__*/ R.createElement(BIe, s4({ ref: t }, r), /*#__PURE__*/ R.createElement(o4, { isPanorama: !1 }, n));
});
//#endregion
//#region node_modules/recharts/es6/util/useReportScale.js
-function BIe() {
- var e = xR(), [t, n] = (0, R.useState)(null), r = Q(SV);
+function HIe() {
+ var e = SR(), [t, n] = (0, R.useState)(null), r = Q(CV);
return (0, R.useEffect)(() => {
if (t != null) {
var n = t.getBoundingClientRect().width / t.offsetWidth;
- GB(n) && n !== r && e(HB(n));
+ KB(n) && n !== r && e(UB(n));
}
}, [
t,
@@ -68153,7 +68205,7 @@ function BIe() {
}
//#endregion
//#region node_modules/recharts/es6/chart/RechartsWrapper.js
-function u4(e, t) {
+function l4(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -68163,30 +68215,30 @@ function u4(e, t) {
}
return n;
}
-function VIe(e) {
+function UIe(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? u4(Object(n), !0).forEach(function(t) {
- HIe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : u4(Object(n)).forEach(function(t) {
+ t % 2 ? l4(Object(n), !0).forEach(function(t) {
+ WIe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : l4(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function HIe(e, t, n) {
- return (t = UIe(t)) in e ? Object.defineProperty(e, t, {
+function WIe(e, t, n) {
+ return (t = GIe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function UIe(e) {
- var t = WIe(e, "string");
+function GIe(e) {
+ var t = KIe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function WIe(e, t) {
+function KIe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -68196,17 +68248,17 @@ function WIe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-function d4() {
- return d4 = Object.assign ? Object.assign.bind() : function(e) {
+function u4() {
+ return u4 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, d4.apply(null, arguments);
+ }, u4.apply(null, arguments);
}
-var GIe = () => (vOe(), null);
-function f4(e) {
+var qIe = () => (yOe(), null);
+function d4(e) {
if (typeof e == "number") return e;
if (typeof e == "string") {
var t = parseFloat(e);
@@ -68214,10 +68266,10 @@ function f4(e) {
}
return 0;
}
-var KIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+var JIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
var n = (0, R.useRef)(null), [r, i] = (0, R.useState)({
- containerWidth: f4(e.style?.width),
- containerHeight: f4(e.style?.height)
+ containerWidth: d4(e.style?.width),
+ containerHeight: d4(e.style?.height)
}), a = (0, R.useCallback)((e, t) => {
i((n) => {
var r = Math.round(e), i = Math.round(t);
@@ -68242,14 +68294,14 @@ var KIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
}, [t, a]);
return (0, R.useEffect)(() => () => {
n.current?.disconnect();
- }, [a]), /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(DH, {
+ }, [a]), /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(OH, {
width: r.containerWidth,
height: r.containerHeight
- }), /*#__PURE__*/ R.createElement("div", d4({ ref: o }, e)));
-}), qIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ }), /*#__PURE__*/ R.createElement("div", u4({ ref: o }, e)));
+}), YIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
var { width: n, height: r } = e, [i, a] = (0, R.useState)({
- containerWidth: f4(n),
- containerHeight: f4(r)
+ containerWidth: d4(n),
+ containerHeight: d4(r)
}), o = (0, R.useCallback)((e, t) => {
a((n) => {
var r = Math.round(e), i = Math.round(t);
@@ -68264,32 +68316,32 @@ var KIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
o(n, r);
}
}, [t, o]);
- return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(DH, {
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(OH, {
width: i.containerWidth,
height: i.containerHeight
- }), /*#__PURE__*/ R.createElement("div", d4({ ref: s }, e)));
-}), JIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ }), /*#__PURE__*/ R.createElement("div", u4({ ref: s }, e)));
+}), XIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
var { width: n, height: r } = e;
- return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(DH, {
+ return /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(OH, {
width: n,
height: r
- }), /*#__PURE__*/ R.createElement("div", d4({ ref: t }, e)));
-}), YIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ }), /*#__PURE__*/ R.createElement("div", u4({ ref: t }, e)));
+}), ZIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
var { width: n, height: r } = e;
- return typeof n == "string" || typeof r == "string" ? /*#__PURE__*/ R.createElement(qIe, d4({}, e, { ref: t })) : typeof n == "number" && typeof r == "number" ? /*#__PURE__*/ R.createElement(JIe, d4({}, e, {
+ return typeof n == "string" || typeof r == "string" ? /*#__PURE__*/ R.createElement(YIe, u4({}, e, { ref: t })) : typeof n == "number" && typeof r == "number" ? /*#__PURE__*/ R.createElement(XIe, u4({}, e, {
width: n,
height: r,
ref: t
- })) : /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(DH, {
+ })) : /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(OH, {
width: n,
height: r
- }), /*#__PURE__*/ R.createElement("div", d4({ ref: t }, e)));
+ }), /*#__PURE__*/ R.createElement("div", u4({ ref: t }, e)));
});
-function XIe(e) {
- return e ? KIe : YIe;
+function QIe(e) {
+ return e ? JIe : ZIe;
}
-var ZIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var { children: n, className: r, height: i, onClick: a, onContextMenu: o, onDoubleClick: s, onMouseDown: c, onMouseEnter: l, onMouseLeave: u, onMouseMove: d, onMouseUp: f, onTouchEnd: p, onTouchMove: m, onTouchStart: h, style: g, width: _, responsive: v, dispatchTouchEvents: y = !0 } = e, b = (0, R.useRef)(null), x = xR(), [S, C] = (0, R.useState)(null), [w, T] = (0, R.useState)(null), E = BIe(), D = dH(), O = D?.width > 0 ? D.width : _, k = D?.height > 0 ? D.height : i, A = (0, R.useCallback)((e) => {
+var $Ie = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var { children: n, className: r, height: i, onClick: a, onContextMenu: o, onDoubleClick: s, onMouseDown: c, onMouseEnter: l, onMouseLeave: u, onMouseMove: d, onMouseUp: f, onTouchEnd: p, onTouchMove: m, onTouchStart: h, style: g, width: _, responsive: v, dispatchTouchEvents: y = !0 } = e, b = (0, R.useRef)(null), x = SR(), [S, C] = (0, R.useState)(null), [w, T] = (0, R.useState)(null), E = HIe(), D = fH(), O = D?.width > 0 ? D.width : _, k = D?.height > 0 ? D.height : i, A = (0, R.useCallback)((e) => {
E(e), typeof t == "function" && t(e), C(e), T(e), e != null && (b.current = e);
}, [
E,
@@ -68297,58 +68349,58 @@ var ZIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
C,
T
]), j = (0, R.useCallback)((e) => {
- x(T2(e)), x(U2({
+ x(w2(e)), x(H2({
handler: a,
reactEvent: e
}));
}, [x, a]), M = (0, R.useCallback)((e) => {
- x(D2(e)), x(U2({
+ x(E2(e)), x(H2({
handler: l,
reactEvent: e
}));
}, [x, l]), N = (0, R.useCallback)((e) => {
- x(kX()), x(U2({
+ x(kX()), x(H2({
handler: u,
reactEvent: e
}));
}, [x, u]), P = (0, R.useCallback)((e) => {
- x(D2(e)), x(U2({
+ x(E2(e)), x(H2({
handler: d,
reactEvent: e
}));
}, [x, d]), ee = (0, R.useCallback)(() => {
- x(I2());
+ x(F2());
}, [x]), F = (0, R.useCallback)(() => {
- x(L2());
+ x(I2());
}, [x]), I = (0, R.useCallback)((e) => {
- x(F2(e.key));
+ x(P2(e.key));
}, [x]), te = (0, R.useCallback)((e) => {
- x(U2({
+ x(H2({
handler: o,
reactEvent: e
}));
}, [x, o]), ne = (0, R.useCallback)((e) => {
- x(U2({
+ x(H2({
handler: s,
reactEvent: e
}));
}, [x, s]), re = (0, R.useCallback)((e) => {
- x(U2({
+ x(H2({
handler: c,
reactEvent: e
}));
}, [x, c]), ie = (0, R.useCallback)((e) => {
- x(U2({
+ x(H2({
handler: f,
reactEvent: e
}));
}, [x, f]), ae = (0, R.useCallback)((e) => {
- x(U2({
+ x(H2({
handler: h,
reactEvent: e
}));
}, [x, h]), oe = (0, R.useCallback)((e) => {
- y && x(J2(e)), x(U2({
+ y && x(q2(e)), x(H2({
handler: m,
reactEvent: e
}));
@@ -68357,16 +68409,16 @@ var ZIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
y,
m
]), se = (0, R.useCallback)((e) => {
- x(U2({
+ x(H2({
handler: p,
reactEvent: e
}));
- }, [x, p]), ce = XIe(v);
- return /*#__PURE__*/ R.createElement(jZ.Provider, { value: S }, /*#__PURE__*/ R.createElement(TI.Provider, { value: w }, /*#__PURE__*/ R.createElement(ce, {
+ }, [x, p]), ce = QIe(v);
+ return /*#__PURE__*/ R.createElement(jZ.Provider, { value: S }, /*#__PURE__*/ R.createElement(EI.Provider, { value: w }, /*#__PURE__*/ R.createElement(ce, {
width: O ?? g?.width,
height: k ?? g?.height,
className: ja("recharts-wrapper", r),
- style: VIe({
+ style: UIe({
position: "relative",
cursor: "default",
width: O,
@@ -68387,8 +68439,8 @@ var ZIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
onTouchMove: oe,
onTouchStart: ae,
ref: A
- }, /*#__PURE__*/ R.createElement(GIe, null), n)));
-}), QIe = [
+ }, /*#__PURE__*/ R.createElement(qIe, null), n)));
+}), eLe = [
"width",
"height",
"responsive",
@@ -68399,16 +68451,16 @@ var ZIe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
"title",
"desc"
];
-function $Ie(e, t) {
+function tLe(e, t) {
if (e == null) return {};
- var n, r, i = eLe(e, t);
+ var n, r, i = nLe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function eLe(e, t) {
+function nLe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -68417,16 +68469,16 @@ function eLe(e, t) {
}
return n;
}
-var p4 = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var { width: n, height: r, responsive: i, children: a, className: o, style: s, compact: c, title: l, desc: u } = e, d = vI($Ie(e, QIe));
- return c ? /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(DH, {
+var f4 = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var { width: n, height: r, responsive: i, children: a, className: o, style: s, compact: c, title: l, desc: u } = e, d = yI(tLe(e, eLe));
+ return c ? /*#__PURE__*/ R.createElement(R.Fragment, null, /*#__PURE__*/ R.createElement(OH, {
width: n,
height: r
- }), /*#__PURE__*/ R.createElement(l4, {
+ }), /*#__PURE__*/ R.createElement(c4, {
otherAttributes: d,
title: l,
desc: u
- }, a)) : /*#__PURE__*/ R.createElement(ZIe, {
+ }, a)) : /*#__PURE__*/ R.createElement($Ie, {
className: o,
style: s,
width: n,
@@ -68443,25 +68495,25 @@ var p4 = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
onTouchStart: e.onTouchStart,
onTouchMove: e.onTouchMove,
onTouchEnd: e.onTouchEnd
- }, /*#__PURE__*/ R.createElement(l4, {
+ }, /*#__PURE__*/ R.createElement(c4, {
otherAttributes: d,
title: l,
desc: u,
ref: t
- }, /*#__PURE__*/ R.createElement(oNe, null, a)));
+ }, /*#__PURE__*/ R.createElement(cNe, null, a)));
});
//#endregion
//#region node_modules/recharts/es6/chart/CartesianChart.js
-function m4() {
- return m4 = Object.assign ? Object.assign.bind() : function(e) {
+function p4() {
+ return p4 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, m4.apply(null, arguments);
+ }, p4.apply(null, arguments);
}
-function h4(e, t) {
+function m4(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -68471,30 +68523,30 @@ function h4(e, t) {
}
return n;
}
-function tLe(e) {
+function rLe(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? h4(Object(n), !0).forEach(function(t) {
- nLe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : h4(Object(n)).forEach(function(t) {
+ t % 2 ? m4(Object(n), !0).forEach(function(t) {
+ iLe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : m4(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function nLe(e, t, n) {
- return (t = rLe(t)) in e ? Object.defineProperty(e, t, {
+function iLe(e, t, n) {
+ return (t = aLe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function rLe(e) {
- var t = iLe(e, "string");
+function aLe(e) {
+ var t = oLe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function iLe(e, t) {
+function oLe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -68504,7 +68556,7 @@ function iLe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var aLe = tLe({
+var sLe = rLe({
accessibilityLayer: !0,
barCategoryGap: "10%",
barGap: 4,
@@ -68519,24 +68571,24 @@ var aLe = tLe({
reverseStackOrder: !1,
stackOffset: "none",
syncMethod: "index"
-}, e4), g4 = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- var n = JL(e.categoricalChartProps, aLe), { chartName: r, defaultTooltipEventType: i, validateTooltipEventTypes: a, tooltipPayloadSearcher: o, categoricalChartProps: s } = e, c = {
+}, $2), h4 = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ var n = YL(e.categoricalChartProps, sLe), { chartName: r, defaultTooltipEventType: i, validateTooltipEventTypes: a, tooltipPayloadSearcher: o, categoricalChartProps: s } = e, c = {
chartName: r,
defaultTooltipEventType: i,
validateTooltipEventTypes: a,
tooltipPayloadSearcher: o,
eventEmitter: void 0
};
- return /*#__PURE__*/ R.createElement(n4, {
+ return /*#__PURE__*/ R.createElement(t4, {
preloadedState: { options: c },
reduxStoreName: s.id ?? r
- }, /*#__PURE__*/ R.createElement(q1, { chartData: s.data }), /*#__PURE__*/ R.createElement(r4, {
+ }, /*#__PURE__*/ R.createElement(K1, { chartData: s.data }), /*#__PURE__*/ R.createElement(n4, {
layout: n.layout,
margin: n.margin
- }), /*#__PURE__*/ R.createElement(a4, {
+ }), /*#__PURE__*/ R.createElement(i4, {
throttleDelay: n.throttleDelay,
throttledEvents: n.throttledEvents
- }), /*#__PURE__*/ R.createElement(i4, {
+ }), /*#__PURE__*/ R.createElement(r4, {
baseValue: n.baseValue,
accessibilityLayer: n.accessibilityLayer,
barCategoryGap: n.barCategoryGap,
@@ -68548,52 +68600,52 @@ var aLe = tLe({
syncMethod: n.syncMethod,
className: n.className,
reverseStackOrder: n.reverseStackOrder
- }), /*#__PURE__*/ R.createElement(p4, m4({}, n, { ref: t })));
-}), oLe = ["axis"], sLe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => /*#__PURE__*/ R.createElement(g4, {
+ }), /*#__PURE__*/ R.createElement(f4, p4({}, n, { ref: t })));
+}), cLe = ["axis"], lLe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => /*#__PURE__*/ R.createElement(h4, {
chartName: "LineChart",
defaultTooltipEventType: "axis",
- validateTooltipEventTypes: oLe,
+ validateTooltipEventTypes: cLe,
tooltipPayloadSearcher: FZ,
categoricalChartProps: e,
ref: t
-})), cLe = ["axis", "item"], _4 = /*#__PURE__*/ (0, R.forwardRef)((e, t) => /*#__PURE__*/ R.createElement(g4, {
+})), uLe = ["axis", "item"], g4 = /*#__PURE__*/ (0, R.forwardRef)((e, t) => /*#__PURE__*/ R.createElement(h4, {
chartName: "BarChart",
defaultTooltipEventType: "axis",
- validateTooltipEventTypes: cLe,
+ validateTooltipEventTypes: uLe,
tooltipPayloadSearcher: FZ,
categoricalChartProps: e,
ref: t
}));
//#endregion
//#region node_modules/recharts/es6/state/ReportPolarOptions.js
-function lLe(e) {
- var t = xR();
+function dLe(e) {
+ var t = SR();
return (0, R.useEffect)(() => {
- t(EIe(e));
+ t(OIe(e));
}, [t, e]), null;
}
//#endregion
//#region node_modules/recharts/es6/chart/PolarChart.js
-var uLe = ["layout"];
-function v4() {
- return v4 = Object.assign ? Object.assign.bind() : function(e) {
+var fLe = ["layout"];
+function _4() {
+ return _4 = Object.assign ? Object.assign.bind() : function(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t];
for (var r in n) ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
}
return e;
- }, v4.apply(null, arguments);
+ }, _4.apply(null, arguments);
}
-function dLe(e, t) {
+function pLe(e, t) {
if (e == null) return {};
- var n, r, i = fLe(e, t);
+ var n, r, i = mLe(e, t);
if (Object.getOwnPropertySymbols) {
var a = Object.getOwnPropertySymbols(e);
for (r = 0; r < a.length; r++) n = a[r], t.indexOf(n) === -1 && {}.propertyIsEnumerable.call(e, n) && (i[n] = e[n]);
}
return i;
}
-function fLe(e, t) {
+function mLe(e, t) {
if (e == null) return {};
var n = {};
for (var r in e) if ({}.hasOwnProperty.call(e, r)) {
@@ -68602,7 +68654,7 @@ function fLe(e, t) {
}
return n;
}
-function y4(e, t) {
+function v4(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -68612,30 +68664,30 @@ function y4(e, t) {
}
return n;
}
-function pLe(e) {
+function hLe(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? y4(Object(n), !0).forEach(function(t) {
- mLe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : y4(Object(n)).forEach(function(t) {
+ t % 2 ? v4(Object(n), !0).forEach(function(t) {
+ gLe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : v4(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function mLe(e, t, n) {
- return (t = hLe(t)) in e ? Object.defineProperty(e, t, {
+function gLe(e, t, n) {
+ return (t = _Le(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function hLe(e) {
- var t = gLe(e, "string");
+function _Le(e) {
+ var t = vLe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function gLe(e, t) {
+function vLe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -68645,7 +68697,7 @@ function gLe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var b4 = pLe({
+var y4 = hLe({
accessibilityLayer: !0,
stackOffset: "none",
barCategoryGap: "10%",
@@ -68664,24 +68716,24 @@ var b4 = pLe({
cy: "50%",
innerRadius: 0,
outerRadius: "80%"
-}, e4), x4 = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
- var n = JL(e.categoricalChartProps, b4), { layout: r } = n, i = dLe(n, uLe), { chartName: a, defaultTooltipEventType: o, validateTooltipEventTypes: s, tooltipPayloadSearcher: c } = e, l = {
+}, $2), b4 = /*#__PURE__*/ (0, R.forwardRef)(function(e, t) {
+ var n = YL(e.categoricalChartProps, y4), { layout: r } = n, i = pLe(n, fLe), { chartName: a, defaultTooltipEventType: o, validateTooltipEventTypes: s, tooltipPayloadSearcher: c } = e, l = {
chartName: a,
defaultTooltipEventType: o,
validateTooltipEventTypes: s,
tooltipPayloadSearcher: c,
eventEmitter: void 0
};
- return /*#__PURE__*/ R.createElement(n4, {
+ return /*#__PURE__*/ R.createElement(t4, {
preloadedState: { options: l },
reduxStoreName: n.id ?? a
- }, /*#__PURE__*/ R.createElement(q1, { chartData: n.data }), /*#__PURE__*/ R.createElement(r4, {
+ }, /*#__PURE__*/ R.createElement(K1, { chartData: n.data }), /*#__PURE__*/ R.createElement(n4, {
layout: r,
margin: n.margin
- }), /*#__PURE__*/ R.createElement(a4, {
+ }), /*#__PURE__*/ R.createElement(i4, {
throttleDelay: n.throttleDelay,
throttledEvents: n.throttledEvents
- }), /*#__PURE__*/ R.createElement(i4, {
+ }), /*#__PURE__*/ R.createElement(r4, {
baseValue: void 0,
accessibilityLayer: n.accessibilityLayer,
barCategoryGap: n.barCategoryGap,
@@ -68693,18 +68745,18 @@ var b4 = pLe({
syncMethod: n.syncMethod,
className: n.className,
reverseStackOrder: n.reverseStackOrder
- }), /*#__PURE__*/ R.createElement(lLe, {
+ }), /*#__PURE__*/ R.createElement(dLe, {
cx: n.cx,
cy: n.cy,
startAngle: n.startAngle,
endAngle: n.endAngle,
innerRadius: n.innerRadius,
outerRadius: n.outerRadius
- }), /*#__PURE__*/ R.createElement(p4, v4({}, i, { ref: t })));
+ }), /*#__PURE__*/ R.createElement(f4, _4({}, i, { ref: t })));
});
//#endregion
//#region node_modules/recharts/es6/chart/RadarChart.js
-function S4(e, t) {
+function x4(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -68714,30 +68766,30 @@ function S4(e, t) {
}
return n;
}
-function C4(e) {
+function S4(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? S4(Object(n), !0).forEach(function(t) {
- _Le(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : S4(Object(n)).forEach(function(t) {
+ t % 2 ? x4(Object(n), !0).forEach(function(t) {
+ yLe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : x4(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function _Le(e, t, n) {
- return (t = vLe(t)) in e ? Object.defineProperty(e, t, {
+function yLe(e, t, n) {
+ return (t = bLe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function vLe(e) {
- var t = yLe(e, "string");
+function bLe(e) {
+ var t = xLe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function yLe(e, t) {
+function xLe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -68747,31 +68799,31 @@ function yLe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var bLe = ["axis"], xLe = C4(C4({}, b4), {}, {
+var SLe = ["axis"], CLe = S4(S4({}, y4), {}, {
layout: "centric",
startAngle: 90,
endAngle: -270
-}), SLe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var n = JL(e, xLe);
- return /*#__PURE__*/ R.createElement(x4, {
+}), wLe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var n = YL(e, CLe);
+ return /*#__PURE__*/ R.createElement(b4, {
chartName: "RadarChart",
defaultTooltipEventType: "axis",
- validateTooltipEventTypes: bLe,
+ validateTooltipEventTypes: SLe,
tooltipPayloadSearcher: FZ,
categoricalChartProps: n,
ref: t
});
-}), CLe = ["axis"], wLe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => /*#__PURE__*/ R.createElement(g4, {
+}), TLe = ["axis"], ELe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => /*#__PURE__*/ R.createElement(h4, {
chartName: "AreaChart",
defaultTooltipEventType: "axis",
- validateTooltipEventTypes: CLe,
+ validateTooltipEventTypes: TLe,
tooltipPayloadSearcher: FZ,
categoricalChartProps: e,
ref: t
}));
//#endregion
//#region node_modules/recharts/es6/chart/RadialBarChart.js
-function w4(e, t) {
+function C4(e, t) {
var n = Object.keys(e);
if (Object.getOwnPropertySymbols) {
var r = Object.getOwnPropertySymbols(e);
@@ -68781,30 +68833,30 @@ function w4(e, t) {
}
return n;
}
-function T4(e) {
+function w4(e) {
for (var t = 1; t < arguments.length; t++) {
var n = arguments[t] == null ? {} : arguments[t];
- t % 2 ? w4(Object(n), !0).forEach(function(t) {
- TLe(e, t, n[t]);
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : w4(Object(n)).forEach(function(t) {
+ t % 2 ? C4(Object(n), !0).forEach(function(t) {
+ DLe(e, t, n[t]);
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : C4(Object(n)).forEach(function(t) {
Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
});
}
return e;
}
-function TLe(e, t, n) {
- return (t = ELe(t)) in e ? Object.defineProperty(e, t, {
+function DLe(e, t, n) {
+ return (t = OLe(t)) in e ? Object.defineProperty(e, t, {
value: n,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = n, e;
}
-function ELe(e) {
- var t = DLe(e, "string");
+function OLe(e) {
+ var t = kLe(e, "string");
return typeof t == "symbol" ? t : t + "";
}
-function DLe(e, t) {
+function kLe(e, t) {
if (typeof e != "object" || !e) return e;
var n = e[Symbol.toPrimitive];
if (n !== void 0) {
@@ -68814,16 +68866,16 @@ function DLe(e, t) {
}
return (t === "string" ? String : Number)(e);
}
-var OLe = ["axis", "item"], kLe = T4(T4({}, b4), {}, {
+var ALe = ["axis", "item"], jLe = w4(w4({}, y4), {}, {
layout: "radial",
startAngle: 0,
endAngle: 360
-}), ALe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
- var n = JL(e, kLe);
- return /*#__PURE__*/ R.createElement(x4, {
+}), MLe = /*#__PURE__*/ (0, R.forwardRef)((e, t) => {
+ var n = YL(e, jLe);
+ return /*#__PURE__*/ R.createElement(b4, {
chartName: "RadialBarChart",
defaultTooltipEventType: "axis",
- validateTooltipEventTypes: OLe,
+ validateTooltipEventTypes: ALe,
tooltipPayloadSearcher: FZ,
categoricalChartProps: n,
ref: t
@@ -68831,42 +68883,42 @@ var OLe = ["axis", "item"], kLe = T4(T4({}, b4), {}, {
});
//#endregion
//#region src/react/charts/cn.ts
-function E4(...e) {
+function T4(...e) {
return Ii(ja(e));
}
//#endregion
//#region src/react/evilcharts/registry/ui/recharts-chart.tsx
-var D4 = {
+var E4 = {
light: "",
dark: ".dark"
-}, O4 = Object.keys(D4);
-function jLe(e) {
- for (let [t, n] of Object.entries(e)) if (n.colors && !O4.some((e) => n.colors?.[e] !== void 0)) throw Error(`[EvilCharts] Invalid chart config for "${t}": colors object must have at least one theme key (${O4.join(", ")}). Received empty object or invalid keys.`);
+}, D4 = Object.keys(E4);
+function NLe(e) {
+ for (let [t, n] of Object.entries(e)) if (n.colors && !D4.some((e) => n.colors?.[e] !== void 0)) throw Error(`[EvilCharts] Invalid chart config for "${t}": colors object must have at least one theme key (${D4.join(", ")}). Received empty object or invalid keys.`);
}
-var k4 = R.createContext(null);
-function A4() {
- let e = R.useContext(k4);
+var O4 = R.createContext(null);
+function k4() {
+ let e = R.useContext(O4);
if (!e) throw Error("useChart must be used within a <ChartContainer />");
return e;
}
-function j4({ id: e, config: t, initialDimension: n = {
+function A4({ id: e, config: t, initialDimension: n = {
width: 320,
height: 200
}, className: r, children: i, footer: a, ...o }) {
let s = R.useId(), c = `chart-${e ?? s.replace(/:/g, "")}`;
- return jLe(t), /* @__PURE__ */ (0, z.jsx)(k4.Provider, {
+ return NLe(t), /* @__PURE__ */ (0, z.jsx)(O4.Provider, {
value: { config: t },
children: /* @__PURE__ */ (0, z.jsxs)("div", {
"data-slot": "chart",
"data-chart": c,
- className: E4("min-h-0 w-full flex-1", "[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border relative flex flex-col justify-center text-xs [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden", !a && "aspect-video", r),
+ className: T4("min-h-0 w-full flex-1", "[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border relative flex flex-col justify-center text-xs [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden", !a && "aspect-video", r),
...o,
children: [
- /* @__PURE__ */ (0, z.jsx)(N4, {
+ /* @__PURE__ */ (0, z.jsx)(M4, {
id: c,
config: t
}),
- /* @__PURE__ */ (0, z.jsx)(pH, {
+ /* @__PURE__ */ (0, z.jsx)(mH, {
className: "min-h-0 w-full flex-1",
initialDimension: n,
children: i
@@ -68876,7 +68928,7 @@ function j4({ id: e, config: t, initialDimension: n = {
})
});
}
-function M4({ isLoading: e }) {
+function j4({ isLoading: e }) {
return e ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "pointer-events-none absolute inset-0 z-20 flex items-center justify-center",
children: /* @__PURE__ */ (0, z.jsxs)("div", {
@@ -68885,7 +68937,7 @@ function M4({ isLoading: e }) {
})
}) : null;
}
-function MLe(e, t) {
+function PLe(e, t) {
let n = e.length;
if (n >= t) return e.slice(0, t);
let r = [], i = Math.floor(t / n), a = t % n;
@@ -68895,46 +68947,46 @@ function MLe(e, t) {
}
return r;
}
-var N4 = ({ id: e, config: t }) => {
+var M4 = ({ id: e, config: t }) => {
let n = Object.entries(t).filter(([, e]) => e.colors);
if (!n.length) return null;
let r = (e) => n.flatMap(([t, n]) => {
let r = n.colors?.[e];
- return !r || !Array.isArray(r) || r.length === 0 ? [] : MLe(r, F4(n)).map((e, n) => ` --color-${t}-${n}: ${e};`);
- }).filter(Boolean).join("\n"), i = Object.entries(D4).map(([t, n]) => `${n} [data-chart=${e}] {\n${r(t)}\n}`).join("\n");
+ return !r || !Array.isArray(r) || r.length === 0 ? [] : PLe(r, P4(n)).map((e, n) => ` --color-${t}-${n}: ${e};`);
+ }).filter(Boolean).join("\n"), i = Object.entries(E4).map(([t, n]) => `${n} [data-chart=${e}] {\n${r(t)}\n}`).join("\n");
return /* @__PURE__ */ (0, z.jsx)("style", { dangerouslySetInnerHTML: { __html: i } });
};
-function P4(e, t, n) {
+function N4(e, t, n) {
if (typeof t != "object" || !t) return;
let r = "payload" in t && typeof t.payload == "object" && t.payload !== null ? t.payload : void 0, i = n;
return n in t && typeof t[n] == "string" ? i = t[n] : r && n in r && typeof r[n] == "string" && (i = r[n]), i in e ? e[i] : e[n];
}
-function F4(e) {
+function P4(e) {
if (!e.colors) return 1;
- let t = O4.map((t) => e.colors?.[t]?.length ?? 0);
+ let t = D4.map((t) => e.colors?.[t]?.length ?? 0);
return Math.max(...t, 1);
}
-var NLe = (e = 10, t = 0, n = 70) => {
+var FLe = (e = 10, t = 0, n = 70) => {
let r = n - t;
return Array.from({ length: e }, () => ({ loading: Math.floor(Math.random() * r) + t }));
-}, PLe = {
+}, ILe = {
sm: "rounded-sm",
md: "rounded-md",
lg: "rounded-lg",
xl: "rounded-xl"
-}, FLe = {
+}, LLe = {
default: "bg-background",
"frosted-glass": "bg-background/70 backdrop-blur-sm"
};
-function I4({ active: e, payload: t, className: n, indicator: r = "dot", hideLabel: i = !1, hideIndicator: a = !1, label: o, labelFormatter: s, labelClassName: c, formatter: l, nameKey: u, labelKey: d, selected: f, roundness: p = "lg", variant: m = "default" }) {
- let { config: h } = A4(), g = R.useMemo(() => {
+function F4({ active: e, payload: t, className: n, indicator: r = "dot", hideLabel: i = !1, hideIndicator: a = !1, label: o, labelFormatter: s, labelClassName: c, formatter: l, nameKey: u, labelKey: d, selected: f, roundness: p = "lg", variant: m = "default" }) {
+ let { config: h } = k4(), g = R.useMemo(() => {
if (i || !t?.length) return null;
- let [e] = t, n = `${d ?? e?.dataKey ?? e?.name ?? "value"}`, r = P4(h, e, n), a = !d && typeof o == "string" ? h[o]?.label ?? o : r?.label;
+ let [e] = t, n = `${d ?? e?.dataKey ?? e?.name ?? "value"}`, r = N4(h, e, n), a = !d && typeof o == "string" ? h[o]?.label ?? o : r?.label;
return s ? /* @__PURE__ */ (0, z.jsx)("div", {
- className: E4("font-medium", c),
+ className: T4("font-medium", c),
children: s(a, t)
}) : a ? /* @__PURE__ */ (0, z.jsx)("div", {
- className: E4("font-medium", c),
+ className: T4("font-medium", c),
children: a
}) : null;
}, [
@@ -68949,23 +69001,23 @@ function I4({ active: e, payload: t, className: n, indicator: r = "dot", hideLab
if (!e || !t?.length) return /* @__PURE__ */ (0, z.jsx)("span", { className: "p-4" });
let _ = t.length === 1 && r !== "dot";
return /* @__PURE__ */ (0, z.jsxs)("div", {
- className: E4("border-border/50 grid min-w-32 items-start gap-1.5 border px-2.5 py-1.5 text-xs shadow-xl", PLe[p], FLe[m], n),
+ className: T4("border-border/50 grid min-w-32 items-start gap-1.5 border px-2.5 py-1.5 text-xs shadow-xl", ILe[p], LLe[m], n),
children: [_ ? null : g, /* @__PURE__ */ (0, z.jsx)("div", {
className: "grid gap-1.5",
children: t.filter((e) => e.type !== "none").map((e, t) => {
- let n = `${(u && e.payload ? e.payload[u] : void 0) ?? e.name ?? e.dataKey ?? "value"}`, i = P4(h, e, n), o = i ? F4(i) : 1;
+ let n = `${(u && e.payload ? e.payload[u] : void 0) ?? e.name ?? e.dataKey ?? "value"}`, i = N4(h, e, n), o = i ? P4(i) : 1;
return /* @__PURE__ */ (0, z.jsx)("div", {
- className: E4("[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5", r === "dot" && "items-center", f != null && f !== e.dataKey && "opacity-30"),
+ className: T4("[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5", r === "dot" && "items-center", f != null && f !== e.dataKey && "opacity-30"),
children: l && e?.value !== void 0 && e.name ? l(e.value, e.name, e, t, e.payload) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [i?.icon ? /* @__PURE__ */ (0, z.jsx)(i.icon, {}) : !a && /* @__PURE__ */ (0, z.jsx)("div", {
- className: E4("shrink-0 rounded-[2px]", {
+ className: T4("shrink-0 rounded-[2px]", {
"h-2.5 w-2.5": r === "dot",
"w-1": r === "line",
"w-0 border-[1.5px] border-dashed bg-transparent!": r === "dashed",
"my-0.5": _ && r === "dashed"
}),
- style: ILe(n, o)
+ style: RLe(n, o)
}), /* @__PURE__ */ (0, z.jsxs)("div", {
- className: E4("flex flex-1 justify-between gap-4 leading-none", _ ? "items-end" : "items-center"),
+ className: T4("flex flex-1 justify-between gap-4 leading-none", _ ? "items-end" : "items-center"),
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "grid gap-1.5",
children: [_ ? g : null, /* @__PURE__ */ (0, z.jsx)("span", {
@@ -68982,27 +69034,27 @@ function I4({ active: e, payload: t, className: n, indicator: r = "dot", hideLab
})]
});
}
-function ILe(e, t) {
+function RLe(e, t) {
return t <= 1 ? { background: `var(--color-${e}-0)` } : { background: `linear-gradient(to right, ${Array.from({ length: t }, (n, r) => `var(--color-${e}-${r}) ${r / (t - 1) * 100}%`).join(", ")})` };
}
-var L4 = ({ animationDuration: e = 200, ...t }) => /* @__PURE__ */ (0, z.jsx)(EOe, {
+var I4 = ({ animationDuration: e = 200, ...t }) => /* @__PURE__ */ (0, z.jsx)(DOe, {
animationDuration: e,
...t
});
//#endregion
//#region src/react/evilcharts/registry/ui/recharts-legend.tsx
-function R4({ className: e, hideIcon: t = !1, nameKey: n, payload: r, verticalAlign: i, align: a = "right", selected: o, onSelectChange: s, isClickable: c, variant: l = "rounded-square" }) {
- let { config: u } = A4();
+function L4({ className: e, hideIcon: t = !1, nameKey: n, payload: r, verticalAlign: i, align: a = "right", selected: o, onSelectChange: s, isClickable: c, variant: l = "rounded-square" }) {
+ let { config: u } = k4();
return r?.length ? /* @__PURE__ */ (0, z.jsx)("div", {
- className: E4("flex items-center gap-4 select-none", a === "left" && "justify-start", a === "center" && "justify-center", a === "right" && "justify-end", i === "top" ? "pb-4" : "pt-4", e),
+ className: T4("flex items-center gap-4 select-none", a === "left" && "justify-start", a === "center" && "justify-center", a === "right" && "justify-end", i === "top" ? "pb-4" : "pt-4", e),
children: r.filter((e) => e.type !== "none").map((e) => {
- let r = `${(n && e.payload ? e.payload[n] : void 0) ?? e.value ?? e.dataKey ?? "value"}`, i = P4(u, e, r), a = o === null || o === r, d = i ? F4(i) : 1;
+ let r = `${(n && e.payload ? e.payload[n] : void 0) ?? e.value ?? e.dataKey ?? "value"}`, i = N4(u, e, r), a = o === null || o === r, d = i ? P4(i) : 1;
return /* @__PURE__ */ (0, z.jsxs)("div", {
- className: E4("[&>svg]:text-muted-foreground flex items-center gap-1.5 transition-opacity [&>svg]:h-3 [&>svg]:w-3", !a && "opacity-30", c && "cursor-pointer"),
+ className: T4("[&>svg]:text-muted-foreground flex items-center gap-1.5 transition-opacity [&>svg]:h-3 [&>svg]:w-3", !a && "opacity-30", c && "cursor-pointer"),
onClick: () => {
c && s?.(o === r ? null : r);
},
- children: [i?.icon && !t ? /* @__PURE__ */ (0, z.jsx)(i.icon, {}) : /* @__PURE__ */ (0, z.jsx)(LLe, {
+ children: [i?.icon && !t ? /* @__PURE__ */ (0, z.jsx)(i.icon, {}) : /* @__PURE__ */ (0, z.jsx)(zLe, {
variant: l,
dataKey: r,
colorsCount: d
@@ -69011,8 +69063,8 @@ function R4({ className: e, hideIcon: t = !1, nameKey: n, payload: r, verticalAl
})
}) : null;
}
-function LLe({ variant: e, dataKey: t, colorsCount: n }) {
- let r = RLe(t, n), i = zLe(t, n);
+function zLe({ variant: e, dataKey: t, colorsCount: n }) {
+ let r = BLe(t, n), i = VLe(t, n);
switch (e) {
case "square": return /* @__PURE__ */ (0, z.jsx)("div", {
className: "h-2 w-2 shrink-0",
@@ -69044,10 +69096,10 @@ function LLe({ variant: e, dataKey: t, colorsCount: n }) {
});
}
}
-function RLe(e, t) {
+function BLe(e, t) {
return t <= 1 ? { backgroundColor: `var(--color-${e}-0)` } : { background: `linear-gradient(to right, ${Array.from({ length: t }, (n, r) => `var(--color-${e}-${r}) ${r / (t - 1) * 100}%`).join(", ")})` };
}
-function zLe(e, t) {
+function VLe(e, t) {
let n = {
WebkitMask: "linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0)",
WebkitMaskComposite: "xor",
@@ -69062,12 +69114,12 @@ function zLe(e, t) {
...n
};
}
-var z4 = MU, B4 = () => null, V4 = {
+var R4 = MU, z4 = () => null, B4 = {
stiffness: 300,
damping: 35,
mass: .8
};
-function BLe({ range: e, totalPoints: t, containerRef: n, commit: r }) {
+function HLe({ range: e, totalPoints: t, containerRef: n, commit: r }) {
let i = R.useRef(null), [a, o] = R.useState(!1), s = (0, R.useCallback)((e) => !n.current || t <= 1 ? 0 : Math.round(e / n.current.getBoundingClientRect().width * (t - 1)), [t, n]), c = (0, R.useCallback)((t, n) => {
t.preventDefault(), t.target.setPointerCapture(t.pointerId), i.current = {
type: n,
@@ -69113,7 +69165,7 @@ function BLe({ range: e, totalPoints: t, containerRef: n, commit: r }) {
])
};
}
-function VLe({ data: e, chartConfig: t, dataKeys: n, xDataKey: r, variant: i = "area", height: a = 56, className: o, stacked: s = !1, strokeVariant: c = "solid", connectNulls: l = !1, barRadius: u, startIndex: d, endIndex: f, defaultStartIndex: p = 0, defaultEndIndex: m, onChange: h, formatLabel: g, curveType: _ = "monotone", minSpan: v = 2, showLabels: y = !0, skipStyle: b = !1 }) {
+function ULe({ data: e, chartConfig: t, dataKeys: n, xDataKey: r, variant: i = "area", height: a = 56, className: o, stacked: s = !1, strokeVariant: c = "solid", connectNulls: l = !1, barRadius: u, startIndex: d, endIndex: f, defaultStartIndex: p = 0, defaultEndIndex: m, onChange: h, formatLabel: g, curveType: _ = "monotone", minSpan: v = 2, showLabels: y = !0, skipStyle: b = !1 }) {
let x = R.useRef(null), S = R.useMemo(() => n ?? Object.keys(t), [n, t]), C = e.length, w = R.useId().replace(/:/g, ""), T = d !== void 0 && f !== void 0, [E, D] = R.useState(() => ({
startIndex: Math.max(0, Math.min(p, C - 1)),
endIndex: Math.max(0, Math.min(m ?? C - 1, C - 1))
@@ -69147,7 +69199,7 @@ function VLe({ data: e, chartConfig: t, dataKeys: n, xDataKey: r, variant: i = "
startIndex: n,
endIndex: r
};
- }, [C, v]), { isDragging: A, bind: j } = BLe({
+ }, [C, v]), { isDragging: A, bind: j } = HLe({
range: E,
totalPoints: C,
containerRef: x,
@@ -69172,16 +69224,16 @@ function VLe({ data: e, chartConfig: t, dataKeys: n, xDataKey: r, variant: i = "
f,
A
]);
- let N = C > 1 ? M.startIndex / (C - 1) * 100 : 0, P = C > 1 ? M.endIndex / (C - 1) * 100 : 100, ee = GP(N), F = GP(P);
+ let N = C > 1 ? M.startIndex / (C - 1) * 100 : 0, P = C > 1 ? M.endIndex / (C - 1) * 100 : 100, ee = KP(N), F = KP(P);
ee.get() !== N && ee.set(N), F.get() !== P && F.set(P);
- let I = YP(ee, V4), te = YP(F, V4), ne = qP(I, (e) => `${e}%`), re = qP(te, (e) => `${e}%`), ie = qP(I, (e) => `${e}%`), ae = qP(te, (e) => `${Math.max(0, 100 - e)}%`), oe = GP(`${Math.max(0, P - N)}%`), se = (0, R.useCallback)(() => {
+ let I = XP(ee, B4), te = XP(F, B4), ne = JP(I, (e) => `${e}%`), re = JP(te, (e) => `${e}%`), ie = JP(I, (e) => `${e}%`), ae = JP(te, (e) => `${Math.max(0, 100 - e)}%`), oe = KP(`${Math.max(0, P - N)}%`), se = (0, R.useCallback)(() => {
oe.set(`${Math.max(0, te.get() - I.get())}%`);
}, [
I,
te,
oe
]);
- WP(I, "change", se), WP(te, "change", se);
+ GP(I, "change", se), GP(te, "change", se);
let ce = (0, R.useCallback)((t) => {
if (!r) return String(t);
let n = e[t]?.[r];
@@ -69194,16 +69246,16 @@ function VLe({ data: e, chartConfig: t, dataKeys: n, xDataKey: r, variant: i = "
return C === 0 ? null : /* @__PURE__ */ (0, z.jsxs)("div", {
ref: x,
"data-chart": b ? void 0 : w,
- className: E4("group relative select-none", o),
+ className: T4("group relative select-none", o),
style: { height: a },
children: [
- !b && /* @__PURE__ */ (0, z.jsx)(N4, {
+ !b && /* @__PURE__ */ (0, z.jsx)(M4, {
id: w,
config: t
}),
/* @__PURE__ */ (0, z.jsx)("div", {
className: "absolute inset-0 overflow-hidden rounded-md",
- children: /* @__PURE__ */ (0, z.jsx)(HLe, {
+ children: /* @__PURE__ */ (0, z.jsx)(WLe, {
data: e,
keys: S,
chartConfig: t,
@@ -69216,15 +69268,15 @@ function VLe({ data: e, chartConfig: t, dataKeys: n, xDataKey: r, variant: i = "
barRadius: u
})
}),
- /* @__PURE__ */ (0, z.jsx)(XP.div, {
+ /* @__PURE__ */ (0, z.jsx)(ZP.div, {
className: "bg-background/70 pointer-events-none absolute inset-y-0 left-0 rounded-l-md backdrop-blur-[2px]",
style: { width: ie }
}),
- /* @__PURE__ */ (0, z.jsx)(XP.div, {
+ /* @__PURE__ */ (0, z.jsx)(ZP.div, {
className: "bg-background/70 pointer-events-none absolute inset-y-0 right-0 rounded-r-md backdrop-blur-[2px]",
style: { width: ae }
}),
- /* @__PURE__ */ (0, z.jsx)(XP.div, {
+ /* @__PURE__ */ (0, z.jsx)(ZP.div, {
className: "absolute inset-y-0 cursor-grab touch-none rounded-sm border active:cursor-grabbing",
style: {
left: ne,
@@ -69232,13 +69284,13 @@ function VLe({ data: e, chartConfig: t, dataKeys: n, xDataKey: r, variant: i = "
},
...j("middle")
}),
- /* @__PURE__ */ (0, z.jsx)(H4, {
+ /* @__PURE__ */ (0, z.jsx)(V4, {
side: "left",
position: ne,
label: y ? ce(M.startIndex) : void 0,
bind: j("left")
}),
- /* @__PURE__ */ (0, z.jsx)(H4, {
+ /* @__PURE__ */ (0, z.jsx)(V4, {
side: "right",
position: re,
label: y ? ce(M.endIndex) : void 0,
@@ -69247,16 +69299,16 @@ function VLe({ data: e, chartConfig: t, dataKeys: n, xDataKey: r, variant: i = "
]
});
}
-function H4({ side: e, position: t, label: n, bind: r }) {
+function V4({ side: e, position: t, label: n, bind: r }) {
let i = e === "left";
- return /* @__PURE__ */ (0, z.jsxs)(XP.div, {
+ return /* @__PURE__ */ (0, z.jsxs)(ZP.div, {
className: "absolute inset-y-0 z-10",
style: { left: t },
children: [/* @__PURE__ */ (0, z.jsx)("div", {
- className: E4("group absolute inset-y-0 flex w-3 cursor-ew-resize touch-none items-center justify-center after:absolute after:inset-y-0 after:-left-4 after:w-11 after:content-['']", i ? "" : "-translate-x-full"),
+ className: T4("group absolute inset-y-0 flex w-3 cursor-ew-resize touch-none items-center justify-center after:absolute after:inset-y-0 after:-left-4 after:w-11 after:content-['']", i ? "" : "-translate-x-full"),
...r,
children: /* @__PURE__ */ (0, z.jsx)("div", {
- className: E4("bg-muted-foreground group-hover:bg-foreground relative flex h-4 w-1.5 items-center justify-center rounded-md transition-colors", i ? "-left-[5.5px]" : "-right-[5.5px]"),
+ className: T4("bg-muted-foreground group-hover:bg-foreground relative flex h-4 w-1.5 items-center justify-center rounded-md transition-colors", i ? "-left-[5.5px]" : "-right-[5.5px]"),
children: /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-[2px]",
children: [
@@ -69267,15 +69319,15 @@ function H4({ side: e, position: t, label: n, bind: r }) {
})
})
}), n && /* @__PURE__ */ (0, z.jsx)("div", {
- className: E4("bg-foreground text-background pointer-events-none absolute -bottom-3 -translate-y-1/2 rounded-[3px] px-1 py-px text-[8px] leading-tight font-medium whitespace-nowrap opacity-0 group-hover:opacity-100", i ? "left-1.5" : "right-1.5"),
+ className: T4("bg-foreground text-background pointer-events-none absolute -bottom-3 -translate-y-1/2 rounded-[3px] px-1 py-px text-[8px] leading-tight font-medium whitespace-nowrap opacity-0 group-hover:opacity-100", i ? "left-1.5" : "right-1.5"),
children: n
})]
});
}
-function HLe({ data: e, keys: t, chartConfig: n, variant: r, curveType: i, chartId: a, stacked: o, strokeVariant: s = "solid", connectNulls: c = !1, barRadius: l }) {
+function WLe({ data: e, keys: t, chartConfig: n, variant: r, curveType: i, chartId: a, stacked: o, strokeVariant: s = "solid", connectNulls: c = !1, barRadius: l }) {
let u = R.useMemo(() => Object.entries(n).filter(([e]) => t.includes(e)).map(([e, t]) => ({
dataKey: e,
- colorsCount: F4(t)
+ colorsCount: P4(t)
})), [n, t]), d = s === "dashed" || s === "animated-dashed" ? "4 4" : void 0, f = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [r === "area" && /* @__PURE__ */ (0, z.jsxs)("linearGradient", {
id: `${a}-zm-vertical-fade`,
x1: "0",
@@ -69329,10 +69381,10 @@ function HLe({ data: e, keys: t, chartConfig: n, variant: r, curveType: i, chart
})
})] })] }, e);
})] });
- if (r === "line") return /* @__PURE__ */ (0, z.jsx)(pH, {
+ if (r === "line") return /* @__PURE__ */ (0, z.jsx)(mH, {
width: "100%",
height: "100%",
- children: /* @__PURE__ */ (0, z.jsxs)(sLe, {
+ children: /* @__PURE__ */ (0, z.jsxs)(lLe, {
data: e,
margin: {
top: 4,
@@ -69340,7 +69392,7 @@ function HLe({ data: e, keys: t, chartConfig: n, variant: r, curveType: i, chart
bottom: 0,
left: 0
},
- children: [/* @__PURE__ */ (0, z.jsx)("defs", { children: f }), t.map((e) => /* @__PURE__ */ (0, z.jsx)(F0, {
+ children: [/* @__PURE__ */ (0, z.jsx)("defs", { children: f }), t.map((e) => /* @__PURE__ */ (0, z.jsx)(P0, {
type: i,
dataKey: e,
stroke: `url(#${a}-zm-${e})`,
@@ -69356,10 +69408,10 @@ function HLe({ data: e, keys: t, chartConfig: n, variant: r, curveType: i, chart
});
if (r === "bar") {
let n = l ?? 3;
- return /* @__PURE__ */ (0, z.jsx)(pH, {
+ return /* @__PURE__ */ (0, z.jsx)(mH, {
width: "100%",
height: "100%",
- children: /* @__PURE__ */ (0, z.jsxs)(_4, {
+ children: /* @__PURE__ */ (0, z.jsxs)(g4, {
data: e,
margin: {
top: 2,
@@ -69369,7 +69421,7 @@ function HLe({ data: e, keys: t, chartConfig: n, variant: r, curveType: i, chart
},
barGap: 2,
barSize: 14,
- children: [/* @__PURE__ */ (0, z.jsx)("defs", { children: f }), t.map((e) => /* @__PURE__ */ (0, z.jsx)(l2, {
+ children: [/* @__PURE__ */ (0, z.jsx)("defs", { children: f }), t.map((e) => /* @__PURE__ */ (0, z.jsx)(c2, {
dataKey: e,
fill: `url(#${a}-zm-${e})`,
fillOpacity: .35,
@@ -69385,10 +69437,10 @@ function HLe({ data: e, keys: t, chartConfig: n, variant: r, curveType: i, chart
})
});
}
- return /* @__PURE__ */ (0, z.jsx)(pH, {
+ return /* @__PURE__ */ (0, z.jsx)(mH, {
width: "100%",
height: "100%",
- children: /* @__PURE__ */ (0, z.jsxs)(wLe, {
+ children: /* @__PURE__ */ (0, z.jsxs)(ELe, {
data: e,
margin: {
top: 4,
@@ -69396,7 +69448,7 @@ function HLe({ data: e, keys: t, chartConfig: n, variant: r, curveType: i, chart
bottom: 0,
left: 0
},
- children: [/* @__PURE__ */ (0, z.jsx)("defs", { children: f }), t.map((e) => /* @__PURE__ */ (0, z.jsx)(X0, {
+ children: [/* @__PURE__ */ (0, z.jsx)("defs", { children: f }), t.map((e) => /* @__PURE__ */ (0, z.jsx)(Y0, {
type: i,
dataKey: e,
stroke: `url(#${a}-zm-${e})`,
@@ -69414,7 +69466,7 @@ function HLe({ data: e, keys: t, chartConfig: n, variant: r, curveType: i, chart
})
});
}
-function ULe({ data: e, defaultStartIndex: t = 0, defaultEndIndex: n }) {
+function GLe({ data: e, defaultStartIndex: t = 0, defaultEndIndex: n }) {
let [r, i] = R.useState({
startIndex: t,
endIndex: n ?? Math.max(0, e.length - 1)
@@ -69438,7 +69490,7 @@ function ULe({ data: e, defaultStartIndex: t = 0, defaultEndIndex: n }) {
}
};
}
-var WLe = {
+var KLe = {
dots: ({ id: e }) => /* @__PURE__ */ (0, z.jsx)("pattern", {
id: e,
x: "0",
@@ -69610,8 +69662,8 @@ var WLe = {
})
})
};
-function U4({ variant: e }) {
- let t = (0, R.useId)().replace(/:/g, ""), n = `${t}-bg-${e}`, r = `${t}-bg-edge-fade`, i = `${t}-bg-blur`, a = WLe[e];
+function H4({ variant: e }) {
+ let t = (0, R.useId)().replace(/:/g, ""), n = `${t}-bg-${e}`, r = `${t}-bg-edge-fade`, i = `${t}-bg-blur`, a = KLe[e];
return /* @__PURE__ */ (0, z.jsxs)(DZ, {
zIndex: -1,
children: [/* @__PURE__ */ (0, z.jsxs)("defs", { children: [
@@ -69642,20 +69694,20 @@ function U4({ variant: e }) {
}
//#endregion
//#region src/react/evilcharts/registry/charts/recharts-bar-chart.tsx
-var W4 = 2, GLe = "loading", KLe = 2e3, qLe = "evil-stacked", JLe = .5, YLe = .05, XLe = [
+var U4 = 2, qLe = "loading", JLe = 2e3, YLe = "evil-stacked", XLe = .5, ZLe = .05, QLe = [
0,
.7,
.5,
1
-], G4 = (0, R.createContext)(null);
-function K4() {
- let e = (0, R.use)(G4);
+], W4 = (0, R.createContext)(null);
+function G4() {
+ let e = (0, R.use)(W4);
if (!e) throw Error("Bar chart parts (<Bar />, <XAxis />, …) must be used within <EvilBarChart />");
return e;
}
-function q4({ config: e, data: t, children: n, className: r, chartProps: i, stackType: a = "default", layout: o = "vertical", barRadius: s = W4, animationType: c = "left-to-right", barGap: l, barCategoryGap: u, backgroundVariant: d, defaultSelectedDataKey: f = null, onSelectionChange: p, isLoading: m = !1, loadingBars: h, xDataKey: g }) {
- let _ = (0, R.useId)().replace(/:/g, ""), [v] = (0, R.useState)(() => Date.now()), [y, b] = (0, R.useState)(f), [x, S] = (0, R.useState)(!1), { loadingData: C, onShimmerExit: w } = hRe(m, h), { visibleData: T, brushProps: E } = ULe({ data: t }), D = (0, R.useMemo)(() => {
- let e = R.Children.toArray(n), t = e.find((e) => (0, R.isValidElement)(e) && e.type === B4), r = (0, R.isValidElement)(t) ? t.props : {};
+function K4({ config: e, data: t, children: n, className: r, chartProps: i, stackType: a = "default", layout: o = "vertical", barRadius: s = U4, animationType: c = "left-to-right", barGap: l, barCategoryGap: u, backgroundVariant: d, defaultSelectedDataKey: f = null, onSelectionChange: p, isLoading: m = !1, loadingBars: h, xDataKey: g }) {
+ let _ = (0, R.useId)().replace(/:/g, ""), [v] = (0, R.useState)(() => Date.now()), [y, b] = (0, R.useState)(f), [x, S] = (0, R.useState)(!1), { loadingData: C, onShimmerExit: w } = _Re(m, h), { visibleData: T, brushProps: E } = GLe({ data: t }), D = (0, R.useMemo)(() => {
+ let e = R.Children.toArray(n), t = e.find((e) => (0, R.isValidElement)(e) && e.type === z4), r = (0, R.isValidElement)(t) ? t.props : {};
return {
slot: {
present: (0, R.isValidElement)(t),
@@ -69663,7 +69715,7 @@ function q4({ config: e, data: t, children: n, className: r, chartProps: i, stac
formatLabel: r.formatLabel,
onChange: r.onChange
},
- chartChildren: e.filter((e) => !((0, R.isValidElement)(e) && e.type === B4))
+ chartChildren: e.filter((e) => !((0, R.isValidElement)(e) && e.type === z4))
};
}, [n]), O = D.slot.present, k = a === "stacked" || a === "percent", A = o === "horizontal", j = O && !m ? T : t, M = (0, R.useCallback)((e) => {
b(e), p?.(e);
@@ -69692,12 +69744,12 @@ function q4({ config: e, data: t, children: n, className: r, chartProps: i, stac
M,
x
]);
- return /* @__PURE__ */ (0, z.jsx)(G4, {
+ return /* @__PURE__ */ (0, z.jsx)(W4, {
value: N,
- children: /* @__PURE__ */ (0, z.jsxs)(j4, {
+ children: /* @__PURE__ */ (0, z.jsxs)(A4, {
className: r,
config: e,
- footer: O && !m && /* @__PURE__ */ (0, z.jsx)(VLe, {
+ footer: O && !m && /* @__PURE__ */ (0, z.jsx)(ULe, {
data: t,
chartConfig: e,
xDataKey: g,
@@ -69713,7 +69765,7 @@ function q4({ config: e, data: t, children: n, className: r, chartProps: i, stac
E.onChange(e), D.slot.onChange?.(e);
}
}),
- children: [/* @__PURE__ */ (0, z.jsx)(M4, { isLoading: m }), /* @__PURE__ */ (0, z.jsxs)(_4, {
+ children: [/* @__PURE__ */ (0, z.jsx)(j4, { isLoading: m }), /* @__PURE__ */ (0, z.jsxs)(g4, {
id: _,
accessibilityLayer: !0,
layout: A ? "vertical" : "horizontal",
@@ -69725,10 +69777,10 @@ function q4({ config: e, data: t, children: n, className: r, chartProps: i, stac
onMouseLeave: () => S(!1),
...i,
children: [
- d && /* @__PURE__ */ (0, z.jsx)(U4, { variant: d }),
- /* @__PURE__ */ (0, z.jsx)(t0, { color: "white" }),
+ d && /* @__PURE__ */ (0, z.jsx)(H4, { variant: d }),
+ /* @__PURE__ */ (0, z.jsx)(e0, { color: "white" }),
D.chartChildren,
- m && /* @__PURE__ */ (0, z.jsx)(gRe, {
+ m && /* @__PURE__ */ (0, z.jsx)(vRe, {
chartId: _,
onShimmerExit: w
})
@@ -69737,8 +69789,8 @@ function q4({ config: e, data: t, children: n, className: r, chartProps: i, stac
})
});
}
-function ZLe({ dataKey: e, variant: t = "default", radius: n, animationType: r, isClickable: i = !1, enableHoverHighlight: a = !1, glowing: o = !1, bufferBar: s = !1, barProps: c }) {
- let { config: l, isStacked: u, isHorizontal: d, isLoading: f, barRadius: p, animationType: m, introStartedAt: h, dataLength: g, selectedDataKey: _, selectDataKey: v, isMouseInChart: y } = K4(), b = (0, R.useId)().replace(/:/g, ""), x = mme();
+function $Le({ dataKey: e, variant: t = "default", radius: n, animationType: r, isClickable: i = !1, enableHoverHighlight: a = !1, glowing: o = !1, bufferBar: s = !1, barProps: c }) {
+ let { config: l, isStacked: u, isHorizontal: d, isLoading: f, barRadius: p, animationType: m, introStartedAt: h, dataLength: g, selectedDataKey: _, selectDataKey: v, isMouseInChart: y } = G4(), b = (0, R.useId)().replace(/:/g, ""), x = pme();
if (f) return null;
let S = n ?? p, C = _ === e, w = x ? "none" : r ?? m, T = {
id: b,
@@ -69758,65 +69810,65 @@ function ZLe({ dataKey: e, variant: t = "default", radius: n, animationType: r,
i && v(C ? null : e);
}
};
- return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(l2, {
+ return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(c2, {
dataKey: e,
- stackId: u ? qLe : void 0,
+ stackId: u ? YLe : void 0,
fill: `url(#${b}-colors-${e})`,
radius: S,
isAnimationActive: !1,
style: i || a ? { cursor: "pointer" } : void 0,
- shape: (e) => /* @__PURE__ */ (0, z.jsx)(J4, {
+ shape: (e) => /* @__PURE__ */ (0, z.jsx)(q4, {
...e,
...T,
animationType: w
}),
- activeBar: (e) => /* @__PURE__ */ (0, z.jsx)(J4, {
+ activeBar: (e) => /* @__PURE__ */ (0, z.jsx)(q4, {
...e,
...T,
animationType: "none"
}),
...c
}), /* @__PURE__ */ (0, z.jsxs)("defs", { children: [
- /* @__PURE__ */ (0, z.jsx)(oRe, {
+ /* @__PURE__ */ (0, z.jsx)(cRe, {
id: b,
dataKey: e,
config: l
}),
- t === "hatched" && /* @__PURE__ */ (0, z.jsx)(sRe, {
+ t === "hatched" && /* @__PURE__ */ (0, z.jsx)(lRe, {
id: b,
dataKey: e
}),
- t === "duotone" && /* @__PURE__ */ (0, z.jsx)(lRe, {
+ t === "duotone" && /* @__PURE__ */ (0, z.jsx)(dRe, {
id: b,
dataKey: e,
config: l
}),
- t === "duotone-reverse" && /* @__PURE__ */ (0, z.jsx)(uRe, {
+ t === "duotone-reverse" && /* @__PURE__ */ (0, z.jsx)(fRe, {
id: b,
dataKey: e,
config: l
}),
- t === "gradient" && /* @__PURE__ */ (0, z.jsx)(dRe, {
+ t === "gradient" && /* @__PURE__ */ (0, z.jsx)(pRe, {
id: b,
dataKey: e
}),
- t === "stripped" && /* @__PURE__ */ (0, z.jsx)(fRe, {
+ t === "stripped" && /* @__PURE__ */ (0, z.jsx)(mRe, {
id: b,
dataKey: e
}),
- s && /* @__PURE__ */ (0, z.jsx)(cRe, {
+ s && /* @__PURE__ */ (0, z.jsx)(uRe, {
id: b,
dataKey: e
}),
- o && /* @__PURE__ */ (0, z.jsx)(pRe, {
+ o && /* @__PURE__ */ (0, z.jsx)(hRe, {
id: b,
dataKey: e
})
] })] });
}
-function QLe({ tickLine: e = !1, axisLine: t = !1, tickMargin: n = 8, minTickGap: r = 8, type: i, ...a }) {
- let { isLoading: o, isHorizontal: s } = K4();
- return o ? null : /* @__PURE__ */ (0, z.jsx)(_2, {
+function eRe({ tickLine: e = !1, axisLine: t = !1, tickMargin: n = 8, minTickGap: r = 8, type: i, ...a }) {
+ let { isLoading: o, isHorizontal: s } = G4();
+ return o ? null : /* @__PURE__ */ (0, z.jsx)(g2, {
tickLine: e,
axisLine: t,
tickMargin: n,
@@ -69825,9 +69877,9 @@ function QLe({ tickLine: e = !1, axisLine: t = !1, tickMargin: n = 8, minTickGap
...a
});
}
-function $Le({ tickLine: e = !1, axisLine: t = !1, tickMargin: n = 8, minTickGap: r = 8, width: i = "auto", type: a, ...o }) {
- let { isLoading: s, isHorizontal: c } = K4();
- return s ? null : /* @__PURE__ */ (0, z.jsx)(S2, {
+function tRe({ tickLine: e = !1, axisLine: t = !1, tickMargin: n = 8, minTickGap: r = 8, width: i = "auto", type: a, ...o }) {
+ let { isLoading: s, isHorizontal: c } = G4();
+ return s ? null : /* @__PURE__ */ (0, z.jsx)(x2, {
tickLine: e,
axisLine: t,
tickMargin: n,
@@ -69837,33 +69889,33 @@ function $Le({ tickLine: e = !1, axisLine: t = !1, tickMargin: n = 8, minTickGap
...o
});
}
-function eRe({ strokeDasharray: e = "3 3", vertical: t, horizontal: n, ...r }) {
- let { isHorizontal: i } = K4();
- return /* @__PURE__ */ (0, z.jsx)(v0, {
+function nRe({ strokeDasharray: e = "3 3", vertical: t, horizontal: n, ...r }) {
+ let { isHorizontal: i } = G4();
+ return /* @__PURE__ */ (0, z.jsx)(_0, {
strokeDasharray: e,
vertical: t ?? i,
horizontal: n ?? !i,
...r
});
}
-function tRe({ variant: e, roundness: t, defaultIndex: n }) {
- let { isLoading: r, selectedDataKey: i } = K4();
- return r ? null : /* @__PURE__ */ (0, z.jsx)(L4, {
+function rRe({ variant: e, roundness: t, defaultIndex: n }) {
+ let { isLoading: r, selectedDataKey: i } = G4();
+ return r ? null : /* @__PURE__ */ (0, z.jsx)(I4, {
cursor: !1,
defaultIndex: n,
- content: /* @__PURE__ */ (0, z.jsx)(I4, {
+ content: /* @__PURE__ */ (0, z.jsx)(F4, {
selected: i,
roundness: t,
variant: e
})
});
}
-function nRe({ variant: e, align: t = "right", verticalAlign: n = "top", isClickable: r = !1 }) {
- let { selectedDataKey: i, selectDataKey: a } = K4();
- return /* @__PURE__ */ (0, z.jsx)(z4, {
+function iRe({ variant: e, align: t = "right", verticalAlign: n = "top", isClickable: r = !1 }) {
+ let { selectedDataKey: i, selectDataKey: a } = G4();
+ return /* @__PURE__ */ (0, z.jsx)(R4, {
verticalAlign: n,
align: t,
- content: /* @__PURE__ */ (0, z.jsx)(R4, {
+ content: /* @__PURE__ */ (0, z.jsx)(L4, {
selected: i,
onSelectChange: a,
isClickable: r,
@@ -69871,8 +69923,8 @@ function nRe({ variant: e, align: t = "right", verticalAlign: n = "top", isClick
})
});
}
-var J4 = (e) => {
- let { x: t = 0, y: n = 0, width: r = 0, height: i = 0, id: a, dataKey: o, variant: s, barRadius: c, glowing: l, bufferBar: u, isClickable: d, enableHoverHighlight: f, isMouseInChart: p, isHorizontal: m = !1, animationType: h = "none", introStartedAt: g = 0, selectedDataKey: _, isActive: v, dataLength: y = 0, onClick: b } = e, x = typeof e.index == "number" ? e.index : -1, S = u && y > 0 && x === y - 1, C = s === "stripped", w = rRe(h, x, y, m, g), T = S ? `url(#${a}-buffer-hatched-${o})` : iRe(s, a, o), E = l ? `url(#${a}-bar-glow-${o})` : void 0, D = aRe({
+var q4 = (e) => {
+ let { x: t = 0, y: n = 0, width: r = 0, height: i = 0, id: a, dataKey: o, variant: s, barRadius: c, glowing: l, bufferBar: u, isClickable: d, enableHoverHighlight: f, isMouseInChart: p, isHorizontal: m = !1, animationType: h = "none", introStartedAt: g = 0, selectedDataKey: _, isActive: v, dataLength: y = 0, onClick: b } = e, x = typeof e.index == "number" ? e.index : -1, S = u && y > 0 && x === y - 1, C = s === "stripped", w = aRe(h, x, y, m, g), T = S ? `url(#${a}-buffer-hatched-${o})` : oRe(s, a, o), E = l ? `url(#${a}-bar-glow-${o})` : void 0, D = sRe({
isClickable: d,
selectedDataKey: _,
dataKey: o,
@@ -69909,7 +69961,7 @@ var J4 = (e) => {
children: [/* @__PURE__ */ (0, z.jsx)(EW, {
...e,
fill: "transparent"
- }), w ? /* @__PURE__ */ (0, z.jsx)(XP.g, {
+ }), w ? /* @__PURE__ */ (0, z.jsx)(ZP.g, {
initial: w.initial,
animate: w.animate,
transition: w.transition,
@@ -69917,7 +69969,7 @@ var J4 = (e) => {
children: A
}) : A]
});
-}, rRe = (e, t, n, r, i) => {
+}, aRe = (e, t, n, r, i) => {
if (e === "none" || t < 0 || n <= 0) return null;
let a = n - 1, o = a / 2, s;
switch (e) {
@@ -69932,11 +69984,11 @@ var J4 = (e) => {
break;
default: s = t;
}
- let c = s * YLe * 1e3, l = JLe * 1e3, u = c + l, d = Date.now() - i;
+ let c = s * ZLe * 1e3, l = XLe * 1e3, u = c + l, d = Date.now() - i;
if (d >= u) return null;
let f = d <= c ? 0 : (d - c) / l, p = {
duration: (u - Math.max(d, c)) / 1e3,
- ease: XLe,
+ ease: QLe,
delay: Math.max(0, c - d) / 1e3
};
return r ? {
@@ -69950,7 +70002,7 @@ var J4 = (e) => {
transition: p,
style: { originY: 1 }
};
-}, iRe = (e, t, n) => {
+}, oRe = (e, t, n) => {
switch (e) {
case "hatched": return `url(#${t}-hatched-${n})`;
case "duotone": return `url(#${t}-duotone-${n})`;
@@ -69959,11 +70011,11 @@ var J4 = (e) => {
case "stripped": return `url(#${t}-stripped-${n})`;
default: return `url(#${t}-colors-${n})`;
}
-}, aRe = ({ isClickable: e, selectedDataKey: t, dataKey: n, enableHoverHighlight: r, isMouseInChart: i, isActive: a }) => {
+}, sRe = ({ isClickable: e, selectedDataKey: t, dataKey: n, enableHoverHighlight: r, isMouseInChart: i, isActive: a }) => {
let o = e && t !== null ? t === null || t === n ? 1 : .15 : 1;
return r && i ? a ? o : o * .3 : o;
-}, oRe = ({ id: e, dataKey: t, config: n }) => {
- let r = F4(n[t] ?? {});
+}, cRe = ({ id: e, dataKey: t, config: n }) => {
+ let r = P4(n[t] ?? {});
return /* @__PURE__ */ (0, z.jsx)("linearGradient", {
id: `${e}-colors-${t}`,
x1: "0",
@@ -69984,7 +70036,7 @@ var J4 = (e) => {
}, i);
})
});
-}, sRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
+}, lRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsxs)("pattern", {
id: `${e}-hatched-mask-pattern`,
x: "0",
@@ -70025,7 +70077,7 @@ var J4 = (e) => {
mask: `url(#${e}-hatched-mask-${t})`
})
})
-] }), cRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
+] }), uRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsxs)("pattern", {
id: `${e}-buffer-hatched-mask-pattern`,
x: "0",
@@ -70066,8 +70118,8 @@ var J4 = (e) => {
mask: `url(#${e}-buffer-hatched-mask-${t})`
})
})
-] }), lRe = ({ id: e, dataKey: t, config: n }) => {
- let r = F4(n[t] ?? {});
+] }), dRe = ({ id: e, dataKey: t, config: n }) => {
+ let r = P4(n[t] ?? {});
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsxs)("linearGradient", {
id: `${e}-duotone-mask-gradient-${t}`,
@@ -70134,8 +70186,8 @@ var J4 = (e) => {
})
})
] });
-}, uRe = ({ id: e, dataKey: t, config: n }) => {
- let r = F4(n[t] ?? {});
+}, fRe = ({ id: e, dataKey: t, config: n }) => {
+ let r = P4(n[t] ?? {});
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsxs)("linearGradient", {
id: `${e}-duotone-reverse-mask-gradient-${t}`,
@@ -70202,7 +70254,7 @@ var J4 = (e) => {
})
})
] });
-}, dRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
+}, pRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsxs)("linearGradient", {
id: `${e}-gradient-mask-gradient`,
x1: "0",
@@ -70239,7 +70291,7 @@ var J4 = (e) => {
mask: `url(#${e}-gradient-mask-${t})`
})
})
-] }), fRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
+] }), mRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsxs)("linearGradient", {
id: `${e}-stripped-mask-gradient`,
x1: "0",
@@ -70276,7 +70328,7 @@ var J4 = (e) => {
mask: `url(#${e}-stripped-mask-${t})`
})
})
-] }), pRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)("filter", {
+] }), hRe = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)("filter", {
id: `${e}-bar-glow-${t}`,
x: "-100%",
y: "-100%",
@@ -70296,35 +70348,35 @@ var J4 = (e) => {
}),
/* @__PURE__ */ (0, z.jsxs)("feMerge", { children: [/* @__PURE__ */ (0, z.jsx)("feMergeNode", { in: "glow" }), /* @__PURE__ */ (0, z.jsx)("feMergeNode", { in: "SourceGraphic" })] })
]
-}), mRe = (e = 17, t = .05, n = .9) => Array.from({ length: e }, (r, i) => {
+}), gRe = (e = 17, t = .05, n = .9) => Array.from({ length: e }, (r, i) => {
let a = i / (e - 1), o = t + Math.sin(a * Math.PI) ** 2 * (n - t);
return {
offset: `${(a * 100).toFixed(0)}%`,
opacity: Number(o.toFixed(3))
};
});
-function hRe(e, t = 12) {
+function _Re(e, t = 12) {
let [n, r] = (0, R.useState)(!1), i = (0, R.useCallback)(() => {
e && r((e) => !e);
}, [e]);
return {
- loadingData: (0, R.useMemo)(() => NLe(t, 20, 80), [t, n]),
+ loadingData: (0, R.useMemo)(() => FLe(t, 20, 80), [t, n]),
onShimmerExit: i
};
}
-var gRe = ({ chartId: e, onShimmerExit: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(l2, {
- dataKey: GLe,
+var vRe = ({ chartId: e, onShimmerExit: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(c2, {
+ dataKey: qLe,
fill: "currentColor",
fillOpacity: .15,
- radius: W4,
+ radius: U4,
isAnimationActive: !1,
legendType: "none",
style: { mask: `url(#${e}-loading-mask)` }
-}), /* @__PURE__ */ (0, z.jsx)("defs", { children: /* @__PURE__ */ (0, z.jsx)(_Re, {
+}), /* @__PURE__ */ (0, z.jsx)("defs", { children: /* @__PURE__ */ (0, z.jsx)(yRe, {
chartId: e,
onShimmerExit: t
-}) })] }), _Re = ({ chartId: e, onShimmerExit: t }) => {
- let n = mRe(), r = (0, R.useRef)(-1);
+}) })] }), yRe = ({ chartId: e, onShimmerExit: t }) => {
+ let n = gRe(), r = (0, R.useRef)(-1);
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsx)("linearGradient", {
id: `${e}-loading-mask-gradient`,
@@ -70347,7 +70399,7 @@ var gRe = ({ chartId: e, onShimmerExit: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fr
height: "1",
x: "0",
y: "0",
- children: /* @__PURE__ */ (0, z.jsx)(XP.rect, {
+ children: /* @__PURE__ */ (0, z.jsx)(ZP.rect, {
y: "0",
width: "1",
height: "1",
@@ -70355,7 +70407,7 @@ var gRe = ({ chartId: e, onShimmerExit: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fr
initial: { x: -1 },
animate: { x: 2 },
transition: {
- duration: KLe / 1e3,
+ duration: JLe / 1e3,
ease: "linear",
repeat: Infinity,
repeatType: "loop"
@@ -70377,11 +70429,11 @@ var gRe = ({ chartId: e, onShimmerExit: t }) => /* @__PURE__ */ (0, z.jsxs)(z.Fr
})
] });
};
-q4.Bar = ZLe, q4.XAxis = QLe, q4.YAxis = $Le, q4.Grid = eRe, q4.Tooltip = tRe, q4.Legend = nRe, q4.Brush = B4;
+K4.Bar = $Le, K4.XAxis = eRe, K4.YAxis = tRe, K4.Grid = nRe, K4.Tooltip = rRe, K4.Legend = iRe, K4.Brush = z4;
//#endregion
//#region src/react/charts/chart-card.tsx
-var Y4 = `${Zi({ radius: "chart" })} flex flex-col gap-4 max-sm:p-4`;
-function X4({ title: e, figure: t, note: n }) {
+var J4 = `${Zi({ radius: "chart" })} flex flex-col gap-4 max-sm:p-4`;
+function Y4({ title: e, figure: t, note: n }) {
return /* @__PURE__ */ (0, z.jsxs)("header", {
className: "flex flex-wrap items-end justify-between gap-x-4 gap-y-1",
children: [/* @__PURE__ */ (0, z.jsxs)("span", {
@@ -70399,24 +70451,24 @@ function X4({ title: e, figure: t, note: n }) {
})]
});
}
-var Z4 = [
+var X4 = [
"var(--color-chart-1)",
"var(--color-chart-2)",
"var(--color-chart-3)",
"var(--color-chart-4)",
"var(--color-chart-5)",
"var(--color-chart-6)"
-], Q4 = (e) => ({ light: [e] }), $4 = (e) => `s${e}`;
-function vRe(e) {
- return Object.fromEntries(e.map((e, t) => [$4(t), {
+], Z4 = (e) => ({ light: [e] }), Q4 = (e) => `s${e}`;
+function bRe(e) {
+ return Object.fromEntries(e.map((e, t) => [Q4(t), {
label: e,
- colors: Q4(Z4[t % Z4.length])
+ colors: Z4(X4[t % X4.length])
}]));
}
//#endregion
//#region src/react/charts/chart-tip.tsx
-var e3 = "flex min-w-32 flex-col gap-1.5 rounded-lg border border-border/50 bg-background px-2.5 py-1.5 text-xs shadow-xl";
-function t3({ swatch: e, name: t, value: n }) {
+var $4 = "flex min-w-32 flex-col gap-1.5 rounded-lg border border-border/50 bg-background px-2.5 py-1.5 text-xs shadow-xl";
+function e3({ swatch: e, name: t, value: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex w-full items-center gap-2",
children: [e, /* @__PURE__ */ (0, z.jsxs)("div", {
@@ -70431,33 +70483,33 @@ function t3({ swatch: e, name: t, value: n }) {
})]
});
}
-var n3 = "size-2.5 shrink-0 rounded-xs";
-function yRe({ active: e, payload: t, label: n, nameKey: r, valueKey: i, hideLabel: a }) {
- let { config: o } = A4(), s = (t ?? []).filter((e) => e.type !== "none");
+var t3 = "size-2.5 shrink-0 rounded-xs";
+function xRe({ active: e, payload: t, label: n, nameKey: r, valueKey: i, hideLabel: a }) {
+ let { config: o } = k4(), s = (t ?? []).filter((e) => e.type !== "none");
if (!e || !s.length) return /* @__PURE__ */ (0, z.jsx)("span", { className: "p-4" });
let c = a || typeof n != "string" ? null : o[n]?.label ?? n;
return /* @__PURE__ */ (0, z.jsxs)("div", {
- className: e3,
+ className: $4,
children: [c ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "font-medium text-foreground",
children: c
}) : null, s.map((e, t) => {
- let n = e.payload ?? {}, a = `${(r ? n[r] : void 0) ?? e.name ?? e.dataKey ?? "value"}`, s = P4(o, e, a), c = i ? n[i] : e.value;
- return /* @__PURE__ */ (0, z.jsx)(t3, {
+ let n = e.payload ?? {}, a = `${(r ? n[r] : void 0) ?? e.name ?? e.dataKey ?? "value"}`, s = N4(o, e, a), c = i ? n[i] : e.value;
+ return /* @__PURE__ */ (0, z.jsx)(e3, {
name: s?.label ?? e.name,
value: Number(c ?? 0),
swatch: /* @__PURE__ */ (0, z.jsx)("i", {
- className: n3,
+ className: t3,
style: { background: `var(--color-${a}-0)` }
})
}, a + t);
})]
});
}
-function r3({ nameKey: e, valueKey: t, hideLabel: n }) {
- return /* @__PURE__ */ (0, z.jsx)(L4, {
+function n3({ nameKey: e, valueKey: t, hideLabel: n }) {
+ return /* @__PURE__ */ (0, z.jsx)(I4, {
cursor: !1,
- content: /* @__PURE__ */ (0, z.jsx)(yRe, {
+ content: /* @__PURE__ */ (0, z.jsx)(xRe, {
nameKey: e,
valueKey: t,
hideLabel: n
@@ -70466,12 +70518,12 @@ function r3({ nameKey: e, valueKey: t, hideLabel: n }) {
}
//#endregion
//#region src/react/charts/bar-card.tsx
-var i3 = [0, (e) => e * 1.2], a3 = (e) => ({
+var r3 = [0, (e) => e * 1.2], i3 = (e) => ({
position: e,
className: "fill-text-secondary",
formatter: (e) => Number(e).toLocaleString()
});
-function o3({ title: e, unit: t, series: n, rows: r, color: i, layout: a = "vertical" }) {
+function a3({ title: e, unit: t, series: n, rows: r, color: i, layout: a = "vertical" }) {
let o = r.filter((e) => Number.isFinite(e.value) && e.value >= 0).map((e) => ({
name: e.name,
value: e.value
@@ -70479,53 +70531,53 @@ function o3({ title: e, unit: t, series: n, rows: r, color: i, layout: a = "vert
if (!s) return null;
let c = a === "horizontal";
return /* @__PURE__ */ (0, z.jsxs)("section", {
- className: Y4,
+ className: J4,
"aria-label": e,
- children: [/* @__PURE__ */ (0, z.jsx)(X4, {
+ children: [/* @__PURE__ */ (0, z.jsx)(Y4, {
title: e,
figure: s.toLocaleString(),
note: t
- }), /* @__PURE__ */ (0, z.jsxs)(q4, {
+ }), /* @__PURE__ */ (0, z.jsxs)(K4, {
data: o,
config: { value: {
label: n,
- colors: Q4(i)
+ colors: Z4(i)
} },
layout: a,
barRadius: 4,
className: c ? "aspect-auto h-64 flex-none text-text-secondary" : "aspect-auto h-56 flex-none text-text-secondary",
children: [
- /* @__PURE__ */ (0, z.jsx)(q4.Grid, {}),
- c ? /* @__PURE__ */ (0, z.jsx)(q4.YAxis, {
+ /* @__PURE__ */ (0, z.jsx)(K4.Grid, {}),
+ c ? /* @__PURE__ */ (0, z.jsx)(K4.YAxis, {
dataKey: "name",
interval: 0
- }) : /* @__PURE__ */ (0, z.jsx)(q4.XAxis, {
+ }) : /* @__PURE__ */ (0, z.jsx)(K4.XAxis, {
dataKey: "name",
interval: 0
}),
- c ? /* @__PURE__ */ (0, z.jsx)(q4.XAxis, {
+ c ? /* @__PURE__ */ (0, z.jsx)(K4.XAxis, {
hide: !0,
- domain: i3
- }) : /* @__PURE__ */ (0, z.jsx)(q4.YAxis, {
+ domain: r3
+ }) : /* @__PURE__ */ (0, z.jsx)(K4.YAxis, {
hide: !0,
- domain: i3
+ domain: r3
}),
- /* @__PURE__ */ (0, z.jsx)(q4.Bar, {
+ /* @__PURE__ */ (0, z.jsx)(K4.Bar, {
dataKey: "value",
enableHoverHighlight: !0,
barProps: {
dataKey: "value",
- label: a3(c ? "right" : "top")
+ label: i3(c ? "right" : "top")
}
}),
- /* @__PURE__ */ (0, z.jsx)(r3, {})
+ /* @__PURE__ */ (0, z.jsx)(n3, {})
]
})]
});
}
//#endregion
//#region src/react/charts/heat.ts
-var s3 = [
+var o3 = [
"周一",
"周二",
"周三",
@@ -70533,8 +70585,8 @@ var s3 = [
"周五",
"周六",
"周日"
-], c3 = (e, t) => e ? Math.max(.12, e / t) : 0;
-function bRe(e) {
+], s3 = (e, t) => e ? Math.max(.12, e / t) : 0;
+function SRe(e) {
let t = Array.from({ length: 7 }, () => Array(24).fill(0));
for (let n of e?.hours || []) {
let { weekday: e, hour: r, count: i } = n;
@@ -70544,14 +70596,14 @@ function bRe(e) {
return {
cells: t.flatMap((e, t) => e.map((e, n) => ({
key: `${t}-${n}`,
- label: `${s3[t]} ${n}:00`,
+ label: `${o3[t]} ${n}:00`,
count: e,
- share: c3(e, r)
+ share: s3(e, r)
}))),
total: n.reduce((e, t) => e + t, 0)
};
}
-function xRe(e) {
+function CRe(e) {
let t = (e?.days || []).filter((e) => /^\d{4}-\d{2}-\d{2}$/.test(e.date) && Number.isFinite(e.count) && e.count >= 0).slice().sort((e, t) => e.date.localeCompare(t.date)), n = {
cells: [],
total: 0,
@@ -70569,7 +70621,7 @@ function xRe(e) {
key: r,
label: r,
count: s,
- share: c3(s, o)
+ share: s3(s, o)
};
});
return {
@@ -70581,7 +70633,7 @@ function xRe(e) {
}
//#endregion
//#region src/react/charts/heat-card.tsx
-var l3 = 14, u3 = 17, d3 = {
+var c3 = 14, l3 = 17, u3 = {
4: {
fill: "fill-chart-4",
dot: "bg-chart-4"
@@ -70590,42 +70642,42 @@ var l3 = 14, u3 = 17, d3 = {
fill: "fill-chart-5",
dot: "bg-chart-5"
}
-}, SRe = {
+}, wRe = {
start: "translate-x-0",
center: "-translate-x-1/2",
end: "-translate-x-full"
};
-function CRe({ cell: e, series: t, tone: n, left: r, top: i, anchor: a }) {
+function TRe({ cell: e, series: t, tone: n, left: r, top: i, anchor: a }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
"aria-hidden": !0,
style: {
left: `${r}%`,
top: `${i}%`
},
- className: `pointer-events-none absolute z-10 -mt-2 -translate-y-full ${e3} ${SRe[a]}`,
+ className: `pointer-events-none absolute z-10 -mt-2 -translate-y-full ${$4} ${wRe[a]}`,
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "font-medium text-foreground",
children: e.label
- }), /* @__PURE__ */ (0, z.jsx)(t3, {
+ }), /* @__PURE__ */ (0, z.jsx)(e3, {
name: t,
value: e.count,
- swatch: /* @__PURE__ */ (0, z.jsx)("i", { className: `${n3} ${d3[n].dot}` })
+ swatch: /* @__PURE__ */ (0, z.jsx)("i", { className: `${t3} ${u3[n].dot}` })
})]
});
}
-function f3({ title: e, words: t, cells: n, total: r, columns: i, rows: a, axis: o, footer: s, tone: c }) {
- let [l, u] = (0, R.useState)(-1), d = o ? 30 : 0, f = o ? 18 : 0, p = d + i * u3, m = f + a * u3, h = (e) => ({
- x: d + e % i * u3,
- y: f + Math.floor(e / i) * u3
- }), g = n[l], _ = g ? h(l) : null, v = _ ? (_.x + l3 / 2) / p : 0, y = v < .1 ? "start" : v > .9 ? "end" : "center", b = _ ? {
+function d3({ title: e, words: t, cells: n, total: r, columns: i, rows: a, axis: o, footer: s, tone: c }) {
+ let [l, u] = (0, R.useState)(-1), d = o ? 30 : 0, f = o ? 18 : 0, p = d + i * l3, m = f + a * l3, h = (e) => ({
+ x: d + e % i * l3,
+ y: f + Math.floor(e / i) * l3
+ }), g = n[l], _ = g ? h(l) : null, v = _ ? (_.x + c3 / 2) / p : 0, y = v < .1 ? "start" : v > .9 ? "end" : "center", b = _ ? {
start: _.x,
- center: _.x + l3 / 2,
- end: _.x + l3
+ center: _.x + c3 / 2,
+ end: _.x + c3
}[y] : 0;
return /* @__PURE__ */ (0, z.jsxs)("section", {
- className: Y4,
+ className: J4,
children: [
- /* @__PURE__ */ (0, z.jsx)(X4, {
+ /* @__PURE__ */ (0, z.jsx)(Y4, {
title: e,
figure: (g ? g.count : r).toLocaleString(),
note: g ? g.label : t.unit
@@ -70648,19 +70700,19 @@ function f3({ title: e, words: t, cells: n, total: r, columns: i, rows: a, axis:
"aria-label": `${e.label},${e.count} ${t.cellUnit}`,
x: r,
y: i,
- width: l3,
- height: l3,
+ width: c3,
+ height: c3,
rx: 3,
fillOpacity: e.share || 1,
opacity: l >= 0 && l !== n ? .4 : 1,
- className: e.share ? `outline-none transition-opacity duration-200 focus-visible:stroke-border-focus-ring ${d3[c].fill}` : "fill-chart-track outline-none transition-opacity duration-200 focus-visible:stroke-border-focus-ring",
+ className: e.share ? `outline-none transition-opacity duration-200 focus-visible:stroke-border-focus-ring ${u3[c].fill}` : "fill-chart-track outline-none transition-opacity duration-200 focus-visible:stroke-border-focus-ring",
onPointerEnter: () => u(n),
onFocus: () => u(n),
onBlur: () => u(-1)
}, e.key);
})]
})
- }), g && _ ? /* @__PURE__ */ (0, z.jsx)(CRe, {
+ }), g && _ ? /* @__PURE__ */ (0, z.jsx)(TRe, {
cell: g,
series: t.series,
tone: c,
@@ -70676,24 +70728,24 @@ function f3({ title: e, words: t, cells: n, total: r, columns: i, rows: a, axis:
]
});
}
-var wRe = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [s3.map((e, t) => /* @__PURE__ */ (0, z.jsx)("text", {
+var ERe = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [o3.map((e, t) => /* @__PURE__ */ (0, z.jsx)("text", {
x: 0,
- y: 18 + t * u3 + 7,
+ y: 18 + t * l3 + 7,
dominantBaseline: "middle",
className: "fill-text-secondary text-caption-1-regular",
children: e
}, e)), Array.from({ length: 24 }, (e, t) => t % 2 ? null : /* @__PURE__ */ (0, z.jsx)("text", {
- x: 30 + t * u3,
+ x: 30 + t * l3,
y: 8,
dominantBaseline: "middle",
className: "fill-text-secondary text-caption-1-regular",
children: t
}, t))] });
-function p3({ activity: e, title: t, dailyTitle: n, words: r, tone: i, empty: a }) {
- let o = bRe(e), s = xRe(e);
+function f3({ activity: e, title: t, dailyTitle: n, words: r, tone: i, empty: a }) {
+ let o = SRe(e), s = CRe(e);
return s.cells.length ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: "inline-grid w-full items-start gap-5 lg:grid-cols-2",
- children: [/* @__PURE__ */ (0, z.jsx)(f3, {
+ children: [/* @__PURE__ */ (0, z.jsx)(d3, {
title: t,
words: r,
tone: i,
@@ -70701,9 +70753,9 @@ function p3({ activity: e, title: t, dailyTitle: n, words: r, tone: i, empty: a
total: o.total,
columns: 24,
rows: 7,
- axis: wRe,
+ axis: ERe,
footer: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("span", { children: "星期 × 小时" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e?.timezone || "UTC+08:00" })] })
- }), /* @__PURE__ */ (0, z.jsx)(f3, {
+ }), /* @__PURE__ */ (0, z.jsx)(d3, {
title: n,
words: r,
tone: i,
@@ -70714,7 +70766,7 @@ function p3({ activity: e, title: t, dailyTitle: n, words: r, tone: i, empty: a
footer: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("span", { children: s.start }), /* @__PURE__ */ (0, z.jsx)("span", { children: s.end })] })
})]
}) : a ? /* @__PURE__ */ (0, z.jsxs)("section", {
- className: Y4,
+ className: J4,
children: [/* @__PURE__ */ (0, z.jsx)("h3", {
className: "text-title-2-medium text-text-primary",
children: t
@@ -70726,7 +70778,7 @@ function p3({ activity: e, title: t, dailyTitle: n, words: r, tone: i, empty: a
}
//#endregion
//#region src/react/components/expandable-ranking.tsx
-function m3({ children: e, className: t = "", previewCount: n = 10 }) {
+function p3({ children: e, className: t = "", previewCount: n = 10 }) {
let r = (0, R.useId)(), i = (0, R.useRef)(null), [a, o] = (0, R.useState)(!1), [s, c] = (0, R.useState)(!1), l = R.Children.toArray(e), u = l.length > n;
(0, R.useLayoutEffect)(() => {
let e = i.current;
@@ -70773,14 +70825,14 @@ function m3({ children: e, className: t = "", previewCount: n = 10 }) {
}
//#endregion
//#region src/react/evilcharts/registry/charts/recharts-radial-chart.tsx
-var TRe = "30%", ERe = "100%", h3 = 5, g3 = 14, DRe = 5, _3 = 1500, v3 = (0, R.createContext)(null);
-function y3() {
- let e = (0, R.use)(v3);
+var DRe = "30%", ORe = "100%", m3 = 5, h3 = 14, kRe = 5, g3 = 1500, _3 = (0, R.createContext)(null);
+function v3() {
+ let e = (0, R.use)(_3);
if (!e) throw Error("Radial chart parts (<RadialBar />, <Tooltip />, …) must be used within <EvilRadialChart />");
return e;
}
-function b3({ config: e, data: t, nameKey: n, children: r, className: i, chartProps: a, variant: o = "full", max: s, innerRadius: c = TRe, outerRadius: l = ERe, defaultSelectedDataKey: u = null, onSelectionChange: d, isLoading: f = !1, backgroundVariant: p }) {
- let m = (0, R.useId)().replace(/:/g, ""), [h, g] = (0, R.useState)(u), _ = PRe(f), v = jRe(o), y = (0, R.useCallback)((e, t) => {
+function y3({ config: e, data: t, nameKey: n, children: r, className: i, chartProps: a, variant: o = "full", max: s, innerRadius: c = DRe, outerRadius: l = ORe, defaultSelectedDataKey: u = null, onSelectionChange: d, isLoading: f = !1, backgroundVariant: p }) {
+ let m = (0, R.useId)().replace(/:/g, ""), [h, g] = (0, R.useState)(u), _ = IRe(f), v = NRe(o), y = (0, R.useCallback)((e, t) => {
g(e), d?.(e === null ? null : {
dataKey: e,
value: t ?? 0
@@ -70807,12 +70859,12 @@ function b3({ config: e, data: t, nameKey: n, children: r, className: i, chartPr
h,
y
]);
- return /* @__PURE__ */ (0, z.jsx)(v3, {
+ return /* @__PURE__ */ (0, z.jsx)(_3, {
value: x,
- children: /* @__PURE__ */ (0, z.jsxs)(j4, {
+ children: /* @__PURE__ */ (0, z.jsxs)(A4, {
className: i,
config: e,
- children: [/* @__PURE__ */ (0, z.jsx)(M4, { isLoading: f }), /* @__PURE__ */ (0, z.jsxs)(ALe, {
+ children: [/* @__PURE__ */ (0, z.jsx)(j4, { isLoading: f }), /* @__PURE__ */ (0, z.jsxs)(MLe, {
id: m,
data: f ? _ : b,
innerRadius: c,
@@ -70823,16 +70875,16 @@ function b3({ config: e, data: t, nameKey: n, children: r, className: i, chartPr
cy: v.cy,
...a,
children: [
- s != null && s > 0 && /* @__PURE__ */ (0, z.jsx)(C$, {
+ s != null && s > 0 && /* @__PURE__ */ (0, z.jsx)(S$, {
type: "number",
domain: [0, s],
tick: !1,
axisLine: !1
}),
- p && /* @__PURE__ */ (0, z.jsx)(U4, { variant: p }),
+ p && /* @__PURE__ */ (0, z.jsx)(H4, { variant: p }),
r,
- f && /* @__PURE__ */ (0, z.jsx)(FRe, {}),
- /* @__PURE__ */ (0, z.jsx)("defs", { children: /* @__PURE__ */ (0, z.jsx)(MRe, {
+ f && /* @__PURE__ */ (0, z.jsx)(LRe, {}),
+ /* @__PURE__ */ (0, z.jsx)("defs", { children: /* @__PURE__ */ (0, z.jsx)(PRe, {
config: e,
chartId: m
}) })
@@ -70841,9 +70893,9 @@ function b3({ config: e, data: t, nameKey: n, children: r, className: i, chartPr
})
});
}
-function ORe({ dataKey: e, cornerRadius: t = h3, barSize: n = g3, showBackground: r = !0, isClickable: i = !1, radialBarProps: a }) {
- let { nameKey: o, isLoading: s, selectedBar: c, selectBar: l } = y3();
- return s ? null : /* @__PURE__ */ (0, z.jsx)(K1, {
+function ARe({ dataKey: e, cornerRadius: t = m3, barSize: n = h3, showBackground: r = !0, isClickable: i = !1, radialBarProps: a }) {
+ let { nameKey: o, isLoading: s, selectedBar: c, selectBar: l } = v3();
+ return s ? null : /* @__PURE__ */ (0, z.jsx)(G1, {
dataKey: e,
cornerRadius: t,
barSize: n,
@@ -70866,12 +70918,12 @@ function ORe({ dataKey: e, cornerRadius: t = h3, barSize: n = g3, showBackground
...a
});
}
-function kRe({ variant: e, roundness: t, defaultIndex: n }) {
- let { nameKey: r, isLoading: i } = y3();
- return i ? null : /* @__PURE__ */ (0, z.jsx)(L4, {
+function jRe({ variant: e, roundness: t, defaultIndex: n }) {
+ let { nameKey: r, isLoading: i } = v3();
+ return i ? null : /* @__PURE__ */ (0, z.jsx)(I4, {
defaultIndex: n,
cursor: !1,
- content: /* @__PURE__ */ (0, z.jsx)(I4, {
+ content: /* @__PURE__ */ (0, z.jsx)(F4, {
nameKey: r,
hideLabel: !0,
roundness: t,
@@ -70879,12 +70931,12 @@ function kRe({ variant: e, roundness: t, defaultIndex: n }) {
})
});
}
-function ARe({ variant: e, align: t = "center", verticalAlign: n = "bottom", isClickable: r = !1 }) {
- let { nameKey: i, isLoading: a, selectedBar: o, selectBar: s } = y3();
- return a ? null : /* @__PURE__ */ (0, z.jsx)(z4, {
+function MRe({ variant: e, align: t = "center", verticalAlign: n = "bottom", isClickable: r = !1 }) {
+ let { nameKey: i, isLoading: a, selectedBar: o, selectBar: s } = v3();
+ return a ? null : /* @__PURE__ */ (0, z.jsx)(R4, {
verticalAlign: n,
align: t,
- content: /* @__PURE__ */ (0, z.jsx)(R4, {
+ content: /* @__PURE__ */ (0, z.jsx)(L4, {
selected: o,
onSelectChange: s,
isClickable: r,
@@ -70893,7 +70945,7 @@ function ARe({ variant: e, align: t = "center", verticalAlign: n = "bottom", isC
})
});
}
-function jRe(e) {
+function NRe(e) {
switch (e) {
case "semi": return {
startAngle: 180,
@@ -70909,8 +70961,8 @@ function jRe(e) {
};
}
}
-var MRe = ({ config: e, chartId: t }) => /* @__PURE__ */ (0, z.jsx)(z.Fragment, { children: Object.entries(e).map(([e, n]) => {
- let r = F4(n);
+var PRe = ({ config: e, chartId: t }) => /* @__PURE__ */ (0, z.jsx)(z.Fragment, { children: Object.entries(e).map(([e, n]) => {
+ let r = P4(n);
return /* @__PURE__ */ (0, z.jsx)("linearGradient", {
id: `${t}-radial-colors-${e}`,
x1: "0",
@@ -70932,29 +70984,29 @@ var MRe = ({ config: e, chartId: t }) => /* @__PURE__ */ (0, z.jsx)(z.Fragment,
})
}, `${t}-radial-colors-${e}`);
}) });
-function NRe() {
- return Array.from({ length: DRe }, (e, t) => ({
+function FRe() {
+ return Array.from({ length: kRe }, (e, t) => ({
name: `loading${t}`,
value: 40 + Math.random() * 60
}));
}
-function PRe(e) {
+function IRe(e) {
let [t, n] = (0, R.useState)(0);
return (0, R.useEffect)(() => {
if (!e) return;
let t = setInterval(() => {
n((e) => e + 1);
- }, _3);
+ }, g3);
return () => clearInterval(t);
- }, [e]), (0, R.useMemo)(() => NRe(), [t]);
+ }, [e]), (0, R.useMemo)(() => FRe(), [t]);
}
-var FRe = () => /* @__PURE__ */ (0, z.jsx)(K1, {
+var LRe = () => /* @__PURE__ */ (0, z.jsx)(G1, {
dataKey: "value",
- cornerRadius: h3,
- barSize: g3,
+ cornerRadius: m3,
+ barSize: h3,
background: !0,
isAnimationActive: !0,
- animationDuration: _3,
+ animationDuration: g3,
animationEasing: "ease-in-out",
shape: (e) => /* @__PURE__ */ (0, z.jsx)(LW, {
...e,
@@ -70962,17 +71014,17 @@ var FRe = () => /* @__PURE__ */ (0, z.jsx)(K1, {
fillOpacity: .25
})
});
-b3.RadialBar = ORe, b3.Tooltip = kRe, b3.Legend = ARe;
+y3.RadialBar = ARe, y3.Tooltip = jRe, y3.Legend = MRe;
//#endregion
//#region src/react/stats/radial-card.tsx
-var IRe = [
+var RRe = [
"bg-chart-1",
"bg-chart-2",
"bg-chart-3",
"bg-chart-4",
"bg-chart-5",
"bg-chart-6"
-], LRe = [
+], zRe = [
"aria-pressed:bg-chart-1/10 aria-pressed:ring-chart-1",
"aria-pressed:bg-chart-2/10 aria-pressed:ring-chart-2",
"aria-pressed:bg-chart-3/10 aria-pressed:ring-chart-3",
@@ -70980,15 +71032,15 @@ var IRe = [
"aria-pressed:bg-chart-5/10 aria-pressed:ring-chart-5",
"aria-pressed:bg-chart-6/10 aria-pressed:ring-chart-6"
];
-function x3({ title: e, rows: t, unit: n = "个视频" }) {
+function b3({ title: e, rows: t, unit: n = "个视频" }) {
let [r, i] = (0, R.useState)(-1), [a, o] = (0, R.useState)(-1), s = t.filter((e) => Number.isFinite(e.value) && e.value >= 0);
if (!s.length) return null;
let c = a >= 0 ? a : r, l = s.reduce((e, t) => e + t.value, 0), u = s[c], d = (e) => i((t) => t === e ? -1 : e), f = s.map((e, t) => ({
- slice: $4(t),
+ slice: Q4(t),
value: e.value
}));
return /* @__PURE__ */ (0, z.jsxs)("section", {
- className: Y4,
+ className: J4,
children: [
/* @__PURE__ */ (0, z.jsxs)("header", {
className: "flex flex-wrap items-end justify-between gap-x-4 gap-y-1",
@@ -71010,14 +71062,14 @@ function x3({ title: e, rows: t, unit: n = "个视频" }) {
role: "img",
"aria-label": e,
onPointerLeave: () => o(-1),
- children: /* @__PURE__ */ (0, z.jsxs)(b3, {
+ children: /* @__PURE__ */ (0, z.jsxs)(y3, {
data: f,
nameKey: "slice",
- config: vRe(s.map((e) => e.name)),
+ config: bRe(s.map((e) => e.name)),
max: x_e(s.map((e) => e.value)),
innerRadius: "22%",
className: "aspect-auto h-75 max-sm:h-65",
- children: [/* @__PURE__ */ (0, z.jsx)(b3.RadialBar, {
+ children: [/* @__PURE__ */ (0, z.jsx)(y3.RadialBar, {
dataKey: "value",
barSize: S_e(s.length),
radialBarProps: {
@@ -71029,7 +71081,7 @@ function x3({ title: e, rows: t, unit: n = "个视频" }) {
onClick: (e, t) => d(t),
onMouseEnter: (e, t) => o(t)
}
- }), /* @__PURE__ */ (0, z.jsx)(r3, {
+ }), /* @__PURE__ */ (0, z.jsx)(n3, {
nameKey: "slice",
hideLabel: !0
})]
@@ -71045,13 +71097,13 @@ function x3({ title: e, rows: t, unit: n = "个视频" }) {
onPointerLeave: () => o(-1),
onFocus: () => o(t),
onBlur: () => o(-1),
- className: `flex min-w-0 cursor-pointer flex-col items-start gap-1 rounded-xl bg-background-tertiary-default p-2.5 text-left outline-none aria-pressed:ring-1 aria-pressed:ring-inset focus-visible:ring-2 focus-visible:ring-border-focus-ring ${LRe[t % 6]}`,
+ className: `flex min-w-0 cursor-pointer flex-col items-start gap-1 rounded-xl bg-background-tertiary-default p-2.5 text-left outline-none aria-pressed:ring-1 aria-pressed:ring-inset focus-visible:ring-2 focus-visible:ring-border-focus-ring ${zRe[t % 6]}`,
children: [
/* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 items-center gap-1.5 text-caption-1-regular text-text-secondary",
children: [/* @__PURE__ */ (0, z.jsx)("i", {
"aria-hidden": !0,
- className: `size-3 shrink-0 rounded-sm ${IRe[t % 6]}`
+ className: `size-3 shrink-0 rounded-sm ${RRe[t % 6]}`
}), e.name]
}),
/* @__PURE__ */ (0, z.jsx)("b", {
@@ -71070,8 +71122,8 @@ function x3({ title: e, rows: t, unit: n = "个视频" }) {
}
//#endregion
//#region src/react/stats/stats-page.tsx
-var RRe = 10, S3 = Z4[5], zRe = Z4[4], BRe = `${Zi()} flex flex-col gap-4`, VRe = "添加媒体文件夹或关注来源后,这里会显示馆藏统计。", HRe = "补全资料或添加标签后,这里会显示馆藏中的内容标签。", URe = "开始播放后,这里会显示最近的真实观看证据。", WRe = "刮削或手动打标之后,这里会显示每个来源覆盖了多少视频。", GRe = "添加媒体文件夹后,这里会显示存储空间。";
-function C3({ term: e, value: t }) {
+var BRe = 10, x3 = X4[5], VRe = X4[4], HRe = `${Zi()} flex flex-col gap-4`, URe = "添加媒体文件夹或关注来源后,这里会显示馆藏统计。", WRe = "补全资料或添加标签后,这里会显示馆藏中的内容标签。", GRe = "开始播放后,这里会显示最近的真实观看证据。", KRe = "刮削或手动打标之后,这里会显示每个来源覆盖了多少视频。", qRe = "添加媒体文件夹后,这里会显示存储空间。";
+function S3({ term: e, value: t }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-h-16 min-w-0 flex-col gap-1.5 rounded-2lg bg-background-primary-default p-3",
children: [/* @__PURE__ */ (0, z.jsx)("span", {
@@ -71083,7 +71135,7 @@ function C3({ term: e, value: t }) {
})]
});
}
-function w3({ term: e, value: t, total: n }) {
+function C3({ term: e, value: t, total: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-1.5 border-b border-separator-border py-3 last:border-b-0",
children: [/* @__PURE__ */ (0, z.jsxs)("p", {
@@ -71092,7 +71144,7 @@ function w3({ term: e, value: t, total: n }) {
className: "tabular-nums",
children: [t.toLocaleString(), /* @__PURE__ */ (0, z.jsxs)("span", {
className: "ml-1.5 text-caption-1-regular text-text-secondary",
- children: [dI(t, n), "%"]
+ children: [fI(t, n), "%"]
})]
})]
}), /* @__PURE__ */ (0, z.jsx)(ia, {
@@ -71102,7 +71154,7 @@ function w3({ term: e, value: t, total: n }) {
})]
});
}
-function T3({ term: e, figure: t, unit: n }) {
+function w3({ term: e, figure: t, unit: n }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex shrink-0 flex-col gap-0.5 pb-5 md:w-64 md:pr-6 md:pb-0",
children: [
@@ -71121,28 +71173,28 @@ function T3({ term: e, figure: t, unit: n }) {
]
});
}
-function E3({ headline: e, children: t }) {
+function T3({ headline: e, children: t }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
- className: `${BRe} md:flex-row md:gap-6`,
+ className: `${HRe} md:flex-row md:gap-6`,
children: [e, /* @__PURE__ */ (0, z.jsx)("div", {
className: "min-w-0 grow",
children: t
})]
});
}
-function KRe({ data: t, configurable: n, openMediaSettings: r }) {
+function JRe({ data: t, configurable: n, openMediaSettings: r }) {
return t.by_loc.reduce((e, t) => e + t.videos, 0) ? /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-5",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "inline-grid w-full gap-5 md:grid-cols-2",
- children: [/* @__PURE__ */ (0, z.jsx)(x3, {
+ children: [/* @__PURE__ */ (0, z.jsx)(b3, {
title: "网盘与本地",
rows: t.by_loc.map((t) => ({
name: e[t.k] ?? t.k,
value: t.videos,
detail: s(t.bytes)
}))
- }), /* @__PURE__ */ (0, z.jsx)(x3, {
+ }), /* @__PURE__ */ (0, z.jsx)(b3, {
title: "媒体库",
rows: t.by_library.map((e) => ({
name: e.name,
@@ -71153,25 +71205,25 @@ function KRe({ data: t, configurable: n, openMediaSettings: r }) {
}), /* @__PURE__ */ (0, z.jsxs)("div", {
className: "inline-grid w-full gap-5 md:grid-cols-2 xl:grid-cols-3",
children: [
- /* @__PURE__ */ (0, z.jsx)(o3, {
+ /* @__PURE__ */ (0, z.jsx)(a3, {
title: "时长",
unit: "个视频",
series: "视频",
- color: S3,
+ color: x3,
rows: E_e(t.by_length)
}),
- /* @__PURE__ */ (0, z.jsx)(o3, {
+ /* @__PURE__ */ (0, z.jsx)(a3, {
title: "画质",
unit: "个视频",
series: "视频",
- color: S3,
- rows: mI(t.by_quality)
+ color: x3,
+ rows: hI(t.by_quality)
}),
- /* @__PURE__ */ (0, z.jsx)(o3, {
+ /* @__PURE__ */ (0, z.jsx)(a3, {
title: "文件类型",
unit: "个条目",
series: "条目",
- color: S3,
+ color: x3,
layout: "horizontal",
rows: w_e(t.by_medium)
})
@@ -71191,11 +71243,11 @@ function KRe({ data: t, configurable: n, openMediaSettings: r }) {
size: "small",
children: "添加关注"
})] }),
- children: VRe
+ children: URe
});
}
-function qRe({ data: e }) {
- return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(p3, {
+function YRe({ data: e }) {
+ return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(f3, {
activity: e.play_activity,
title: "播放时间",
dailyTitle: "每日播放",
@@ -71205,40 +71257,40 @@ function qRe({ data: e }) {
cellUnit: "个作品"
},
tone: 5
- }), /* @__PURE__ */ (0, z.jsx)(o3, {
+ }), /* @__PURE__ */ (0, z.jsx)(a3, {
title: "播放次数",
unit: "个作品",
series: "作品",
- color: zRe,
+ color: VRe,
rows: O_e(e.replays)
})] });
}
-function JRe({ attribution: e }) {
+function XRe({ attribution: e }) {
let t = e.videos;
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col",
children: [
- /* @__PURE__ */ (0, z.jsx)(w3, {
+ /* @__PURE__ */ (0, z.jsx)(C3, {
term: "有创作者",
value: e.creator,
total: t
}),
- /* @__PURE__ */ (0, z.jsx)(w3, {
+ /* @__PURE__ */ (0, z.jsx)(C3, {
term: "有番号",
value: e.code,
total: t
}),
- /* @__PURE__ */ (0, z.jsx)(w3, {
+ /* @__PURE__ */ (0, z.jsx)(C3, {
term: "有厂牌",
value: e.studio,
total: t
}),
- /* @__PURE__ */ (0, z.jsx)(w3, {
+ /* @__PURE__ */ (0, z.jsx)(C3, {
term: "已抽帧",
value: e.thumb,
total: t
}),
- /* @__PURE__ */ (0, z.jsx)(w3, {
+ /* @__PURE__ */ (0, z.jsx)(C3, {
term: "已探测时长",
value: e.duration,
total: t
@@ -71246,7 +71298,7 @@ function JRe({ attribution: e }) {
]
});
}
-function YRe({ volume: e }) {
+function ZRe({ volume: e }) {
let t = e.total, n = e.used ?? 0;
return /* @__PURE__ */ (0, z.jsxs)("article", {
className: "flex min-w-0 flex-col gap-1.5 border-b border-separator-border py-3 last:border-b-0",
@@ -71263,7 +71315,7 @@ function YRe({ volume: e }) {
className: "whitespace-nowrap tabular-nums",
children: [s(n), /* @__PURE__ */ (0, z.jsxs)("span", {
className: "ml-1.5 text-caption-1-regular text-text-secondary",
- children: [dI(n, t), "%"]
+ children: [fI(n, t), "%"]
})]
})]
}),
@@ -71285,10 +71337,10 @@ function YRe({ volume: e }) {
]
});
}
-function XRe({ volumes: e, configurable: t, openMediaSettings: n }) {
+function QRe({ volumes: e, configurable: t, openMediaSettings: n }) {
return e.length ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "flex flex-col",
- children: e.map((e) => /* @__PURE__ */ (0, z.jsx)(YRe, { volume: e }, `${e.kind}:${e.label}`))
+ children: e.map((e) => /* @__PURE__ */ (0, z.jsx)(ZRe, { volume: e }, `${e.kind}:${e.label}`))
}) : /* @__PURE__ */ (0, z.jsx)($i, {
shell: "plain",
icon: at,
@@ -71298,12 +71350,12 @@ function XRe({ volumes: e, configurable: t, openMediaSettings: n }) {
onClick: n,
children: "添加媒体文件夹"
}) : void 0,
- children: GRe
+ children: qRe
});
}
-function ZRe({ tags: e, tagLabel: t, onTag: n }) {
- return e.length ? /* @__PURE__ */ (0, z.jsx)(m3, {
- previewCount: RRe,
+function $Re({ tags: e, tagLabel: t, onTag: n }) {
+ return e.length ? /* @__PURE__ */ (0, z.jsx)(p3, {
+ previewCount: BRe,
className: "inline-grid w-full gap-x-6 gap-y-1 sm:grid-cols-2",
children: e.map((e, r) => /* @__PURE__ */ (0, z.jsx)("li", {
className: "min-w-0",
@@ -71337,14 +71389,14 @@ function ZRe({ tags: e, tagLabel: t, onTag: n }) {
size: "small",
children: "补全资料"
}),
- children: HRe
+ children: WRe
});
}
-function QRe({ rows: e }) {
+function eze({ rows: e }) {
return e.length ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "flex flex-col gap-5",
children: e.map((e) => {
- let t = fI(e);
+ let t = pI(e);
return /* @__PURE__ */ (0, z.jsxs)("article", {
className: "flex flex-wrap items-center gap-x-6 gap-y-2",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
@@ -71368,7 +71420,7 @@ function QRe({ rows: e }) {
value: t
}), /* @__PURE__ */ (0, z.jsx)("small", {
className: "mt-1.5 block text-caption-1-regular text-text-secondary",
- children: `真实 ${t.toFixed(0)}% · 到达 ${pI(e).toFixed(0)}%`
+ children: `真实 ${t.toFixed(0)}% · 到达 ${mI(e).toFixed(0)}%`
})]
})]
}, `${e.kind}:${e.id}`);
@@ -71383,10 +71435,10 @@ function QRe({ rows: e }) {
size: "small",
children: "浏览馆藏"
}),
- children: URe
+ children: GRe
});
}
-function $Re({ sources: e, videos: t }) {
+function tze({ sources: e, videos: t }) {
return e.length ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "inline-grid w-full gap-x-8 gap-y-6 sm:grid-cols-2",
children: e.map((e) => /* @__PURE__ */ (0, z.jsxs)("article", {
@@ -71426,17 +71478,17 @@ function $Re({ sources: e, videos: t }) {
size: "small",
children: "补全资料"
}),
- children: WRe
+ children: KRe
});
}
-function D3({ id: e, label: t, figure: n, detail: r, icon: i, accent: a }) {
- return /* @__PURE__ */ (0, z.jsx)(ny, {
+function E3({ id: e, label: t, figure: n, detail: r, icon: i, accent: a }) {
+ return /* @__PURE__ */ (0, z.jsx)(sy, {
id: e,
- className: KS({
+ className: vS({
interactive: !0,
selectable: !0
}),
- children: /* @__PURE__ */ (0, z.jsx)(XS, {
+ children: /* @__PURE__ */ (0, z.jsx)(SS, {
label: t,
icon: i,
accent: a,
@@ -71445,31 +71497,31 @@ function D3({ id: e, label: t, figure: n, detail: r, icon: i, accent: a }) {
})
});
}
-function eze(e) {
+function nze(e) {
let t = $n({
- queryKey: lI,
- queryFn: ({ signal: e }) => uI(e)
+ queryKey: uI,
+ queryFn: ({ signal: e }) => dI(e)
}), n = t.data;
if (!n) return /* @__PURE__ */ (0, z.jsx)(ta, { children: /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
title: "馆藏统计读取失败",
children: t.error ? U(t.error) : "未取得统计数据,请刷新页面重试。"
}) });
- let r = n.consumption, i = n.storage_summary, a = n.by_loc.reduce((e, t) => e + t.videos, 0), o = n.by_loc.reduce((e, t) => e + t.bytes, 0), c = dI(n.tag_cov, n.attribution.videos);
+ let r = n.consumption, i = n.storage_summary, a = n.by_loc.reduce((e, t) => e + t.videos, 0), o = n.by_loc.reduce((e, t) => e + t.bytes, 0), c = fI(n.tag_cov, n.attribution.videos);
return /* @__PURE__ */ (0, z.jsxs)(ta, { children: [
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-caption-1-regular text-text-secondary",
children: `账本当前快照 · ${a.toLocaleString()} 个视频 · ${s(o)}`
}),
- /* @__PURE__ */ (0, z.jsxs)($v, {
+ /* @__PURE__ */ (0, z.jsxs)(ay, {
defaultSelectedKey: "inventory",
className: "flex flex-col gap-4",
children: [
- /* @__PURE__ */ (0, z.jsxs)(ty, {
+ /* @__PURE__ */ (0, z.jsxs)(oy, {
"aria-label": "统计视图",
- className: qS,
+ className: yS,
children: [
- /* @__PURE__ */ (0, z.jsx)(D3, {
+ /* @__PURE__ */ (0, z.jsx)(E3, {
id: "inventory",
label: "馆藏视频",
icon: Qe,
@@ -71477,7 +71529,7 @@ function eze(e) {
figure: a.toLocaleString(),
detail: s(o)
}),
- /* @__PURE__ */ (0, z.jsx)(D3, {
+ /* @__PURE__ */ (0, z.jsx)(E3, {
id: "viewing",
label: "看过",
icon: nt,
@@ -71485,7 +71537,7 @@ function eze(e) {
figure: r.played.toLocaleString(),
detail: v_e(r.play_seconds)
}),
- /* @__PURE__ */ (0, z.jsx)(D3, {
+ /* @__PURE__ */ (0, z.jsx)(E3, {
id: "coverage",
label: "内容标签",
icon: pt,
@@ -71493,7 +71545,7 @@ function eze(e) {
figure: `${c}%`,
detail: `${n.tag_cov.toLocaleString()} / ${n.attribution.videos.toLocaleString()}`
}),
- /* @__PURE__ */ (0, z.jsx)(D3, {
+ /* @__PURE__ */ (0, z.jsx)(E3, {
id: "storage",
label: "使用空间",
icon: at,
@@ -71503,18 +71555,18 @@ function eze(e) {
})
]
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "inventory",
- children: /* @__PURE__ */ (0, z.jsx)(KRe, {
+ children: /* @__PURE__ */ (0, z.jsx)(JRe, {
data: n,
...e
})
}),
- /* @__PURE__ */ (0, z.jsxs)(ry, {
+ /* @__PURE__ */ (0, z.jsxs)(cy, {
id: "viewing",
className: "flex flex-col gap-5",
- children: [/* @__PURE__ */ (0, z.jsx)(E3, {
- headline: /* @__PURE__ */ (0, z.jsx)(T3, {
+ children: [/* @__PURE__ */ (0, z.jsx)(T3, {
+ headline: /* @__PURE__ */ (0, z.jsx)(w3, {
term: "观看",
figure: r.played.toLocaleString(),
unit: "个作品有播放记录"
@@ -71522,62 +71574,62 @@ function eze(e) {
children: /* @__PURE__ */ (0, z.jsxs)("div", {
className: "inline-grid w-full gap-3 sm:grid-cols-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(C3, {
+ /* @__PURE__ */ (0, z.jsx)(S3, {
term: "馆藏观看",
value: r.library_played
}),
- /* @__PURE__ */ (0, z.jsx)(C3, {
+ /* @__PURE__ */ (0, z.jsx)(S3, {
term: "在线直接观看",
value: r.online_played
}),
- /* @__PURE__ */ (0, z.jsx)(C3, {
+ /* @__PURE__ */ (0, z.jsx)(S3, {
term: "高潮计数",
value: r.o_total
}),
- /* @__PURE__ */ (0, z.jsx)(C3, {
+ /* @__PURE__ */ (0, z.jsx)(S3, {
term: "快进扫过",
value: r.skimmed
}),
- /* @__PURE__ */ (0, z.jsx)(C3, {
+ /* @__PURE__ */ (0, z.jsx)(S3, {
term: "喜欢",
value: r.liked
}),
- /* @__PURE__ */ (0, z.jsx)(C3, {
+ /* @__PURE__ */ (0, z.jsx)(S3, {
term: "明确不喜欢",
value: r.dislike
}),
- /* @__PURE__ */ (0, z.jsx)(C3, {
+ /* @__PURE__ */ (0, z.jsx)(S3, {
term: "看过了",
value: r.seen
}),
- /* @__PURE__ */ (0, z.jsx)(C3, {
+ /* @__PURE__ */ (0, z.jsx)(S3, {
term: "回收站",
value: r.trash
})
]
})
- }), /* @__PURE__ */ (0, z.jsx)(qRe, { data: n })]
+ }), /* @__PURE__ */ (0, z.jsx)(YRe, { data: n })]
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "coverage",
- children: /* @__PURE__ */ (0, z.jsx)(E3, {
- headline: /* @__PURE__ */ (0, z.jsx)(T3, {
+ children: /* @__PURE__ */ (0, z.jsx)(T3, {
+ headline: /* @__PURE__ */ (0, z.jsx)(w3, {
term: "内容标签覆盖",
figure: `${c}%`,
unit: `${n.tag_cov.toLocaleString()} / ${n.attribution.videos.toLocaleString()}`
}),
- children: /* @__PURE__ */ (0, z.jsx)(JRe, { attribution: n.attribution })
+ children: /* @__PURE__ */ (0, z.jsx)(XRe, { attribution: n.attribution })
})
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "storage",
- children: /* @__PURE__ */ (0, z.jsx)(E3, {
- headline: /* @__PURE__ */ (0, z.jsx)(T3, {
+ children: /* @__PURE__ */ (0, z.jsx)(T3, {
+ headline: /* @__PURE__ */ (0, z.jsx)(w3, {
term: "使用空间",
figure: String(i.measured),
unit: "个卷已取得容量"
}),
- children: /* @__PURE__ */ (0, z.jsx)(XRe, {
+ children: /* @__PURE__ */ (0, z.jsx)(QRe, {
volumes: n.storage_volumes,
...e
})
@@ -71585,51 +71637,51 @@ function eze(e) {
})
]
}),
- /* @__PURE__ */ (0, z.jsxs)($v, {
+ /* @__PURE__ */ (0, z.jsxs)(ay, {
defaultSelectedKey: "tags",
className: `${Zi({ padding: "none" })} flex flex-col`,
children: [
/* @__PURE__ */ (0, z.jsx)("div", {
className: "px-4 pt-3",
- children: /* @__PURE__ */ (0, z.jsxs)(QO, {
+ children: /* @__PURE__ */ (0, z.jsxs)(WO, {
"aria-label": "统计维度",
- className: ek,
+ className: KO,
children: [
- /* @__PURE__ */ (0, z.jsx)(ny, {
+ /* @__PURE__ */ (0, z.jsx)(sy, {
id: "tags",
- className: tk,
+ className: qO,
children: "内容标签"
}),
- /* @__PURE__ */ (0, z.jsx)(ny, {
+ /* @__PURE__ */ (0, z.jsx)(sy, {
id: "recent",
- className: tk,
+ className: qO,
children: "最近看过"
}),
- /* @__PURE__ */ (0, z.jsx)(ny, {
+ /* @__PURE__ */ (0, z.jsx)(sy, {
id: "sources",
- className: tk,
+ className: qO,
children: "标签来源"
})
]
})
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "tags",
className: "px-4 pt-3.5 pb-4",
- children: /* @__PURE__ */ (0, z.jsx)(ZRe, {
+ children: /* @__PURE__ */ (0, z.jsx)($Re, {
tags: n.top_tags,
...e
})
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "recent",
className: "px-4 pt-3.5 pb-4",
- children: /* @__PURE__ */ (0, z.jsx)(QRe, { rows: n.recent })
+ children: /* @__PURE__ */ (0, z.jsx)(eze, { rows: n.recent })
}),
- /* @__PURE__ */ (0, z.jsx)(ry, {
+ /* @__PURE__ */ (0, z.jsx)(cy, {
id: "sources",
className: "px-4 pt-3.5 pb-4",
- children: /* @__PURE__ */ (0, z.jsx)($Re, {
+ children: /* @__PURE__ */ (0, z.jsx)(tze, {
sources: n.tag_source,
videos: n.attribution.videos
})
@@ -71640,66 +71692,66 @@ function eze(e) {
}
//#endregion
//#region node_modules/d3-sankey/src/align.js
-function tze(e, t) {
+function rze(e, t) {
return e.sourceLinks.length ? e.depth : t - 1;
}
//#endregion
//#region node_modules/d3-sankey/src/constant.js
-function O3(e) {
+function D3(e) {
return function() {
return e;
};
}
//#endregion
//#region node_modules/d3-sankey/src/sankey.js
+function O3(e, t) {
+ return A3(e.source, t.source) || e.index - t.index;
+}
function k3(e, t) {
- return j3(e.source, t.source) || e.index - t.index;
+ return A3(e.target, t.target) || e.index - t.index;
}
function A3(e, t) {
- return j3(e.target, t.target) || e.index - t.index;
-}
-function j3(e, t) {
return e.y0 - t.y0;
}
-function M3(e) {
+function j3(e) {
return e.value;
}
-function nze(e) {
+function ize(e) {
return e.index;
}
-function rze(e) {
+function aze(e) {
return e.nodes;
}
-function ize(e) {
+function oze(e) {
return e.links;
}
-function N3(e, t) {
+function M3(e, t) {
let n = e.get(t);
if (!n) throw Error("missing: " + t);
return n;
}
-function P3({ nodes: e }) {
+function N3({ nodes: e }) {
for (let t of e) {
let e = t.y0, n = e;
for (let n of t.sourceLinks) n.y0 = e + n.width / 2, e += n.width;
for (let e of t.targetLinks) e.y1 = n + e.width / 2, n += e.width;
}
}
-function aze() {
- let e = 0, t = 0, n = 1, r = 1, i = 24, a = 8, o, s = nze, c = tze, l, u, d = rze, f = ize, p = 6;
+function sze() {
+ let e = 0, t = 0, n = 1, r = 1, i = 24, a = 8, o, s = ize, c = rze, l, u, d = aze, f = oze, p = 6;
function m() {
let e = {
nodes: d.apply(null, arguments),
links: f.apply(null, arguments)
};
- return h(e), g(e), _(e), v(e), x(e), P3(e), e;
+ return h(e), g(e), _(e), v(e), x(e), N3(e), e;
}
m.update = function(e) {
- return P3(e), e;
+ return N3(e), e;
}, m.nodeId = function(e) {
- return arguments.length ? (s = typeof e == "function" ? e : O3(e), m) : s;
+ return arguments.length ? (s = typeof e == "function" ? e : D3(e), m) : s;
}, m.nodeAlign = function(e) {
- return arguments.length ? (c = typeof e == "function" ? e : O3(e), m) : c;
+ return arguments.length ? (c = typeof e == "function" ? e : D3(e), m) : c;
}, m.nodeSort = function(e) {
return arguments.length ? (l = e, m) : l;
}, m.nodeWidth = function(e) {
@@ -71707,9 +71759,9 @@ function aze() {
}, m.nodePadding = function(e) {
return arguments.length ? (a = o = +e, m) : a;
}, m.nodes = function(e) {
- return arguments.length ? (d = typeof e == "function" ? e : O3(e), m) : d;
+ return arguments.length ? (d = typeof e == "function" ? e : D3(e), m) : d;
}, m.links = function(e) {
- return arguments.length ? (f = typeof e == "function" ? e : O3(e), m) : f;
+ return arguments.length ? (f = typeof e == "function" ? e : D3(e), m) : f;
}, m.linkSort = function(e) {
return arguments.length ? (u = e, m) : u;
}, m.size = function(i) {
@@ -71725,12 +71777,12 @@ function aze() {
for (let [e, r] of t.entries()) {
r.index = e;
let { source: t, target: i } = r;
- typeof t != "object" && (t = r.source = N3(n, t)), typeof i != "object" && (i = r.target = N3(n, i)), t.sourceLinks.push(r), i.targetLinks.push(r);
+ typeof t != "object" && (t = r.source = M3(n, t)), typeof i != "object" && (i = r.target = M3(n, i)), t.sourceLinks.push(r), i.targetLinks.push(r);
}
if (u != null) for (let { sourceLinks: t, targetLinks: n } of e) t.sort(u), n.sort(u);
}
function g({ nodes: e }) {
- for (let t of e) t.value = t.fixedValue === void 0 ? Math.max(iK(t.sourceLinks, M3), iK(t.targetLinks, M3)) : t.fixedValue;
+ for (let t of e) t.value = t.fixedValue === void 0 ? Math.max(iK(t.sourceLinks, j3), iK(t.targetLinks, j3)) : t.fixedValue;
}
function _({ nodes: e }) {
let t = e.length, n = new Set(e), r = /* @__PURE__ */ new Set(), i = 0;
@@ -71764,7 +71816,7 @@ function aze() {
return o;
}
function b(e) {
- let n = tK(e, (e) => (r - t - (e.length - 1) * o) / iK(e, M3));
+ let n = tK(e, (e) => (r - t - (e.length - 1) * o) / iK(e, j3));
for (let i of e) {
let e = t;
for (let t of i) {
@@ -71800,7 +71852,7 @@ function aze() {
let i = (n / r - e.y0) * t;
e.y0 += i, e.y1 += i, D(e);
}
- l === void 0 && i.sort(j3), w(i, n);
+ l === void 0 && i.sort(A3), w(i, n);
}
}
function C(e, t, n) {
@@ -71816,7 +71868,7 @@ function aze() {
let i = (n / r - e.y0) * t;
e.y0 += i, e.y1 += i, D(e);
}
- l === void 0 && i.sort(j3), w(i, n);
+ l === void 0 && i.sort(A3), w(i, n);
}
}
function w(e, n) {
@@ -71837,12 +71889,12 @@ function aze() {
}
function D({ sourceLinks: e, targetLinks: t }) {
if (u === void 0) {
- for (let { source: { sourceLinks: e } } of t) e.sort(A3);
- for (let { target: { targetLinks: t } } of e) t.sort(k3);
+ for (let { source: { sourceLinks: e } } of t) e.sort(k3);
+ for (let { target: { targetLinks: t } } of e) t.sort(O3);
}
}
function O(e) {
- if (u === void 0) for (let { sourceLinks: t, targetLinks: n } of e) t.sort(A3), n.sort(k3);
+ if (u === void 0) for (let { sourceLinks: t, targetLinks: n } of e) t.sort(k3), n.sort(O3);
}
function k(e, t) {
let n = e.y0 - (e.sourceLinks.length - 1) * o / 2;
@@ -71872,15 +71924,15 @@ function aze() {
}
//#endregion
//#region node_modules/d3-path/src/path.js
-var F3 = Math.PI, I3 = 2 * F3, L3 = 1e-6, oze = I3 - L3;
-function R3() {
+var P3 = Math.PI, F3 = 2 * P3, I3 = 1e-6, cze = F3 - I3;
+function L3() {
this._x0 = this._y0 = this._x1 = this._y1 = null, this._ = "";
}
-function z3() {
- return new R3();
+function R3() {
+ return new L3();
}
-R3.prototype = z3.prototype = {
- constructor: R3,
+L3.prototype = R3.prototype = {
+ constructor: L3,
moveTo: function(e, t) {
this._ += "M" + (this._x0 = this._x1 = +e) + "," + (this._y0 = this._y1 = +t);
},
@@ -71901,11 +71953,11 @@ R3.prototype = z3.prototype = {
var a = this._x1, o = this._y1, s = n - e, c = r - t, l = a - e, u = o - t, d = l * l + u * u;
if (i < 0) throw Error("negative radius: " + i);
if (this._x1 === null) this._ += "M" + (this._x1 = e) + "," + (this._y1 = t);
- else if (d > L3) {
- if (!(Math.abs(u * s - c * l) > L3) || !i) this._ += "L" + (this._x1 = e) + "," + (this._y1 = t);
+ else if (d > I3) {
+ if (!(Math.abs(u * s - c * l) > I3) || !i) this._ += "L" + (this._x1 = e) + "," + (this._y1 = t);
else {
- var f = n - a, p = r - o, m = s * s + c * c, h = f * f + p * p, g = Math.sqrt(m), _ = Math.sqrt(d), v = i * Math.tan((F3 - Math.acos((m + d - h) / (2 * g * _))) / 2), y = v / _, b = v / g;
- Math.abs(y - 1) > L3 && (this._ += "L" + (e + y * l) + "," + (t + y * u)), this._ += "A" + i + "," + i + ",0,0," + +(u * f > l * p) + "," + (this._x1 = e + b * s) + "," + (this._y1 = t + b * c);
+ var f = n - a, p = r - o, m = s * s + c * c, h = f * f + p * p, g = Math.sqrt(m), _ = Math.sqrt(d), v = i * Math.tan((P3 - Math.acos((m + d - h) / (2 * g * _))) / 2), y = v / _, b = v / g;
+ Math.abs(y - 1) > I3 && (this._ += "L" + (e + y * l) + "," + (t + y * u)), this._ += "A" + i + "," + i + ",0,0," + +(u * f > l * p) + "," + (this._x1 = e + b * s) + "," + (this._y1 = t + b * c);
}
}
},
@@ -71913,7 +71965,7 @@ R3.prototype = z3.prototype = {
e = +e, t = +t, n = +n, a = !!a;
var o = n * Math.cos(r), s = n * Math.sin(r), c = e + o, l = t + s, u = 1 ^ a, d = a ? r - i : i - r;
if (n < 0) throw Error("negative radius: " + n);
- this._x1 === null ? this._ += "M" + c + "," + l : (Math.abs(this._x1 - c) > L3 || Math.abs(this._y1 - l) > L3) && (this._ += "L" + c + "," + l), n && (d < 0 && (d = d % I3 + I3), d > oze ? this._ += "A" + n + "," + n + ",0,1," + u + "," + (e - o) + "," + (t - s) + "A" + n + "," + n + ",0,1," + u + "," + (this._x1 = c) + "," + (this._y1 = l) : d > L3 && (this._ += "A" + n + "," + n + ",0," + +(d >= F3) + "," + u + "," + (this._x1 = e + n * Math.cos(i)) + "," + (this._y1 = t + n * Math.sin(i))));
+ this._x1 === null ? this._ += "M" + c + "," + l : (Math.abs(this._x1 - c) > I3 || Math.abs(this._y1 - l) > I3) && (this._ += "L" + c + "," + l), n && (d < 0 && (d = d % F3 + F3), d > cze ? this._ += "A" + n + "," + n + ",0,1," + u + "," + (e - o) + "," + (t - s) + "A" + n + "," + n + ",0,1," + u + "," + (this._x1 = c) + "," + (this._y1 = l) : d > I3 && (this._ += "A" + n + "," + n + ",0," + +(d >= P3) + "," + u + "," + (this._x1 = e + n * Math.cos(i)) + "," + (this._y1 = t + n * Math.sin(i))));
},
rect: function(e, t, n, r) {
this._ += "M" + (this._x0 = this._x1 = +e) + "," + (this._y0 = this._y1 = +t) + "h" + +n + "v" + +r + "h" + -n + "Z";
@@ -71924,90 +71976,90 @@ R3.prototype = z3.prototype = {
};
//#endregion
//#region node_modules/d3-shape/src/constant.js
-function B3(e) {
+function z3(e) {
return function() {
return e;
};
}
//#endregion
//#region node_modules/d3-shape/src/point.js
-function sze(e) {
+function lze(e) {
return e[0];
}
-function cze(e) {
+function uze(e) {
return e[1];
}
//#endregion
//#region node_modules/d3-shape/src/array.js
-var lze = Array.prototype.slice;
+var dze = Array.prototype.slice;
//#endregion
//#region node_modules/d3-shape/src/link/index.js
-function uze(e) {
+function fze(e) {
return e.source;
}
-function dze(e) {
+function pze(e) {
return e.target;
}
-function fze(e) {
- var t = uze, n = dze, r = sze, i = cze, a = null;
+function mze(e) {
+ var t = fze, n = pze, r = lze, i = uze, a = null;
function o() {
- var o, s = lze.call(arguments), c = t.apply(this, s), l = n.apply(this, s);
- if (a ||= o = z3(), e(a, +r.apply(this, (s[0] = c, s)), +i.apply(this, s), +r.apply(this, (s[0] = l, s)), +i.apply(this, s)), o) return a = null, o + "" || null;
+ var o, s = dze.call(arguments), c = t.apply(this, s), l = n.apply(this, s);
+ if (a ||= o = R3(), e(a, +r.apply(this, (s[0] = c, s)), +i.apply(this, s), +r.apply(this, (s[0] = l, s)), +i.apply(this, s)), o) return a = null, o + "" || null;
}
return o.source = function(e) {
return arguments.length ? (t = e, o) : t;
}, o.target = function(e) {
return arguments.length ? (n = e, o) : n;
}, o.x = function(e) {
- return arguments.length ? (r = typeof e == "function" ? e : B3(+e), o) : r;
+ return arguments.length ? (r = typeof e == "function" ? e : z3(+e), o) : r;
}, o.y = function(e) {
- return arguments.length ? (i = typeof e == "function" ? e : B3(+e), o) : i;
+ return arguments.length ? (i = typeof e == "function" ? e : z3(+e), o) : i;
}, o.context = function(e) {
return arguments.length ? (a = e ?? null, o) : a;
}, o;
}
-function pze(e, t, n, r, i) {
+function hze(e, t, n, r, i) {
e.moveTo(t, n), e.bezierCurveTo(t = (t + r) / 2, n, t, i, r, i);
}
-function mze() {
- return fze(pze);
+function gze() {
+ return mze(hze);
}
//#endregion
//#region node_modules/d3-sankey/src/sankeyLinkHorizontal.js
-function hze(e) {
+function _ze(e) {
return [e.source.x1, e.y0];
}
-function gze(e) {
+function vze(e) {
return [e.target.x0, e.y1];
}
-function _ze() {
- return mze().source(hze).target(gze);
+function yze() {
+ return gze().source(_ze).target(vze);
}
//#endregion
//#region src/react/taste/taste.ts
-var vze = "/api/taste", V3 = "/api/taste/refresh", yze = "/api/taste/import", bze = "/api/taste/source", H3 = (e) => ["taste", e], xze = ["taste", "refresh"], Sze = [
+var bze = "/api/taste", B3 = "/api/taste/refresh", xze = "/api/taste/import", Sze = "/api/taste/source", V3 = (e) => ["taste", e], Cze = ["taste", "refresh"], wze = [
["7d", "最近 7 天"],
["30d", "最近 30 天"],
["90d", "最近 90 天"],
["365d", "最近一年"],
["all", "全部时间"]
-], U3 = (e, t) => W(`${vze}?window=${e}`, t), Cze = (e) => W(V3, e);
-async function wze(e, t) {
+], H3 = (e, t) => W(`${bze}?window=${e}`, t), Tze = (e) => W(B3, e);
+async function Eze(e, t) {
await X.fetchQuery({
- queryKey: H3(e),
- queryFn: () => U3(e, t)
+ queryKey: V3(e),
+ queryFn: () => H3(e, t)
});
}
-var Tze = (e) => G(V3, {
+var Dze = (e) => G(B3, {
window: e,
background: !0
-}), Eze = (e, t) => G(bze, {
+}), Oze = (e, t) => G(Sze, {
operation: "remove",
source_key: e,
window: t
});
-async function Dze(e) {
- let t = await fetch(yze, {
+async function kze(e) {
+ let t = await fetch(xze, {
method: "POST",
credentials: "same-origin",
headers: {
@@ -72025,35 +72077,35 @@ async function Dze(e) {
}
return n;
}
-var Oze = 1e4, W3 = (e) => e ? new Date(e).toLocaleDateString("zh-CN") : "—", kze = (e) => e >= 3600 ? `${(e / 3600).toFixed(1)} 小时` : `${Math.round(e / 60)} 分钟`, Aze = (e) => Number(e.web_visits ?? e.score ?? e.visits ?? e.peach_items ?? 0);
-function jze(e) {
+var Aze = 1e4, U3 = (e) => e ? new Date(e).toLocaleDateString("zh-CN") : "—", jze = (e) => e >= 3600 ? `${(e / 3600).toFixed(1)} 小时` : `${Math.round(e / 60)} 分钟`, Mze = (e) => Number(e.web_visits ?? e.score ?? e.visits ?? e.peach_items ?? 0);
+function Nze(e) {
if (e.web_visits == null) return Number(e.score || e.visits || 0).toLocaleString();
let t = [];
return e.web_visits && t.push(`浏览 ${e.web_visits}`), e.peach_items && t.push(`Peach ${e.peach_items}`), t.join(" · ");
}
-function Mze(e) {
- let t = e.map(Aze), n = Math.max(1, ...t);
+function Pze(e) {
+ let t = e.map(Mze), n = Math.max(1, ...t);
return t.map((e) => Math.max(0, Math.min(100, e / n * 100)));
}
-var G3 = (e, t) => e.filter((e) => Number.isFinite(Number(e.score)) && Number(e.score) > 0).map((e) => ({
+var W3 = (e, t) => e.filter((e) => Number.isFinite(Number(e.score)) && Number(e.score) > 0).map((e) => ({
name: e.name,
value: Number(e.score)
})).sort((e, t) => t.value - e.value).slice(0, t);
-function Nze(e) {
- let t = G3(e, 6);
+function Fze(e) {
+ let t = W3(e, 6);
return t.length < 3 ? [] : t;
}
-var K3 = {
+var G3 = {
width: 720,
height: 435
-}, q3 = {
+}, K3 = {
source: 145,
target: 545
};
-function Pze(e = []) {
+function Ize(e = []) {
let t = e.filter((e) => e.source && e.target && Number.isFinite(e.value) && e.value > 0);
if (!t.length) return null;
- let n = [...new Set(t.map((e) => e.source))], r = [...new Set(t.map((e) => e.target))], i = aze().nodeId((e) => e.id).nodeWidth(10).nodePadding(22).extent([[155, 16], [535, 404]])({
+ let n = [...new Set(t.map((e) => e.source))], r = [...new Set(t.map((e) => e.target))], i = sze().nodeId((e) => e.id).nodeWidth(10).nodePadding(22).extent([[155, 16], [535, 404]])({
nodes: [...n.map((e) => ({
id: `source:${e}`,
name: e,
@@ -72068,7 +72120,7 @@ function Pze(e = []) {
target: `target:${e.target}`,
value: e.value
}))
- }), a = t.reduce((e, t) => e + t.value, 0), o = _ze();
+ }), a = t.reduce((e, t) => e + t.value, 0), o = yze();
return {
nodes: i.nodes.map((e) => ({
id: e.id,
@@ -72098,11 +72150,11 @@ function Pze(e = []) {
total: a
};
}
-var Fze = (e) => e.length > 18 ? `${e.slice(0, 16)}…` : e, J3 = R.memo(function({ cx: e, cy: t, dataKey: n, chartId: r, className: i, fillOpacity: a = 1, type: o = "default", maskId: s }) {
+var Lze = (e) => e.length > 18 ? `${e.slice(0, 16)}…` : e, q3 = R.memo(function({ cx: e, cy: t, dataKey: n, chartId: r, className: i, fillOpacity: a = 1, type: o = "default", maskId: s }) {
let c = R.useId().replace(/:/g, ""), l = `url(#${r}-colors-${String(n)})`;
if (e === void 0 || t === void 0) return null;
switch (o) {
- case "border": return /* @__PURE__ */ (0, z.jsx)(X3, {
+ case "border": return /* @__PURE__ */ (0, z.jsx)(Y3, {
cx: e,
cy: t,
dotId: c,
@@ -72111,7 +72163,7 @@ var Fze = (e) => e.length > 18 ? `${e.slice(0, 16)}…` : e, J3 = R.memo(functio
className: i,
maskId: s
});
- case "colored-border": return /* @__PURE__ */ (0, z.jsx)(Z3, {
+ case "colored-border": return /* @__PURE__ */ (0, z.jsx)(X3, {
cx: e,
cy: t,
dotId: c,
@@ -72120,7 +72172,7 @@ var Fze = (e) => e.length > 18 ? `${e.slice(0, 16)}…` : e, J3 = R.memo(functio
className: i,
maskId: s
});
- default: return /* @__PURE__ */ (0, z.jsx)(Y3, {
+ default: return /* @__PURE__ */ (0, z.jsx)(J3, {
cx: e,
cy: t,
dotId: c,
@@ -72130,7 +72182,7 @@ var Fze = (e) => e.length > 18 ? `${e.slice(0, 16)}…` : e, J3 = R.memo(functio
maskId: s
});
}
-}), Y3 = R.memo(({ cx: e, cy: t, dotId: n, fillOpacity: r, gradientUrl: i, className: a, maskId: o }) => /* @__PURE__ */ (0, z.jsxs)("g", {
+}), J3 = R.memo(({ cx: e, cy: t, dotId: n, fillOpacity: r, gradientUrl: i, className: a, maskId: o }) => /* @__PURE__ */ (0, z.jsxs)("g", {
className: a,
mask: o ? `url(#${o})` : void 0,
children: [/* @__PURE__ */ (0, z.jsx)("defs", { children: /* @__PURE__ */ (0, z.jsx)("clipPath", {
@@ -72150,9 +72202,9 @@ var Fze = (e) => e.length > 18 ? `${e.slice(0, 16)}…` : e, J3 = R.memo(functio
clipPath: `url(#dot-clip-${n})`
})]
}));
-Y3.displayName = "DefaultDot";
-var X3 = R.memo(({ cx: e, cy: t, dotId: n, fillOpacity: r, gradientUrl: i, className: a, maskId: o }) => /* @__PURE__ */ (0, z.jsxs)("g", {
- className: E4(a, "text-background"),
+J3.displayName = "DefaultDot";
+var Y3 = R.memo(({ cx: e, cy: t, dotId: n, fillOpacity: r, gradientUrl: i, className: a, maskId: o }) => /* @__PURE__ */ (0, z.jsxs)("g", {
+ className: T4(a, "text-background"),
mask: o ? `url(#${o})` : void 0,
children: [
/* @__PURE__ */ (0, z.jsx)("defs", { children: /* @__PURE__ */ (0, z.jsx)("clipPath", {
@@ -72188,9 +72240,9 @@ var X3 = R.memo(({ cx: e, cy: t, dotId: n, fillOpacity: r, gradientUrl: i, class
}) })
]
}));
-X3.displayName = "PrimaryBorderDot";
-var Z3 = R.memo(({ cx: e, cy: t, dotId: n, fillOpacity: r, gradientUrl: i, className: a, maskId: o }) => /* @__PURE__ */ (0, z.jsxs)("g", {
- className: E4(a, "text-background"),
+Y3.displayName = "PrimaryBorderDot";
+var X3 = R.memo(({ cx: e, cy: t, dotId: n, fillOpacity: r, gradientUrl: i, className: a, maskId: o }) => /* @__PURE__ */ (0, z.jsxs)("g", {
+ className: T4(a, "text-background"),
mask: o ? `url(#${o})` : void 0,
children: [
/* @__PURE__ */ (0, z.jsx)("defs", { children: /* @__PURE__ */ (0, z.jsx)("clipPath", {
@@ -72218,17 +72270,17 @@ var Z3 = R.memo(({ cx: e, cy: t, dotId: n, fillOpacity: r, gradientUrl: i, class
})
]
}));
-Z3.displayName = "ColoredBorderDot";
+X3.displayName = "ColoredBorderDot";
//#endregion
//#region src/react/evilcharts/registry/charts/recharts-radar-chart.tsx
-var Ize = 1, Lze = .3, Rze = 6, Q3 = 1500, $3 = "value", e6 = (0, R.createContext)(null);
-function t6() {
- let e = (0, R.use)(e6);
+var Rze = 1, zze = .3, Bze = 6, Z3 = 1500, Q3 = "value", $3 = (0, R.createContext)(null);
+function e6() {
+ let e = (0, R.use)($3);
if (!e) throw Error("Radar chart parts (<Radar />, <PolarAngleAxis />, …) must be used within <EvilRadarChart />");
return e;
}
-function n6({ config: e, data: t, children: n, className: r, chartProps: i, backgroundVariant: a, defaultSelectedDataKey: o = null, onSelectionChange: s, isLoading: c = !1, loadingPoints: l }) {
- let u = (0, R.useId)().replace(/:/g, ""), [d, f] = (0, R.useState)(o), p = Zze(c, l), m = (0, R.useCallback)((e) => {
+function t6({ config: e, data: t, children: n, className: r, chartProps: i, backgroundVariant: a, defaultSelectedDataKey: o = null, onSelectionChange: s, isLoading: c = !1, loadingPoints: l }) {
+ let u = (0, R.useId)().replace(/:/g, ""), [d, f] = (0, R.useState)(o), p = $ze(c, l), m = (0, R.useCallback)((e) => {
f(e), s?.(e);
}, [s]), h = (0, R.useMemo)(() => ({
config: e,
@@ -72241,37 +72293,37 @@ function n6({ config: e, data: t, children: n, className: r, chartProps: i, back
d,
m
]);
- return /* @__PURE__ */ (0, z.jsx)(e6, {
+ return /* @__PURE__ */ (0, z.jsx)($3, {
value: h,
- children: /* @__PURE__ */ (0, z.jsxs)(j4, {
+ children: /* @__PURE__ */ (0, z.jsxs)(A4, {
className: r,
config: e,
- children: [/* @__PURE__ */ (0, z.jsx)(M4, { isLoading: c }), /* @__PURE__ */ (0, z.jsxs)(SLe, {
+ children: [/* @__PURE__ */ (0, z.jsx)(j4, { isLoading: c }), /* @__PURE__ */ (0, z.jsxs)(wLe, {
id: u,
data: c ? p : t,
...i,
children: [
- a && /* @__PURE__ */ (0, z.jsx)(U4, { variant: a }),
+ a && /* @__PURE__ */ (0, z.jsx)(H4, { variant: a }),
n,
- c && /* @__PURE__ */ (0, z.jsx)(Qze, {})
+ c && /* @__PURE__ */ (0, z.jsx)(eBe, {})
]
})]
})
});
}
-function zze({ dataKey: e, variant: t = "filled", fillOpacity: n = Lze, isGlowing: r = !1, isClickable: i = !1, children: a, radarProps: o }) {
- let { config: s, isLoading: c, selectedDataKey: l, selectDataKey: u } = t6(), d = (0, R.useId)().replace(/:/g, "");
+function Vze({ dataKey: e, variant: t = "filled", fillOpacity: n = zze, isGlowing: r = !1, isClickable: i = !1, children: a, radarProps: o }) {
+ let { config: s, isLoading: c, selectedDataKey: l, selectDataKey: u } = e6(), d = (0, R.useId)().replace(/:/g, "");
if (c) return null;
let f = i && l !== null && l !== e, p = {
stroke: f ? .2 : 1,
fill: f ? .1 : 1,
dot: f ? .2 : 1
- }, m = t === "filled", { dot: h, activeDot: g } = Gze(a, d, e, p.dot);
- return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(g1, {
+ }, m = t === "filled", { dot: h, activeDot: g } = qze(a, d, e, p.dot);
+ return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(h1, {
dataKey: e,
stroke: `url(#${d}-radar-stroke-${e})`,
strokeOpacity: p.stroke,
- strokeWidth: Ize,
+ strokeWidth: Rze,
fill: m ? `url(#${d}-radar-fill-${e})` : "none",
fillOpacity: m ? n * p.fill : 0,
dot: h,
@@ -72284,30 +72336,30 @@ function zze({ dataKey: e, variant: t = "filled", fillOpacity: n = Lze, isGlowin
},
...o
}), /* @__PURE__ */ (0, z.jsxs)("defs", { children: [
- /* @__PURE__ */ (0, z.jsx)(Kze, {
+ /* @__PURE__ */ (0, z.jsx)(Jze, {
id: d,
dataKey: e,
config: s
}),
- /* @__PURE__ */ (0, z.jsx)(qze, {
+ /* @__PURE__ */ (0, z.jsx)(Yze, {
id: d,
dataKey: e,
config: s
}),
- m && /* @__PURE__ */ (0, z.jsx)(Jze, {
+ m && /* @__PURE__ */ (0, z.jsx)(Xze, {
id: d,
dataKey: e,
config: s
}),
- r && /* @__PURE__ */ (0, z.jsx)(Yze, {
+ r && /* @__PURE__ */ (0, z.jsx)(Zze, {
id: d,
dataKey: e
})
] })] });
}
-var r6 = () => null, i6 = () => null;
-function Bze({ gridType: e = "polygon", stroke: t = "currentColor", strokeOpacity: n = .2, strokeDasharray: r = "3 4", ...i }) {
- return /* @__PURE__ */ (0, z.jsx)(l$, {
+var n6 = () => null, r6 = () => null;
+function Hze({ gridType: e = "polygon", stroke: t = "currentColor", strokeOpacity: n = .2, strokeDasharray: r = "3 4", ...i }) {
+ return /* @__PURE__ */ (0, z.jsx)(c$, {
gridType: e,
stroke: t,
strokeOpacity: n,
@@ -72315,47 +72367,47 @@ function Bze({ gridType: e = "polygon", stroke: t = "currentColor", strokeOpacit
...i
});
}
-function Vze({ tick: e = {
+function Uze({ tick: e = {
fill: "currentColor",
fontSize: 12
}, tickLine: t = !1, ...n }) {
- let { isLoading: r } = t6();
- return r ? null : /* @__PURE__ */ (0, z.jsx)(C$, {
+ let { isLoading: r } = e6();
+ return r ? null : /* @__PURE__ */ (0, z.jsx)(S$, {
tick: e,
tickLine: t,
...n
});
}
-function Hze({ tick: e = {
+function Wze({ tick: e = {
fill: "currentColor",
fontSize: 10
}, tickLine: t = !1, axisLine: n = !1, ...r }) {
- let { isLoading: i } = t6();
- return i ? null : /* @__PURE__ */ (0, z.jsx)(_$, {
+ let { isLoading: i } = e6();
+ return i ? null : /* @__PURE__ */ (0, z.jsx)(g$, {
tick: e,
tickLine: t,
axisLine: n,
...r
});
}
-function Uze({ variant: e, roundness: t, defaultIndex: n }) {
- let { isLoading: r, selectedDataKey: i } = t6();
- return r ? null : /* @__PURE__ */ (0, z.jsx)(L4, {
+function Gze({ variant: e, roundness: t, defaultIndex: n }) {
+ let { isLoading: r, selectedDataKey: i } = e6();
+ return r ? null : /* @__PURE__ */ (0, z.jsx)(I4, {
defaultIndex: n,
cursor: !1,
- content: /* @__PURE__ */ (0, z.jsx)(I4, {
+ content: /* @__PURE__ */ (0, z.jsx)(F4, {
selected: i,
roundness: t,
variant: e
})
});
}
-function Wze({ variant: e, align: t = "center", verticalAlign: n = "bottom", isClickable: r = !1 }) {
- let { isLoading: i, selectedDataKey: a, selectDataKey: o } = t6();
- return i ? null : /* @__PURE__ */ (0, z.jsx)(z4, {
+function Kze({ variant: e, align: t = "center", verticalAlign: n = "bottom", isClickable: r = !1 }) {
+ let { isLoading: i, selectedDataKey: a, selectDataKey: o } = e6();
+ return i ? null : /* @__PURE__ */ (0, z.jsx)(R4, {
verticalAlign: n,
align: t,
- content: /* @__PURE__ */ (0, z.jsx)(R4, {
+ content: /* @__PURE__ */ (0, z.jsx)(L4, {
selected: a,
onSelectChange: o,
isClickable: r,
@@ -72363,22 +72415,22 @@ function Wze({ variant: e, align: t = "center", verticalAlign: n = "bottom", isC
})
});
}
-var Gze = (e, t, n, r) => {
+var qze = (e, t, n, r) => {
let i = !1, a = !1;
return R.Children.forEach(e, (e) => {
if ((0, R.isValidElement)(e)) {
- if (e.type === r6) {
+ if (e.type === n6) {
let { variant: a } = e.props;
- i = /* @__PURE__ */ (0, z.jsx)(J3, {
+ i = /* @__PURE__ */ (0, z.jsx)(q3, {
type: a,
dataKey: n,
chartId: t,
fillOpacity: r
});
}
- if (e.type === i6) {
+ if (e.type === r6) {
let { variant: i } = e.props;
- a = /* @__PURE__ */ (0, z.jsx)(J3, {
+ a = /* @__PURE__ */ (0, z.jsx)(q3, {
type: i,
dataKey: n,
chartId: t,
@@ -72390,7 +72442,7 @@ var Gze = (e, t, n, r) => {
dot: i,
activeDot: a
};
-}, a6 = ({ dataKey: e, colorsCount: t, opacities: n }) => t === 1 ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("stop", {
+}, i6 = ({ dataKey: e, colorsCount: t, opacities: n }) => t === 1 ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("stop", {
offset: "0%",
stopColor: `var(--color-${e}-0)`,
stopOpacity: n?.[0]
@@ -72405,46 +72457,46 @@ var Gze = (e, t, n, r) => {
stopColor: `var(--color-${e}-${i}, var(--color-${e}-0))`,
stopOpacity: n?.[i]
}, a);
-}) }), Kze = ({ id: e, dataKey: t, config: n }) => {
- let r = F4(n[t] ?? {});
+}) }), Jze = ({ id: e, dataKey: t, config: n }) => {
+ let r = P4(n[t] ?? {});
return /* @__PURE__ */ (0, z.jsx)("linearGradient", {
id: `${e}-colors-${t}`,
x1: "0",
y1: "0",
x2: "1",
y2: "0",
- children: /* @__PURE__ */ (0, z.jsx)(a6, {
+ children: /* @__PURE__ */ (0, z.jsx)(i6, {
dataKey: t,
colorsCount: r
})
});
-}, qze = ({ id: e, dataKey: t, config: n }) => {
- let r = F4(n[t] ?? {});
+}, Yze = ({ id: e, dataKey: t, config: n }) => {
+ let r = P4(n[t] ?? {});
return /* @__PURE__ */ (0, z.jsx)("linearGradient", {
id: `${e}-radar-stroke-${t}`,
x1: "0",
y1: "0",
x2: "1",
y2: "1",
- children: /* @__PURE__ */ (0, z.jsx)(a6, {
+ children: /* @__PURE__ */ (0, z.jsx)(i6, {
dataKey: t,
colorsCount: r
})
});
-}, Jze = ({ id: e, dataKey: t, config: n }) => {
- let r = F4(n[t] ?? {}), i = r === 1 ? [.8, .3] : Array.from({ length: r }, (e, t) => t === 0 ? .8 : .3);
+}, Xze = ({ id: e, dataKey: t, config: n }) => {
+ let r = P4(n[t] ?? {}), i = r === 1 ? [.8, .3] : Array.from({ length: r }, (e, t) => t === 0 ? .8 : .3);
return /* @__PURE__ */ (0, z.jsx)("radialGradient", {
id: `${e}-radar-fill-${t}`,
cx: "50%",
cy: "50%",
r: "50%",
- children: /* @__PURE__ */ (0, z.jsx)(a6, {
+ children: /* @__PURE__ */ (0, z.jsx)(i6, {
dataKey: t,
colorsCount: r,
opacities: i
})
});
-}, Yze = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)("filter", {
+}, Zze = ({ id: e, dataKey: t }) => /* @__PURE__ */ (0, z.jsxs)("filter", {
id: `${e}-radar-glow-${t}`,
x: "-50%",
y: "-50%",
@@ -72464,7 +72516,7 @@ var Gze = (e, t, n, r) => {
}),
/* @__PURE__ */ (0, z.jsxs)("feMerge", { children: [/* @__PURE__ */ (0, z.jsx)("feMergeNode", { in: "glow" }), /* @__PURE__ */ (0, z.jsx)("feMergeNode", { in: "SourceGraphic" })] })
]
-}), Xze = (e) => [
+}), Qze = (e) => [
"A",
"B",
"C",
@@ -72473,20 +72525,20 @@ var Gze = (e, t, n, r) => {
"F"
].slice(0, e).map((e) => ({
skill: e,
- [$3]: 30 + Math.random() * 70
+ [Q3]: 30 + Math.random() * 70
}));
-function Zze(e, t = Rze) {
+function $ze(e, t = Bze) {
let [n, r] = (0, R.useState)(0);
return (0, R.useEffect)(() => {
if (!e) return;
let t = setInterval(() => {
r((e) => e + 1);
- }, Q3);
+ }, Z3);
return () => clearInterval(t);
- }, [e]), (0, R.useMemo)(() => Xze(t), [t, n]);
+ }, [e]), (0, R.useMemo)(() => Qze(t), [t, n]);
}
-var Qze = () => /* @__PURE__ */ (0, z.jsx)(g1, {
- dataKey: $3,
+var eBe = () => /* @__PURE__ */ (0, z.jsx)(h1, {
+ dataKey: Q3,
stroke: "currentColor",
strokeOpacity: .3,
strokeWidth: 2,
@@ -72494,30 +72546,30 @@ var Qze = () => /* @__PURE__ */ (0, z.jsx)(g1, {
fillOpacity: .1,
dot: !1,
isAnimationActive: !0,
- animationDuration: Q3,
+ animationDuration: Z3,
animationEasing: "ease-in-out"
});
-n6.Radar = zze, n6.Dot = r6, n6.ActiveDot = i6, n6.PolarGrid = Bze, n6.PolarAngleAxis = Vze, n6.PolarRadiusAxis = Hze, n6.Tooltip = Uze, n6.Legend = Wze;
+t6.Radar = Vze, t6.Dot = n6, t6.ActiveDot = r6, t6.PolarGrid = Hze, t6.PolarAngleAxis = Uze, t6.PolarRadiusAxis = Wze, t6.Tooltip = Gze, t6.Legend = Kze;
//#endregion
//#region src/react/taste/charts.tsx
-var $ze = [
+var tBe = [
"stroke-chart-1",
"stroke-chart-2",
"stroke-chart-3",
"stroke-chart-4",
"stroke-chart-5",
"stroke-chart-6"
-], eBe = [
+], nBe = [
"fill-chart-1",
"fill-chart-2",
"fill-chart-3",
"fill-chart-4",
"fill-chart-5",
"fill-chart-6"
-], o6 = { value: {
+], a6 = { value: {
label: "标签命中",
- colors: Q4(Z4[3])
-} }, tBe = [
+ colors: Z4(X4[3])
+} }, rBe = [
"min-h-24",
"min-h-24",
"min-h-24",
@@ -72527,78 +72579,78 @@ var $ze = [
"min-h-52",
"min-h-60",
"min-h-64"
-], nBe = 26, rBe = { radius: o6.value }, iBe = (e, t) => Math.sqrt(e / t);
-function aBe({ rows: e, label: t }) {
- let n = Nze(e);
+], iBe = 26, aBe = { radius: a6.value }, oBe = (e, t) => Math.sqrt(e / t);
+function sBe({ rows: e, label: t }) {
+ let n = Fze(e);
if (!n.length) return null;
let r = n[0].value, i = n.map((e) => ({
...e,
- radius: iBe(e.value, r)
+ radius: oBe(e.value, r)
}));
return /* @__PURE__ */ (0, z.jsx)("div", {
role: "img",
"aria-label": `${t}:${i.map((e) => e.name).join(",")}`,
- children: /* @__PURE__ */ (0, z.jsxs)(n6, {
+ children: /* @__PURE__ */ (0, z.jsxs)(t6, {
data: i,
- config: rBe,
+ config: aBe,
chartProps: { outerRadius: "58%" },
className: "aspect-auto h-70 text-text-secondary",
children: [
- /* @__PURE__ */ (0, z.jsx)(n6.PolarGrid, {}),
- /* @__PURE__ */ (0, z.jsx)(n6.PolarAngleAxis, { dataKey: "name" }),
- /* @__PURE__ */ (0, z.jsx)(n6.PolarRadiusAxis, {
+ /* @__PURE__ */ (0, z.jsx)(t6.PolarGrid, {}),
+ /* @__PURE__ */ (0, z.jsx)(t6.PolarAngleAxis, { dataKey: "name" }),
+ /* @__PURE__ */ (0, z.jsx)(t6.PolarRadiusAxis, {
domain: [0, 1],
allowDecimals: !0,
tick: !1
}),
- /* @__PURE__ */ (0, z.jsx)(n6.Radar, { dataKey: "radius" }),
- /* @__PURE__ */ (0, z.jsx)(r3, { valueKey: "value" })
+ /* @__PURE__ */ (0, z.jsx)(t6.Radar, { dataKey: "radius" }),
+ /* @__PURE__ */ (0, z.jsx)(n3, { valueKey: "value" })
]
})
});
}
-function oBe({ rows: e, label: t }) {
- let n = G3(e, 8);
+function cBe({ rows: e, label: t }) {
+ let n = W3(e, 8);
return n.length ? /* @__PURE__ */ (0, z.jsx)("section", {
"aria-label": t,
- className: `flex grow flex-col ${tBe[n.length]}`,
- children: /* @__PURE__ */ (0, z.jsxs)(q4, {
+ className: `flex grow flex-col ${rBe[n.length]}`,
+ children: /* @__PURE__ */ (0, z.jsxs)(K4, {
data: n,
- config: o6,
+ config: a6,
layout: "horizontal",
barRadius: 4,
- chartProps: { maxBarSize: nBe },
+ chartProps: { maxBarSize: iBe },
className: "aspect-auto text-text-secondary",
children: [
- /* @__PURE__ */ (0, z.jsx)(q4.YAxis, {
+ /* @__PURE__ */ (0, z.jsx)(K4.YAxis, {
dataKey: "name",
interval: 0
}),
- /* @__PURE__ */ (0, z.jsx)(q4.XAxis, {
+ /* @__PURE__ */ (0, z.jsx)(K4.XAxis, {
hide: !0,
- domain: i3
+ domain: r3
}),
- /* @__PURE__ */ (0, z.jsx)(q4.Bar, {
+ /* @__PURE__ */ (0, z.jsx)(K4.Bar, {
dataKey: "value",
enableHoverHighlight: !0,
barProps: {
dataKey: "value",
- label: a3("right")
+ label: i3("right")
}
}),
- /* @__PURE__ */ (0, z.jsx)(r3, {})
+ /* @__PURE__ */ (0, z.jsx)(n3, {})
]
})
}) : null;
}
-function sBe({ flows: e }) {
- let [t, n] = (0, R.useState)(null), r = Pze(e);
+function lBe({ flows: e }) {
+ let [t, n] = (0, R.useState)(null), r = Ize(e);
if (!r) return null;
let i = t?.node ?? null, a = (e, n) => t ? i === null ? t.label === n : e.source === i || e.target === i : !0;
return /* @__PURE__ */ (0, z.jsxs)("section", {
- className: Y4,
+ className: J4,
children: [
- /* @__PURE__ */ (0, z.jsx)(X4, {
+ /* @__PURE__ */ (0, z.jsx)(Y4, {
title: "创作者线索来源",
figure: (t ? t.value : r.total).toLocaleString(),
note: t ? t.label : "条线索"
@@ -72606,7 +72658,7 @@ function sBe({ flows: e }) {
/* @__PURE__ */ (0, z.jsx)("div", {
className: "min-w-0 overflow-x-auto",
children: /* @__PURE__ */ (0, z.jsxs)("svg", {
- viewBox: `0 0 ${K3.width} ${K3.height}`,
+ viewBox: `0 0 ${G3.width} ${G3.height}`,
fill: "none",
role: "img",
"aria-label": "来源网站与创作者线索",
@@ -72620,7 +72672,7 @@ function sBe({ flows: e }) {
"aria-label": `${e.label}:${e.value} 条线索`,
fillOpacity: 0,
strokeOpacity: a(e, e.label) ? .55 : .08,
- className: `outline-none transition-opacity ${$ze[e.color]}`,
+ className: `outline-none transition-opacity ${tBe[e.color]}`,
onPointerEnter: () => n({
value: e.value,
label: e.label,
@@ -72654,15 +72706,15 @@ function sBe({ flows: e }) {
width: 10,
height: e.height,
rx: 5,
- className: e.side === "source" ? eBe[e.color] : "fill-text-secondary"
+ className: e.side === "source" ? nBe[e.color] : "fill-text-secondary"
}), /* @__PURE__ */ (0, z.jsxs)("text", {
- x: q3[e.side],
+ x: K3[e.side],
y: e.y + e.height / 2,
textAnchor: e.side === "source" ? "end" : "start",
dominantBaseline: "middle",
className: "fill-text-secondary text-caption-1-regular",
- children: [Fze(e.name), /* @__PURE__ */ (0, z.jsx)("tspan", {
- x: q3[e.side],
+ children: [Lze(e.name), /* @__PURE__ */ (0, z.jsx)("tspan", {
+ x: K3[e.side],
dy: 15,
children: e.side === "source" ? e.value.toLocaleString() : `${e.share.toFixed(1)}%`
})]
@@ -72679,11 +72731,11 @@ function sBe({ flows: e }) {
}
//#endregion
//#region src/react/taste/taste-page.tsx
-var cBe = 10, s6 = Ii(uy, dy, "text-body-2-medium"), c6 = `${Zi()} flex flex-col gap-4`, l6 = "rounded-xl bg-background-primary-default p-3", lBe = "读取运行 Peach 的这台电脑上的浏览记录", uBe = "导入或读取浏览记录后,这里会列出已采集设备。", dBe = "馆藏里暂时没有对得上浏览信号的标签。", fBe = "采集浏览记录后,这里会显示聚合后的口味证据。", pBe = "这些词在浏览记录中出现,但 Peach 观看记录还没有对应证据", mBe = "在运行 Peach 的电脑上使用浏览器:点上面的「读取浏览器历史」。", hBe = "记录在其他设备上:导出文件后,点上面的「导入历史文件」。多台设备的文件分别导入。", gBe = "需要刷新时再次读取或导入;数据源可在页面底部移除。", _Be = "这个数据源将不再用于口味分析。原始导出文件保留。", u6 = "peach-taste-guide-dismissed";
-function d6({ icon: e, term: t, figure: n, detail: r, accent: i }) {
+var uBe = 10, o6 = Ii(hy, gy, "text-body-2-medium"), s6 = `${Zi()} flex flex-col gap-4`, c6 = "rounded-xl bg-background-primary-default p-3", dBe = "读取运行 Peach 的这台电脑上的浏览记录", fBe = "导入或读取浏览记录后,这里会列出已采集设备。", pBe = "馆藏里暂时没有对得上浏览信号的标签。", mBe = "采集浏览记录后,这里会显示聚合后的口味证据。", hBe = "这些词在浏览记录中出现,但 Peach 观看记录还没有对应证据", gBe = "在运行 Peach 的电脑上使用浏览器:点上面的「读取浏览器历史」。", _Be = "记录在其他设备上:导出文件后,点上面的「导入历史文件」。多台设备的文件分别导入。", vBe = "需要刷新时再次读取或导入;数据源可在页面底部移除。", yBe = "这个数据源将不再用于口味分析。原始导出文件保留。", l6 = "peach-taste-guide-dismissed";
+function u6({ icon: e, term: t, figure: n, detail: r, accent: i }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
- className: KS(),
- children: /* @__PURE__ */ (0, z.jsx)(XS, {
+ className: vS(),
+ children: /* @__PURE__ */ (0, z.jsx)(SS, {
label: t,
icon: e,
accent: i,
@@ -72692,7 +72744,7 @@ function d6({ icon: e, term: t, figure: n, detail: r, accent: i }) {
})
});
}
-function f6({ name: e, domain: t }) {
+function d6({ name: e, domain: t }) {
return /* @__PURE__ */ (0, z.jsxs)("span", {
className: "relative inline-grid size-8 shrink-0 place-items-center overflow-hidden rounded-lg bg-background-tertiary-default text-caption-1-medium text-text-secondary",
children: [e.slice(0, 1).toUpperCase(), /* @__PURE__ */ (0, z.jsx)("img", {
@@ -72706,22 +72758,22 @@ function f6({ name: e, domain: t }) {
})]
});
}
-function vBe({ html: e }) {
+function bBe({ html: e }) {
return /* @__PURE__ */ (0, z.jsx)("span", {
- className: `relative inline-grid size-8 shrink-0 place-items-center overflow-hidden rounded-full bg-background-tertiary-default text-caption-1-medium text-text-secondary ${KN}`,
+ className: `relative inline-grid size-8 shrink-0 place-items-center overflow-hidden rounded-full bg-background-tertiary-default text-caption-1-medium text-text-secondary ${qN}`,
dangerouslySetInnerHTML: { __html: e }
});
}
-function yBe({ rows: e, kind: t, visual: n, empty: r, onSignal: i, avatarInner: a }) {
+function xBe({ rows: e, kind: t, visual: n, empty: r, onSignal: i, avatarInner: a }) {
if (!e.length) return /* @__PURE__ */ (0, z.jsx)($i, {
shell: "plain",
icon: gt,
title: "暂无足够证据",
children: r
});
- let o = Mze(e);
- return /* @__PURE__ */ (0, z.jsx)(m3, {
- previewCount: cBe,
+ let o = Pze(e);
+ return /* @__PURE__ */ (0, z.jsx)(p3, {
+ previewCount: uBe,
className: "inline-grid w-full gap-x-7 gap-y-2 sm:grid-cols-2",
children: e.map((e, r) => {
let s = !!t && !!e.peach_items, c = String(e.source_domain || ""), l = /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
@@ -72740,15 +72792,15 @@ function yBe({ rows: e, kind: t, visual: n, empty: r, onSignal: i, avatarInner:
className: "w-6 shrink-0 text-caption-1-regular tabular-nums text-text-secondary",
children: r + 1
}),
- n === "domain" ? /* @__PURE__ */ (0, z.jsx)(f6, {
+ n === "domain" ? /* @__PURE__ */ (0, z.jsx)(d6, {
name: e.name,
domain: e.name
}) : null,
- n === "creator" && !e.entity_id && !e.has_avatar && c ? /* @__PURE__ */ (0, z.jsx)(f6, {
+ n === "creator" && !e.entity_id && !e.has_avatar && c ? /* @__PURE__ */ (0, z.jsx)(d6, {
name: e.name,
domain: c
}) : null,
- n !== "none" && n !== "domain" && (e.entity_id || e.has_avatar || !c) ? /* @__PURE__ */ (0, z.jsx)(vBe, { html: a(e.name, e.entity_id ? {
+ n !== "none" && n !== "domain" && (e.entity_id || e.has_avatar || !c) ? /* @__PURE__ */ (0, z.jsx)(bBe, { html: a(e.name, e.entity_id ? {
id: e.entity_id,
has_image: !!e.has_image,
avatar_focus: e.avatar_focus
@@ -72760,7 +72812,7 @@ function yBe({ rows: e, kind: t, visual: n, empty: r, onSignal: i, avatarInner:
children: e.name
}), /* @__PURE__ */ (0, z.jsx)("small", {
className: "text-caption-1-regular text-text-secondary",
- children: jze(e)
+ children: Nze(e)
})]
}),
s ? /* @__PURE__ */ (0, z.jsx)(Ge, {
@@ -72783,24 +72835,24 @@ function yBe({ rows: e, kind: t, visual: n, empty: r, onSignal: i, avatarInner:
})
});
}
-function p6({ label: e, panels: t, onSignal: n, avatarInner: r }) {
- return /* @__PURE__ */ (0, z.jsxs)($v, {
+function f6({ label: e, panels: t, onSignal: n, avatarInner: r }) {
+ return /* @__PURE__ */ (0, z.jsxs)(ay, {
className: `${Zi({ padding: "none" })} flex flex-col`,
children: [/* @__PURE__ */ (0, z.jsx)("div", {
className: "px-4 pt-3",
- children: /* @__PURE__ */ (0, z.jsx)(QO, {
+ children: /* @__PURE__ */ (0, z.jsx)(WO, {
"aria-label": e,
- className: ek,
- children: t.map((e) => /* @__PURE__ */ (0, z.jsx)(ny, {
+ className: KO,
+ children: t.map((e) => /* @__PURE__ */ (0, z.jsx)(sy, {
id: e.id,
- className: tk,
+ className: qO,
children: e.name
}, e.id))
})
- }), t.map((e) => /* @__PURE__ */ (0, z.jsx)(ry, {
+ }), t.map((e) => /* @__PURE__ */ (0, z.jsx)(cy, {
id: e.id,
className: "px-4 pt-3.5 pb-4",
- children: /* @__PURE__ */ (0, z.jsx)(yBe, {
+ children: /* @__PURE__ */ (0, z.jsx)(xBe, {
...e.props,
onSignal: n,
avatarInner: r
@@ -72808,7 +72860,7 @@ function p6({ label: e, panels: t, onSignal: n, avatarInner: r }) {
}, e.id))]
});
}
-function bBe({ data: e, onSignal: t, navigate: n }) {
+function SBe({ data: e, onSignal: t, navigate: n }) {
let r = e.analysis;
if (!r?.headline) return null;
let i = r.confidence || {}, a = [...(r.explore || []).map((e) => ({
@@ -72823,7 +72875,7 @@ function bBe({ data: e, onSignal: t, navigate: n }) {
act: () => n(e.route)
}))];
return /* @__PURE__ */ (0, z.jsxs)("section", {
- className: c6,
+ className: s6,
"aria-label": "口味总结",
children: [
/* @__PURE__ */ (0, z.jsxs)("header", {
@@ -72849,7 +72901,7 @@ function bBe({ data: e, onSignal: t, navigate: n }) {
r.points?.length ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "inline-grid w-full gap-3 sm:grid-cols-2",
children: r.points.map((e) => /* @__PURE__ */ (0, z.jsxs)("div", {
- className: `flex min-w-0 flex-col gap-1 ${l6}`,
+ className: `flex min-w-0 flex-col gap-1 ${c6}`,
children: [/* @__PURE__ */ (0, z.jsx)("span", {
className: "text-caption-1-regular text-text-secondary",
children: e.label
@@ -72864,7 +72916,7 @@ function bBe({ data: e, onSignal: t, navigate: n }) {
children: a.map((e) => /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
onClick: e.act,
- className: `flex w-full min-w-0 cursor-pointer items-center gap-3 ${l6} text-left outline-none hover:bg-background-primary-hover focus-visible:ring-2 focus-visible:ring-border-focus-ring`,
+ className: `flex w-full min-w-0 cursor-pointer items-center gap-3 ${c6} text-left outline-none hover:bg-background-primary-hover focus-visible:ring-2 focus-visible:ring-border-focus-ring`,
children: [/* @__PURE__ */ (0, z.jsxs)("span", {
className: "flex min-w-0 grow flex-col gap-1",
children: [/* @__PURE__ */ (0, z.jsx)("b", {
@@ -72883,15 +72935,15 @@ function bBe({ data: e, onSignal: t, navigate: n }) {
shell: "plain",
icon: gt,
title: "还没有可探索的入口",
- children: dBe
+ children: pBe
})
]
});
}
-function xBe({ onboarding: e, done: t }) {
+function CBe({ onboarding: e, done: t }) {
let [n, r] = (0, R.useState)(() => {
try {
- return localStorage.getItem(u6) === "1";
+ return localStorage.getItem(l6) === "1";
} catch {
return !1;
}
@@ -72901,17 +72953,17 @@ function xBe({ onboarding: e, done: t }) {
padding: "none",
className: "p-4"
}),
- children: /* @__PURE__ */ (0, z.jsxs)(Ay, {
+ children: /* @__PURE__ */ (0, z.jsxs)(Fy, {
summary: "浏览器历史记录导入指南",
defaultOpen: e,
children: [
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
- children: mBe
+ children: gBe
}),
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
- children: hBe
+ children: _Be
}),
/* @__PURE__ */ (0, z.jsxs)("ul", {
className: "flex list-disc flex-col gap-1 pl-5 text-body-2-regular text-text-secondary",
@@ -72941,7 +72993,7 @@ function xBe({ onboarding: e, done: t }) {
}),
/* @__PURE__ */ (0, z.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
- children: gBe
+ children: vBe
}),
/* @__PURE__ */ (0, z.jsx)("span", {
className: "self-start",
@@ -72950,7 +73002,7 @@ function xBe({ onboarding: e, done: t }) {
size: "small",
onClick: () => {
try {
- localStorage.setItem(u6, "1");
+ localStorage.setItem(l6, "1");
} catch {}
r(!0);
},
@@ -72961,7 +73013,7 @@ function xBe({ onboarding: e, done: t }) {
})
});
}
-function SBe({ busy: e, onRefresh: t, onImport: n }) {
+function wBe({ busy: e, onRefresh: t, onImport: n }) {
let r = (0, R.useRef)(null), [i, a] = (0, R.useState)(!1), o = (e) => {
a(!1), e();
};
@@ -72971,7 +73023,7 @@ function SBe({ busy: e, onRefresh: t, onImport: n }) {
"data-variant": "primary",
children: [/* @__PURE__ */ (0, z.jsx)(H, {
leadingIcon: Ze,
- title: lBe,
+ title: dBe,
onClick: t,
...q(e),
children: "读取浏览器历史"
@@ -72993,13 +73045,13 @@ function SBe({ busy: e, onRefresh: t, onImport: n }) {
onOpenChange: a,
placement: "bottom end",
offset: 4,
- className: ly,
- children: /* @__PURE__ */ (0, z.jsxs)(iO, {
+ className: my,
+ children: /* @__PURE__ */ (0, z.jsxs)($D, {
"aria-label": "更多取得浏览记录的方式",
className: "flex w-52 flex-col gap-1 outline-none",
children: [/* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
- className: s6,
+ className: o6,
onClick: () => o(t),
children: [/* @__PURE__ */ (0, z.jsx)(Ze, {
"aria-hidden": !0,
@@ -73007,7 +73059,7 @@ function SBe({ busy: e, onRefresh: t, onImport: n }) {
}), "读取浏览器历史"]
}), /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
- className: s6,
+ className: o6,
onClick: () => o(n),
children: [/* @__PURE__ */ (0, z.jsx)(xt, {
"aria-hidden": !0,
@@ -73017,15 +73069,15 @@ function SBe({ busy: e, onRefresh: t, onImport: n }) {
})
})] });
}
-function CBe({ sources: e, window: t, toast: n }) {
+function TBe({ sources: e, window: t, toast: n }) {
let r = er({
- mutationFn: (e) => Eze(e, t),
+ mutationFn: (e) => Oze(e, t),
onSuccess: (e) => {
- X.setQueryData(H3(t), e.dashboard), n("已移除口味数据源");
+ X.setQueryData(V3(t), e.dashboard), n("已移除口味数据源");
}
});
return /* @__PURE__ */ (0, z.jsxs)("section", {
- className: c6,
+ className: s6,
"aria-label": "数据源",
children: [
/* @__PURE__ */ (0, z.jsx)("h3", {
@@ -73039,7 +73091,7 @@ function CBe({ sources: e, window: t, toast: n }) {
e.length ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "inline-grid w-full gap-2 sm:grid-cols-2",
children: e.map((e) => /* @__PURE__ */ (0, z.jsxs)("div", {
- className: `flex min-w-0 items-center gap-3 ${l6}`,
+ className: `flex min-w-0 items-center gap-3 ${c6}`,
children: [
/* @__PURE__ */ (0, z.jsx)("span", {
className: "inline-grid size-8 shrink-0 place-items-center rounded-lg text-text-secondary",
@@ -73071,7 +73123,7 @@ function CBe({ sources: e, window: t, toast: n }) {
onClick: () => {
r.isPending || b({
title: "移除口味数据源",
- body: _Be,
+ body: yBe,
confirmLabel: "移除口味数据源",
onConfirm: () => r.mutateAsync(e.source_key)
});
@@ -73083,28 +73135,28 @@ function CBe({ sources: e, window: t, toast: n }) {
shell: "plain",
icon: Qe,
title: "还没有数据源",
- children: uBe
+ children: fBe
})
]
});
}
-function wBe(e) {
+function EBe(e) {
let { onSignal: t, navigate: n, toast: r, avatarInner: i, onboarding: a } = e, [o, c] = (0, R.useState)("all"), [l, u] = (0, R.useState)("browser"), d = (0, R.useRef)(null), f = $n({
- queryKey: H3(o),
- queryFn: ({ signal: e }) => U3(o, e),
+ queryKey: V3(o),
+ queryFn: ({ signal: e }) => H3(o, e),
placeholderData: Zt
- }), { job: p, running: m, outcome: h, start: g } = vO({
- queryKey: xze,
- queryFn: ({ signal: e }) => Cze(e),
- start: () => Tze(o),
- idlePollMs: Oze,
+ }), { job: p, running: m, outcome: h, start: g } = pO({
+ queryKey: Cze,
+ queryFn: ({ signal: e }) => Tze(e),
+ start: () => Dze(o),
+ idlePollMs: Aze,
onFinish: (e) => {
e.status !== "failed" && (X.invalidateQueries({ queryKey: ["taste"] }), r("已更新口味分析"));
}
}), _ = er({
- mutationFn: (e) => Dze(e),
+ mutationFn: (e) => kze(e),
onSuccess: (e) => {
- X.setQueryData(H3("all"), e.dashboard), c("all"), r("已导入口味数据");
+ X.setQueryData(V3("all"), e.dashboard), c("all"), r("已导入口味数据");
}
}), v = (e) => {
let t = e.currentTarget.files?.[0];
@@ -73119,40 +73171,40 @@ function wBe(e) {
}) });
let x = b.summary || {}, S = b.coverage || {}, C = b.rankings || {}, w = b.storage || {}, T = C.browser_categories || [], E = b.gaps || [], D = S.tagged || 0, O = S.identified || 0, k = g.error ? U(g.error) : _.error ? U(_.error) : h?.status === "failed" ? h.error || "读取未取得" : "";
return /* @__PURE__ */ (0, z.jsxs)(ta, { children: [
- /* @__PURE__ */ (0, z.jsxs)($v, {
+ /* @__PURE__ */ (0, z.jsxs)(ay, {
selectedKey: l,
onSelectionChange: (e) => u(String(e)),
className: "flex flex-col gap-5",
children: [
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center justify-between gap-3",
- children: [/* @__PURE__ */ (0, z.jsxs)(QO, {
+ children: [/* @__PURE__ */ (0, z.jsxs)(WO, {
"aria-label": "口味证据来源",
- className: ek,
- children: [/* @__PURE__ */ (0, z.jsx)(ny, {
+ className: KO,
+ children: [/* @__PURE__ */ (0, z.jsx)(sy, {
id: "browser",
- className: tk,
+ className: qO,
children: "浏览器记录"
- }), /* @__PURE__ */ (0, z.jsx)(ny, {
+ }), /* @__PURE__ */ (0, z.jsx)(sy, {
id: "peach",
- className: tk,
+ className: qO,
children: "Peach 内部"
})]
}), /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-wrap items-center gap-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(py, {
+ /* @__PURE__ */ (0, z.jsx)(vy, {
"aria-label": "分析范围",
selectedKey: o,
onSelectionChange: (e) => {
e !== null && c(String(e));
},
- children: Sze.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(my, {
+ children: wze.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)(yy, {
id: e,
children: t
}, e))
}),
- /* @__PURE__ */ (0, z.jsx)(SBe, {
+ /* @__PURE__ */ (0, z.jsx)(wBe, {
busy: m || g.isPending || _.isPending,
onRefresh: y,
onImport: () => d.current?.click()
@@ -73168,7 +73220,7 @@ function wBe(e) {
]
})]
}),
- /* @__PURE__ */ (0, z.jsx)(xBe, {
+ /* @__PURE__ */ (0, z.jsx)(CBe, {
onboarding: a,
done: !!(x.history_sources || b.updated_at)
}),
@@ -73176,46 +73228,46 @@ function wBe(e) {
"aria-live": "polite",
className: "flex flex-col gap-3 empty:hidden",
children: [
- m ? /* @__PURE__ */ (0, z.jsx)(mO, {
+ m ? /* @__PURE__ */ (0, z.jsx)(lO, {
label: p?.message || "正在读取浏览记录并更新口味分析",
value: p?.checked,
total: p?.total
}) : null,
- _.isPending ? /* @__PURE__ */ (0, z.jsx)(mO, { label: "正在导入历史文件" }) : null,
+ _.isPending ? /* @__PURE__ */ (0, z.jsx)(lO, { label: "正在导入历史文件" }) : null,
k ? /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
children: k
}) : null
]
}),
- /* @__PURE__ */ (0, z.jsxs)(ry, {
+ /* @__PURE__ */ (0, z.jsxs)(cy, {
id: "browser",
className: "flex flex-col gap-5",
children: [
/* @__PURE__ */ (0, z.jsxs)("div", {
- className: qS,
+ className: yS,
children: [
- /* @__PURE__ */ (0, z.jsx)(d6, {
+ /* @__PURE__ */ (0, z.jsx)(u6, {
accent: 0,
icon: ot,
term: "浏览记录",
figure: Number(x.history_visits || 0).toLocaleString(),
- detail: `${x.history_sources || 0} 个数据源 · ${W3(x.range_start)}—${W3(x.range_end)}`
+ detail: `${x.history_sources || 0} 个数据源 · ${U3(x.range_start)}—${U3(x.range_end)}`
}),
- /* @__PURE__ */ (0, z.jsx)(d6, {
+ /* @__PURE__ */ (0, z.jsx)(u6, {
accent: 1,
icon: pt,
term: "口味维度",
figure: T.length.toLocaleString(),
detail: T[0]?.name || "尚无主维度"
}),
- /* @__PURE__ */ (0, z.jsx)(d6, {
+ /* @__PURE__ */ (0, z.jsx)(u6, {
accent: 2,
icon: gt,
term: "浏览候选",
figure: E.length.toLocaleString()
}),
- /* @__PURE__ */ (0, z.jsx)(d6, {
+ /* @__PURE__ */ (0, z.jsx)(u6, {
accent: 3,
icon: Qe,
term: "私有导出",
@@ -73225,7 +73277,7 @@ function wBe(e) {
]
}),
/* @__PURE__ */ (0, z.jsxs)("section", {
- className: `${c6} md:flex-row md:gap-6`,
+ className: `${s6} md:flex-row md:gap-6`,
"aria-label": "浏览器画像",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex shrink-0 flex-col gap-2 pb-5 md:w-80 md:pr-6 md:pb-0",
@@ -73234,29 +73286,29 @@ function wBe(e) {
className: "text-caption-1-regular text-text-secondary",
children: "浏览器画像"
}),
- /* @__PURE__ */ (0, z.jsx)(aBe, {
+ /* @__PURE__ */ (0, z.jsx)(sBe, {
rows: T,
label: "主要口味维度"
}),
/* @__PURE__ */ (0, z.jsx)("small", {
className: "text-caption-1-regular text-text-secondary",
- children: b.updated_at ? `更新于 ${W3(b.updated_at)}` : "尚未采集浏览记录"
+ children: b.updated_at ? `更新于 ${U3(b.updated_at)}` : "尚未采集浏览记录"
})
]
}), /* @__PURE__ */ (0, z.jsx)("div", {
className: "flex min-w-0 grow flex-col",
- children: T.length ? /* @__PURE__ */ (0, z.jsx)(oBe, {
+ children: T.length ? /* @__PURE__ */ (0, z.jsx)(cBe, {
rows: T,
label: "口味维度排名"
}) : /* @__PURE__ */ (0, z.jsx)($i, {
shell: "plain",
icon: gt,
title: "暂无口味维度",
- children: fBe
+ children: mBe
})
})]
}),
- /* @__PURE__ */ (0, z.jsx)(p3, {
+ /* @__PURE__ */ (0, z.jsx)(f3, {
activity: b.activity,
title: "浏览活跃时间",
dailyTitle: "每日活跃",
@@ -73268,8 +73320,8 @@ function wBe(e) {
tone: 4,
empty: "还没有可用于分析的口味网站访问记录。"
}),
- /* @__PURE__ */ (0, z.jsx)(sBe, { flows: b.creator_flows }),
- /* @__PURE__ */ (0, z.jsx)(p6, {
+ /* @__PURE__ */ (0, z.jsx)(lBe, { flows: b.creator_flows }),
+ /* @__PURE__ */ (0, z.jsx)(f6, {
label: "浏览器口味维度",
onSignal: t,
avatarInner: i,
@@ -73311,40 +73363,40 @@ function wBe(e) {
rows: E,
kind: "",
visual: "none",
- empty: pBe
+ empty: hBe
}
}
]
})
]
}),
- /* @__PURE__ */ (0, z.jsxs)(ry, {
+ /* @__PURE__ */ (0, z.jsxs)(cy, {
id: "peach",
className: "flex flex-col gap-5",
children: [
/* @__PURE__ */ (0, z.jsxs)("div", {
- className: qS,
+ className: yS,
children: [
- /* @__PURE__ */ (0, z.jsx)(d6, {
+ /* @__PURE__ */ (0, z.jsx)(u6, {
accent: 0,
icon: nt,
term: "Peach 看过",
figure: Number(x.peach_items || 0).toLocaleString(),
- detail: kze(x.peach_seconds || 0)
+ detail: jze(x.peach_seconds || 0)
}),
- /* @__PURE__ */ (0, z.jsx)(d6, {
+ /* @__PURE__ */ (0, z.jsx)(u6, {
accent: 1,
icon: bt,
term: "喜欢",
figure: Number(x.liked || 0).toLocaleString()
}),
- /* @__PURE__ */ (0, z.jsx)(d6, {
+ /* @__PURE__ */ (0, z.jsx)(u6, {
accent: 2,
icon: yt,
term: "不合口味",
figure: Number(x.disliked || 0).toLocaleString()
}),
- /* @__PURE__ */ (0, z.jsx)(d6, {
+ /* @__PURE__ */ (0, z.jsx)(u6, {
accent: 3,
icon: pt,
term: "有标签",
@@ -73353,7 +73405,7 @@ function wBe(e) {
]
}),
/* @__PURE__ */ (0, z.jsxs)("section", {
- className: `${c6} md:flex-row md:gap-6`,
+ className: `${s6} md:flex-row md:gap-6`,
"aria-label": "Peach 观看",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex shrink-0 flex-col gap-0.5 pb-5 md:w-72 md:pr-6 md:pb-0",
@@ -73373,18 +73425,18 @@ function wBe(e) {
]
}), /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-w-0 grow flex-col",
- children: [/* @__PURE__ */ (0, z.jsx)(m6, {
+ children: [/* @__PURE__ */ (0, z.jsx)(p6, {
term: "有标签",
value: D,
rest: S.untagged || 0
- }), /* @__PURE__ */ (0, z.jsx)(m6, {
+ }), /* @__PURE__ */ (0, z.jsx)(p6, {
term: "有身份",
value: O,
rest: S.unidentified || 0
})]
})]
}),
- /* @__PURE__ */ (0, z.jsx)(p6, {
+ /* @__PURE__ */ (0, z.jsx)(f6, {
label: "Peach 口味维度",
onSignal: t,
avatarInner: i,
@@ -73425,19 +73477,19 @@ function wBe(e) {
})
]
}),
- /* @__PURE__ */ (0, z.jsx)(bBe, {
+ /* @__PURE__ */ (0, z.jsx)(SBe, {
data: b,
onSignal: t,
navigate: n
}),
- /* @__PURE__ */ (0, z.jsx)(CBe, {
+ /* @__PURE__ */ (0, z.jsx)(TBe, {
sources: b.sources || [],
window: o,
toast: r
})
] });
}
-function m6({ term: e, value: t, rest: n }) {
+function p6({ term: e, value: t, rest: n }) {
let r = Math.max(t + n, 1);
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col gap-1.5 border-b border-separator-border py-3 last:border-b-0",
@@ -73459,13 +73511,13 @@ function m6({ term: e, value: t, rest: n }) {
}
//#endregion
//#region src/react/batch-dock/batch-dock-api.ts
-var h6 = {
+var m6 = {
group: "clear",
operation: "clear",
label: "取消",
glyph: "x"
};
-function TBe(e, t = !1) {
+function DBe(e, t = !1) {
switch (e) {
case "trash": return [
{
@@ -73481,7 +73533,7 @@ function TBe(e, t = !1) {
glyph: "trash",
danger: !0
},
- h6
+ m6
];
case "junk": return [
t ? {
@@ -73502,7 +73554,7 @@ function TBe(e, t = !1) {
glyph: "trash",
danger: !0
},
- h6
+ m6
];
case "follow": return [
{
@@ -73523,7 +73575,7 @@ function TBe(e, t = !1) {
label: "忽略",
glyph: "eye-off"
},
- h6
+ m6
];
default: return [
{
@@ -73557,42 +73609,42 @@ function TBe(e, t = !1) {
glyph: "trash",
danger: !0
},
- h6
+ m6
];
}
}
//#endregion
//#region src/react/batch-dock/batch-dock-island.tsx
-var g6 = null, _6 = null, v6 = {
+var h6 = null, g6 = null, _6 = {
count: 0,
context: "catalog",
junkDismissed: !1
};
-function y6() {
- let e = g6;
- if (!e || !_6) return;
- let t = v6;
- (0, ze.flushSync)(() => _6.render(/* @__PURE__ */ (0, z.jsx)(IF, { children: /* @__PURE__ */ (0, z.jsx)(OBe, {
+function v6() {
+ let e = h6;
+ if (!e || !g6) return;
+ let t = _6;
+ (0, ze.flushSync)(() => g6.render(/* @__PURE__ */ (0, z.jsx)(LF, { children: /* @__PURE__ */ (0, z.jsx)(ABe, {
host: e,
props: t
}) })));
}
-var EBe = { render(e) {
- v6 = e, y6();
+var OBe = { render(e) {
+ _6 = e, v6();
} };
-function DBe(e) {
- return g6 = e, _6 = (0, Be.createRoot)(e.root), y6(), EBe;
+function kBe(e) {
+ return h6 = e, g6 = (0, Be.createRoot)(e.root), v6(), OBe;
}
-function OBe({ host: e, props: t }) {
+function ABe({ host: e, props: t }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
className: "peach-react",
"data-batch-scope": "",
"data-context": t.context,
- children: /* @__PURE__ */ (0, z.jsx)(QP, {
+ children: /* @__PURE__ */ (0, z.jsx)($P, {
label: "所选项目操作",
visible: t.count > 0,
count: `已选 ${t.count} 项`,
- children: TBe(t.context, t.junkDismissed).map((t) => /* @__PURE__ */ (0, z.jsxs)("button", {
+ children: DBe(t.context, t.junkDismissed).map((t) => /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
"data-batch-group": t.group,
"data-batch-action": t.operation,
@@ -73609,32 +73661,32 @@ function OBe({ host: e, props: t }) {
}
//#endregion
//#region src/player/host.ts
-var b6 = null;
-function kBe(e) {
- b6 = e;
+var y6 = null;
+function jBe(e) {
+ y6 = e;
}
-function x6() {
- if (!b6) throw Error("播放器还没有接上宿主(configurePlayer)");
- return b6;
+function b6() {
+ if (!y6) throw Error("播放器还没有接上宿主(configurePlayer)");
+ return y6;
}
//#endregion
//#region src/player/menu.ts
-var S6 = null;
-function ABe(e) {
- S6 = e;
+var x6 = null;
+function MBe(e) {
+ x6 = e;
}
-function jBe() {
+function NBe() {
let e = document.getElementById("playerMenu");
return e || (e = document.createElement("div"), e.className = "popmenu", e.setAttribute("data-player-context-menu", ""), e.id = "playerMenu", e.setAttribute("role", "menu"), e.setAttribute("aria-label", "播放器菜单"), e.hidden = !0, document.body.append(e)), e;
}
-var C6 = null, w6 = (e, t) => t ? e.replace("<svg", `<svg ${t}=""`) : e;
-function T6() {
+var S6 = null, C6 = (e, t) => t ? e.replace("<svg", `<svg ${t}=""`) : e;
+function w6() {
let e = document.getElementById("playerMenu");
e?.matches(":popover-open") && e.hidePopover(), e && e.parentElement !== document.body && document.body.append(e), e && S(e, () => {
e.innerHTML = "";
- }), C6 &&= (C6(), null);
+ }), S6 &&= (S6(), null);
}
-async function MBe(e) {
+async function PBe(e) {
try {
return await navigator.clipboard.writeText(e), !0;
} catch {
@@ -73647,12 +73699,12 @@ async function MBe(e) {
return t.remove(), n;
}
}
-function NBe(e) {
- let t = !!S6?.inMiniplayer(e), n = e.peachItem, r = S6?.kind(e) ?? "item", i = (t) => {
+function FBe(e) {
+ let t = !!x6?.inMiniplayer(e), n = e.peachItem, r = x6?.kind(e) ?? "item", i = (t) => {
let i = new URL(r === "follow" ? `/follow/item/${n?.id}` : `/item/${n?.id}`, location.origin);
return t && i.searchParams.set("t", String(Math.floor(e.currentTime() || 0))), i.href;
}, a = (e, t) => {
- MBe(i(e)).then((e) => x6().toast(e ? t : "复制失败,请手动复制地址栏", {
+ PBe(i(e)).then((e) => b6().toast(e ? t : "复制失败,请手动复制地址栏", {
timeout: 4e3,
warn: !e
}));
@@ -73664,11 +73716,11 @@ function NBe(e) {
}, t ? {
icon: "maximize-2",
label: "展开",
- run: () => S6?.expand()
+ run: () => x6?.expand()
} : {
icon: "picture-in-picture-2",
label: "迷你播放器",
- run: () => S6?.toMiniplayer()
+ run: () => x6?.toMiniplayer()
}];
document.pictureInPictureEnabled && o.push({
icon: "player-pip",
@@ -73691,29 +73743,29 @@ function NBe(e) {
run: () => s.click()
}), o;
}
-function PBe(e, t, n) {
- let r = jBe();
- T6();
- let a = x6().stage();
+function IBe(e, t, n) {
+ let r = NBe();
+ w6();
+ let a = b6().stage();
a instanceof HTMLDialogElement && a.open && a.append(r), r.setAttribute("popover", "manual");
- let o = NBe(e);
+ let o = FBe(e);
r.innerHTML = o.map((e, t) => {
let n = e.checked !== void 0;
- return `<button type="button" role="${n ? "menuitemcheckbox" : "menuitem"}"${n ? ` aria-checked="${e.checked}"` : ""} data-player-menu="${t}">${w6(l(e.icon), e.fill ? "data-player-menu-fill" : "")}<span>${i(e.label)}</span>${n ? w6(l("check"), "data-player-menu-check") : ""}</button>`;
+ return `<button type="button" role="${n ? "menuitemcheckbox" : "menuitem"}"${n ? ` aria-checked="${e.checked}"` : ""} data-player-menu="${t}">${C6(l(e.icon), e.fill ? "data-player-menu-fill" : "")}<span>${i(e.label)}</span>${n ? C6(l("check"), "data-player-menu-check") : ""}</button>`;
}).join(""), P(r), r.showPopover(), r.style.left = `${Math.max(8, Math.min(t, innerWidth - r.offsetWidth - 8))}px`, r.style.top = `${Math.max(8, Math.min(n, innerHeight - r.offsetHeight - 8))}px`;
let s = [...r.querySelectorAll("[data-player-menu]")];
s.forEach((e) => {
e.onclick = (t) => {
t.stopPropagation();
let n = o[Number(e.dataset.playerMenu)];
- T6(), n?.run();
+ w6(), n?.run();
};
});
let c = (e) => {
- r.contains(e.target) || T6();
+ r.contains(e.target) || w6();
}, u = (e) => {
if (e.key === "Escape") {
- e.preventDefault(), e.stopPropagation(), T6();
+ e.preventDefault(), e.stopPropagation(), w6();
return;
}
if (e.key !== "ArrowDown" && e.key !== "ArrowUp") return;
@@ -73721,51 +73773,51 @@ function PBe(e, t, n) {
let t = s.indexOf(document.activeElement);
s[(t + (e.key === "ArrowDown" ? 1 : -1) + s.length) % s.length]?.focus();
}, d = (t) => {
- F(t, e.el()) && T6();
+ F(t, e.el()) && w6();
};
setTimeout(() => {
document.addEventListener("pointerdown", c, !0), document.addEventListener("keydown", u, !0), window.addEventListener("scroll", d, {
capture: !0,
passive: !0
});
- }, 0), C6 = () => {
+ }, 0), S6 = () => {
document.removeEventListener("pointerdown", c, !0), document.removeEventListener("keydown", u, !0), window.removeEventListener("scroll", d, !0);
}, s[0]?.focus();
}
-function FBe(e) {
+function LBe(e) {
e.el().addEventListener("contextmenu", (t) => {
- t.target.closest(".vjs-peach-settings-menu") || (t.preventDefault(), PBe(e, t.clientX, t.clientY));
- }), e.on("dispose", T6);
+ t.target.closest(".vjs-peach-settings-menu") || (t.preventDefault(), IBe(e, t.clientX, t.clientY));
+ }), e.on("dispose", w6);
}
//#endregion
//#region src/player/registry.ts
-var E6 = null, D6 = () => E6;
-function O6(e) {
- E6 = e;
+var T6 = null, E6 = () => T6;
+function D6(e) {
+ T6 = e;
}
-function k6(e) {
+function O6(e) {
!e || e.isDisposed() || requestAnimationFrame(() => {
e.isDisposed() || e.trigger("resize");
});
}
//#endregion
//#region src/player/stats.ts
-function A6(e) {
+function k6(e) {
let t = e.currentTime || 0;
for (let n = 0; n < e.buffered.length; n++) if (e.buffered.start(n) <= t && e.buffered.end(n) >= t) return Math.max(0, e.buffered.end(n) - t);
return 0;
}
-function IBe(e) {
+function RBe(e) {
let t = e.currentTime || 0;
for (let n = 0; n < e.buffered.length; n++) if (e.buffered.start(n) <= t + .25 && e.buffered.end(n) >= t) return e.buffered.end(n);
return e.buffered.length ? e.buffered.end(e.buffered.length - 1) : 0;
}
-var j6 = 3e3;
-function M6(e, t) {
+var A6 = 3e3;
+function j6(e, t) {
let n = Number(e) || 0, r = p(t) || 0;
return n > 0 && r > 0 ? n * 8 / r : 0;
}
-function LBe(e) {
+function zBe(e) {
let t = [], n = null, r = 0, i = 0;
return {
bitrate: Number(e) || 0,
@@ -73780,10 +73832,10 @@ function LBe(e) {
},
sample(e) {
if (!e) return i;
- let a = performance.now(), o = IBe(e), s = e.currentTime || 0;
+ let a = performance.now(), o = RBe(e), s = e.currentTime || 0;
if (n) {
let e = (a - n.at) / 1e3, i = Math.abs(s - n.ct) > e * 4 + 1, c = o - n.frontier;
- !i && c > 0 && (r += c), e * 1e3 > j6 * 2 && (t.length = 0);
+ !i && c > 0 && (r += c), e * 1e3 > A6 * 2 && (t.length = 0);
}
for (n = {
at: a,
@@ -73792,56 +73844,56 @@ function LBe(e) {
}, t.push({
at: a,
advanced: r
- }); t.length > 2 && a - t[0].at > j6;) t.shift();
+ }); t.length > 2 && a - t[0].at > A6;) t.shift();
let c = t[0], l = (a - c.at) / 1e3, u = r - c.advanced;
return l >= .5 && u > 0 && this.bitrate > 0 && (i = u * this.bitrate / l), i;
}
};
}
-var N6 = 24;
-function P6(e, t) {
- e.push(Number.isFinite(t) && t > 0 ? t : 0), e.length > N6 && e.splice(0, e.length - N6);
+var M6 = 24;
+function N6(e, t) {
+ e.push(Number.isFinite(t) && t > 0 ? t : 0), e.length > M6 && e.splice(0, e.length - M6);
}
-var F6 = "peach-player-panel";
-function I6(e, t, n, r) {
- let a = [...Array(Math.max(0, N6 - e.length)).fill(null), ...e], o = Math.max(1, n || 0), s = a.map((e) => {
+var P6 = "peach-player-panel";
+function F6(e, t, n, r) {
+ let a = [...Array(Math.max(0, M6 - e.length)).fill(null), ...e], o = Math.max(1, n || 0), s = a.map((e) => {
if (e === null) return "<i aria-hidden=\"true\"></i>";
let n = e <= 0 ? 0 : Math.max(.08, Math.min(1, e / o));
return `<i data-bar="${t === "buffer" ? e < 5 ? "low" : e < 15 ? "mid" : "good" : "on"}" style="height:${(n * 100).toFixed(1)}%" aria-hidden="true"></i>`;
}).join("");
return `<span data-player-stats-plot="${t}" role="img" aria-label="${i(r)}">${s}</span>`;
}
-function RBe() {
+function BBe() {
return `<button data-player-stats-button="" id="playerStatsBtn" aria-label="播放统计" title="播放统计" aria-pressed="false" hidden>${l("chart")}</button>
<div data-player-net="" id="playerNet" role="status" aria-live="polite" hidden></div>
<div data-player-stats="" id="playerStats" role="status" hidden></div>`;
}
-function L6(e, t = "") {
+function I6(e, t = "") {
let n = t ? encodeURIComponent(t) : "";
return performance.getEntriesByType("resource").filter((t) => t.name.includes("/stream") && (t.name.includes(`/stream?id=${e}`) || t.name.includes(`/stream/hls/${e}/`)) && (!n || t.name.includes(`session=${n}`)));
}
-function R6(e, t = "") {
- let n = L6(e, t), r = n.reduce((e, t) => e + (t.transferSize || t.encodedBodySize || 0), 0), i = n.reduce((e, t) => e + (t.duration || 0), 0) / 1e3;
+function L6(e, t = "") {
+ let n = I6(e, t), r = n.reduce((e, t) => e + (t.transferSize || t.encodedBodySize || 0), 0), i = n.reduce((e, t) => e + (t.duration || 0), 0) / 1e3;
return r > 0 && i > 0 ? r * 8 / i : 0;
}
-function z6(e, t, n = "", r = null) {
+function R6(e, t, n = "", r = null) {
let i = 0;
try {
i = Number(e?.tech({ IWillNotUseThisInPlugins: !0 })?.vhs?.stats?.bandwidth) || 0;
} catch {}
- return i > 0 ? i : r ? Number(r.bits) || 0 : R6(t, n);
+ return i > 0 ? i : r ? Number(r.bits) || 0 : L6(t, n);
}
-function B6(e) {
+function z6(e) {
if (!Number.isFinite(e) || e <= 0) return "加载中…";
let t = e / 8;
return t >= 1048576 ? `${(t / 1048576).toFixed(1)} MB/s` : `${Math.max(1, Math.round(t / 1024))} KB/s`;
}
-function zBe(e, t) {
- return e > 0 ? B6(e) : t > 0 ? `已缓冲 ${Math.round(t)} 秒` : B6(0);
+function VBe(e, t) {
+ return e > 0 ? z6(e) : t > 0 ? `已缓冲 ${Math.round(t)} 秒` : z6(0);
}
//#endregion
//#region src/player/controls.ts
-function V6(e, t, n = "") {
+function B6(e, t, n = "") {
if (!e) return () => {};
let r = e.querySelector(":scope>.vjs-peach-tooltip");
r || (r = document.createElement("span"), r.className = "vjs-peach-tooltip", r.setAttribute("role", "tooltip"), r.innerHTML = "<span class=\"vjs-peach-tooltip-text\"></span><kbd hidden></kbd>", e.append(r));
@@ -73852,24 +73904,24 @@ function V6(e, t, n = "") {
};
return o(), o;
}
-function BBe(e, t = !0) {
- let n = x6(), r = n.settings();
+function HBe(e, t = !0) {
+ let n = b6(), r = n.settings();
r.ambientMode = !!e, t && n.saveSettings(), n.stage()?.toggleAttribute("data-ambient", r.ambientMode), document.dispatchEvent(new CustomEvent("peachambientchange", { detail: { enabled: r.ambientMode } }));
}
-var H6 = /* @__PURE__ */ new WeakMap();
-function U6(e) {
+var V6 = /* @__PURE__ */ new WeakMap();
+function H6(e) {
if (!e) return;
- let t = x6().settings().theaterMode;
- e.setAttribute("aria-pressed", String(t)), e.querySelector("use")?.setAttribute("href", t ? "#i-theater-exit" : "#i-theater-enter"), H6.get(e)?.(t ? "默认视图" : "影院模式");
+ let t = b6().settings().theaterMode;
+ e.setAttribute("aria-pressed", String(t)), e.querySelector("use")?.setAttribute("href", t ? "#i-theater-exit" : "#i-theater-enter"), V6.get(e)?.(t ? "默认视图" : "影院模式");
}
-function W6(e, t = !0) {
- let n = x6(), r = n.settings();
+function U6(e, t = !0) {
+ let n = b6(), r = n.settings();
r.theaterMode = !!e, t && n.saveSettings();
let i = n.stage();
- i?.toggleAttribute("data-theater", r.theaterMode), U6(i?.querySelector("[data-player-theater]")), k6(D6());
+ i?.toggleAttribute("data-theater", r.theaterMode), H6(i?.querySelector("[data-player-theater]")), O6(E6());
}
-function VBe(e) {
- let t = x6().stage(), n = t?.querySelector("[data-ambient-canvas]");
+function UBe(e) {
+ let t = b6().stage(), n = t?.querySelector("[data-ambient-canvas]");
if (!t || !n) return () => {};
let r = n.getContext("2d", { alpha: !1 });
if (!r) return () => {};
@@ -73886,14 +73938,14 @@ function VBe(e) {
e.requestVideoFrameCallback ? e.requestVideoFrameCallback((e) => u(t, e)) : requestAnimationFrame((e) => u(t, e));
}, u = (t, n) => {
if (!(i || t !== o)) {
- if (!x6().settings().ambientMode) {
+ if (!b6().settings().ambientMode) {
s();
return;
}
e.paused || (!document.hidden && n - a > 480 && (a = n, c()), l(t));
}
}, d = () => {
- i || !x6().settings().ambientMode || (c(), e.paused || l(++o));
+ i || !b6().settings().ambientMode || (c(), e.paused || l(++o));
}, f = (e) => {
let n = !!e.detail.enabled;
t.toggleAttribute("data-ambient", n), n ? d() : (o++, s());
@@ -73902,7 +73954,7 @@ function VBe(e) {
i = !0, o++, document.removeEventListener("peachambientchange", f), e.removeEventListener("play", d), e.removeEventListener("loadeddata", d), s();
};
}
-function HBe(e, t, n = 0, r = null) {
+function WBe(e, t, n = 0, r = null) {
let a = e.getChild("controlBar")?.el();
if (!a || a.querySelector("[data-player-quality]")) return;
let o = document.createElement("div");
@@ -73912,7 +73964,7 @@ function HBe(e, t, n = 0, r = null) {
let s = a.querySelector(".vjs-fullscreen-control");
a.insertBefore(o, s || null);
let c = o.querySelector("button"), u = o.querySelector("[data-player-quality-badge]");
- V6(c, "设置");
+ B6(c, "设置");
let d = o.querySelector(".vjs-peach-settings-menu"), f = typeof e.qualityLevels == "function" ? e.qualityLevels() : null, p = r, m = "auto", h = (e, t) => {
let n = [Number(e), Number(t)].filter((e) => e > 0);
return n.length ? Math.min(...n) : 0;
@@ -73954,11 +74006,11 @@ function HBe(e, t, n = 0, r = null) {
active: t
};
}, v = () => d.getAttribute("aria-hidden") !== "true", y = (e) => {
- d.setAttribute("aria-hidden", String(!e)), c.setAttribute("aria-expanded", String(e)), e && document.dispatchEvent(new CustomEvent(F6, { detail: "settings" }));
+ d.setAttribute("aria-hidden", String(!e)), c.setAttribute("aria-expanded", String(e)), e && document.dispatchEvent(new CustomEvent(P6, { detail: "settings" }));
}, b = () => y(!1), x = (e) => {
e.detail !== "settings" && b();
};
- document.addEventListener(F6, x);
+ document.addEventListener(P6, x);
let S = null, C = (e, t) => {
let n = d.querySelector(".vjs-peach-panel"), r = document.createElement("div");
if (r.className = "vjs-peach-panel", r.innerHTML = e, !n || !t || !v()) return d.replaceChildren(r), d.style.height = "", r;
@@ -73972,12 +74024,12 @@ function HBe(e, t, n = 0, r = null) {
}, 250);
}), r;
}, w = (e, t) => e.querySelector(t), T = (t = 0) => {
- let { active: n } = _(), r = Number(e.playbackRate()) || 1, a = C(`<div class="vjs-peach-panel-menu"><button type="button" class="vjs-peach-menu-row" role="menuitemcheckbox" data-player-ambient aria-checked="${x6().settings().ambientMode}">
+ let { active: n } = _(), r = Number(e.playbackRate()) || 1, a = C(`<div class="vjs-peach-panel-menu"><button type="button" class="vjs-peach-menu-row" role="menuitemcheckbox" data-player-ambient aria-checked="${b6().settings().ambientMode}">
${l("player-ambient")}<span>氛围模式</span><i class="vjs-peach-switch" aria-hidden="true"></i></button>
<button type="button" class="vjs-peach-menu-row" role="menuitem" data-player-speed>${l("player-speed")}<span>播放速度</span><b>${r === 1 ? "正常" : `${r}×`}</b>${l("player-menu-next")}</button>
<button type="button" class="vjs-peach-menu-row" role="menuitem" data-player-quality-view>${l("player-quality")}<span>清晰度</span><b>${i(n.label)}</b>${l("player-menu-next")}</button></div>`, t);
w(a, "[data-player-ambient]").onclick = () => {
- BBe(!x6().settings().ambientMode), T();
+ HBe(!b6().settings().ambientMode), T();
}, w(a, "[data-player-speed]").onclick = () => k(), w(a, "[data-player-quality-view]").onclick = () => A();
}, E = .05, D = [
1,
@@ -74034,22 +74086,22 @@ function HBe(e, t, n = 0, r = null) {
}), f?.on?.(["addqualitylevel", "removequalitylevel"], () => {
v() ? T() : _();
}), e.on("dispose", () => {
- document.removeEventListener("pointerdown", j), document.removeEventListener(F6, x), S && clearTimeout(S);
- }), _(), UBe(e, o), WBe(e), (e) => {
+ document.removeEventListener("pointerdown", j), document.removeEventListener(P6, x), S && clearTimeout(S);
+ }), _(), GBe(e, o), KBe(e), (e) => {
p = e?.length ? e : null, v() ? T() : _();
};
}
-function UBe(e, t) {
+function GBe(e, t) {
let n = e.getChild("controlBar")?.el();
if (!n || n.querySelector("[data-player-theater]")) return;
- let r = x6().settings().theaterMode, i = document.createElement("div");
+ let r = b6().settings().theaterMode, i = document.createElement("div");
i.className = "vjs-peach-theater vjs-control", i.innerHTML = `<button type="button" data-player-theater aria-pressed="${r}">${l(r ? "theater-exit" : "theater-enter")}</button>`, n.insertBefore(i, t.nextSibling);
let a = i.querySelector("button");
- H6.set(a, V6(a, "影院模式", "T")), U6(a), a.onclick = (e) => {
- e.stopPropagation(), W6(!x6().settings().theaterMode);
+ V6.set(a, B6(a, "影院模式", "T")), H6(a), a.onclick = (e) => {
+ e.stopPropagation(), U6(!b6().settings().theaterMode);
};
}
-function WBe(e) {
+function KBe(e) {
let t = e.getChild("controlBar")?.el();
if (!t || t.querySelector(".vjs-peach-right-controls")) return;
let n = t.querySelector(":scope>.vjs-play-control");
@@ -74061,7 +74113,7 @@ function WBe(e) {
e.dataset.peachExplicitIcon = "";
let r = document.createElementNS("http://www.w3.org/2000/svg", "svg");
return r.setAttribute("viewBox", n.getAttribute("viewBox") || ""), r.setAttribute("aria-hidden", "true"), r.setAttribute("class", "vjs-peach-control-icon vjs-peach-morph-icon"), r.innerHTML = n.innerHTML, e.append(r), r;
- }, o = (e) => [...document.getElementById(`i-${e}`)?.querySelectorAll("path") || []], s = i(n, "player-play")?.querySelector("path"), c = o("player-play")[0]?.getAttribute("d") || "", u = o("player-pause")[0]?.getAttribute("d") || "", d = V6(n, "播放", "K"), f = CSS.supports("d", "path(\"M0 0\")"), p = () => {
+ }, o = (e) => [...document.getElementById(`i-${e}`)?.querySelectorAll("path") || []], s = i(n, "player-play")?.querySelector("path"), c = o("player-play")[0]?.getAttribute("d") || "", u = o("player-pause")[0]?.getAttribute("d") || "", d = B6(n, "播放", "K"), f = CSS.supports("d", "path(\"M0 0\")"), p = () => {
let t = e.paused() || e.ended(), n = t ? c : u;
s && (f ? s.style.setProperty("d", `path("${n}")`) : s.setAttribute("d", n)), d(t ? "播放" : "暂停");
};
@@ -74072,7 +74124,7 @@ function WBe(e) {
], p), p();
let m = t.querySelector(":scope>.vjs-volume-panel"), h = m?.querySelector(":scope>.vjs-mute-control"), g = i(h, "player-volume");
g && o("player-volume-muted").forEach((e) => g.append(e.cloneNode(!0)));
- let _ = V6(h, "静音", "M"), v = () => {
+ let _ = B6(h, "静音", "M"), v = () => {
let t = e.muted() || e.volume() === 0;
g && (g.dataset.silent = String(t), g.dataset.loud = String(!t && e.volume() > .5)), _(t ? "取消静音" : "静音");
};
@@ -74098,7 +74150,7 @@ function WBe(e) {
});
let C = document.createElement("button"), w = !1;
C.type = "button", C.className = "vjs-peach-time vjs-control", C.dataset.playerTime = "", C.innerHTML = "<span class=\"vjs-peach-time-text\"></span>";
- let T = C.querySelector(".vjs-peach-time-text"), E = V6(C, "显示剩余时间"), D = () => {
+ let T = C.querySelector(".vjs-peach-time-text"), E = B6(C, "显示剩余时间"), D = () => {
let t = Math.max(0, Number(e.currentTime()) || 0), n = Math.max(0, Number(e.duration()) || 0), r = a(Math.max(0, n - t));
T.textContent = `${w ? `-${r}` : a(t)} / ${a(n)}`, C.dataset.remaining = String(w), E(w ? "显示已播放时间" : "显示剩余时间", w ? `剩余 ${r},总时长 ${a(n)};点击显示已播放时间` : `已播放 ${a(t)},总时长 ${a(n)};点击显示剩余时间`);
};
@@ -74111,11 +74163,11 @@ function WBe(e) {
], D), D(), m ? m.insertAdjacentElement("afterend", C) : t.append(C);
let O = t.querySelector(":scope>.vjs-picture-in-picture-control");
r(O, "player-pip");
- let k = V6(O, "画中画");
+ let k = B6(O, "画中画");
e.on(["enterpictureinpicture", "leavepictureinpicture"], () => k(document.pictureInPictureElement ? "退出画中画" : "画中画"));
- let A = t.querySelector(":scope>.vjs-fullscreen-control"), j = r(A, "player-fullscreen-enter"), M = V6(A, "全屏", "F"), N = () => {
+ let A = t.querySelector(":scope>.vjs-fullscreen-control"), j = r(A, "player-fullscreen-enter"), M = B6(A, "全屏", "F"), N = () => {
let t = !!e.isFullscreen();
- e.el().toggleAttribute("data-peach-fullscreen", t), j?.setAttribute("href", t ? "#i-player-fullscreen-exit" : "#i-player-fullscreen-enter"), M(t ? "退出全屏" : "全屏"), k6(e);
+ e.el().toggleAttribute("data-peach-fullscreen", t), j?.setAttribute("href", t ? "#i-player-fullscreen-exit" : "#i-player-fullscreen-enter"), M(t ? "退出全屏" : "全屏"), O6(e);
};
e.on([
"fullscreenchange",
@@ -74135,7 +74187,7 @@ function WBe(e) {
});
let F = document.createElement("div");
F.className = "vjs-peach-expand vjs-control", F.innerHTML = `<button type="button" data-player-expand aria-expanded="false">${l("player-expand")}</button><span class="vjs-peach-hover" aria-hidden="true"></span>`, ee.prepend(F);
- let I = F.querySelector("button"), te = V6(I, "展开控件"), ne = (t) => {
+ let I = F.querySelector("button"), te = B6(I, "展开控件"), ne = (t) => {
e.el().classList.toggle("vjs-peach-right-expanded", t), I.setAttribute("aria-expanded", String(t)), te(t ? "收起控件" : "展开控件");
};
I.onclick = (t) => {
@@ -74147,7 +74199,7 @@ function WBe(e) {
}, ie = new ResizeObserver(re);
ie.observe(e.el()), e.on("dispose", () => ie.disconnect()), ne(!1), re();
}
-function GBe(e, n, r = {}) {
+function qBe(e, n, r = {}) {
let i = e.getChild("controlBar")?.el()?.querySelector(".vjs-progress-control");
if (!i || i.querySelector("[data-player-seek-preview]")) return;
let o = r.thumbnail !== !1, s = document.createElement("div");
@@ -74180,13 +74232,13 @@ function GBe(e, n, r = {}) {
i.removeEventListener("pointermove", g), i.removeEventListener("pointerleave", _);
});
}
-function KBe(e, t) {
+function JBe(e, t) {
let n = navigator.mediaSession;
if (!n || typeof n.setActionHandler != "function") return;
let r = () => p(e.duration()) || p(t.duration) || 0, i = (t) => {
let n = r();
e.currentTime(Math.max(0, n ? Math.min(n, t) : t));
- }, a = () => Math.max(1, Number(x6().settings().seekSeconds) || 10), o = [
+ }, a = () => Math.max(1, Number(b6().settings().seekSeconds) || 10), o = [
["play", () => {
e.play();
}],
@@ -74227,11 +74279,11 @@ function KBe(e, t) {
} catch {}
});
}
-function qBe(e) {
+function YBe(e) {
let t = e.el().querySelector(".vjs-loading-spinner");
!t || t.querySelector(".vjs-peach-spinner-container") || (t.innerHTML = "<span class=\"vjs-peach-spinner-container\"><span class=\"vjs-peach-spinner-rotator\"><span class=\"vjs-peach-spinner-left\"><span class=\"vjs-peach-spinner-circle\"></span></span><span class=\"vjs-peach-spinner-right\"><span class=\"vjs-peach-spinner-circle\"></span></span></span></span>");
}
-function JBe(e, n) {
+function XBe(e, n) {
t(`/api/assets/${n}/subtitles`).then((t) => {
!e || e.isDisposed() || (t?.subtitles || []).filter((e) => e.playable).forEach((t) => {
e.addRemoteTextTrack({
@@ -74246,7 +74298,7 @@ function JBe(e, n) {
}
//#endregion
//#region src/player/dispose.ts
-function G6(e) {
+function W6(e) {
if (!e || e.isDisposed()) return;
let t = e.el()?.querySelector("video");
try {
@@ -74264,23 +74316,23 @@ function G6(e) {
}
//#endregion
//#region src/player/stream.ts
-function K6() {
+function G6() {
return globalThis.crypto?.randomUUID?.() || `${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`;
}
-function q6(e, t) {
+function K6(e, t) {
return {
src: `/stream?id=${e.id}&session=${encodeURIComponent(t)}`,
type: String(e.name || "").toLowerCase().endsWith(".webm") ? "video/webm" : "video/mp4"
};
}
-function YBe(e) {
+function ZBe(e) {
return e.location === "online" && e.follow_item_id ? {
src: `/follow-stream?id=${e.follow_item_id}`,
type: "video/mp4"
} : null;
}
-async function J6(e, n) {
- let r = YBe(e);
+async function q6(e, n) {
+ let r = ZBe(e);
if (r) return r;
try {
let r = await t(`/api/stream-plan?id=${e.id}&session=${encodeURIComponent(n)}`);
@@ -74289,9 +74341,9 @@ async function J6(e, n) {
type: r.mime_type || "application/vnd.apple.mpegurl"
};
} catch {}
- return q6(e, n);
+ return K6(e, n);
}
-function Y6(e) {
+function J6(e) {
e && fetch(`/api/stream-cancel?session=${encodeURIComponent(e)}`, {
method: "POST",
credentials: "same-origin",
@@ -74300,21 +74352,21 @@ function Y6(e) {
document.documentElement.dataset.peachStreamCancel = JSON.stringify(e);
}).catch(() => {});
}
-var X6 = "";
+var Y6 = "";
+function X6() {
+ return Y6;
+}
function Z6() {
- return X6;
+ return Y6 ||= G6(), Y6;
}
+var QBe = (e) => K6(e, Z6()), $Be = (e) => q6(e, Z6());
function Q6() {
- return X6 ||= K6(), X6;
-}
-var XBe = (e) => q6(e, Q6()), ZBe = (e) => J6(e, Q6());
-function $6() {
- let e = X6;
- e && (X6 = "", Y6(e));
+ let e = Y6;
+ e && (Y6 = "", J6(e));
}
//#endregion
//#region src/player/telemetry.ts
-function e8(e, n, r = {}) {
+function $6(e, n, r = {}) {
if (!n) return;
let i = 0, a = 0, o = 0, s = null;
n.addEventListener("seeking", () => {
@@ -74362,7 +74414,7 @@ function e8(e, n, r = {}) {
d(), u(!1);
}, { once: !0 }), l();
}
-function QBe(e, n) {
+function eVe(e, n) {
let r = 0, i = 0, a = !1, o = null, s = (r) => {
let a = p(e.duration) || p(n.duration);
!i && !r || (t("/api/follow/activity", {
@@ -74398,7 +74450,7 @@ function QBe(e, n) {
}
//#endregion
//#region src/player/videojs.ts
-var t8 = "/vendor/videojs/8.24.1/", n8 = (e) => new Promise((t, n) => {
+var e8 = "/vendor/videojs/8.24.1/", t8 = (e) => new Promise((t, n) => {
let r = document.head.querySelector(`script[src="${e}"]`);
if (r?.dataset.loaded) {
t();
@@ -74410,20 +74462,20 @@ var t8 = "/vendor/videojs/8.24.1/", n8 = (e) => new Promise((t, n) => {
}, { once: !0 }), i.addEventListener("error", () => {
i.remove(), n(/* @__PURE__ */ Error(`script unavailable: ${e}`));
}, { once: !0 }), r || (i.src = e, document.head.appendChild(i));
-}), r8 = () => globalThis.videojs, i8 = null;
-function a8() {
- let e = r8();
- return e ? Promise.resolve(e) : (i8 ??= n8(`${t8}video.min.js`).then(() => n8(`${t8}lang/zh-CN.js`)).then(() => {
- let e = r8();
+}), n8 = () => globalThis.videojs, r8 = null;
+function i8() {
+ let e = n8();
+ return e ? Promise.resolve(e) : (r8 ??= t8(`${e8}video.min.js`).then(() => t8(`${e8}lang/zh-CN.js`)).then(() => {
+ let e = n8();
if (!e) throw Error("videojs unavailable");
return e;
}).catch((e) => {
- throw i8 = null, e;
- }), i8);
+ throw r8 = null, e;
+ }), r8);
}
//#endregion
//#region src/player/immerse-player.ts
-var $Be = {
+var tVe = {
controls: !1,
preload: "auto",
posterImage: !1,
@@ -74435,37 +74487,37 @@ var $Be = {
errorDisplay: !1,
textTrackSettings: !1
};
-function eVe(e, t) {
+function nVe(e, t) {
let { item: n, session: r } = t, i = null, a = !1;
- return Promise.all([J6(n, r), a8().catch(() => null)]).then(([o, s]) => {
+ return Promise.all([q6(n, r), i8().catch(() => null)]).then(([o, s]) => {
if (a) return;
- let c = q6(n, r), l = String(o.type || "").includes("mpegurl");
+ let c = K6(n, r), l = String(o.type || "").includes("mpegurl");
if (!s) e.src = (l ? c : o).src;
else {
- let t = s(e, $Be);
+ let t = s(e, tVe);
i = t, l && t.one("error", () => {
a || t.src(c);
}), t.src(o);
}
- e8(n, e, t.onEnded ? { onEnded: t.onEnded } : {}), t.onLoaded?.();
+ $6(n, e, t.onEnded ? { onEnded: t.onEnded } : {}), t.onLoaded?.();
}), () => {
- a || (a = !0, Y6(r), i ? G6(i) : (e.pause(), e.removeAttribute("src"), e.load()));
+ a || (a = !0, J6(r), i ? W6(i) : (e.pause(), e.removeAttribute("src"), e.load()));
};
}
//#endregion
//#region src/player/detail-player.ts
-var o8 = /* @__PURE__ */ new WeakMap(), s8 = null, c8 = null, l8 = null;
-function u8() {
- s8 &&= (clearInterval(s8), null), c8 &&= (clearInterval(c8), null), l8 &&= (clearTimeout(l8), null);
+var a8 = /* @__PURE__ */ new WeakMap(), o8 = null, s8 = null, c8 = null;
+function l8() {
+ o8 &&= (clearInterval(o8), null), s8 &&= (clearInterval(s8), null), c8 &&= (clearTimeout(c8), null);
}
-async function tVe(e, t, n, r = {}) {
- let o = D6();
+async function rVe(e, t, n, r = {}) {
+ let o = E6();
if (o && !o.isDisposed()) return o;
- let c = x6(), u = r.resume ?? null;
+ let c = b6(), u = r.resume ?? null;
u?.autoplay && (n = !0);
- let d = () => r.source ? Promise.resolve(r.source) : ZBe(e), f;
+ let d = () => r.source ? Promise.resolve(r.source) : $Be(e), f;
try {
- f = await a8();
+ f = await i8();
} catch {
return t.controls = !0, d().then((e) => {
t.src = e.src, n && t.play().catch(() => {});
@@ -74485,7 +74537,7 @@ async function tVe(e, t, n, r = {}) {
remainingTimeDisplay: !1
}
});
- O6(m), m.peachItem = e, FBe(m), m.on("loadedmetadata", () => {
+ D6(m), m.peachItem = e, LBe(m), m.on("loadedmetadata", () => {
let e = m.el()?.querySelector("video");
e?.videoWidth && e.videoHeight && m.el().style.setProperty("--peach-video-ratio", `${e.videoWidth}/${e.videoHeight}`);
});
@@ -74493,7 +74545,7 @@ async function tVe(e, t, n, r = {}) {
speed: [],
activity: [],
buffer: []
- }, _ = Number(r.size ?? e.size) || 0, v = LBe(M6(_, e.duration)), y = 0, b = !1, x = () => D6() === m && !m.isDisposed(), S = () => {
+ }, _ = Number(r.size ?? e.size) || 0, v = zBe(j6(_, e.duration)), y = 0, b = !1, x = () => E6() === m && !m.isDisposed(), S = () => {
if (!h || b || !x()) return;
let e = Number(m.duration());
(!Number.isFinite(e) || Math.abs(e - h) > Math.max(2, h * .001)) && (b = !0, m.duration(h), queueMicrotask(() => {
@@ -74504,15 +74556,15 @@ async function tVe(e, t, n, r = {}) {
ready: !1,
updateStats: () => {}
};
- o8.set(m, w), w.updateStats = () => {
+ a8.set(m, w), w.updateStats = () => {
let n = w.chrome?.statsPanel;
if (!n || n.hidden || !x()) return;
- let o = t.getVideoPlaybackQuality ? t.getVideoPlaybackQuality() : null, c = t.getBoundingClientRect(), l = `${t.videoWidth || e.width || "?"}×${t.videoHeight || e.height || "?"}`, u = C(), d = Z6(), f = u ? L6(e.id, d) : [], p = f.reduce((e, t) => e + (t.transferSize || t.encodedBodySize || 0), 0), b = f.reduce((e, t) => e + (t.duration || 0), 0) / 1e3;
+ let o = t.getVideoPlaybackQuality ? t.getVideoPlaybackQuality() : null, c = t.getBoundingClientRect(), l = `${t.videoWidth || e.width || "?"}×${t.videoHeight || e.height || "?"}`, u = C(), d = X6(), f = u ? I6(e.id, d) : [], p = f.reduce((e, t) => e + (t.transferSize || t.encodedBodySize || 0), 0), b = f.reduce((e, t) => e + (t.duration || 0), 0) / 1e3;
v.sample(t);
- let S = z6(m, e.id, d, u ? null : v) || (b > 0 ? p * 8 / b : 0), T = u ? p : v.bitrate > 0 ? v.bytes() : v.seconds, E = Math.max(0, T - y);
+ let S = R6(m, e.id, d, u ? null : v) || (b > 0 ? p * 8 / b : 0), T = u ? p : v.bitrate > 0 ? v.bytes() : v.seconds, E = Math.max(0, T - y);
y = T;
- let D = A6(t);
- P6(g.speed, S), P6(g.activity, E), P6(g.buffer, D);
+ let D = k6(t);
+ N6(g.speed, S), N6(g.activity, E), N6(g.buffer, D);
let O = String(e.name || ""), k = (O.includes(".") ? O.split(".").pop() || "" : u ? "" : String(m.currentSource()?.type || "").split("/").pop() || "").toUpperCase() || "—", A = S ? `${(S / 1e6).toFixed(1)} Mbps` : "—", j = u || v.bitrate > 0, M = u ? [
"网络活动",
`${p ? s(p) : "—"} · ${f.length} 请求`,
@@ -74530,17 +74582,17 @@ async function tVe(e, t, n, r = {}) {
[
"连接速度",
A,
- I6(g.speed, "speed", Math.max(1e7, ...g.speed), `连接速度 ${A === "—" ? "暂无数据" : A}`)
+ F6(g.speed, "speed", Math.max(1e7, ...g.speed), `连接速度 ${A === "—" ? "暂无数据" : A}`)
],
[
M[0],
M[1],
- I6(g.activity, "activity", Math.max(1, ...g.activity), M[2])
+ F6(g.activity, "activity", Math.max(1, ...g.activity), M[2])
],
[
"缓冲健康",
`${D.toFixed(1)} 秒`,
- I6(g.buffer, "buffer", 30, `当前可连续播放 ${D.toFixed(1)} 秒`)
+ F6(g.buffer, "buffer", 30, `当前可连续播放 ${D.toFixed(1)} 秒`)
],
["播放时间", `${a(t.currentTime)} / ${a(h || m.duration())}`],
["日期", (/* @__PURE__ */ new Date()).toLocaleString()]
@@ -74556,15 +74608,15 @@ async function tVe(e, t, n, r = {}) {
if (!n || m.isDisposed()) return;
let r = C();
r || v.sample(t);
- let a = z6(m, e.id, Z6(), r ? null : v), o = r ? B6(a) : zBe(a, A6(t));
+ let a = R6(m, e.id, X6(), r ? null : v), o = r ? z6(a) : VBe(a, k6(t));
n.innerHTML = `${l("gauge")}<span class="sr-only">加载速度</span><span>${i(o)}</span>`;
}, O = () => {
let e = w.chrome?.netBadge;
- !e || !e.isConnected || (e.hidden = !1, D(), c8 && clearInterval(c8), c8 = setInterval(D, 500));
+ !e || !e.isConnected || (e.hidden = !1, D(), s8 && clearInterval(s8), s8 = setInterval(D, 500));
}, k = () => {
let e = w.chrome?.netBadge;
- e && (l8 && clearTimeout(l8), l8 = setTimeout(() => {
- e.hidden = !0, c8 &&= (clearInterval(c8), null);
+ e && (c8 && clearTimeout(c8), c8 = setTimeout(() => {
+ e.hidden = !0, s8 &&= (clearInterval(s8), null);
}, 1400));
};
return m.on([
@@ -74576,7 +74628,7 @@ async function tVe(e, t, n, r = {}) {
D(), k();
}), m.on("error", () => {
if (T && !E && !m.isDisposed()) {
- E = !0, T = !1, m.src(XBe(e)), n && m.play()?.catch(() => {});
+ E = !0, T = !1, m.src(QBe(e)), n && m.play()?.catch(() => {});
return;
}
r.checkSourceStatus !== !1 && c.loadSourceStatus().then((t) => {
@@ -74587,27 +74639,27 @@ async function tVe(e, t, n, r = {}) {
});
}), m.ready(() => {
S();
- let n = HBe(m, t, e.height, r.qualities ?? null);
+ let n = WBe(m, t, e.height, r.qualities ?? null);
r.mediaPromise?.then((t) => {
if (!x()) return;
n?.(t?.qualities?.length ? t.qualities : null);
let r = Number(t?.size) || 0;
- r > 0 && !_ && (_ = r, v.bitrate = M6(r, e.duration));
- }).catch(() => {}), GBe(m, e, { thumbnail: !r.source }), KBe(m, e), qBe(m), r.source || JBe(m, e.id), w.ready = !0, w.chrome?.statsButton && (w.chrome.statsButton.hidden = !1);
+ r > 0 && !_ && (_ = r, v.bitrate = j6(r, e.duration));
+ }).catch(() => {}), qBe(m, e, { thumbnail: !r.source }), JBe(m, e), YBe(m), r.source || XBe(m, e.id), w.ready = !0, w.chrome?.statsButton && (w.chrome.statsButton.hidden = !1);
}), d().then((e) => {
x() && (T = String(e.type || "").includes("mpegurl"), m.src(e), S(), setTimeout(S, 0), setTimeout(S, 250), u && u.time > 0 && m.one("loadedmetadata", () => {
m.isDisposed() || m.currentTime(u.time);
}), n && m.play()?.catch(() => {}));
}).catch(() => {}), m;
}
-var nVe = "<canvas data-ambient-canvas=\"\" width=\"32\" height=\"18\"></canvas>";
-function d8(e, t = null) {
- if (e.querySelector(":scope > [data-ambient-canvas]") || e.insertAdjacentHTML("afterbegin", nVe), e.querySelector(":scope > #playerStatsBtn")) return;
+var iVe = "<canvas data-ambient-canvas=\"\" width=\"32\" height=\"18\"></canvas>";
+function u8(e, t = null) {
+ if (e.querySelector(":scope > [data-ambient-canvas]") || e.insertAdjacentHTML("afterbegin", iVe), e.querySelector(":scope > #playerStatsBtn")) return;
let n = document.createElement("template");
- n.innerHTML = RBe(), e.insertBefore(n.content, t);
+ n.innerHTML = BBe(), e.insertBefore(n.content, t);
}
-function f8(e, t) {
- let n = o8.get(e);
+function d8(e, t) {
+ let n = a8.get(e);
if (!n || e.isDisposed()) return () => {};
let r = (e) => t.querySelector(`:scope > #${e}`), i = {
statsButton: r("playerStatsBtn"),
@@ -74619,29 +74671,29 @@ function f8(e, t) {
if (a && o) {
a.hidden = !n.ready;
let e = () => {
- o.hidden || (o.hidden = !0, a.setAttribute("aria-pressed", "false"), s8 &&= (clearInterval(s8), null));
+ o.hidden || (o.hidden = !0, a.setAttribute("aria-pressed", "false"), o8 &&= (clearInterval(o8), null));
};
a.onclick = () => {
if (!o.hidden) {
e();
return;
}
- document.dispatchEvent(new CustomEvent(F6, { detail: "stats" })), o.hidden = !1, a.setAttribute("aria-pressed", "true"), n.updateStats(), s8 && clearInterval(s8), s8 = setInterval(n.updateStats, 1e3);
+ document.dispatchEvent(new CustomEvent(P6, { detail: "stats" })), o.hidden = !1, a.setAttribute("aria-pressed", "true"), n.updateStats(), o8 && clearInterval(o8), o8 = setInterval(n.updateStats, 1e3);
};
let t = (t) => {
t.detail !== "stats" && e();
};
- document.addEventListener(F6, t), s = () => document.removeEventListener(F6, t);
+ document.addEventListener(P6, t), s = () => document.removeEventListener(P6, t);
}
- let c = e.el().querySelector("video"), l = c ? VBe(c) : () => {}, u = !0, d = () => {
- u && (u = !1, s(), l(), n.chrome === i && (n.chrome = null, u8()));
+ let c = e.el().querySelector("video"), l = c ? UBe(c) : () => {}, u = !0, d = () => {
+ u && (u = !1, s(), l(), n.chrome === i && (n.chrome = null, l8()));
};
return e.one("dispose", d), d;
}
-function p8(e, n) {
- if (n.kind === "immerse") return eVe(e, n);
- let { kind: r, item: i, media: a = null, handedOff: o, onPlayer: s } = n, c = x6(), l = n.chrome === !1 ? null : e.parentElement;
- l && d8(l, e);
+function f8(e, n) {
+ if (n.kind === "immerse") return nVe(e, n);
+ let { kind: r, item: i, media: a = null, handedOff: o, onPlayer: s } = n, c = b6(), l = n.chrome === !1 ? null : e.parentElement;
+ l && u8(l, e);
let u = { resume: n.resume ?? null };
if (r === "follow") u = {
...u,
@@ -74661,16 +74713,16 @@ function p8(e, n) {
method: "POST",
body: JSON.stringify({ id: i.id })
}).catch(() => {});
- }, { once: !0 }), e8(i, e, {
+ }, { once: !0 }), $6(i, e, {
watched: "#watched",
mark: "#mark",
ratio: "#ratioTxt"
});
}
let d = null, f = !1, p = () => {}, m = () => {
- p(), !(!d || o?.(d)) && (D6() === d && (O6(null), u8()), G6(d));
+ p(), !(!d || o?.(d)) && (E6() === d && (D6(null), l8()), W6(d));
};
- return tVe(i, e, n.autoplay ?? c.settings().detailAutoplay, u).then((t) => {
+ return rVe(i, e, n.autoplay ?? c.settings().detailAutoplay, u).then((t) => {
if (d = t, f) {
m();
return;
@@ -74679,47 +74731,47 @@ function p8(e, n) {
s?.(null);
return;
}
- l && (p = f8(t, l)), r === "follow" && QBe(i, e), s?.(t);
+ l && (p = d8(t, l)), r === "follow" && eVe(i, e), s?.(t);
}), () => {
f = !0, m();
};
}
//#endregion
//#region src/player/playback.ts
-function m8(e) {
+function p8(e) {
e && (e.paused ? e.play()?.catch(() => {}) : e.pause());
}
-function rVe(e, t) {
+function aVe(e, t) {
let n = e.duration, r = (e.currentTime || 0) + t;
e.currentTime = Number.isFinite(n) ? Math.max(0, Math.min(n, r)) : Math.max(0, r);
}
//#endregion
//#region src/react/item-detail/item-detail.ts
-var h8 = (e) => ["item", e], g8 = (e) => [
+var m8 = (e) => ["item", e], h8 = (e) => [
"item-queue",
e.kind,
e.kind === "playlist" ? e.playlistId : e.seedId
-], iVe = (e, t) => [
+], oVe = (e, t) => [
"item-related",
e,
t
-], aVe = (e) => `/api/item?id=${e}`, oVe = (e, t) => `/api/related?id=${e}&limit=${t}`, _8 = "/api/playlist", v8 = "/api/feedback", y8 = "/api/item-tag", b8 = "/api/watch-later", x8 = "/api/quality-goal", S8 = "/api/preference", C8 = class extends Error {};
-async function w8(e, t) {
- let n = await W(aVe(e), t);
- if (n.error) throw new C8(n.error);
+], sVe = (e) => `/api/item?id=${e}`, cVe = (e, t) => `/api/related?id=${e}&limit=${t}`, g8 = "/api/playlist", _8 = "/api/feedback", v8 = "/api/item-tag", y8 = "/api/watch-later", b8 = "/api/quality-goal", x8 = "/api/preference", S8 = class extends Error {};
+async function C8(e, t) {
+ let n = await W(sVe(e), t);
+ if (n.error) throw new S8(n.error);
return n;
}
-async function T8(e, t, n) {
+async function w8(e, t, n) {
if (e.kind === "mix") {
- let r = e.seedId, [i, a] = await Promise.all([w8(r, n), t.mixRelated(r)]);
- return X.setQueryData(h8(i.id), i), {
+ let r = e.seedId, [i, a] = await Promise.all([C8(r, n), t.mixRelated(r)]);
+ return X.setQueryData(m8(i.id), i), {
kind: "mix",
seedId: r,
title: `Mix · ${t.mixLabel(i)}`,
items: [i, ...a.filter((e) => e.id !== i.id)]
};
}
- if (e.kind === "playlist") return E8(await W(`${_8}?id=${e.playlistId}`, n));
+ if (e.kind === "playlist") return T8(await W(`${g8}?id=${e.playlistId}`, n));
let r = await W(`/api/${e.kind}?id=${e.seedId}`, n);
if (r.error || !r.items?.length) throw Error(r.error || "这一组已不存在");
return {
@@ -74729,19 +74781,19 @@ async function T8(e, t, n) {
items: r.items
};
}
-var E8 = (e) => ({
+var T8 = (e) => ({
kind: "playlist",
playlistId: e.id,
title: e.name,
items: e.items || [],
currentAssetId: e.current_asset_id
-}), D8 = (e) => e.disposal === "vanished";
-function O8(e, t) {
+}), E8 = (e) => e.disposal === "vanished";
+function D8(e, t) {
if (e.kind === "mix") return t;
- let n = e.kind === "playlist" ? e.items.filter((e) => !D8(e)) : e.items;
+ let n = e.kind === "playlist" ? e.items.filter((e) => !E8(e)) : e.items;
return n.length ? t != null && n.some((e) => e.id === t) ? t : e.kind === "playlist" && n.some((t) => t.id === e.currentAssetId) ? e.currentAssetId : n[0].id : null;
}
-function sVe(e, t) {
+function lVe(e, t) {
if (t?.kind !== "parts") return e;
let n = t.items.find((t) => t.id === e.id)?.part_label || "";
return e.part_label === n ? e : {
@@ -74749,14 +74801,14 @@ function sVe(e, t) {
part_label: n
};
}
-async function cVe(e, t) {
+async function uVe(e, t) {
let { queue: n, actions: r } = e, i = null;
if (n) {
- let a = g8(n);
+ let a = h8(n);
try {
i = (n.fresh ? void 0 : X.getQueryData(a)) || await X.fetchQuery({
queryKey: a,
- queryFn: () => T8(n, e.helpers, t),
+ queryFn: () => w8(n, e.helpers, t),
staleTime: 0
});
} catch (n) {
@@ -74769,19 +74821,19 @@ async function cVe(e, t) {
}
e.grid.cache(i.items);
}
- let a = i ? O8(i, e.id) : e.id;
+ let a = i ? D8(i, e.id) : e.id;
if (a == null) {
r.redirect(i?.kind === "playlist" ? { kind: "playlists" } : { kind: "gone" });
return;
}
let o;
try {
- o = X.getQueryData(h8(a)) || await X.fetchQuery({
- queryKey: h8(a),
- queryFn: () => w8(a, t)
+ o = X.getQueryData(m8(a)) || await X.fetchQuery({
+ queryKey: m8(a),
+ queryFn: () => C8(a, t)
});
} catch (e) {
- if (e instanceof C8) {
+ if (e instanceof S8) {
r.redirect({ kind: "gone" });
return;
}
@@ -74792,7 +74844,7 @@ async function cVe(e, t) {
id: Number(o.follow_item_id)
});
}
-function lVe(e) {
+function dVe(e) {
let t = e.entity_refs || {}, n = /* @__PURE__ */ new Set(), r = (e) => {
let t = c(e.name);
return !e.name || n.has(t) ? !1 : (n.add(t), !0);
@@ -74813,42 +74865,42 @@ function lVe(e) {
unowned: !i.length && !l.length && !String(e.creator || "").trim()
};
}
-var k8 = (e) => Math.min(Math.max(e || 0, 0), 100), A8 = (e) => Math.round(k8(e) / 20), uVe = (e) => {
- let t = A8(e);
+var O8 = (e) => Math.min(Math.max(e || 0, 0), 100), k8 = (e) => Math.round(O8(e) / 20), fVe = (e) => {
+ let t = k8(e);
return t ? `${t} 星` : "未评分";
-}, dVe = (e, t) => {
+}, pVe = (e, t) => {
let n = t * 20;
return n === (e || 0) ? 0 : n;
};
-function fVe(e, t) {
+function mVe(e, t) {
let n = /* @__PURE__ */ new Map();
return (e.tags || []).filter((e) => !t.isDurationTag(e.k)).forEach((e) => {
let r = c(t.tagLabel(e.k)), i = n.get(r);
(!i || c(e.k) === r && c(i.k) !== r) && n.set(r, e);
}), [...n.values()].slice(0, 40);
}
-var j8 = (e, t) => (e.tags || []).some((e) => c(e.k) === c(t)), M8 = (e, t) => ({
+var A8 = (e, t) => (e.tags || []).some((e) => c(e.k) === c(t)), j8 = (e, t) => ({
...e,
tags: (e.tags || []).filter((e) => c(e.k) !== c(t))
-}), N8 = (e, t) => j8(e, t.k) ? e : {
+}), M8 = (e, t) => A8(e, t.k) ? e : {
...e,
tags: [...e.tags || [], t]
-}, P8 = "peach.recentTags";
-function F8() {
+}, N8 = "peach.recentTags";
+function P8() {
try {
- let e = JSON.parse(localStorage.getItem(P8) || "[]");
+ let e = JSON.parse(localStorage.getItem(N8) || "[]");
return Array.isArray(e) ? e.map(String) : [];
} catch {
return [];
}
}
-function pVe(e) {
+function hVe(e) {
try {
- let t = F8().filter((t) => c(t) !== c(e));
- localStorage.setItem(P8, JSON.stringify([e, ...t].slice(0, 12)));
+ let t = P8().filter((t) => c(t) !== c(e));
+ localStorage.setItem(N8, JSON.stringify([e, ...t].slice(0, 12)));
} catch {}
}
-function mVe(e, t, n) {
+function gVe(e, t, n) {
let r = c(e), i = new Map(t.map((e) => [c(e.k), e])), a = t.filter((e) => !r || c(e.k).includes(r)).slice(0, 120), o = r ? [] : n.map((e) => i.get(c(e)) || {
k: e,
n: 0
@@ -74859,73 +74911,73 @@ function mVe(e, t, n) {
create: r && !s ? e.trim() : ""
};
}
-var hVe = {
+var _Ve = {
中字: "subtitle",
无码: "uncensored",
无码破解: "cracked",
有码: "censored"
-}, gVe = {
+}, vVe = {
mix: "Mix",
parts: "分卷",
editions: "版本",
playlist: "播放列表"
};
-function _Ve(e) {
+function yVe(e) {
let t = e.items.length, n = e.kind === "parts" ? `${t} 卷` : e.kind === "editions" ? `${t} 个版本` : `${t} 个视频`;
return {
- title: gVe[e.kind],
+ title: vVe[e.kind],
summary: e.kind === "editions" ? n : `${e.title} · ${n}`
};
}
-var I8 = (e = "") => /^(?:\d+|[a-h])$/i.test(e) ? `第 ${e} 卷` : e, vVe = (e, t) => t?.kind === "parts" && e.part_label ? `<small class="javedition partlabel">${i(I8(e.part_label))}</small>` : "";
-function yVe(e, t, n, r) {
+var F8 = (e = "") => /^(?:\d+|[a-h])$/i.test(e) ? `第 ${e} 卷` : e, bVe = (e, t) => t?.kind === "parts" && e.part_label ? `<small class="javedition partlabel">${i(F8(e.part_label))}</small>` : "";
+function xVe(e, t, n, r) {
let i = e.filter((e) => e !== t), a = i.indexOf(n);
return i.splice(a + +!!r, 0, t), i;
}
-var bVe = (e, t) => e.length === t.length && e.every((e, n) => e === t[n]);
-function xVe(e, t) {
+var SVe = (e, t) => e.length === t.length && e.every((e, n) => e === t[n]);
+function CVe(e, t) {
return t ? "offline" : e.location === "online" && !e.follow_item_id ? "online" : e.cost === "metered" && e.location !== "online" ? "metered" : "";
}
-function SVe(e) {
+function wVe(e) {
let t = Number(e.duration) > 0 ? Number(e.duration) : 0;
return !e.play_seconds || !t ? null : Math.min(Number(e.play_seconds) / t, 1) * 100;
}
-function L8(e, t) {
+function I8(e, t) {
return e === "dislike" ? t.feedback === "dislike" ? "已标记不合口味" : "已取消不合口味" : e === "seen" ? t.feedback === "seen" ? "已标记看过" : "已取消看过" : e === "dispose" ? t.disposal === "trash" ? "已移入回收站" : "已移出回收站" : "已记录一次高潮";
}
//#endregion
//#region src/react/immerse/immerse.ts
-var CVe = (e, t, n) => [
+var TVe = (e, t, n) => [
"immerse-list",
e,
t,
n
];
-function wVe(e) {
+function EVe(e) {
let t = new URLSearchParams();
for (let [n, r] of Object.entries(e)) r && t.set(n, String(r));
return t.delete("orient"), t.set("sort", "rand"), t.set("limit", "60"), t.set("offset", "0"), t.set("thumb", ""), t.toString();
}
-var TVe = (e, t) => e.cost !== "metered" && !!e.duration && !t(String(e.location ?? ""));
-function EVe(e, t = Math.random) {
+var DVe = (e, t) => e.cost !== "metered" && !!e.duration && !t(String(e.location ?? ""));
+function OVe(e, t = Math.random) {
for (let n = e.length - 1; n > 0; n--) {
let r = Math.floor(t() * (n + 1));
[e[n], e[r]] = [e[r], e[n]];
}
return e;
}
-async function DVe(e, t) {
- return EVe(((await W(`/api/items?${e}`)).items || []).filter((e) => TVe(e, t)));
+async function kVe(e, t) {
+ return OVe(((await W(`/api/items?${e}`)).items || []).filter((e) => DVe(e, t)));
}
-var R8 = (e) => X.ensureQueryData({
- queryKey: h8(e),
- queryFn: ({ signal: t }) => w8(e, t)
+var L8 = (e) => X.ensureQueryData({
+ queryKey: m8(e),
+ queryFn: ({ signal: t }) => C8(e, t)
});
-function OVe(e, t) {
+function AVe(e, t) {
let n = new Set(e.map((e) => e.id));
return e.concat(t.filter((e) => !n.has(e.id)));
}
-function kVe(e) {
+function jVe(e) {
let t = e.performers || [], n = t.length ? t.slice(0, 3).join("、") + (t.length > 3 ? ` 等 ${t.length} 人` : "") : e.creator || "未归属", r = t.length ? "performer" : e.creator ? "creator" : "";
return {
who: n,
@@ -74934,314 +74986,314 @@ function kVe(e) {
ref: r && e.entity_refs?.[r]?.[0] || null
};
}
-function AVe(e, t, n) {
+function MVe(e, t, n) {
if (!e || !t || !n || !Number.isFinite(n)) return null;
let r = e / t;
return (r > n ? r / n : n / r) > 1.05 ? "contain" : "cover";
}
-function jVe(e, t) {
+function NVe(e, t) {
return e.videoWidth && e.videoHeight ? e.videoWidth >= e.videoHeight : !!(t.width && t.height && t.width > 0 && t.height > 0 && t.width >= t.height);
}
-var MVe = 15e3, z8 = {
+var PVe = 15e3, R8 = {
open: !1,
idle: !1,
wide: !1,
loading: null,
shown: null
-}, B8 = null, V8 = null, H8 = null, U8 = null, W8 = z8, G8 = 0, K8 = 0, q8 = 0, J8 = "", Y8 = [], X8 = 0, Z8 = !1, Q8 = !1, $8 = null, e5 = /* @__PURE__ */ new Set(), t5 = "", n5 = null, r5 = 0, i5 = null, a5 = !1;
-function o5() {
- if (!B8) throw Error("沉浸岛还没有接上宿主(configureImmerse)");
- return B8;
+}, z8 = null, B8 = null, V8 = null, H8 = null, U8 = R8, W8 = 0, G8 = 0, K8 = 0, q8 = "", J8 = [], Y8 = 0, X8 = !1, Z8 = !1, Q8 = null, $8 = /* @__PURE__ */ new Set(), e5 = "", t5 = null, n5 = 0, r5 = null, i5 = !1;
+function a5() {
+ if (!z8) throw Error("沉浸岛还没有接上宿主(configureImmerse)");
+ return z8;
}
-function NVe() {
- return (!V8 || !H8?.isConnected) && (V8?.unmount(), H8 = document.createElement("div"), H8.dataset.immerseHost = "", document.body.append(H8), V8 = (0, Be.createRoot)(H8)), V8;
+function FVe() {
+ return (!B8 || !V8?.isConnected) && (B8?.unmount(), V8 = document.createElement("div"), V8.dataset.immerseHost = "", document.body.append(V8), B8 = (0, Be.createRoot)(V8)), B8;
}
-function s5() {
- let e = NVe();
- (0, ze.flushSync)(() => e.render(/* @__PURE__ */ (0, z.jsx)(IF, { children: /* @__PURE__ */ (0, z.jsx)(ZVe, { view: W8 }) })));
+function o5() {
+ let e = FVe();
+ (0, ze.flushSync)(() => e.render(/* @__PURE__ */ (0, z.jsx)(LF, { children: /* @__PURE__ */ (0, z.jsx)($Ve, { view: U8 }) })));
}
-function c5() {
- let e = n5 ? R6(n5.id) : 0;
- return e ? `${t5} · ${B6(e)}` : t5;
+function s5() {
+ let e = t5 ? L6(t5.id) : 0;
+ return e ? `${e5} · ${z6(e)}` : e5;
}
-function l5(e, t = null) {
- if (clearInterval(r5), r5 = 0, e === null) {
- W8 = {
- ...W8,
+function c5(e, t = null) {
+ if (clearInterval(n5), n5 = 0, e === null) {
+ U8 = {
+ ...U8,
loading: null
- }, s5();
+ }, o5();
return;
}
- t5 = e, n5 = t, W8 = {
- ...W8,
- loading: c5()
- }, s5(), r5 = window.setInterval(() => {
- n5 = Y8[X8] ?? null, W8 = {
- ...W8,
- loading: c5()
- }, s5();
+ e5 = e, t5 = t, U8 = {
+ ...U8,
+ loading: s5()
+ }, o5(), n5 = window.setInterval(() => {
+ t5 = J8[Y8] ?? null, U8 = {
+ ...U8,
+ loading: s5()
+ }, o5();
}, 500);
}
-function PVe(e) {
+function IVe(e) {
let t = document.createElement("div");
t.dataset.immerseSlide = "", e && (t.style.transform = `translateY(${e}%)`);
let n = document.createElement("video");
- n.className = "video-js", n.playsInline = !0, n.preload = "auto", t.append(n), U8.track.append(t);
- let r = K6(), i = () => {}, a = {
+ n.className = "video-js", n.playsInline = !0, n.preload = "auto", t.append(n), H8.track.append(t);
+ let r = G6(), i = () => {}, a = {
el: t,
video: n,
session: r,
- release: () => Y6(r),
+ release: () => J6(r),
disposed: !1,
gone: new Promise((e) => {
i = e;
}),
leave: i
};
- return e5.add(a), a;
+ return $8.add(a), a;
}
-function FVe(e, t) {
+function LVe(e, t) {
return new Promise((n) => {
- e.release = p8(e.video, {
+ e.release = f8(e.video, {
kind: "immerse",
item: t,
session: e.session,
onLoaded: n,
onEnded: () => {
- W8.open && g5(1);
+ U8.open && h5(1);
}
}), e.gone.then(n);
});
}
-function u5(e) {
- !e || e.disposed || (e.disposed = !0, e5.delete(e), e.leave(), e.release(), e.el.remove(), $8 === e && ($8 = null));
+function l5(e) {
+ !e || e.disposed || (e.disposed = !0, $8.delete(e), e.leave(), e.release(), e.el.remove(), Q8 === e && (Q8 = null));
}
-var d5 = [
+var u5 = [
"loadeddata",
"canplay",
"error"
];
-function IVe(e) {
+function RVe(e) {
let { video: t } = e;
return t.readyState >= 3 ? Promise.resolve() : new Promise((n) => {
let r = !1, i = () => {
- r || (r = !0, clearTimeout(a), d5.forEach((e) => t.removeEventListener(e, i)), n());
+ r || (r = !0, clearTimeout(a), u5.forEach((e) => t.removeEventListener(e, i)), n());
};
- d5.forEach((e) => t.addEventListener(e, i, { once: !0 }));
- let a = setTimeout(i, MVe);
+ u5.forEach((e) => t.addEventListener(e, i, { once: !0 }));
+ let a = setTimeout(i, PVe);
e.gone.then(i);
});
}
-function f5(e) {
- let t = e.closest("[data-immerse-track]"), n = t && t.clientWidth && t.clientHeight ? t.clientWidth / t.clientHeight : window.innerWidth / window.innerHeight, r = AVe(e.videoWidth, e.videoHeight, n);
+function d5(e) {
+ let t = e.closest("[data-immerse-track]"), n = t && t.clientWidth && t.clientHeight ? t.clientWidth / t.clientHeight : window.innerWidth / window.innerHeight, r = MVe(e.videoWidth, e.videoHeight, n);
r === "contain" ? e.dataset.fit = "contain" : r && delete e.dataset.fit;
}
-var p5 = () => U8?.track.querySelectorAll("video").forEach(f5);
-function LVe(e) {
- delete e.dataset.fit, e.readyState >= 1 ? f5(e) : e.addEventListener("loadedmetadata", () => f5(e), { once: !0 });
+var f5 = () => H8?.track.querySelectorAll("video").forEach(d5);
+function zVe(e) {
+ delete e.dataset.fit, e.readyState >= 1 ? d5(e) : e.addEventListener("loadedmetadata", () => d5(e), { once: !0 });
}
-function RVe(e) {
- W8 = {
- ...W8,
+function BVe(e) {
+ U8 = {
+ ...U8,
wide: e
- }, s5(), p5();
+ }, o5(), f5();
}
-var m5 = () => {
- let e = J8;
+var p5 = () => {
+ let e = q8;
return X.fetchQuery({
- queryKey: CVe(e, K8, q8),
- queryFn: () => DVe(e, o5().sourceOffline),
+ queryKey: TVe(e, G8, K8),
+ queryFn: () => kVe(e, a5().sourceOffline),
staleTime: Infinity
});
};
-function zVe(e, t) {
+function VVe(e, t) {
let n = () => p(e.duration) || p(t.duration);
e.addEventListener("timeupdate", () => {
let t = n();
- t && U8 && (U8.progress.style.width = `${(e.currentTime / t * 100).toFixed(2)}%`);
- }), i5 = {
+ t && H8 && (H8.progress.style.width = `${(e.currentTime / t * 100).toFixed(2)}%`);
+ }), r5 = {
video: e,
duration: n
};
}
-async function h5(e = 0) {
- let t = Y8[X8];
- if (!t || Z8) return;
- let n = G8;
- o5().route(t.id), Z8 = !0, l5(e ? "切换中…" : "加载中…", t);
+async function m5(e = 0) {
+ let t = J8[Y8];
+ if (!t || X8) return;
+ let n = W8;
+ a5().route(t.id), X8 = !0, c5(e ? "切换中…" : "加载中…", t);
let r = null;
try {
- if (await R8(t.id).catch((e) => {
- if (!(e instanceof C8)) throw e;
- }), n !== G8) return;
- let i = $8, a = !!(e && i);
- a || u5(i);
- let o = PVe(a ? e > 0 ? 100 : -100 : 0);
- if (r = o, LVe(o.video), await FVe(o, t), await IVe(o), o.disposed || (RVe(jVe(o.video, t)), a && i && (requestAnimationFrame(() => requestAnimationFrame(() => {
+ if (await L8(t.id).catch((e) => {
+ if (!(e instanceof S8)) throw e;
+ }), n !== W8) return;
+ let i = Q8, a = !!(e && i);
+ a || l5(i);
+ let o = IVe(a ? e > 0 ? 100 : -100 : 0);
+ if (r = o, zVe(o.video), await LVe(o, t), await RVe(o), o.disposed || (BVe(NVe(o.video, t)), a && i && (requestAnimationFrame(() => requestAnimationFrame(() => {
i.el.style.transform = `translateY(${e > 0 ? -100 : 100}%)`, o.el.style.transform = "";
- })), await new Promise((e) => setTimeout(e, 210)), u5(i), o.el.style.transform = ""), o.disposed)) return;
- $8 = o, r = null, o.video.play()?.catch(() => {}), W8 = {
- ...W8,
+ })), await new Promise((e) => setTimeout(e, 210)), l5(i), o.el.style.transform = ""), o.disposed)) return;
+ Q8 = o, r = null, o.video.play()?.catch(() => {}), U8 = {
+ ...U8,
idle: !1,
shown: {
item: t,
- index: X8,
- length: Y8.length
+ index: Y8,
+ length: J8.length
}
- }, zVe(o.video, t), G("/api/play", { id: t.id }).catch(() => {}), l5(null);
+ }, VVe(o.video, t), G("/api/play", { id: t.id }).catch(() => {}), c5(null);
} catch {
- u5(r), n === G8 && l5(null);
+ l5(r), n === W8 && c5(null);
} finally {
- n === G8 && (Z8 = !1);
+ n === W8 && (X8 = !1);
}
}
-async function g5(e) {
- if (Z8 || !W8.open) return;
- let t = G8;
- if (X8 += e, l5("切换中…", Y8[X8] ?? null), X8 >= Y8.length - 3 && !Q8) {
- Q8 = !0;
+async function h5(e) {
+ if (X8 || !U8.open) return;
+ let t = W8;
+ if (Y8 += e, c5("切换中…", J8[Y8] ?? null), Y8 >= J8.length - 3 && !Z8) {
+ Z8 = !0;
try {
- q8 += 1;
- let e = await m5();
- t === G8 && (Y8 = OVe(Y8, e));
+ K8 += 1;
+ let e = await p5();
+ t === W8 && (J8 = AVe(J8, e));
} catch {} finally {
- Q8 = !1;
+ Z8 = !1;
}
}
- t === G8 && (X8 >= Y8.length && (X8 = 0), X8 < 0 && (X8 = Y8.length - 1), await h5(e));
+ t === W8 && (Y8 >= J8.length && (Y8 = 0), Y8 < 0 && (Y8 = J8.length - 1), await m5(e));
}
-async function BVe(e) {
- let t = ++G8;
- _5(), K8 += 1, q8 = 0, J8 = wVe(o5().filters()), X.removeQueries({ queryKey: ["immerse-list"] }), W8 = {
- ...W8,
+async function HVe(e) {
+ let t = ++W8;
+ g5(), G8 += 1, K8 = 0, q8 = EVe(a5().filters()), X.removeQueries({ queryKey: ["immerse-list"] }), U8 = {
+ ...U8,
open: !0,
idle: !0,
shown: null
- }, document.body.setAttribute("data-immerse-open", ""), l5("加载内容…");
+ }, document.body.setAttribute("data-immerse-open", ""), c5("加载内容…");
try {
- let n = await m5();
+ let n = await p5();
if (e && !n.some((t) => t.id === e)) {
- let t = await R8(e).catch((e) => {
- if (e instanceof C8) return null;
+ let t = await L8(e).catch((e) => {
+ if (e instanceof S8) return null;
throw e;
});
t?.id && (n = [t, ...n.filter((t) => t.id !== e)]);
}
- if (t !== G8) return;
- if (Y8 = n, !Y8.length) {
- v5(), o5().warn("当前筛选下没有可直接播放的内容");
+ if (t !== W8) return;
+ if (J8 = n, !J8.length) {
+ _5(), a5().warn("当前筛选下没有可直接播放的内容");
return;
}
- X8 = Math.max(0, Y8.findIndex((t) => t.id === e)), await h5();
+ Y8 = Math.max(0, J8.findIndex((t) => t.id === e)), await m5();
} catch {
- if (t !== G8) return;
- l5(null), v5();
+ if (t !== W8) return;
+ c5(null), _5();
}
}
-function _5() {
- clearInterval(r5), r5 = 0, w5(), S5 = null, i5 = null, a5 = !1, [...e5].forEach(u5), Z8 = !1;
+function g5() {
+ clearInterval(n5), n5 = 0, C5(), x5 = null, r5 = null, i5 = !1, [...$8].forEach(l5), X8 = !1;
}
-function v5() {
- W8.open && (G8++, _5(), W8 = z8, document.body.removeAttribute("data-immerse-open"), s5(), o5().closed());
+function _5() {
+ U8.open && (W8++, g5(), U8 = R8, document.body.removeAttribute("data-immerse-open"), o5(), a5().closed());
}
-var y5 = 0, b5 = null, x5 = 0, S5 = null, C5 = 0;
-function w5() {
- clearTimeout(y5), y5 = 0, b5 = null;
+var v5 = 0, y5 = null, b5 = 0, x5 = null, S5 = 0;
+function C5() {
+ clearTimeout(v5), v5 = 0, y5 = null;
}
-function VVe(e) {
- let t = $8?.video;
+function UVe(e) {
+ let t = Q8?.video;
if (!t) return;
let n = e < window.innerWidth / 2 ? -1 : 1, r = Date.now();
- if (b5 && b5.side === n && r - b5.at <= 280) {
- w5(), rVe(t, o5().seekSeconds() * n);
+ if (y5 && y5.side === n && r - y5.at <= 280) {
+ C5(), aVe(t, a5().seekSeconds() * n);
return;
}
- y5 && (clearTimeout(y5), y5 = 0, m8(t)), b5 = {
+ v5 && (clearTimeout(v5), v5 = 0, p8(t)), y5 = {
side: n,
at: r
- }, y5 = window.setTimeout(() => {
- y5 = 0, b5 = null, W8.open && m8($8?.video);
+ }, v5 = window.setTimeout(() => {
+ v5 = 0, y5 = null, U8.open && p8(Q8?.video);
}, 280);
}
-function HVe() {
- Date.now() < x5 || m8($8?.video);
+function WVe() {
+ Date.now() < b5 || p8(Q8?.video);
}
-var T5 = (e) => U8?.bar.toggleAttribute("data-scrubbing", e);
-function E5(e) {
- U8 && (U8.progress.style.width = `${(e * 100).toFixed(2)}%`);
+var w5 = (e) => H8?.bar.toggleAttribute("data-scrubbing", e);
+function T5(e) {
+ H8 && (H8.progress.style.width = `${(e * 100).toFixed(2)}%`);
}
-function D5(e) {
+function E5(e) {
let t = e.target;
if (e.touches.length !== 1 || !t?.closest("[data-immerse-track]")) {
- S5 = null;
+ x5 = null;
return;
}
- let n = $8?.video;
- S5 = {
+ let n = Q8?.video;
+ x5 = {
x: e.touches[0].clientX,
y: e.touches[0].clientY,
axis: "",
from: n && n.currentTime || 0
};
}
-function O5(e) {
- if (!S5 || e.touches.length !== 1) return;
- let t = e.touches[0].clientX - S5.x, n = e.touches[0].clientY - S5.y;
- if (!S5.axis) {
+function D5(e) {
+ if (!x5 || e.touches.length !== 1) return;
+ let t = e.touches[0].clientX - x5.x, n = e.touches[0].clientY - x5.y;
+ if (!x5.axis) {
if (Math.abs(t) < 12 && Math.abs(n) < 12) return;
- S5.axis = Math.abs(t) > Math.abs(n) ? "x" : "y", S5.axis === "x" && T5(!0);
+ x5.axis = Math.abs(t) > Math.abs(n) ? "x" : "y", x5.axis === "x" && w5(!0);
}
- if (S5.axis !== "x") return;
- let r = $8?.video, i = r && r.duration || 0;
- i && (e.preventDefault(), S5.to = Math.min(i, Math.max(0, S5.from + t / window.innerWidth * i)), E5(S5.to / i));
+ if (x5.axis !== "x") return;
+ let r = Q8?.video, i = r && r.duration || 0;
+ i && (e.preventDefault(), x5.to = Math.min(i, Math.max(0, x5.from + t / window.innerWidth * i)), T5(x5.to / i));
}
-function k5(e) {
- if (!S5) return;
- let t = S5;
- if (S5 = null, x5 = Date.now() + 700, T5(!1), t.axis === "x") {
- let e = $8?.video;
+function O5(e) {
+ if (!x5) return;
+ let t = x5;
+ if (x5 = null, b5 = Date.now() + 700, w5(!1), t.axis === "x") {
+ let e = Q8?.video;
e && t.to != null && (e.currentTime = t.to);
return;
}
let n = e.changedTouches[0], r = n.clientX - t.x, i = t.y - n.clientY;
if (Math.abs(i) > 60) {
- w5(), g5(i > 0 ? 1 : -1);
+ C5(), h5(i > 0 ? 1 : -1);
return;
}
- Math.abs(r) <= 14 && Math.abs(i) <= 14 && (e.preventDefault(), VVe(n.clientX));
+ Math.abs(r) <= 14 && Math.abs(i) <= 14 && (e.preventDefault(), UVe(n.clientX));
}
-function A5() {
- S5 = null, T5(!1);
+function k5() {
+ x5 = null, w5(!1);
}
-function j5(e) {
+function A5(e) {
let t = Date.now();
- t - C5 < 260 || (C5 = t, g5(e.deltaY > 0 ? 1 : -1));
+ t - S5 < 260 || (S5 = t, h5(e.deltaY > 0 ? 1 : -1));
}
-function M5(e) {
- let t = U8.bar.getBoundingClientRect();
+function j5(e) {
+ let t = H8.bar.getBoundingClientRect();
return Math.min(1, Math.max(0, (e.clientX - t.left) / t.width));
}
-function UVe(e) {
- i5?.duration() && (a5 = !0, T5(!0), e.currentTarget.setPointerCapture(e.pointerId), E5(M5(e)), e.preventDefault());
+function GVe(e) {
+ r5?.duration() && (i5 = !0, w5(!0), e.currentTarget.setPointerCapture(e.pointerId), T5(j5(e)), e.preventDefault());
}
-function WVe(e) {
- a5 && E5(M5(e));
+function KVe(e) {
+ i5 && T5(j5(e));
}
-function GVe(e) {
- if (!a5) return;
- a5 = !1, T5(!1);
- let t = i5?.duration();
- i5 && t && (i5.video.currentTime = t * M5(e));
+function qVe(e) {
+ if (!i5) return;
+ i5 = !1, w5(!1);
+ let t = r5?.duration();
+ r5 && t && (r5.video.currentTime = t * j5(e));
}
-function KVe() {
- a5 = !1, T5(!1);
+function JVe() {
+ i5 = !1, w5(!1);
}
-async function N5(e, t) {
- let n = await G(v8, {
+async function M5(e, t) {
+ let n = await G(_8, {
id: e,
kind: t
- }), r = X.getQueryData(h8(e));
- if (!r) return gb(e, {
+ }), r = X.getQueryData(m8(e));
+ if (!r) return ab(e, {
feedback: n.feedback ?? void 0,
o_count: n.o_count
}), n;
@@ -75250,15 +75302,15 @@ async function N5(e, t) {
feedback: n.feedback ?? void 0,
o_count: n.o_count
};
- return X.setQueryData(h8(e), i), gb(e, {
+ return X.setQueryData(m8(e), i), ab(e, {
feedback: i.feedback,
disposal: i.disposal,
watch_later: i.watch_later,
rating: i.rating,
o_count: i.o_count
- }), o5().cache(i), n;
+ }), a5().cache(i), n;
}
-var qVe = [
+var YVe = [
{
kind: "dislike",
glyph: "thumbs-down",
@@ -75275,31 +75327,31 @@ var qVe = [
label: "记一次高潮"
}
];
-function P5(e) {
+function N5(e) {
return $n({
- queryKey: h8(e ?? 0),
- queryFn: ({ signal: t }) => w8(e, t),
+ queryKey: m8(e ?? 0),
+ queryFn: ({ signal: t }) => C8(e, t),
enabled: e != null,
staleTime: Infinity
}).data;
}
-function JVe({ kind: e, glyph: t, label: n, id: r }) {
- let i = P5(r), a = er({
+function XVe({ kind: e, glyph: t, label: n, id: r }) {
+ let i = N5(r), a = er({
mutationFn: async (t) => {
- let n = X.getQueryData(h8(t))?.feedback || null;
+ let n = X.getQueryData(m8(t))?.feedback || null;
return {
- result: await N5(t, e),
+ result: await M5(t, e),
before: n
};
},
onSuccess: ({ result: t, before: n }, r) => {
- o5().toast(L8(e, t), { undo: async () => {
- e === "o" ? await N5(r, "o-undo") : (t.feedback && await N5(r, t.feedback), n && await N5(r, n));
+ a5().toast(I8(e, t), { undo: async () => {
+ e === "o" ? await M5(r, "o-undo") : (t.feedback && await M5(r, t.feedback), n && await M5(r, n));
} }), e === "dislike" && t.feedback === "dislike" && setTimeout(() => {
- g5(1);
+ h5(1);
}, 260);
},
- onError: (e) => o5().failure("更新反馈", e)
+ onError: (e) => a5().failure("更新反馈", e)
}), o = a.isPending, s = e !== "o" && i ? i.feedback === e ? "true" : "false" : void 0;
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-immerse-action": "",
@@ -75330,11 +75382,11 @@ function JVe({ kind: e, glyph: t, label: n, id: r }) {
})]
});
}
-function YVe({ shown: e }) {
- let t = e?.item ?? null, n = P5(t?.id ?? null), r = n ? kVe(n) : null, i = o5(), a = (e) => {
- e.preventDefault(), n && (v5(), n.performers?.[0] ? i.openEntity("performer", n.performers[0]) : n.creator ? i.openEntity("creator", n.creator) : i.openUnowned());
+function ZVe({ shown: e }) {
+ let t = e?.item ?? null, n = N5(t?.id ?? null), r = n ? jVe(n) : null, i = a5(), a = (e) => {
+ e.preventDefault(), n && (_5(), n.performers?.[0] ? i.openEntity("performer", n.performers[0]) : n.creator ? i.openEntity("creator", n.creator) : i.openUnowned());
}, s = () => {
- t && (v5(), i.openItem(t.id));
+ t && (_5(), i.openItem(t.id));
}, c = r ? i.avatarHtml(r.name, r.ref, r.kind || "performer") : "";
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-immerse-ui": "",
@@ -75363,18 +75415,18 @@ function YVe({ shown: e }) {
})]
});
}
-var XVe = { __html: ie("媒体加载中") };
-function ZVe({ view: e }) {
+var QVe = { __html: ie("媒体加载中") };
+function $Ve({ view: e }) {
let t = (0, R.useRef)(null), n = (0, R.useRef)(null), r = (0, R.useRef)(null), i = (0, R.useRef)(null);
(0, R.useLayoutEffect)(() => {
let e = t.current;
- return U8 = {
+ return H8 = {
root: e,
track: n.current,
bar: r.current,
progress: i.current
- }, e.addEventListener("touchstart", D5, { passive: !0 }), e.addEventListener("touchmove", O5, { passive: !1 }), e.addEventListener("touchend", k5, { passive: !1 }), e.addEventListener("touchcancel", A5, { passive: !0 }), e.addEventListener("wheel", j5, { passive: !0 }), () => {
- e.removeEventListener("touchstart", D5), e.removeEventListener("touchmove", O5), e.removeEventListener("touchend", k5), e.removeEventListener("touchcancel", A5), e.removeEventListener("wheel", j5), U8 = null;
+ }, e.addEventListener("touchstart", E5, { passive: !0 }), e.addEventListener("touchmove", D5, { passive: !1 }), e.addEventListener("touchend", O5, { passive: !1 }), e.addEventListener("touchcancel", k5, { passive: !0 }), e.addEventListener("wheel", A5, { passive: !0 }), () => {
+ e.removeEventListener("touchstart", E5), e.removeEventListener("touchmove", D5), e.removeEventListener("touchend", O5), e.removeEventListener("touchcancel", k5), e.removeEventListener("wheel", A5), H8 = null;
};
}, []);
let a = e.shown?.item.id ?? null, o = (e) => e ? "" : void 0;
@@ -75391,10 +75443,10 @@ function ZVe({ view: e }) {
children: [/* @__PURE__ */ (0, z.jsx)("div", {
ref: n,
"data-immerse-track": "",
- onClick: HVe
+ onClick: WVe
}), /* @__PURE__ */ (0, z.jsx)("div", {
"data-immerse-actions": "",
- children: qVe.map((e) => /* @__PURE__ */ (0, z.jsx)(JVe, {
+ children: YVe.map((e) => /* @__PURE__ */ (0, z.jsx)(XVe, {
...e,
id: a
}, e.kind))
@@ -75407,7 +75459,7 @@ function ZVe({ view: e }) {
hidden: e.loading === null,
children: [/* @__PURE__ */ (0, z.jsx)("span", {
"data-immerse-spinner": "",
- dangerouslySetInnerHTML: XVe
+ dangerouslySetInnerHTML: QVe
}), /* @__PURE__ */ (0, z.jsx)("span", { children: e.loading ?? "" })]
}),
/* @__PURE__ */ (0, z.jsx)("button", {
@@ -75415,7 +75467,7 @@ function ZVe({ view: e }) {
"data-immerse-close": "",
title: "关闭",
"aria-label": "关闭",
- onClick: v5,
+ onClick: _5,
children: /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
children: /* @__PURE__ */ (0, z.jsx)("use", { href: "#i-x" })
@@ -75424,71 +75476,71 @@ function ZVe({ view: e }) {
/* @__PURE__ */ (0, z.jsx)("div", {
ref: r,
"data-immerse-bar": "",
- onPointerDown: UVe,
- onPointerMove: WVe,
- onPointerUp: GVe,
- onPointerCancel: KVe,
+ onPointerDown: GVe,
+ onPointerMove: KVe,
+ onPointerUp: qVe,
+ onPointerCancel: JVe,
children: /* @__PURE__ */ (0, z.jsx)("i", { ref: i })
}),
- /* @__PURE__ */ (0, z.jsx)(YVe, { shown: e.shown })
+ /* @__PURE__ */ (0, z.jsx)(ZVe, { shown: e.shown })
]
});
}
-var QVe = {
- open: BVe,
- close: v5,
- isOpen: () => W8.open,
- activeVideo: () => W8.open ? $8?.video ?? null : null
+var eHe = {
+ open: HVe,
+ close: _5,
+ isOpen: () => U8.open,
+ activeVideo: () => U8.open ? Q8?.video ?? null : null
};
-function $Ve(e) {
- if (!W8.open) return;
+function tHe(e) {
+ if (!U8.open) return;
let t = e.target;
- t && (t.tagName === "INPUT" || t.tagName === "TEXTAREA" || t.isContentEditable) || e.ctrlKey || e.metaKey || e.altKey || (e.key === "ArrowDown" && g5(1), e.key === "ArrowUp" && g5(-1));
+ t && (t.tagName === "INPUT" || t.tagName === "TEXTAREA" || t.isContentEditable) || e.ctrlKey || e.metaKey || e.altKey || (e.key === "ArrowDown" && h5(1), e.key === "ArrowUp" && h5(-1));
}
-function eHe(e) {
- let t = !B8;
- return B8 = e, s5(), t && (document.addEventListener("keydown", $Ve), addEventListener("resize", () => {
- W8.open && p5();
+function nHe(e) {
+ let t = !z8;
+ return z8 = e, o5(), t && (document.addEventListener("keydown", tHe), addEventListener("resize", () => {
+ U8.open && f5();
}), addEventListener("pagehide", () => {
- e5.forEach((e) => Y6(e.session));
- })), QVe;
+ $8.forEach((e) => J6(e.session));
+ })), eHe;
}
//#endregion
//#region src/manage-header.ts
-var tHe = {
+var rHe = {
"/junk-files": "垃圾文件",
"/duplicates": "重复文件",
"/review": "人工复核",
"/trash": "回收站",
"/quality-goals": "高清版",
"/scraping": "来源和凭证"
-}, nHe = /* @__PURE__ */ new Set(["/data-cleanup", "/scraping"]), rHe = ({ total: e, shown: t }) => `${e.toLocaleString()} 个符合 · 显示 ${t}`;
-function iHe(e) {
+}, iHe = /* @__PURE__ */ new Set(["/data-cleanup", "/scraping"]), aHe = ({ total: e, shown: t }) => `${e.toLocaleString()} 个符合 · 显示 ${t}`;
+function oHe(e) {
let t = e.sections.find(([t]) => t === e.section);
if (!t) return null;
- let n = tHe[e.path] ?? "";
+ let n = rHe[e.path] ?? "";
return {
title: e.section === "cleanup" && n || t[1],
crumb: n,
- compact: nHe.has(e.path) || e.section === "configuration",
+ compact: iHe.has(e.path) || e.section === "configuration",
lede: e.section === "trash" ? e.trash ? {
kind: "count",
- text: rHe(e.trash),
+ text: aHe(e.trash),
total: e.trash.total
} : { kind: "skeleton" } : { kind: "none" }
};
}
-var aHe = "<span class=\"skeleton\" data-trash-lede-skeleton=\"text\" aria-hidden=\"true\"></span><span class=\"skeleton\" data-trash-lede-skeleton=\"action\" aria-hidden=\"true\"></span>";
+var sHe = "<span class=\"skeleton\" data-trash-lede-skeleton=\"text\" aria-hidden=\"true\"></span><span class=\"skeleton\" data-trash-lede-skeleton=\"action\" aria-hidden=\"true\"></span>";
//#endregion
//#region src/react/settings-panel/icon.tsx
-function F5({ name: e }) {
+function P5({ name: e }) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
"aria-hidden": "true",
children: /* @__PURE__ */ (0, z.jsx)("use", { href: `#i-${e}` })
});
}
-function oHe({ name: e }) {
+function cHe({ name: e }) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
"aria-hidden": "true",
@@ -75497,29 +75549,29 @@ function oHe({ name: e }) {
}
//#endregion
//#region src/react/manage-header/manage-header-island.tsx
-var I5 = null, L5 = null, R5 = null;
-function sHe() {
- let e = I5, t = R5;
- !e || !L5 || !t || (0, ze.flushSync)(() => L5.render(/* @__PURE__ */ (0, z.jsx)(uHe, {
+var F5 = null, I5 = null, L5 = null;
+function lHe() {
+ let e = F5, t = L5;
+ !e || !I5 || !t || (0, ze.flushSync)(() => I5.render(/* @__PURE__ */ (0, z.jsx)(fHe, {
host: e,
props: t
})));
}
-var cHe = { render(e) {
- R5 = e, sHe();
+var uHe = { render(e) {
+ L5 = e, lHe();
} };
-function lHe(e) {
- return I5 = e, R5 = null, e.root.replaceChildren(), L5 = (0, Be.createRoot)(e.root), cHe;
+function dHe(e) {
+ return F5 = e, L5 = null, e.root.replaceChildren(), I5 = (0, Be.createRoot)(e.root), uHe;
}
-function uHe({ host: e, props: t }) {
- let n = iHe(t);
+function fHe({ host: e, props: t }) {
+ let n = oHe(t);
return n ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
- /* @__PURE__ */ (0, z.jsx)(dHe, {
+ /* @__PURE__ */ (0, z.jsx)(pHe, {
host: e,
section: t.section,
menu: t.menu
}),
- n.crumb ? /* @__PURE__ */ (0, z.jsx)(fHe, {
+ n.crumb ? /* @__PURE__ */ (0, z.jsx)(mHe, {
host: e,
label: n.crumb
}) : null,
@@ -75528,29 +75580,29 @@ function uHe({ host: e, props: t }) {
"data-compact": n.compact ? "" : void 0,
children: n.title
}),
- n.lede.kind === "none" ? null : /* @__PURE__ */ (0, z.jsx)(pHe, {
+ n.lede.kind === "none" ? null : /* @__PURE__ */ (0, z.jsx)(hHe, {
host: e,
lede: n.lede
})
] }) : null;
}
-var z5 = null;
-function B5(e, t, n) {
+var R5 = null;
+function z5(e, t, n) {
e.style.setProperty("--tab-x", `${t}px`), e.style.setProperty("--tab-width", `${n}px`);
}
-function dHe({ host: e, section: t, menu: n }) {
+function pHe({ host: e, section: t, menu: n }) {
let r = (0, R.useRef)(null), i = (0, R.useRef)(null), a = () => {
let e = r.current, t = i.current;
if (!e || !t) return;
let n = e.querySelector("button[aria-pressed=\"true\"]");
- n && !n.offsetWidth || (B5(t, n?.offsetLeft ?? 0, n?.offsetWidth ?? 0), n && (z5 = {
+ n && !n.offsetWidth || (z5(t, n?.offsetLeft ?? 0, n?.offsetWidth ?? 0), n && (R5 = {
x: n.offsetLeft,
width: n.offsetWidth
}));
};
return (0, R.useLayoutEffect)(() => {
let e = r.current, t = i.current;
- z5 ? B5(t, z5.x, z5.width) : a();
+ R5 ? z5(t, R5.x, R5.width) : a();
let n = 0, o = requestAnimationFrame(() => {
t.setAttribute("data-ready", ""), n = requestAnimationFrame(a);
}), s = new ResizeObserver(a);
@@ -75573,7 +75625,7 @@ function dHe({ host: e, section: t, menu: n }) {
"aria-pressed": a,
"aria-current": a ? "page" : void 0,
onClick: () => e.openManage(n),
- children: [/* @__PURE__ */ (0, z.jsx)(F5, { name: i }), /* @__PURE__ */ (0, z.jsx)("span", { children: r })]
+ children: [/* @__PURE__ */ (0, z.jsx)(P5, { name: i }), /* @__PURE__ */ (0, z.jsx)("span", { children: r })]
}, n);
}), /* @__PURE__ */ (0, z.jsx)("span", {
ref: i,
@@ -75583,7 +75635,7 @@ function dHe({ host: e, section: t, menu: n }) {
})
});
}
-function fHe({ host: e, label: t }) {
+function mHe({ host: e, label: t }) {
return /* @__PURE__ */ (0, z.jsx)("nav", {
"data-manage-crumb": "",
"aria-label": "Breadcrumb",
@@ -75593,20 +75645,20 @@ function fHe({ host: e, label: t }) {
t.metaKey || t.ctrlKey || t.shiftKey || t.altKey || t.button || (t.preventDefault(), e.openDataCleanup());
},
children: "数据管理"
- }), /* @__PURE__ */ (0, z.jsx)(F5, { name: "chevron-right" })] }), /* @__PURE__ */ (0, z.jsx)("li", {
+ }), /* @__PURE__ */ (0, z.jsx)(P5, { name: "chevron-right" })] }), /* @__PURE__ */ (0, z.jsx)("li", {
"aria-current": "true",
children: /* @__PURE__ */ (0, z.jsx)("span", { children: t })
})] })
});
}
-function pHe({ host: e, lede: t }) {
+function hHe({ host: e, lede: t }) {
return /* @__PURE__ */ (0, z.jsx)("p", {
className: "mono",
"data-manage-lede": "",
children: t.kind === "skeleton" ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-trash-lede-skeletons": "",
- dangerouslySetInnerHTML: { __html: aHe }
- }) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(mHe, { text: t.text }), t.total ? /* @__PURE__ */ (0, z.jsx)("button", {
+ dangerouslySetInnerHTML: { __html: sHe }
+ }) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(gHe, { text: t.text }), t.total ? /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-empty-trash": "",
"data-danger": "",
@@ -75616,7 +75668,7 @@ function pHe({ host: e, lede: t }) {
}) : null] })
});
}
-function mHe({ text: e }) {
+function gHe({ text: e }) {
let t = (0, R.useRef)(null);
return (0, R.useLayoutEffect)(() => {
ae(t.current, e);
@@ -75627,40 +75679,40 @@ function mHe({ text: e }) {
}
//#endregion
//#region src/number-setting.ts
-function V5(e, t, n, r) {
+function B5(e, t, n, r) {
return Number.isInteger(e) && e >= t && e <= n ? e : r;
}
//#endregion
//#region src/react/settings/configuration-summary.tsx
-var hHe = (e) => {
+var _He = (e) => {
let t = e.updates;
return t ? t.message ? `${t.current_version} · ${t.message}` : t.current_version : "未取得";
};
-function gHe({ openConfiguration: e }) {
+function vHe({ openConfiguration: e }) {
let t = $n({
- queryKey: $F,
- queryFn: ({ signal: e }) => eI(e)
+ queryKey: eI,
+ queryFn: ({ signal: e }) => tI(e)
}), n = t.data;
return /* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex flex-col",
- children: [n ? /* @__PURE__ */ (0, z.jsxs)(Oy, { children: [
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ children: [n ? /* @__PURE__ */ (0, z.jsxs)(Ny, { children: [
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "媒体库",
children: `${n.library_count} 个`
}),
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "端口",
children: String(n.port)
}),
- /* @__PURE__ */ (0, z.jsx)(ky, {
+ /* @__PURE__ */ (0, z.jsx)(Py, {
term: "更新",
- children: hHe(n)
+ children: _He(n)
})
- ] }) : /* @__PURE__ */ (0, z.jsx)(Sy, { children: /* @__PURE__ */ (0, z.jsx)(K, {
+ ] }) : /* @__PURE__ */ (0, z.jsx)(Dy, { children: /* @__PURE__ */ (0, z.jsx)(K, {
tone: "error",
title: "配置读取失败",
children: t.error ? U(t.error) : "未取得配置,请刷新页面重试。"
- }) }), /* @__PURE__ */ (0, z.jsx)(Cy, {
+ }) }), /* @__PURE__ */ (0, z.jsx)(Oy, {
status: "媒体文件夹、端口、代理与更新在配置页上改。",
children: /* @__PURE__ */ (0, z.jsx)(H, {
onClick: e,
@@ -75671,16 +75723,16 @@ function gHe({ openConfiguration: e }) {
}
//#endregion
//#region src/react/settings-panel/legacy-controls.tsx
-var H5 = (e) => e.map(([e, t, n]) => n ? [
+var V5 = (e) => e.map(([e, t, n]) => n ? [
e,
t,
n
] : [e, t]);
-function U5({ id: e, name: t, legend: n, options: r, value: i, attr: a, variant: o, text: s = !1, epoch: c, onChoose: l }) {
+function H5({ id: e, name: t, legend: n, options: r, value: i, attr: a, variant: o, text: s = !1, epoch: c, onChoose: l }) {
let u = (0, R.useRef)(null), d = (0, R.useRef)(null), f = (0, R.useRef)(l);
return f.current = l, (0, R.useLayoutEffect)(() => {
let e = u.current;
- e && (d.current && d.current.value === i && d.current.epoch === c || (e.innerHTML = D(t, n, H5(r), i, {
+ e && (d.current && d.current.value === i && d.current.epoch === c || (e.innerHTML = D(t, n, V5(r), i, {
attr: a,
className: o,
text: s
@@ -75698,13 +75750,13 @@ function U5({ id: e, name: t, legend: n, options: r, value: i, attr: a, variant:
ref: u
});
}
-function W5({ id: e, label: t, options: n, value: r, disabled: i = !1, busy: a = !1, hidden: o, describedBy: s, epoch: c, onPick: l, decorate: u }) {
+function U5({ id: e, label: t, options: n, value: r, disabled: i = !1, busy: a = !1, hidden: o, describedBy: s, epoch: c, onPick: l, decorate: u }) {
let d = (0, R.useRef)(null), f = (0, R.useRef)(null), p = (0, R.useRef)(-1), m = (0, R.useRef)(l);
return m.current = l, (0, R.useLayoutEffect)(() => {
let e = d.current;
if (!e) return;
if (p.current !== c || !f.current) {
- e.innerHTML = I(H5(n), r, { label: t });
+ e.innerHTML = I(V5(n), r, { label: t });
let i = L(e.firstElementChild);
i.addEventListener("change", () => m.current(i.value)), f.current = i, p.current = c;
}
@@ -75717,7 +75769,7 @@ function W5({ id: e, label: t, options: n, value: r, disabled: i = !1, busy: a =
"aria-describedby": s
});
}
-function _He({ field: e, label: t, max: n, value: r, hidden: i, onStep: a, onSettle: o }) {
+function yHe({ field: e, label: t, max: n, value: r, hidden: i, onStep: a, onSettle: o }) {
let s = (0, R.useRef)(null), c = (0, R.useRef)(null), l = (0, R.useRef)({
onStep: a,
onSettle: o
@@ -75752,7 +75804,7 @@ function _He({ field: e, label: t, max: n, value: r, hidden: i, onStep: a, onSet
}
//#endregion
//#region src/react/settings-panel/glow-settings.tsx
-var vHe = [
+var bHe = [
[
"strength",
"强度",
@@ -75779,7 +75831,7 @@ var vHe = [
100
]
];
-function yHe({ host: e, version: t }) {
+function xHe({ host: e, version: t }) {
let n = (0, R.useRef)(null), r = (0, R.useRef)(!1);
return (0, R.useLayoutEffect)(() => {
let t = n.current;
@@ -75792,7 +75844,7 @@ function yHe({ host: e, version: t }) {
ref: n
});
}
-function bHe({ host: e, spot: t, index: n, glow: r }) {
+function SHe({ host: e, spot: t, index: n, glow: r }) {
let i = de[n], a = (0, R.useRef)(null), o = (0, R.useRef)(null), s = (0, R.useRef)(null), [c, l] = (0, R.useState)("all");
(0, R.useLayoutEffect)(() => {
let [e, t, n] = [
@@ -75831,7 +75883,7 @@ function bHe({ host: e, spot: t, index: n, glow: r }) {
children: u
})]
}),
- /* @__PURE__ */ (0, z.jsx)(F5, { name: "chevron-down" })
+ /* @__PURE__ */ (0, z.jsx)(P5, { name: "chevron-down" })
]
}), /* @__PURE__ */ (0, z.jsxs)("div", {
className: "popmenu",
@@ -75870,7 +75922,7 @@ function bHe({ host: e, spot: t, index: n, glow: r }) {
})]
});
}
-function xHe({ host: e, version: t }) {
+function CHe({ host: e, version: t }) {
let n = e.store.value.homeGlow, r = _e(n.preset);
return /* @__PURE__ */ (0, z.jsxs)("section", {
"data-glow-setting": "",
@@ -75889,7 +75941,7 @@ function xHe({ host: e, version: t }) {
children: ge(n.preset)
})]
}),
- /* @__PURE__ */ (0, z.jsx)(yHe, {
+ /* @__PURE__ */ (0, z.jsx)(xHe, {
host: e,
version: t
}),
@@ -75900,7 +75952,7 @@ function xHe({ host: e, version: t }) {
}),
/* @__PURE__ */ (0, z.jsx)("div", {
"data-glow-fields": "",
- children: vHe.map(([t, i, a]) => /* @__PURE__ */ (0, z.jsx)(_He, {
+ children: bHe.map(([t, i, a]) => /* @__PURE__ */ (0, z.jsx)(yHe, {
field: t,
label: i,
max: a,
@@ -75922,7 +75974,7 @@ function xHe({ host: e, version: t }) {
hidden: r,
children: [/* @__PURE__ */ (0, z.jsx)("h4", { children: "颜色" }), /* @__PURE__ */ (0, z.jsx)("div", {
"data-glow-stops": "",
- children: me.map((t, r) => /* @__PURE__ */ (0, z.jsx)(bHe, {
+ children: me.map((t, r) => /* @__PURE__ */ (0, z.jsx)(SHe, {
host: e,
spot: t,
index: r,
@@ -75947,7 +75999,7 @@ function xHe({ host: e, version: t }) {
}
//#endregion
//#region src/react/settings-panel/number-setting.tsx
-var SHe = {
+var wHe = {
batchSizeSetting: {
min: 1,
max: 200,
@@ -75988,10 +76040,10 @@ var SHe = {
optional: !0,
fallback: 60
}
-}, G5 = (e) => `peach.number.${e}`;
-function K5({ id: e, label: t, value: n, disabled: r = !1, onApply: i }) {
- let a = SHe[e], { min: o, max: s, unit: c, fallback: l } = a, u = a.optional === !0, d = (0, R.useRef)(0);
- d.current ||= V5(Number(localStorage.getItem(G5(e))), o, s, n && n > 0 ? n : l);
+}, W5 = (e) => `peach.number.${e}`;
+function G5({ id: e, label: t, value: n, disabled: r = !1, onApply: i }) {
+ let a = wHe[e], { min: o, max: s, unit: c, fallback: l } = a, u = a.optional === !0, d = (0, R.useRef)(0);
+ d.current ||= B5(Number(localStorage.getItem(W5(e))), o, s, n && n > 0 ? n : l);
let [f, p] = (0, R.useState)(n ?? 0), [m, h] = (0, R.useState)(String(n && n > 0 ? n : d.current)), [g, _] = (0, R.useState)(""), v = (0, R.useRef)(null), y = (0, R.useRef)(i);
y.current = i, (0, R.useLayoutEffect)(() => {
n !== null && (p(n), n > 0 && h(String(n)));
@@ -76003,7 +76055,7 @@ function K5({ id: e, label: t, value: n, disabled: r = !1, onApply: i }) {
t.setAttribute("aria-invalid", "true"), _(`请输入 ${o}–${s} 的整数(${c})`);
return;
}
- t.removeAttribute("aria-invalid"), _(""), d.current = Number(t.value), localStorage.setItem(G5(e), String(d.current)), y.current(d.current);
+ t.removeAttribute("aria-invalid"), _(""), d.current = Number(t.value), localStorage.setItem(W5(e), String(d.current)), y.current(d.current);
}
}, x = (0, R.useRef)(b);
x.current = b, (0, R.useEffect)(() => {
@@ -76018,7 +76070,7 @@ function K5({ id: e, label: t, value: n, disabled: r = !1, onApply: i }) {
p(d.current), h(String(d.current)), y.current(d.current);
return;
}
- t && t.value && t.checkValidity() && (d.current = Number(t.value)), localStorage.setItem(G5(e), String(d.current)), p(0), y.current(0);
+ t && t.value && t.checkValidity() && (d.current = Number(t.value)), localStorage.setItem(W5(e), String(d.current)), p(0), y.current(0);
}, w = r || n === null;
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-number-setting": "",
@@ -76068,13 +76120,13 @@ function K5({ id: e, label: t, value: n, disabled: r = !1, onApply: i }) {
}
//#endregion
//#region src/react/sidebar/sidebar-order.ts
-function q5(e) {
- let { mutate: t } = Hx();
+function K5(e) {
+ let { mutate: t } = Kx();
return (0, R.useCallback)((n) => {
e.value.sidebarOrder = n, e.save(), t({ sidebarOrder: n }, { onError: () => {} });
}, [e, t]);
}
-function J5(e, t, n, r) {
+function q5(e, t, n, r) {
if (t === n) return null;
let i = [...e], a = i.indexOf(t);
if (a < 0) return null;
@@ -76084,17 +76136,17 @@ function J5(e, t, n, r) {
}
//#endregion
//#region src/react/settings-panel/sidebar-order.tsx
-var CHe = "__home__", Y5 = (e) => e === "" ? CHe : e;
-function wHe({ host: e }) {
- let t = q5(e.store), n = e.store.value.sidebarOrder, r = new Map(e.navCatalog.map((e) => [e[0], e])), i = n.map((e) => r.get(e)).filter((e) => e !== void 0), a = e.navCatalog.filter(([e]) => !n.includes(e)), [o, s] = (0, R.useState)(null), [c, l] = (0, R.useState)(!1), [u, d] = (0, R.useState)(null), [f, p] = (0, R.useState)(null), m = (0, R.useRef)(null), h = (0, R.useRef)(null), g = (e, r, i) => {
- let a = J5(n, e, r, i);
+var THe = "__home__", J5 = (e) => e === "" ? THe : e;
+function EHe({ host: e }) {
+ let t = K5(e.store), n = e.store.value.sidebarOrder, r = new Map(e.navCatalog.map((e) => [e[0], e])), i = n.map((e) => r.get(e)).filter((e) => e !== void 0), a = e.navCatalog.filter(([e]) => !n.includes(e)), [o, s] = (0, R.useState)(null), [c, l] = (0, R.useState)(!1), [u, d] = (0, R.useState)(null), [f, p] = (0, R.useState)(null), m = (0, R.useRef)(null), h = (0, R.useRef)(null), g = (e, r, i) => {
+ let a = q5(n, e, r, i);
a && t(a);
}, _ = (e, r) => {
let i = n.indexOf(e), a = i + r;
if (i < 0 || a < 0 || a >= n.length) return;
let o = [...n];
[o[i], o[a]] = [o[a], o[i]], t(o);
- }, v = a.find(([e]) => Y5(e) === o) ?? a[0], y = () => {
+ }, v = a.find(([e]) => J5(e) === o) ?? a[0], y = () => {
h.current && S(h.current), l(!1);
}, b = () => {
let e = h.current;
@@ -76115,7 +76167,7 @@ function wHe({ host: e }) {
}, w = (e) => ({
draggable: !0,
onDragStart: (t) => {
- d(e), t.dataTransfer.effectAllowed = "move", t.dataTransfer.setData("text/plain", Y5(e));
+ d(e), t.dataTransfer.effectAllowed = "move", t.dataTransfer.setData("text/plain", J5(e));
},
onDragOver: (t) => {
if (u === null || u === e) return;
@@ -76147,9 +76199,9 @@ function wHe({ host: e }) {
/* @__PURE__ */ (0, z.jsx)("i", {
"data-sidebar-grip": "",
"aria-hidden": "true",
- children: /* @__PURE__ */ (0, z.jsx)(F5, { name: "grip-vertical" })
+ children: /* @__PURE__ */ (0, z.jsx)(P5, { name: "grip-vertical" })
}),
- /* @__PURE__ */ (0, z.jsx)(F5, { name: a ?? "" }),
+ /* @__PURE__ */ (0, z.jsx)(P5, { name: a ?? "" }),
/* @__PURE__ */ (0, z.jsx)("b", { children: r })
]
}), /* @__PURE__ */ (0, z.jsxs)("span", {
@@ -76163,7 +76215,7 @@ function wHe({ host: e }) {
title: "上移",
disabled: o === 0,
onClick: () => _(e, -1),
- children: /* @__PURE__ */ (0, z.jsx)(F5, { name: "chevron-up" })
+ children: /* @__PURE__ */ (0, z.jsx)(P5, { name: "chevron-up" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -76173,7 +76225,7 @@ function wHe({ host: e }) {
title: "下移",
disabled: o === i.length - 1,
onClick: () => _(e, 1),
- children: /* @__PURE__ */ (0, z.jsx)(F5, { name: "chevron-down" })
+ children: /* @__PURE__ */ (0, z.jsx)(P5, { name: "chevron-down" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -76185,11 +76237,11 @@ function wHe({ host: e }) {
onClick: () => {
n.length > 1 && t(n.filter((t) => t !== e));
},
- children: /* @__PURE__ */ (0, z.jsx)(F5, { name: "eye-off" })
+ children: /* @__PURE__ */ (0, z.jsx)(P5, { name: "eye-off" })
})
]
})]
- }, Y5(e))), /* @__PURE__ */ (0, z.jsxs)("div", {
+ }, J5(e))), /* @__PURE__ */ (0, z.jsxs)("div", {
"data-sidebar-add-row": "",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
"data-sidebar-add-picker": "",
@@ -76205,13 +76257,13 @@ function wHe({ host: e }) {
ref: m,
onClick: b,
children: v ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
- /* @__PURE__ */ (0, z.jsx)(F5, { name: v[2] ?? "" }),
+ /* @__PURE__ */ (0, z.jsx)(P5, { name: v[2] ?? "" }),
/* @__PURE__ */ (0, z.jsx)("span", {
"data-sidebar-add-label": "",
children: v[1]
}),
- /* @__PURE__ */ (0, z.jsx)(F5, { name: "chevron-down" })
- ] }) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(F5, { name: "check" }), /* @__PURE__ */ (0, z.jsx)("span", { children: "全部页面都已显示" })] })
+ /* @__PURE__ */ (0, z.jsx)(P5, { name: "chevron-down" })
+ ] }) : /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(P5, { name: "check" }), /* @__PURE__ */ (0, z.jsx)("span", { children: "全部页面都已显示" })] })
}), a.length ? /* @__PURE__ */ (0, z.jsx)("div", {
className: "popmenu",
"data-sidebar-add-menu": "",
@@ -76222,15 +76274,15 @@ function wHe({ host: e }) {
children: a.map(([e, t, n]) => /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
role: "option",
- "data-sidebar-add-option": Y5(e),
+ "data-sidebar-add-option": J5(e),
"aria-selected": v?.[0] === e,
tabIndex: v?.[0] === e ? 0 : -1,
onKeyDown: x,
onClick: () => {
- s(Y5(e)), y(), m.current?.focus();
+ s(J5(e)), y(), m.current?.focus();
},
- children: [/* @__PURE__ */ (0, z.jsx)(F5, { name: n ?? "" }), /* @__PURE__ */ (0, z.jsx)("span", { children: t })]
- }, Y5(e)))
+ children: [/* @__PURE__ */ (0, z.jsx)(P5, { name: n ?? "" }), /* @__PURE__ */ (0, z.jsx)("span", { children: t })]
+ }, J5(e)))
}) : null]
}), /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -76247,7 +76299,7 @@ function wHe({ host: e }) {
}
//#endregion
//#region src/react/settings-panel/settings-panel.tsx
-var X5 = [
+var Y5 = [
["界面", "ri-palette-line"],
["浏览", "ri-layout-grid-line"],
["播放", "ri-play-circle-line"],
@@ -76255,7 +76307,7 @@ var X5 = [
["关注", "ri-rss-line"],
["安全", "ri-shield-check-line"],
["这台电脑", "ri-macbook-line"]
-], THe = [
+], DHe = [
["seed", "随机"],
["rating", "评分"],
["o", "高潮计数"],
@@ -76264,21 +76316,21 @@ var X5 = [
["size", "体积"],
["new", "入库时间"],
["played", "观看时间"]
-], EHe = [["desc", "降序"], ["asc", "升序"]], DHe = [
+], OHe = [["desc", "降序"], ["asc", "升序"]], kHe = [
["off", "关闭"],
["precise", "精准"],
["coarse", "粗略"]
-], OHe = [
+], AHe = [
["7", "每周"],
["30", "每月"],
["90", "每季"],
["0", "从不"]
-], kHe = [
+], jHe = [
0,
7,
30,
90
-], AHe = [[
+], MHe = [[
"cover",
"官方封面",
""
@@ -76286,7 +76338,7 @@ var X5 = [
"thumbnail",
"预览图",
""
-]], jHe = [
+]], NHe = [
[
"feedHideGroupSetting",
"feedHideGroupCompilations",
@@ -76311,91 +76363,91 @@ var X5 = [
"feedHideExcerptDescription",
"把出过的正片剪成十几分钟单卖的,比如ハイライト厂牌。"
]
-], MHe = "button:not([disabled]),input:not([disabled]),textarea:not([disabled]),a[href]", Z5 = null, Q5 = null, $5 = null, e7 = {
+], PHe = "button:not([disabled]),input:not([disabled]),textarea:not([disabled]),a[href]", X5 = null, Z5 = null, Q5 = null, $5 = {
open: !1,
closing: !1,
epoch: 0,
tab: 0,
machine: "none"
-}, t7 = 0, n7 = null;
-function NHe() {
- return (!Q5 || !$5?.isConnected) && (Q5?.unmount(), $5 = document.createElement("div"), $5.dataset.settingsHost = "", document.body.append($5), Q5 = (0, Be.createRoot)($5)), Q5;
+}, e7 = 0, t7 = null;
+function FHe() {
+ return (!Z5 || !Q5?.isConnected) && (Z5?.unmount(), Q5 = document.createElement("div"), Q5.dataset.settingsHost = "", document.body.append(Q5), Z5 = (0, Be.createRoot)(Q5)), Z5;
}
-function r7() {
- let e = Z5;
- e && (0, ze.flushSync)(() => NHe().render(/* @__PURE__ */ (0, z.jsx)(IF, { children: /* @__PURE__ */ (0, z.jsx)(BHe, {
+function n7() {
+ let e = X5;
+ e && (0, ze.flushSync)(() => FHe().render(/* @__PURE__ */ (0, z.jsx)(LF, { children: /* @__PURE__ */ (0, z.jsx)(HHe, {
host: e,
- view: e7
+ view: $5
}) })));
}
-function i7(e) {
- e7 = {
- ...e7,
+function r7(e) {
+ $5 = {
+ ...$5,
...e
- }, r7();
+ }, n7();
}
-async function PHe(e) {
- if (e7.machine === "summary") return;
+async function IHe(e) {
+ if ($5.machine === "summary") return;
let t = await e.configurable();
- if (e7.open) {
+ if ($5.open) {
if (!t) {
- i7({ machine: "note" });
+ r7({ machine: "note" });
return;
}
try {
- await tI(new AbortController().signal);
+ await nI(new AbortController().signal);
} catch {}
- e7.open && i7({ machine: "summary" });
+ $5.open && r7({ machine: "summary" });
}
}
-function FHe(e = "") {
- let t = Z5;
+function LHe(e = "") {
+ let t = X5;
if (!t) return;
- y(), t7 += 1, n7 ||= document.activeElement, t.sound("whoosh"), document.documentElement.style.overflow = "hidden", document.body.classList.add("settings-open");
- let n = X5.findIndex(([t]) => t === e), r = Vx();
- i7({
+ y(), e7 += 1, t7 ||= document.activeElement, t.sound("whoosh"), document.documentElement.style.overflow = "hidden", document.body.classList.add("settings-open");
+ let n = Y5.findIndex(([t]) => t === e), r = Kre();
+ r7({
open: !0,
closing: !1,
- epoch: e7.epoch + 1,
- tab: n >= 0 ? n : e7.tab
+ epoch: $5.epoch + 1,
+ tab: n >= 0 ? n : $5.tab
}), r.then((e) => {
e && t.syncRemote(e);
- }), PHe(t), queueMicrotask(() => document.getElementById("settingsClose")?.focus());
+ }), IHe(t), queueMicrotask(() => document.getElementById("settingsClose")?.focus());
}
-function a7() {
- if (!e7.open || e7.closing) return;
- let e = ++t7;
- i7({ closing: !0 });
+function i7() {
+ if (!$5.open || $5.closing) return;
+ let e = ++e7;
+ r7({ closing: !0 });
let t = () => {
- e !== t7 || !e7.closing || (i7({
+ e !== e7 || !$5.closing || (r7({
open: !1,
closing: !1
- }), document.documentElement.style.overflow = "", document.body.classList.remove("settings-open"), n7 instanceof HTMLElement && document.contains(n7) && n7.focus(), n7 = null);
+ }), document.documentElement.style.overflow = "", document.body.classList.remove("settings-open"), t7 instanceof HTMLElement && document.contains(t7) && t7.focus(), t7 = null);
};
if (matchMedia("(prefers-reduced-motion: reduce)").matches) {
queueMicrotask(t);
return;
}
- $5?.querySelector("[data-settings-card]")?.addEventListener("animationend", t, { once: !0 }), setTimeout(t, 380);
+ Q5?.querySelector("[data-settings-card]")?.addEventListener("animationend", t, { once: !0 }), setTimeout(t, 380);
}
-var IHe = {
- open: FHe,
- close: a7,
- isOpen: () => e7.open,
+var RHe = {
+ open: LHe,
+ close: i7,
+ isOpen: () => $5.open,
reveal: (e) => queueMicrotask(() => document.querySelector(e)?.scrollIntoView({ block: "nearest" }))
};
-function LHe(e) {
- return Z5 = e, r7(), IHe;
+function zHe(e) {
+ return X5 = e, n7(), RHe;
}
-function RHe(e) {
+function BHe(e) {
if (e.key !== "Tab") return;
- let t = [...e.currentTarget.querySelectorAll(MHe)].filter((e) => e.getClientRects().length > 0);
+ let t = [...e.currentTarget.querySelectorAll(PHe)].filter((e) => e.getClientRects().length > 0);
if (!t.length) return;
let n = t[0], r = t[t.length - 1];
e.shiftKey && document.activeElement === n ? (e.preventDefault(), r.focus()) : !e.shiftKey && document.activeElement === r && (e.preventDefault(), n.focus());
}
-var o7 = (e) => `settings-tab-${e}`, s7 = (e) => e === X5.length - 1 ? "machineGroup" : `settings-group-${e}`;
-function zHe({ tab: e, epoch: t, onSelect: n }) {
+var a7 = (e) => `settings-tab-${e}`, o7 = (e) => e === Y5.length - 1 ? "machineGroup" : `settings-group-${e}`;
+function VHe({ tab: e, epoch: t, onSelect: n }) {
let r = (0, R.useRef)(null), i = (0, R.useRef)(null), a = (0, R.useRef)(null), o = (0, R.useRef)(e), s = (0, R.useRef)([]), c = (e, t) => {
let n = i.current;
if (!n) return;
@@ -76423,7 +76475,7 @@ function zHe({ tab: e, epoch: t, onSelect: n }) {
o.current = e, l.current(s.current[e], t);
}, [e, t]);
let u = (e, t) => {
- let r = X5.length, i = t;
+ let r = Y5.length, i = t;
if (e.key === "ArrowRight" || e.key === "ArrowDown") i = (t + 1) % r;
else if (e.key === "ArrowLeft" || e.key === "ArrowUp") i = (t + r - 1) % r;
else if (e.key === "Home") i = 0;
@@ -76452,11 +76504,11 @@ function zHe({ tab: e, epoch: t, onSelect: n }) {
role: "presentation",
children: "设置"
}),
- X5.map(([t, r], i) => /* @__PURE__ */ (0, z.jsxs)("button", {
+ Y5.map(([t, r], i) => /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
role: "tab",
- id: o7(i),
- "aria-controls": s7(i),
+ id: a7(i),
+ "aria-controls": o7(i),
"aria-selected": i === e,
tabIndex: i === e ? 0 : -1,
ref: (e) => {
@@ -76467,22 +76519,22 @@ function zHe({ tab: e, epoch: t, onSelect: n }) {
onPointerEnter: (e) => {
e.pointerType !== "touch" && c(e.currentTarget, !0);
},
- children: [/* @__PURE__ */ (0, z.jsx)(oHe, { name: r }), t]
+ children: [/* @__PURE__ */ (0, z.jsx)(cHe, { name: r }), t]
}, t))
]
});
}
-function c7({ index: e, tab: t, children: n }) {
+function s7({ index: e, tab: t, children: n }) {
return /* @__PURE__ */ (0, z.jsxs)("section", {
"data-setting-group": "",
- id: s7(e),
+ id: o7(e),
role: "tabpanel",
- "aria-labelledby": o7(e),
+ "aria-labelledby": a7(e),
hidden: e !== t,
- children: [/* @__PURE__ */ (0, z.jsx)("h3", { children: X5[e][0] }), n]
+ children: [/* @__PURE__ */ (0, z.jsx)("h3", { children: Y5[e][0] }), n]
});
}
-function l7({ id: e, title: t, description: n, describedBy: r = `${e.replace(/Setting$/, "")}Description`, checked: i, onToggle: a }) {
+function c7({ id: e, title: t, description: n, describedBy: r = `${e.replace(/Setting$/, "")}Description`, checked: i, onToggle: a }) {
return /* @__PURE__ */ (0, z.jsxs)("label", {
"data-setting-row": "",
children: [/* @__PURE__ */ (0, z.jsxs)("span", { children: [/* @__PURE__ */ (0, z.jsx)("b", { children: t }), /* @__PURE__ */ (0, z.jsx)("small", {
@@ -76499,7 +76551,7 @@ function l7({ id: e, title: t, description: n, describedBy: r = `${e.replace(/Se
})]
});
}
-function u7({ title: e, description: t, kind: n, children: r }) {
+function l7({ title: e, description: t, kind: n, children: r }) {
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-setting-row": "",
"data-setting-sort": n === "sort" ? "" : void 0,
@@ -76507,11 +76559,11 @@ function u7({ title: e, description: t, kind: n, children: r }) {
children: [/* @__PURE__ */ (0, z.jsxs)("span", { children: [/* @__PURE__ */ (0, z.jsx)("b", { children: e }), typeof t == "string" ? /* @__PURE__ */ (0, z.jsx)("small", { children: t }) : t] }), r]
});
}
-var d7 = ({ html: e, ...t }) => /* @__PURE__ */ (0, z.jsx)("small", {
+var u7 = ({ html: e, ...t }) => /* @__PURE__ */ (0, z.jsx)("small", {
...t,
dangerouslySetInnerHTML: { __html: e }
-}), f7 = () => `${ie("保存中")}<span>正在保存…</span>`, p7 = (e, t) => e instanceof Error && e.message || t;
-function BHe({ host: e, view: t }) {
+}), d7 = () => `${ie("保存中")}<span>正在保存…</span>`, f7 = (e, t) => e instanceof Error && e.message || t;
+function HHe({ host: e, view: t }) {
let n = (0, R.useSyncExternalStore)(e.store.subscribe, e.store.version), r = e.store.value, i = (0, R.useRef)(null), a = (0, R.useRef)(null), o = (0, R.useRef)(null), s = (0, R.useRef)(null), c = (0, R.useRef)(null), l = (0, R.useRef)(t.tab), u = () => {
let [e, t] = [a.current, s.current];
if (!e || !t) return;
@@ -76531,7 +76583,7 @@ function BHe({ host: e, view: t }) {
c.current?.();
});
let f = t.epoch, p = (e) => {
- e !== e7.tab && i7({ tab: e });
+ e !== $5.tab && r7({ tab: e });
}, m = () => e.store.save();
return /* @__PURE__ */ (0, z.jsx)("section", {
"data-settings-panel": "",
@@ -76542,9 +76594,9 @@ function BHe({ host: e, view: t }) {
"aria-labelledby": "settingsTitle",
"data-closing": t.closing ? "" : void 0,
ref: i,
- onKeyDown: RHe,
+ onKeyDown: BHe,
onClick: (e) => {
- e.target === e.currentTarget && a7();
+ e.target === e.currentTarget && i7();
},
children: /* @__PURE__ */ (0, z.jsxs)("div", {
"data-settings-card": "",
@@ -76555,19 +76607,19 @@ function BHe({ host: e, view: t }) {
ref: o,
children: [/* @__PURE__ */ (0, z.jsx)("h2", {
id: "settingsTitle",
- children: X5[t.tab][0]
+ children: Y5[t.tab][0]
}), /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
id: "settingsClose",
"aria-label": "关闭设置",
- onClick: a7,
+ onClick: i7,
children: /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
children: /* @__PURE__ */ (0, z.jsx)("use", { href: "#i-x" })
})
})]
}),
- /* @__PURE__ */ (0, z.jsx)(zHe, {
+ /* @__PURE__ */ (0, z.jsx)(VHe, {
tab: t.tab,
epoch: f,
onSelect: p
@@ -76576,14 +76628,14 @@ function BHe({ host: e, view: t }) {
"data-settings-scroll": "",
ref: s,
children: [
- /* @__PURE__ */ (0, z.jsxs)(c7, {
+ /* @__PURE__ */ (0, z.jsxs)(s7, {
index: 0,
tab: t.tab,
children: [
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "主题",
description: "跟随系统,或固定用浅色、深色。",
- children: /* @__PURE__ */ (0, z.jsx)(U5, {
+ children: /* @__PURE__ */ (0, z.jsx)(H5, {
id: "themeSetting",
name: "theme",
legend: "主题",
@@ -76611,7 +76663,7 @@ function BHe({ host: e, view: t }) {
onChange: (t) => e.setHighContrast(t.target.checked)
})]
}),
- /* @__PURE__ */ (0, z.jsx)(l7, {
+ /* @__PURE__ */ (0, z.jsx)(c7, {
id: "uiSoundsSetting",
title: "界面音效",
checked: r.uiSounds,
@@ -76620,7 +76672,7 @@ function BHe({ host: e, view: t }) {
r.uiSounds = t, m(), e.changed("uiSounds");
}
}),
- /* @__PURE__ */ (0, z.jsx)(l7, {
+ /* @__PURE__ */ (0, z.jsx)(c7, {
id: "homeGlowSetting",
title: "侧栏光晕",
checked: r.homeGlow.on,
@@ -76629,7 +76681,7 @@ function BHe({ host: e, view: t }) {
r.homeGlow.on = t, m(), e.changed("glow");
}
}),
- /* @__PURE__ */ (0, z.jsx)(xHe, {
+ /* @__PURE__ */ (0, z.jsx)(CHe, {
host: e,
version: n
}),
@@ -76639,37 +76691,37 @@ function BHe({ host: e, view: t }) {
children: [/* @__PURE__ */ (0, z.jsxs)("span", { children: [/* @__PURE__ */ (0, z.jsx)("b", {
id: "sidebarOrderTitle",
children: "左侧导航"
- }), /* @__PURE__ */ (0, z.jsx)("small", { children: "直接拖动排序;可隐藏入口,也可从具体页面列表重新添加。窄栏和筛选抽屉会保持一致。" })] }), /* @__PURE__ */ (0, z.jsx)(wHe, { host: e })]
+ }), /* @__PURE__ */ (0, z.jsx)("small", { children: "直接拖动排序;可隐藏入口,也可从具体页面列表重新添加。窄栏和筛选抽屉会保持一致。" })] }), /* @__PURE__ */ (0, z.jsx)(EHe, { host: e })]
})
]
}),
- /* @__PURE__ */ (0, z.jsx)(HHe, {
+ /* @__PURE__ */ (0, z.jsx)(WHe, {
host: e,
tab: t.tab,
epoch: f
}),
- /* @__PURE__ */ (0, z.jsx)(WHe, {
+ /* @__PURE__ */ (0, z.jsx)(KHe, {
host: e,
tab: t.tab,
epoch: f
}),
- /* @__PURE__ */ (0, z.jsx)(c7, {
+ /* @__PURE__ */ (0, z.jsx)(s7, {
index: 3,
tab: t.tab,
- children: /* @__PURE__ */ (0, z.jsx)(KHe, {
+ children: /* @__PURE__ */ (0, z.jsx)(JHe, {
host: e,
epoch: f
})
}),
- /* @__PURE__ */ (0, z.jsx)(qHe, {
+ /* @__PURE__ */ (0, z.jsx)(YHe, {
host: e,
tab: t.tab,
epoch: f
}),
- /* @__PURE__ */ (0, z.jsx)(c7, {
+ /* @__PURE__ */ (0, z.jsx)(s7, {
index: 5,
tab: t.tab,
- children: /* @__PURE__ */ (0, z.jsx)(l7, {
+ children: /* @__PURE__ */ (0, z.jsx)(c7, {
id: "censorSetting",
title: "SFW 模式",
describedBy: "sfwDescription",
@@ -76678,10 +76730,10 @@ function BHe({ host: e, view: t }) {
onToggle: (t) => e.setCensored(t)
})
}),
- /* @__PURE__ */ (0, z.jsx)(c7, {
+ /* @__PURE__ */ (0, z.jsx)(s7, {
index: 6,
tab: t.tab,
- children: /* @__PURE__ */ (0, z.jsx)(YHe, {
+ children: /* @__PURE__ */ (0, z.jsx)(ZHe, {
host: e,
machine: t.machine
})
@@ -76692,7 +76744,7 @@ function BHe({ host: e, view: t }) {
})
});
}
-function VHe(e, t) {
+function UHe(e, t) {
let n = e.querySelector("[data-select-label]");
if (!n) return;
n.querySelector("[data-icon-swap]") || (n.innerHTML = E("arrow-up", "arrow-down", "a", {
@@ -76702,18 +76754,18 @@ function VHe(e, t) {
let r = n.querySelector("[data-sort-direction-label]");
r && (r.textContent = t ? "升序" : "降序");
}
-function HHe({ host: e, tab: t, epoch: n }) {
+function WHe({ host: e, tab: t, epoch: n }) {
let r = e.store.value, i = () => e.store.save(), a = r.defaultSort === "seed", o = r.defaultSortDirection === "asc";
- return /* @__PURE__ */ (0, z.jsxs)(c7, {
+ return /* @__PURE__ */ (0, z.jsxs)(s7, {
index: 1,
tab: t,
children: [
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "每批作品",
description: "首页每次加载的作品数量。",
children: /* @__PURE__ */ (0, z.jsx)("div", {
id: "batchSizeSetting",
- children: /* @__PURE__ */ (0, z.jsx)(K5, {
+ children: /* @__PURE__ */ (0, z.jsx)(G5, {
id: "batchSizeSetting",
label: "每批作品",
value: r.batchSize,
@@ -76723,7 +76775,7 @@ function HHe({ host: e, tab: t, epoch: n }) {
}, n)
})
}),
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "默认排序",
kind: "sort",
description: /* @__PURE__ */ (0, z.jsx)("small", {
@@ -76732,19 +76784,19 @@ function HHe({ host: e, tab: t, epoch: n }) {
}),
children: /* @__PURE__ */ (0, z.jsxs)("div", {
"data-setting-sort-controls": "",
- children: [/* @__PURE__ */ (0, z.jsx)(W5, {
+ children: [/* @__PURE__ */ (0, z.jsx)(U5, {
id: "defaultSortSetting",
label: "默认排序",
- options: THe,
+ options: DHe,
value: r.defaultSort,
epoch: n,
onPick: (t) => {
r.defaultSort = t, i(), e.changed("defaultSort");
}
- }), /* @__PURE__ */ (0, z.jsx)(W5, {
+ }), /* @__PURE__ */ (0, z.jsx)(U5, {
id: "defaultSortDirectionSetting",
label: "默认排序方向",
- options: EHe,
+ options: OHe,
value: o ? "asc" : "desc",
hidden: a,
disabled: a,
@@ -76753,7 +76805,7 @@ function HHe({ host: e, tab: t, epoch: n }) {
onPick: (t) => {
r.defaultSortDirection = t, i(), e.changed("sortDirection");
},
- decorate: (e) => VHe(e, o)
+ decorate: (e) => UHe(e, o)
})]
})
}),
@@ -76770,29 +76822,29 @@ function HHe({ host: e, tab: t, epoch: n }) {
}
})]
}),
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "JAV 默认封面",
description: "首页、接着看和 Mix 等位置共用;缺图时使用另一种封面。",
- children: /* @__PURE__ */ (0, z.jsx)(U5, {
+ children: /* @__PURE__ */ (0, z.jsx)(H5, {
id: "javImageSetting",
name: "jav-image",
legend: "JAV 默认封面",
- options: AHe,
+ options: MHe,
value: r.javImage,
attr: "data-jav-image-choice",
variant: "javimageswitch",
text: !0,
epoch: n,
onChoose: (t) => {
- r.javImage = db(t), i(), e.changed("javImage");
+ r.javImage = eb(t), i(), e.changed("javImage");
}
})
}),
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "视频封面默认大小",
kind: "related",
description: "首页和 JAV 等视频列表共用;小图展示完整封套,大图展示完整正封。",
- children: /* @__PURE__ */ (0, z.jsx)(U5, {
+ children: /* @__PURE__ */ (0, z.jsx)(H5, {
id: "javSizeSetting",
name: "video-size",
legend: "视频封面默认大小",
@@ -76805,7 +76857,7 @@ function HHe({ host: e, tab: t, epoch: n }) {
onChoose: (t) => e.setVideoLayout(t)
})
}),
- /* @__PURE__ */ (0, z.jsx)(l7, {
+ /* @__PURE__ */ (0, z.jsx)(c7, {
id: "feedAutoScrollSetting",
title: "新作自动滚动",
checked: r.feedAutoScroll,
@@ -76814,7 +76866,7 @@ function HHe({ host: e, tab: t, epoch: n }) {
r.feedAutoScroll = t, i(), e.changed("feedAutoScroll");
}
}),
- jHe.map(([t, n, r, i, a, o]) => /* @__PURE__ */ (0, z.jsx)(UHe, {
+ NHe.map(([t, n, r, i, a, o]) => /* @__PURE__ */ (0, z.jsx)(GHe, {
host: e,
id: t,
settingKey: n,
@@ -76826,8 +76878,8 @@ function HHe({ host: e, tab: t, epoch: n }) {
]
});
}
-function UHe({ host: e, id: t, settingKey: n, label: r, title: i, describedBy: a, description: o }) {
- let s = Hx(), [c, l] = (0, R.useState)(null), u = (0, R.useRef)(null), d = e.store.value, f = (t) => {
+function GHe({ host: e, id: t, settingKey: n, label: r, title: i, describedBy: a, description: o }) {
+ let s = Kx(), [c, l] = (0, R.useState)(null), u = (0, R.useRef)(null), d = e.store.value, f = (t) => {
l(t), te(u.current), s.mutate({ [n]: t }, {
onSuccess: (i) => {
d[n] = i[n] === !0, e.store.save(), e.changed("feedCompilations"), e.receipt(t ? `新作已收起${r}` : `新作已列出${r}`);
@@ -76855,28 +76907,28 @@ function UHe({ host: e, id: t, settingKey: n, label: r, title: i, describedBy: a
})]
});
}
-function WHe({ host: e, tab: t, epoch: n }) {
+function KHe({ host: e, tab: t, epoch: n }) {
let r = e.store.value, i = () => e.store.save();
- return /* @__PURE__ */ (0, z.jsxs)(c7, {
+ return /* @__PURE__ */ (0, z.jsxs)(s7, {
index: 2,
tab: t,
children: [
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "悬停放大",
description: "转圈完成后进入放大预览。",
children: /* @__PURE__ */ (0, z.jsx)("div", {
id: "hoverDelaySetting",
- children: /* @__PURE__ */ (0, z.jsx)(K5, {
+ children: /* @__PURE__ */ (0, z.jsx)(G5, {
id: "hoverDelaySetting",
label: "悬停放大",
value: r.hoverDelaySeconds,
onApply: (t) => {
- r.hoverDelaySeconds = V5(t, 0, 60, 5), i(), e.changed("hoverDelay");
+ r.hoverDelaySeconds = B5(t, 0, 60, 5), i(), e.changed("hoverDelay");
}
}, n)
})
}),
- /* @__PURE__ */ (0, z.jsx)(l7, {
+ /* @__PURE__ */ (0, z.jsx)(c7, {
id: "detailAutoplaySetting",
title: "打开详情自动播放",
checked: r.detailAutoplay,
@@ -76885,7 +76937,7 @@ function WHe({ host: e, tab: t, epoch: n }) {
r.detailAutoplay = e, i();
}
}),
- /* @__PURE__ */ (0, z.jsx)(l7, {
+ /* @__PURE__ */ (0, z.jsx)(c7, {
id: "miniplayerSetting",
title: "小窗播放",
checked: r.miniplayer,
@@ -76894,12 +76946,12 @@ function WHe({ host: e, tab: t, epoch: n }) {
r.miniplayer = t, i(), e.changed("miniplayer");
}
}),
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "快进 / 快退",
description: "卡片预览和详情播放器共用。",
children: /* @__PURE__ */ (0, z.jsx)("div", {
id: "seekSecondsSetting",
- children: /* @__PURE__ */ (0, z.jsx)(K5, {
+ children: /* @__PURE__ */ (0, z.jsx)(G5, {
id: "seekSecondsSetting",
label: "快进 / 快退",
value: r.seekSeconds,
@@ -76909,13 +76961,13 @@ function WHe({ host: e, tab: t, epoch: n }) {
}, n)
})
}),
- /* @__PURE__ */ (0, z.jsx)(GHe, { epoch: n }),
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(qHe, { epoch: n }),
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "相关推荐",
description: "详情下方一次显示的相似作品数量。",
children: /* @__PURE__ */ (0, z.jsx)("div", {
id: "relatedLimitSetting",
- children: /* @__PURE__ */ (0, z.jsx)(K5, {
+ children: /* @__PURE__ */ (0, z.jsx)(G5, {
id: "relatedLimitSetting",
label: "相关推荐",
value: r.relatedLimit,
@@ -76928,26 +76980,26 @@ function WHe({ host: e, tab: t, epoch: n }) {
]
});
}
-function GHe({ epoch: e }) {
+function qHe({ epoch: e }) {
let t = $n({
- queryKey: Rx,
- queryFn: ({ signal: e }) => Bx(e)
- }), n = Wx(), r = n.reset;
+ queryKey: Ux,
+ queryFn: ({ signal: e }) => Gx(e)
+ }), n = Jre(), r = n.reset;
(0, R.useEffect)(() => {
r();
}, [e, r]);
- let i = t.data?.mode || "off", a = n.isPending ? f7() : t.isFetching ? k("正在读取状态") : n.isError ? m7(p7(n.error, "保存失败")) : t.isError ? m7(`状态未取得:${p7(t.error, String(t.error))}`) : t.data ? m7(Kx(t.data)) : "读取运行状态…";
- return /* @__PURE__ */ (0, z.jsx)(u7, {
+ let i = t.data?.mode || "off", a = n.isPending ? d7() : t.isFetching ? k("正在读取状态") : n.isError ? p7(f7(n.error, "保存失败")) : t.isError ? p7(`状态未取得:${f7(t.error, String(t.error))}`) : t.data ? p7(Xre(t.data)) : "读取运行状态…";
+ return /* @__PURE__ */ (0, z.jsx)(l7, {
title: "视频缩略图采集",
- description: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("small", { children: "拖动进度条时按时间点看画面。精准每 10 秒一张,粗略每 30 秒一张;两小时的片子约 720 / 240 张,占 20–100 / 7–35 MB。只采集本机磁盘上的片子,网盘上的每张都要回源拉一次。" }), /* @__PURE__ */ (0, z.jsx)(d7, {
+ description: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("small", { children: "拖动进度条时按时间点看画面。精准每 10 秒一张,粗略每 30 秒一张;两小时的片子约 720 / 240 张,占 20–100 / 7–35 MB。只采集本机磁盘上的片子,网盘上的每张都要回源拉一次。" }), /* @__PURE__ */ (0, z.jsx)(u7, {
id: "videoThumbnailState",
"aria-live": "polite",
html: a
})] }),
- children: /* @__PURE__ */ (0, z.jsx)(W5, {
+ children: /* @__PURE__ */ (0, z.jsx)(U5, {
id: "videoThumbnailSetting",
label: "视频缩略图采集",
- options: DHe,
+ options: kHe,
value: n.isPending || n.isError ? n.variables ?? i : i,
disabled: n.isPending || t.isFetching,
epoch: e,
@@ -76955,26 +77007,26 @@ function GHe({ epoch: e }) {
})
});
}
-function KHe({ host: e, epoch: t }) {
- let n = e.store.value, r = Hx();
- return /* @__PURE__ */ (0, z.jsx)(u7, {
+function JHe({ host: e, epoch: t }) {
+ let n = e.store.value, r = Kx();
+ return /* @__PURE__ */ (0, z.jsx)(l7, {
title: "搜索记录",
description: "保存在 Peach 账本,所有访问端同步。",
children: /* @__PURE__ */ (0, z.jsx)("div", {
id: "searchHistoryLimitSetting",
- children: /* @__PURE__ */ (0, z.jsx)(K5, {
+ children: /* @__PURE__ */ (0, z.jsx)(G5, {
id: "searchHistoryLimitSetting",
label: "搜索记录",
value: n.searchHistoryLimit,
onApply: (t) => {
- n.searchHistoryLimit = V5(t, 0, 50, 10), e.store.save(), e.changed("searchHistoryLimit"), r.mutate({ searchHistoryLimit: n.searchHistoryLimit }, { onError: () => {} });
+ n.searchHistoryLimit = B5(t, 0, 50, 10), e.store.save(), e.changed("searchHistoryLimit"), r.mutate({ searchHistoryLimit: n.searchHistoryLimit }, { onError: () => {} });
}
}, t)
})
});
}
-function qHe({ host: e, tab: t, epoch: n }) {
- let r = e.store.value, i = Hx(), a = Hx(), [o, s] = (0, R.useState)("");
+function YHe({ host: e, tab: t, epoch: n }) {
+ let r = e.store.value, i = Kx(), a = Kx(), [o, s] = (0, R.useState)("");
(0, R.useEffect)(() => {
s("");
}, [n]);
@@ -76984,22 +77036,22 @@ function qHe({ host: e, tab: t, epoch: n }) {
typeof t.followInitialDays == "number" && (r.followInitialDays = t.followInitialDays), e.store.save(), s("已保存,适用于尚未开始采集的来源。"), e.receipt("已保存首次采集历史范围");
},
onError: (t) => {
- s(p7(t, "")), e.failure("保存首次采集历史范围", t);
+ s(f7(t, "")), e.failure("保存首次采集历史范围", t);
}
}));
};
- return /* @__PURE__ */ (0, z.jsxs)(c7, {
+ return /* @__PURE__ */ (0, z.jsxs)(s7, {
index: 4,
tab: t,
children: [
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "首次采集历史范围",
description: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("small", { children: "按发布时间限制新来源首次导入的内容;范围内不足 30 条时补到 30 条。没有日期的条目仍会导入;已有内容不受影响,支持历史分页的来源可手动加载更早。" }), /* @__PURE__ */ (0, z.jsx)("small", {
id: "followInitialDaysState",
"aria-live": "polite",
children: o
})] }),
- children: /* @__PURE__ */ (0, z.jsx)(W5, {
+ children: /* @__PURE__ */ (0, z.jsx)(U5, {
id: "followInitialDaysSetting",
label: "首次采集历史范围",
options: e.followInitialRanges,
@@ -77009,44 +77061,44 @@ function qHe({ host: e, tab: t, epoch: n }) {
onPick: (e) => c(Number(e))
})
}),
- /* @__PURE__ */ (0, z.jsx)(JHe, { epoch: n }),
- /* @__PURE__ */ (0, z.jsx)(u7, {
+ /* @__PURE__ */ (0, z.jsx)(XHe, { epoch: n }),
+ /* @__PURE__ */ (0, z.jsx)(l7, {
title: "头像与站点图标刷新",
description: "创作者头像、来源图标和外链圆标保存在本机,到期后下次显示时重新取一次;视频与图片不保存。",
- children: /* @__PURE__ */ (0, z.jsx)(W5, {
+ children: /* @__PURE__ */ (0, z.jsx)(U5, {
id: "metadataRefreshSetting",
label: "头像与站点图标刷新",
- options: OHe,
+ options: AHe,
value: String(r.metadataRefreshDays),
epoch: n,
onPick: (t) => {
let n = Number(t);
- r.metadataRefreshDays = kHe.includes(n) ? n : 30, e.store.save(), i.mutate({ metadataRefreshDays: r.metadataRefreshDays }, { onError: () => {} });
+ r.metadataRefreshDays = jHe.includes(n) ? n : 30, e.store.save(), i.mutate({ metadataRefreshDays: r.metadataRefreshDays }, { onError: () => {} });
}
})
})
]
});
}
-function JHe({ epoch: e }) {
+function XHe({ epoch: e }) {
let t = $n({
- queryKey: Lx,
- queryFn: ({ signal: e }) => zx(e)
- }), n = Ux(), r = n.reset;
+ queryKey: Hx,
+ queryFn: ({ signal: e }) => Wx(e)
+ }), n = qre(), r = n.reset;
(0, R.useEffect)(() => {
r();
}, [e, r]);
- let i = t.data, a = n.isPending || t.isFetching || t.isError && !n.isError, o = n.isPending ? f7() : t.isFetching ? k("正在读取状态") : n.isError ? m7(p7(n.error, "保存失败")) : t.isError ? m7(`状态未取得:${p7(t.error, String(t.error))}`) : i ? m7(Gx(i)) : "读取运行状态…";
- return /* @__PURE__ */ (0, z.jsx)(u7, {
+ let i = t.data, a = n.isPending || t.isFetching || t.isError && !n.isError, o = n.isPending ? d7() : t.isFetching ? k("正在读取状态") : n.isError ? p7(f7(n.error, "保存失败")) : t.isError ? p7(`状态未取得:${f7(t.error, String(t.error))}`) : i ? p7(Yre(i)) : "读取运行状态…";
+ return /* @__PURE__ */ (0, z.jsx)(l7, {
title: "关注自动更新",
- description: /* @__PURE__ */ (0, z.jsx)(d7, {
+ description: /* @__PURE__ */ (0, z.jsx)(u7, {
id: "followScheduleState",
"aria-live": "polite",
html: o
}),
children: /* @__PURE__ */ (0, z.jsx)("div", {
id: "followScheduleSetting",
- children: /* @__PURE__ */ (0, z.jsx)(K5, {
+ children: /* @__PURE__ */ (0, z.jsx)(G5, {
id: "followScheduleSetting",
label: "关注自动更新",
value: i && !a ? i.enabled ? i.interval_minutes : 0 : null,
@@ -77056,13 +77108,13 @@ function JHe({ epoch: e }) {
})
});
}
-function YHe({ host: e, machine: t }) {
+function ZHe({ host: e, machine: t }) {
return t === "summary" ? /* @__PURE__ */ (0, z.jsx)("div", {
id: "machineSettings",
children: /* @__PURE__ */ (0, z.jsx)("div", {
className: "peach-react",
- children: /* @__PURE__ */ (0, z.jsx)(gHe, { openConfiguration: () => {
- a7(), e.openConfiguration();
+ children: /* @__PURE__ */ (0, z.jsx)(vHe, { openConfiguration: () => {
+ i7(), e.openConfiguration();
} })
})
}, "summary") : t === "note" ? /* @__PURE__ */ (0, z.jsx)("div", {
@@ -77070,55 +77122,55 @@ function YHe({ host: e, machine: t }) {
dangerouslySetInnerHTML: { __html: j("媒体文件夹、端口、代理与更新只能在运行 Peach 服务的那台设备上改:在它的浏览器里打开配置页。", { label: "在服务端设备修改" }) }
}, "note") : /* @__PURE__ */ (0, z.jsx)("div", { id: "machineSettings" }, "none");
}
-function m7(e) {
+function p7(e) {
return e.replace(/[&<>"']/g, (e) => `&#${e.charCodeAt(0)};`);
}
//#endregion
//#region src/react/sidebar/sidebar-island.tsx
-var h7 = "__home__", XHe = {
+var m7 = "__home__", QHe = {
creator: 26,
tag: 30,
tech: 16
-}, g7 = 180, _7 = null, v7 = null, y7 = {
+}, h7 = 180, g7 = null, _7 = null, v7 = {
content: null,
filters: {},
latest: null
-}, b7 = 0;
-function x7() {
- let e = _7;
- if (!e || !v7) return;
- let t = y7, n = b7;
- (0, ze.flushSync)(() => v7.render(/* @__PURE__ */ (0, z.jsx)(IF, { children: /* @__PURE__ */ (0, z.jsx)($He, {
+}, y7 = 0;
+function b7() {
+ let e = g7;
+ if (!e || !_7) return;
+ let t = v7, n = y7;
+ (0, ze.flushSync)(() => _7.render(/* @__PURE__ */ (0, z.jsx)(LF, { children: /* @__PURE__ */ (0, z.jsx)(tUe, {
host: e,
props: t,
epoch: n
}) })));
}
-var ZHe = {
+var $He = {
render(e) {
- y7 = e, x7();
+ v7 = e, b7();
},
navChanged() {
- b7 += 1, x7();
+ y7 += 1, b7();
}
};
-function QHe(e) {
- return _7 = e, y7 = {
+function eUe(e) {
+ return g7 = e, v7 = {
content: null,
filters: {},
latest: null
- }, e.scroll.replaceChildren(), v7 = (0, Be.createRoot)(e.scroll), x7(), e.attached(), ZHe;
+ }, e.scroll.replaceChildren(), _7 = (0, Be.createRoot)(e.scroll), b7(), e.attached(), $He;
}
-function $He({ host: e, props: t, epoch: n }) {
+function tUe({ host: e, props: t, epoch: n }) {
let r = (0, R.useSyncExternalStore)(e.store.subscribe, e.store.version);
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsx)("div", { "data-sidebar-head": "" }),
- /* @__PURE__ */ (0, z.jsx)(eUe, {
+ /* @__PURE__ */ (0, z.jsx)(nUe, {
host: e,
epoch: n,
version: r
}),
- t.content ? /* @__PURE__ */ (0, z.jsx)(nUe, {
+ t.content ? /* @__PURE__ */ (0, z.jsx)(iUe, {
host: e,
content: t.content,
filters: t.filters,
@@ -77126,8 +77178,8 @@ function $He({ host: e, props: t, epoch: n }) {
}) : null
] });
}
-function eUe({ host: e, epoch: t, version: n }) {
- let r = q5(e.store), i = e.store.value.sidebarOrder, a = new Map(e.navCatalog.map((e) => [e[0], e])), o = i.map((e) => a.get(e)).filter((e) => e !== void 0), s = o.map(([t]) => e.navOn(t)), c = (0, R.useRef)(null), l = (0, R.useRef)(null), u = ZO(l, c, "[data-nav][aria-pressed=\"true\"]", `${t}:${n}:${o.map(([e], t) => s[t] ? e || h7 : "").join(",")}`, { axis: "y" }), { sync: d } = u;
+function nUe({ host: e, epoch: t, version: n }) {
+ let r = K5(e.store), i = e.store.value.sidebarOrder, a = new Map(e.navCatalog.map((e) => [e[0], e])), o = i.map((e) => a.get(e)).filter((e) => e !== void 0), s = o.map(([t]) => e.navOn(t)), c = (0, R.useRef)(null), l = (0, R.useRef)(null), u = UO(l, c, "[data-nav][aria-pressed=\"true\"]", `${t}:${n}:${o.map(([e], t) => s[t] ? e || m7 : "").join(",")}`, { axis: "y" }), { sync: d } = u;
(0, R.useEffect)(() => {
let t = e.scroll, n = t.parentElement, r = t.querySelector(":scope > [data-sidebar-head]"), i = new ResizeObserver(() => d());
return [
@@ -77145,7 +77197,7 @@ function eUe({ host: e, epoch: t, version: n }) {
}, _ = (e) => ({
draggable: !0,
onDragStart: (t) => {
- p(e), t.dataTransfer.effectAllowed = "move", t.dataTransfer.setData("text/plain", e || h7);
+ p(e), t.dataTransfer.effectAllowed = "move", t.dataTransfer.setData("text/plain", e || m7);
},
onDragOver: (t) => {
if (f === null || f === e) return;
@@ -77160,7 +77212,7 @@ function eUe({ host: e, epoch: t, version: n }) {
t.preventDefault();
let n = f, a = m?.key === e && m.after;
g();
- let o = n === null ? null : J5(i, n, e, a);
+ let o = n === null ? null : q5(i, n, e, a);
o && r(o);
},
onDragEnd: g
@@ -77183,16 +77235,16 @@ function eUe({ host: e, epoch: t, version: n }) {
"data-sidebar-home-logo": "",
src: "/peach-logo.png",
alt: ""
- }) : /* @__PURE__ */ (0, z.jsx)(F5, { name: r }), /* @__PURE__ */ (0, z.jsx)("span", { children: n })]
- }, t || h7))
+ }) : /* @__PURE__ */ (0, z.jsx)(P5, { name: r }), /* @__PURE__ */ (0, z.jsx)("span", { children: n })]
+ }, t || m7))
}), v ? (0, ze.createPortal)(/* @__PURE__ */ (0, z.jsx)("span", {
"data-sidebar-glide": "",
"aria-hidden": "true",
ref: l
}), v) : null] });
}
-var S7 = (e, t) => String(e[t] ?? "").split(",").filter(Boolean);
-function tUe(e) {
+var x7 = (e, t) => String(e[t] ?? "").split(",").filter(Boolean);
+function rUe(e) {
if (!e) return null;
let t = /* @__PURE__ */ new Map(), n = [
["loc", e.locations],
@@ -77205,7 +77257,7 @@ function tUe(e) {
for (let [e, r] of n) for (let n of r) t.set(`${e}\n${n.value}`, n.n ?? 0);
return t;
}
-function nUe({ host: e, content: t, filters: n, latest: r }) {
+function iUe({ host: e, content: t, filters: n, latest: r }) {
let i = t.kind === "catalog" ? t.key : `follow:${t.selected.join(",")}:${t.tags.map((e) => e.value).join(",")}`;
(0, R.useLayoutEffect)(() => {
t.kind === "catalog" && M(e.scroll, "drawer");
@@ -77214,8 +77266,8 @@ function nUe({ host: e, content: t, filters: n, latest: r }) {
i,
t.kind
]);
- let a = t.kind === "catalog" ? rUe(e, t.facets, n, r, i) : [iUe(e, t.tags, new Set(t.selected))], o = 0;
- return a.map((e) => e && /* @__PURE__ */ (0, z.jsx)(aUe, {
+ let a = t.kind === "catalog" ? aUe(e, t.facets, n, r, i) : [oUe(e, t.tags, new Set(t.selected))], o = 0;
+ return a.map((e) => e && /* @__PURE__ */ (0, z.jsx)(sUe, {
title: e.title,
kind: e.kind,
active: e.active,
@@ -77224,11 +77276,11 @@ function nUe({ host: e, content: t, filters: n, latest: r }) {
children: e.body
}, e.title));
}
-function rUe(e, t, n, r, i) {
- let a = tUe(r), o = (t, r, i) => {
+function aUe(e, t, n, r, i) {
+ let a = rUe(r), o = (t, r, i) => {
if (!t.length) return null;
- let o = S7(n, r);
- return /* @__PURE__ */ (0, z.jsx)(T7, {
+ let o = x7(n, r);
+ return /* @__PURE__ */ (0, z.jsx)(w7, {
rows: t,
filterKey: r,
multi: i,
@@ -77238,7 +77290,7 @@ function rUe(e, t, n, r, i) {
});
}, s = (t, s, c, l, u, d) => {
if (!c.length) return null;
- let f = S7(n, l), p = c.some((e) => f.includes(e.value));
+ let f = x7(n, l), p = c.some((e) => f.includes(e.value));
if (!d) return {
title: t,
kind: s,
@@ -77250,12 +77302,12 @@ function rUe(e, t, n, r, i) {
title: t,
kind: s,
active: p,
- body: /* @__PURE__ */ (0, z.jsx)(sUe, {
+ body: /* @__PURE__ */ (0, z.jsx)(lUe, {
epoch: i,
title: t,
rows: c,
latest: m ?? null,
- limit: XHe[d],
+ limit: QHe[d],
filterKey: l,
selected: f,
counts: a,
@@ -77270,7 +77322,7 @@ function rUe(e, t, n, r, i) {
title: "时长",
kind: "meta",
active: !1,
- body: /* @__PURE__ */ (0, z.jsx)(cUe, {
+ body: /* @__PURE__ */ (0, z.jsx)(uUe, {
host: e,
filters: n
})
@@ -77284,7 +77336,7 @@ function rUe(e, t, n, r, i) {
title: "关注标签",
kind: "online",
active: !1,
- body: /* @__PURE__ */ (0, z.jsx)(E7, {
+ body: /* @__PURE__ */ (0, z.jsx)(T7, {
rows: t.followTags,
host: e,
selected: null,
@@ -77293,12 +77345,12 @@ function rUe(e, t, n, r, i) {
} : null
];
}
-function iUe(e, t, n) {
+function oUe(e, t, n) {
return t.length ? {
title: "内容标签",
kind: "online",
active: t.some((e) => n.has(e.value)),
- body: /* @__PURE__ */ (0, z.jsx)(E7, {
+ body: /* @__PURE__ */ (0, z.jsx)(T7, {
rows: t,
host: e,
selected: n,
@@ -77306,19 +77358,19 @@ function iUe(e, t, n) {
})
} : null;
}
-function C7(e, t) {
+function S7(e, t) {
let n = null;
try {
n = sessionStorage.getItem(`peach.sidebar.group.${e}`);
} catch {}
return n === null ? t : n === "open";
}
-function aUe({ title: e, kind: t, active: n, index: r, epoch: i, children: a }) {
- let o = (0, R.useRef)(null), s = (0, R.useRef)(null), [c, l] = (0, R.useState)(() => C7(e, n)), u = (0, R.useRef)(!1);
+function sUe({ title: e, kind: t, active: n, index: r, epoch: i, children: a }) {
+ let o = (0, R.useRef)(null), s = (0, R.useRef)(null), [c, l] = (0, R.useState)(() => S7(e, n)), u = (0, R.useRef)(!1);
(0, R.useLayoutEffect)(() => {
let t = o.current, r = s.current;
if (!t || !r) return;
- let i = u.current ? C7(e, n) : c;
+ let i = u.current ? S7(e, n) : c;
u.current = !0, t.open !== i && (t.open = i, r.inert = !i, r.style.height = "", r.classList.contains("fcollapse") && r.classList.toggle("fcollapse-settled", i), l(i));
}, [i]);
let d = (t) => {
@@ -77339,7 +77391,7 @@ function aUe({ title: e, kind: t, active: n, index: r, epoch: i, children: a })
"aria-expanded": c,
"aria-controls": f,
onClick: d,
- children: [/* @__PURE__ */ (0, z.jsx)(F5, { name: "chevron-right" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e })]
+ children: [/* @__PURE__ */ (0, z.jsx)(P5, { name: "chevron-right" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e })]
}), /* @__PURE__ */ (0, z.jsx)("div", {
ref: s,
"data-sidebar-collapse": "",
@@ -77350,7 +77402,7 @@ function aUe({ title: e, kind: t, active: n, index: r, epoch: i, children: a })
children: /* @__PURE__ */ (0, z.jsx)("div", {
"data-sidebar-body": "",
id: `sidebar-group-${encodeURIComponent(e)}`,
- children: /* @__PURE__ */ (0, z.jsx)(w7.Provider, {
+ children: /* @__PURE__ */ (0, z.jsx)(C7.Provider, {
value: d,
children: a
})
@@ -77359,15 +77411,15 @@ function aUe({ title: e, kind: t, active: n, index: r, epoch: i, children: a })
})]
});
}
-var w7 = (0, R.createContext)(() => {});
-function oUe({ dot: e }) {
- return e ? e.kind === "glyph" ? /* @__PURE__ */ (0, z.jsx)(F5, { name: e.name }) : e.kind === "image" ? /* @__PURE__ */ (0, z.jsx)("img", {
+var C7 = (0, R.createContext)(() => {});
+function cUe({ dot: e }) {
+ return e ? e.kind === "glyph" ? /* @__PURE__ */ (0, z.jsx)(P5, { name: e.name }) : e.kind === "image" ? /* @__PURE__ */ (0, z.jsx)("img", {
"data-sidebar-source-icon": "",
src: e.src,
alt: ""
}) : /* @__PURE__ */ (0, z.jsx)("i", { "data-sidebar-cost": e.cost }) : null;
}
-function T7({ rows: e, filterKey: t, multi: n, selected: r, counts: i, host: a }) {
+function w7({ rows: e, filterKey: t, multi: n, selected: r, counts: i, host: a }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-sidebar-chips": "",
children: e.map((e) => {
@@ -77384,7 +77436,7 @@ function T7({ rows: e, filterKey: t, multi: n, selected: r, counts: i, host: a }
title: e.offline,
onClick: () => a.toggleChip(t, e.value, n),
children: [
- /* @__PURE__ */ (0, z.jsx)(oUe, { dot: e.dot }),
+ /* @__PURE__ */ (0, z.jsx)(cUe, { dot: e.dot }),
/* @__PURE__ */ (0, z.jsx)("span", {
"data-sidebar-chip-label": "",
children: e.label
@@ -77399,8 +77451,8 @@ function T7({ rows: e, filterKey: t, multi: n, selected: r, counts: i, host: a }
})
});
}
-function sUe({ epoch: e, title: t, rows: n, latest: r, limit: i, filterKey: a, selected: o, counts: s, host: c, expandable: l }) {
- let u = (0, R.useContext)(w7), [d, f] = (0, R.useState)(null), [p, m] = (0, R.useState)(e);
+function lUe({ epoch: e, title: t, rows: n, latest: r, limit: i, filterKey: a, selected: o, counts: s, host: c, expandable: l }) {
+ let u = (0, R.useContext)(C7), [d, f] = (0, R.useState)(null), [p, m] = (0, R.useState)(e);
p !== e && (m(e), f(null));
let h = (0, R.useRef)(null), g = (0, R.useRef)(null), _ = !!d?.all, v = d ? d.rows : n;
return (0, R.useLayoutEffect)(() => {
@@ -77415,7 +77467,7 @@ function sUe({ epoch: e, title: t, rows: n, latest: r, limit: i, filterKey: a, s
e.body.classList.add("fcollapse"), T(e.body, e.before, () => !!t?.open && !e.body.inert);
}
t(), requestAnimationFrame(t);
- }, [d, _]), /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(T7, {
+ }, [d, _]), /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(w7, {
rows: _ ? v : v.slice(0, i),
filterKey: a,
multi: !1,
@@ -77440,10 +77492,10 @@ function sUe({ epoch: e, title: t, rows: n, latest: r, limit: i, filterKey: a, s
all: !_
}), _ && u());
},
- children: /* @__PURE__ */ (0, z.jsx)(F5, { name: "chevron-down" })
+ children: /* @__PURE__ */ (0, z.jsx)(P5, { name: "chevron-down" })
}) : null] });
}
-function E7({ rows: e, host: t, selected: n, badges: r }) {
+function T7({ rows: e, host: t, selected: n, badges: r }) {
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-sidebar-chips": "",
children: e.map((e) => /* @__PURE__ */ (0, z.jsxs)("button", {
@@ -77464,10 +77516,10 @@ function E7({ rows: e, host: t, selected: n, badges: r }) {
}, e.value))
});
}
-var D7 = (e, t) => e ? Math.min(g7, Number(e) / 60) : t;
-function cUe({ host: e, filters: t }) {
- let n = `${t.dur_min ?? ""}:${t.dur_max ?? ""}`, [r, i] = (0, R.useState)(n), [a, o] = (0, R.useState)(() => [D7(t.dur_min, 0), D7(t.dur_max, g7)]), [s, c] = (0, R.useState)("max");
- r !== n && (i(n), o([D7(t.dur_min, 0), D7(t.dur_max, g7)]));
+var E7 = (e, t) => e ? Math.min(h7, Number(e) / 60) : t;
+function uUe({ host: e, filters: t }) {
+ let n = `${t.dur_min ?? ""}:${t.dur_max ?? ""}`, [r, i] = (0, R.useState)(n), [a, o] = (0, R.useState)(() => [E7(t.dur_min, 0), E7(t.dur_max, h7)]), [s, c] = (0, R.useState)("max");
+ r !== n && (i(n), o([E7(t.dur_min, 0), E7(t.dur_max, h7)]));
let [l, u] = a, d = (0, R.useRef)(null), f = (0, R.useRef)(null), p = (0, R.useRef)(null), m = (0, R.useRef)(a);
m.current = a;
let h = (e, t) => {
@@ -77480,11 +77532,11 @@ function cUe({ host: e, filters: t }) {
}, [e]), (0, R.useLayoutEffect)(() => {
let e = d.current;
if (!e) return;
- e.style.setProperty("--lo", `${l / g7 * 100}%`), e.style.setProperty("--hi", `${u / g7 * 100}%`);
+ e.style.setProperty("--lo", `${l / h7 * 100}%`), e.style.setProperty("--hi", `${u / h7 * 100}%`);
let t = e.getBoundingClientRect();
e.querySelectorAll("[data-sidebar-range-tip]").forEach((e) => {
let n = e.dataset.rangeEnd === "max" ? u : l;
- e.style.left = `${n / g7 * 100}%`, e.style.setProperty("--range-tip-shift", "0px");
+ e.style.left = `${n / h7 * 100}%`, e.style.setProperty("--range-tip-shift", "0px");
let r = e.getBoundingClientRect(), i = r.right > t.right ? t.right - r.right : r.left < t.left ? t.left - r.left : 0;
i && e.style.setProperty("--range-tip-shift", `${Math.round(i)}px`);
});
@@ -77494,7 +77546,7 @@ function cUe({ host: e, filters: t }) {
"data-range-end": e,
"data-range-active": s === e ? "" : void 0,
"aria-hidden": "true",
- children: e === "max" && t >= g7 ? "不限" : `${t} 分钟`
+ children: e === "max" && t >= h7 ? "不限" : `${t} 分钟`
});
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-sidebar-duration": "",
@@ -77509,7 +77561,7 @@ function cUe({ host: e, filters: t }) {
id: "durMin",
type: "range",
min: "0",
- max: g7,
+ max: h7,
step: "5",
value: l,
"aria-label": "最短时长(分钟)",
@@ -77520,7 +77572,7 @@ function cUe({ host: e, filters: t }) {
id: "durMax",
type: "range",
min: "0",
- max: g7,
+ max: h7,
step: "5",
value: u,
"aria-label": "最长时长(分钟)",
@@ -77535,17 +77587,17 @@ function cUe({ host: e, filters: t }) {
}
//#endregion
//#region src/board-skeleton.ts
-var O7 = (e = "60%") => `<span class="skeleton" style="width:${e}"></span>`, lUe = () => `${O7("80%")}${O7("48%")}`, uUe = (e, t) => e.repeat(t);
-function dUe() {
- return `<div data-stage-grid="" aria-hidden="true"><div data-stage-media="" class="skeleton-detail-media skeleton"></div><aside data-stage-side=""><div data-stage-side-content="" class="skeleton-lines">${O7("85%")}${O7("65%")}${uUe(lUe(), 4)}</div></aside></div>`;
+var D7 = (e = "60%") => `<span class="skeleton" style="width:${e}"></span>`, dUe = () => `${D7("80%")}${D7("48%")}`, fUe = (e, t) => e.repeat(t);
+function pUe() {
+ return `<div data-stage-grid="" aria-hidden="true"><div data-stage-media="" class="skeleton-detail-media skeleton"></div><aside data-stage-side=""><div data-stage-side-content="" class="skeleton-lines">${D7("85%")}${D7("65%")}${fUe(dUe(), 4)}</div></aside></div>`;
}
//#endregion
//#region src/react/follow-detail/follow-detail.ts
-var k7 = (e) => ["follow-item", e], fUe = (e) => `/api/follow?item=${encodeURIComponent(e)}`, pUe = "/api/follow/save", mUe = "/api/follow/media/hide";
-async function A7(e, t) {
- let n = await W(fUe(e), t);
+var O7 = (e) => ["follow-item", e], mUe = (e) => `/api/follow?item=${encodeURIComponent(e)}`, hUe = "/api/follow/save", gUe = "/api/follow/media/hide";
+async function k7(e, t) {
+ let n = await W(mUe(e), t);
for (let t of n.groups || []) {
- let r = Yj(t).find((t) => t.id === e);
+ let r = SM(t).find((t) => t.id === e);
if (r) return {
item: r,
group: t,
@@ -77555,21 +77607,21 @@ async function A7(e, t) {
}
throw Error("这条关注内容已不存在");
}
-async function hUe(e, t) {
- let n = k7(e.id), r = Rde(e.id), i = X.getQueryData(Gj) ? null : X.fetchQuery({
- queryKey: Gj,
- queryFn: () => Kj(t)
+async function _Ue(e, t) {
+ let n = O7(e.id), r = dde(e.id), i = X.getQueryData(vM) ? null : X.fetchQuery({
+ queryKey: vM,
+ queryFn: () => yM(t)
});
r ? X.setQueryData(n, {
...r,
item: r.item
}) : await X.fetchQuery({
queryKey: n,
- queryFn: () => A7(e.id, t)
+ queryFn: () => k7(e.id, t)
}), await i;
}
-function gUe(e, t, n, r) {
- let i = e.media_items || [], a = r === "images" ? "image" : "video", o = i.find((e) => e.media_kind === a) || i[0], s = i.length ? i.find((e) => e.index === (n ?? o.index)) || o : null, c = i.filter((e) => e.media_kind === "image"), l = c.findIndex((e) => e.index === s?.index), u = c.length > 1 && l >= 0, d = i.length > 1 && !u, f = !i.length && t && eM(t).length > 1 ? t : null, p = s?.media_kind || e.media_kind || "", m = (u ? [...c, e] : [s, e]).filter((e) => !!e && (e.width || 0) > 0 && (e.height || 0) > 0);
+function vUe(e, t, n, r) {
+ let i = e.media_items || [], a = r === "images" ? "image" : "video", o = i.find((e) => e.media_kind === a) || i[0], s = i.length ? i.find((e) => e.index === (n ?? o.index)) || o : null, c = i.filter((e) => e.media_kind === "image"), l = c.findIndex((e) => e.index === s?.index), u = c.length > 1 && l >= 0, d = i.length > 1 && !u, f = !i.length && t && DM(t).length > 1 ? t : null, p = s?.media_kind || e.media_kind || "", m = (u ? [...c, e] : [s, e]).filter((e) => !!e && (e.width || 0) > 0 && (e.height || 0) > 0);
return {
embedded: i,
selected: s,
@@ -77583,32 +77635,32 @@ function gUe(e, t, n, r) {
src: e.playable ? `/follow-stream?id=${e.id}${s ? `&media=${s.index}` : ""}` : ""
};
}
-var _Ue = (e) => Yj(e).find((e) => (e.media_items || []).some((e) => e.resource_group)), vUe = {
+var yUe = (e) => SM(e).find((e) => (e.media_items || []).some((e) => e.resource_group)), bUe = {
"gofile.io": "Gofile",
"pixeldrain.com": "Pixeldrain",
"mega.nz": "MEGA",
"mega.io": "MEGA",
"mediafire.com": "MediaFire",
"drive.google.com": "Google Drive"
-}, yUe = {
+}, xUe = {
gofile: "Gofile",
pixeldrain: "Pixeldrain",
mega: "MEGA",
mediafire: "MediaFire",
google_drive: "Google Drive"
};
-function bUe(e) {
+function SUe(e) {
try {
let t = new URL(e).hostname.replace(/^www\./, "");
- return vUe[t] || t;
+ return bUe[t] || t;
} catch {
return "外部文件页";
}
}
-function j7(e, t) {
- return yUe[e?.resource_provider || ""] || t.provider_label || t.provider || "在线图片";
+function A7(e, t) {
+ return xUe[e?.resource_provider || ""] || t.provider_label || t.provider || "在线图片";
}
-function xUe(e, t, n = "") {
+function CUe(e, t, n = "") {
let r = n;
!r && e.is_release && (r = t.variant_label || t.variant_kind || ""), r ||= t.variant_kind === "wip" ? "WIP" : t.variant_label || t.variant_kind || "视频";
let i = e.is_release ? t.summary || (t.has_media ? "(仅附件)" : "(无正文)") : t.title;
@@ -77617,56 +77669,56 @@ function xUe(e, t, n = "") {
title: e.is_release && t.author ? `${t.author}:${i}` : i
};
}
-var SUe = (e) => String(e.name || "").trim(), M7 = (e, t) => e.tag_types?.[t] || "unknown", CUe = /* @__PURE__ */ new Set([
+var wUe = (e) => String(e.name || "").trim(), j7 = (e, t) => e.tag_types?.[t] || "unknown", TUe = /* @__PURE__ */ new Set([
"artist",
"character",
"copyright",
"metadata",
"unknown"
]);
-function wUe(e, t) {
- let n = M7(e, t);
- return `r34-${CUe.has(n) ? n : "general"}`;
+function EUe(e, t) {
+ let n = j7(e, t);
+ return `r34-${TUe.has(n) ? n : "general"}`;
}
-var N7 = [
+var M7 = [
"copyright",
"character",
"artist",
"general",
"metadata"
];
-function TUe(e, t) {
+function DUe(e, t) {
let n = e.detail_tags || e.tags || [], r = (t) => {
- let n = N7.indexOf(M7(e, t));
- return n < 0 ? N7.length : n;
+ let n = M7.indexOf(j7(e, t));
+ return n < 0 ? M7.length : n;
};
return [...n].sort((e, n) => r(e) - r(n) || t(e).localeCompare(t(n)));
}
-function EUe(e, t) {
+function OUe(e, t) {
let n = t.find((t) => t.id === e.source_id), r = t.filter((e) => n?.author_key && e.author_key === n.author_key);
return !r.length && n && r.push(n), r;
}
-var DUe = (e, t) => ({
+var kUe = (e, t) => ({
sources: e.sources,
aliases: e.aliases,
credentials: t
-}), P7 = (e) => e?.size ? { size: e.size } : {};
-function OUe(e, t) {
+}), N7 = (e) => e?.size ? { size: e.size } : {};
+function AUe(e, t) {
let { images: n, kind: r, src: i, selected: a } = t;
return n.length ? n.map((t, r) => ({
src: `/follow-stream?id=${e.id}&media=${t.index}`,
thumb: t.thumb_url || e.thumb_url || `/follow-stream?id=${e.id}&media=${t.index}`,
name: t.name || e.title,
- source: j7(t, e),
- ...P7(t),
+ source: A7(t, e),
+ ...N7(t),
position: r + 1,
total: n.length
})) : r === "image" && i ? [{
src: i,
thumb: e.thumb_url || i,
name: e.title,
- source: j7(a, e),
- ...P7(a),
+ source: A7(a, e),
+ ...N7(a),
position: 1,
total: 1
}] : e.thumb_url ? [{
@@ -77678,10 +77730,10 @@ function OUe(e, t) {
total: 1
}] : [];
}
-var kUe = (e) => e === "seen" ? "已标记看过" : "已更新关注状态";
+var jUe = (e) => e === "seen" ? "已标记看过" : "已更新关注状态";
//#endregion
//#region src/react/components/mix-queue.tsx
-function F7({ kind: e, title: t, summary: n, onClose: r, actions: i, listRef: a, children: o, ...s }) {
+function P7({ kind: e, title: t, summary: n, onClose: r, actions: i, listRef: a, children: o, ...s }) {
return /* @__PURE__ */ (0, z.jsxs)("aside", {
"data-mix-queue": "",
"data-queue-kind": e,
@@ -77709,7 +77761,7 @@ function F7({ kind: e, title: t, summary: n, onClose: r, actions: i, listRef: a,
})]
});
}
-function I7({ current: e, pic: t, lead: n, after: r, row: i, children: a, ...o }) {
+function F7({ current: e, pic: t, lead: n, after: r, row: i, children: a, ...o }) {
let s = /* @__PURE__ */ (0, z.jsx)("span", {
"data-mix-item-text": "",
children: a
@@ -77732,29 +77784,29 @@ function I7({ current: e, pic: t, lead: n, after: r, row: i, children: a, ...o }
}), r]
});
}
-var AUe = ({ label: e, count: t }) => /* @__PURE__ */ (0, z.jsxs)("h3", {
+var MUe = ({ label: e, count: t }) => /* @__PURE__ */ (0, z.jsxs)("h3", {
"data-mix-group-label": "",
children: [
e,
" ",
/* @__PURE__ */ (0, z.jsx)("span", { children: t })
]
-}), L7 = (e) => Number(e) > 0, jUe = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("span", {
+}), I7 = (e) => Number(e) > 0, NUe = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("span", {
className: "contents",
dangerouslySetInnerHTML: { __html: l(e) }
-}), R7 = l("external-link", "externalmark");
-function MUe(e) {
+}), L7 = l("external-link", "externalmark");
+function PUe(e) {
let { id: t, actions: n } = e, r = $n({
- queryKey: k7(t),
- queryFn: ({ signal: e }) => A7(t, e)
+ queryKey: O7(t),
+ queryFn: ({ signal: e }) => k7(t, e)
}), i = $n({
- queryKey: Gj,
- queryFn: ({ signal: e }) => Kj(e)
+ queryKey: vM,
+ queryFn: ({ signal: e }) => yM(e)
}), a = (0, R.useMemo)(() => new Set((i.data?.providers || []).filter((e) => e.present).map((e) => e.provider)), [i.data]), [o, s] = (0, R.useState)(e.mediaIndex);
- return r.data ? /* @__PURE__ */ (0, z.jsx)(NUe, {
+ return r.data ? /* @__PURE__ */ (0, z.jsx)(FUe, {
...e,
data: r.data,
- context: DUe(r.data, a),
+ context: kUe(r.data, a),
mediaIndex: o,
onMedia: s
}) : /* @__PURE__ */ (0, z.jsx)("div", {
@@ -77763,9 +77815,9 @@ function MUe(e) {
children: /* @__PURE__ */ (0, z.jsxs)("div", {
"data-stage-media": "",
"data-follow-detail-media": "none",
- children: [/* @__PURE__ */ (0, z.jsx)(z7, { onClose: n.close }), /* @__PURE__ */ (0, z.jsx)("div", {
+ children: [/* @__PURE__ */ (0, z.jsx)(R7, { onClose: n.close }), /* @__PURE__ */ (0, z.jsx)("div", {
"data-follow-detail-placeholder": "",
- children: r.isError ? /* @__PURE__ */ (0, z.jsx)(vb, {
+ children: r.isError ? /* @__PURE__ */ (0, z.jsx)(sb, {
message: m(r.error),
onRetry: () => void r.refetch()
}) : null
@@ -77773,7 +77825,7 @@ function MUe(e) {
})
});
}
-var z7 = ({ onClose: e }) => /* @__PURE__ */ (0, z.jsx)("button", {
+var R7 = ({ onClose: e }) => /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-stage-close": "",
id: "closeStage",
@@ -77782,8 +77834,8 @@ var z7 = ({ onClose: e }) => /* @__PURE__ */ (0, z.jsx)("button", {
onClick: e,
dangerouslySetInnerHTML: { __html: l("x") }
});
-function NUe({ data: e, context: t, mediaIndex: n, onMedia: r, mediaView: i, helpers: a, actions: o }) {
- let { item: s, group: c } = e, l = gUe(s, c, n, i), u = LUe(s, o, r), d = `${s.id}:${l.selected?.index ?? ""}`, [f, p] = (0, R.useState)({
+function FUe({ data: e, context: t, mediaIndex: n, onMedia: r, mediaView: i, helpers: a, actions: o }) {
+ let { item: s, group: c } = e, l = vUe(s, c, n, i), u = zUe(s, o, r), d = `${s.id}:${l.selected?.index ?? ""}`, [f, p] = (0, R.useState)({
key: "",
kind: ""
}), m = {
@@ -77803,20 +77855,20 @@ function NUe({ data: e, context: t, mediaIndex: n, onMedia: r, mediaView: i, hel
s,
l.kind
]);
- let h = !l.embedded.length && l.collection ? _Ue(l.collection) : void 0, g = l.embeddedQueue ? /* @__PURE__ */ (0, z.jsx)(U7, {
+ let h = !l.embedded.length && l.collection ? yUe(l.collection) : void 0, g = l.embeddedQueue ? /* @__PURE__ */ (0, z.jsx)(H7, {
item: s,
current: l.selected.index,
helpers: a,
actions: o,
onMedia: r
- }) : l.collection ? h ? /* @__PURE__ */ (0, z.jsx)(U7, {
+ }) : l.collection ? h ? /* @__PURE__ */ (0, z.jsx)(H7, {
item: h,
current: null,
helpers: a,
actions: o,
onMedia: r,
currentId: s.id
- }) : /* @__PURE__ */ (0, z.jsx)(FUe, {
+ }) : /* @__PURE__ */ (0, z.jsx)(LUe, {
group: l.collection,
itemId: s.id,
helpers: a,
@@ -77827,7 +77879,7 @@ function NUe({ data: e, context: t, mediaIndex: n, onMedia: r, mediaView: i, hel
"data-with-queue": g ? "" : void 0,
"data-follow-detail": "",
children: [
- /* @__PURE__ */ (0, z.jsx)(PUe, {
+ /* @__PURE__ */ (0, z.jsx)(IUe, {
item: s,
media: l,
helpers: a,
@@ -77836,7 +77888,7 @@ function NUe({ data: e, context: t, mediaIndex: n, onMedia: r, mediaView: i, hel
issues: m
}, d),
g,
- /* @__PURE__ */ (0, z.jsx)(IUe, {
+ /* @__PURE__ */ (0, z.jsx)(RUe, {
item: s,
data: e,
context: t,
@@ -77849,8 +77901,8 @@ function NUe({ data: e, context: t, mediaIndex: n, onMedia: r, mediaView: i, hel
]
});
}
-function PUe({ item: e, media: t, helpers: n, actions: r, onMedia: i, issues: a }) {
- let { kind: o, selected: s, src: c, images: u, position: d, carousel: f, frameRatio: p } = t, m = (0, R.useRef)(null), [h, g] = (0, R.useState)(null), _ = OUe(e, t), v = s?.thumb_url || e.thumb_url || "", y = e.playable && o === "video", b = e.playable && o === "image" ? c : e.thumb_url || "", x = e.playable && o === "image" && v && v !== c ? v : "", [S, C] = (0, R.useState)(b), w = (0, R.useRef)({
+function IUe({ item: e, media: t, helpers: n, actions: r, onMedia: i, issues: a }) {
+ let { kind: o, selected: s, src: c, images: u, position: d, carousel: f, frameRatio: p } = t, m = (0, R.useRef)(null), [h, g] = (0, R.useState)(null), _ = AUe(e, t), v = s?.thumb_url || e.thumb_url || "", y = e.playable && o === "video", b = e.playable && o === "image" ? c : e.thumb_url || "", x = e.playable && o === "image" && v && v !== c ? v : "", [S, C] = (0, R.useState)(b), w = (0, R.useRef)({
item: e,
selected: s
}), T = (0, R.useRef)(a.failed);
@@ -77880,14 +77932,14 @@ function PUe({ item: e, media: t, helpers: n, actions: r, onMedia: i, issues: a
"--follow-image-arrow-inset": h === null ? void 0 : `${h}px`
},
children: [
- /* @__PURE__ */ (0, z.jsx)(z7, { onClose: r.close }),
+ /* @__PURE__ */ (0, z.jsx)(R7, { onClose: r.close }),
y ? null : b ? /* @__PURE__ */ (0, z.jsx)("img", {
"data-follow-detail-poster": "",
"data-zoomable": _.length ? "" : void 0,
src: S,
alt: e.title,
referrerPolicy: "no-referrer",
- onClick: _.length ? () => void aA(Math.max(0, d), _) : void 0,
+ onClick: _.length ? () => void NA(Math.max(0, d), _) : void 0,
onError: () => {
if (x && S !== x) {
C(x), a.thumbFallback();
@@ -77899,7 +77951,7 @@ function PUe({ item: e, media: t, helpers: n, actions: r, onMedia: i, issues: a
"data-follow-detail-placeholder": "",
children: [/* @__PURE__ */ (0, z.jsx)("span", {
className: "contents",
- dangerouslySetInnerHTML: { __html: oM(e.resource_provider || e.provider) }
+ dangerouslySetInnerHTML: { __html: NM(e.resource_provider || e.provider) }
}), /* @__PURE__ */ (0, z.jsx)("span", { children: "没有可用预览" })]
}),
f ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
@@ -77938,11 +77990,11 @@ function PUe({ item: e, media: t, helpers: n, actions: r, onMedia: i, issues: a
]
});
}
-var B7 = ({ kind: e }) => /* @__PURE__ */ (0, z.jsx)("span", {
+var z7 = ({ kind: e }) => /* @__PURE__ */ (0, z.jsx)("span", {
"data-follow-nothumb": "",
dangerouslySetInnerHTML: { __html: l(e === "image" ? "image-off" : "play") }
});
-function V7({ src: e }) {
+function B7({ src: e }) {
let [t, n] = (0, R.useState)(!1);
return t ? null : /* @__PURE__ */ (0, z.jsx)("img", {
src: e,
@@ -77952,14 +78004,14 @@ function V7({ src: e }) {
onError: () => n(!0)
});
}
-function H7(e) {
+function V7(e) {
return (0, R.useCallback)((t) => {
t && e.wireDrag(t);
}, [e]);
}
-function FUe({ group: e, itemId: t, helpers: n, actions: r }) {
- let i = eM(e), a = H7(n);
- return /* @__PURE__ */ (0, z.jsx)(F7, {
+function LUe({ group: e, itemId: t, helpers: n, actions: r }) {
+ let i = DM(e), a = V7(n);
+ return /* @__PURE__ */ (0, z.jsx)(P7, {
kind: "collection",
"data-follow-queue": "",
title: "视频合集",
@@ -77967,12 +78019,12 @@ function FUe({ group: e, itemId: t, helpers: n, actions: r }) {
listRef: a,
summary: `${e.primary.title || "未命名合集"} · ${i.length} 个视频`,
children: i.map((n) => {
- let i = e.duplicates.includes(n), a = xUe(e, n, i ? n.provider_label : ""), s = i ? oM(n.provider, n.provider_label) : "";
- return /* @__PURE__ */ (0, z.jsxs)(I7, {
+ let i = e.duplicates.includes(n), a = CUe(e, n, i ? n.provider_label : ""), s = i ? NM(n.provider, n.provider_label) : "";
+ return /* @__PURE__ */ (0, z.jsxs)(F7, {
current: n.id === t,
"data-follow-queue-item": n.id,
onClick: () => r.openItem(n.id),
- pic: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [n.thumb_url ? /* @__PURE__ */ (0, z.jsx)(V7, { src: n.thumb_url }) : /* @__PURE__ */ (0, z.jsx)(B7, { kind: "video" }), L7(n.duration) ? /* @__PURE__ */ (0, z.jsx)("i", {
+ pic: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [n.thumb_url ? /* @__PURE__ */ (0, z.jsx)(B7, { src: n.thumb_url }) : /* @__PURE__ */ (0, z.jsx)(z7, { kind: "video" }), I7(n.duration) ? /* @__PURE__ */ (0, z.jsx)("i", {
className: "mono",
"data-mix-item-duration": "",
children: o(n.duration)
@@ -77990,15 +78042,15 @@ function FUe({ group: e, itemId: t, helpers: n, actions: r }) {
children: a.label
}), /* @__PURE__ */ (0, z.jsx)("time", {
dateTime: n.published_at || "",
- children: pM(n)
+ children: BM(n)
})]
})]
}, n.id);
})
});
}
-function U7({ item: e, current: t, currentId: n = e.id, helpers: r, actions: i, onMedia: a }) {
- let o = e.media_items || [], s = H7(r), c = [];
+function H7({ item: e, current: t, currentId: n = e.id, helpers: r, actions: i, onMedia: a }) {
+ let o = e.media_items || [], s = V7(r), c = [];
o.forEach((e) => {
let t = e.resource_group || "ungrouped", n = c.find((e) => e.key === t);
n || (n = {
@@ -78008,26 +78060,26 @@ function U7({ item: e, current: t, currentId: n = e.id, helpers: r, actions: i,
}, c.push(n)), n.items.push(e);
});
let l = (t) => e.id === n ? a(t.index) : i.openItem(e.id, t.index);
- return /* @__PURE__ */ (0, z.jsx)(F7, {
+ return /* @__PURE__ */ (0, z.jsx)(P7, {
kind: "media",
"data-follow-queue": "",
title: "多媒体",
onClose: i.close,
listRef: s,
summary: `${e.title || "未命名内容"} · ${o.length} 个媒体`,
- children: c.map((n) => [n.label ? /* @__PURE__ */ (0, z.jsx)(AUe, {
+ children: c.map((n) => [n.label ? /* @__PURE__ */ (0, z.jsx)(MUe, {
label: n.label,
count: n.items.length
- }, `label:${n.key}`) : null, ...n.items.map((n) => /* @__PURE__ */ (0, z.jsxs)(I7, {
+ }, `label:${n.key}`) : null, ...n.items.map((n) => /* @__PURE__ */ (0, z.jsxs)(F7, {
current: n.index === t,
"data-follow-media-owner": e.id,
"data-follow-media-item": n.index,
"data-media-kind": n.media_kind || "",
onClick: () => l(n),
- pic: n.thumb_url ? /* @__PURE__ */ (0, z.jsx)(V7, { src: n.thumb_url }) : /* @__PURE__ */ (0, z.jsx)(B7, { kind: n.media_kind || "" }),
+ pic: n.thumb_url ? /* @__PURE__ */ (0, z.jsx)(B7, { src: n.thumb_url }) : /* @__PURE__ */ (0, z.jsx)(z7, { kind: n.media_kind || "" }),
children: [/* @__PURE__ */ (0, z.jsx)("b", {
"data-middle-truncate": "",
- children: SUe(n)
+ children: wUe(n)
}), /* @__PURE__ */ (0, z.jsx)("span", {
"data-truncate-end": "",
children: n.media_kind === "image" ? "图片" : "视频"
@@ -78035,13 +78087,13 @@ function U7({ item: e, current: t, currentId: n = e.id, helpers: r, actions: i,
}, n.index))])
});
}
-function IUe({ item: e, data: t, context: n, media: r, write: a, issue: s, helpers: u, actions: d }) {
+function RUe({ item: e, data: t, context: n, media: r, write: a, issue: s, helpers: u, actions: d }) {
let { kind: f, selected: p, src: m } = r, h = {
primary: e,
variants: [],
duplicates: [],
has_wip: e.variant_kind === "wip"
- }, g = dM(h, e), _ = lM(e, EUe(e, t.sources), n), v = _.credited ? "" : e.author && c(e.author) !== c(_.author) ? e.author : "", y = fM(e, n), b = TUe(e, u.tagLabel), x = e.status === "saved", { busy: S } = a, C = (e) => S.has(e) ? {
+ }, g = RM(h, e), _ = IM(e, OUe(e, t.sources), n), v = _.credited ? "" : e.author && c(e.author) !== c(_.author) ? e.author : "", y = zM(e, n), b = DUe(e, u.tagLabel), x = e.status === "saved", { busy: S } = a, C = (e) => S.has(e) ? {
"aria-busy": !0,
"aria-disabled": !0
} : {};
@@ -78057,7 +78109,7 @@ function IUe({ item: e, data: t, context: n, media: r, write: a, issue: s, helpe
"data-stage-title": "",
"data-follow-detail-name": "",
"data-reveal-line": "",
- dangerouslySetInnerHTML: { __html: uM(h, e) + i(e.title) }
+ dangerouslySetInnerHTML: { __html: LM(h, e) + i(e.title) }
}), e.url ? /* @__PURE__ */ (0, z.jsx)("a", {
"data-follow-origin": "",
href: e.url,
@@ -78065,7 +78117,7 @@ function IUe({ item: e, data: t, context: n, media: r, write: a, issue: s, helpe
rel: "noreferrer noopener",
title: "打开来源页面",
"aria-label": "打开来源页面",
- dangerouslySetInnerHTML: { __html: R7 }
+ dangerouslySetInnerHTML: { __html: L7 }
}) : null]
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
@@ -78084,8 +78136,8 @@ function IUe({ item: e, data: t, context: n, media: r, write: a, issue: s, helpe
"data-stage-meta": "",
"data-reveal-line": "",
children: [
- /* @__PURE__ */ (0, z.jsx)("span", { children: pM(e) }),
- L7(e.duration) ? /* @__PURE__ */ (0, z.jsx)("span", { children: o(e.duration) }) : null,
+ /* @__PURE__ */ (0, z.jsx)("span", { children: BM(e) }),
+ I7(e.duration) ? /* @__PURE__ */ (0, z.jsx)("span", { children: o(e.duration) }) : null,
g ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-follow-badges": "",
dangerouslySetInnerHTML: { __html: g }
@@ -78118,9 +78170,9 @@ function IUe({ item: e, data: t, context: n, media: r, write: a, issue: s, helpe
href: e,
target: "_blank",
rel: "noreferrer noopener",
- children: [bUe(e), /* @__PURE__ */ (0, z.jsx)("span", {
+ children: [SUe(e), /* @__PURE__ */ (0, z.jsx)("span", {
className: "contents",
- dangerouslySetInnerHTML: { __html: R7 }
+ dangerouslySetInnerHTML: { __html: L7 }
})]
}, e))
}) : null,
@@ -78227,7 +78279,7 @@ function IUe({ item: e, data: t, context: n, media: r, write: a, issue: s, helpe
"aria-label": `恢复显示 ${e.name || ""}`,
...C(`restore:${e.index}`),
onClick: () => a.restore(e.index),
- children: [e.thumb_url ? /* @__PURE__ */ (0, z.jsx)(V7, { src: e.thumb_url }) : /* @__PURE__ */ (0, z.jsx)(jUe, { name: "image-off" }), /* @__PURE__ */ (0, z.jsx)("i", { dangerouslySetInnerHTML: { __html: l("rotate-ccw") } })]
+ children: [e.thumb_url ? /* @__PURE__ */ (0, z.jsx)(B7, { src: e.thumb_url }) : /* @__PURE__ */ (0, z.jsx)(NUe, { name: "image-off" }), /* @__PURE__ */ (0, z.jsx)("i", { dangerouslySetInnerHTML: { __html: l("rotate-ccw") } })]
}, e.index))
})]
}) : null,
@@ -78241,7 +78293,7 @@ function IUe({ item: e, data: t, context: n, media: r, write: a, issue: s, helpe
"data-follow-detail-tags": "",
children: b.map((t) => /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
- "data-tag-cat": wUe(e, t),
+ "data-tag-cat": EUe(e, t),
"data-follow-tag": t,
onClick: () => d.openTag(t),
children: u.tagLabel(t)
@@ -78251,8 +78303,8 @@ function IUe({ item: e, data: t, context: n, media: r, write: a, issue: s, helpe
})
});
}
-function LUe(e, t, n) {
- let r = e.id, i = k7(r), [a, o] = (0, R.useState)(() => /* @__PURE__ */ new Set()), [s, c] = (0, R.useState)(""), l = (e, t) => o((n) => {
+function zUe(e, t, n) {
+ let r = e.id, i = O7(r), [a, o] = (0, R.useState)(() => /* @__PURE__ */ new Set()), [s, c] = (0, R.useState)(""), l = (e, t) => o((n) => {
let r = new Set(n);
return t ? r.add(e) : r.delete(e), r;
}), u = (e) => {
@@ -78262,17 +78314,17 @@ function LUe(e, t, n) {
...t.item,
status: e
}
- }), Bde(r, e);
+ }), pde(r, e);
}, d = (e) => {
c(m(e) || "操作失败"), t.failure("更新关注状态", e);
}, f = er({
- mutationFn: ({ to: e }) => G(aj, {
+ mutationFn: ({ to: e }) => G(Mj, {
item: r,
to: e
}),
onSuccess: (e, { to: n, was: i }) => {
- u(n), c(""), n === "ignored" && cF(), t.toast(kUe(n), { undo: i === "saved" ? void 0 : async () => {
- await G(aj, {
+ u(n), c(""), n === "ignored" && lF(), t.toast(jUe(n), { undo: i === "saved" ? void 0 : async () => {
+ await G(Mj, {
item: r,
to: i
}), u(i);
@@ -78281,7 +78333,7 @@ function LUe(e, t, n) {
onError: d,
onSettled: (e, t, { to: n }) => l(n, !1)
}), p = er({
- mutationFn: () => G(pUe, { item: r }),
+ mutationFn: () => G(hUe, { item: r }),
onSuccess: () => {
u("saved"), c(""), t.toast("已保存到账本");
},
@@ -78289,7 +78341,7 @@ function LUe(e, t, n) {
onSettled: () => l("save", !1)
}), h = er({
mutationFn: async ({ index: e, hidden: t }) => {
- await G(mUe, {
+ await G(gUe, {
item: r,
media: e,
hidden: t
@@ -78300,17 +78352,17 @@ function LUe(e, t, n) {
},
onSuccess: (e, { hidden: r, next: a }) => {
let o = X.getQueryData(i);
- o && zde(o.item), n(a), c(""), t.toast(r ? "已隐藏这张图" : "已恢复显示");
+ o && fde(o.item), n(a), c(""), t.toast(r ? "已隐藏这张图" : "已恢复显示");
},
onError: d,
onSettled: (e, t, { index: n, hidden: r }) => l(`${r ? "hide" : "restore"}:${n}`, !1)
}), g = $n({
- queryKey: Lme(r),
- queryFn: ({ signal: e }) => Bme(r, e)
+ queryKey: Ime(r),
+ queryFn: ({ signal: e }) => zme(r, e)
}).data?.want ?? null, _ = er({
- mutationFn: async (e) => (e ? await sF([e.id]) : await oF({ follow: r }), !e),
+ mutationFn: async (e) => (e ? await cF([e.id]) : await sF({ follow: r }), !e),
onSuccess: (e) => {
- c(""), t.toast(e ? "已加入想要" : "已取消想要"), cF();
+ c(""), t.toast(e ? "已加入想要" : "已取消想要"), lF();
},
onError: d,
onSettled: () => l("want", !1)
@@ -78350,23 +78402,23 @@ function LUe(e, t, n) {
}
//#endregion
//#region src/react/components/overlay-host.ts
-function RUe(e) {
+function BUe(e) {
let t = e.querySelector(":scope > [data-react-overlays]");
if (t) return t;
let n = e.ownerDocument.createElement("div");
return n.className = "peach-react", n.dataset.reactOverlays = "", e.append(n), n;
}
-function zUe(e) {
+function VUe(e) {
let t = e?.ownerDocument ?? globalThis.document, n = e?.closest("dialog[open]");
- return RUe(n ?? t.body);
+ return BUe(n ?? t.body);
}
//#endregion
//#region src/react/cover-crop/cover-crop.ts
-var BUe = "/api/cover-crop", VUe = (e, t) => G(BUe, {
+var HUe = "/api/cover-crop", UUe = (e, t) => G(HUe, {
code: e,
box: t
-}), W7 = .704;
-function G7({ className: e }) {
+}), U7 = .704;
+function W7({ className: e }) {
return /* @__PURE__ */ (0, z.jsx)("svg", {
"aria-hidden": !0,
viewBox: "0 0 24 24",
@@ -78379,7 +78431,7 @@ function G7({ className: e }) {
children: /* @__PURE__ */ (0, z.jsx)("use", { href: "#i-crop" })
});
}
-function HUe({ code: e, coverUrl: t, box: n, onSaved: r }) {
+function WUe({ code: e, coverUrl: t, box: n, onSaved: r }) {
let [i, a] = (0, R.useState)(!1), o = (0, R.useRef)(null);
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("button", {
ref: o,
@@ -78390,15 +78442,15 @@ function HUe({ code: e, coverUrl: t, box: n, onSaved: r }) {
title: "裁剪封面:框出正封那一块",
onClick: () => a(!0),
className: "flex size-7 cursor-pointer items-center justify-center rounded-lg text-foreground-icon-secondary outline-none transition-colors hover:bg-background-primary-hover hover:text-foreground-icon-primary focus-visible:ring-2 focus-visible:ring-border-focus-ring",
- children: /* @__PURE__ */ (0, z.jsx)(G7, { className: "size-3.75" })
+ children: /* @__PURE__ */ (0, z.jsx)(W7, { className: "size-3.75" })
}), /* @__PURE__ */ (0, z.jsx)(Oh, {
- getContainer: () => zUe(o.current),
- children: /* @__PURE__ */ (0, z.jsx)(EA, {
+ getContainer: () => VUe(o.current),
+ children: /* @__PURE__ */ (0, z.jsx)(tj, {
isOpen: i,
onOpenChange: a,
width: "cover-crop",
label: "裁剪封面",
- children: /* @__PURE__ */ (0, z.jsx)(UUe, {
+ children: /* @__PURE__ */ (0, z.jsx)(GUe, {
code: e,
coverUrl: t,
box: n,
@@ -78408,9 +78460,9 @@ function HUe({ code: e, coverUrl: t, box: n, onSaved: r }) {
})
})] });
}
-function UUe({ code: e, coverUrl: t, box: n, onSaved: r, close: i }) {
- let [a, o] = (0, R.useState)(null), [s, c] = (0, R.useState)(null), [l, u] = (0, R.useState)(!0), d = uO(), f = er({
- mutationFn: (t) => VUe(e, t),
+function GUe({ code: e, coverUrl: t, box: n, onSaved: r, close: i }) {
+ let [a, o] = (0, R.useState)(null), [s, c] = (0, R.useState)(null), [l, u] = (0, R.useState)(!0), d = aO(), f = er({
+ mutationFn: (t) => UUe(e, t),
onSuccess: () => {
i(), r();
}
@@ -78422,15 +78474,15 @@ function UUe({ code: e, coverUrl: t, box: n, onSaved: r, close: i }) {
y0: n.y0,
x1: n.x1,
y1: n.y1
- } : hA(e, W7);
- c(_A(t, e, null));
+ } : Ole(e, U7);
+ c(ZA(t, e, null));
}
let m = f.isPending;
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex shrink-0 items-start gap-4 p-5",
children: [
- /* @__PURE__ */ (0, z.jsx)(DA, { children: /* @__PURE__ */ (0, z.jsx)(G7, { className: "size-6" }) }),
+ /* @__PURE__ */ (0, z.jsx)(nj, { children: /* @__PURE__ */ (0, z.jsx)(W7, { className: "size-6" }) }),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex min-w-0 flex-1 flex-col gap-2",
children: [
@@ -78449,7 +78501,7 @@ function UUe({ code: e, coverUrl: t, box: n, onSaved: r, close: i }) {
}) : null
]
}),
- /* @__PURE__ */ (0, z.jsx)(fO, {
+ /* @__PURE__ */ (0, z.jsx)(sO, {
icon: Xe,
size: "small",
"aria-label": "关闭",
@@ -78460,24 +78512,24 @@ function UUe({ code: e, coverUrl: t, box: n, onSaved: r, close: i }) {
/* @__PURE__ */ (0, z.jsx)("div", {
ref: d,
className: "flex min-h-0 flex-1 flex-col items-center gap-4 overflow-y-auto border-t border-separator-border px-5 py-4",
- children: /* @__PURE__ */ (0, z.jsx)(AA, {
+ children: /* @__PURE__ */ (0, z.jsx)(ij, {
src: t,
- aspect: l ? W7 : null,
+ aspect: l ? U7 : null,
box: s,
size: a,
label: `${e} 的正封取景框`,
onSize: (e) => {
- pA(e) && p(e);
+ YA(e) && p(e);
},
onBox: c
})
}),
/* @__PURE__ */ (0, z.jsxs)("div", {
className: "flex shrink-0 flex-wrap items-center gap-3 border-t border-separator-border p-5",
- children: [/* @__PURE__ */ (0, z.jsx)(GN, {
+ children: [/* @__PURE__ */ (0, z.jsx)(KN, {
isSelected: l,
onChange: (e) => {
- u(e), e && s && a && c(_A(s, a, W7));
+ u(e), e && s && a && c(ZA(s, a, U7));
},
children: /* @__PURE__ */ (0, z.jsx)("span", {
className: "text-body-2-regular text-text-secondary",
@@ -78506,21 +78558,21 @@ function UUe({ code: e, coverUrl: t, box: n, onSaved: r, close: i }) {
}
//#endregion
//#region src/react/item-detail/item-detail-page.tsx
-var K7 = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("span", {
+var G7 = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("span", {
className: "contents",
dangerouslySetInnerHTML: { __html: l(e) }
-}), q7 = ({ html: e }) => /* @__PURE__ */ (0, z.jsx)("span", {
+}), K7 = ({ html: e }) => /* @__PURE__ */ (0, z.jsx)("span", {
className: "contents",
dangerouslySetInnerHTML: { __html: e }
});
-function WUe(e) {
+function KUe(e) {
let { queue: t, actions: n } = e, r = $n({
- queryKey: t ? g8(t) : ["item-queue", "none"],
- queryFn: ({ signal: n }) => T8(t, e.helpers, n),
+ queryKey: t ? h8(t) : ["item-queue", "none"],
+ queryFn: ({ signal: n }) => w8(t, e.helpers, n),
enabled: !!t
- }), i = t && r.data || null, a = i ? O8(i, e.id) : t ? null : e.id, o = $n({
- queryKey: h8(a ?? 0),
- queryFn: ({ signal: e }) => w8(a, e),
+ }), i = t && r.data || null, a = i ? D8(i, e.id) : t ? null : e.id, o = $n({
+ queryKey: m8(a ?? 0),
+ queryFn: ({ signal: e }) => C8(a, e),
enabled: a != null
});
if (!o.data || t && !i) {
@@ -78531,9 +78583,9 @@ function WUe(e) {
children: /* @__PURE__ */ (0, z.jsxs)("div", {
"data-stage-media": "",
"data-item-media": "none",
- children: [/* @__PURE__ */ (0, z.jsx)(J7, { onClose: n.close }), /* @__PURE__ */ (0, z.jsx)("div", {
+ children: [/* @__PURE__ */ (0, z.jsx)(q7, { onClose: n.close }), /* @__PURE__ */ (0, z.jsx)("div", {
"data-item-placeholder": "",
- children: e ? /* @__PURE__ */ (0, z.jsx)(vb, {
+ children: e ? /* @__PURE__ */ (0, z.jsx)(sb, {
message: m(e),
onRetry: () => {
r.error && r.refetch(), o.error && o.refetch();
@@ -78543,13 +78595,13 @@ function WUe(e) {
})
});
}
- return /* @__PURE__ */ (0, z.jsx)(GUe, {
+ return /* @__PURE__ */ (0, z.jsx)(qUe, {
...e,
- item: sVe(o.data, i),
+ item: lVe(o.data, i),
queue: i
}, o.data.id);
}
-var J7 = ({ onClose: e }) => /* @__PURE__ */ (0, z.jsx)("button", {
+var q7 = ({ onClose: e }) => /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-stage-close": "",
id: "closeStage",
@@ -78558,36 +78610,36 @@ var J7 = ({ onClose: e }) => /* @__PURE__ */ (0, z.jsx)("button", {
onClick: e,
dangerouslySetInnerHTML: { __html: l("x") }
});
-function GUe(e) {
- let { item: t, queue: n, actions: r, helpers: i } = e, a = sWe(t, r, e.grid.cache, i.tagLabel), o = (0, R.useRef)(t);
+function qUe(e) {
+ let { item: t, queue: n, actions: r, helpers: i } = e, a = lWe(t, r, e.grid.cache, i.tagLabel), o = (0, R.useRef)(t);
(0, R.useLayoutEffect)(() => {
r.present(o.current, n);
}, [r]), (0, R.useEffect)(() => {
- n?.kind === "playlist" && G(_8, {
+ n?.kind === "playlist" && G(g8, {
action: "progress",
id: n.playlistId,
asset_id: t.id
}).catch(() => {});
}, []);
- let s = xVe(t, i.sourceOffline(t.location || ""));
+ let s = CVe(t, i.sourceOffline(t.location || ""));
return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsxs)("div", {
"data-stage-grid": "",
"data-with-queue": n ? "" : void 0,
"data-item-detail": "",
children: [
- /* @__PURE__ */ (0, z.jsx)(KUe, {
+ /* @__PURE__ */ (0, z.jsx)(JUe, {
item: t,
gate: s,
helpers: i,
actions: r
}),
- n ? /* @__PURE__ */ (0, z.jsx)(JUe, {
+ n ? /* @__PURE__ */ (0, z.jsx)(XUe, {
queue: n,
itemId: t.id,
helpers: i,
actions: r
}) : null,
- /* @__PURE__ */ (0, z.jsx)(ZUe, {
+ /* @__PURE__ */ (0, z.jsx)($Ue, {
item: t,
queue: n,
write: a,
@@ -78595,9 +78647,9 @@ function GUe(e) {
actions: r
})
]
- }), !n && e.relatedLimit > 0 ? /* @__PURE__ */ (0, z.jsx)(oWe, { ...e }) : null] });
+ }), !n && e.relatedLimit > 0 ? /* @__PURE__ */ (0, z.jsx)(cWe, { ...e }) : null] });
}
-function KUe({ item: e, gate: t, helpers: n, actions: r }) {
+function JUe({ item: e, gate: t, helpers: n, actions: r }) {
let [i, a] = (0, R.useState)(t ? "" : "auto"), o = (0, R.useRef)(null), c = (0, R.useRef)(e);
(0, R.useLayoutEffect)(() => {
let e = o.current;
@@ -78608,7 +78660,7 @@ function KUe({ item: e, gate: t, helpers: n, actions: r }) {
ref: o,
"data-stage-media": "",
"data-item-media": t || "video",
- children: [/* @__PURE__ */ (0, z.jsx)(J7, { onClose: r.close }), t === "offline" ? /* @__PURE__ */ (0, z.jsx)(qUe, {
+ children: [/* @__PURE__ */ (0, z.jsx)(q7, { onClose: r.close }), t === "offline" ? /* @__PURE__ */ (0, z.jsx)(YUe, {
item: e,
badge: l,
helpers: n,
@@ -78618,7 +78670,7 @@ function KUe({ item: e, gate: t, helpers: n, actions: r }) {
role: "status",
"data-item-gate": "online",
children: [
- /* @__PURE__ */ (0, z.jsx)(q7, { html: l }),
+ /* @__PURE__ */ (0, z.jsx)(K7, { html: l }),
/* @__PURE__ */ (0, z.jsx)("b", { children: "在线资产" }),
/* @__PURE__ */ (0, z.jsx)("span", { children: "这条没有对应的关注条目,媒体地址无从解析。" }),
/* @__PURE__ */ (0, z.jsx)("button", {
@@ -78633,11 +78685,11 @@ function KUe({ item: e, gate: t, helpers: n, actions: r }) {
id: "gate",
"data-item-gate": "metered",
onClick: () => a("clicked"),
- children: [/* @__PURE__ */ (0, z.jsx)(q7, { html: l }), /* @__PURE__ */ (0, z.jsxs)("span", { children: ["点此开始拉流 · ", s(e.size || 0)] })]
+ children: [/* @__PURE__ */ (0, z.jsx)(K7, { html: l }), /* @__PURE__ */ (0, z.jsxs)("span", { children: ["点此开始拉流 · ", s(e.size || 0)] })]
}) : null]
});
}
-function qUe({ item: e, badge: t, helpers: n, actions: r }) {
+function YUe({ item: e, badge: t, helpers: n, actions: r }) {
let [i, a] = (0, R.useState)(!1), [o, s] = (0, R.useState)(!1), c = async () => {
a(!0);
let t = await r.checkSource(e.location || "").catch(() => !1);
@@ -78648,7 +78700,7 @@ function qUe({ item: e, badge: t, helpers: n, actions: r }) {
role: "status",
"data-item-gate": "offline",
children: [
- /* @__PURE__ */ (0, z.jsx)(q7, { html: t }),
+ /* @__PURE__ */ (0, z.jsx)(K7, { html: t }),
/* @__PURE__ */ (0, z.jsx)("b", { children: "脱盘模式" }),
/* @__PURE__ */ (0, z.jsx)("span", { children: n.offlineReason(e.location || "") }),
/* @__PURE__ */ (0, z.jsx)("button", {
@@ -78662,8 +78714,8 @@ function qUe({ item: e, badge: t, helpers: n, actions: r }) {
]
});
}
-function JUe({ queue: e, itemId: t, helpers: n, actions: r }) {
- let i = _Ve(e), a = (0, R.useRef)(null), s = XUe(e, t, r), c = (0, R.useRef)(s);
+function XUe({ queue: e, itemId: t, helpers: n, actions: r }) {
+ let i = yVe(e), a = (0, R.useRef)(null), s = QUe(e, t, r), c = (0, R.useRef)(s);
c.current = s;
let u = (0, R.useCallback)((t) => {
a.current = t, t && (n.wireDrag(t), e.kind === "playlist" && n.wireDragReorder(t, {
@@ -78671,7 +78723,7 @@ function JUe({ queue: e, itemId: t, helpers: n, actions: r }) {
attribute: "data-queue-row",
onMove: (e, t, n) => c.current.move(+e, +t, n)
}));
- }, [n, e.kind]), d = YUe(e, r), f = e.kind === "mix" ? /* @__PURE__ */ (0, z.jsx)("button", {
+ }, [n, e.kind]), d = ZUe(e, r), f = e.kind === "mix" ? /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-save-mix": "",
title: "保存为播放列表",
@@ -78690,7 +78742,7 @@ function JUe({ queue: e, itemId: t, helpers: n, actions: r }) {
seedId: e.seedId,
playlistId: e.playlistId
};
- return /* @__PURE__ */ (0, z.jsx)(F7, {
+ return /* @__PURE__ */ (0, z.jsx)(P7, {
kind: e.kind,
title: i.title,
summary: i.summary,
@@ -78699,11 +78751,11 @@ function JUe({ queue: e, itemId: t, helpers: n, actions: r }) {
listRef: u,
children: e.items.map((i) => {
let a = e.kind === "editions" && i.edition_label ? /* @__PURE__ */ (0, z.jsx)("i", {
- className: `javedition ${hVe[i.edition_label] || "censored"}`,
+ className: `javedition ${_Ve[i.edition_label] || "censored"}`,
"data-queue-edition": "",
children: i.edition_label
- }) : null, c = e.kind === "playlist" && D8(i);
- return /* @__PURE__ */ (0, z.jsxs)(I7, {
+ }) : null, c = e.kind === "playlist" && E8(i);
+ return /* @__PURE__ */ (0, z.jsxs)(F7, {
current: i.id === t,
"data-queue-item": i.id,
row: { "data-queue-row": i.id },
@@ -78713,25 +78765,25 @@ function JUe({ queue: e, itemId: t, helpers: n, actions: r }) {
onClick: () => {
c || r.openQueueItem(p, i.id);
},
- pic: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(q7, { html: n.queueThumbHtml(i) }), /* @__PURE__ */ (0, z.jsx)("i", {
+ pic: /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)(K7, { html: n.queueThumbHtml(i) }), /* @__PURE__ */ (0, z.jsx)("i", {
className: "mono",
"data-mix-item-duration": "",
children: o(i.duration)
})] }),
- lead: /* @__PURE__ */ (0, z.jsx)(q7, { html: n.queueAvatarHtml(i) }),
+ lead: /* @__PURE__ */ (0, z.jsx)(K7, { html: n.queueAvatarHtml(i) }),
after: e.kind === "playlist" ? /* @__PURE__ */ (0, z.jsxs)("span", {
"data-queue-edit": "",
children: [/* @__PURE__ */ (0, z.jsx)("i", {
"data-queue-grip": "",
"aria-hidden": "true",
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "grip-vertical" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "grip-vertical" })
}), /* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-queue-remove": i.id,
title: "移出播放列表",
"aria-label": "移出播放列表",
onClick: () => s.remove(i.id),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "x" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "x" })
})]
}) : null,
children: [/* @__PURE__ */ (0, z.jsxs)("span", {
@@ -78742,14 +78794,14 @@ function JUe({ queue: e, itemId: t, helpers: n, actions: r }) {
})]
}), /* @__PURE__ */ (0, z.jsx)("span", {
"data-truncate-end": "",
- children: c ? "已消失 · 文件已不在盘上" : e.kind === "parts" ? I8(i.part_label) : n.mixLabel(i)
+ children: c ? "已消失 · 文件已不在盘上" : e.kind === "parts" ? F8(i.part_label) : n.mixLabel(i)
})]
}, i.id);
})
});
}
-function YUe(e, t) {
- let n = er({ mutationFn: (t) => G(_8, {
+function ZUe(e, t) {
+ let n = er({ mutationFn: (t) => G(g8, {
action: "create",
name: t,
asset_ids: e.items.map((e) => e.id),
@@ -78762,11 +78814,11 @@ function YUe(e, t) {
save: (e) => n.mutateAsync(e)
});
}
-function XUe(e, t, n) {
- let r = g8({
+function QUe(e, t, n) {
+ let r = h8({
kind: "playlist",
playlistId: e.playlistId
- }), i = (e) => (X.setQueryData(r, E8(e)), e), a = (t) => G(_8, {
+ }), i = (e) => (X.setQueryData(r, T8(e)), e), a = (t) => G(g8, {
id: e.playlistId,
...t
}).then((e) => e.playlist), o = er({
@@ -78782,8 +78834,8 @@ function XUe(e, t, n) {
return {
move: async (t, r, c) => {
if (e.kind !== "playlist") return;
- let l = yVe(s, t, r, c);
- if (bVe(l, s)) return;
+ let l = xVe(s, t, r, c);
+ if (SVe(l, s)) return;
let u = s;
await o.mutateAsync(l), n.toast("已调整播放顺序", { undo: async () => {
i(await a({
@@ -78829,7 +78881,7 @@ function XUe(e, t, n) {
}
};
}
-function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
+function $Ue({ item: e, queue: t, write: n, helpers: r, actions: i }) {
let a = e.location === "online", o = n.busyAttrs, [c, l] = (0, R.useState)(!1);
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-stage-side": "",
@@ -78837,7 +78889,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
children: /* @__PURE__ */ (0, z.jsxs)("div", {
"data-stage-side-content": "",
children: [
- /* @__PURE__ */ (0, z.jsx)(QUe, {
+ /* @__PURE__ */ (0, z.jsx)(eWe, {
item: e,
queue: t,
helpers: r,
@@ -78849,7 +78901,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-live": "polite",
children: n.sourceState
}),
- /* @__PURE__ */ (0, z.jsx)(eWe, {
+ /* @__PURE__ */ (0, z.jsx)(nWe, {
item: e,
write: n
}),
@@ -78860,7 +78912,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
children: [
/* @__PURE__ */ (0, z.jsxs)("span", {
"data-spec-item": "",
- children: [/* @__PURE__ */ (0, z.jsx)(K7, { name: "monitor" }), /* @__PURE__ */ (0, z.jsxs)("span", { children: [
+ children: [/* @__PURE__ */ (0, z.jsx)(G7, { name: "monitor" }), /* @__PURE__ */ (0, z.jsxs)("span", { children: [
e.width || "?",
"×",
e.height || "?"
@@ -78868,11 +78920,11 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
}),
/* @__PURE__ */ (0, z.jsxs)("span", {
"data-spec-item": "",
- children: [/* @__PURE__ */ (0, z.jsx)(K7, { name: "hard-drive" }), /* @__PURE__ */ (0, z.jsx)("span", { children: s(e.size || 0) })]
+ children: [/* @__PURE__ */ (0, z.jsx)(G7, { name: "hard-drive" }), /* @__PURE__ */ (0, z.jsx)("span", { children: s(e.size || 0) })]
}),
e.release_date ? /* @__PURE__ */ (0, z.jsxs)("span", {
"data-spec-item": "",
- children: [/* @__PURE__ */ (0, z.jsx)(K7, { name: "calendar" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e.release_date })]
+ children: [/* @__PURE__ */ (0, z.jsx)(G7, { name: "calendar" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e.release_date })]
}) : null,
e.region_label ? /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
@@ -78880,22 +78932,22 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"data-open-region": e.region || "",
title: e.region_settled ? "已判定的产地;打开同产地的作品" : "按番号或厂牌推断的产地,批量判定后不再变;打开同产地的作品",
onClick: () => i.openRegion(e.region || ""),
- children: [/* @__PURE__ */ (0, z.jsx)(K7, { name: "globe" }), /* @__PURE__ */ (0, z.jsxs)("span", { children: [e.region_label, e.region_settled ? "" : "(推断)"] })]
+ children: [/* @__PURE__ */ (0, z.jsx)(G7, { name: "globe" }), /* @__PURE__ */ (0, z.jsxs)("span", { children: [e.region_label, e.region_settled ? "" : "(推断)"] })]
}) : null
]
}),
- /* @__PURE__ */ (0, z.jsx)(tWe, {
+ /* @__PURE__ */ (0, z.jsx)(rWe, {
item: e,
helpers: r,
actions: i
}),
- /* @__PURE__ */ (0, z.jsx)(nWe, {
+ /* @__PURE__ */ (0, z.jsx)(iWe, {
item: e,
write: n,
helpers: r,
actions: i
}),
- /* @__PURE__ */ (0, z.jsx)(iWe, { item: e }),
+ /* @__PURE__ */ (0, z.jsx)(oWe, { item: e }),
/* @__PURE__ */ (0, z.jsxs)("div", {
"data-stage-actions": "",
"data-item-feedback": "",
@@ -78909,7 +78961,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-pressed": !!e.liked,
...o("like"),
onClick: () => n.preference({ liked: !e.liked }),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "thumbs-up" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "thumbs-up" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -78921,7 +78973,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-controls": "preferencePanel",
"data-has-reason": String(!!e.like_reason),
onClick: () => l((e) => !e),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "notebook-pen" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "notebook-pen" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -78932,7 +78984,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-pressed": e.feedback === "dislike",
...o("dislike"),
onClick: () => n.feedback("dislike"),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "thumbs-down" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "thumbs-down" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -78943,7 +78995,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-pressed": e.feedback === "seen",
...o("seen"),
onClick: () => n.feedback("seen"),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "eye" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "eye" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -78954,7 +79006,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-pressed": !!e.watch_later,
...o("later"),
onClick: n.later,
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: e.watch_later ? "check" : "bookmark-plus" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: e.watch_later ? "check" : "bookmark-plus" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -78963,7 +79015,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-label": "加入播放列表",
title: "加入播放列表",
onClick: () => i.addToPlaylist(e),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "playlist" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "playlist" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -78974,7 +79026,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-pressed": !!e.better_version,
...o("quality"),
onClick: n.quality,
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "sparkles" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "sparkles" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -78982,7 +79034,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-label": "云下载",
title: "云下载 · 贴磁力交给 115 或 PikPak 离线下载",
onClick: () => i.cloudDownload(e),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "cloud-download" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "cloud-download" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
@@ -78993,11 +79045,11 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
"aria-pressed": e.disposal === "trash",
...o("dispose"),
onClick: () => n.feedback("dispose"),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "trash" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "trash" })
})
]
}),
- /* @__PURE__ */ (0, z.jsx)(aWe, {
+ /* @__PURE__ */ (0, z.jsx)(sWe, {
item: e,
open: c,
write: n
@@ -79008,7 +79060,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
...o("o"),
onClick: () => n.feedback("o"),
children: [
- /* @__PURE__ */ (0, z.jsx)(K7, { name: "sperm" }),
+ /* @__PURE__ */ (0, z.jsx)(G7, { name: "sperm" }),
/* @__PURE__ */ (0, z.jsx)("span", { children: "记一次高潮" }),
/* @__PURE__ */ (0, z.jsx)("b", {
className: "mono",
@@ -79021,7 +79073,7 @@ function ZUe({ item: e, queue: t, write: n, helpers: r, actions: i }) {
})
});
}
-function QUe({ item: e, queue: t, helpers: n, actions: r, onStatus: i }) {
+function eWe({ item: e, queue: t, helpers: n, actions: r, onStatus: i }) {
let a = (0, R.useRef)(null), [o, s] = (0, R.useState)(!1), [c, l] = (0, R.useState)(!1);
(0, R.useLayoutEffect)(() => {
let e = a.current;
@@ -79031,7 +79083,7 @@ function QUe({ item: e, queue: t, helpers: n, actions: r, onStatus: i }) {
}, n = new ResizeObserver(t);
return n.observe(e), t(), () => n.disconnect();
}, []);
- let u = () => s((e) => !e), d = n.badgeHtml(e.location || "", e.cost || "", "srcbig") + n.titleHtml(e) + vVe(e, t);
+ let u = () => s((e) => !e), d = n.badgeHtml(e.location || "", e.cost || "", "srcbig") + n.titleHtml(e) + bVe(e, t);
return /* @__PURE__ */ (0, z.jsx)("div", {
"data-item-title": "",
children: /* @__PURE__ */ (0, z.jsxs)("div", {
@@ -79058,21 +79110,21 @@ function QUe({ item: e, queue: t, helpers: n, actions: r, onStatus: i }) {
"aria-label": o ? "收起标题" : "展开标题",
title: o ? "收起标题" : "展开完整标题",
onClick: u,
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: o ? "chevron-up" : "chevron-down" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: o ? "chevron-up" : "chevron-down" })
}),
e.has_cover && e.code ? /* @__PURE__ */ (0, z.jsx)("span", {
"data-cover-crop-host": "",
- children: /* @__PURE__ */ (0, z.jsx)(HUe, {
+ children: /* @__PURE__ */ (0, z.jsx)(WUe, {
code: e.code,
coverUrl: `/cover?code=${encodeURIComponent(e.code)}`,
box: e.poster_box || null,
onSaved: () => void X.invalidateQueries({
- queryKey: h8(e.id),
+ queryKey: m8(e.id),
exact: !0
})
})
}) : null,
- e.location === "online" ? null : /* @__PURE__ */ (0, z.jsx)($Ue, {
+ e.location === "online" ? null : /* @__PURE__ */ (0, z.jsx)(tWe, {
id: e.id,
actions: r,
onStatus: i
@@ -79082,7 +79134,7 @@ function QUe({ item: e, queue: t, helpers: n, actions: r, onStatus: i }) {
})
});
}
-function $Ue({ id: e, actions: t, onStatus: n }) {
+function tWe({ id: e, actions: t, onStatus: n }) {
let [r, i] = (0, R.useState)(""), a = async () => {
r || (i("reveal"), n(""), n(await t.reveal(e)), i(""));
}, o = async () => {
@@ -79112,17 +79164,17 @@ function $Ue({ id: e, actions: t, onStatus: n }) {
"aria-disabled": !0
} : {},
onClick: () => void o(),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "folder-sync" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "folder-sync" })
})] });
}
-function eWe({ item: e, write: t }) {
- let n = A8(e.rating);
+function nWe({ item: e, write: t }) {
+ let n = k8(e.rating);
return /* @__PURE__ */ (0, z.jsxs)("div", {
id: "detailRating",
role: "group",
"data-item-rating": "",
"aria-label": "评分",
- "data-value": k8(e.rating),
+ "data-value": O8(e.rating),
children: [/* @__PURE__ */ (0, z.jsx)("div", {
"data-rating-stars": "",
children: [
@@ -79139,18 +79191,18 @@ function eWe({ item: e, write: t }) {
"aria-label": e === n ? `取消评分(当前 ${e} 星)` : `评为 ${e} 星`,
...t.busyAttrs(`rate:${e}`),
onClick: () => t.rate(e),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "star" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "star" })
}, e))
}), /* @__PURE__ */ (0, z.jsx)("span", {
"data-rating-value": "",
"aria-live": "polite",
- children: uVe(e.rating)
+ children: fVe(e.rating)
})]
});
}
-function tWe({ item: e, helpers: t, actions: n }) {
- let r = (0, R.useMemo)(() => lVe(e), [e]), [i, a] = (0, R.useState)(!1), o = Math.max(0, r.cast.length - 8), s = (e, r, a) => {
- let o = e === "performer" && a >= 8 && !i, s = e === "performer" ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("span", { children: r.name.slice(0, 1) }), /* @__PURE__ */ (0, z.jsx)(q7, { html: t.faceHtml(r) })] }) : e === "studio" ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("span", { children: r.name.slice(0, 2) }), r.has_logo ? /* @__PURE__ */ (0, z.jsx)("img", {
+function rWe({ item: e, helpers: t, actions: n }) {
+ let r = (0, R.useMemo)(() => dVe(e), [e]), [i, a] = (0, R.useState)(!1), o = Math.max(0, r.cast.length - 8), s = (e, r, a) => {
+ let o = e === "performer" && a >= 8 && !i, s = e === "performer" ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("span", { children: r.name.slice(0, 1) }), /* @__PURE__ */ (0, z.jsx)(K7, { html: t.faceHtml(r) })] }) : e === "studio" ? /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [/* @__PURE__ */ (0, z.jsx)("span", { children: r.name.slice(0, 2) }), r.has_logo ? /* @__PURE__ */ (0, z.jsx)("img", {
src: `/logo?studio=${encodeURIComponent(r.name)}&variant=icon`,
alt: "",
loading: "lazy",
@@ -79204,7 +79256,7 @@ function tWe({ item: e, helpers: t, actions: n }) {
onClick: n.openUnowned,
children: [/* @__PURE__ */ (0, z.jsx)("span", {
"data-id-face": "",
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "user-round" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "user-round" })
}), /* @__PURE__ */ (0, z.jsx)("span", {
"data-id-name": "",
children: "未归属"
@@ -79247,19 +79299,19 @@ function tWe({ item: e, helpers: t, actions: n }) {
"data-entity-name": e.name,
title: e.name,
onClick: () => n.openEntity("series", e.name),
- children: [/* @__PURE__ */ (0, z.jsx)(K7, { name: "tags" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e.name })]
+ children: [/* @__PURE__ */ (0, z.jsx)(G7, { name: "tags" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e.name })]
}, e.name) : /* @__PURE__ */ (0, z.jsxs)("span", {
"data-series-link": "",
title: e.name,
- children: [/* @__PURE__ */ (0, z.jsx)(K7, { name: "tags" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e.name })]
+ children: [/* @__PURE__ */ (0, z.jsx)(G7, { name: "tags" }), /* @__PURE__ */ (0, z.jsx)("span", { children: e.name })]
}, e.name))
})]
}) : null
]
});
}
-function nWe({ item: e, write: t, helpers: n, actions: r }) {
- let i = fVe(e, n);
+function iWe({ item: e, write: t, helpers: n, actions: r }) {
+ let i = mVe(e, n);
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-stage-tags": "",
id: "detailTags",
@@ -79278,16 +79330,16 @@ function nWe({ item: e, write: t, helpers: n, actions: r }) {
"aria-label": `删除标签 ${n.tagLabel(e.k)}`,
...t.busyAttrs(`tag:${e.k}`),
onClick: () => t.removeTag(e),
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "x" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "x" })
})]
- }, e.k)), /* @__PURE__ */ (0, z.jsx)(rWe, {
+ }, e.k)), /* @__PURE__ */ (0, z.jsx)(aWe, {
item: e,
write: t,
helpers: n
})]
});
}
-function rWe({ item: e, write: t, helpers: n }) {
+function aWe({ item: e, write: t, helpers: n }) {
let r = (0, R.useRef)(null), i = (0, R.useRef)(null), a = (0, R.useRef)(null), o = (0, R.useRef)(!1), [s, c] = (0, R.useState)(!1), [l, u] = (0, R.useState)(""), [d, f] = (0, R.useState)(""), [p, m] = (0, R.useState)(-1), h = (0, R.useCallback)(() => {
i.current && S(i.current), c(!1);
}, []);
@@ -79301,7 +79353,7 @@ function rWe({ item: e, write: t, helpers: n }) {
clearTimeout(t), document.removeEventListener("pointerdown", e, !0);
};
}, [s, h]);
- let g = s ? mVe(d, n.tagCandidates(), F8()) : {
+ let g = s ? gVe(d, n.tagCandidates(), P8()) : {
recent: [],
results: [],
create: ""
@@ -79329,12 +79381,12 @@ function rWe({ item: e, write: t, helpers: n }) {
if (n.key === "Enter") {
n.preventDefault();
let r = p >= 0 ? _[p] : null;
- r ? v(r, r.n !== -1 && j8(e, r.k)) : l.trim() && (h(), t.addTag(l.trim()));
+ r ? v(r, r.n !== -1 && A8(e, r.k)) : l.trim() && (h(), t.addTag(l.trim()));
}
}
}, b = -1, x = (t) => {
b += 1;
- let r = b, i = j8(e, t.k);
+ let r = b, i = A8(e, t.k);
return /* @__PURE__ */ (0, z.jsxs)("button", {
type: "button",
"data-pick": t.k,
@@ -79342,7 +79394,7 @@ function rWe({ item: e, write: t, helpers: n }) {
"aria-pressed": i,
onClick: () => v(t, i),
children: [
- /* @__PURE__ */ (0, z.jsx)(K7, { name: i ? "check" : "tags" }),
+ /* @__PURE__ */ (0, z.jsx)(G7, { name: i ? "check" : "tags" }),
/* @__PURE__ */ (0, z.jsx)("span", {
"data-pick-name": "",
children: n.tagLabel(t.k)
@@ -79365,7 +79417,7 @@ function rWe({ item: e, write: t, helpers: n }) {
onClick: () => {
i.current && (P(i.current), c(!0), u(""), f(""), m(-1), requestAnimationFrame(() => a.current?.focus()));
},
- children: /* @__PURE__ */ (0, z.jsx)(K7, { name: "plus" })
+ children: /* @__PURE__ */ (0, z.jsx)(G7, { name: "plus" })
}), /* @__PURE__ */ (0, z.jsxs)("div", {
ref: i,
id: "tagPicker",
@@ -79375,7 +79427,7 @@ function rWe({ item: e, write: t, helpers: n }) {
hidden: !0,
children: [/* @__PURE__ */ (0, z.jsxs)("label", {
"data-tag-search": "",
- children: [/* @__PURE__ */ (0, z.jsx)(K7, { name: "search" }), /* @__PURE__ */ (0, z.jsx)("input", {
+ children: [/* @__PURE__ */ (0, z.jsx)(G7, { name: "search" }), /* @__PURE__ */ (0, z.jsx)("input", {
ref: a,
id: "tagPickSearch",
maxLength: 80,
@@ -79416,7 +79468,7 @@ function rWe({ item: e, write: t, helpers: n }) {
onClick: () => {
h(), t.addTag(g.create);
},
- children: [/* @__PURE__ */ (0, z.jsx)(K7, { name: "plus" }), /* @__PURE__ */ (0, z.jsxs)("span", {
+ children: [/* @__PURE__ */ (0, z.jsx)(G7, { name: "plus" }), /* @__PURE__ */ (0, z.jsxs)("span", {
"data-pick-name": "",
children: [
"新建“",
@@ -79431,8 +79483,8 @@ function rWe({ item: e, write: t, helpers: n }) {
})]
})] });
}
-function iWe({ item: e }) {
- let t = SVe(e);
+function oWe({ item: e }) {
+ let t = wVe(e);
return /* @__PURE__ */ (0, z.jsxs)("div", {
"data-item-trace": "",
children: [/* @__PURE__ */ (0, z.jsxs)("div", {
@@ -79466,7 +79518,7 @@ function iWe({ item: e }) {
})]
});
}
-function aWe({ item: e, open: t, write: n }) {
+function sWe({ item: e, open: t, write: n }) {
let [r, i] = (0, R.useState)(e.like_reason || ""), a = (0, R.useRef)(null);
(0, R.useEffect)(() => {
t && a.current?.focus();
@@ -79505,11 +79557,11 @@ function aWe({ item: e, open: t, write: n }) {
})]
});
}
-function oWe(e) {
+function cWe(e) {
let { item: t, relatedLimit: n, helpers: r, grid: i } = e, a = $n({
- queryKey: iVe(t.id, n),
+ queryKey: oVe(t.id, n),
queryFn: async ({ signal: e }) => {
- let r = await W(oVe(t.id, n), e);
+ let r = await W(cVe(t.id, n), e);
return i.cache(r.items || []), r.items || [];
}
}), [o] = (0, R.useState)(() => r.relatedSkeletonHtml()), s = (0, R.useCallback)((e) => {
@@ -79524,7 +79576,7 @@ function oWe(e) {
ref: s,
id: "nrow",
"data-related-row": "",
- children: a.data ? /* @__PURE__ */ (0, z.jsx)(Nb, {
+ children: a.data ? /* @__PURE__ */ (0, z.jsx)(Rb, {
mode: "items",
variant: "next",
items: a.data,
@@ -79538,12 +79590,12 @@ function oWe(e) {
cache: i.cache,
wireDrag: r.wireDrag,
skeletonHtml: () => ""
- }) : a.isError ? null : /* @__PURE__ */ (0, z.jsx)(q7, { html: o })
+ }) : a.isError ? null : /* @__PURE__ */ (0, z.jsx)(K7, { html: o })
})]
});
}
-function sWe(e, t, n, r) {
- let i = e.id, a = h8(i), [o, s] = (0, R.useState)(() => /* @__PURE__ */ new Set()), [c, l] = (0, R.useState)(""), [u, d] = (0, R.useState)(""), f = (e, t) => s((n) => {
+function lWe(e, t, n, r) {
+ let i = e.id, a = m8(i), [o, s] = (0, R.useState)(() => /* @__PURE__ */ new Set()), [c, l] = (0, R.useState)(""), [u, d] = (0, R.useState)(""), f = (e, t) => s((n) => {
let r = new Set(n);
return t ? r.add(e) : r.delete(e), r;
}), p = () => X.getQueryData(a) || e, m = (e) => {
@@ -79559,7 +79611,7 @@ function sWe(e, t, n, r) {
rating: t.rating,
o_count: t.o_count
};
- return gb(i, r), n([t]), t;
+ return ab(i, r), n([t]), t;
}, h = (e, t) => G(e, {
id: i,
...t
@@ -79574,7 +79626,7 @@ function sWe(e, t, n, r) {
run: n
}));
}, v = async (e, t) => {
- let n = await h(v8, t === void 0 ? { kind: e } : {
+ let n = await h(_8, t === void 0 ? { kind: e } : {
kind: e,
value: t
});
@@ -79594,21 +79646,21 @@ function sWe(e, t, n, r) {
"aria-disabled": !0
} : {},
rate: (e) => _(`rate:${e}`, "评分", async () => {
- let n = p().rating || 0, r = dVe(n, e);
- await v("rate", r), t.toast(r ? `已评 ${A8(r)} 星` : "已取消评分", { undo: async () => {
+ let n = p().rating || 0, r = pVe(n, e);
+ await v("rate", r), t.toast(r ? `已评 ${k8(r)} 星` : "已取消评分", { undo: async () => {
await v("rate", n);
} });
}),
feedback: (e) => _(e, "操作", async () => {
let n = { feedback: p().feedback || null }, r = await v(e);
- t.toast(L8(e, r), { undo: async () => {
+ t.toast(I8(e, r), { undo: async () => {
e === "o" ? await v("o-undo") : e === "dispose" ? await v("dispose") : (r.feedback && await v(r.feedback), n.feedback && await v(n.feedback)), await t.trashChanged(p().disposal || null, !0);
} }), e === "dispose" && await t.trashChanged(r.disposal || null, !1);
}),
later: () => _("later", "更新稍后看", async () => {
- let e = await h(b8, {});
+ let e = await h(y8, {});
m({ watch_later: e.watch_later }), t.toast(e.watch_later ? "已加入稍后看" : "已移出稍后看", { undo: async () => {
- m({ watch_later: (await h(b8, {})).watch_later });
+ m({ watch_later: (await h(y8, {})).watch_later });
} });
}),
quality: () => _("quality", "更新版本需求", async () => {
@@ -79618,9 +79670,9 @@ function sWe(e, t, n, r) {
}, n = (e) => m({
better_version: e.better_version,
better_version_reason: e.better_version_reason || ""
- }), r = await h(x8, { wanted: !e.wanted });
+ }), r = await h(b8, { wanted: !e.wanted });
n(r), t.toast(r.better_version ? "已标记寻找更好版本" : "已取消寻找更好版本", { undo: async () => {
- n(await h(x8, e));
+ n(await h(b8, e));
} });
}),
preference: ({ liked: e, reason: n }) => {
@@ -79634,7 +79686,7 @@ function sWe(e, t, n, r) {
});
d("保存中…");
try {
- o(await h(S8, {
+ o(await h(x8, {
liked: a,
reason: i
}));
@@ -79644,7 +79696,7 @@ function sWe(e, t, n, r) {
d("已保存"), setTimeout(() => d((e) => e === "已保存" ? "" : e), 1400);
let s = p();
t.toast(s.liked ? "已保存喜欢偏好" : "已取消喜欢", { undo: async () => {
- o(await h(S8, r));
+ o(await h(x8, r));
} });
});
},
@@ -79653,11 +79705,11 @@ function sWe(e, t, n, r) {
operation: "remove",
tag: e.k
})).ok) throw Error("标签未删除");
- m((t) => M8(t, e.k)), t.toast(`已删除标签「${r(e.k)}」`, { undo: async () => {
- await h(y8, {
+ m((t) => j8(t, e.k)), t.toast(`已删除标签「${r(e.k)}」`, { undo: async () => {
+ await h(v8, {
operation: "add",
tag: e.k
- }), m((t) => N8(t, e));
+ }), m((t) => M8(t, e));
} });
}),
addTag: (e) => {
@@ -79666,14 +79718,14 @@ function sWe(e, t, n, r) {
(await h("/api/item-tag", {
operation: "add",
tag: n
- })).ok && (m((e) => N8(e, {
+ })).ok && (m((e) => M8(e, {
k: n,
cat: "general"
- })), pVe(n), t.toast(`已添加标签「${r(n)}」`, { undo: async () => {
- await h(y8, {
+ })), hVe(n), t.toast(`已添加标签「${r(n)}」`, { undo: async () => {
+ await h(v8, {
operation: "remove",
tag: n
- }), m((e) => M8(e, n));
+ }), m((e) => j8(e, n));
} }));
});
}
@@ -79681,31 +79733,31 @@ function sWe(e, t, n, r) {
}
//#endregion
//#region src/react/stage/stage-player.ts
-var Y7 = null, X7 = null, Z7 = null, Q7 = null, $7 = null, e9 = !1, t9 = 0, n9 = null, r9 = () => !1, i9 = (e, t, n) => `${e}:${t}:${n ?? ""}`;
-function cWe(e, t) {
- Y7 = e, r9 = () => t.isOpen(), n9 = () => t.requestClose(), kBe({
+var J7 = null, Y7 = null, X7 = null, Z7 = null, Q7 = null, $7 = !1, e9 = 0, t9 = null, n9 = () => !1, r9 = (e, t, n) => `${e}:${t}:${n ?? ""}`;
+function uWe(e, t) {
+ J7 = e, n9 = () => t.isOpen(), t9 = () => t.requestClose(), jBe({
...e.player,
stage: () => document.getElementById("stage")
- }), ABe({
- inMiniplayer: (e) => X7?.player === e,
- kind: (e) => X7?.player === e ? X7.kind : Z7?.kind ?? Q7?.kind ?? "item",
- expand: () => S9(),
- toMiniplayer: () => C9()
- }), a9 || (a9 = !0, addEventListener("pagehide", () => $6()));
-}
-var a9 = !1;
-function o9() {
- if (!Y7) throw Error("舞台播放器还没有接上宿主(configureStagePlayer)");
- return Y7;
-}
-function s9(e) {
- Q7 = e;
-}
-var lWe = () => Q7;
-function c9(e, t) {
- let { kind: n, item: r, media: i = null } = t, a = i9(n, r.id, i?.index ?? null);
- if (X7 && X7.key === a) return uWe(e, X7);
- X7 && x9();
+ }), MBe({
+ inMiniplayer: (e) => Y7?.player === e,
+ kind: (e) => Y7?.player === e ? Y7.kind : X7?.kind ?? Z7?.kind ?? "item",
+ expand: () => x9(),
+ toMiniplayer: () => S9()
+ }), i9 || (i9 = !0, addEventListener("pagehide", () => Q6()));
+}
+var i9 = !1;
+function a9() {
+ if (!J7) throw Error("舞台播放器还没有接上宿主(configureStagePlayer)");
+ return J7;
+}
+function o9(e) {
+ Z7 = e;
+}
+var dWe = () => Z7;
+function s9(e, t) {
+ let { kind: n, item: r, media: i = null } = t, a = r9(n, r.id, i?.index ?? null);
+ if (Y7 && Y7.key === a) return fWe(e, Y7);
+ Y7 && b9();
let o = {
player: null,
kind: n,
@@ -79713,28 +79765,28 @@ function c9(e, t) {
mediaIndex: i?.index ?? null,
key: a
};
- Z7 = o;
+ X7 = o;
let s = document.createElement("video");
t.id && (s.id = t.id), s.className = "video-js vjs-big-play-centered", s.controls = !0, s.setAttribute("playsinline", ""), s.preload = "metadata", t.poster && (s.poster = t.poster), t.onError && s.addEventListener("error", t.onError), e.append(s);
- let c = p8(s, {
+ let c = f8(s, {
kind: n,
item: r,
media: i,
autoplay: t.autoplay,
resume: t.resume ?? null,
onPlayer: (e) => {
- Z7 === o && (o.player = e);
+ X7 === o && (o.player = e);
},
- handedOff: (e) => X7?.player === e
+ handedOff: (e) => Y7?.player === e
});
return () => {
- let e = !!o.player && X7?.player === o.player;
- Z7 === o && (Z7 = null), c(), !e && (o.player || (s.pause(), s.removeAttribute("src"), s.load()), $6());
+ let e = !!o.player && Y7?.player === o.player;
+ X7 === o && (X7 = null), c(), !e && (o.player || (s.pause(), s.removeAttribute("src"), s.load()), Q6());
};
}
-function uWe(e, t) {
+function fWe(e, t) {
let { player: n } = t;
- y9(t), X7 = null, b9(), n.el().classList.remove("vjs-peach-mini"), d8(e), e.append(n.el()), O6(n);
+ v9(t), Y7 = null, y9(), n.el().classList.remove("vjs-peach-mini"), u8(e), e.append(n.el()), D6(n);
let r = {
player: n,
kind: t.kind,
@@ -79742,23 +79794,23 @@ function uWe(e, t) {
mediaIndex: t.mediaIndex,
key: t.key
};
- Z7 = r;
- let i = f8(n, e);
- return k6(n), () => {
- Z7 === r && (Z7 = null), i(), X7?.player !== n && (D6() === n && O6(null), G6(n), $6());
+ X7 = r;
+ let i = d8(n, e);
+ return O6(n), () => {
+ X7 === r && (X7 = null), i(), Y7?.player !== n && (E6() === n && D6(null), W6(n), Q6());
};
}
-var l9 = () => {
- let e = Z7?.player;
+var c9 = () => {
+ let e = X7?.player;
return e && !e.isDisposed() ? e : null;
};
-function dWe(e) {
- let t = e9;
- e9 = !1, X7?.pending && x9();
- let n = Z7, r = n?.player, i = Q7;
- if (!n || !r || r.isDisposed() || !i || !$7) return;
- let a = o9().player.settings();
- (t || e && a.miniplayer && !r.paused() && !r.ended() && !r.error()) && gWe({
+function pWe(e) {
+ let t = $7;
+ $7 = !1, Y7?.pending && b9();
+ let n = X7, r = n?.player, i = Z7;
+ if (!n || !r || r.isDisposed() || !i || !Q7) return;
+ let a = a9().player.settings();
+ (t || e && a.miniplayer && !r.paused() && !r.ended() && !r.error()) && vWe({
player: r,
kind: n.kind,
item: n.item,
@@ -79766,52 +79818,52 @@ function dWe(e) {
key: n.key
}, i);
}
-function fWe(e, t) {
- if (e9 = !1, X7) {
- if (X7.kind === e && X7.item.id === t) {
- X7.pending = !0, b9();
+function mWe(e, t) {
+ if ($7 = !1, Y7) {
+ if (Y7.kind === e && Y7.item.id === t) {
+ Y7.pending = !0, y9();
return;
}
- x9();
+ b9();
}
}
-function u9(e) {
- $7 = e, $7 && _9();
+function l9(e) {
+ Q7 = e, Q7 && g9();
}
-var d9 = () => !!X7 && !X7.pending && !X7.player.isDisposed();
-function pWe() {
- return d9() ? $7?.frame.querySelector("video") ?? null : null;
+var u9 = () => !!Y7 && !Y7.pending && !Y7.player.isDisposed();
+function hWe() {
+ return u9() ? Q7?.frame.querySelector("video") ?? null : null;
}
-function mWe() {
- return r9() ? document.getElementById("stage")?.querySelector("video") ?? null : pWe();
+function gWe() {
+ return n9() ? document.getElementById("stage")?.querySelector("video") ?? null : hWe();
}
-function f9(e) {
- $7 && ($7.title.textContent = e.title || "", $7.sub.textContent = e.sub || "", $7.info.setAttribute("aria-label", e.title ? `展开到详情:${e.title}` : "展开到详情"));
+function d9(e) {
+ Q7 && (Q7.title.textContent = e.title || "", Q7.sub.textContent = e.sub || "", Q7.info.setAttribute("aria-label", e.title ? `展开到详情:${e.title}` : "展开到详情"));
}
-function p9(e = X7?.item) {
- if (!$7) return;
- let t = $7.frame.querySelector("video"), n = t?.videoWidth || Number(e?.width) || 16, r = t?.videoHeight || Number(e?.height) || 9;
- $7.frame.style.setProperty("--miniplayer-aspect", `${Math.max(n, r)}/${r}`);
+function f9(e = Y7?.item) {
+ if (!Q7) return;
+ let t = Q7.frame.querySelector("video"), n = t?.videoWidth || Number(e?.width) || 16, r = t?.videoHeight || Number(e?.height) || 9;
+ Q7.frame.style.setProperty("--miniplayer-aspect", `${Math.max(n, r)}/${r}`);
}
-function m9() {
- let e = X7?.player;
- if (!e || e.isDisposed() || !$7) return;
+function p9() {
+ let e = Y7?.player;
+ if (!e || e.isDisposed() || !Q7) return;
let t = e.paused();
- $7.play.setAttribute("aria-label", t ? "播放" : "暂停"), $7.play.querySelector("[data-icon-swap]") || ($7.play.innerHTML = E("player-pause", "player-play", t ? "b" : "a")), re($7.play, t ? "b" : "a");
-}
-function h9() {
- let e = X7?.player;
- if (!e || e.isDisposed() || !$7) return;
- let t = p(X7?.item.duration) || p(e.duration());
- $7.time.textContent = `${a(e.currentTime())} / ${t ? a(t) : "0:00"}`;
+ Q7.play.setAttribute("aria-label", t ? "播放" : "暂停"), Q7.play.querySelector("[data-icon-swap]") || (Q7.play.innerHTML = E("player-pause", "player-play", t ? "b" : "a")), re(Q7.play, t ? "b" : "a");
}
-var g9 = () => Math.max(1, Number(o9().player.settings().seekSeconds) || 10);
-function _9() {
- if (!$7 || !Y7) return;
- let e = g9();
- for (let [t, n] of [[$7.back, `后退 ${e} 秒`], [$7.ahead, `前进 ${e} 秒`]]) t.setAttribute("aria-label", n), t.title = n;
-}
-function v9(e) {
+function m9() {
+ let e = Y7?.player;
+ if (!e || e.isDisposed() || !Q7) return;
+ let t = p(Y7?.item.duration) || p(e.duration());
+ Q7.time.textContent = `${a(e.currentTime())} / ${t ? a(t) : "0:00"}`;
+}
+var h9 = () => Math.max(1, Number(a9().player.settings().seekSeconds) || 10);
+function g9() {
+ if (!Q7 || !J7) return;
+ let e = h9();
+ for (let [t, n] of [[Q7.back, `后退 ${e} 秒`], [Q7.ahead, `前进 ${e} 秒`]]) t.setAttribute("aria-label", n), t.title = n;
+}
+function _9(e) {
let t = (t, n) => {
e.player.on(t, n), e.off.push(() => {
try {
@@ -79823,17 +79875,17 @@ function v9(e) {
"play",
"pause",
"ended"
- ], m9), t([
+ ], p9), t([
"timeupdate",
"durationchange",
"loadedmetadata"
- ], h9), t("loadedmetadata", () => p9()), m9(), h9(), p9(), _9();
+ ], m9), t("loadedmetadata", () => f9()), p9(), m9(), f9(), g9();
}
-function y9(e) {
+function v9(e) {
e.off.forEach((e) => e()), e.off = [];
}
-function hWe() {
- let e = $7?.root;
+function _We() {
+ let e = Q7?.root;
if (!e) return;
let t = e.hidden;
if (e.hidden = !1, !t) return;
@@ -79841,8 +79893,8 @@ function hWe() {
let n = () => e.removeAttribute("data-miniplayer-enter");
e.addEventListener("animationend", n, { once: !0 }), setTimeout(n, 500);
}
-function b9() {
- let e = $7?.root;
+function y9() {
+ let e = Q7?.root;
if (e) {
e.hidden = !0;
for (let t of [
@@ -79853,78 +79905,78 @@ function b9() {
e.style.transform = "";
}
}
-function gWe(e, t) {
- if (!$7) return;
+function vWe(e, t) {
+ if (!Q7) return;
let n = {
...e,
meta: t,
off: [],
pending: !1
};
- X7 = n, t9++, e.player.el().classList.add("vjs-peach-mini"), $7.frame.prepend(e.player.el()), f9(t), v9(n), hWe(), k6(e.player);
+ Y7 = n, e9++, e.player.el().classList.add("vjs-peach-mini"), Q7.frame.prepend(e.player.el()), d9(t), _9(n), _We(), O6(e.player);
}
-function x9() {
- let e = X7;
- e && y9(e), X7 = null, t9++;
+function b9() {
+ let e = Y7;
+ e && v9(e), Y7 = null, e9++;
let t = e?.player ?? null;
- t && D6() === t && O6(null), G6(t), t && $6(), $7?.frame.querySelectorAll(".video-js,video").forEach((e) => e.remove()), T6(), b9();
+ t && E6() === t && D6(null), W6(t), t && Q6(), Q7?.frame.querySelectorAll(".video-js,video").forEach((e) => e.remove()), w6(), y9();
}
-function S9() {
- if (!d9() || !X7) return;
- let { kind: e, item: t, mediaIndex: n } = X7;
- o9().expand(e, t.id, n);
+function x9() {
+ if (!u9() || !Y7) return;
+ let { kind: e, item: t, mediaIndex: n } = Y7;
+ a9().expand(e, t.id, n);
}
-function C9() {
- if (d9() && !r9()) {
- S9();
+function S9() {
+ if (u9() && !n9()) {
+ x9();
return;
}
- r9() && l9() && n9 && (e9 = !0, n9());
+ n9() && c9() && t9 && ($7 = !0, t9());
}
-function _We() {
- let e = X7?.player;
+function yWe() {
+ let e = Y7?.player;
!e || e.isDisposed() || (e.paused() ? e.play()?.catch(() => {}) : e.pause());
}
-function w9(e) {
- let t = X7?.player;
+function C9(e) {
+ let t = Y7?.player;
if (!t || t.isDisposed()) return;
- let n = p(t.duration()) || p(X7?.item.duration) || 0, r = Math.max(0, (Number(t.currentTime()) || 0) + g9() * e);
+ let n = p(t.duration()) || p(Y7?.item.duration) || 0, r = Math.max(0, (Number(t.currentTime()) || 0) + h9() * e);
t.currentTime(n ? Math.min(n, r) : r);
}
-function T9(e) {
- return !(!d9() || !e || e.part_group || e.edition_group || e.medium && e.medium !== "video" || e.cost === "metered" && e.location !== "online" || e.location === "online" && !e.follow_item_id || o9().sourceOffline(String(e.location ?? "")));
-}
-async function vWe(e) {
- if (!d9() || !X7 || !$7) return;
- let n = ++t9, r = await t(`/api/item?id=${e}`).catch(() => null);
- if (n !== t9 || !d9() || !X7 || !$7 || !r || r.error) return;
- if (!T9(r)) {
- o9().openItem(e);
+function w9(e) {
+ return !(!u9() || !e || e.part_group || e.edition_group || e.medium && e.medium !== "video" || e.cost === "metered" && e.location !== "online" || e.location === "online" && !e.follow_item_id || a9().sourceOffline(String(e.location ?? "")));
+}
+async function bWe(e) {
+ if (!u9() || !Y7 || !Q7) return;
+ let n = ++e9, r = await t(`/api/item?id=${e}`).catch(() => null);
+ if (n !== e9 || !u9() || !Y7 || !Q7 || !r || r.error) return;
+ if (!w9(r)) {
+ a9().openItem(e);
return;
}
- o9().cache(r);
- let i = X7;
- y9(i), D6() === i.player && O6(null), G6(i.player), $6(), $7.frame.querySelectorAll(".video-js,video").forEach((e) => e.remove());
+ a9().cache(r);
+ let i = Y7;
+ v9(i), E6() === i.player && D6(null), W6(i.player), Q6(), Q7.frame.querySelectorAll(".video-js,video").forEach((e) => e.remove());
let a = document.createElement("video");
- a.className = "video-js", a.setAttribute("playsinline", ""), a.preload = "metadata", $7.frame.prepend(a);
+ a.className = "video-js", a.setAttribute("playsinline", ""), a.preload = "metadata", Q7.frame.prepend(a);
let o = {
kind: "item",
item: r,
title: String(r.title || r.name || ""),
sub: String(r.performers?.[0] || r.creator || "未归属")
};
- f9(o), p8(a, {
+ d9(o), f8(a, {
kind: "item",
item: r,
autoplay: !0,
chrome: !1,
onPlayer: (t) => {
- if (n !== t9) {
- t && D6() === t && O6(null), G6(t);
+ if (n !== e9) {
+ t && E6() === t && D6(null), W6(t);
return;
}
if (!t) {
- x9(), o9().openItem(e);
+ b9(), a9().openItem(e);
return;
}
t.el().classList.add("vjs-peach-mini");
@@ -79933,26 +79985,26 @@ async function vWe(e) {
kind: "item",
item: r,
mediaIndex: null,
- key: i9("item", r.id, null),
+ key: r9("item", r.id, null),
meta: o,
off: [],
pending: !1
};
- X7 = i, v9(i);
+ Y7 = i, _9(i);
}
- }), p9(r);
+ }), f9(r);
}
//#endregion
//#region src/react/stage/miniplayer.tsx
-var E9 = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("svg", {
+var T9 = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("svg", {
viewBox: "0 0 24 24",
"aria-hidden": "true",
children: /* @__PURE__ */ (0, z.jsx)("use", { href: `#i-${e}` })
-}), yWe = { __html: "<svg viewBox=\"0 0 24 24\" aria-hidden=\"true\"><use href=\"#i-player-pause\"/></svg>" }, D9 = (e) => (t) => {
+}), xWe = { __html: "<svg viewBox=\"0 0 24 24\" aria-hidden=\"true\"><use href=\"#i-player-pause\"/></svg>" }, E9 = (e) => (t) => {
t.stopPropagation(), e();
-}, bWe = (0, R.memo)(function() {
+}, SWe = (0, R.memo)(function() {
let e = (0, R.useRef)(null), t = (0, R.useRef)(null), n = (0, R.useRef)(null), r = (0, R.useRef)(null), i = (0, R.useRef)(null), a = (0, R.useRef)(null), o = (0, R.useRef)(null), s = (0, R.useRef)(null), c = (0, R.useRef)(null), l = (0, R.useRef)(null);
- return (0, R.useLayoutEffect)(() => (u9({
+ return (0, R.useLayoutEffect)(() => (l9({
root: e.current,
frame: n.current,
play: r.current,
@@ -79962,7 +80014,7 @@ var E9 = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("svg", {
title: s.current,
sub: c.current,
info: l.current
- }), () => u9(null)), []), (0, R.useEffect)(() => SWe(e.current, t.current), []), /* @__PURE__ */ (0, z.jsx)("aside", {
+ }), () => l9(null)), []), (0, R.useEffect)(() => wWe(e.current, t.current), []), /* @__PURE__ */ (0, z.jsx)("aside", {
ref: e,
"data-miniplayer": "",
id: "miniplayer",
@@ -79986,24 +80038,24 @@ var E9 = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("svg", {
id: "miniplayerExpand",
"aria-label": "展开到详情",
"aria-keyshortcuts": "i",
- onClick: D9(S9),
- children: /* @__PURE__ */ (0, z.jsx)(E9, { name: "maximize-2" })
+ onClick: E9(x9),
+ children: /* @__PURE__ */ (0, z.jsx)(T9, { name: "maximize-2" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
type: "button",
"data-miniplayer-button": "close",
id: "miniplayerClose",
"aria-label": "关闭小窗",
- onClick: D9(x9),
- children: /* @__PURE__ */ (0, z.jsx)(E9, { name: "x" })
+ onClick: E9(b9),
+ children: /* @__PURE__ */ (0, z.jsx)(T9, { name: "x" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
ref: a,
type: "button",
"data-miniplayer-seek": "",
id: "miniplayerBack",
- onClick: D9(() => w9(-1)),
- children: /* @__PURE__ */ (0, z.jsx)(E9, { name: "rotate-ccw" })
+ onClick: E9(() => C9(-1)),
+ children: /* @__PURE__ */ (0, z.jsx)(T9, { name: "rotate-ccw" })
}),
/* @__PURE__ */ (0, z.jsx)("button", {
ref: r,
@@ -80012,16 +80064,16 @@ var E9 = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("svg", {
id: "miniplayerPlay",
"aria-label": "暂停",
"aria-keyshortcuts": "k",
- onClick: D9(_We),
- dangerouslySetInnerHTML: yWe
+ onClick: E9(yWe),
+ dangerouslySetInnerHTML: xWe
}),
/* @__PURE__ */ (0, z.jsx)("button", {
ref: o,
type: "button",
"data-miniplayer-seek": "",
id: "miniplayerAhead",
- onClick: D9(() => w9(1)),
- children: /* @__PURE__ */ (0, z.jsx)(E9, { name: "rotate-cw" })
+ onClick: E9(() => C9(1)),
+ children: /* @__PURE__ */ (0, z.jsx)(T9, { name: "rotate-cw" })
}),
/* @__PURE__ */ (0, z.jsx)("span", {
ref: i,
@@ -80038,7 +80090,7 @@ var E9 = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("svg", {
"data-miniplayer-info": "",
id: "miniplayerInfo",
"aria-label": "展开到详情",
- onClick: () => S9(),
+ onClick: () => x9(),
children: [/* @__PURE__ */ (0, z.jsx)("span", {
ref: s,
"data-miniplayer-title": "",
@@ -80052,7 +80104,7 @@ var E9 = ({ name: e }) => /* @__PURE__ */ (0, z.jsx)("svg", {
})
});
});
-function xWe(e, t, n) {
+function CWe(e, t, n) {
let r = e.getBoundingClientRect(), i = (r.top + r.height / 2 < innerHeight / 2 ? "t" : "b") + (r.left + r.width / 2 < innerWidth / 2 ? "l" : "r"), a = parseFloat(getComputedStyle(document.documentElement).getPropertyValue("--topH")) || 56, o = {
left: r.left - t,
top: r.top - n
@@ -80074,7 +80126,7 @@ function xWe(e, t, n) {
};
e.addEventListener("transitionend", u), setTimeout(u, 600);
}
-function SWe(e, t) {
+function wWe(e, t) {
let n = null, r = (e) => {
if (!(e.button !== 0 || e.target.closest("[data-miniplayer-button],[data-miniplayer-play],[data-miniplayer-seek],.vjs-control-bar"))) {
n = {
@@ -80100,7 +80152,7 @@ function SWe(e, t) {
} catch {}
i.moved && (e.dataset.dragged = "1", setTimeout(() => {
delete e.dataset.dragged;
- }, 0), xWe(e, i.dx, i.dy));
+ }, 0), CWe(e, i.dx, i.dy));
}, o = (t) => {
e.dataset.dragged && (t.stopPropagation(), t.preventDefault());
}, s = (e) => {
@@ -80112,37 +80164,37 @@ function SWe(e, t) {
}
//#endregion
//#region src/react/stage/stage.tsx
-var O9 = null, k9 = null, A9 = null, j9 = null, M9 = 0, N9 = null, P9 = !1, F9 = !1, I9 = () => {
+var D9 = null, O9 = null, k9 = null, A9 = null, j9 = 0, M9 = null, N9 = !1, P9 = !1, F9 = () => {
let e = document.getElementById("stage");
return e instanceof HTMLDialogElement ? e : null;
};
-function L9() {
- if (!O9) throw Error("舞台还没有接上宿主(configureStage)");
- return O9;
+function I9() {
+ if (!D9) throw Error("舞台还没有接上宿主(configureStage)");
+ return D9;
}
-function CWe() {
- return (!k9 || !A9?.isConnected) && (k9?.unmount(), A9 = document.createElement("div"), A9.dataset.stageHost = "", document.body.append(A9), k9 = (0, Be.createRoot)(A9)), k9;
+function TWe() {
+ return (!O9 || !k9?.isConnected) && (O9?.unmount(), k9 = document.createElement("div"), k9.dataset.stageHost = "", document.body.append(k9), O9 = (0, Be.createRoot)(k9)), O9;
}
-function R9() {
- let e = CWe();
- (0, ze.flushSync)(() => e.render(/* @__PURE__ */ (0, z.jsx)(IF, { children: /* @__PURE__ */ (0, z.jsx)(wWe, { view: j9 }) })));
+function L9() {
+ let e = TWe();
+ (0, ze.flushSync)(() => e.render(/* @__PURE__ */ (0, z.jsx)(LF, { children: /* @__PURE__ */ (0, z.jsx)(EWe, { view: A9 }) })));
}
-function wWe({ view: e }) {
- return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [e ? /* @__PURE__ */ (0, z.jsx)(TWe, { view: e }, e.generation) : null, /* @__PURE__ */ (0, z.jsx)(bWe, {})] });
+function EWe({ view: e }) {
+ return /* @__PURE__ */ (0, z.jsxs)(z.Fragment, { children: [e ? /* @__PURE__ */ (0, z.jsx)(B9, { view: e }, e.generation) : null, /* @__PURE__ */ (0, z.jsx)(SWe, {})] });
}
-var z9 = () => /* @__PURE__ */ (0, z.jsx)("div", {
+var R9 = () => /* @__PURE__ */ (0, z.jsx)("div", {
"data-skeleton": "detail",
role: "status",
"aria-label": "正在读取作品详情",
- dangerouslySetInnerHTML: { __html: dUe() }
+ dangerouslySetInnerHTML: { __html: pUe() }
});
-function B9(e) {
+function z9(e) {
let t = e.currentTarget;
if (e.target !== t) return !1;
let n = t.getBoundingClientRect();
return e.clientX < n.left || e.clientX > n.right || e.clientY < n.top || e.clientY > n.bottom;
}
-function TWe({ view: e }) {
+function B9({ view: e }) {
let t = (0, R.useRef)(null);
(0, R.useLayoutEffect)(() => {
let e = t.current, n = (e) => {
@@ -80150,7 +80202,7 @@ function TWe({ view: e }) {
};
return e.addEventListener("cancel", n), () => e.removeEventListener("cancel", n);
}, []);
- let { phase: n, content: r } = e, i = r.kind === "item" ? /* @__PURE__ */ (0, z.jsx)(WUe, { ...r.props }) : /* @__PURE__ */ (0, z.jsx)(MUe, { ...r.props });
+ let { phase: n, content: r } = e, i = r.kind === "item" ? /* @__PURE__ */ (0, z.jsx)(KUe, { ...r.props }) : /* @__PURE__ */ (0, z.jsx)(PUe, { ...r.props });
return /* @__PURE__ */ (0, z.jsxs)("dialog", {
ref: t,
id: "stage",
@@ -80160,17 +80212,17 @@ function TWe({ view: e }) {
e.key !== "Escape" || e.defaultPrevented || (e.preventDefault(), V9());
},
onPointerDown: (e) => {
- F9 = B9(e);
+ P9 = z9(e);
},
onClick: (e) => {
- F9 && B9(e) && V9();
+ P9 && z9(e) && V9();
},
children: [
- n === "skeleton" ? /* @__PURE__ */ (0, z.jsx)(z9, {}, "skeleton") : null,
+ n === "skeleton" ? /* @__PURE__ */ (0, z.jsx)(R9, {}, "skeleton") : null,
n === "reveal" ? /* @__PURE__ */ (0, z.jsx)("div", {
"data-stage-fade": "",
"aria-hidden": "true",
- children: /* @__PURE__ */ (0, z.jsx)(z9, {})
+ children: /* @__PURE__ */ (0, z.jsx)(R9, {})
}, "fade") : null,
n === "skeleton" ? null : /* @__PURE__ */ (0, z.jsx)("div", {
"data-stage-scroll": "",
@@ -80183,31 +80235,31 @@ function TWe({ view: e }) {
});
}
function V9() {
- !j9 || P9 || (P9 = !0, j9.request.actions.close());
+ !A9 || N9 || (N9 = !0, A9.request.actions.close());
}
function H9(e, t) {
- let n = I9();
+ let n = F9();
n?.toggleAttribute("data-ambient", e), n?.toggleAttribute("data-theater", t);
}
-function EWe(e) {
+function DWe(e) {
let t = e.resume ?? null, n = (n) => {
let r = t && (e.id == null || e.id === n) ? t : null;
return t = null, r;
- }, r = () => L9().player.settings();
+ }, r = () => I9().player.settings();
if (e.kind === "item") {
let { kind: t, resume: i, actions: a, ...o } = e, s = {
...a,
close: V9,
present: (e, t) => {
let n = e.performers;
- s9({
+ o9({
kind: "item",
item: e,
title: String(e.title || e.name || ""),
sub: String(n?.[0] || e.creator || "未归属")
}), H9(r().ambientMode, r().theaterMode), a.present(e, t);
},
- mountPlayer: (e, t, r, i) => c9(e, {
+ mountPlayer: (e, t, r, i) => s9(e, {
kind: "item",
item: t,
autoplay: i?.autoplay,
@@ -80227,14 +80279,14 @@ function EWe(e) {
...o,
close: V9,
present: (e, t) => {
- s9({
+ o9({
kind: "follow",
item: e,
title: e.title || "",
sub: e.author || e.source_label || ""
}), H9(t === "video" && r().ambientMode, t === "video" && r().theaterMode), o.present(e, t);
},
- mountPlayer: (e, t, r, i) => c9(e, {
+ mountPlayer: (e, t, r, i) => s9(e, {
kind: "follow",
item: t,
media: r,
@@ -80251,48 +80303,48 @@ function EWe(e) {
}
};
}
-function DWe(e, t) {
+function OWe(e, t) {
let n = e.querySelector(":scope > [data-stage-fade]");
e.setAttribute("data-stage-reveal", ""), e.getBoundingClientRect(), e.setAttribute("data-stage-revealing", "");
let r = 0, i = () => {
- clearTimeout(r), n?.removeEventListener("transitionend", a), e.removeAttribute("data-stage-reveal"), e.removeAttribute("data-stage-revealing"), j9?.generation === t && j9.phase === "reveal" && (j9 = {
- ...j9,
+ clearTimeout(r), n?.removeEventListener("transitionend", a), e.removeAttribute("data-stage-reveal"), e.removeAttribute("data-stage-revealing"), A9?.generation === t && A9.phase === "reveal" && (A9 = {
+ ...A9,
phase: "content"
- }, R9());
+ }, L9());
}, a = (e) => {
e.target === n && i();
};
n?.addEventListener("transitionend", a), r = window.setTimeout(i, 1e3);
}
-async function OWe(e) {
- j9 && U9({ miniplayer: !1 });
- let t = ++M9, n = new AbortController();
- N9 = n, P9 = !1, F9 = !1, fWe(e.kind, e.id ?? NaN), j9 = {
+async function kWe(e) {
+ A9 && U9({ miniplayer: !1 });
+ let t = ++j9, n = new AbortController();
+ M9 = n, N9 = !1, P9 = !1, mWe(e.kind, e.id ?? NaN), A9 = {
generation: t,
request: e,
- content: EWe(e),
+ content: DWe(e),
phase: "skeleton"
- }, R9();
- let r = I9();
+ }, L9();
+ let r = F9();
if (!r) return;
w(r), document.body.setAttribute("data-detail-open", ""), r.open || r.showModal();
- let i = j9.content;
+ let i = A9.content;
try {
- i.kind === "item" ? await cVe(i.props, n.signal) : await hUe(i.props, n.signal);
+ i.kind === "item" ? await uVe(i.props, n.signal) : await _Ue(i.props, n.signal);
} catch {
if (n.signal.aborted) return;
}
- if (t !== M9 || !j9) return;
+ if (t !== j9 || !A9) return;
let a = !!r.querySelector(".skeleton-awaiting");
- j9 = {
- ...j9,
+ A9 = {
+ ...A9,
phase: a ? "content" : "reveal"
- }, R9(), a || DWe(r, t), ee(r, ":scope>:not([data-stage-fade]) [data-reveal-line]");
+ }, L9(), a || OWe(r, t), ee(r, ":scope>:not([data-stage-fade]) [data-reveal-line]");
let o = document.activeElement;
(o === r || !r.contains(o)) && r.querySelector("#closeStage")?.focus();
}
-function kWe() {
- let e = I9();
+function AWe() {
+ let e = F9();
return !e?.open || e.hasAttribute("data-closing") || matchMedia("(prefers-reduced-motion: reduce)").matches ? Promise.resolve() : (e.setAttribute("data-closing", ""), new Promise((t) => {
let n = 0, r = () => {
clearTimeout(n), e.removeEventListener("animationend", i), t();
@@ -80303,76 +80355,76 @@ function kWe() {
}));
}
function U9({ miniplayer: e = !0 } = {}) {
- if (M9++, N9?.abort(), N9 = null, dWe(e), !j9) return;
- let t = I9();
- t && L9().release(t), T6(), t?.open && t.close(), j9 = null, P9 = !1, F9 = !1, R9(), s9(null), document.body.removeAttribute("data-detail-open");
+ if (j9++, M9?.abort(), M9 = null, pWe(e), !A9) return;
+ let t = F9();
+ t && I9().release(t), w6(), t?.open && t.close(), A9 = null, N9 = !1, P9 = !1, L9(), o9(null), document.body.removeAttribute("data-detail-open");
}
-function AWe(e) {
- !j9 || j9.content.kind !== "item" || (j9 = {
- ...j9,
+function jWe(e) {
+ !A9 || A9.content.kind !== "item" || (A9 = {
+ ...A9,
content: {
kind: "item",
props: {
- ...j9.content.props,
+ ...A9.content.props,
...e
}
}
- }, R9());
+ }, L9());
}
-function jWe() {
- let e = lWe(), t = e?.kind === "item" ? e.item : null, n = t ? L9().player.posterUrl(t) : "";
+function MWe() {
+ let e = dWe(), t = e?.kind === "item" ? e.item : null, n = t ? I9().player.posterUrl(t) : "";
if (!n) return;
- let r = l9();
+ let r = c9();
r ? r.poster(n) : document.getElementById("vid")?.setAttribute("poster", n);
}
-var MWe = {
- open: OWe,
- update: AWe,
- exit: kWe,
+var NWe = {
+ open: kWe,
+ update: jWe,
+ exit: AWe,
dispose: U9,
requestClose: V9,
- repaintPoster: jWe,
- isOpen: () => !!j9,
- activeVideo: () => mWe(),
+ repaintPoster: MWe,
+ isOpen: () => !!A9,
+ activeVideo: () => gWe(),
toggleTheater: () => {
- j9 && W6(!L9().player.settings().theaterMode);
+ A9 && U6(!I9().player.settings().theaterMode);
},
- toggleMiniplayer: () => C9(),
- closeMiniplayer: () => x9(),
- miniplayerActive: () => d9(),
- miniplayerTakesCard: (e) => T9(e),
+ toggleMiniplayer: () => S9(),
+ closeMiniplayer: () => b9(),
+ miniplayerActive: () => u9(),
+ miniplayerTakesCard: (e) => w9(e),
miniplayerPlay: (e) => {
- vWe(e);
+ bWe(e);
}
};
-function NWe(e) {
- return O9 = e, cWe(e, {
- isOpen: () => !!j9,
+function PWe(e) {
+ return D9 = e, uWe(e, {
+ isOpen: () => !!A9,
requestClose: V9
- }), R9(), MWe;
+ }), L9(), NWe;
}
//#endregion
//#region node_modules/sonner/dist/index.mjs
-function PWe(e) {
+function FWe(e) {
if (!e || typeof document > "u") return;
let t = document.head || document.getElementsByTagName("head")[0], n = document.createElement("style");
n.type = "text/css", t.appendChild(n), n.styleSheet ? n.styleSheet.cssText = e : n.appendChild(document.createTextNode(e));
}
-var FWe = (e) => {
+var IWe = (e) => {
switch (e) {
- case "success": return RWe;
- case "info": return BWe;
- case "warning": return zWe;
- case "error": return VWe;
+ case "success": return zWe;
+ case "info": return VWe;
+ case "warning": return BWe;
+ case "error": return HWe;
default: return null;
}
-}, IWe = Array(12).fill(0), LWe = ({ visible: e, className: t }) => /*#__PURE__*/ R.createElement("div", {
+}, LWe = Array(12).fill(0), RWe = ({ visible: e, className: t }) => /*#__PURE__*/ R.createElement("div", {
className: ["sonner-loading-wrapper", t].filter(Boolean).join(" "),
"data-visible": e
-}, /*#__PURE__*/ R.createElement("div", { className: "sonner-spinner" }, IWe.map((e, t) => /*#__PURE__*/ R.createElement("div", {
+}, /*#__PURE__*/ R.createElement("div", { className: "sonner-spinner" }, LWe.map((e, t) => /*#__PURE__*/ R.createElement("div", {
className: "sonner-loading-bar",
key: `spinner-bar-${t}`
-})))), RWe = /*#__PURE__*/ R.createElement("svg", {
+})))), zWe = /*#__PURE__*/ R.createElement("svg", {
xmlns: "http://www.w3.org/2000/svg",
viewBox: "0 0 20 20",
fill: "currentColor",
@@ -80383,7 +80435,7 @@ var FWe = (e) => {
fillRule: "evenodd",
d: "M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",
clipRule: "evenodd"
-})), zWe = /*#__PURE__*/ R.createElement("svg", {
+})), BWe = /*#__PURE__*/ R.createElement("svg", {
xmlns: "http://www.w3.org/2000/svg",
viewBox: "0 0 24 24",
fill: "currentColor",
@@ -80394,7 +80446,7 @@ var FWe = (e) => {
fillRule: "evenodd",
d: "M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",
clipRule: "evenodd"
-})), BWe = /*#__PURE__*/ R.createElement("svg", {
+})), VWe = /*#__PURE__*/ R.createElement("svg", {
xmlns: "http://www.w3.org/2000/svg",
viewBox: "0 0 20 20",
fill: "currentColor",
@@ -80405,7 +80457,7 @@ var FWe = (e) => {
fillRule: "evenodd",
d: "M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",
clipRule: "evenodd"
-})), VWe = /*#__PURE__*/ R.createElement("svg", {
+})), HWe = /*#__PURE__*/ R.createElement("svg", {
xmlns: "http://www.w3.org/2000/svg",
viewBox: "0 0 20 20",
fill: "currentColor",
@@ -80416,7 +80468,7 @@ var FWe = (e) => {
fillRule: "evenodd",
d: "M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",
clipRule: "evenodd"
-})), HWe = /*#__PURE__*/ R.createElement("svg", {
+})), UWe = /*#__PURE__*/ R.createElement("svg", {
xmlns: "http://www.w3.org/2000/svg",
width: "12",
height: "12",
@@ -80437,7 +80489,7 @@ var FWe = (e) => {
y1: "6",
x2: "18",
y2: "18"
-})), UWe = () => {
+})), WWe = () => {
let [e, t] = R.useState(document.hidden);
return R.useEffect(() => {
let e = () => {
@@ -80445,7 +80497,7 @@ var FWe = (e) => {
};
return document.addEventListener("visibilitychange", e), () => document.removeEventListener("visibilitychange", e);
}, []), e;
-}, WWe = 1, GWe = 100, W9 = (e) => typeof e?.id == "number" || e?.id?.length > 0 ? e.id : WWe++, G9 = new class {
+}, GWe = 1, KWe = 100, W9 = (e) => typeof e?.id == "number" || e?.id?.length > 0 ? e.id : GWe++, G9 = new class {
constructor() {
this.subscribe = (e) => (this.subscribers.push(e), this.getActiveToasts().forEach((t) => e(t)), () => {
let t = this.subscribers.indexOf(e);
@@ -80455,7 +80507,7 @@ var FWe = (e) => {
}, this.addToast = (e) => {
this.publish(e), this.toasts = [...this.toasts, e], this.trimHistory();
}, this.trimHistory = () => {
- let e = this.toasts.length - GWe;
+ let e = this.toasts.length - KWe;
e <= 0 || (this.toasts = this.toasts.filter((t) => e > 0 && this.dismissedToasts.has(t.id) ? (this.dismissedToasts.delete(t.id), e--, !1) : !0));
}, this.create = (e) => {
let { message: t, ...n } = e, r = W9(e), i = this.pendingDismissals.get(r);
@@ -80533,7 +80585,7 @@ var FWe = (e) => {
type: "default",
message: e
});
- else if (qWe(e) && !e.ok) {
+ else if (JWe(e) && !e.ok) {
i = !1;
let r = typeof t.error == "function" ? await t.error(`HTTP error! status: ${e.status}`) : t.error, a = typeof t.description == "function" ? await t.description(`HTTP error! status: ${e.status}`) : t.description, o = typeof r == "object" && !R.isValidElement(r) ? r : { message: r };
this.create({
@@ -80586,7 +80638,7 @@ var FWe = (e) => {
}), n;
}, this.getActiveToasts = () => this.toasts.filter((e) => !this.dismissedToasts.has(e.id)), this.subscribers = [], this.toasts = [], this.dismissedToasts = /* @__PURE__ */ new Set(), this.pendingDismissals = /* @__PURE__ */ new Map();
}
-}(), KWe = (e, t) => G9.message(e, t), qWe = (e) => e && typeof e == "object" && "ok" in e && typeof e.ok == "boolean" && "status" in e && typeof e.status == "number", K9 = Object.assign(KWe, {
+}(), qWe = (e, t) => G9.message(e, t), JWe = (e) => e && typeof e == "object" && "ok" in e && typeof e.ok == "boolean" && "status" in e && typeof e.status == "number", K9 = Object.assign(qWe, {
success: G9.success,
info: G9.info,
warning: G9.warning,
@@ -80600,20 +80652,20 @@ var FWe = (e) => {
getHistory: () => G9.toasts,
getToasts: () => G9.getActiveToasts()
});
-PWe("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px;flex:1;min-width:0}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--normal-text);background:var(--normal-bg);border:1px solid var(--normal-border);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{-webkit-user-select:none;user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");
+FWe("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px;flex:1;min-width:0}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--normal-text);background:var(--normal-bg);border:1px solid var(--normal-border);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{-webkit-user-select:none;user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");
function q9(e) {
return e.label !== void 0;
}
-var JWe = 3, YWe = "24px", XWe = "16px", J9 = 4e3, ZWe = 356, QWe = 14, $We = 45, eGe = 200;
+var YWe = 3, XWe = "24px", ZWe = "16px", J9 = 4e3, QWe = 356, $We = 14, eGe = 45, tGe = 200;
function Y9(...e) {
return e.filter(Boolean).join(" ");
}
-function tGe(e) {
+function nGe(e) {
let [t, n] = e.split("-"), r = [];
return t && r.push(t), n && r.push(n), r;
}
-var nGe = (e) => {
- let { invert: t, toast: n, unstyled: r, interacting: i, setHeights: a, visibleToasts: o, heights: s, index: c, toasts: l, expanded: u, removeToast: d, defaultRichColors: f, closeButton: p, style: m, cancelButtonStyle: h, actionButtonStyle: g, className: _ = "", descriptionClassName: v = "", duration: y, position: b, gap: x, expandByDefault: S, classNames: C, icons: w, closeButtonAriaLabel: T = "Close toast" } = e, [E, D] = R.useState(null), [O, k] = R.useState(null), [A, j] = R.useState(!1), [M, N] = R.useState(!1), [P, ee] = R.useState(!1), [F, I] = R.useState(!1), [te, ne] = R.useState(!1), [re, ie] = R.useState(0), [ae, oe] = R.useState(0), se = R.useRef(n.duration || y || J9), ce = R.useRef(null), le = R.useRef(null), ue = c === 0, L = c + 1 <= o, de = n.type, fe = de ?? "default", pe = n.dismissible !== !1, me = n.className || "", he = n.descriptionClassName || "", ge = R.useMemo(() => s.findIndex((e) => e.toastId === n.id) || 0, [s, n.id]), _e = R.useMemo(() => n.closeButton ?? p, [n.closeButton, p]), ve = R.useMemo(() => n.duration || y || J9, [n.duration, y]), ye = R.useRef(0), be = R.useRef(0), xe = R.useRef(0), Se = R.useRef(null), [Ce, we] = b.split("-"), Te = R.useMemo(() => s.reduce((e, t, n) => n >= ge ? e : e + t.height, 0), [s, ge]), Ee = UWe(), De = R.useMemo(() => e.swipeDirections ?? tGe(b), [e.swipeDirections, b]), Oe = n.invert || t, ke = de === "loading";
+var rGe = (e) => {
+ let { invert: t, toast: n, unstyled: r, interacting: i, setHeights: a, visibleToasts: o, heights: s, index: c, toasts: l, expanded: u, removeToast: d, defaultRichColors: f, closeButton: p, style: m, cancelButtonStyle: h, actionButtonStyle: g, className: _ = "", descriptionClassName: v = "", duration: y, position: b, gap: x, expandByDefault: S, classNames: C, icons: w, closeButtonAriaLabel: T = "Close toast" } = e, [E, D] = R.useState(null), [O, k] = R.useState(null), [A, j] = R.useState(!1), [M, N] = R.useState(!1), [P, ee] = R.useState(!1), [F, I] = R.useState(!1), [te, ne] = R.useState(!1), [re, ie] = R.useState(0), [ae, oe] = R.useState(0), se = R.useRef(n.duration || y || J9), ce = R.useRef(null), le = R.useRef(null), ue = c === 0, L = c + 1 <= o, de = n.type, fe = de ?? "default", pe = n.dismissible !== !1, me = n.className || "", he = n.descriptionClassName || "", ge = R.useMemo(() => s.findIndex((e) => e.toastId === n.id) || 0, [s, n.id]), _e = R.useMemo(() => n.closeButton ?? p, [n.closeButton, p]), ve = R.useMemo(() => n.duration || y || J9, [n.duration, y]), ye = R.useRef(0), be = R.useRef(0), xe = R.useRef(0), Se = R.useRef(null), [Ce, we] = b.split("-"), Te = R.useMemo(() => s.reduce((e, t, n) => n >= ge ? e : e + t.height, 0), [s, ge]), Ee = WWe(), De = R.useMemo(() => e.swipeDirections ?? nGe(b), [e.swipeDirections, b]), Oe = n.invert || t, ke = de === "loading";
be.current = R.useMemo(() => ge * x + Te, [ge, Te]), R.useEffect(() => {
se.current = ve;
}, [ve]), R.useEffect(() => {
@@ -80654,7 +80706,7 @@ var nGe = (e) => {
let Ae = R.useCallback(() => {
N(!0), ie(be.current), a((e) => e.filter((e) => e.toastId !== n.id)), setTimeout(() => {
d(n);
- }, eGe);
+ }, tGe);
}, [
n,
d,
@@ -80687,12 +80739,12 @@ var nGe = (e) => {
return w?.loading ? /*#__PURE__*/ R.createElement("div", {
className: Y9(C?.loader, n?.classNames?.loader, "sonner-loader"),
"data-visible": de === "loading"
- }, w.loading) : /*#__PURE__*/ R.createElement(LWe, {
+ }, w.loading) : /*#__PURE__*/ R.createElement(RWe, {
className: Y9(C?.loader, n?.classNames?.loader),
visible: de === "loading"
});
}
- let Me = n.icon || w?.[de] || FWe(de);
+ let Me = n.icon || w?.[de] || IWe(de);
return /*#__PURE__*/ R.createElement("li", {
tabIndex: 0,
ref: le,
@@ -80739,7 +80791,7 @@ var nGe = (e) => {
if (F || !pe) return;
Se.current = null;
let e = Number(le.current?.style.getPropertyValue("--swipe-amount-x").replace("px", "") || 0), t = Number(le.current?.style.getPropertyValue("--swipe-amount-y").replace("px", "") || 0), r = (/* @__PURE__ */ new Date()).getTime() - ce.current?.getTime(), i = E === "x" ? e : t, a = Math.abs(i) / r;
- if ((E === "x" ? De.includes(e > 0 ? "right" : "left") : De.includes(t > 0 ? "bottom" : "top")) && (Math.abs(i) >= $We || a > .11)) {
+ if ((E === "x" ? De.includes(e > 0 ? "right" : "left") : De.includes(t > 0 ? "bottom" : "top")) && (Math.abs(i) >= eGe || a > .11)) {
ie(be.current), n.onDismiss == null || n.onDismiss.call(n, n), k(E === "x" ? e > 0 ? "right" : "left" : t > 0 ? "down" : "up"), Ae(), I(!0);
return;
}
@@ -80780,7 +80832,7 @@ var nGe = (e) => {
Ae(), n.onDismiss == null || n.onDismiss.call(n, n);
},
className: Y9(C?.closeButton, n?.classNames?.closeButton)
- }, w?.close ?? HWe) : null, (de || n.icon || n.promise) && n.icon !== null && (w?.[de] !== null || n.icon) ? /*#__PURE__*/ R.createElement("div", {
+ }, w?.close ?? UWe) : null, (de || n.icon || n.promise) && n.icon !== null && (w?.[de] !== null || n.icon) ? /*#__PURE__*/ R.createElement("div", {
"data-icon": "",
className: Y9(C?.icon, n?.classNames?.icon)
}, de === "loading" ? n.icon || je() : n.promise ? je() : null, de === "loading" ? null : Me) : null, /*#__PURE__*/ R.createElement("div", {
@@ -80815,10 +80867,10 @@ function X9() {
let e = document.documentElement.getAttribute("dir");
return e === "auto" || !e ? window.getComputedStyle(document.documentElement).direction : e;
}
-function rGe(e, t) {
+function iGe(e, t) {
let n = {};
return [e, t].forEach((e, t) => {
- let r = t === 1, i = r ? "--mobile-offset" : "--offset", a = r ? XWe : YWe;
+ let r = t === 1, i = r ? "--mobile-offset" : "--offset", a = r ? ZWe : XWe;
function o(e) {
[
"top",
@@ -80839,8 +80891,8 @@ function rGe(e, t) {
}) : o(a);
}), n;
}
-var iGe = /*#__PURE__*/ R.forwardRef(function(e, t) {
- let { id: n, invert: r, position: i = "bottom-right", hotkey: a = ["altKey", "KeyT"], expand: o, closeButton: s, className: c, offset: l, mobileOffset: u, theme: d = "light", richColors: f, duration: p, style: m, visibleToasts: h = JWe, toastOptions: g, dir: _ = X9(), gap: v = QWe, icons: y, customAriaLabel: b, containerAriaLabel: x = "Notifications" } = e, [S, C] = R.useState([]), w = R.useMemo(() => n ? S.filter((e) => e.toasterId === n) : S.filter((e) => !e.toasterId), [S, n]), T = R.useMemo(() => Array.from(new Set([i].concat(w.filter((e) => e.position).map((e) => e.position)))), [w, i]), [E, D] = R.useState([]), [O, k] = R.useState(!1), [A, j] = R.useState(!1), [M, N] = R.useState(d === "system" ? typeof window < "u" && window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light" : d), P = R.useRef(null), ee = a.join("+").replace(/Key/g, "").replace(/Digit/g, ""), F = R.useRef(null), I = R.useRef(!1), te = R.useCallback((e) => {
+var aGe = /*#__PURE__*/ R.forwardRef(function(e, t) {
+ let { id: n, invert: r, position: i = "bottom-right", hotkey: a = ["altKey", "KeyT"], expand: o, closeButton: s, className: c, offset: l, mobileOffset: u, theme: d = "light", richColors: f, duration: p, style: m, visibleToasts: h = YWe, toastOptions: g, dir: _ = X9(), gap: v = $We, icons: y, customAriaLabel: b, containerAriaLabel: x = "Notifications" } = e, [S, C] = R.useState([]), w = R.useMemo(() => n ? S.filter((e) => e.toasterId === n) : S.filter((e) => !e.toasterId), [S, n]), T = R.useMemo(() => Array.from(new Set([i].concat(w.filter((e) => e.position).map((e) => e.position)))), [w, i]), [E, D] = R.useState([]), [O, k] = R.useState(!1), [A, j] = R.useState(!1), [M, N] = R.useState(d === "system" ? typeof window < "u" && window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light" : d), P = R.useRef(null), ee = a.join("+").replace(/Key/g, "").replace(/Digit/g, ""), F = R.useRef(null), I = R.useRef(!1), te = R.useCallback((e) => {
C((t) => (t.find((t) => t.id === e.id)?.delete || G9.dismiss(e.id), t.filter(({ id: t }) => t !== e.id)));
}, []);
return R.useEffect(() => G9.subscribe((e) => {
@@ -80926,10 +80978,10 @@ var iGe = /*#__PURE__*/ R.forwardRef(function(e, t) {
"data-x-position": a,
style: {
"--front-toast-height": `${E[0]?.height || 0}px`,
- "--width": `${ZWe}px`,
+ "--width": `${QWe}px`,
"--gap": `${v}px`,
...m,
- ...rGe(l, u)
+ ...iGe(l, u)
},
onBlur: (e) => {
I.current && !e.currentTarget.contains(e.relatedTarget) && (I.current = !1, F.current &&= (F.current.focus({ preventScroll: !0 }), null));
@@ -80947,7 +80999,7 @@ var iGe = /*#__PURE__*/ R.forwardRef(function(e, t) {
e.target instanceof HTMLElement && e.target.dataset.dismissible === "false" || j(!0);
},
onPointerUp: () => j(!1)
- }, w.filter((e) => !e.position && n === 0 || e.position === t).map((n, i) => /*#__PURE__*/ R.createElement(nGe, {
+ }, w.filter((e) => !e.position && n === 0 || e.position === t).map((n, i) => /*#__PURE__*/ R.createElement(rGe, {
key: n.id,
icons: y,
index: i,
@@ -80981,8 +81033,8 @@ var iGe = /*#__PURE__*/ R.forwardRef(function(e, t) {
"data-toast-glyph": t ? "draw" : "still",
"aria-hidden": "true",
dangerouslySetInnerHTML: { __html: e }
-}), Q9 = !1, aGe = (e, t) => {
- Q9 || (Q9 = !0, (0, Be.createRoot)(e).render(/* @__PURE__ */ (0, z.jsx)(iGe, {
+}), Q9 = !1, oGe = (e, t) => {
+ Q9 || (Q9 = !0, (0, Be.createRoot)(e).render(/* @__PURE__ */ (0, z.jsx)(aGe, {
position: "bottom-right",
closeButton: !0,
gap: 8,
@@ -81003,7 +81055,7 @@ var iGe = /*#__PURE__*/ R.forwardRef(function(e, t) {
error: Z9(t.error, !1)
}
})));
-}, oGe = (e, t) => {
+}, sGe = (e, t) => {
let n = t.alert ? K9.error : K9.success, r = t.action;
n(/* @__PURE__ */ (0, z.jsx)("span", { dangerouslySetInnerHTML: { __html: t.html } }), {
id: e,
@@ -81020,94 +81072,94 @@ var iGe = /*#__PURE__*/ R.forwardRef(function(e, t) {
//#region src/react/entry.tsx
function $9(e) {
return (t, n) => {
- let r = (0, Be.createRoot)(t), i = (t) => r.render(/* @__PURE__ */ (0, z.jsx)(IF, { children: /* @__PURE__ */ (0, z.jsx)(e, { ...t }) }));
+ let r = (0, Be.createRoot)(t), i = (t) => r.render(/* @__PURE__ */ (0, z.jsx)(LF, { children: /* @__PURE__ */ (0, z.jsx)(e, { ...t }) }));
return (0, ze.flushSync)(() => i(n)), {
update: i,
unmount: () => r.unmount()
};
};
}
-var sGe = {
+var cGe = {
activity: {
- prefetch: (e, t) => zy(t),
- mount: $9(hne)
+ prefetch: (e, t) => ane(t),
+ mount: $9(Ene)
},
"catalog-grid": {
- prefetch: Sne,
- mount: $9(Nb)
+ prefetch: Nne,
+ mount: $9(Rb)
},
configuration: {
- prefetch: (e, t) => tI(t),
+ prefetch: (e, t) => nI(t),
mount: $9(h_e)
},
"data-cleanup": {
- prefetch: (e, t) => GS(t),
- mount: $9(Gce)
+ prefetch: (e, t) => wie(t),
+ mount: $9(Zce)
},
duplicates: {
- prefetch: (e, t) => rre(t),
- mount: $9(Qce)
+ prefetch: (e, t) => Qne(t),
+ mount: $9(ole)
},
"catalog-filter": {
prefetch: async () => {},
- mount: $9(cle)
+ mount: $9(gle)
},
"entity-page": {
- prefetch: (e) => Ale(e),
- mount: $9(Jue)
+ prefetch: (e) => Vk(e),
+ mount: $9(xue)
},
"feed-new": {
- prefetch: Tle,
- mount: $9(Que)
+ prefetch: Ek,
+ mount: $9(Tue)
},
"follow-feed": {
- prefetch: Lde,
- mount: $9(sfe)
+ prefetch: ude,
+ mount: $9(Pde)
},
"follow-manage": {
- prefetch: (e, t) => kde(t, e.tab),
- mount: $9(qme)
+ prefetch: (e, t) => nde(t, e.tab),
+ mount: $9(Kme)
},
index: {
- prefetch: (e, t) => Vle(e, t),
- mount: $9(ohe)
+ prefetch: (e, t) => lA(e, t),
+ mount: $9(ahe)
},
"junk-queue": {
prefetch: async () => {},
- mount: $9(xhe)
+ mount: $9(bhe)
},
"library-processing": {
- prefetch: (e, t) => Jb(t),
- mount: $9((e) => e.mode === "notice" ? /* @__PURE__ */ (0, z.jsx)(Dhe, { ...e }) : /* @__PURE__ */ (0, z.jsx)(gO, { ...e }))
+ prefetch: (e, t) => $b(t),
+ mount: $9((e) => e.mode === "notice" ? /* @__PURE__ */ (0, z.jsx)(Ehe, { ...e }) : /* @__PURE__ */ (0, z.jsx)(dO, { ...e }))
},
playlists: {
- prefetch: (e, t) => khe(t),
- mount: $9(Vhe)
+ prefetch: (e, t) => Ohe(t),
+ mount: $9(Bhe)
},
"quality-goals": {
- prefetch: (e, t) => xre(t),
- mount: $9(Uhe)
+ prefetch: (e, t) => gre(t),
+ mount: $9(Hhe)
},
review: {
- prefetch: (e, t) => Hre(t),
- mount: $9(oge)
+ prefetch: (e, t) => Lre(t),
+ mount: $9(age)
},
search: {
prefetch: async () => {},
- mount: $9(_le)
+ mount: $9(fk)
},
scraping: {
- prefetch: (e, t) => pge(t),
- mount: $9(bge)
+ prefetch: (e, t) => fge(t),
+ mount: $9(yge)
},
stats: {
prefetch: (e, t) => __e(t),
- mount: $9(eze)
+ mount: $9(nze)
},
taste: {
- prefetch: (e, t) => wze("all", t),
- mount: $9(wBe)
+ prefetch: (e, t) => Eze("all", t),
+ mount: $9(EBe)
}
};
//#endregion
-export { DBe as configureBatchDock, eHe as configureImmerse, lHe as configureManageHeader, LHe as configureSettingsPanel, QHe as configureSidebar, NWe as configureStage, aGe as mountToaster, sGe as pages, oGe as showToast };
+export { kBe as configureBatchDock, nHe as configureImmerse, dHe as configureManageHeader, zHe as configureSettingsPanel, eUe as configureSidebar, PWe as configureStage, oGe as mountToaster, cGe as pages, sGe as showToast };