-
Notifications
You must be signed in to change notification settings - Fork 471
Refactor/code-reivew #7893
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor/code-reivew #7893
Conversation
📝 WalkthroughWalkthroughWarning/warning-icon markup changed from PrimeIcons/gold to Lucide/ Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant User
participant PackEnableToggle as PackEnableToggle (component)
participant ConflictDetector as useConflictDetection
participant DialogRouter as Dialog/DialogService
participant ImportFailedDialog as ImportFailedDialog (UI)
participant ConflictDialog as ConflictDialog (UI)
User->>PackEnableToggle: click enable/install
Note right of PackEnableToggle: gather pack state (versions/conflicts)
PackEnableToggle->>ConflictDetector: detectImportFailConflicts(packInfo)
ConflictDetector-->>PackEnableToggle: conflicts (may include import_failed)
alt contains import_failed
PackEnableToggle->>DialogRouter: open ImportFailedDialog with details
DialogRouter->>ImportFailedDialog: render import_failed info
ImportFailedDialog-->>User: show import failure UI
else other conflicts only
PackEnableToggle->>DialogRouter: open ConflictDialog with conflicts
DialogRouter->>ConflictDialog: render conflict list
ConflictDialog-->>User: show conflict UI
end
Possibly related PRs
📜 Recent review detailsConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro 📒 Files selected for processing (1)
🧰 Additional context used📓 Path-based instructions (9)src/**/*.vue📄 CodeRabbit inference engine (.github/copilot-instructions.md)
Files:
src/**/*.{vue,ts}📄 CodeRabbit inference engine (.github/copilot-instructions.md)
Files:
src/**/*.{ts,tsx,vue}📄 CodeRabbit inference engine (src/CLAUDE.md)
Files:
src/**/{composables,components}/**/*.{ts,tsx,vue}📄 CodeRabbit inference engine (src/CLAUDE.md)
Files:
src/**/*.{vue,ts,tsx}📄 CodeRabbit inference engine (src/CLAUDE.md)
Files:
src/**/{components,composables}/**/*.{ts,tsx,vue}📄 CodeRabbit inference engine (src/CLAUDE.md)
Files:
**/*.vue📄 CodeRabbit inference engine (AGENTS.md)
Files:
**/*.{ts,tsx,vue}📄 CodeRabbit inference engine (AGENTS.md)
Files:
**/*.{ts,tsx,vue,js,jsx,json,css}📄 CodeRabbit inference engine (AGENTS.md)
Files:
🧠 Learnings (17)📓 Common learnings📚 Learning: 2025-11-24T19:47:45.616ZApplied to files:
📚 Learning: 2025-11-24T19:47:45.616ZApplied to files:
📚 Learning: 2025-11-24T19:47:45.616ZApplied to files:
📚 Learning: 2025-12-13T11:03:21.073ZApplied to files:
📚 Learning: 2025-11-24T19:47:45.616ZApplied to files:
📚 Learning: 2025-12-21T06:04:12.562ZApplied to files:
📚 Learning: 2025-11-24T19:47:34.324ZApplied to files:
📚 Learning: 2025-12-09T03:49:52.828ZApplied to files:
📚 Learning: 2025-12-09T21:40:12.361ZApplied to files:
📚 Learning: 2025-12-16T22:26:49.463ZApplied to files:
📚 Learning: 2025-12-22T21:36:08.369ZApplied to files:
📚 Learning: 2026-01-08T02:26:18.357ZApplied to files:
📚 Learning: 2025-12-11T12:25:15.470ZApplied to files:
📚 Learning: 2025-12-18T02:07:38.870ZApplied to files:
📚 Learning: 2025-12-18T21:15:46.862ZApplied to files:
📚 Learning: 2025-12-21T01:06:02.786ZApplied to files:
🔇 Additional comments (2)
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. Comment |
🎨 Storybook Build Status✅ Build completed successfully! ⏰ Completed at: 01/08/2026, 09:30:35 PM UTC 🔗 Links🎉 Your Storybook is ready for review! |
🎭 Playwright Test Results❌ Some tests failed ⏰ Completed at: 01/08/2026, 09:36:05 PM UTC 📈 Summary
📊 Test Reports by Browser
🎉 Click on the links above to view detailed test results for each browser configuration. |
Bundle Size ReportSummary
Category Glance Per-category breakdownApp Entry Points — 3.25 MB (baseline 3.25 MB) • 🟢 -83 BMain entry bundles and manifests
Status: 3 added / 3 removed Graph Workspace — 1.01 MB (baseline 1.01 MB) • 🔴 +13 BGraph editor runtime, canvas, workflow orchestration
Status: 1 added / 1 removed Views & Navigation — 6.63 kB (baseline 6.63 kB) • ⚪ 0 BTop-level views, pages, and routed surfaces
Status: 1 added / 1 removed Panels & Settings — 300 kB (baseline 300 kB) • ⚪ 0 BConfiguration panels, inspectors, and settings screens
Status: 6 added / 6 removed UI Components — 197 kB (baseline 197 kB) • ⚪ 0 BReusable component library chunks
Status: 8 added / 8 removed Data & Services — 12.5 kB (baseline 12.5 kB) • ⚪ 0 BStores, services, APIs, and repositories
Status: 2 added / 2 removed Utilities & Hooks — 1.41 kB (baseline 1.41 kB) • ⚪ 0 BHelpers, composables, and utility bundles
Status: 1 added / 1 removed Vendor & Third-Party — 9.19 MB (baseline 9.19 MB) • ⚪ 0 BExternal libraries and shared vendor chunks
Other — 3.6 MB (baseline 3.6 MB) • ⚪ 0 BBundles that do not match a named category
Status: 16 added / 16 removed |
| > | ||
| <i class="pi pi-exclamation-triangle text-lg text-yellow-600"></i> | ||
| <i | ||
| class="icon-[lucide--triangle-alert] text-lg text-yellow-600" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ha! I beat the rabbit to it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 3
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts (1)
175-198: Critical: Test selector doesn't match component implementation.The test checks for
.pi-exclamation-triangleon lines 195 and 207, butPackEnableToggle.vue(lines 12-14) uses the Lucide icon classicon-[lucide--triangle-alert]. This test will fail.🐛 Proposed fix for icon class selector
it('should show warning icon when package has conflicts', () => { mockGetConflictsForPackageByID.mockReturnValue({ package_id: 'test-pack', package_name: 'Test Pack', has_conflict: true, conflicts: [ { type: 'import_failed', current_value: 'installed', required_value: 'error message' } ], is_compatible: false }) mockIsPackEnabled.mockReturnValue(true) const wrapper = mountComponent() // Check if warning icon exists - const warningIcon = wrapper.find('.pi-exclamation-triangle') + const warningIcon = wrapper.find('.icon-\\[lucide--triangle-alert\\]') expect(warningIcon.exists()).toBe(true) expect(warningIcon.classes()).toContain('text-warning-background') }) it('should not show warning icon when package has no conflicts', () => { mockGetConflictsForPackageByID.mockReturnValue(null) mockIsPackEnabled.mockReturnValue(true) const wrapper = mountComponent() // Check if warning icon does not exist - const warningIcon = wrapper.find('.pi-exclamation-triangle') + const warningIcon = wrapper.find('.icon-\\[lucide--triangle-alert\\]') expect(warningIcon.exists()).toBe(false) })Note: The class selector needs to escape the brackets in the Lucide icon class name.
src/components/topbar/TopbarBadge.test.ts (1)
179-189: Update test to check for Lucide icon class instead of PrimeIcon.The test checks for
.pi-exclamation-triangle(PrimeIcon) on line 188, butTopbarBadge.vueusesicon-[lucide--triangle-alert]for the warning variant. Update the assertion to match the actual icon class rendered by the component.
🤖 Fix all issues with AI agents
In
@src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue:
- Line 39: Fix the import typo by replacing the double-slash module specifier in
the import of useImportFailedDetection (currently
'@//workbench/extensions/manager/composables/useImportFailedDetection') with the
correct single-slash path
('@/workbench/extensions/manager/composables/useImportFailedDetection') so it
matches the project's import pattern.
In
@src/workbench/extensions/manager/components/manager/ManagerDialogContent.vue:
- Around line 41-43: Replace the inconsistent color class on the warning icon in
ManagerDialogContent.vue: locate the <i> element using the icon identifier
"icon-[lucide--triangle-alert]" and change its class from "text-yellow-600" to
"text-warning-background" so it matches the other components
(NodeConflictHeader.vue, PackVersionSelectorPopover.vue, TopbarBadge.vue,
ImportFailedNodeHeader.vue).
📜 Review details
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (12)
src/components/button/IconGroup.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/composables/useConflictDetection.ts
🧰 Additional context used
📓 Path-based instructions (17)
src/**/*.vue
📄 CodeRabbit inference engine (.github/copilot-instructions.md)
src/**/*.vue: Use the Vue 3 Composition API instead of the Options API when writing Vue components (exception: when overriding or extending PrimeVue components for compatibility)
Use setup() function for component logic
Utilize ref and reactive for reactive state
Implement computed properties with computed()
Use watch and watchEffect for side effects
Implement lifecycle hooks with onMounted, onUpdated, etc.
Utilize provide/inject for dependency injection
Use vue 3.5 style of default prop declaration
Use Tailwind CSS for styling
Implement proper props and emits definitions
Utilize Vue 3's Teleport component when needed
Use Suspense for async components
Follow Vue 3 style guide and naming conventions
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
src/**/*.{vue,ts}
📄 CodeRabbit inference engine (.github/copilot-instructions.md)
src/**/*.{vue,ts}: Leverage VueUse functions for performance-enhancing styles
Implement proper error handling
Use vue-i18n in composition API for any string literals. Place new translation entries in src/locales/en/main.json
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/composables/useConflictDetection.tssrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
src/**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (src/CLAUDE.md)
src/**/*.{ts,tsx,vue}: Sanitize HTML with DOMPurify to prevent XSS attacks
Avoid using @ts-expect-error; use proper TypeScript types instead
Use es-toolkit for utility functions instead of other utility libraries
Implement proper TypeScript types throughout the codebase
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/composables/useConflictDetection.tssrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
src/**/{composables,components}/**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (src/CLAUDE.md)
Clean up subscriptions in state management to prevent memory leaks
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/composables/useConflictDetection.tssrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
src/**/*.{vue,ts,tsx}
📄 CodeRabbit inference engine (src/CLAUDE.md)
Follow Vue 3 composition API style guide
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/composables/useConflictDetection.tssrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
src/**/{components,composables}/**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (src/CLAUDE.md)
Use vue-i18n for ALL user-facing strings by adding them to
src/locales/en/main.json
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/composables/useConflictDetection.tssrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
**/*.vue
📄 CodeRabbit inference engine (AGENTS.md)
**/*.vue: Use Vue 3.5+ with TypeScript in.vuefiles, exclusively using Composition API with<script setup lang="ts">syntax
Use Tailwind 4 for styling in Vue components; avoid<style>blocks
Name Vue components using PascalCase (e.g.,MenuHamburger.vue)
Use Vue 3.5 TypeScript-style default prop declaration with reactive props destructuring; do not usewithDefaultsor runtime props declaration
Prefercomputed()overrefwithwatchwhen deriving values
PreferuseModelover separately defining prop and emit for two-way binding
Usevue-i18nin composition API for string literals; place new translation entries insrc/locales/en/main.json
Usecn()utility function from@/utils/tailwindUtilfor merging Tailwind class names; do not use:class="[]"syntax
Do not use thedark:Tailwind variant; use semantic values from thestyle.csstheme instead (e.g.,bg-node-component-surface)
Do not use!importantor the!important prefix for Tailwind classes; find and correct interfering!importantclasses instead
Avoid new usage of PrimeVue components; use VueUse, shadcn/vue, or Reka UI instead
Leverage VueUse functions for performance-enhancing styles in Vue components
Implement proper props and emits definitions in Vue components
Utilize Vue 3's Teleport component when needed
Use Suspense for async components
Follow Vue 3 style guide and naming conventions
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (AGENTS.md)
**/*.{ts,tsx,vue}: Use TypeScript exclusively; do not write new JavaScript code
Use sorted and grouped imports organized by plugin/source
Enforce ESLint rules including Vue + TypeScript rules, disallow floating promises, disallow unused imports, and restrict i18n raw text in templates
Do not useanytype oras anytype assertions; fix the underlying type issue instead
Write code that is expressive and self-documenting; avoid redundant comments and clean as you go
Keep functions short and functional; minimize nesting and follow the arrow anti-pattern
Avoid mutable state; prefer immutability and assignment at point of declaration
Use function declarations instead of function expressions when possible
Use es-toolkit for utility functions
Implement proper error handling in code
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/composables/useConflictDetection.tssrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
**/*.{ts,tsx,vue,js,jsx,json,css}
📄 CodeRabbit inference engine (AGENTS.md)
Apply Prettier formatting with 2-space indentation, single quotes, no trailing semicolons, and 80-character line width
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/composables/useConflictDetection.tssrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
src/**/*.ts
📄 CodeRabbit inference engine (.github/copilot-instructions.md)
src/**/*.ts: Use es-toolkit for utility functions
Use TypeScript for type safety
Files:
src/workbench/extensions/manager/composables/useConflictDetection.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/components/topbar/TopbarBadge.test.ts
src/**/{services,composables}/**/*.{ts,tsx}
📄 CodeRabbit inference engine (src/CLAUDE.md)
src/**/{services,composables}/**/*.{ts,tsx}: Useapi.apiURL()for backend endpoints instead of constructing URLs directly
Useapi.fileURL()for static file access instead of constructing URLs directly
Files:
src/workbench/extensions/manager/composables/useConflictDetection.ts
**/**/use[A-Z]*.ts
📄 CodeRabbit inference engine (AGENTS.md)
Name composables using the pattern
useXyz.ts
Files:
src/workbench/extensions/manager/composables/useConflictDetection.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (AGENTS.md)
Minimize the surface area (exported values) of each module and composable
Files:
src/workbench/extensions/manager/composables/useConflictDetection.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/components/topbar/TopbarBadge.test.ts
src/components/**/*.vue
📄 CodeRabbit inference engine (src/components/CLAUDE.md)
src/components/**/*.vue: Use setup() function in Vue 3 Composition API
Destructure props using Vue 3.5 style in Vue components
Use ref/reactive for state management in Vue 3 Composition API
Implement computed() for derived state in Vue 3 Composition API
Use provide/inject for dependency injection in Vue components
Prefer emit/@event-name for state changes over other communication patterns
Use defineExpose only for imperative operations (such as form.validate(), modal.open())
Replace PrimeVue Dropdown component with Select
Replace PrimeVue OverlayPanel component with Popover
Replace PrimeVue Calendar component with DatePicker
Replace PrimeVue InputSwitch component with ToggleSwitch
Replace PrimeVue Sidebar component with Drawer
Replace PrimeVue Chips component with AutoComplete with multiple enabled
Replace PrimeVue TabMenu component with Tabs without panels
Replace PrimeVue Steps component with Stepper without panels
Replace PrimeVue InlineMessage component with Message
Extract complex conditionals to computed properties
Implement cleanup for async operations in Vue components
Use lifecycle hooks: onMounted, onUpdated in Vue 3 Composition API
Use Teleport/Suspense when needed for component rendering
Define proper props and emits definitions in Vue components
Files:
src/components/dialog/content/MissingNodesHeader.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
src/components/**/*.{vue,css}
📄 CodeRabbit inference engine (src/components/CLAUDE.md)
src/components/**/*.{vue,css}: Use Tailwind CSS only for styling (no custom CSS)
Use the correct tokens from style.css in the design system package
Files:
src/components/dialog/content/MissingNodesHeader.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
src/components/**/*.{vue,ts,js}
📄 CodeRabbit inference engine (src/components/CLAUDE.md)
src/components/**/*.{vue,ts,js}: Use existing VueUse composables (such as useElementHover) instead of manually managing event listeners
Use useIntersectionObserver for visibility detection instead of custom scroll handlers
Use vue-i18n for ALL UI strings
Files:
src/components/dialog/content/MissingNodesHeader.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
**/*.test.ts
📄 CodeRabbit inference engine (AGENTS.md)
**/*.test.ts: Use unit/component tests intests-ui/orsrc/**/*.test.tswith Vitest framework
For mocking in tests, leverage Vitest utilities; keep module mocks contained and avoid global mutable state within test files
Do not write change detector tests or tests dependent on non-behavioral features like utility classes or styles
Aim for behavioral coverage of critical and new features in unit tests
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/components/topbar/TopbarBadge.test.ts
🧠 Learnings (33)
📓 Common learnings
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7358
File: src/components/dialog/content/signin/SignUpForm.vue:45-54
Timestamp: 2025-12-11T12:25:24.164Z
Learning: The project has CI automation that handles code formatting (pnpm format) automatically, so manual formatting suggestions should not be provided in code reviews for the Comfy-Org/ComfyUI_frontend repository.
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7177
File: src/platform/assets/components/UploadModelFooter.vue:72-78
Timestamp: 2025-12-05T06:11:09.383Z
Learning: For the ComfyUI_frontend repository, avoid suggesting comments that would be redundant when the code is already self-explanatory through descriptive naming (e.g., filenames, prop names, aria-labels). The project prefers clean code without unnecessary documentation comments.
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 6300
File: src/locales/en/main.json:774-780
Timestamp: 2025-12-09T04:35:43.971Z
Learning: In the Comfy-Org/ComfyUI_frontend repository, locale files other than `src/locales/en/main.json` are generated automatically on every release. Developers only need to add English (en) key/values in `src/locales/en/main.json` when making PRs; manual updates to other locale files (fr, ja, ko, ru, zh, zh-TW, es, ar, tr, etc.) are not required and should not be suggested in reviews.
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue InlineMessage component with Message
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7649
File: src/components/graph/selectionToolbox/ColorPickerButton.vue:15-18
Timestamp: 2025-12-21T01:06:10.298Z
Learning: In Comfy-Org/ComfyUI_frontend, when filled icons are required (e.g., `pi pi-circle-fill`), it's acceptable to use PrimeIcons alongside Lucide icons, as Lucide does not easily provide filled icon variants. Mixed icon library usage is justified when one library lacks equivalent functionality.
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue OverlayPanel component with Popover
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue Dropdown component with Select
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue InlineMessage component with Message
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vue
📚 Learning: 2025-12-09T03:49:52.828Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 6300
File: src/platform/updates/components/WhatsNewPopup.vue:5-13
Timestamp: 2025-12-09T03:49:52.828Z
Learning: In Vue files across the ComfyUI_frontend repo, when a button is needed, prefer the repo's common button components from src/components/button/ (IconButton.vue, TextButton.vue, IconTextButton.vue) over plain HTML <button> elements. These components wrap PrimeVue with the project’s design system styling. Use only the common button components for consistency and theming, and import them from src/components/button/ as needed.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
📚 Learning: 2025-12-09T21:40:12.361Z
Learnt from: benceruleanlu
Repo: Comfy-Org/ComfyUI_frontend PR: 7297
File: src/components/actionbar/ComfyActionbar.vue:33-43
Timestamp: 2025-12-09T21:40:12.361Z
Learning: In Vue single-file components, allow inline Tailwind CSS class strings for static classes and avoid extracting them into computed properties solely for readability. Prefer keeping static class names inline for simplicity and performance. For dynamic or conditional classes, use Vue bindings (e.g., :class) to compose classes.
Applies to all Vue files in the repository (e.g., src/**/*.vue) where Tailwind utilities are used for static styling.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
📚 Learning: 2025-12-16T22:26:49.463Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7537
File: src/components/ui/button/Button.vue:17-17
Timestamp: 2025-12-16T22:26:49.463Z
Learning: In Vue 3.5+ with <script setup>, when using defineProps<Props>() with partial destructuring (e.g., const { as = 'button', class: customClass = '' } = defineProps<Props>() ), props that are not destructured (e.g., variant, size) stay accessible by name in the template scope. This pattern is valid: you can destructure only a subset of props for convenience while referencing the remaining props directly in template expressions. Apply this guideline to Vue components across the codebase (all .vue files).
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
📚 Learning: 2025-12-22T21:36:08.369Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7649
File: src/platform/cloud/subscription/components/PricingTable.vue:185-201
Timestamp: 2025-12-22T21:36:08.369Z
Learning: In Vue components, avoid creating single-use variants for common UI components (e.g., Button and other shared components). Aim for reusable variants that cover multiple use cases. It’s acceptable to temporarily mix variant props with inline Tailwind classes when a styling need is unique to one place, but plan and consolidate into shared, reusable variants as patterns emerge across the codebase.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
📚 Learning: 2025-12-11T12:25:15.470Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7358
File: src/components/dialog/content/signin/SignUpForm.vue:45-54
Timestamp: 2025-12-11T12:25:15.470Z
Learning: This repository uses CI automation to format code (pnpm format). Do not include manual formatting suggestions in code reviews for Comfy-Org/ComfyUI_frontend. If formatting issues are detected, rely on the CI formatter or re-run pnpm format. Focus reviews on correctness, readability, performance, accessibility, and maintainability rather than style formatting.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/composables/useConflictDetection.tssrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.test.tssrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
📚 Learning: 2025-12-18T02:07:38.870Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7598
File: src/components/sidebar/tabs/AssetsSidebarTab.vue:131-131
Timestamp: 2025-12-18T02:07:38.870Z
Learning: Tailwind CSS v4 safe utilities (e.g., items-center-safe, justify-*-safe, place-*-safe) are allowed in Vue components under src/ and in story files. Do not flag these specific safe variants as invalid when reviewing code in src/**/*.vue or related stories.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
📚 Learning: 2025-12-18T21:15:46.862Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7603
File: src/components/queue/QueueOverlayHeader.vue:49-59
Timestamp: 2025-12-18T21:15:46.862Z
Learning: In the ComfyUI_frontend repository, for Vue components, do not add aria-label to buttons that have visible text content (e.g., buttons containing <span> text). The visible text provides the accessible name. Use aria-label only for elements without visible labels (e.g., icon-only buttons). If a button has no visible label, provide a clear aria-label or associate with an aria-labelledby describing its action.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
📚 Learning: 2025-12-21T01:06:02.786Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7649
File: src/components/graph/selectionToolbox/ColorPickerButton.vue:15-18
Timestamp: 2025-12-21T01:06:02.786Z
Learning: In Comfy-Org/ComfyUI_frontend, in Vue component files, when a filled icon is required (e.g., 'pi pi-circle-fill'), you may mix PrimeIcons with Lucide icons since Lucide lacks filled variants. This mixed usage is acceptable when one icon library does not provide an equivalent filled icon. Apply consistently across Vue components in the src directory where icons are used, and document the rationale when a mixed approach is chosen.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackInstallButton.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue InputSwitch component with ToggleSwitch
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Avoid new usage of PrimeVue components; use VueUse, shadcn/vue, or Reka UI instead
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.{vue,ts,js} : Use existing VueUse composables (such as useElementHover) instead of manually managing event listeners
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Implement computed() for derived state in Vue 3 Composition API
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:02.860Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-24T19:47:02.860Z
Learning: Applies to src/**/*.{vue,ts} : Leverage VueUse functions for performance-enhancing styles
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Use ref/reactive for state management in Vue 3 Composition API
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:34.324Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:34.324Z
Learning: Applies to src/**/{components,composables}/**/*.{ts,tsx,vue} : Use vue-i18n for ALL user-facing strings by adding them to `src/locales/en/main.json`
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Extract complex conditionals to computed properties
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.{vue,ts,js} : Use vue-i18n for ALL UI strings
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Leverage VueUse functions for performance-enhancing styles in Vue components
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Do not use the `dark:` Tailwind variant; use semantic values from the `style.css` theme instead (e.g., `bg-node-component-surface`)
Applied to files:
src/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/dialog/content/MissingNodesHeader.vuesrc/components/topbar/TopbarBadge.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Do not use `!important` or the `!` important prefix for Tailwind classes; find and correct interfering `!important` classes instead
Applied to files:
src/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/components/topbar/TopbarBadge.vue
📚 Learning: 2025-12-09T03:39:54.501Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7169
File: src/platform/remote/comfyui/jobs/jobTypes.ts:1-107
Timestamp: 2025-12-09T03:39:54.501Z
Learning: In the ComfyUI_frontend project, Zod is on v3.x. Do not suggest Zod v4 standalone validators (z.uuid, z.ulid, z.cuid2, z.nanoid) until an upgrade to Zod 4 is performed. When reviewing TypeScript files (e.g., src/platform/remote/comfyui/jobs/jobTypes.ts) validate against Zod 3 capabilities and avoid introducing v4-specific features; flag any proposal to upgrade or incorporate v4-only validators and propose staying with compatible 3.x patterns.
Applied to files:
src/workbench/extensions/manager/composables/useConflictDetection.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-12-13T11:03:11.264Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7416
File: src/stores/imagePreviewStore.ts:5-7
Timestamp: 2025-12-13T11:03:11.264Z
Learning: In the ComfyUI_frontend repository, lint rules require keeping 'import type' statements separate from non-type imports, even if importing from the same module. Do not suggest consolidating them into a single import statement. Ensure type imports remain on their own line (import type { ... } from 'module') and regular imports stay on separate lines.
Applied to files:
src/workbench/extensions/manager/composables/useConflictDetection.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-12-17T00:40:09.635Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7537
File: src/components/ui/button/Button.stories.ts:45-55
Timestamp: 2025-12-17T00:40:09.635Z
Learning: Prefer pure function declarations over function expressions (e.g., use function foo() { ... } instead of const foo = () => { ... }) for pure functions in the repository. Function declarations are more functional-leaning, offer better hoisting clarity, and can improve readability and tooling consistency. Apply this guideline across TypeScript files in Comfy-Org/ComfyUI_frontend, including story and UI component code, except where a function expression is semantically required (e.g., callbacks, higher-order functions with closures).
Applied to files:
src/workbench/extensions/manager/composables/useConflictDetection.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-12-30T22:22:33.836Z
Learnt from: kaili-yang
Repo: Comfy-Org/ComfyUI_frontend PR: 7805
File: src/composables/useCoreCommands.ts:439-439
Timestamp: 2025-12-30T22:22:33.836Z
Learning: When accessing reactive properties from Pinia stores in TypeScript files, avoid using .value on direct property access (e.g., useStore().isOverlayExpanded). Pinia auto-wraps refs when accessed directly, returning the primitive value. The .value accessor is only needed when destructuring store properties or when using storeToRefs().
Applied to files:
src/workbench/extensions/manager/composables/useConflictDetection.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-12-18T16:03:02.066Z
Learnt from: henrikvilhelmberglund
Repo: Comfy-Org/ComfyUI_frontend PR: 7617
File: src/components/actionbar/ComfyActionbar.vue:301-308
Timestamp: 2025-12-18T16:03:02.066Z
Learning: In the ComfyUI frontend queue system, useQueuePendingTaskCountStore().count indicates the number of tasks in the queue, where count = 1 means a single active/running task and count > 1 means there are pending tasks in addition to the active task. Therefore, in src/components/actionbar/ComfyActionbar.vue, enable the 'Clear Pending Tasks' button only when count > 1 to avoid clearing the currently running task. The active task should be canceled using the 'Cancel current run' button instead. This rule should be enforced via a conditional check on the queue count, with appropriate disabled/aria-disabled states for accessibility, and tests should verify behavior for count = 1 and count > 1.
Applied to files:
src/components/dialog/content/MissingNodesHeader.vuesrc/components/topbar/TopbarBadge.vuesrc/components/button/IconGroup.vue
📚 Learning: 2025-12-10T03:09:13.807Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7303
File: src/components/topbar/CurrentUserPopover.test.ts:199-205
Timestamp: 2025-12-10T03:09:13.807Z
Learning: In test files, prefer selecting or asserting on accessible properties (text content, aria-label, role, accessible name) over data-testid attributes. This ensures tests validate actual user-facing behavior and accessibility, reducing reliance on implementation details like test IDs.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-12-30T01:31:04.927Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7797
File: tests-ui/tests/lib/litegraph/src/widgets/ComboWidget.test.ts:648-648
Timestamp: 2025-12-30T01:31:04.927Z
Learning: In Vitest v4, when mocking functions that may be called as constructors (using new), the mock implementation must use function() or class syntax rather than an arrow function. Arrow mocks can cause '<anonymous> is not a constructor' errors. This is a breaking change from Vitest v3 where mocks could use an arrow function. Apply this guideline to test files that mock constructor-like calls (e.g., in tests under tests-ui, such as ComboWidget.test.ts) and ensure mock implementations are defined with function() { ... } or class { ... } to preserve constructor behavior.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.test.ts : Do not write change detector tests or tests dependent on non-behavioral features like utility classes or styles
Applied to files:
src/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Use `cn()` utility function from `@/utils/tailwindUtil` for merging Tailwind class names; do not use `:class="[]"` syntax
Applied to files:
src/components/button/IconGroup.vue
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (5)
- GitHub Check: deploy-and-comment
- GitHub Check: test
- GitHub Check: lint-and-format
- GitHub Check: setup
- GitHub Check: collect
🔇 Additional comments (10)
src/workbench/extensions/manager/composables/useConflictDetection.ts (1)
404-427: LGTM! Clean refactoring improves code clarity.The simplified logic with early exit (line 404) and standardized conflict entry creation is more maintainable than the previous conditional branching. The error message extraction with sensible defaults (
'Unknown import error'for missing error, traceback fallback to errorMsg) ensures consistent handling of import failures.src/workbench/extensions/manager/components/manager/NodeConflictHeader.vue (1)
5-5: LGTM!The icon and color class update correctly aligns with the PR's standardization effort, using the semantic
text-warning-backgroundtoken and Lucide icon as preferred by the coding guidelines.src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.vue (1)
48-48: LGTM!The warning icon update correctly uses
text-warning-backgroundand the Lucide icon, maintaining consistency with the PR's standardization effort.src/components/topbar/TopbarBadge.vue (1)
177-177: LGTM!The warning variant correctly updates both the text color and icon to use
text-warning-backgroundand Lucide's triangle-alert icon, aligning with the PR's standardization goals and coding guidelines.Also applies to: 194-194
src/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vue (1)
4-4: LGTM!The warning icon update correctly uses the semantic
text-warning-backgroundcolor token and Lucide icon, consistent with the PR's standardization effort.src/components/topbar/TopbarBadge.test.ts (1)
164-164: LGTM! Semantic color token usage.The test now correctly validates the updated warning variant styling using
text-warning-backgroundinstead of the hardcodedtext-gold-600. This aligns with the design system's semantic color tokens.src/components/dialog/content/MissingNodesHeader.vue (1)
4-4: LGTM! Consistent icon and color token migration.The update to Lucide's
triangle-alerticon and the semantictext-warning-backgroundcolor token aligns with the design system migration and improves consistency across the UI.src/workbench/extensions/manager/components/manager/button/PackInstallButton.vue (1)
10-10: LGTM! Consistent warning icon migration.The conflict indicator correctly uses Lucide's
triangle-alerticon with the semantictext-warning-backgroundcolor token, maintaining consistency with the broader UI migration.src/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts (1)
197-197: LGTM! Semantic color token in test.The test correctly validates the updated warning color using
text-warning-backgroundinstead of the hardcodedtext-yellow-500, aligning with semantic design tokens.src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue (1)
12-14: LGTM! Consistent warning icon implementation.The conflict indicator correctly uses Lucide's
triangle-alerticon with semantic color tokentext-warning-background, matching the design system migration across the PR.
src/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
Outdated
Show resolved
Hide resolved
src/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vue
Outdated
Show resolved
Hide resolved
src/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
Outdated
Show resolved
Hide resolved
|
@DrJKL Can you approve again? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In
@src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue:
- Line 39: Update the import path that currently reads
'@//workbench/extensions/manager/composables/useImportFailedDetection' in
PackEnableToggle.vue to use a single slash alias:
'@/workbench/extensions/manager/composables/useImportFailedDetection' so the
module resolves correctly.
📜 Review details
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (7)
src/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
🧰 Additional context used
📓 Path-based instructions (13)
src/**/*.{vue,ts}
📄 CodeRabbit inference engine (.github/copilot-instructions.md)
src/**/*.{vue,ts}: Leverage VueUse functions for performance-enhancing styles
Implement proper error handling
Use vue-i18n in composition API for any string literals. Place new translation entries in src/locales/en/main.json
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
src/**/*.ts
📄 CodeRabbit inference engine (.github/copilot-instructions.md)
src/**/*.ts: Use es-toolkit for utility functions
Use TypeScript for type safety
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts
src/**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (src/CLAUDE.md)
src/**/*.{ts,tsx,vue}: Sanitize HTML with DOMPurify to prevent XSS attacks
Avoid using @ts-expect-error; use proper TypeScript types instead
Use es-toolkit for utility functions instead of other utility libraries
Implement proper TypeScript types throughout the codebase
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
src/**/{composables,components}/**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (src/CLAUDE.md)
Clean up subscriptions in state management to prevent memory leaks
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
src/**/*.{vue,ts,tsx}
📄 CodeRabbit inference engine (src/CLAUDE.md)
Follow Vue 3 composition API style guide
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
src/**/{components,composables}/**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (src/CLAUDE.md)
Use vue-i18n for ALL user-facing strings by adding them to
src/locales/en/main.json
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (AGENTS.md)
**/*.{ts,tsx,vue}: Use TypeScript exclusively; do not write new JavaScript code
Use sorted and grouped imports organized by plugin/source
Enforce ESLint rules including Vue + TypeScript rules, disallow floating promises, disallow unused imports, and restrict i18n raw text in templates
Do not useanytype oras anytype assertions; fix the underlying type issue instead
Write code that is expressive and self-documenting; avoid redundant comments and clean as you go
Keep functions short and functional; minimize nesting and follow the arrow anti-pattern
Avoid mutable state; prefer immutability and assignment at point of declaration
Use function declarations instead of function expressions when possible
Use es-toolkit for utility functions
Implement proper error handling in code
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
**/*.{ts,tsx,vue,js,jsx,json,css}
📄 CodeRabbit inference engine (AGENTS.md)
Apply Prettier formatting with 2-space indentation, single quotes, no trailing semicolons, and 80-character line width
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
**/*.test.ts
📄 CodeRabbit inference engine (AGENTS.md)
**/*.test.ts: Use unit/component tests intests-ui/orsrc/**/*.test.tswith Vitest framework
For mocking in tests, leverage Vitest utilities; keep module mocks contained and avoid global mutable state within test files
Do not write change detector tests or tests dependent on non-behavioral features like utility classes or styles
Aim for behavioral coverage of critical and new features in unit tests
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (AGENTS.md)
Minimize the surface area (exported values) of each module and composable
Files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts
src/components/**/*.{vue,ts,js}
📄 CodeRabbit inference engine (src/components/CLAUDE.md)
src/components/**/*.{vue,ts,js}: Use existing VueUse composables (such as useElementHover) instead of manually managing event listeners
Use useIntersectionObserver for visibility detection instead of custom scroll handlers
Use vue-i18n for ALL UI strings
Files:
src/components/topbar/TopbarBadge.test.ts
src/**/*.vue
📄 CodeRabbit inference engine (.github/copilot-instructions.md)
src/**/*.vue: Use the Vue 3 Composition API instead of the Options API when writing Vue components (exception: when overriding or extending PrimeVue components for compatibility)
Use setup() function for component logic
Utilize ref and reactive for reactive state
Implement computed properties with computed()
Use watch and watchEffect for side effects
Implement lifecycle hooks with onMounted, onUpdated, etc.
Utilize provide/inject for dependency injection
Use vue 3.5 style of default prop declaration
Use Tailwind CSS for styling
Implement proper props and emits definitions
Utilize Vue 3's Teleport component when needed
Use Suspense for async components
Follow Vue 3 style guide and naming conventions
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
**/*.vue
📄 CodeRabbit inference engine (AGENTS.md)
**/*.vue: Use Vue 3.5+ with TypeScript in.vuefiles, exclusively using Composition API with<script setup lang="ts">syntax
Use Tailwind 4 for styling in Vue components; avoid<style>blocks
Name Vue components using PascalCase (e.g.,MenuHamburger.vue)
Use Vue 3.5 TypeScript-style default prop declaration with reactive props destructuring; do not usewithDefaultsor runtime props declaration
Prefercomputed()overrefwithwatchwhen deriving values
PreferuseModelover separately defining prop and emit for two-way binding
Usevue-i18nin composition API for string literals; place new translation entries insrc/locales/en/main.json
Usecn()utility function from@/utils/tailwindUtilfor merging Tailwind class names; do not use:class="[]"syntax
Do not use thedark:Tailwind variant; use semantic values from thestyle.csstheme instead (e.g.,bg-node-component-surface)
Do not use!importantor the!important prefix for Tailwind classes; find and correct interfering!importantclasses instead
Avoid new usage of PrimeVue components; use VueUse, shadcn/vue, or Reka UI instead
Leverage VueUse functions for performance-enhancing styles in Vue components
Implement proper props and emits definitions in Vue components
Utilize Vue 3's Teleport component when needed
Use Suspense for async components
Follow Vue 3 style guide and naming conventions
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
🧠 Learnings (43)
📓 Common learnings
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7649
File: src/components/graph/selectionToolbox/ColorPickerButton.vue:15-18
Timestamp: 2025-12-21T01:06:10.298Z
Learning: In Comfy-Org/ComfyUI_frontend, when filled icons are required (e.g., `pi pi-circle-fill`), it's acceptable to use PrimeIcons alongside Lucide icons, as Lucide does not easily provide filled icon variants. Mixed icon library usage is justified when one library lacks equivalent functionality.
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue InlineMessage component with Message
📚 Learning: 2025-11-24T19:47:22.909Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: browser_tests/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:22.909Z
Learning: Applies to browser_tests/**/*.{e2e,spec}.{ts,tsx,js,jsx} : Prefer specific selectors in browser tests
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.test.ts : Do not write change detector tests or tests dependent on non-behavioral features like utility classes or styles
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue OverlayPanel component with Popover
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-09T03:39:54.501Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7169
File: src/platform/remote/comfyui/jobs/jobTypes.ts:1-107
Timestamp: 2025-12-09T03:39:54.501Z
Learning: In the ComfyUI_frontend project, Zod is on v3.x. Do not suggest Zod v4 standalone validators (z.uuid, z.ulid, z.cuid2, z.nanoid) until an upgrade to Zod 4 is performed. When reviewing TypeScript files (e.g., src/platform/remote/comfyui/jobs/jobTypes.ts) validate against Zod 3 capabilities and avoid introducing v4-specific features; flag any proposal to upgrade or incorporate v4-only validators and propose staying with compatible 3.x patterns.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts
📚 Learning: 2025-12-13T11:03:11.264Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7416
File: src/stores/imagePreviewStore.ts:5-7
Timestamp: 2025-12-13T11:03:11.264Z
Learning: In the ComfyUI_frontend repository, lint rules require keeping 'import type' statements separate from non-type imports, even if importing from the same module. Do not suggest consolidating them into a single import statement. Ensure type imports remain on their own line (import type { ... } from 'module') and regular imports stay on separate lines.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts
📚 Learning: 2025-12-17T00:40:09.635Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7537
File: src/components/ui/button/Button.stories.ts:45-55
Timestamp: 2025-12-17T00:40:09.635Z
Learning: Prefer pure function declarations over function expressions (e.g., use function foo() { ... } instead of const foo = () => { ... }) for pure functions in the repository. Function declarations are more functional-leaning, offer better hoisting clarity, and can improve readability and tooling consistency. Apply this guideline across TypeScript files in Comfy-Org/ComfyUI_frontend, including story and UI component code, except where a function expression is semantically required (e.g., callbacks, higher-order functions with closures).
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts
📚 Learning: 2025-12-30T22:22:33.836Z
Learnt from: kaili-yang
Repo: Comfy-Org/ComfyUI_frontend PR: 7805
File: src/composables/useCoreCommands.ts:439-439
Timestamp: 2025-12-30T22:22:33.836Z
Learning: When accessing reactive properties from Pinia stores in TypeScript files, avoid using .value on direct property access (e.g., useStore().isOverlayExpanded). Pinia auto-wraps refs when accessed directly, returning the primitive value. The .value accessor is only needed when destructuring store properties or when using storeToRefs().
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts
📚 Learning: 2025-12-10T03:09:13.807Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7303
File: src/components/topbar/CurrentUserPopover.test.ts:199-205
Timestamp: 2025-12-10T03:09:13.807Z
Learning: In test files, prefer selecting or asserting on accessible properties (text content, aria-label, role, accessible name) over data-testid attributes. This ensures tests validate actual user-facing behavior and accessibility, reducing reliance on implementation details like test IDs.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts
📚 Learning: 2025-12-30T01:31:04.927Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7797
File: tests-ui/tests/lib/litegraph/src/widgets/ComboWidget.test.ts:648-648
Timestamp: 2025-12-30T01:31:04.927Z
Learning: In Vitest v4, when mocking functions that may be called as constructors (using new), the mock implementation must use function() or class syntax rather than an arrow function. Arrow mocks can cause '<anonymous> is not a constructor' errors. This is a breaking change from Vitest v3 where mocks could use an arrow function. Apply this guideline to test files that mock constructor-like calls (e.g., in tests under tests-ui, such as ComboWidget.test.ts) and ensure mock implementations are defined with function() { ... } or class { ... } to preserve constructor behavior.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts
📚 Learning: 2025-12-11T12:25:15.470Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7358
File: src/components/dialog/content/signin/SignUpForm.vue:45-54
Timestamp: 2025-12-11T12:25:15.470Z
Learning: This repository uses CI automation to format code (pnpm format). Do not include manual formatting suggestions in code reviews for Comfy-Org/ComfyUI_frontend. If formatting issues are detected, rely on the CI formatter or re-run pnpm format. Focus reviews on correctness, readability, performance, accessibility, and maintainability rather than style formatting.
Applied to files:
src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.tssrc/components/topbar/TopbarBadge.test.tssrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.tssrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.test.ts : Aim for behavioral coverage of critical and new features in unit tests
Applied to files:
src/components/topbar/TopbarBadge.test.ts
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue InputSwitch component with ToggleSwitch
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue InlineMessage component with Message
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Avoid new usage of PrimeVue components; use VueUse, shadcn/vue, or Reka UI instead
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-13T11:03:21.073Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7416
File: src/stores/imagePreviewStore.ts:5-7
Timestamp: 2025-12-13T11:03:21.073Z
Learning: In the Comfy-Org/ComfyUI_frontend repository, linting rules enforce keeping `import type` statements separate from regular `import` statements, even when importing from the same module. Do not suggest consolidating them into a single import statement.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:34.324Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:34.324Z
Learning: Applies to src/**/*.{ts,tsx,vue} : Avoid using ts-expect-error; use proper TypeScript types instead
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.{ts,tsx,vue} : Do not use `any` type or `as any` type assertions; fix the underlying type issue instead
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.{ts,tsx,vue} : Implement proper error handling in code
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:02.860Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-24T19:47:02.860Z
Learning: Applies to src/**/*.{vue,ts} : Implement proper error handling
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.{ts,tsx,vue} : Use sorted and grouped imports organized by plugin/source
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:48:09.318Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: .cursor/rules/unit-test.mdc:0-0
Timestamp: 2025-11-24T19:48:09.318Z
Learning: Applies to test/**/*.{test,spec}.{js,ts,jsx,tsx} : Tests should be cross-platform compatible using `path.resolve`, `path.join`, and `path.sep` for Windows, macOS, and Linux compatibility
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.{ts,tsx,vue} : Use function declarations instead of function expressions when possible
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.{ts,tsx,vue} : Write code that is expressive and self-documenting; avoid redundant comments and clean as you go
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.{vue,ts,js} : Use existing VueUse composables (such as useElementHover) instead of manually managing event listeners
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Implement computed() for derived state in Vue 3 Composition API
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-09T03:49:52.828Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 6300
File: src/platform/updates/components/WhatsNewPopup.vue:5-13
Timestamp: 2025-12-09T03:49:52.828Z
Learning: In Vue files across the ComfyUI_frontend repo, when a button is needed, prefer the repo's common button components from src/components/button/ (IconButton.vue, TextButton.vue, IconTextButton.vue) over plain HTML <button> elements. These components wrap PrimeVue with the project’s design system styling. Use only the common button components for consistency and theming, and import them from src/components/button/ as needed.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-11-24T19:47:02.860Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-24T19:47:02.860Z
Learning: Applies to src/**/*.{vue,ts} : Leverage VueUse functions for performance-enhancing styles
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Use ref/reactive for state management in Vue 3 Composition API
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:34.324Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:34.324Z
Learning: Applies to src/**/{components,composables}/**/*.{ts,tsx,vue} : Use vue-i18n for ALL user-facing strings by adding them to `src/locales/en/main.json`
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Extract complex conditionals to computed properties
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.{vue,ts,js} : Use vue-i18n for ALL UI strings
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Leverage VueUse functions for performance-enhancing styles in Vue components
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-09T21:40:12.361Z
Learnt from: benceruleanlu
Repo: Comfy-Org/ComfyUI_frontend PR: 7297
File: src/components/actionbar/ComfyActionbar.vue:33-43
Timestamp: 2025-12-09T21:40:12.361Z
Learning: In Vue single-file components, allow inline Tailwind CSS class strings for static classes and avoid extracting them into computed properties solely for readability. Prefer keeping static class names inline for simplicity and performance. For dynamic or conditional classes, use Vue bindings (e.g., :class) to compose classes.
Applies to all Vue files in the repository (e.g., src/**/*.vue) where Tailwind utilities are used for static styling.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-16T22:26:49.463Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7537
File: src/components/ui/button/Button.vue:17-17
Timestamp: 2025-12-16T22:26:49.463Z
Learning: In Vue 3.5+ with <script setup>, when using defineProps<Props>() with partial destructuring (e.g., const { as = 'button', class: customClass = '' } = defineProps<Props>() ), props that are not destructured (e.g., variant, size) stay accessible by name in the template scope. This pattern is valid: you can destructure only a subset of props for convenience while referencing the remaining props directly in template expressions. Apply this guideline to Vue components across the codebase (all .vue files).
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-22T21:36:08.369Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7649
File: src/platform/cloud/subscription/components/PricingTable.vue:185-201
Timestamp: 2025-12-22T21:36:08.369Z
Learning: In Vue components, avoid creating single-use variants for common UI components (e.g., Button and other shared components). Aim for reusable variants that cover multiple use cases. It’s acceptable to temporarily mix variant props with inline Tailwind classes when a styling need is unique to one place, but plan and consolidate into shared, reusable variants as patterns emerge across the codebase.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2026-01-08T02:26:18.357Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7893
File: src/components/button/IconGroup.vue:5-6
Timestamp: 2026-01-08T02:26:18.357Z
Learning: In components that use the cn utility from '@/utils/tailwindUtil' with tailwind-merge, rely on the behavior that conflicting Tailwind classes are resolved by keeping the last one. For example, cn('base-classes bg-default', propClass) will have any conflicting background class from propClass override bg-default. This additive pattern is intentional and aligns with the shadcn-ui convention; ensure you document or review expectations accordingly in Vue components.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-18T02:07:38.870Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7598
File: src/components/sidebar/tabs/AssetsSidebarTab.vue:131-131
Timestamp: 2025-12-18T02:07:38.870Z
Learning: Tailwind CSS v4 safe utilities (e.g., items-center-safe, justify-*-safe, place-*-safe) are allowed in Vue components under src/ and in story files. Do not flag these specific safe variants as invalid when reviewing code in src/**/*.vue or related stories.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-18T21:15:46.862Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7603
File: src/components/queue/QueueOverlayHeader.vue:49-59
Timestamp: 2025-12-18T21:15:46.862Z
Learning: In the ComfyUI_frontend repository, for Vue components, do not add aria-label to buttons that have visible text content (e.g., buttons containing <span> text). The visible text provides the accessible name. Use aria-label only for elements without visible labels (e.g., icon-only buttons). If a button has no visible label, provide a clear aria-label or associate with an aria-labelledby describing its action.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-21T01:06:02.786Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7649
File: src/components/graph/selectionToolbox/ColorPickerButton.vue:15-18
Timestamp: 2025-12-21T01:06:02.786Z
Learning: In Comfy-Org/ComfyUI_frontend, in Vue component files, when a filled icon is required (e.g., 'pi pi-circle-fill'), you may mix PrimeIcons with Lucide icons since Lucide lacks filled variants. This mixed usage is acceptable when one icon library does not provide an equivalent filled icon. Apply consistently across Vue components in the src directory where icons are used, and document the rationale when a mixed approach is chosen.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vuesrc/workbench/extensions/manager/components/manager/NodeConflictHeader.vuesrc/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vuesrc/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Do not use `!important` or the `!` important prefix for Tailwind classes; find and correct interfering `!important` classes instead
Applied to files:
src/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Do not use the `dark:` Tailwind variant; use semantic values from the `style.css` theme instead (e.g., `bg-node-component-surface`)
Applied to files:
src/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
📚 Learning: 2025-12-16T17:30:29.719Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7559
File: .storybook/preview.ts:61-61
Timestamp: 2025-12-16T17:30:29.719Z
Learning: In .storybook/preview.ts for the Comfy-Org/ComfyUI_frontend repository, using `document.body.classList.add('[&_*]:!font-inter')` is the correct approach for applying the Inter font to all Storybook story elements. The simpler `font-inter` class alone does not work in this context. This runtime arbitrary variant pattern is valid and should not be flagged as an issue.
Applied to files:
src/workbench/extensions/manager/components/manager/ManagerDialogContent.vue
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
- GitHub Check: lint-and-format
- GitHub Check: test
- GitHub Check: collect
🔇 Additional comments (7)
src/workbench/extensions/manager/components/manager/ImportFailedNodeHeader.vue (1)
4-4: LGTM! Icon updated correctly.The warning icon now uses the Lucide icon library with the semantic color token
text-warning-background, and the self-closing tag format is cleaner. This aligns with the PR's goal of standardizing warning indicators across components.src/workbench/extensions/manager/components/manager/NodeConflictHeader.vue (1)
5-5: LGTM! Consistent icon update.The warning icon correctly uses the Lucide icon with
text-warning-background, matching the standardization applied across other components in this PR.src/workbench/extensions/manager/components/manager/button/PackEnableToggle.test.ts (1)
175-210: LGTM! Test assertions updated correctly.The test selectors and color class assertions have been properly updated to reflect the migration from PrimeIcons to Lucide icons and the standardization on
text-warning-background. The escaped bracket syntax in the selector (.icon-\\[lucide--triangle-alert\\]) is correct for CSS class matching.src/workbench/extensions/manager/components/manager/ManagerDialogContent.vue (1)
41-43: LGTM! Inconsistency resolved.The warning icon now correctly uses
text-warning-background, resolving the inconsistency previously flagged in past reviews. The self-closing tag format and Lucide icon migration are consistent with other components in this PR.src/components/topbar/TopbarBadge.test.ts (1)
153-191: LGTM! Test assertions align with component updates.The warning variant tests have been correctly updated to reflect the migration to Lucide icons and the semantic color token
text-warning-background. The escaped bracket syntax in the icon selector is appropriate for CSS class matching.src/workbench/extensions/manager/components/manager/PackVersionSelectorPopover.test.ts (1)
414-414: LGTM! Test selectors updated to match Lucide icon implementation.The test assertions correctly target the new Lucide-based warning icon class (
.icon-[lucide--triangle-alert]) across all compatibility warning scenarios. The behavioral coverage remains intact—tests still verify that warning icons appear when conflicts are detected.Also applies to: 539-539, 665-665, 708-708
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue (1)
12-14: LGTM! Icon replaced with Lucide and semantic color token.The warning icon correctly uses the Lucide
triangle-alerticon and the semantic color tokentext-warning-background, aligning with the project's migration away from PrimeVue/PrimeIcons and toward semantic theming.
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
Outdated
Show resolved
Hide resolved
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
🔧 Auto-fixes AppliedThis PR has been automatically updated to fix linting and formatting issues.
Changes made:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue (1)
3-11: Add button semantics for keyboard accessibility.The clickable div that opens the conflict modal is not keyboard accessible. It lacks proper button semantics, making it inaccessible to keyboard users and unclear to screen readers.
♿ Suggested fix to improve accessibility
- <div + <button + type="button" v-if="packageConflict?.has_conflict" v-tooltip="{ value: $t('manager.conflicts.warningTooltip'), showDelay: 300 }" - class="flex h-6 w-6 cursor-pointer items-center justify-center" + class="flex h-6 w-6 items-center justify-center" + :aria-label="$t('manager.conflicts.warningTooltip')" @click="showConflictModal(true)" > <i class="icon-[lucide--triangle-alert] text-xl text-warning-background" /> - </div> + </button>Note: Using a
<button>provides proper keyboard support (Enter/Space keys) and screen reader announcements automatically. Thecursor-pointerclass is unnecessary on buttons. Consider adding the tooltip text as anaria-labelfor non-visual users.
📜 Review details
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (1)
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
🧰 Additional context used
📓 Path-based instructions (9)
src/**/*.vue
📄 CodeRabbit inference engine (.github/copilot-instructions.md)
src/**/*.vue: Use the Vue 3 Composition API instead of the Options API when writing Vue components (exception: when overriding or extending PrimeVue components for compatibility)
Use setup() function for component logic
Utilize ref and reactive for reactive state
Implement computed properties with computed()
Use watch and watchEffect for side effects
Implement lifecycle hooks with onMounted, onUpdated, etc.
Utilize provide/inject for dependency injection
Use vue 3.5 style of default prop declaration
Use Tailwind CSS for styling
Implement proper props and emits definitions
Utilize Vue 3's Teleport component when needed
Use Suspense for async components
Follow Vue 3 style guide and naming conventions
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
src/**/*.{vue,ts}
📄 CodeRabbit inference engine (.github/copilot-instructions.md)
src/**/*.{vue,ts}: Leverage VueUse functions for performance-enhancing styles
Implement proper error handling
Use vue-i18n in composition API for any string literals. Place new translation entries in src/locales/en/main.json
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
src/**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (src/CLAUDE.md)
src/**/*.{ts,tsx,vue}: Sanitize HTML with DOMPurify to prevent XSS attacks
Avoid using @ts-expect-error; use proper TypeScript types instead
Use es-toolkit for utility functions instead of other utility libraries
Implement proper TypeScript types throughout the codebase
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
src/**/{composables,components}/**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (src/CLAUDE.md)
Clean up subscriptions in state management to prevent memory leaks
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
src/**/*.{vue,ts,tsx}
📄 CodeRabbit inference engine (src/CLAUDE.md)
Follow Vue 3 composition API style guide
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
src/**/{components,composables}/**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (src/CLAUDE.md)
Use vue-i18n for ALL user-facing strings by adding them to
src/locales/en/main.json
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
**/*.vue
📄 CodeRabbit inference engine (AGENTS.md)
**/*.vue: Use Vue 3.5+ with TypeScript in.vuefiles, exclusively using Composition API with<script setup lang="ts">syntax
Use Tailwind 4 for styling in Vue components; avoid<style>blocks
Name Vue components using PascalCase (e.g.,MenuHamburger.vue)
Use Vue 3.5 TypeScript-style default prop declaration with reactive props destructuring; do not usewithDefaultsor runtime props declaration
Prefercomputed()overrefwithwatchwhen deriving values
PreferuseModelover separately defining prop and emit for two-way binding
Usevue-i18nin composition API for string literals; place new translation entries insrc/locales/en/main.json
Usecn()utility function from@/utils/tailwindUtilfor merging Tailwind class names; do not use:class="[]"syntax
Do not use thedark:Tailwind variant; use semantic values from thestyle.csstheme instead (e.g.,bg-node-component-surface)
Do not use!importantor the!important prefix for Tailwind classes; find and correct interfering!importantclasses instead
Avoid new usage of PrimeVue components; use VueUse, shadcn/vue, or Reka UI instead
Leverage VueUse functions for performance-enhancing styles in Vue components
Implement proper props and emits definitions in Vue components
Utilize Vue 3's Teleport component when needed
Use Suspense for async components
Follow Vue 3 style guide and naming conventions
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
**/*.{ts,tsx,vue}
📄 CodeRabbit inference engine (AGENTS.md)
**/*.{ts,tsx,vue}: Use TypeScript exclusively; do not write new JavaScript code
Use sorted and grouped imports organized by plugin/source
Enforce ESLint rules including Vue + TypeScript rules, disallow floating promises, disallow unused imports, and restrict i18n raw text in templates
Do not useanytype oras anytype assertions; fix the underlying type issue instead
Write code that is expressive and self-documenting; avoid redundant comments and clean as you go
Keep functions short and functional; minimize nesting and follow the arrow anti-pattern
Avoid mutable state; prefer immutability and assignment at point of declaration
Use function declarations instead of function expressions when possible
Use es-toolkit for utility functions
Implement proper error handling in code
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
**/*.{ts,tsx,vue,js,jsx,json,css}
📄 CodeRabbit inference engine (AGENTS.md)
Apply Prettier formatting with 2-space indentation, single quotes, no trailing semicolons, and 80-character line width
Files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
🧠 Learnings (17)
📓 Common learnings
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 6300
File: src/platform/updates/components/WhatsNewPopup.vue:5-13
Timestamp: 2025-12-09T03:50:03.127Z
Learning: In the Comfy-Org/ComfyUI_frontend repository, when avoiding PrimeVue components, prefer using the repo's common button components from src/components/button/ (IconButton.vue, TextButton.vue, IconTextButton.vue) rather than plain HTML buttons. These components wrap PrimeVue with custom design system styling.
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7649
File: src/components/graph/selectionToolbox/ColorPickerButton.vue:15-18
Timestamp: 2025-12-21T01:06:10.298Z
Learning: In Comfy-Org/ComfyUI_frontend, when filled icons are required (e.g., `pi pi-circle-fill`), it's acceptable to use PrimeIcons alongside Lucide icons, as Lucide does not easily provide filled icon variants. Mixed icon library usage is justified when one library lacks equivalent functionality.
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.vue : Avoid new usage of PrimeVue components; use VueUse, shadcn/vue, or Reka UI instead
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue InputSwitch component with ToggleSwitch
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue OverlayPanel component with Popover
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Replace PrimeVue InlineMessage component with Message
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-13T11:03:21.073Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7416
File: src/stores/imagePreviewStore.ts:5-7
Timestamp: 2025-12-13T11:03:21.073Z
Learning: In the Comfy-Org/ComfyUI_frontend repository, linting rules enforce keeping `import type` statements separate from regular `import` statements, even when importing from the same module. Do not suggest consolidating them into a single import statement.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.{vue,css} : Use the correct tokens from style.css in the design system package
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T06:04:12.562Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-21T06:04:12.562Z
Learning: Applies to **/*.{ts,tsx,vue} : Do not use `any` type or `as any` type assertions; fix the underlying type issue instead
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-11-24T19:47:34.324Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:34.324Z
Learning: Applies to src/**/*.{ts,tsx,vue} : Avoid using ts-expect-error; use proper TypeScript types instead
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-09T03:49:52.828Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 6300
File: src/platform/updates/components/WhatsNewPopup.vue:5-13
Timestamp: 2025-12-09T03:49:52.828Z
Learning: In Vue files across the ComfyUI_frontend repo, when a button is needed, prefer the repo's common button components from src/components/button/ (IconButton.vue, TextButton.vue, IconTextButton.vue) over plain HTML <button> elements. These components wrap PrimeVue with the project’s design system styling. Use only the common button components for consistency and theming, and import them from src/components/button/ as needed.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-09T21:40:12.361Z
Learnt from: benceruleanlu
Repo: Comfy-Org/ComfyUI_frontend PR: 7297
File: src/components/actionbar/ComfyActionbar.vue:33-43
Timestamp: 2025-12-09T21:40:12.361Z
Learning: In Vue single-file components, allow inline Tailwind CSS class strings for static classes and avoid extracting them into computed properties solely for readability. Prefer keeping static class names inline for simplicity and performance. For dynamic or conditional classes, use Vue bindings (e.g., :class) to compose classes.
Applies to all Vue files in the repository (e.g., src/**/*.vue) where Tailwind utilities are used for static styling.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-16T22:26:49.463Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7537
File: src/components/ui/button/Button.vue:17-17
Timestamp: 2025-12-16T22:26:49.463Z
Learning: In Vue 3.5+ with <script setup>, when using defineProps<Props>() with partial destructuring (e.g., const { as = 'button', class: customClass = '' } = defineProps<Props>() ), props that are not destructured (e.g., variant, size) stay accessible by name in the template scope. This pattern is valid: you can destructure only a subset of props for convenience while referencing the remaining props directly in template expressions. Apply this guideline to Vue components across the codebase (all .vue files).
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-22T21:36:08.369Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7649
File: src/platform/cloud/subscription/components/PricingTable.vue:185-201
Timestamp: 2025-12-22T21:36:08.369Z
Learning: In Vue components, avoid creating single-use variants for common UI components (e.g., Button and other shared components). Aim for reusable variants that cover multiple use cases. It’s acceptable to temporarily mix variant props with inline Tailwind classes when a styling need is unique to one place, but plan and consolidate into shared, reusable variants as patterns emerge across the codebase.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2026-01-08T02:26:18.357Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7893
File: src/components/button/IconGroup.vue:5-6
Timestamp: 2026-01-08T02:26:18.357Z
Learning: In components that use the cn utility from '@/utils/tailwindUtil' with tailwind-merge, rely on the behavior that conflicting Tailwind classes are resolved by keeping the last one. For example, cn('base-classes bg-default', propClass) will have any conflicting background class from propClass override bg-default. This additive pattern is intentional and aligns with the shadcn-ui convention; ensure you document or review expectations accordingly in Vue components.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-11T12:25:15.470Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7358
File: src/components/dialog/content/signin/SignUpForm.vue:45-54
Timestamp: 2025-12-11T12:25:15.470Z
Learning: This repository uses CI automation to format code (pnpm format). Do not include manual formatting suggestions in code reviews for Comfy-Org/ComfyUI_frontend. If formatting issues are detected, rely on the CI formatter or re-run pnpm format. Focus reviews on correctness, readability, performance, accessibility, and maintainability rather than style formatting.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-18T02:07:38.870Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7598
File: src/components/sidebar/tabs/AssetsSidebarTab.vue:131-131
Timestamp: 2025-12-18T02:07:38.870Z
Learning: Tailwind CSS v4 safe utilities (e.g., items-center-safe, justify-*-safe, place-*-safe) are allowed in Vue components under src/ and in story files. Do not flag these specific safe variants as invalid when reviewing code in src/**/*.vue or related stories.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-18T21:15:46.862Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7603
File: src/components/queue/QueueOverlayHeader.vue:49-59
Timestamp: 2025-12-18T21:15:46.862Z
Learning: In the ComfyUI_frontend repository, for Vue components, do not add aria-label to buttons that have visible text content (e.g., buttons containing <span> text). The visible text provides the accessible name. Use aria-label only for elements without visible labels (e.g., icon-only buttons). If a button has no visible label, provide a clear aria-label or associate with an aria-labelledby describing its action.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
📚 Learning: 2025-12-21T01:06:02.786Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7649
File: src/components/graph/selectionToolbox/ColorPickerButton.vue:15-18
Timestamp: 2025-12-21T01:06:02.786Z
Learning: In Comfy-Org/ComfyUI_frontend, in Vue component files, when a filled icon is required (e.g., 'pi pi-circle-fill'), you may mix PrimeIcons with Lucide icons since Lucide lacks filled variants. This mixed usage is acceptable when one icon library does not provide an equivalent filled icon. Apply consistently across Vue components in the src directory where icons are used, and document the rationale when a mixed approach is chosen.
Applied to files:
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue
🔇 Additional comments (2)
src/workbench/extensions/manager/components/manager/button/PackEnableToggle.vue (2)
12-14: LGTM! Icon and color token updates align with design system.The replacement of the PrimeVue icon with a Lucide icon (
triangle-alert) and the use of the semantic color token (text-warning-background) correctly follow the coding guidelines and PR objectives.
42-42: Import path fix resolves previous review issue.The import path now correctly uses a single slash in the alias (
@/workbench), which fixes the double slash typo flagged in the previous review.
Summary
#7871
#7858
I refactored the code based on the reviews I received on those two PRs.
Changes
┆Issue is synchronized with this Notion page by Unito