Zum Inhalt springen
Skillpedia
Websites & UI (Frontend)75k · #2794

css-at-property

Was er macht

Dieser Skill erklärt, wie man Typ und Startwert von CSS-Custom-Properties festlegt, damit der Browser sie animieren kann. Er ist für Frontend-Entwickler gedacht, die animierte Verläufe oder typisierte Designtokens bauen.

Wann du ihn nutzt

  • ✓Wenn du einen Verlauf oder eine Farbvariable sanft animieren willst.
  • ✓Wenn sich eine Custom Property abrupt ändert, statt zu übergehen.
  • ✓Wenn du Designtokens mit festgelegtem Typ und Gültigkeitsbereich willst.

Link zum Skill

https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/css-at-property/SKILL.md

Kopiere ihn und füge ihn in deine KI ein (Claude, ChatGPT oder Cursor) mit der Bitte, den Anweisungen zu folgen.

So nutzt du ihn

Am einfachsten: Kopiere die Nachricht und füge sie in deine KI ein. Sie liest den Skill und folgt den Anweisungen.

Fertige Nachricht zum Einfügen

Nutze diesen Skill, um mir zu helfen: https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/css-at-property/SKILL.md Lies die SKILL.md unter diesem Link und folge ihren Anweisungen für meine Aufgabe.
Soll deine KI Skills wie diesen selbst finden?Installiere den kostenlosen Skillpedia-MCP: eine Zeile, und sie durchsucht vor jeder Aufgabe 15.000+ Skills.In 1 Minute installieren →

Beispielanfrage an deine KI

“Lass den Verlauf in meinem Hero-Bereich sanft animieren, indem du seine Farbvariablen registrierst.”

5 neue Skills pro Woche. 1 Minute Lesezeit.

So funktioniert es

Der Agent fügt at-property-Deklarationen mit einem Syntaxtyp, einem Anfangswert und einer Vererbungseinstellung für jede Custom Property hinzu, die in einer Animation oder einem Übergang vorkommt.

Technischer Inhalt (originale SKILL.md)

Originaltext des Autors, auf Englisch, direkt von GitHub.

Register CSS custom properties with @property for animation and type safety

CSS custom properties are powerful but limited by default: they are untyped string substitutions that the browser cannot interpolate during transitions or animations. Registering a property with @property gives the browser the information it needs to animate between values, validate token assignments, and scope inheritance — turning custom properties from string macros into first-class typed values. This unlocks gradient animations, typed design tokens, and scoped component theming that are impossible with unregistered properties.

Quick Reference

  • Unregistered custom properties cannot be animated — they transition as discrete strings
  • @property specifies syntax (color, length, number), initial-value, and inherits
  • Registered properties enable smooth interpolation for gradients and complex values
  • inherits: false creates scoped tokens that do not cascade to children

Check

Review the CSS custom properties in this file. Identify any properties that are used in transitions or animations — these require @property registration to animate correctly.

Fix

Add @property registrations for the custom properties used in transitions or animations in this CSS. Include the correct syntax descriptor, an initial-value, and the appropriate inherits value.

Explain

Explain how @property works, why unregistered custom properties cannot be animated, what the syntax descriptor values mean, and how inherits controls cascade behaviour.

Code Review

Inspect all CSS transitions and animations that reference custom properties. Flag any custom property used in a transition or animation that is not registered with @property, and flag any @property registration that is missing initial-value.


For full implementation details, code examples, and framework-specific guidance, see references/rule.md.

Rule page: https://frontendchecklist.io/rules/css/css-at-property

Häufige Fragen

Warum können normale Custom Properties nicht animiert werden?

Der Skill sagt, nicht registrierte Custom Properties werden als Text behandelt, sodass der Browser nicht zwischen Werten überblenden kann.

Was bewirkt inherits false?

Der Skill sagt, es erzeugt begrenzte Tokens, die nicht an untergeordnete Elemente weitergegeben werden.

Welche Werttypen kann man festlegen?

Der Skill nennt Beispiele wie Farbe, Länge und Zahl.

Details

Originalbeschreibung des Autors

Use when implementing animated gradients, complex CSS transitions that involve custom property values, or building a typed design token system where custom property misuse should produce visible errors.

repo: thedaviddias/Front-End-Checklist

Beliebtheit

GitHub-Sterne
75k
Platz im Ranking
#2794
Lizenz
MIT
Aktualisiert
31.10.2026

Ist dieser Skill nützlich?

0

Anmelden um abzustimmen.

Kommentare

  • …

Weitere Skills aus diesem Repository

Ähnliche Skills