Skip to content

[codex] Add G-Stack skill filter#152

Merged
ryota-murakami merged 2 commits into
mainfrom
codex/add-gstack-filters
May 10, 2026
Merged

[codex] Add G-Stack skill filter#152
ryota-murakami merged 2 commits into
mainfrom
codex/add-gstack-filters

Conversation

@ryota-murakami

@ryota-murakami ryota-murakami commented May 10, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add a G-Stack skill type filter alongside Symlinked, Local, and Orphan in the installed skills agent view.
  • Reuse the same per-agent G-Stack attribution helper for the card badge and the filter so sibling-agent state cannot bleed across rows.
  • Ignore static-storybook/ and make pnpm lint fail on any ESLint warning with --max-warnings 0.
  • Clean up the existing lint warnings that would fail the stricter lint gate.

Validation

  • pnpm exec vitest run --project node src/renderer/src/redux/selectors.test.ts src/renderer/src/components/skills/skillsListHelpers.test.ts src/renderer/src/components/skills/skillItemHelpers.test.ts
  • pnpm exec vitest run --project browser src/renderer/src/components/layout/MainContent.browser.test.tsx
  • pnpm lint
  • pnpm validate
  • /review clean

Summary by CodeRabbit

リリースノート

  • 新機能

    • インストール済みエージェントビューのスキル種別フィルタに「G-Stack」オプションを追加しました。
  • テスト

    • E2Eテストのタイミング信頼性を改善しました。
    • スキルフィルタリング機能のテストカバレッジを拡張しました。
  • その他

    • リント設定を更新し、警告を厳格に管理するようにしました。

Review Change Stack

@vercel

vercel Bot commented May 10, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
skills-desktop Ready Ready Preview, Comment May 10, 2026 2:49pm

Request Review

@coderabbitai

coderabbitai Bot commented May 10, 2026

Copy link
Copy Markdown
Contributor

Warning

Rate limit exceeded

@ryota-murakami has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 33 minutes and 35 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: c22aea56-b36f-4f9c-9e8a-40e928998067

📥 Commits

Reviewing files that changed from the base of the PR and between a70c771 and 9b822f5.

📒 Files selected for processing (4)
  • src/renderer/src/components/layout/MainContent.browser.test.tsx
  • src/renderer/src/components/layout/MainContent.tsx
  • src/renderer/src/styles/globals.css
  • tailwind.config.ts

Walkthrough

This PR adds a "G-Stack" skill-type filter option to the installed agent view. It introduces a centralized isGStackManagedForAgent helper for consistent G-Stack detection across the UI, integrates it into the selector layer, updates the dropdown component, refactors existing badge logic to use the new helper, and adds comprehensive test coverage. Minor e2e fixes and config updates are also included.

Changes

G-Stack Filter Feature

Layer / File(s) Summary
Type Contract
src/renderer/src/redux/slices/uiSlice.ts
SkillTypeFilter union expanded to include 'gstack' option.
G-Stack Detection Utility
src/renderer/src/utils/gstackSkill.ts
New module exports isGStackManagedForAgent helper that detects G-Stack-managed skills by testing symlink paths against skills/gstack pattern, with per-agent eligibility checks.
Selector Integration
src/renderer/src/redux/selectors.ts
selectFilteredSkills adds gstack filtering branch delegating to isGStackManagedForAgent; documentation updated.
UI Dropdown
src/renderer/src/components/layout/MainContent.tsx, src/renderer/src/components/layout/MainContent.browser.test.tsx
Adds gstack option to filter dropdown with label "G-Stack" and bg-sky-400 dot styling; test coverage expanded for G-Stack radio item rendering.
Helper Refactoring
src/renderer/src/components/skills/skillItemHelpers.ts, src/renderer/src/components/skills/skillsListHelpers.ts
Removes inline G-Stack detection logic from skillItemHelpers and uses isGStackManagedForAgent instead; adds SKILL_TYPE_FILTER_LABELS map for human-readable filter names in empty-state messages.
Test Coverage
src/renderer/src/redux/selectors.test.ts, src/renderer/src/components/skills/skillsListHelpers.test.ts
Adds gstack test cases for selector filtering (symlink and local skill paths), agent-scoped filtering regression test, and empty-state message validation.
E2E & Config
e2e/spec/hide-agents.e2e.ts, e2e/spec/regression.e2e.ts, e2e/spec/sync.e2e.ts, package.json, .gitignore
Reorders e2e imports; converts appWindow.evaluate callbacks to async for proper promise handling in RAF-based delays; updates eslint config to fail on warnings (--max-warnings 0); adds static-storybook/ to gitignore.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed PRタイトル「[codex] Add G-Stack skill filter」は、変更セットの主要な目的(Installed agentビューへのG-Stackスキルタイプフィルターの追加)を明確かつ簡潔に説明しており、実装内容と一致している。
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
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.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/add-gstack-filters

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@codecov-commenter

