improvement(cmdk): refactor search modal to use cmdk + fix icon SVG IDs#3044
Merged
waleedlatif1 merged 11 commits intostagingfrom Jan 28, 2026
Merged
improvement(cmdk): refactor search modal to use cmdk + fix icon SVG IDs#3044waleedlatif1 merged 11 commits intostagingfrom
waleedlatif1 merged 11 commits intostagingfrom
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
Greptile OverviewGreptile SummaryThis PR refactors the search modal from a custom implementation to use the Key Changes:
Issues Found:
Confidence Score: 4/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant User
participant Sidebar
participant SearchStore
participant PermissionConfig
participant SearchModal
participant CMDK
Note over Sidebar,SearchStore: On Sidebar Mount
Sidebar->>PermissionConfig: usePermissionConfig()
PermissionConfig-->>Sidebar: { filterBlocks }
Sidebar->>SearchStore: initializeData(filterBlocks)
SearchStore->>SearchStore: Check isInitialized flag
alt Not Initialized
SearchStore->>SearchStore: getAllBlocks()
SearchStore->>SearchStore: Filter & process blocks/tools/triggers
SearchStore->>SearchStore: Set isInitialized = true
end
Note over User,CMDK: User Opens Search Modal (Cmd+K)
User->>SearchModal: Press Cmd+K
SearchModal->>SearchStore: Read pre-computed data
SearchStore-->>SearchModal: { blocks, tools, triggers, toolOperations, docs }
SearchModal->>CMDK: Render Command palette with data
CMDK-->>User: Display search interface
Note over User,CMDK: User Searches
User->>CMDK: Type search query
CMDK->>CMDK: customFilter() scores items
CMDK-->>User: Show filtered results
Note over User,SearchModal: User Selects Item
User->>CMDK: Select item (Enter/Click)
alt Block/Tool/Trigger
CMDK->>SearchModal: handleBlockSelect()
SearchModal->>SearchModal: Dispatch 'add-block-from-toolbar' event
else Tool Operation
CMDK->>SearchModal: handleToolOperationSelect()
SearchModal->>SearchModal: Dispatch with presetOperation
else Workflow/Workspace
CMDK->>SearchModal: handleWorkflowSelect()
SearchModal->>SearchModal: router.push(href)
else Doc/Page
CMDK->>SearchModal: handleDocSelect()
SearchModal->>SearchModal: window.open(href)
end
SearchModal->>SearchModal: onOpenChange(false)
SearchModal-->>User: Close modal
|
...im/app/workspace/[workspaceId]/w/components/sidebar/components/search-modal/search-modal.tsx
Show resolved
Hide resolved
...im/app/workspace/[workspaceId]/w/components/sidebar/components/search-modal/search-modal.tsx
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
...im/app/workspace/[workspaceId]/w/components/sidebar/components/search-modal/search-modal.tsx
Show resolved
Hide resolved
waleedlatif1
added a commit
that referenced
this pull request
Jan 28, 2026
…Ds (#3044) * improvement(cmdk): refactor search modal to use cmdk + fix icon SVG IDs * chore: remove unrelated workflow.tsx changes * chore: remove comments * chore: add devtools middleware to search modal store * fix: allow search data re-initialization when permissions change * fix: include keywords in search filter + show service name in tool operations * fix: correct filterBlocks type signature * fix: move generic to function parameter position * fix(mcp): correct event handler type for onInput * perf: always render command palette for instant opening * fix: clear search input when modal reopens
waleedlatif1
added a commit
that referenced
this pull request
Jan 28, 2026
* fix(workflow): update container dimensions on keyboard movement * fix(workflow): avoid duplicate container updates during drag Add !change.dragging check to only handle keyboard movements in onNodesChange, since mouse drags are already handled by onNodeDrag. * fix(workflow): persist keyboard movements to backend Keyboard arrow key movements now call collaborativeBatchUpdatePositions to sync position changes to the backend for persistence and real-time collaboration. * improvement(cmdk): refactor search modal to use cmdk + fix icon SVG IDs (#3044) * improvement(cmdk): refactor search modal to use cmdk + fix icon SVG IDs * chore: remove unrelated workflow.tsx changes * chore: remove comments * chore: add devtools middleware to search modal store * fix: allow search data re-initialization when permissions change * fix: include keywords in search filter + show service name in tool operations * fix: correct filterBlocks type signature * fix: move generic to function parameter position * fix(mcp): correct event handler type for onInput * perf: always render command palette for instant opening * fix: clear search input when modal reopens * fix(helm): move rotationPolicy under privateKey for cert-manager compatibility (#3046) * fix(helm): move rotationPolicy under privateKey for cert-manager compatibility * docs(helm): add reclaimPolicy Retain guidance for production database storage * fix(helm): prevent empty branding ConfigMap creation * fix(workflow): avoid duplicate position updates on drag end Check isInDragOperation before persisting in onNodesChange to prevent duplicate calls. Drag-end events have dragStartPosition still set, while keyboard movements don't, allowing proper distinction.
Closed
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Type of Change
Testing
Tested manually
Checklist