@rigel-cms/rigel 1.0.0 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/docs/extensions.md +194 -0
- package/package.json +15 -3
- package/src/article-body.ts +49 -37
- package/src/article-render.ts +25 -2
- package/src/article.ts +44 -0
- package/src/config.ts +12 -2
- package/src/editor/App.svelte +98 -97
- package/src/editor/blocks/extension.ts +29 -0
- package/src/editor/blocks/index.ts +17 -15
- package/src/editor/blocks/video.ts +2 -1
- package/src/editor/i18n/README.md +23 -0
- package/src/editor/i18n/de/connection.json +136 -0
- package/src/editor/i18n/de/defaults.json +6 -0
- package/src/editor/i18n/de/fields.json +130 -0
- package/src/editor/i18n/de/local.json +49 -0
- package/src/editor/i18n/de/media.json +166 -0
- package/src/editor/i18n/de/richtext.json +116 -0
- package/src/editor/i18n/de/shell.json +181 -0
- package/src/editor/i18n/de/system.json +14 -0
- package/src/editor/i18n/de/validation.json +82 -0
- package/src/editor/i18n/en/connection.json +136 -0
- package/src/editor/i18n/en/defaults.json +6 -0
- package/src/editor/i18n/en/fields.json +130 -0
- package/src/editor/i18n/en/local.json +49 -0
- package/src/editor/i18n/en/media.json +166 -0
- package/src/editor/i18n/en/richtext.json +116 -0
- package/src/editor/i18n/en/shell.json +181 -0
- package/src/editor/i18n/en/system.json +14 -0
- package/src/editor/i18n/en/validation.json +82 -0
- package/src/editor/i18n/es/connection.json +136 -0
- package/src/editor/i18n/es/defaults.json +6 -0
- package/src/editor/i18n/es/fields.json +130 -0
- package/src/editor/i18n/es/local.json +49 -0
- package/src/editor/i18n/es/media.json +166 -0
- package/src/editor/i18n/es/richtext.json +116 -0
- package/src/editor/i18n/es/shell.json +181 -0
- package/src/editor/i18n/es/system.json +14 -0
- package/src/editor/i18n/es/validation.json +82 -0
- package/src/editor/i18n/format.ts +26 -0
- package/src/editor/i18n/fr/connection.json +136 -0
- package/src/editor/i18n/fr/defaults.json +6 -0
- package/src/editor/i18n/fr/fields.json +130 -0
- package/src/editor/i18n/fr/local.json +49 -0
- package/src/editor/i18n/fr/media.json +166 -0
- package/src/editor/i18n/fr/richtext.json +116 -0
- package/src/editor/i18n/fr/shell.json +181 -0
- package/src/editor/i18n/fr/system.json +14 -0
- package/src/editor/i18n/fr/validation.json +82 -0
- package/src/editor/i18n/index.ts +18 -0
- package/src/editor/i18n/it/connection.json +136 -0
- package/src/editor/i18n/it/defaults.json +6 -0
- package/src/editor/i18n/it/fields.json +130 -0
- package/src/editor/i18n/it/local.json +49 -0
- package/src/editor/i18n/it/media.json +166 -0
- package/src/editor/i18n/it/richtext.json +116 -0
- package/src/editor/i18n/it/shell.json +181 -0
- package/src/editor/i18n/it/system.json +14 -0
- package/src/editor/i18n/it/validation.json +82 -0
- package/src/editor/i18n/ja/connection.json +136 -0
- package/src/editor/i18n/ja/defaults.json +6 -0
- package/src/editor/i18n/ja/fields.json +130 -0
- package/src/editor/i18n/ja/local.json +49 -0
- package/src/editor/i18n/ja/media.json +166 -0
- package/src/editor/i18n/ja/richtext.json +116 -0
- package/src/editor/i18n/ja/shell.json +181 -0
- package/src/editor/i18n/ja/system.json +14 -0
- package/src/editor/i18n/ja/validation.json +82 -0
- package/src/editor/i18n/locales.ts +13 -0
- package/src/editor/i18n/nl/connection.json +136 -0
- package/src/editor/i18n/nl/defaults.json +6 -0
- package/src/editor/i18n/nl/fields.json +130 -0
- package/src/editor/i18n/nl/local.json +49 -0
- package/src/editor/i18n/nl/media.json +166 -0
- package/src/editor/i18n/nl/richtext.json +116 -0
- package/src/editor/i18n/nl/shell.json +181 -0
- package/src/editor/i18n/nl/system.json +14 -0
- package/src/editor/i18n/nl/validation.json +82 -0
- package/src/editor/i18n/ru/connection.json +138 -0
- package/src/editor/i18n/ru/defaults.json +6 -0
- package/src/editor/i18n/ru/fields.json +132 -0
- package/src/editor/i18n/ru/local.json +49 -0
- package/src/editor/i18n/ru/media.json +166 -0
- package/src/editor/i18n/ru/richtext.json +116 -0
- package/src/editor/i18n/ru/shell.json +181 -0
- package/src/editor/i18n/ru/system.json +14 -0
- package/src/editor/i18n/ru/validation.json +82 -0
- package/src/editor/i18n/server.ts +13 -0
- package/src/editor/i18n/zh/connection.json +136 -0
- package/src/editor/i18n/zh/defaults.json +6 -0
- package/src/editor/i18n/zh/fields.json +130 -0
- package/src/editor/i18n/zh/local.json +49 -0
- package/src/editor/i18n/zh/media.json +166 -0
- package/src/editor/i18n/zh/richtext.json +116 -0
- package/src/editor/i18n/zh/shell.json +181 -0
- package/src/editor/i18n/zh/system.json +14 -0
- package/src/editor/i18n/zh/validation.json +82 -0
- package/src/editor/lib/ActionDialog.svelte +5 -4
- package/src/editor/lib/BlockEditor.svelte +305 -88
- package/src/editor/lib/CollectionPanel.svelte +17 -15
- package/src/editor/lib/DatePicker.svelte +15 -12
- package/src/editor/lib/ExtensionMount.svelte +12 -0
- package/src/editor/lib/Field.svelte +3 -2
- package/src/editor/lib/ImagePicker.svelte +82 -81
- package/src/editor/lib/MarkdownEditor.svelte +25 -24
- package/src/editor/lib/MediaPicker.svelte +6 -5
- package/src/editor/lib/MenuEditor.svelte +31 -30
- package/src/editor/lib/PreviewFrame.svelte +11 -6
- package/src/editor/lib/PropertiesTabs.svelte +3 -2
- package/src/editor/lib/PublishDialog.svelte +15 -14
- package/src/editor/lib/ReferenceSelect.svelte +3 -2
- package/src/editor/lib/SchemaField.svelte +15 -13
- package/src/editor/lib/SchemaPanel.svelte +20 -19
- package/src/editor/lib/Select.svelte +3 -2
- package/src/editor/lib/SeoGuidance.svelte +6 -5
- package/src/editor/lib/Settings.svelte +54 -54
- package/src/editor/lib/Shortcuts.svelte +7 -6
- package/src/editor/lib/SitePreview.svelte +10 -9
- package/src/editor/lib/TopBar.svelte +18 -17
- package/src/editor/lib/UnsavedChanges.svelte +7 -6
- package/src/editor/lib/VisualEditor.svelte +14 -13
- package/src/editor/lib/calendar.ts +10 -4
- package/src/editor/lib/embed-preview.ts +23 -5
- package/src/editor/lib/extension-preview.ts +121 -0
- package/src/editor/lib/github-auth.ts +23 -22
- package/src/editor/lib/github-backend.ts +96 -91
- package/src/editor/lib/images.ts +33 -31
- package/src/editor/lib/menu-tree.ts +5 -4
- package/src/editor/lib/preview-frame.ts +4 -3
- package/src/editor/lib/schema-edit.ts +3 -2
- package/src/editor/lib/settings.ts +5 -3
- package/src/editor/lib/slash-command.ts +1 -0
- package/src/editor/lib/tooltip.ts +1 -1
- package/src/editor/main.ts +9 -0
- package/src/editor/styles.css +6 -3
- package/src/env.d.ts +11 -1
- package/src/extensions.ts +160 -0
- package/src/manifest/collections.ts +6 -5
- package/src/manifest/menu.ts +12 -10
- package/src/manifest/navigation.ts +9 -8
- package/src/manifest/references.ts +8 -7
- package/src/manifest/seo.ts +4 -3
- package/src/manifest/types.ts +1 -0
- package/src/preview.ts +22 -2
- package/src/routes/local-api.ts +5 -3
- package/src/routes/local-documents.ts +20 -16
- package/src/routes/local-media.ts +21 -16
- package/src/routes/local-menu.ts +9 -7
- package/src/routes/local-post.ts +18 -12
- package/src/routes/media-files.ts +10 -8
- package/src/routes/rigel-page.astro +2 -1
- package/src/schema/store.ts +22 -20
- package/src/schema/types.ts +1 -0
- package/src/schema/validate.ts +73 -69
- package/src/slugs.ts +11 -10
- package/src/vite/manifest-plugin.ts +33 -1
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
{
|
|
2
|
+
"richtext.bold": "加粗",
|
|
3
|
+
"richtext.italic": "斜体",
|
|
4
|
+
"richtext.inlineCode": "行内代码",
|
|
5
|
+
"richtext.strikethrough": "删除线",
|
|
6
|
+
"richtext.underline": "下划线",
|
|
7
|
+
"richtext.highlight": "高亮",
|
|
8
|
+
"richtext.subscript": "下标",
|
|
9
|
+
"richtext.superscript": "上标",
|
|
10
|
+
"richtext.video": "视频",
|
|
11
|
+
"richtext.youtube": "YouTube",
|
|
12
|
+
"richtext.vimeo": "Vimeo",
|
|
13
|
+
"richtext.body": "正文",
|
|
14
|
+
"richtext.loadArticleError": "无法加载文章",
|
|
15
|
+
"richtext.safeUrlError": "请输入安全的 http、https、mailto 或相对 URL。",
|
|
16
|
+
"richtext.link": "链接",
|
|
17
|
+
"richtext.moreFormatting": "更多格式",
|
|
18
|
+
"richtext.tableControls": "表格控件",
|
|
19
|
+
"richtext.addRowBelow": "在下方添加行",
|
|
20
|
+
"richtext.addColumnRight": "在右侧添加列",
|
|
21
|
+
"richtext.removeRow": "删除行",
|
|
22
|
+
"richtext.removeColumn": "删除列",
|
|
23
|
+
"richtext.headerRow": "表头行",
|
|
24
|
+
"richtext.imageEditing": "图片编辑",
|
|
25
|
+
"richtext.bodyFormatting": "正文格式",
|
|
26
|
+
"richtext.editAltText": "编辑替代文本",
|
|
27
|
+
"richtext.editImageLink": "编辑图片链接",
|
|
28
|
+
"richtext.addImageLink": "添加图片链接",
|
|
29
|
+
"richtext.blockType": "区块类型",
|
|
30
|
+
"richtext.replaceImage": "替换图片",
|
|
31
|
+
"richtext.insertMedia": "插入媒体",
|
|
32
|
+
"richtext.table": "表格",
|
|
33
|
+
"richtext.bulletedList": "无序列表",
|
|
34
|
+
"richtext.numberedList": "有序列表",
|
|
35
|
+
"richtext.undo": "撤销",
|
|
36
|
+
"richtext.redo": "重做",
|
|
37
|
+
"richtext.addBlock": "添加区块",
|
|
38
|
+
"richtext.moreActions": "更多操作",
|
|
39
|
+
"richtext.viewAsMarkdown": "以 Markdown 查看",
|
|
40
|
+
"richtext.editLink": "编辑链接",
|
|
41
|
+
"richtext.linkUrl": "链接 URL",
|
|
42
|
+
"richtext.applyLink": "应用链接",
|
|
43
|
+
"richtext.removeLink": "移除链接",
|
|
44
|
+
"richtext.closeLink": "关闭链接编辑",
|
|
45
|
+
"richtext.editImageAltText": "编辑图片替代文本",
|
|
46
|
+
"richtext.decorativeAltText": "替代文本(装饰性图片请留空)",
|
|
47
|
+
"richtext.imageAltText": "图片替代文本",
|
|
48
|
+
"richtext.applyAltText": "应用替代文本",
|
|
49
|
+
"richtext.closeAltText": "关闭替代文本编辑",
|
|
50
|
+
"richtext.selectedTextFormatting": "所选文本格式",
|
|
51
|
+
"richtext.closeMarkdownView": "关闭 Markdown 视图",
|
|
52
|
+
"richtext.bodyAsMarkdown": "Markdown 格式正文",
|
|
53
|
+
"richtext.articleBlocks": "文章区块",
|
|
54
|
+
"richtext.insertParagraphHere": "在此插入段落",
|
|
55
|
+
"richtext.insertParagraph": "插入段落",
|
|
56
|
+
"richtext.blockOptionsHandle": "区块选项和拖动手柄",
|
|
57
|
+
"richtext.dragBlockHint": "拖动以调整顺序;点击查看区块选项",
|
|
58
|
+
"richtext.insertBlock": "插入区块",
|
|
59
|
+
"richtext.chooseBlock": "选择区块",
|
|
60
|
+
"richtext.findBlock": "查找区块",
|
|
61
|
+
"richtext.findBlockPlaceholder": "查找区块…",
|
|
62
|
+
"richtext.noMatchingBlocks": "没有匹配的区块。",
|
|
63
|
+
"richtext.addTable": "添加表格",
|
|
64
|
+
"richtext.blockOptions": "区块选项",
|
|
65
|
+
"richtext.duplicateBlock": "复制区块",
|
|
66
|
+
"richtext.deleteBlock": "删除区块",
|
|
67
|
+
"richtext.moveUp": "上移",
|
|
68
|
+
"richtext.moveDown": "下移",
|
|
69
|
+
"richtext.convertBlockType": "转换区块类型",
|
|
70
|
+
"richtext.code": "代码",
|
|
71
|
+
"richtext.bulletList": "无序列表",
|
|
72
|
+
"richtext.quote": "引用",
|
|
73
|
+
"richtext.unsupportedMarkdown": "此 Markdown 包含可视化编辑器无法安全保留的格式。请在下方编辑原始源码;尚未进行任何转换。",
|
|
74
|
+
"richtext.visual": "可视化",
|
|
75
|
+
"richtext.markdown": "Markdown",
|
|
76
|
+
"richtext.textStyle": "文本样式",
|
|
77
|
+
"richtext.paragraph": "段落",
|
|
78
|
+
"richtext.codeBlock": "代码块",
|
|
79
|
+
"richtext.textFormatting": "文本格式",
|
|
80
|
+
"richtext.listsAndQuote": "列表和引用",
|
|
81
|
+
"richtext.image": "图片",
|
|
82
|
+
"richtext.divider": "分隔线",
|
|
83
|
+
"richtext.pageLoadError": "无法在预览中加载页面。",
|
|
84
|
+
"richtext.liveEditingUnavailable": "此页面未配置实时编辑。更改不会显示在此预览中。",
|
|
85
|
+
"richtext.previewUnavailable": "预览不可用",
|
|
86
|
+
"richtext.previewMode": "预览模式",
|
|
87
|
+
"richtext.browse": "浏览",
|
|
88
|
+
"richtext.edit": "编辑",
|
|
89
|
+
"richtext.editPreviewHint": "点击区域进行编辑。脚本、表单和链接仍处于禁用状态。",
|
|
90
|
+
"richtext.browsePreviewHint": "此预览中已禁用脚本、表单和链接。",
|
|
91
|
+
"richtext.previewOnWebsite": "在网站中预览",
|
|
92
|
+
"richtext.togglePropertiesPanel": "切换属性面板",
|
|
93
|
+
"richtext.newPagePreviewHint": "新页面 — 保存会写入文件。网站获取该文件后,对应路由才会渲染。",
|
|
94
|
+
"richtext.noDocumentPreview": "此文档未映射预览 URL。请使用属性面板编辑。",
|
|
95
|
+
"richtext.websitePageEditor": "网站页面编辑器",
|
|
96
|
+
"richtext.editText": "编辑文本",
|
|
97
|
+
"richtext.propertiesPanelWidth": "属性面板宽度",
|
|
98
|
+
"richtext.preparedPageLoadError": "无法加载已适配的页面。请检查其 URL 及控制框架嵌入的响应头。",
|
|
99
|
+
"richtext.previewTimeout": "预览加载超时。请检查 URL 后重试。",
|
|
100
|
+
"richtext.loadingPreview": "正在加载预览…",
|
|
101
|
+
"richtext.preparedPageUnavailable": "无法加载已适配的页面。",
|
|
102
|
+
"richtext.noPreparedAnchors": "此页面未设置 Rigel 锚点。",
|
|
103
|
+
"richtext.websitePreview": "网站预览",
|
|
104
|
+
"richtext.liveDraftPreview": "网站草稿实时预览",
|
|
105
|
+
"richtext.preparedTemplateHint": "已适配模板 · 已禁用脚本、导航和表单。未设置锚点的字段和列表不会显示在预览中。",
|
|
106
|
+
"richtext.menuPreviewUnsupported": "不支持菜单预览。",
|
|
107
|
+
"richtext.noContentPreview": "此内容未映射已适配的预览 URL。",
|
|
108
|
+
"richtext.previewFetchError": "无法获取草稿预览。请检查 URL、HTTPS、CORS(针对此编辑器的 Access-Control-Allow-Origin)、重定向及编辑器的 connect-src 策略。不会发送身份验证 Cookie。",
|
|
109
|
+
"richtext.previewHtmlError": "草稿预览未返回 HTML。请检查映射的路由及 Content-Type 响应头。",
|
|
110
|
+
"richtext.heading": "{level} 级标题",
|
|
111
|
+
"richtext.editingMode": "{label}编辑模式",
|
|
112
|
+
"richtext.formatting": "{label}格式",
|
|
113
|
+
"richtext.markdownSource": "{label} Markdown 源码",
|
|
114
|
+
"richtext.panelPixels": "{width} 像素",
|
|
115
|
+
"richtext.previewHttpError": "草稿预览返回 HTTP {status}。请检查草稿部署及映射的路由。"
|
|
116
|
+
}
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
{
|
|
2
|
+
"shell.search": "搜索",
|
|
3
|
+
"shell.searchShortcut": "⌘/Ctrl + K",
|
|
4
|
+
"shell.closeDialog": "关闭对话框",
|
|
5
|
+
"shell.escapeKey": "Esc",
|
|
6
|
+
"shell.escapeKeyLowercase": "esc",
|
|
7
|
+
"shell.keyboardShortcuts": "键盘快捷键",
|
|
8
|
+
"shell.keyboardShortcutsMenu": "键盘快捷键",
|
|
9
|
+
"shell.page": "页面",
|
|
10
|
+
"shell.collection": "集合",
|
|
11
|
+
"shell.menus": "菜单",
|
|
12
|
+
"shell.searchItemHint": "{name} · {slug}",
|
|
13
|
+
"shell.searchMenuHint": "菜单 · {slug}",
|
|
14
|
+
"shell.searchContent": "搜索内容",
|
|
15
|
+
"shell.searchContentTooltip": "搜索内容 (⌘K)",
|
|
16
|
+
"shell.searchPlaceholder": "搜索…",
|
|
17
|
+
"shell.searchPagesCollectionsPosts": "搜索页面、集合和文章",
|
|
18
|
+
"shell.searchPagesCollectionsPostsPlaceholder": "搜索页面、集合和文章…",
|
|
19
|
+
"shell.searchResults": "搜索结果",
|
|
20
|
+
"shell.noResults": "无结果",
|
|
21
|
+
"shell.searchNavigate": "切换",
|
|
22
|
+
"shell.searchOpen": "打开",
|
|
23
|
+
"shell.searchClose": "关闭",
|
|
24
|
+
"shell.appearance": "外观",
|
|
25
|
+
"shell.editor": "编辑器",
|
|
26
|
+
"shell.connection": "连接",
|
|
27
|
+
"shell.media": "媒体",
|
|
28
|
+
"shell.language": "语言",
|
|
29
|
+
"shell.advanced": "高级",
|
|
30
|
+
"shell.apiKeysStorageError": "无法在此浏览器中保存 API 密钥。请允许浏览器存储数据后重试。",
|
|
31
|
+
"shell.settings": "设置",
|
|
32
|
+
"shell.close": "关闭",
|
|
33
|
+
"shell.theme": "主题",
|
|
34
|
+
"shell.themeSystem": "跟随系统",
|
|
35
|
+
"shell.themeLight": "浅色",
|
|
36
|
+
"shell.themeDark": "深色",
|
|
37
|
+
"shell.accessibility": "无障碍",
|
|
38
|
+
"shell.highContrastMode": "高对比度模式",
|
|
39
|
+
"shell.highContrastHint": "增强浅色和深色主题中的文字和边框对比度。",
|
|
40
|
+
"shell.editorExperience": "编辑体验",
|
|
41
|
+
"shell.articleBodyEditing": "文章正文编辑",
|
|
42
|
+
"shell.sidebar": "侧边栏",
|
|
43
|
+
"shell.inlinePreview": "行内预览",
|
|
44
|
+
"shell.editorExperienceHint": "行内预览让你点击文章正文,直接在页面上编辑。其他字段仍在侧边栏中。此偏好设置保存在当前浏览器中;内容仍需点击“保存”才会保存。",
|
|
45
|
+
"shell.githubAccount": "GitHub 账号",
|
|
46
|
+
"shell.noGithubAccount": "未连接 GitHub 账号。",
|
|
47
|
+
"shell.repository": "仓库",
|
|
48
|
+
"shell.editingBranch": "编辑分支",
|
|
49
|
+
"shell.publishingBranch": "发布分支",
|
|
50
|
+
"shell.localMode": "本地模式",
|
|
51
|
+
"shell.localModeHint": "未连接 GitHub 账号。点击“保存”时,内容会保存到本地文件。",
|
|
52
|
+
"shell.stockPhotoApiKeys": "图库服务 API 密钥",
|
|
53
|
+
"shell.stockPhotoApiKeysHint": "管理图库服务的 API 密钥。密钥会自动保存,且仅保存在当前浏览器中。",
|
|
54
|
+
"shell.providerAccessKey": "{name} 访问密钥",
|
|
55
|
+
"shell.providerApiKey": "{name} API 密钥",
|
|
56
|
+
"shell.getAccessKey": "获取访问密钥",
|
|
57
|
+
"shell.getApiKey": "获取 API 密钥",
|
|
58
|
+
"shell.hideKey": "隐藏 {name}",
|
|
59
|
+
"shell.showKey": "显示 {name}",
|
|
60
|
+
"shell.keyFormatError": "请检查 {name} 的格式。",
|
|
61
|
+
"shell.editorInterfaceLanguage": "编辑器界面语言",
|
|
62
|
+
|
|
63
|
+
"shell.developerMode": "开发者模式",
|
|
64
|
+
"shell.enableDevMode": "启用开发者模式",
|
|
65
|
+
"shell.devModeHint": "显示当前草稿的原始 JSON,并在标签旁显示字段键名。",
|
|
66
|
+
"shell.clearData": "清除数据",
|
|
67
|
+
"shell.fileCacheHint": "Rigel 目前不会将文件内容或缩略图存入浏览器的持久缓存。",
|
|
68
|
+
"shell.clearFileCache": "清除文件缓存",
|
|
69
|
+
"shell.eraseAllDataHint": "清除此浏览器中的 Rigel 设置、API 密钥和未保存的草稿。已保存到仓库的文件不受影响。",
|
|
70
|
+
"shell.eraseDataError": "无法清除浏览器数据。请检查浏览器存储权限后重试。",
|
|
71
|
+
"shell.eraseAllData": "清除所有数据",
|
|
72
|
+
"shell.waitForSave": "请等待当前保存操作完成。",
|
|
73
|
+
"shell.publishReviewInactive": "发布审核已失效。请重新连接并再次审核。",
|
|
74
|
+
"shell.saveBeforeReview": "请先保存尚未保存的修改,再审核发布内容。你的修改仍然保留。",
|
|
75
|
+
"shell.reviewError": "无法审核已保存的更改。",
|
|
76
|
+
"shell.draftsSynced": "草稿已同步,尚未发布任何内容。请关闭此对话框,并在发布前重新审核。",
|
|
77
|
+
"shell.publishedToBranch": "已发布到 {name}。你配置的部署流程现在可以开始;网站不会立即上线。草稿分支仍然保留。",
|
|
78
|
+
"shell.publishVerificationError": "无法验证发布结果。请先在 GitHub 上检查,再重试。",
|
|
79
|
+
"shell.configurationLoadError": "无法加载编辑器配置。请重新构建网站后重试。",
|
|
80
|
+
"shell.configurationIncomplete": "编辑器配置不完整。请重新构建网站后重试。",
|
|
81
|
+
"shell.configurationLoadFailed": "无法加载编辑器配置。",
|
|
82
|
+
"shell.waitForGithubVerification": "请等待 GitHub 访问权限验证完成后再保存。",
|
|
83
|
+
"shell.connectBeforeSaving": "请先连接 GitHub 并验证仓库访问权限,再保存。",
|
|
84
|
+
"shell.sessionExpiredRetry": "你的 GitHub 会话已过期。请重新连接 GitHub 后重试。未保存的修改仍然保留。",
|
|
85
|
+
"shell.sessionExpiredCheckAccess": "你的 GitHub 会话已过期。请重新登录以检查仓库访问权限。",
|
|
86
|
+
"shell.githubConnectionError": "无法连接 GitHub。请尝试重新登录。",
|
|
87
|
+
"shell.githubAccessError": "无法检查 GitHub 访问权限。请重试。",
|
|
88
|
+
"shell.selectBeforeSaving": "请先选择内容,再保存。",
|
|
89
|
+
"shell.saveFailedStatus": "保存失败 ({status})",
|
|
90
|
+
"shell.saveChangesError": "无法保存更改",
|
|
91
|
+
"shell.githubUser": "GitHub 用户",
|
|
92
|
+
"shell.localUser": "本地用户",
|
|
93
|
+
"shell.eraseBrowserDataTitle": "清除浏览器数据?",
|
|
94
|
+
"shell.eraseData": "清除数据",
|
|
95
|
+
"shell.eraseBrowserDataDescription": "这会清除此浏览器中的 Rigel 设置、API 密钥、GitHub 登录信息和未保存的草稿。已保存的仓库文件不会改变。编辑器将重新加载。",
|
|
96
|
+
"shell.name": "名称",
|
|
97
|
+
"shell.slug": "路径标识",
|
|
98
|
+
"shell.title": "标题",
|
|
99
|
+
"shell.category": "分类",
|
|
100
|
+
"shell.allMenus": "所有菜单",
|
|
101
|
+
"shell.documents": "文档",
|
|
102
|
+
"shell.allNamedEntries": "所有{name}",
|
|
103
|
+
"shell.allPages": "所有页面",
|
|
104
|
+
"shell.allEntries": "所有条目",
|
|
105
|
+
"shell.settingsStorageError": "无法在此浏览器中保存设置。请允许浏览器存储数据后重试。",
|
|
106
|
+
"shell.addDocument": "添加{name}",
|
|
107
|
+
"shell.newDocumentDescription": "输入名称,从模板创建草稿。点击“保存”前,不会写入任何内容。",
|
|
108
|
+
"shell.pageName": "页面名称",
|
|
109
|
+
"shell.createDraft": "创建草稿",
|
|
110
|
+
"shell.titleRequired": "请输入包含字母或数字的标题。",
|
|
111
|
+
"shell.slugAlreadyUsed": "路径标识“{slug}”已被其他文档或页面使用。",
|
|
112
|
+
"shell.addToCollection": "添加到{name}",
|
|
113
|
+
"shell.newPostDescription": "输入标题以创建草稿。点击“保存”前,不会写入任何内容。",
|
|
114
|
+
"shell.deletePostTitle": "删除“{name}”?",
|
|
115
|
+
"shell.delete": "删除",
|
|
116
|
+
"shell.discardNewPostDescription": "这会丢弃新文章及其未保存的修改。",
|
|
117
|
+
"shell.deleteRemotePostDescription": "这会从 {branch} 中删除 {slug}.json,并丢弃所有未保存的修改。此操作无法在编辑器中撤销。",
|
|
118
|
+
"shell.deleteLocalPostDescription": "这会删除 {slug}.json,并丢弃所有未保存的修改。此操作无法在编辑器中撤销。",
|
|
119
|
+
"shell.deleteFailedStatus": "删除失败 ({status})",
|
|
120
|
+
"shell.signedOutAnotherTab": "已在其他标签页中退出登录。请重新连接 GitHub 以保存。未保存的修改仍然保留。",
|
|
121
|
+
"shell.loadingEditor": "正在加载编辑器",
|
|
122
|
+
"shell.connectGithub": "连接 GitHub",
|
|
123
|
+
"shell.retryLoading": "重新加载",
|
|
124
|
+
"shell.loadingConfiguration": "正在加载编辑器配置…",
|
|
125
|
+
"shell.signedInAs": "已以 {name} 的身份登录。",
|
|
126
|
+
"shell.noEditingAccess": "你没有编辑权限。请联系网站管理员。",
|
|
127
|
+
"shell.openingEditor": "正在打开编辑器…",
|
|
128
|
+
"shell.accessConfirmed": "访问权限已确认。请再次尝试打开编辑器。",
|
|
129
|
+
"shell.manageGithubAccess": "管理 GitHub 访问权限",
|
|
130
|
+
"shell.signInHint": "登录以编辑此网站。",
|
|
131
|
+
"shell.checkingAccess": "正在检查访问权限…",
|
|
132
|
+
"shell.openEditor": "打开编辑器",
|
|
133
|
+
"shell.checkAccess": "检查访问权限",
|
|
134
|
+
"shell.signingIn": "正在登录…",
|
|
135
|
+
"shell.signInAgain": "重新登录",
|
|
136
|
+
"shell.signInWithGithub": "使用 GitHub 登录",
|
|
137
|
+
"shell.legalNotice": "继续即表示你同意{terms},并知悉{privacy}。",
|
|
138
|
+
"shell.termsOfUse": "使用条款",
|
|
139
|
+
"shell.privacyPolicy": "隐私政策",
|
|
140
|
+
"shell.welcome": "欢迎",
|
|
141
|
+
"shell.content": "内容",
|
|
142
|
+
"shell.publish": "发布",
|
|
143
|
+
"shell.saveBeforePublishing": "请先保存修改,再发布",
|
|
144
|
+
"shell.publishSavedChanges": "发布分支中已保存的更改",
|
|
145
|
+
"shell.expandSidebar": "展开侧边栏",
|
|
146
|
+
"shell.collapseSidebar": "收起侧边栏",
|
|
147
|
+
"shell.githubUserMenu": "GitHub 用户菜单",
|
|
148
|
+
"shell.localUserMenu": "本地用户菜单",
|
|
149
|
+
"shell.liveSite": "线上网站",
|
|
150
|
+
"shell.configureGithubAccess": "配置 GitHub 访问权限",
|
|
151
|
+
"shell.reconnectGithub": "重新连接 GitHub",
|
|
152
|
+
"shell.signOutTooltip": "退出此编辑器",
|
|
153
|
+
"shell.signOut": "退出登录",
|
|
154
|
+
"shell.githubBackendHint": "后端:github",
|
|
155
|
+
"shell.sessionExpired": "你的 GitHub 会话已过期。未保存的修改仍然保留。",
|
|
156
|
+
"shell.repositoryAccessChanged": "仓库访问权限已变更。请先重新连接 GitHub,再保存。",
|
|
157
|
+
"shell.connecting": "正在连接…",
|
|
158
|
+
"shell.backTo": "← 返回{name}",
|
|
159
|
+
"shell.pages": "页面",
|
|
160
|
+
"shell.saving": "正在保存…",
|
|
161
|
+
"shell.saveFailed": "保存失败",
|
|
162
|
+
"shell.unsaved": "未保存",
|
|
163
|
+
"shell.saved": "已保存",
|
|
164
|
+
"shell.save": "保存",
|
|
165
|
+
"shell.addNew": "新增",
|
|
166
|
+
"shell.deletePost": "删除文章",
|
|
167
|
+
"shell.retrySave": "重新保存",
|
|
168
|
+
"shell.dismissSaveError": "关闭保存错误提示",
|
|
169
|
+
"shell.loading": "正在加载…",
|
|
170
|
+
"shell.draftBadge": "草稿",
|
|
171
|
+
"shell.noEntries": "暂无条目",
|
|
172
|
+
"shell.websiteRoute": "网站路由",
|
|
173
|
+
"shell.notConfigured": "未配置",
|
|
174
|
+
"shell.fixedRouteHint": "此文案页面使用固定的 Astro 路由。只能在网站代码中更改其 URL;修改 slug 元数据无法改变其地址。",
|
|
175
|
+
"shell.welcomeTitle": "欢迎使用 Rigel CMS",
|
|
176
|
+
"shell.welcomeTagline": "全宇宙最棒的 CMS。",
|
|
177
|
+
"shell.welcomeHint": "从侧边栏选择页面或集合,开始编辑。",
|
|
178
|
+
"shell.currentDraft": "当前草稿",
|
|
179
|
+
"shell.editorPreviewWidth": "编辑器与预览宽度",
|
|
180
|
+
"shell.editorWidthPercent": "编辑器宽度 {percent}%"
|
|
181
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
{
|
|
2
|
+
"system.editorTitle": "Rigel — 内容编辑器",
|
|
3
|
+
"system.sidebar.website": "网站",
|
|
4
|
+
"system.sidebar.pages": "页面",
|
|
5
|
+
"system.sidebar.shared": "共享内容",
|
|
6
|
+
"system.sidebar.menus": "菜单",
|
|
7
|
+
"system.sidebar.assets": "资源",
|
|
8
|
+
"system.sidebar.media": "媒体",
|
|
9
|
+
"system.sidebar.more": "更多内容",
|
|
10
|
+
"system.reference.unavailable": "不可用 ({id})",
|
|
11
|
+
"system.reference.expectedMany": "{label}:应为引用数组",
|
|
12
|
+
"system.reference.expectedOne": "{label}:应为单个引用",
|
|
13
|
+
"system.reference.existingOnly": "{label}:只能选择已有条目"
|
|
14
|
+
}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
{
|
|
2
|
+
"validation.body.invalidTree": "文章区块树无效或过大",
|
|
3
|
+
"validation.body.unsupportedBlock": "不支持的文章区块",
|
|
4
|
+
"validation.body.expectedBlock": "应为文章区块",
|
|
5
|
+
"validation.body.nestedTable": "不支持嵌套表格",
|
|
6
|
+
"validation.body.tableStructure": "表格结构无效",
|
|
7
|
+
"validation.body.tableContent": "表格内容无效",
|
|
8
|
+
"validation.body.tableCell": "表格单元格无效或包含不支持的合并单元格",
|
|
9
|
+
"validation.body.tableCellStyles": "不支持自定义表格单元格样式",
|
|
10
|
+
"validation.body.tableDimensions": "表格行列数无效",
|
|
11
|
+
"validation.body.tableColumnWidths": "表格列宽无效",
|
|
12
|
+
"validation.body.listItems": "列表必须包含列表项",
|
|
13
|
+
"validation.body.inlineContent": "应为行内文章内容",
|
|
14
|
+
"validation.body.headingLevel": "请使用 1–6 级标题",
|
|
15
|
+
"validation.body.listType": "不支持的列表类型",
|
|
16
|
+
"validation.body.listStart": "列表起始编号无效",
|
|
17
|
+
"validation.body.invalidText": "文章文本无效",
|
|
18
|
+
"validation.body.textSize": "文章文本过大",
|
|
19
|
+
"validation.body.customStyles": "不支持自定义文章样式",
|
|
20
|
+
"validation.body.imageRequired": "图片必须包含 URL 和替代文本",
|
|
21
|
+
"validation.body.linkRequired": "链接必须包含 URL",
|
|
22
|
+
"validation.body.imageUrl": "图片 URL 不安全",
|
|
23
|
+
"validation.body.imageLinkUrl": "图片链接 URL 不安全",
|
|
24
|
+
"validation.body.linkUrl": "链接 URL 不安全",
|
|
25
|
+
"validation.body.videoUrl": "视频 URL 不安全",
|
|
26
|
+
"validation.body.videoPosterUrl": "视频封面 URL 不安全",
|
|
27
|
+
"validation.body.videoCaption": "视频说明无效",
|
|
28
|
+
"validation.body.videoPlayback": "视频播放设置无效",
|
|
29
|
+
"validation.body.videoEmbed": "视频嵌入内容无效",
|
|
30
|
+
"validation.body.embedTitle": "嵌入内容标题无效",
|
|
31
|
+
"validation.body.imageCredit": "图片署名无效",
|
|
32
|
+
"validation.body.imageCreditUrl": "图片署名 URL 不安全",
|
|
33
|
+
"validation.body.childrenRequired": "文章区块必须包含子节点",
|
|
34
|
+
"validation.body.emptyTable": "表格元素不能为空",
|
|
35
|
+
"validation.body.tableSize": "表格必须为矩形,且最多 50 行、20 列",
|
|
36
|
+
"validation.body.unexpectedChildren": "文章包含不应有的子节点",
|
|
37
|
+
"validation.body.expectedBody": "应为 Lexical 文章正文",
|
|
38
|
+
"validation.slug.required": "URL别名必须包含字母或数字。",
|
|
39
|
+
"validation.slug.invalid": "URL别名无效;请使用小写字母、数字和单个连字符。",
|
|
40
|
+
"validation.slug.duplicate": "URL别名“{slug}”已被使用。",
|
|
41
|
+
"validation.collection.invalid": "文章 frontmatter 无效",
|
|
42
|
+
"validation.collection.required": "{label}:必填",
|
|
43
|
+
"validation.collection.expected": "{label}:应为 {type}",
|
|
44
|
+
"validation.menu.maxDepth": "菜单 maxDepth 必须为 1 至 10 的整数",
|
|
45
|
+
"validation.menu.required": "菜单必须包含由小写字母、数字和连字符组成的 slug、title 和 items 数组",
|
|
46
|
+
"validation.menu.depth": "菜单超出最大层级 {maxDepth}",
|
|
47
|
+
"validation.menu.itemRequired": "菜单项必须包含非空的 id、label、url,以及 children 数组",
|
|
48
|
+
"validation.menu.duplicateId": "菜单项 id 重复:{id}",
|
|
49
|
+
"validation.menu.newTab": "菜单项 newTab 必须为布尔值",
|
|
50
|
+
"validation.menu.unsafeUrl": "菜单 URL 不安全",
|
|
51
|
+
"validation.menu.invalidUrl": "菜单 URL 无效",
|
|
52
|
+
"validation.menu.unsafeProtocol": "菜单 URL 协议不安全",
|
|
53
|
+
"validation.schema.unknownObject": "{path}:未知的对象类型",
|
|
54
|
+
"validation.schema.unknownDocument": "{path}:未知的文档类型",
|
|
55
|
+
"validation.schema.required": "{path}:必填",
|
|
56
|
+
"validation.schema.unsafeKey": "{path}:键 {key} 不安全",
|
|
57
|
+
"validation.schema.object": "{path}:必须为对象",
|
|
58
|
+
"validation.schema.array": "{path}:必须为数组",
|
|
59
|
+
"validation.schema.minItems": "{path}:至少需要 {min} 项",
|
|
60
|
+
"validation.schema.maxItems": "{path}:最多允许 {max} 项",
|
|
61
|
+
"validation.schema.reference": "{path}:必须为引用",
|
|
62
|
+
"validation.schema.section": "{path}:必须为 {name} 区块",
|
|
63
|
+
"validation.schema.scalar": "{path}:必须为 {type}",
|
|
64
|
+
"validation.schema.stableKey": "{path}:必须包含稳定的 _key",
|
|
65
|
+
"validation.schema.duplicateKey": "{path}:_key 重复:{key}",
|
|
66
|
+
"validation.schema.unknownSection": "{path}:未知的区块类型 {type}",
|
|
67
|
+
"validation.schema.arrayItem": "{path}:不匹配任何允许的数组项类型",
|
|
68
|
+
"validation.schema.referenceId": "{path}:引用 id 无效",
|
|
69
|
+
"validation.schema.referenceTarget": "{path}:引用必须指向 {targets}",
|
|
70
|
+
"validation.schema.referenceAlternatives": "{target} 或 {alternatives}",
|
|
71
|
+
"validation.schema.referenceProperty": "{path}:未知的引用属性 {key}",
|
|
72
|
+
"validation.schema.unresolvedTarget": "{path}:无法解析引用目标 {ref}",
|
|
73
|
+
"validation.schema.undeclaredTarget": "{path}:引用目标类型未声明",
|
|
74
|
+
"validation.schema.duplicateDocument": "文档 id 重复:{id}",
|
|
75
|
+
"validation.schema.slug": "{path}:slug 必须由小写字母、数字和单个连字符组成",
|
|
76
|
+
"validation.schema.documentObject": "{path}:文档必须为对象",
|
|
77
|
+
"validation.schema.documentType": "{path}:_type 必须为 {type}",
|
|
78
|
+
"validation.schema.documentId": "{path}:_id 必须为 {id}",
|
|
79
|
+
"validation.schema.selfReference": "{path}:文档不能引用自身",
|
|
80
|
+
"validation.schema.unresolvedReference": "{path}:无法解析引用 {ref}",
|
|
81
|
+
"validation.schema.disallowedReference": "{path}:引用 {ref} 不是允许的目标"
|
|
82
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
|
+
import { t } from "../i18n";
|
|
2
3
|
import Icon from "./Icon.svelte";
|
|
3
4
|
let { title, description, confirmLabel, fieldLabel, danger = false, onconfirm, onclose }: {
|
|
4
5
|
title: string; description: string; confirmLabel: string; fieldLabel?: string; danger?: boolean;
|
|
@@ -20,20 +21,20 @@
|
|
|
20
21
|
busy = true;
|
|
21
22
|
error = "";
|
|
22
23
|
try { await onconfirm(value.trim()); onclose(); }
|
|
23
|
-
catch (cause) { error = cause instanceof Error ? cause.message : "
|
|
24
|
+
catch (cause) { error = cause instanceof Error ? cause.message : $t("connection.actionFailed"); }
|
|
24
25
|
finally { busy = false; }
|
|
25
26
|
}
|
|
26
27
|
</script>
|
|
27
28
|
|
|
28
29
|
<dialog bind:this={dialog} class="rigel rigel-modal-backdrop action-dialog" aria-labelledby="action-title" aria-describedby="action-description" oncancel={(event) => { event.preventDefault(); event.stopPropagation(); if (!busy) onclose(); }} onkeydown={(event) => { if (event.key === "Escape") { event.preventDefault(); event.stopPropagation(); if (!busy) onclose(); } }}>
|
|
29
30
|
<form class="rigel-modal" onsubmit={(event) => { event.preventDefault(); void submit(); }}>
|
|
30
|
-
<div class="action-head"><h2 id="action-title">{title}</h2><button type="button" class="icon-btn" aria-label="
|
|
31
|
+
<div class="action-head"><h2 id="action-title">{title}</h2><button type="button" class="icon-btn" aria-label={$t("connection.cancel")} disabled={busy} onclick={onclose}><Icon name="x" size={16} /></button></div>
|
|
31
32
|
<p id="action-description">{description}</p>
|
|
32
33
|
{#if fieldLabel}<label><span>{fieldLabel}</span><input type="text" bind:this={input} bind:value required disabled={busy} /></label>{/if}
|
|
33
34
|
{#if error}<p class="error" role="alert">{error}</p>{/if}
|
|
34
35
|
<div class="action-actions">
|
|
35
|
-
<button type="button" bind:this={cancel} disabled={busy} onclick={onclose}>
|
|
36
|
-
<button type="submit" class:primary={!danger} class:danger-btn={danger} disabled={busy}>{busy ?
|
|
36
|
+
<button type="button" bind:this={cancel} disabled={busy} onclick={onclose}>{$t("connection.cancel")}</button>
|
|
37
|
+
<button type="submit" class:primary={!danger} class:danger-btn={danger} disabled={busy}>{busy ? $t("connection.working") : confirmLabel}</button>
|
|
37
38
|
</div>
|
|
38
39
|
</form>
|
|
39
40
|
</dialog>
|