Enhance workspace features with tabs, editor commands, and Git links#112
Merged
Conversation
复用 reveal 能力,开启后切换标签/打开文件即在文件树展开并滚动到当前文件; 仅当侧栏已打开时触发,避免频繁强开侧栏打扰;偏好持久化到 KV,命令面板可切换。
右键标签可置顶/取消置顶,置顶标签稳定排到最左、显示图钉图标(hover 让位关闭按钮); 关闭其他/关闭右侧均保留置顶标签;置顶状态随会话持久化恢复。
状态栏显示「空格/制表符: N」,点开下拉可切换缩进类型与 Tab 宽度(2/4/8), 即时作用于编辑器并随编辑器配置持久化。
新增后端 git_staged_diff(git diff --cached);有暂存改动且非「提交全部」时, AI 提交信息基于将要提交的暂存 diff 生成,避免描述到未纳入本次提交的改动。
新增后端 git_permalink:基于 origin 远程与当前 HEAD 提交生成永久链接, 支持 GitHub/Gitee(/blob/) 与 GitLab(/-/blob/)、SSH 与 HTTPS 远程; 命令面板「复制远程永久链接(当前行)」一键复制,便于分享到 PR/IM。
原先用固定 190px 估算夹取,菜单项较多时底部仍溢出;改为渲染后测量 getBoundingClientRect 再夹取,保证完整菜单始终落在视口内(留 8px 边距)。
集成 @replit/codemirror-indentation-markers,按缩进层级绘制竖向引导线并高亮当前块; 设置页可开关,配置项前后端同步(config.rs 结构体与默认值、types/app.ts),切换即时生效。
新增「在浏览器打开远程链接(当前行)」(plugin-shell open); 抽出 buildPermalink 复用,复制/打开两路共享;编辑器右键(可 Blame 时)新增复制/打开两项,更易触达。
git_status 已返回的 branch 透传到状态栏,仓库内显示分支名(GitBranch 图标), 点击触发打开 Git 面板,便于快速进入分支/提交操作。
命令面板「文本」分组新增四项:作用于选区,无选区时按整行(大小写)/全文(排序)处理; 均通过 CM 事务改写并保留选区焦点。
「文本」分组新增两项:删除重复行(保留首次出现)、去除行尾空白; 作用于选区,无选区时作用于全文,复用按行范围逻辑。
命令面板「切换专注模式」进入;隐藏顶部 AppHeader、运行输入栏、文件树侧栏与底部状态栏, 仅保留编辑区;右上角浮动「退出专注」按钮可随时退出。
docs.yml 用 pnpm 10,但锁文件原为 pnpm 8 的 6.0 格式,--frozen-lockfile 校验失败; 用 pnpm 10 重建锁文件并通过 frozen 校验。
排序行/大小写/去重/去行尾空白逻辑从 App.vue 移入独立 composable, App.vue 仅保留命令面板调用;零行为变化,-70 行。
copy/open 永久链接(含路径与仓库校验)从 App.vue 移入独立 composable, 内部自取 toast/i18n;App.vue 仅传入 rootDir/currentFilePath/cursorInfo。零行为变化。
revealInTree、自动定位开关与 currentFilePath 监听从 App.vue 移入独立 composable; App.vue 仅传入 currentFilePath/sidebarVisible 并消费返回值。零行为变化。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.