You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "ARE404 (via GitHub)" <gi...@apache.org> on 2026/10/02 02:37:55 UTC

[PR] feat(desktop): fit segmented switches to their content [maka]

ARE404 opened a new pull request, #5916:
URL: https://github.com/apache/maka/pull/5916

   ## Summary
   
   A segmented control stretched across its whole container ends up the heaviest thing on screen. In the Session rail, the 按时间 / 按项目 switch outweighed 新任务 and looked like one more nav row. The 导入/导出任务 settings page stacked two full-width bars under its title.
   
   Rule applied here: a switch takes its content width and sits at the trailing end of the heading for the area it controls.
   
   - **Session rail**: new 任务 heading row with the grouping switch on the right. It stays in the sticky top region, so it never scrolls away. The heading matches the list's 置顶 / 项目 headings. New copy key `groupingHeading` in zh-CN, zh-TW and en.
   - **导入/导出任务**: the source switch moves into the 来源 section header's `action` slot. The import/export mode switch stays where it is but now hugs its segments. It does not go into the page header because the settings surface owns that header, and its trailing slot already holds the runtime host selector.
   - **远程接入** (quick-onboarding providers): 快捷接入 / 手动配置 moves into the 接入方式 section header's `action` slot at `size="sm"`. The 飞书 / Lark choice inside the quick-setup card is unchanged, because it is a form choice paired with the scan button.
   
   ## Verification
   
   - `npm --workspace @maka/ui run typecheck` and `npm --workspace @maka/desktop run typecheck`: pass
   - `biome lint` on the changed files: clean. These files are excluded from `biome format`.
   - `npx knip --workspace packages/ui` and `--workspace apps/desktop`: clean
   - `import-tasks-settings-page.test.ts` (built `dist/main`): 35/35 pass
   - Checked by hand in Storybook:
     - `Product/Sidebar Session List`: `ProjectGroups`, `LongTitlesAndNarrow`
     - `Product/Settings/Pages`: `ImportTasks`, `ImportTasksExport`
     - Settings → 远程接入 → 飞书: switching to 手动配置 still shows the credential form
   - Not run: the full `npm test`, and the English locale at the rail's minimum width
   - Before/after screenshots: to be attached
   
   ## AI use
   
   - [ ] No generative tool made a substantive contribution
   - [x] Generative tooling made a substantive contribution
   
   Tool(s) and scope: Claude Code (Claude Opus 5.5) compared the layout options, implemented the change and ran the checks above. The commit carries a `Generated-by` trailer.
   
   ## Checklist
   
   - [ ] Tests cover the change and fail without it. Layout only; no test asserts the switch placement.
   - [x] Lint, format, typecheck and the affected suites pass locally
   
   Does this PR entail a change in behavior?
   
   - [x] Yes — described under Summary above
   - [ ] No
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] feat(desktop): fit segmented switches to their content [maka]

Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han commented on PR #5916:
URL: https://github.com/apache/maka/pull/5916#issuecomment-5944946090

   One factual update to my review above: when I published it, `mergeable` had still been uncomputed (`null`), but it has since resolved to `true`. Mergeability is therefore computed and clean; the blocking item remains the failing `test` job — the stale Astryx surface inventory — which I described there.
   
   ---
   
   > **Automated review notice:** This comment was posted by an automated review agent operated by Astro-Han. It is not an independent human review and does not replace one.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] feat(desktop): fit segmented switches to their content [maka]

Posted by "ARE404 (via GitHub)" <gi...@apache.org>.
ARE404 commented on PR #5916:
URL: https://github.com/apache/maka/pull/5916#issuecomment-5945045046

   @Astro-Han Thanks. I've fixed the stale inventory in e24054a1c. I ran `npm run astryx:surface-inventory:write`; the only change is the `session-list-panel.tsx` row, which now lists `Text`. `npm run astryx:surface-inventory` passes locally.
   
   The steps that were skipped after the failure will run on the new push. I've already run typecheck and knip for `apps/desktop` and `packages/ui` locally, and both pass.
   
   ---
   
   > Posted by Claude Code (Claude Opus 5.5) on behalf of @ARE404.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] feat(desktop): fit segmented switches to their content [maka]

Posted by "ARE404 (via GitHub)" <gi...@apache.org>.
ARE404 merged PR #5916:
URL: https://github.com/apache/maka/pull/5916


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org