feat(settings): add local storage tab to display IndexedDB usage and site quota

This commit is contained in:
HouYunFei
2026-08-06 15:30:46 +08:00
parent a4074f7413
commit c23942ddba
9 changed files with 229 additions and 5 deletions
+19 -2
View File
@@ -357,12 +357,29 @@ export default {
config: {
title: "Settings & Preferences",
invalidFile: "The settings file format is invalid",
description: "Provider aggregation, model selection, and sync preferences",
modalDescription: "Provider aggregation, default models, and sync preferences",
description: "Providers, model selection, sync, and local storage",
modalDescription: "Providers, default models, sync, and local storage",
tabs: {
channels: "Providers",
preferences: "Preferences",
promptSources: "Prompt sources",
localStorage: "Local storage",
},
localStorage: {
title: "IndexedDB storage usage",
description: "View browser data saved by Infinite Canvas, grouped by object store.",
indexedDbUsage: "IndexedDB usage",
siteUsage: "Total site usage",
quota: "Available quota",
contentEstimate: "Estimated from stored content",
siteUsageHint: "Includes IndexedDB and other site data",
quotaHint: "Allocated dynamically by the browser",
quotaProgress: "Site quota usage",
mainDatabase: "Infinite Canvas data",
records: "{{count}} records",
refresh: "Refresh usage",
readFailed: "Failed to read local storage",
stores: { appState: "App state", images: "Image files", media: "Audio and video files", imageLogs: "Image history", videoLogs: "Video history", agentMessages: "Agent messages", promptCache: "Prompt cache" },
},
promptSources: {
add: "Add source",
+19 -2
View File
@@ -357,12 +357,29 @@ export default {
config: {
title: "配置与用户偏好",
invalidFile: "配置文件格式不正确",
description: "渠道聚合、模型选择同步偏好",
modalDescription: "渠道聚合、默认模型同步偏好",
description: "渠道聚合、模型选择同步与本地存储",
modalDescription: "渠道聚合、默认模型同步与本地存储",
tabs: {
channels: "渠道",
preferences: "偏好设置",
promptSources: "提示词来源",
localStorage: "本地存储",
},
localStorage: {
title: "IndexedDB 存储使用情况",
description: "查看 Infinite Canvas 在浏览器中保存的数据量,并按对象仓库统计内容体积。",
indexedDbUsage: "IndexedDB 占用",
siteUsage: "站点总占用",
quota: "可用配额",
contentEstimate: "按仓库内容估算",
siteUsageHint: "包含 IndexedDB 等站点数据",
quotaHint: "由浏览器动态分配",
quotaProgress: "站点配额使用率",
mainDatabase: "Infinite Canvas 主数据",
records: "{{count}} 条",
refresh: "刷新统计",
readFailed: "读取本地存储失败",
stores: { appState: "应用状态", images: "图片文件", media: "音视频文件", imageLogs: "生图记录", videoLogs: "视频记录", agentMessages: "Agent 消息", promptCache: "提示词缓存" },
},
promptSources: {
add: "新增来源",