Skip to content

Conversation

@Mowd
Copy link
Contributor

@Mowd Mowd commented Oct 7, 2025

Fix #759 : Add discard option for pinned tabs in CloseTab command

  • Change closePinned setting from boolean to dropdown with three options:
    • none: do nothing when closing pinned tabs
    • close: remove pinned tabs (previous behavior)
    • discard: unload tab content but keep the tab
  • Implement browser.tabs.discard() API for pinned tabs
  • Update UI template to use select dropdown instead of checkbox
  • Add backward compatibility for boolean settings
  • Update translations for en, zh_TW, zh_CN, ja_JP, and ko_KR locales

- Change closePinned setting from boolean to dropdown with three options:
  * none: do nothing when closing pinned tabs
  * close: remove pinned tabs (previous behavior)
  * discard: unload tab content but keep the tab
- Implement browser.tabs.discard() API for pinned tabs
- Update UI template to use select dropdown instead of checkbox
- Add backward compatibility for boolean settings
- Update translations for en, zh_TW, zh_CN, ja_JP, and ko_KR locales
@Robbendebiene
Copy link
Owner

I think this will be automatically possible using #765 via Multi Purpose Command:

  • Multi Purpose Command:
    • Close Tab (close pinned = false)
    • Discard Tab

Can you confirm this?

Since I plan to elevate the multi purpose command functionality in the next major release (see #715) I don't want to add new settings unless they are really necessary.

@Robbendebiene
Copy link
Owner

Oh and again, thanks for all the work and the detailed PR description. I really appreciate it.

@Mowd
Copy link
Contributor Author

Mowd commented Oct 7, 2025

I think this will be automatically possible using #765 via Multi Purpose Command:

* _Multi Purpose Command_:
  
  * _Close Tab_ (close pinned = false)
  * _Discard Tab_

Can you confirm this?

Since I plan to elevate the multi purpose command functionality in the next major release (see #715) I don't want to add new settings unless they are really necessary.

Sure! Using Multi-Purpose Command with the unload + close command is totally doable.
It only requires a little bit of knowledge or some documents that you need to disable the close pin tab of the close command and combine it with the unload command to achieve the same effect. Not very intuitive, but it can be done.

@Robbendebiene
Copy link
Owner

I agree that it is (currently) not very discoverable nor user friendly. On the other hand I usually try to mimic Firefox's default behaviour which does not unload pinned tabs on Ctrl + W. So I guess it is a Zen browser specific feature.

I'm sorry for all the effort you put into this but I'm closing this in favour of the new Unload Tab command in combination with the Multi Purpose Command.

At the end the multi purpose command offers way more options like focusing the first tab when the gesture is performed on a pinned tab.

Here is a little screenshot of the new UI (work in progress):

grafik

@Mowd
Copy link
Contributor Author

Mowd commented Oct 9, 2025

No problem. I just switched to Zen browser several days ago and found this. Thanks for your work and for providing such a good extension.

@Robbendebiene
Copy link
Owner

Appreciate it. Thank you for your understanding.

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.

zen 浏览器中关闭标签页的手势,会导致固定的标签页被取消固定

2 participants