controlling-command-visibility
CommunityShow VS commands only when relevant.
Software Engineering#command#extensions#visibility#ui-context#visual-studio#before-query-status#provideuicontextrule
Authormadskristensen
Version1.0.0
Installs0
System Documentation
What problem does it solve?
This guidance helps developers ensure Visual Studio commands are visible and enabled only in the appropriate UI contexts, reducing clutter and preventing unintended actions.
Core Features & Use Cases
- Declarative visibility using VisibilityConstraints in .vsct or VisibleWhen in VisualStudio.Extensibility to show/hide commands before a package loads.
- UIContext-based rule definition with ProvideUIContextRule or equivalent to activate contexts like file type, editor content, or solution state.
- Runtime enablement and visibility adjustments after package initialization via BeforeQueryStatus and related APIs, with optional delegation back to UIContext using Command.Supported.
- Cross-model coverage for Visual Studio extension development using out-of-process, in-process Toolkit, or legacy VSSDK approaches.
Quick Start
Define UIContext rules and runtime checks to conditionally display VS commands.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: controlling-command-visibility Download link: https://github.com/madskristensen/vs-agent-plugins/archive/main.zip#controlling-command-visibility Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.