Skip to content

Conversation

papa-Leo
Copy link

@papa-Leo papa-Leo commented Sep 28, 2025

This PR adds some new commands to the URL bar, as discussed in #10577:

Default commands

  • Reset Pinned Tab
  • Replace Pinned URL with Current
  • Duplicate Tab
  • Reopen Closed Tab
  • Bookmark Tab
  • Move Current/Selected Tabs to Folder
  • Move Current/Selected Tabs to Space

Advanced preference commands

  • Create New Workspace
  • Delete Current Workspace
  • Unsplit Tabs
  • Unsplit Current Tab
  • Split View Vertical
  • Split View Horizontal
  • Split View Grid
  • Copy Current URL Markdown
  • Search Bookmarks
  • Swap Split Tabs
  • Open in Container

💬 More suggestions are welcome, please put them in the comments.

@papa-Leo papa-Leo requested a review from mr-cheffy as a code owner September 28, 2025 13:48
@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. Feature labels Sep 28, 2025
@mr-cheffy
Copy link
Member

I'll convert this into a draft since I see not all of them are done. Please ping me or undraft it once its ready for review, thanks!

@mr-cheffy mr-cheffy marked this pull request as draft September 28, 2025 14:04
@12th-devs
Copy link
Contributor

Is the warning for deleting the current workspace still present? I would not want someone to be typing something, have that prioritized then have there main workspace deleted with no hope

@papa-Leo
Copy link
Author

Is the warning for deleting the current workspace still present? I would not want someone to be typing something, have that prioritized then have there main workspace deleted with no hope

I've implemented this with the cmd_zenCtxDeleteWorkspace, so yes the confirmation is still present. 👍

@12th-devs
Copy link
Contributor

12th-devs commented Sep 28, 2025

Is the warning for deleting the current workspace still present? I would not want someone to be typing something, have that prioritized then have there main workspace deleted with no hope

I've implemented this with the cmd_zenCtxDeleteWorkspace, so yes the confirmation is still present. 👍

Awesome!

(Sorry for not looking at the pr)

@mr-cheffy
Copy link
Member

To be honest, I dont think deleting or creating spaces is something that should be considered "quick action"...

@papa-Leo
Copy link
Author

To be honest, I don't think deleting or creating spaces is something that should be considered "quick action"...

I’ve implemented them because they’re useful for my personal workflow, but it’s true that they’re a bit niche.

Obviously the final decision is up to you, but I propose that they’re disabled by default, and can be enabled with an advanced preference flag. This keeps things simple but makes it available for those who need it.

I’d love to hear thoughts on this

@12th-devs
Copy link
Contributor

This file might be of help to you: https://github.com/BibekBhusal0/zen-custom-js/blob/main/command-palette/all-commands.js

@papa-Leo
Copy link
Author

This file might be of help to you: https://github.com/BibekBhusal0/zen-custom-js/blob/main/command-palette/all-commands.js

This is great! Thanks for sharing 😀

@NexusOnePlus
Copy link

I think it could also be useful to have commands for working with containers.

My suggestions would be:

  • Use Container (Select a container and reload the current tab in it)
  • Open in Container (Choose a container and open the query/URL in a new tab within that container)

@mr-cheffy
Copy link
Member

I also wouldn't like having Copy Current URL Markdown and all of the split related commands here as they would add clutter when the actions aren't really that necessary or alternatives already exist

@papa-Leo
Copy link
Author

I also wouldn't like having Copy Current URL Markdown and all of the split related commands here as they would add clutter when the actions aren't really that necessary or alternatives already exist

@mr-cheffy what do you think about my previously mentioned suggestion that these extra commands are disabled by default, but can be enabled with an advanced preference flag for power users?
These extra commands would make a huge difference to my workflow, and I'm sure that's true for others.

@papa-Leo
Copy link
Author

I see the "command palette" feature as a way to make less frequently used commands more accessible - especially those with complicated keyboard shortcuts or no shortcuts at all. That’s why I was focusing on these specific commands.

But I understand if this approach doesn’t align with your goal for the feature. This is your project, so I'll go with whatever you choose.
I appreciate your guidance

@papa-Leo
Copy link
Author

papa-Leo commented Sep 29, 2025

These are the commands I recommend moving to advanced preferences:

  • Split View Vertical
  • Split View Horizontal
  • Split View Grid
  • Unsplit All Tabs
  • Create New Workspace
  • Delete Current Workspace
  • Copy Current URL Markdown
  • Move Tab to Folder
  • Move Tab to Workspace
  • Container related commands as mentioned by @NexusOnePlus previously

Do you have an upper limit in mind to the number of commands that are enabled by default?

@willrossignol
Copy link

I found myself looking for a "Bookmark current tab" action while using the new URL bar, that'd be sweet!

@mr-cheffy
Copy link
Member

I agree @papa-Leo, the pref should be named zen.urlbar.suggestions.quick-actions.advanced.

Move Tab to Folder
Move Tab to Workspace

These however can stay as they are more common actions

@papa-Leo papa-Leo force-pushed the new-urlbar-commands branch from 6dde6c7 to b1a4046 Compare October 1, 2025 14:10
@mr-cheffy
Copy link
Member

@papa-Leo actions are heuristic, meaning they need to be fetched fast, and getting the values of preferences are very slow.

I would rather this pref be considered a startup pref. Meaning it'll only be read once.

e.g.

var actions = [
  { normal action },
  { normal action },
  ...(advanced pref getter) ? [ advanced prefs ] : []
]

@mr-cheffy
Copy link
Member

Let me know when its ready for a review!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants