Add a Copy button to the Diagnostics dialog
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 88/100
- Issue 类型
- 功能
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- html, javascript, rust, tauri
- 领域
- desktop-dev, frontend
调研方向
从 ui/index.html 中 .dialog-actions 内、#diagnostics-save 旁边的 diagnostics-dialog 标记开始,然后查看 ui/main.js 中诊断部分的保存点击处理函数。添加一个 #diagnostics-copy 按钮,调用 navigator.clipboard.writeText 复制 #diagnostics-text 中的文本,并将成功或失败信息写入 #diagnostics-message。完成标准:复制的文本与对话框内容完全一致,能显示确认或错误信息,并且 cargo build --workspace 仍然通过。
由索引模型根据 Issue 内容生成。
描述
The Diagnostics dialog shows a report and has a Save to Documents button. When someone is filling in a bug report it is quicker to copy the text straight to the clipboard.
What to do
Add a Copy button next to Save to Documents that puts the report text on the clipboard and confirms it.
- Markup:
ui/index.html, in<dialog id="diagnostics-dialog">, inside.dialog-actions. Add a<button id="diagnostics-copy" type="button">Copy</button>next to#diagnostics-save. - Behaviour:
ui/main.js, in the "diagnostics" section next to the#diagnostics-saveclick handler. Usenavigator.clipboard.writeText(...)with the text already in#diagnostics-text, and write the outcome into#diagnostics-message(for example "Copied to the clipboard."). - If copying fails, show the reason in the same message line instead of failing silently.
No styling should be needed: buttons inside dialogs are already styled.
Done when
- The button appears in the dialog and copies exactly the text shown.
- A confirmation appears, and an error is shown if the clipboard is unavailable.
cargo build --workspacestill passes (the UI is embedded in the app at build time).
How to try it
npm install, then npm run dev. Click Diagnostics at the bottom left of the window, press Copy, and paste somewhere.
- 主要语言
- Rust
- 星标
- 7
- 派生
- 1
- 平均合并
- 6 小时 34 分钟
- 30 天内合并 PR
- 2
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
CodingRule/Hidely 的其他 Issue
-
accessibility help wanted
难度 2/5 1-3 小时 新手友好度 72/100
CodingRule/Hidely#15 ·
-
compatibility help wanted testing
难度 2/5 1-3 小时 新手友好度 72/100
CodingRule/Hidely#14 ·
-
enhancement good first issue
难度 2/5 1-3 小时 新手友好度 85/100
CodingRule/Hidely#13 ·
-
enhancement good first issue
难度 2/5 1-3 小时 新手友好度 88/100
CodingRule/Hidely#12 ·
-
enhancement good first issue
难度 2/5 1-3 小时 新手友好度 84/100
CodingRule/Hidely#3 ·
查看 CodingRule/Hidely 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 2 天内回复
-
autofixer: follow-up
难度 2/5 1-3 小时 新手友好度 78/100
tursodatabase/turso#12531 ·
维护者通常 1 天内回复
-
bug help wanted ui
难度 2/5 1-3 小时 新手友好度 82/100
userFRM/egui-charts#4292 ·
维护者通常 1 天内回复
-
Issue-Bug Need-Review
难度 1/5 1-3 小时 新手友好度 85/100
PowerShell/DSC#1832 ·
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 1 天内回复