Box Model
Box-Modell
Das CSS-Box-Modell erklärt die Größe eines Elements. Jede Box hat Inhalt, Auffüllung (Padding), einen Rahmen (Border) und einen Außenabstand (Margin).
Ein weiteres Beispiel
Eine 320px-Karte ragt nicht mehr heraus, nachdem border-box Padding und Rand in diese Breite einbezieht.
Hauptteile
- 01Outer constraint
- 02Content and spacing model
- 03Computed size or reflow result
Verwenden Sie es, wenn
Prüfe das Box-Modell, wenn die echte Größe nicht zur eingestellten Breite oder Höhe passt.
Nutze es nicht, wenn
Verdecke niemals einen Box-Modell-Fehler mit Zahlen, die keinen klaren Grund haben.
In Code verwendeter Name
box-sizing: border-box Vor dem Ausliefern
Check content order, shared design values, component consistency, contrast, zoom, and layout changes by screen size. Verify every theme, language, and state. If there is motion, offer an equal reduced-motion experience.
Outcome: Complete the task with Box-Modell (Box Model). User context: Eine 320px-Karte ragt nicht mehr heraus, nachdem border-box Padding und Rand in diese Breite einbezieht. Design concept to apply: Box-Modell (Box Model). Why it fits: Prüfe das Box-Modell, wenn die echte Größe nicht zur eingestellten Breite oder Höhe passt. Do not use it when: Verdecke niemals einen Box-Modell-Fehler mit Zahlen, die keinen klaren Grund haben. Design requirements: Set the content order, shared design values, and reusable components. Define how the layout changes by screen size and state. Keep useful design choices separate from decoration. Inclusion and resilience: Check contrast, zoom, languages, themes, and reduced motion when needed. Do not use color or effects as the only way to show meaning. Acceptance criteria: The design stays clear on phones and desktops, at zoom, in every theme, and in all supported languages. Interactive states stay clear and consistent. Evidence and limits (evidence boundary): Ein formelles Dokument kann trotzdem ein Entwurf, ein Release Candidate oder die finale Version sein. Prüfe seinen Status und die Browser- oder Plattform-Unterstützung. Unknowns to confirm: Brand limits, amount of content, supported themes and languages, target devices, and design-system rules.
Diese Anfrage prüfen
Review how Box-Modell (Box Model) is used now. Definition: Das CSS-Box-Modell erklärt die Größe eines Elements. Jede Box hat Inhalt, Auffüllung (Padding), einen Rahmen (Border) und einen Außenabstand (Margin). Release checks: Check content order, shared design values, component consistency, contrast, zoom, and layout changes by screen size. Verify every theme, language, and state. If there is motion, offer an equal reduced-motion experience. Before changing code, list the evidence, gaps, severity, and the smallest safe fix.