You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs: update validation workflow with styling_preflight and resolve_css_api tools
Adds new tools to the anti-hallucination workflow context file that agents
read. Promotes styling_preflight as the recommended one-call CSS validation
tool and adds resolve_css_api to the validator table.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Returns: component's full style API (parts, tokens, slots), valid/invalid status for every `::part()` and token reference, Shadow DOM/theme issues, a correct CSS snippet, and a pass/fail verdict.
18
+
19
+
## Full Code Validation
20
+
21
+
For comprehensive validation (HTML + CSS + JS), call `validate_component_code`:
|`resolve_css_api`| Validates every `::part()`, CSS custom property, and slot reference against CEM data — catches hallucinated names with fuzzy-match suggestions |
41
58
|`check_shadow_dom_usage`| 15 patterns: descendant piercing, ::part() misuse (chaining, structural combining, descendant selectors), deprecated /deep/>>>/::deep, ::slotted() in consumer CSS + compound/descendant misuse, :host/:host-context() in consumer CSS, !important on tokens, display:contents on host, unknown parts, misspelled tokens |
0 commit comments