Skip to content

fix: stop shellui-theme.css requesting tailwindcss when linked directly - #44

Merged
Shewart merged 1 commit into
mainfrom
fix/theme-css-import
Oct 10, 2026
Merged

Shewart merged 1 commit into
mainfrom
fix/theme-css-import

Conversation

@Shewart

@Shewart Shewart commented Oct 10, 2026

Copy link
Copy Markdown
Contributor

src/ShellUI.Components/wwwroot/shellui-theme.css started with @import "tailwindcss";. A page that links the theme directly (<link href="_content/ShellUI.Components/shellui-theme.css">, as the docs site does) made the browser request tailwindcss as a URL and log a 404 on every load.

  • shellui-theme.css now holds only the theme
  • scripts/rebuild-precompiled-css.sh writes @import "tailwindcss"; at the top of its generated Tailwind input; it is the only thing that builds from the theme file

Checked:

  • shellui-all.css is byte-for-byte identical before and after
  • A fresh Blazor app linking shellui-theme.css from the package: the stylesheet loads, there is no tailwindcss request, the console is clean, and --background applies
  • All 303 tests pass

The theme started with @import "tailwindcss";, so a page that links it
asked the browser for a tailwindcss URL and logged a 404 on every load.
The CSS build script now writes the import into its generated input, so
the theme file holds only the theme and shellui-all.css is unchanged.
Copilot AI balanced review requested due to automatic review settings October 10, 2026 13:56

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@Shewart
Shewart merged commit 16d18c3 into main Oct 10, 2026
1 check passed
@Shewart
Shewart deleted the fix/theme-css-import branch October 10, 2026 14:04
Shewart added a commit that referenced this pull request Oct 13, 2026
Release notes and version references for 0.4.0-alpha.2.

**In this release** (already on main):
- #48: the Tailwind CLI is downloaded once per machine and run from
there, so projects hold no binary; downloads survive slow connections;
`init` carries on if the download fails; `.shellui/` is git-ignored;
`update` moves older projects onto the shared CLI
- #46: `update` installs new dependencies and keeps files you changed
(`--force` to overwrite); `remove` finds layouts and custom paths; the
package `TimePicker` value fix; `color-scheme` for light and dark
- #44: `shellui-theme.css` no longer 404s when linked directly
- #43: NuGet package icon and README logo

**This PR**
- `Directory.Build.props`: suffix `alpha.2`
- Docs name stable `0.3.4` and prerelease `0.4.0-alpha.2` (README,
VERSIONING_STRATEGY, CLI_INSTALLATION, CLI_SYNTAX, FAQ, QUICKSTART);
stable-docs links point to `v0.3.4`
- The version fallbacks in `VersionHelper` and `ComponentMetadata`
(still `0.3.0` on main) are now `0.4.0-alpha.2`
- `docs/RELEASE_NOTES.md`: the 0.4.0-alpha.2 section, plus the 0.3.4 and
0.3.3 sections from `release/v0.3`; `scripts/extract-release-notes.sh
0.4.0-alpha.2` extracts it

**Release checks** (on `9c7cfac` plus this commit)
- Release build has 0 warnings, and all 334 tests pass
- A 0.3.4 project updated with the packed alpha.2 CLI: targets
refreshed, the 112 MB project copy of Tailwind removed, 54 components
updated, the edited `AppSidebar` kept, 5 new dependencies installed,
builds 0/0
- A fresh Identity app, `init --yes --dashboard 02` then `add auth-01
data-table chat qr-code time-picker`: uses the shared Tailwind CLI and
builds 0/0; `.shellui` holds only its `.gitignore`
- All 93 direct targets together in `my-app` build 0/0 on net8.0, net9.0
and net10.0, with no project copies of the CLI
- The packed `ShellUI.Components` in a browser: `window.ShellUI` loads,
TimePicker shows its value, dark mode sets `color-scheme` (including the
native date input), Popover closes on Escape, Command runs `Action` then
`CommandSelected`, no console errors
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants