diff --git a/UPGRADE.md b/UPGRADE.md index ef9c2af7..c2551dda 100644 --- a/UPGRADE.md +++ b/UPGRADE.md @@ -8,35 +8,43 @@ the change is inside the components. What reaches an application is below, in th ### 1. Breakpoints are M3's window size classes -Tailwind's `sm:`, `md:`, `lg:`, `xl:` and `2xl:` no longer compile. The variants are -`medium:` (600px), `expanded:` (840px), `large:` (1200px) and `extra-large:` (1600px), plus -`max-medium:` and friends for "below"; compact is everything below `medium`. Replace every -prefix in the application's views: +Tailwind's `sm:`, `md:`, `lg:`, `xl:` and `2xl:` no longer compile, and there are no responsive +variants in their place: the breakpoints are M3's window size classes — compact below 600px, then +medium (600px), expanded (840px), large (1200px) and extra-large (1600px) — and only those. A +layout component takes the class as a prop (`hide-below`, `hide-from`, `stack-below`, ``'s +`columns` map); the application's own CSS writes the width as a range media query: | Was | Becomes | |---|---| -| `sm:` / `max-sm:` (640) | `medium:` / `max-medium:` (600) | -| `md:` / `max-md:` (768) | `medium:` or `expanded:` — choose by what the layout means | -| `lg:` / `max-lg:` (1024) | `expanded:` / `max-expanded:` (840) | -| `xl:` / `max-xl:` (1280) | `large:` / `max-large:` (1200) | -| `2xl:` (1536) | `extra-large:` (1600) | +| `sm:` / `max-sm:` (640) | `medium` · `@media (width >= 600px)` / `(width < 600px)` | +| `md:` / `max-md:` (768) | `medium` or `expanded` — choose by what the layout means | +| `lg:` / `max-lg:` (1024) | `expanded` · `@media (width >= 840px)` / `(width < 840px)` | +| `xl:` / `max-xl:` (1280) | `large` · `@media (width >= 1200px)` / `(width < 1200px)` | +| `2xl:` (1536) | `extra-large` · `@media (width >= 1600px)` | -Scripts read the same numbers from `resources/js/breakpoints.js` (`from('expanded')`, -`upTo('medium')`). `DesignGuard` reports every leftover prefix with its replacement. +`