Skip to content

Conversation

@gonfunko
Copy link
Contributor

@gonfunko gonfunko commented Jan 8, 2026

The basics

The details

Resolves

Fixes #9179

Proposed Changes

This PR updates the ContextMenuRegistry interfaces such that CoreRegistryItem includes an optional preconditionFn, which is required for ActionRegistryItem, and optional for SeparatorRegistryItem. Previously, SeparatorRegistryItem did not have it at all, so there was no way to restrict separators to particular scopes other than the soft-deprecated and less-flexible scopeType field.

@gonfunko gonfunko requested a review from a team as a code owner January 8, 2026 22:00
@gonfunko gonfunko requested a review from maribethb January 8, 2026 22:00
@gonfunko gonfunko changed the title refactor: Make preconditionFn part of all context menu items refactor: Make preconditionFn part of all context menu items Jan 8, 2026
@gonfunko gonfunko merged commit 25c6187 into main Jan 9, 2026
13 of 16 checks passed
@gonfunko gonfunko deleted the context-preconditions branch January 9, 2026 21:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Move preconditionFn to CoreRegistryItem

3 participants