Conversation
… for profile filtering
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
📝 WalkthroughWalkthroughThis PR replaces the single ChangesSkills Tag Filtering
Sequence Diagram(s)sequenceDiagram
participant User
participant DiscoverFilters
participant useDiscoverFilters
participant getPopularTags
User->>DiscoverFilters: open Discover page
DiscoverFilters->>useDiscoverFilters: request filters
useDiscoverFilters->>getPopularTags: compute tags from profiles
getPopularTags-->>useDiscoverFilters: topTags, allTags
useDiscoverFilters-->>DiscoverFilters: topTags, allTags
User->>DiscoverFilters: type in skill search
DiscoverFilters->>DiscoverFilters: filter allTags into visibleTags
User->>DiscoverFilters: select tag from dropdown
DiscoverFilters->>DiscoverFilters: close dropdown, apply selected tag
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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 |
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/features/discover/components/DiscoverFilters.tsx`:
- Around line 123-238: The autocomplete in DiscoverFilters should use basic
combobox semantics so assistive tech can understand the popup. Update the
input/search block to wire the dropdown with aria-expanded, aria-controls, and
an appropriate combobox-related role/state, and give the suggestions container a
listbox-style role tied to the input. Keep the existing tag selection behavior
in handleTagSelect, setIsTagDropdownOpen, and the dropdownRef logic, and also
add Escape-to-close handling for the tag search popup.
- Around line 149-176: The new autocomplete search UI in DiscoverFilters needs
accessible names for both controls: add a proper label/aria-label to the
skill-search input instead of relying on placeholder text, and give the
icon-only clear button an accessible label as well. Update the input and button
in DiscoverFilters so screen readers can identify their purpose, using the
existing Search and X controls as the reference points.
In `@src/features/discover/model/discover.selectors.ts`:
- Around line 9-28: The tag aggregation in getPopularTags currently treats
differently cased strings as separate values, which splits counts and breaks
selectedTag matching. Update the normalization logic used in this selector so
canvas.loves and canvas.comfort entries are converted to a canonical form before
counting and before building allTags/topTags, or ensure the canonical key is
used consistently across filtering. Keep the behavior localized in
getPopularTags and any related tag comparison helpers so React/react variants
resolve to the same tag.
🪄 Autofix (Beta)
❌ Autofix failed (check again to retry)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: c3ccfb1c-a5fd-4fce-8768-64e4ce7def54
📒 Files selected for processing (3)
src/features/discover/components/DiscoverFilters.tsxsrc/features/discover/hooks/useDiscoverFilters.tssrc/features/discover/model/discover.selectors.ts
|
Note Autofix is a beta feature. Expect some limitations and changes as we gather feedback and continue to improve it. An unexpected error occurred while generating fixes: Repository rule violations found Changes must be made through a pull request. |
|
Note Autofix is a beta feature. Expect some limitations and changes as we gather feedback and continue to improve it. Fixes Applied SuccessfullyFixed 1 file(s) based on 1 unresolved review comment. A stacked PR containing fixes has been created.
Time taken: |
|
Note Autofix is a beta feature. Expect some limitations and changes as we gather feedback and continue to improve it. Fixes Applied SuccessfullyFixed 1 file(s) based on 1 unresolved review comment. A stacked PR containing fixes has been created.
Time taken: |
|
Note Autofix is a beta feature. Expect some limitations and changes as we gather feedback and continue to improve it. Autofix skipped. No unresolved CodeRabbit review comments with fix instructions found. |
Título do PR:
Feat: Busca inteligente e Autocomplete de Skills no Discover
Descrição:
Qual é o objetivo deste PR?
Melhorar significativamente a experiência de busca e filtragem de perfis na aba Discover. Substituímos a lista fixa (que exibia apenas as 8 tags mais populares e ocupava muito espaço) por uma barra de busca dinâmica, permitindo que os usuários encontrem tecnologias de nicho.
Mudanças Principais:
getPopularTagsno seletor foi refatorada para retornar o "Top 3" de tags mais usadas e, simultaneamente, uma lista completa e alfabética de todas as skills únicas extraídas dos perfis carregados (camposlovesecomfort).DiscoverFilters.tsx):Testes Realizados:
Summary by CodeRabbit
New Features
Bug Fixes