fix(ui): modifier-key-new-tab#15920
Conversation
There was a problem hiding this comment.
Pull request overview
This PR attempts to add “open in new tab/window” behavior (Cmd/Ctrl/Shift+click) for items in the folder browser and for clickable table cells in the admin UI, aiming to align modifier-click behavior with standard web link interactions.
Changes:
- Add modifier-click handling in the folder item click handler to open the clicked document in a new tab/window.
- Add modifier-click handling for
DefaultCellwhen it renders as abuttonto open the corresponding document URL in a new tab/window. - Refactor default collection item URL generation in
DefaultCellinto a small helper (getItemUrl).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| packages/ui/src/providers/Folders/index.tsx | Adds modifier-click logic to open documents in a new tab/window from the folder view, altering existing selection behavior. |
| packages/ui/src/elements/Table/DefaultCell/index.tsx | Adds modifier-click logic for button-rendered cells and deduplicates URL construction via getItemUrl. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Hi @ossaidqadri, fyi, this looks like a duplicate of #15873 |
|
Thanks @jhb-dev for pointing this out! I just reviewed #15873 and noticed it has the same bugs that the reviewer comments identified in my PR: Issues in #15873:
My PR #15920 fixes both:
Both PRs solve the same user need, but mine addresses the code review feedback and is more complete. Happy to coordinate with @mibragimov on the best path forward - whether that's closing this in favor of theirs (with the bugs fixed) or vice versa. |
|
This PR needs e2e tests that verifies the functionality in multiple places to avoid regressions. Use the playwright utils to simulate the keybinds, there must be a way to simulate them for both windows and macos |
|
On a deeper review I'm closing this PR and it's something we should address and fix in v4 due to the new UI/UX considerations. |
Fixes #15837
Description
This PR adds support for opening list entries and folder cards in new tabs when using modifier keys (Cmd/Ctrl+Click or Shift+Click), matching standard web browser behavior.
Changes
Security
Testing