feat(settings): 设置项悬停显示功能说明,降低 Less Computer / 录音胶囊等的理解门槛#777
Open
bigsongeth wants to merge 1 commit into
Open
feat(settings): 设置项悬停显示功能说明,降低 Less Computer / 录音胶囊等的理解门槛#777bigsongeth wants to merge 1 commit into
bigsongeth wants to merge 1 commit into
Conversation
页面瘦身后设置页描述小字全部隐藏,Less Computer、录音胶囊这类光看名字 猜不出用途的功能只剩一个标签,理解成本高。本次把已有的 desc 文案以 Tooltip 形式挂回标签文字上: - Tooltip 新增 wrap 模式,整句说明允许换行(默认 nowrap 不变) - SettingRow 的 desc 恢复生效:悬停标签文字弹出说明,虚线下划线 + help 光标做「可悬停」暗示,布局保持紧凑 - SectionTitle 新增 hint,Less Computer / Claude 控制台 / 录音与输入 三个板块标题接上已有的 desc 文案 - 录音与输入里录音胶囊 / 录音方式 / 首选麦克风 / 录音时静音 / 插入剪贴板等行补传现成的 i18n desc 文案全部复用现有 i18n key,五种语言无需新增翻译。
Contributor
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
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.
User description
问题
设置页「瘦身」后描述小字全部隐藏,Less Computer、录音胶囊这类光看名字猜不出用途的功能只剩一个标签,新用户理解成本高。
方案
把已有的 desc 文案以悬停 Tooltip 的形式挂回标签文字上——布局保持紧凑,可理解性回来了:
wrap模式:整句说明允许换行(默认 nowrap 行为不变,侧栏菜单提示不受影响)desc恢复生效:悬停标签文字弹出说明;带说明的文字加虚线下划线 +cursor: help,暗示「悬停可看解释」hint:Less Computer、Claude 控制台、录音与输入三个板块标题接上已有的 descdesc的行(如快捷键页的 Less Computer 按住说话键)自动获得提示文案全部复用现有 i18n key,五种语言无需新增翻译。
效果
首次悬停 600ms 后出现,沿用 Tooltip 既有的「预热」行为,连续查看多项说明时即时切换。
验证
tsc+vite build通过PR Type
Enhancement
Description
Add Tooltip wrap mode for multiline descriptions
SettingRow and SectionTitle use Tooltip with desc/hint
Apply tooltips to RecordingInput, ClaudeConsole, CodingAgent sections
All descriptions from existing i18n keys, no new translations
File Walkthrough
Tooltip.tsx
Add wrap mode to Tooltipopenless-all/app/src/components/Tooltip.tsx
wrapprop to allow multiline tooltip contentwrapBubbleStylewith normal white-space and max-width:280pxwrapis trueClaudeConsoleSection.tsx
Add hint to ClaudeConsole section titleopenless-all/app/src/pages/settings/ClaudeConsoleSection.tsx
hintprop to SectionTitle with existing desc translationCodingAgentSection.tsx
Add hint to CodingAgent section titleopenless-all/app/src/pages/settings/CodingAgentSection.tsx
hintprop to SectionTitle with existing desc translationRecordingInputSection.tsx
Add tooltips to RecordingInput section itemsopenless-all/app/src/pages/settings/RecordingInputSection.tsx
descprop to multiple SettingRow components (mode, microphone,capsule, etc.)
shared.tsx
Integrate Tooltip into SectionTitle and SettingRowopenless-all/app/src/pages/settings/shared.tsx
hintableTextStylewith dotted underline and help cursordescrendering (now in tooltip)