Skip to content

fix(command-palette): use data-checked for theme selection tick instead of manual icon#827

Open
aihnatiuk wants to merge 1 commit into
crynta:mainfrom
aihnatiuk:fix/command-palette
Open

fix(command-palette): use data-checked for theme selection tick instead of manual icon#827
aihnatiuk wants to merge 1 commit into
crynta:mainfrom
aihnatiuk:fix/command-palette

Conversation

@aihnatiuk

@aihnatiuk aihnatiuk commented Jun 19, 2026

Copy link
Copy Markdown

What

Fix tick icon positioning for the selected theme in the Command Palette.

Why

Theme picker in the Command Palette displays tick for the selected theme in the wrong position. This is caused by a duplicate HugeiconsIcon component that is passed as a child to the CommandItem which has its own tick icon that has 0 opacity in this case. The change is to reuse existing functionality of the CommandItem and to avoid passing extra icon child.

Testing

  • pnpm exec tsc --noEmit clean
  • Manual smoke-test of the affected feature
  • (If you touched src-tauri/) cargo test --locked and cargo clippy --all-targets --locked -- -D warnings clean
  • (If you changed a #[tauri::command] signature) called out below so the FE caller can be updated in lockstep
  • (If UI) tested in pnpm tauri dev
  • Platforms tested: Windows
  • Shells tested (if relevant):

Screenshots / GIFs

Before:
image
After:
image

Summary by CodeRabbit

  • Style
    • Updated the theme selection indicator styling in the command palette for improved visual consistency.

@aihnatiuk aihnatiuk requested a review from crynta as a code owner June 19, 2026 11:05
@coderabbitai

coderabbitai Bot commented Jun 19, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 49ca713d-b2c1-434f-a8d1-6f54821e6527

📥 Commits

Reviewing files that changed from the base of the PR and between 10af844 and be75746.

📒 Files selected for processing (1)
  • src/modules/command-palette/CommandPalette.tsx

📝 Walkthrough

Walkthrough

The active-theme indicator in the command palette's theme list is changed from conditionally rendering a Tick02Icon inside each CommandItem to setting a data-checked attribute on the item element. The Tick02Icon import is removed accordingly.

Changes

Theme Selection Indicator

Layer / File(s) Summary
Theme active state: icon → data-checked attribute
src/modules/command-palette/CommandPalette.tsx
Removes conditional Tick02Icon render inside the theme loop; each CommandItem now receives data-checked={t.id === themeId}. Tick02Icon import is dropped.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~5 minutes

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed Title follows Conventional Commits format (fix scope: component) and accurately summarizes the main change: replacing manual icon rendering with data-checked attribute for theme selection.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Comment @coderabbitai help to get the list of available commands and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant