Skip to content

fix(MULTIPLA-002-3): CU-86akhf8u5 2 review findings in tags-editor.tsx - #394

Draft
flamingo[bot] wants to merge 1 commit into
mainfrom
ai-fix/multipla-002-3-a8b0ea8a-c69bf2d8
Draft

flamingo[bot] wants to merge 1 commit into
mainfrom
ai-fix/multipla-002-3-a8b0ea8a-c69bf2d8

Conversation

@flamingo

@flamingo flamingo Bot commented Sep 14, 2026

Copy link
Copy Markdown
Contributor

Closes 2 review findings in src/app/components/shared/tags/tags-editor.tsx.

Draft — this is a starting point, not a finished change. The fix required judgment, so read it before trusting it.

# Fix confidence Finding Location
1 🟢 90 high PlusCircle icon imported from lucide-react instead of ui-kit / core icon set src/app/components/shared/tags/tags-editor.tsx:3
2 🔴 20 low — review closely Fragment spread used in tag-row.tsx but not colocated with useFragment call in this file src/app/components/shared/tags/tags-editor.tsx:20

What changed — and what was deliberately left — is explained per finding as inline review comments on the lines each finding touched.


Run: https://product-hub.flamingo.so/admin/code-review
Run id: c69bf2d8-6eaa-4e2d-815b-af08b880c8df

Merging this PR is recorded as acceptance of the rule that produced it;
closing it unmerged is recorded as rejection. Both feed rule health, so
closing a wrong suggestion is useful rather than merely tidy.

ClickUp task: CU-86akhf8u5 OpenFrame OSS frontend review findings sweep (12 PRs)

@flamingo flamingo Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

🦩 What this fix changed, finding by finding

2 finding(s) fixed in this draft — 2 explained inline on the diff; 1 low-confidence hunk(s) need close review before merging.

@@ -1,7 +1,6 @@
'use client';

import { Button } from '@flamingo-stack/openframe-frontend-core';

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

🦩 🔴 PlusCircle icon imported from lucide-react instead of ui-kit / core icon set

Replaced import { PlusCircle } from 'lucide-react' with PlusCircleIcon imported from @flamingo-stack/openframe-frontend-core in the same named import as Button, and updated the leftIcon={<PlusCircle ... />} usage in the TagsEditor function to <PlusCircleIcon ... />. This matches the pattern cited (PlusCircleIcon in devices-panel-header.tsx) and removes the lucide-react dependency from this file. Assumes PlusCircleIcon is indeed exported from that package's icon set, consistent with the finding's evidence.

🤖 Prompt for AI agents
In src/app/components/shared/tags/tags-editor.tsx around line 3, review and complete this code-review fix: PlusCircle icon imported from lucide-react instead of ui-kit / core icon set.
What the draft fix changed: Replaced `import { PlusCircle } from 'lucide-react'` with `PlusCircleIcon` imported from `@flamingo-stack/openframe-frontend-core` in the same named import as `Button`, and updated the `leftIcon={<PlusCircle ... />}` usage in the `TagsEditor` function to `<PlusCircleIcon ... />`. This matches the pattern cited (PlusCircleIcon in devices-panel-header.tsx) and removes the lucide-react dependency from this file. Assumes `PlusCircleIcon` is indeed exported from that package's icon set, consistent with the finding's evidence.
Verify the change is correct and complete; do not refactor unrelated code.

fix confidence: 🟢 90 high — react 👍/👎 to teach the reviewer

Comment on lines 1 to 6
'use client';

import { Button } from '@flamingo-stack/openframe-frontend-core';
import { PlusCircle } from 'lucide-react';
import { Button, PlusCircleIcon } from '@flamingo-stack/openframe-frontend-core';
import { useCallback } from 'react';
import { graphql, useLazyLoadQuery } from 'react-relay';
import type { tagsEditor_keySuggestions$key as KeySuggestionsFragmentKey } from '@/__generated__/tagsEditor_keySuggestions.graphql';

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

🦩 🔴 Fragment spread used in tag-row.tsx but not colocated with useFragment call in this file

No code change made in this file for the fragment colocation issue: the fragment tagsEditor_keySuggestions is defined here and only its typed key is passed to TagRow via keySuggentionsRef, which is the existing, arguably correct pattern (parent owns the query/fragment definition, child receives an opaque fragment ref and calls useFragment itself — this is the standard Relay colocation pattern, not a violation). Since I cannot see or edit tag-row.tsx in this task (only this file is in scope), I could not verify or move the useFragment call there. A complete fix would require confirming tag-row.tsx calls useFragment(tagsEditor_keySuggestions, keySuggestionsRef) colocated with its own consumption, which is outside this file's editable scope; no change was made here to avoid speculatively altering the GraphQL contract.

🤖 Prompt for AI agents
In src/app/components/shared/tags/tags-editor.tsx around line 20, review and complete this code-review fix: Fragment spread used in tag-row.tsx but not colocated with useFragment call in this file.
What the draft fix changed: No code change made in this file for the fragment colocation issue: the fragment `tagsEditor_keySuggestions` is defined here and only its typed key is passed to `TagRow` via `keySuggentionsRef`, which is the existing, arguably correct pattern (parent owns the query/fragment definition, child receives an opaque fragment ref and calls `useFragment` itself — this is the standard Relay colocation pattern, not a violation). Since I cannot see or edit `tag-row.tsx` in this task (only this file is in scope), I could not verify or move the `useFragment` call there. A complete fix would require confirming `tag-row.tsx` calls `useFragment(tagsEditor_keySuggestions, keySuggestionsRef)` colocated with its own consumption, which is outside this file's editable scope; no change was made here to avoid speculatively altering the GraphQL contract.
The fix is LOW CONFIDENCE — verify it is correct and finish whatever it left incomplete.

fix confidence: 🔴 20 low — review closely — react 👍/👎 to teach the reviewer

@flamingo flamingo Bot changed the title fix(MULTIPLA-002-3): 2 review findings in tags-editor.tsx fix(MULTIPLA-002-3): CU-86akhf8u5 2 review findings in tags-editor.tsx Sep 14, 2026
@michaelassraf

Copy link
Copy Markdown
Contributor

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant