Take Tailwind out of the package, and its detection out of the guard
tests / feature (8.4) (push) Successful in 2m0s
tests / feature (8.5) (push) Successful in 2m0s
tests / browser (chrome, chromium) (push) Failing after 8m3s
tests / browser (firefox, firefox) (push) Failing after 12m58s
tests / browser (safari, webkit) (push) Failing after 13m8s

Tailwind left the stack in 2.0.0, but the package still carried about 330
mentions of it. What the guard's Tailwind detection protected — a class
that compiles to nothing — is now protected by a check that does not care
where a dead class came from.

DesignGuard: about 500 lines of Tailwind tables, scales, palettes and
"2.0.0 replacement" hints give way to one check — a class a view or PHP
file writes that neither the application's stylesheets nor the package's
own declare. It catches a utility of any framework, a typo and a class
whose rules were deleted alike, so it also found two classes ReStride
draws nothing with. A stylesheet has to be in reach for it: the `.css`
files among the scanned paths, or what the `missingStylesheets()` entry
imports. The class reader no longer mistakes an array index for a class
list (`$block['base']`), and it reads the array a class helper is given,
where it read nothing before.

The package's own three Tailwind self-guards go with it. Only their one
unique check stays, as a test of its own: every `matchMedia` width in
resources/js is an M3 breakpoint.

The pagination views are `material.blade.php` and
`simple-material.blade.php`; only Laravel's and Livewire's default theme
names ever made them `tailwind`. The provider sets `Paginator`'s default
views and switches `livewire.pagination_theme` to `material` when it is
still Livewire's own default, so no application can forget the config; a
theme an application chose, and a component's own `$paginationTheme` or
`paginationView()`, still win.

The rest is prose: the layer-order guidance for an application that still
builds Tailwind, the Tailwind wording in the README, the Boost guidelines
and the development skill, and about 25 "this used to be a Tailwind
utility" comments, along with every "plan step NN" pointer into a
gitignored folder. The reset keeps its credit, and NOTICE now carries it
too.

