fix: extension action 'context' category #2369
Merged
JammingBen merged 2 commits intomainfrom Apr 16, 2026
Merged
Conversation
Makes sure that extension actions of category `context` are the only actions that get used for the "Open with" menu while also being candidates for default actions. This prevents certain actions from showing up multiple times in the context menu.
JammingBen
commented
Apr 14, 2026
Comment on lines
-103
to
-106
| .filter( | ||
| (action) => | ||
| isNil(action.category) || action.category === 'context' || action.category === 'actions' | ||
| ) |
Member
Author
Member
There was a problem hiding this comment.
no clue 😅 should be fine like you have it now.
Comment on lines
+21
to
+32
| /** | ||
| * Determines where an action will be displayed in the resource context menu. | ||
| * | ||
| * - actions: action will appear in the "actions" section of the resource context menu. | ||
| * - context: action will appear in the "Open with..."-menu of the resource context menu. | ||
| * It will also be the default when no other action is available for the given file type. | ||
| * - share: action will appear in the "shares" section of the resource context menu. | ||
| * - sidebar: action will appear in the "sidebar" section of the resource context menu. | ||
| * | ||
| * @default actions | ||
| */ | ||
| category?: ActionCategory |
Member
Author
There was a problem hiding this comment.
I don't now what we were thinking when naming these, but it's super confusing to me. I hope this comment brings at least some clarity to devs using this interface.
kulmann
approved these changes
Apr 16, 2026
Comment on lines
-103
to
-106
| .filter( | ||
| (action) => | ||
| isNil(action.category) || action.category === 'context' || action.category === 'actions' | ||
| ) |
Member
There was a problem hiding this comment.
no clue 😅 should be fine like you have it now.
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.
Makes sure that extension actions of category
contextare the only actions that get used for the "Open with" menu while also being candidates for default actions.This prevents certain actions from showing up multiple times in the context menu.
fixes #2256