ux-css-layout

Applies VS Code CSS conventions for layouts, scrolling, and text truncation.

Updated Apr 28, 2026
Ready to run
npx skills add https://github.com/CokiStudios/cokistudios.github.io --skill ux-css-layout-cokistudios
💬 Prompt for ChatGPT / Claude Chat▼
Please help me install this Agent Skill.
Skill: ux-css-layout
Source: https://github.com/CokiStudios/cokistudios.github.io/tree/main/vscode-src/.github/skills/ux-css-layout
Command: npx skills add https://github.com/CokiStudios/cokistudios.github.io --skill ux-css-layout-cokistudios

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Writing CSS in the VS Code codebase requires following strict conventions for file organization, class naming, layout systems, and text overflow handling. This Skill prevents common visual bugs like clipped text without ellipsis, broken flex truncation, and off-scale design token values. ## Core Features & Use Cases - CSS Conventions & Naming: Enforces co-located CSS files, monaco- prefixed class naming, standard sizes, and a strict no-new-!important policy. - Programmatic Layout Patterns: Guides usage of SplitView, Grid, and scrollable elements (SmoothScrollableElement, DomScrollableElement) instead of CSS media queries. - Text Overflow & Design Tokens: Provides the required three-property ellipsis pattern, flex min-width: 0 fixes, hover tooltips for truncated text, and the --vscode-* size token ramp for spacing, radius, font, codicon, and stroke values. - Use Case: When building a new view pane with a resizable header label, use this Skill to correctly apply the ellipsis pattern with min-width: 0 on the flex child and wire up a delayed hover showing the full text. ## Quick Start Ask the AI to review or write CSS for a VS Code workbench component following the ux-css-layout conventions, including ellipsis handling and design-system size tokens.

Frequently Asked Questions about ux-css-layout

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I make text truncate with ellipsis in CSS flex containers?▼

Text truncation in flex containers requires setting min-width: 0 on the flex child, because flex items default to min-width: auto and refuse to shrink below content width. Combine this with overflow: hidden, white-space: nowrap, and text-overflow: ellipsis.

How does VS Code handle responsive layout without media queries?▼

VS Code uses a programmatic constraint-based layout system instead of CSS media queries. Views declare minimumSize and maximumSize, and SplitView or Grid distribute space using LayoutPriority, snap behavior, and ResizeObserver for container-aware sizing.

What CSS class naming conventions does VS Code use?▼

VS Code uses the monaco- prefix for major components like .monaco-workbench and .monaco-split-view2, modifier classes like .vertical, and state classes like .visible, .focused, and .active. Feature-specific classes use kebab-case without a prefix.

Why is text-overflow ellipsis not working in my CSS?▼

Ellipsis fails when any of the three required properties are missing: overflow: hidden, white-space: nowrap, and text-overflow: ellipsis must all be present. Inside flex containers, you must also add min-width: 0 to the truncating element.

Can I use !important in VS Code CSS?▼

New !important declarations are not allowed in VS Code CSS. Resolve cascade conflicts by increasing selector specificity with component or state-class prefixes instead. The narrow exception is outline: 0 !important for shared focus-indicator suppression.

What are the VS Code design-system size tokens for CSS?▼

VS Code provides --vscode-* CSS variables for spacing (0 to 40px scale), corner radius (xSmall to circle), font size and weight, codicon sizes (16px or 12px only), and a single 1px stroke thickness. Off-scale px values should snap to the nearest scale value, ties rounding up.