Feature suite 1159 passed, Chrome browser suite 299 passed.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Andreas Reinhold / reini
2026-09-17 21:07:39 +02:00
co-authored by Claude Opus 5
parent 247c596c3a
commit fb7007c976
88 changed files with 649 additions and 1521 deletions
+7 -9
View File
@@ -687,11 +687,9 @@ it('toggles each choice of a multi selection group, down to none', function () {
});
/**
* Browser tests owed from docs/plans/material-3-browser-tests.md § Actions (Phase E), written on
* the data-md-* hooks of plan step 36's actions stream: submenu keyboard and hover-open, the
* filtering menu, the sheet-at-compact list, a long menu's scroll, and the FAB menu's own scroll
* behind its fixed close button. Written but not run — the actions group's Chromium run happens
* once every stream in the group has landed.
* The tests below: a submenu opened and closed by keyboard or hover, a menu's filter field, its
* sheet-at-compact form below 600px, a long menu's scroll and the FAB menu's own scroll behind
* its fixed close button. `LongMenuProbe` and `SheetMenuProbe` back the last three of those.
*/
/** A Livewire component whose menu has more items than the popover's 288px cap can show. */
@@ -872,10 +870,10 @@ it('filters a menu\'s items as its field is typed into, moves the highlight with
it('opens a sheet-at-compact menu below 600px, focused on its first item, and the popover from 600px', function () {
$trigger = '#menus button:has-text("Photo")';
// The sheet is <x-bottom-sheet>, rewritten (plan step 36) but still x-show-driven — its CSS
// now animates open/close through @starting-style and transition-behavior: allow-discrete
// rather than Alpine's x-transition classes, but x-show still owns the element's display, so
// its openness shows as visibility, not the Popover API's :popover-open.
// The sheet is <x-bottom-sheet>, still x-show-driven — its CSS now animates open/close
// through @starting-style and transition-behavior: allow-discrete rather than Alpine's
// x-transition classes, but x-show still owns the element's display, so its openness shows
// as visibility, not the Popover API's :popover-open.
$dialog = '[role="dialog"][aria-label="Photo actions"]';
$addToAlbum = '#menus [role="menuitem"]:has-text("Add to album")';
+3 -3
View File
@@ -187,9 +187,9 @@ it('scrolls instantly and leaves every item unmasked under reduced motion', func
});
it('brings an item cut off at the row\'s edge into view when it is pressed under reduced motion', function () {
// Owed by the Chromium baseline (step 32, docs/plans/material-3-browser-tests.md): reduced
// motion writes a zero inset for every item, so a mask cannot say an item is only partly
// shown; carousel.js reads the item's box against the row's instead, as for multi-aspect.
// Under reduced motion, the row writes a zero inset for every item, so a mask cannot say an
// item is only partly shown; carousel.js reads the item's box against the row's instead, as
// for multi-aspect.
$page = carouselShowcase(['reducedMotion' => 'reduce'])
->assertScript(onCarousel(0, <<<'JS'
const row = scroller.getBoundingClientRect()
+9 -9
View File
@@ -7,13 +7,13 @@ use Livewire\Component;
use Livewire\Livewire;
/**
* The central claims of the `@layer material` design (plan step 42, docs/plans/material-3-alignment.md
* Decisions § "Components carry their styles as `data-md-*` attributes inside `@layer material`"),
* each on its own small probe page: an application's unlayered rule beats a component default;
* `[hidden]` beats a component's `display`; the layer order holds even when a component file is
* imported before the foundation; a `data-md-*` attribute survives a Livewire `$refresh`; an icon
* mirrors in a right-to-left document. Every other stylesheet claim (layers, imports, breakpoints,
* no Tailwind) is StylesheetsTest.php's, asserted on the source rather than a rendered page.
* The central claims of the `@layer material` design — components carry their styles as
* `data-md-*` attributes inside `@layer material` — each on its own small probe page: an
* application's unlayered rule beats a component default; `[hidden]` beats a component's
* `display`; the layer order holds even when a component file is imported before the foundation;
* a `data-md-*` attribute survives a Livewire `$refresh`; an icon mirrors in a right-to-left
* document. Every other stylesheet claim (layers, imports, breakpoints) is StylesheetsTest.php's,
* asserted on the source rather than a rendered page.
*/
function cascadeReady(mixed $page): mixed
{
@@ -71,8 +71,8 @@ it('lets [hidden] beat a component\'s display', function () {
});
it('keeps the layer order even when a component file is imported before the foundation', function () {
// Every package stylesheet opens with the same full `@layer` statement (plan step 33), so the
// order it establishes holds whichever file a page reaches first — the error layout's copy of
// Every package stylesheet opens with the same full `@layer` statement, so the order it
// establishes holds whichever file a page reaches first — the error layout's copy of
// it, reached here before the foundation's. The two prebuilt error-page stylesheets, in that
// deliberate order: the layout's bundle, whose button.css rules sit in `material.components`,
// physically precedes the fallback's foundation reset, in `material.reset` — and still loses
+2 -3
View File
@@ -1077,9 +1077,8 @@ it('slides the side sheet in from its own edge in a right-to-left page', functio
// `side="end"` (the default) is the trailing edge — the *left* of a right-to-left page — so it
// slides in from off the left, not the right (the CSS mirror reads `[dir='rtl']` rather than
// `:dir(rtl)`, plan step 39 — Vite's own minifier rewrote that to a `:lang()` list, same as
// Tailwind's build did): caught well before the 500ms spatial transition ends, it is still
// off-screen on the left.
// `:dir(rtl)`, because Vite's own minifier rewrites that to a `:lang()` list): caught well
// before the 500ms spatial transition ends, it is still off-screen on the left.
$page->wait(0.05);
$page->assertScript("getComputedStyle({$sheet}).display !== 'none'")
+4 -4
View File
@@ -6,10 +6,10 @@ use Livewire\Component;
use Livewire\Livewire;
/**
* The layout components at M3's breakpoints (plan step 35): each on a page of its own, measured at
* the pixel either side of the breakpoint it changes at. The window is resized after the page has
* loaded, which is what a person does; a media query answers at once, and a script listening to
* one (resources/js/layout.js) hears a change event.
* The layout components at M3's breakpoints: each on a page of its own, measured at the pixel
* either side of the breakpoint it changes at. The window is resized after the page has loaded,
* which is what a person does; a media query answers at once, and a script listening to one
* (resources/js/layout.js) hears a change event.
*/
function layoutPage(string $body, int $width, int $height = 900, string $dir = 'ltr'): mixed
{
+1 -1
View File
@@ -350,7 +350,7 @@ it('lifts the snackbar and the page above something docked on the phone\'s bar',
* A page for the navigation bar and rail props the shell's own adaptive rail never exercises:
* `tall`, `hide-on-scroll` (with a pinned snackbar), a narrow centred rail, and a rail that hides
* when collapsed. A wide, fixed viewport throughout, so none of M3's breakpoints interfere with
* what each example's own props already decide (docs/plans/material-3-browser-tests.md § Navigation).
* what each example's own props already decide.
*/
function navigationExtrasProbe(): mixed
{