Keep the application's stylesheets off the scaffold page too

Plan step 38 review: /material/shell still passed the whole configured
Vite list, so it loaded Tailwind and all.css a second time beside the
showcase bundle. Both frames now take ShowcaseAssetController::scripts():
every entry but a stylesheet, by the same extensions Laravel's Vite
treats as CSS (not only .css), and skip @vite() when nothing is left,
since a list of stylesheets alone would read a build manifest for
nothing. A test renders the overview, a section, a layout page and the
shell against a hot file. The frame's header said the rail collapses
from `lg`; it is `expanded` (840px). The config comment is shorter and
true.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qwx5USif3wFFmxtHg5U1g9
This commit is contained in:
Andreas Reinhold / reini
2026-09-15 06:07:44 +02:00
co-authored by Claude Opus 5
parent 7abcc7c5f5
commit 2f649983fa
5 changed files with 71 additions and 25 deletions
+7 -10
View File
@@ -192,16 +192,13 @@ return [
|
| Every component in every variant, rendered in the application's own
| scheme. Off unless the application runs locally. 'vite' names the
| application's own entry points: its JavaScript (Livewire, Alpine) and,
| for an application that still builds one of its own, a CSS entry. The
| showcase page draws its CSS only from its own bundle
| (ShowcaseAssetController serves Stylesheets::bundle() of all.css,
| showcase.css and the scheme) — nothing on it needs the application's
| build, Tailwind included — so the showcase's layout keeps only the
| entries here that are not a stylesheet before passing the rest to
| @vite(), and links its own bundle after them. The error pages have no
| bundle of their own to fall back on, so ErrorPage::assets() still
| passes this whole list, CSS included, to @vite().
| application's own entry points: its JavaScript (Livewire, Alpine) and
| the CSS entry that imports this package's stylesheets. The showcase's
| pages pass @vite() only the entries that are not a stylesheet: their
| CSS is a bundle of their own (all.css, showcase.css and the scheme,
| served by ShowcaseAssetController), so they need nothing from the
| application's build. The error pages have no such bundle, so
| ErrorPage::assets() passes this whole list, CSS included, to @vite().
|
*/