codecov-commenter commented May 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 52.01%. Comparing base (1df5a12) to head (9b822f5).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #152      +/-   ##
==========================================
+ Coverage   51.64%   52.01%   +0.37%     
==========================================
  Files         173      174       +1     
  Lines        4202     4216      +14     
  Branches      892      893       +1     
==========================================
+ Hits         2170     2193      +23     
+ Misses       1843     1831      -12     
- Partials      189      192       +3     
Flag Coverage Δ
unittests 52.01% <100.00%> (+0.37%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ryota-murakami ryota-murakami marked this pull request as ready for review May 10, 2026 12:44
@ryota-murakami

Copy link
Copy Markdown
Contributor Author

@coderabbitai full review

@coderabbitai

coderabbitai Bot commented May 10, 2026

Copy link
Copy Markdown
Contributor
✅ Actions performed

Full review triggered.

@ryota-murakami

Copy link
Copy Markdown
Contributor Author

@coderabbitai full review

@coderabbitai

coderabbitai Bot commented May 10, 2026

Copy link
Copy Markdown
Contributor
✅ Actions performed

Full review triggered.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@src/renderer/src/components/layout/MainContent.tsx`:
- Line 111: Replace the hardcoded Tailwind class "bg-sky-400" used for the
'gstack' dot (in the array entry with value 'gstack' / label 'G-Stack' in
MainContent.tsx) with a semantic theme token/class that derives from your OKLCH
theme axes; add or reuse a semantic token like "bg-dot-gstack" (or a shadcn
token) implemented using the OKLCH formula with --theme-hue and --theme-chroma
(e.g., oklch(... calc(var(--theme-chroma) * K) var(--theme-hue))) in your
CSS/token definitions, then swap dotClass to that token name instead of
"bg-sky-400" so the color follows the OKLCH theme system.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: ac5c78db-7588-42e3-8671-16a67e5766f8

📥 Commits

Reviewing files that changed from the base of the PR and between 1df5a12 and a70c771.

📒 Files selected for processing (14)
  • .gitignore
  • e2e/spec/hide-agents.e2e.ts
  • e2e/spec/regression.e2e.ts
  • e2e/spec/sync.e2e.ts
  • package.json
  • src/renderer/src/components/layout/MainContent.browser.test.tsx
  • src/renderer/src/components/layout/MainContent.tsx
  • src/renderer/src/components/skills/skillItemHelpers.ts
  • src/renderer/src/components/skills/skillsListHelpers.test.ts
  • src/renderer/src/components/skills/skillsListHelpers.ts
  • src/renderer/src/redux/selectors.test.ts
  • src/renderer/src/redux/selectors.ts
  • src/renderer/src/redux/slices/uiSlice.ts
  • src/renderer/src/utils/gstackSkill.ts

Comment thread src/renderer/src/components/layout/MainContent.tsx Outdated
@ryota-murakami ryota-murakami merged commit 49beef4 into main May 10, 2026
9 checks passed
@ryota-murakami ryota-murakami deleted the codex/add-gstack-filters branch May 10, 2026 14:51
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.

2 participants