From 185d56e2028aee0f96ac4e34f177ba593a0a6f26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9B=B9=E5=BF=97=E9=B9=8F?= Date: Wed, 26 Aug 2026 13:40:13 +0800 Subject: [PATCH] Add dsh-md-export to the file-viewer plugin catalog --- src/client/locales-ja.ts | 1 + src/client/locales.ts | 2 ++ src/client/plugins-viewers.ts | 7 +++++++ 3 files changed, 10 insertions(+) diff --git a/src/client/locales-ja.ts b/src/client/locales-ja.ts index 3b4aab4..d1db24a 100644 --- a/src/client/locales-ja.ts +++ b/src/client/locales-ja.ts @@ -357,6 +357,7 @@ export const ja: Record = { addPluginsEmpty: 'まだプラグインが収録されていません、GitHub topic であなたのプラグインを公開してください', openPlugin: '開く', copyInstall: 'インストールコマンドをコピー', + pluginMdExportDesc: 'better-sidebar の Markdown ツールバーに「エクスポート」ボタンを追加:現在の .md を単体 HTML(テーブル・コードブロック・Mermaid 図表をインライン化、プレビューテーマに追従したレイアウト)にレンダリングして .md と同じディレクトリに保存、または印刷ダイアログ経由で PDF にエクスポート', pluginOfficeDesc: 'better-sidebar エディター向け Office スイートプレビュー(.docx / .xlsx / .pptx)。重い Office レンダリングライブラリをコアバンドルから分離、必要に応じてインストール', pluginFlowglassDesc: 'ライブセッションフローグラフ:ユーザー、アシスタント、ツール呼び出しの 3 レーン泳道、並列グループ、サブエージェント支線、ドリルダウン、ライブ状態をサポート。better-sidebar インストール時にネイティブ「Flowglass」Tab を登録、未インストール時は独立ドロワーを保持', pluginGitForgeDesc: 'better-sidebar「Git Forge」Tab:GitHub/Gitea 等 Forge アカウントライブラリ + プロジェクト単位の認可 + push ポリシー硬核拒絶。token はローカル secrets のみ、モデルコンテキストに入らない。読み取り専用 GitForge ツールと agent HTTPS credential helper を提供', diff --git a/src/client/locales.ts b/src/client/locales.ts index 4edf8a3..b6e357a 100644 --- a/src/client/locales.ts +++ b/src/client/locales.ts @@ -364,6 +364,7 @@ export const zh = { addPluginsEmpty: '暂未收录插件,欢迎在 GitHub topic 下发布你的插件', openPlugin: '跳转', copyInstall: '复制安装命令', + pluginMdExportDesc: '在 better-sidebar 的 Markdown 工具栏上新增「导出」按钮:一键把当前 .md 渲染为独立 HTML(表格/代码块/Mermaid 图表内联,布局跟随预览主题)直接保存到同目录,或通过打印对话框导出为 PDF', pluginOfficeDesc: '为 better-sidebar 编辑器提供 Office 三件套预览(.docx / .xlsx / .pptx),把重型 Office 渲染库拆出主包、按需安装', pluginFlowglassDesc: '实时会话流程图:三列泳道展示用户、助手与工具调用,支持并行分组、子代理支线、逐层钻取和实时状态;安装 better-sidebar 后注册原生「流镜」Tab,未安装时保留独立抽屉', pluginGitForgeDesc: 'better-sidebar「Git 凭据」Tab:GitHub/Gitea 等 Forge 账号库 + 按项目授权 + push 策略硬拦;token 仅存本地 secrets,不进模型上下文;提供只读 GitForge 工具与 agent HTTPS credential helper', @@ -724,6 +725,7 @@ export const en: Record = { addPluginsEmpty: 'No plugins curated yet — publish yours under the GitHub topic', openPlugin: 'Open', copyInstall: 'Copy install command', + pluginMdExportDesc: 'Adds an "Export" button to the Markdown toolbar in better-sidebar: one click renders the current .md into standalone HTML (tables / code blocks / Mermaid diagrams inlined, layout follows the preview theme) and saves it next to the .md, or exports to PDF via the print dialog', pluginOfficeDesc: 'Office-suite preview (.docx / .xlsx / .pptx) for the better-sidebar editor, keeping the heavy Office render libraries out of the core bundle', pluginFlowglassDesc: 'Live session flowgraph with three lanes for user, assistant, and tool calls, plus parallel groups, sub-agent branches, drill-down, and live status; registers a native Flowglass tab when better-sidebar is installed and keeps its standalone drawer as a fallback', pluginGitForgeDesc: 'Git Forge tab: GitHub/Gitea (and other forge) account library + per-project grants + hard push policy; tokens stay in local secrets (never in model context); read-only GitForge tool and agent HTTPS credential helper', diff --git a/src/client/plugins-viewers.ts b/src/client/plugins-viewers.ts index 8fe8706..0add701 100644 --- a/src/client/plugins-viewers.ts +++ b/src/client/plugins-viewers.ts @@ -20,6 +20,13 @@ export const builtinViewerPlugins: readonly PluginEntry[] = [ description: () => t('pluginOfficeDesc'), install: 'cd ~/.dsh && dsh plugin --profile web add @huanlin/dsh-plugin-better-sidebar-plugin-office', }, + { + id: 'dsh-md-export', + name: 'Markdown 导出插件', + url: 'https://github.com/AnakinCao/dsh-md-export', + description: () => t('pluginMdExportDesc'), + install: 'cd ~/.dsh && dsh plugin --profile web add dsh-md-export', + }, { id: 'dsh-video-preview', name: '视频预览插件',