Skip to content

Commit 5956d41

Browse files
puikinshclaude
andcommitted
Release 0.5.0: AdminLTE core 4.8.1
Bumps the core dependency 4.3.1 → 4.8.1. What the bundled stylesheet picks up: the flex-column sidebar (core #6104), data-lte-print="plain", d-print-none on .app-wrapper / .app-sidebar, and the skip-link hover contrast fix. The extended palettes (data-lte-primary, data-lte-contrast) stay opt-in — they ship as separate core sheets that @adminlte/react/css does not bundle — and are now documented in the README and on /docs/theming. Demo RTL stylesheet refreshed to 4.8.1. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
1 parent 159c76b commit 5956d41

6 files changed

Lines changed: 238 additions & 32 deletions

File tree

‎CHANGELOG.md‎

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,32 @@ All notable changes to **@adminlte/react** are documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [0.5.0] - 2026-08-19
9+
10+
### Changed
11+
12+
- **AdminLTE core upgraded to 4.8.1** (from 4.3.1), covering core [4.4.0](https://github.com/ColorlibHQ/AdminLTE/blob/master/CHANGELOG.md#440---2026-08-18), [4.4.1](https://github.com/ColorlibHQ/AdminLTE/blob/master/CHANGELOG.md#441---2026-08-18), [4.5.0](https://github.com/ColorlibHQ/AdminLTE/blob/master/CHANGELOG.md#450---2026-08-18), [4.6.0](https://github.com/ColorlibHQ/AdminLTE/blob/master/CHANGELOG.md#460---2026-08-18), [4.7.0](https://github.com/ColorlibHQ/AdminLTE/blob/master/CHANGELOG.md#470---2026-08-18), [4.8.0](https://github.com/ColorlibHQ/AdminLTE/blob/master/CHANGELOG.md#480---2026-08-19) and [4.8.1](https://github.com/ColorlibHQ/AdminLTE/blob/master/CHANGELOG.md#481---2026-08-19). What the bundled stylesheet (`@adminlte/react/css`) actually picks up:
13+
- **The sidebar is now a flex column** (core 4.4.0, #6104). `.app-sidebar` gets `display: flex; flex-direction: column`, `.sidebar-brand` / `.sidebar-search` become `flex: 0 0 auto` and `.sidebar-wrapper` `flex: 1 1 auto; min-height: 0` — replacing the hard-coded `height: calc(100vh - (3.5rem + 1px))` that was repeated across every `sidebar-expand-*` breakpoint. The wrapper now fills whatever the sidebar leaves it instead of assuming a 3.5rem header, so a taller brand or an extra block above the menu no longer pushes the last items out of view. Verified in-browser on `/layout/fixed-sidebar`: wrapper 664 px inside a 720 px viewport, still scrolling under OverlayScrollbars.
14+
- **`data-lte-print="plain"`** (core 4.7.0) — set it on `<html>` (or any container) for pages that should print as documents: no `(https://…)` suffix after external links, no outline around buttons. It works with nothing but the bundled CSS. Print also stopped drawing a black box around `.skip-link` and every `.nav-link` — the `border: 1px solid #000` rule is scoped to `.btn` again, which matters here because the sidebar prints by design.
15+
- **`d-print-none` works on the shell** (core 4.6.0) — the print rules that force `display` on `.app-wrapper` and `.app-sidebar` are now `:not(.d-print-none)`, so Bootstrap's utility can hide the chrome from printed pages.
16+
- **Skip-link hover contrast fix** (core 4.6.0) — `--bs-white` / `--bs-primary-emphasis` (a token Bootstrap never defines, so the background computed to transparent) swapped for `--bs-body-bg` / `--bs-primary-text-emphasis`, so the hovered skip link stays legible in both colour modes.
17+
- The demo's `public/css/adminlte.rtl.css` was refreshed from core 4.8.1 to match.
18+
- **Palette attributes are available, opt-in.** Core's extended palettes ship as separate stylesheets that `@adminlte/react/css` deliberately does **not** bundle: `adminlte-colors.css` (4.4.0 — 14 generated colours as `--bs-*` tokens plus the `.bg-*` / `.text-bg-*` / `.text-*` / `.border-*` / `.link-*` / `.bg-gradient-*` / `.card-*` / `.callout-*` / `.direct-chat-*` families, ≈8 kB gzipped) and `adminlte-colors-v3.css` (4.5.0 — the same families for the 18 AdminLTE 3 colours at their original values, ≈9.5 kB gzipped). Install `admin-lte` and import the sheet you want next to the library CSS to get:
19+
- **`data-lte-primary="teal"`** (4.6.0, with 4.8.1's pagination focus-ring fix) — promotes any palette colour to Bootstrap's `primary`, so buttons, links, pagination, form focus rings, progress bars, list groups and dropdowns follow it. Verified: `.btn-primary` goes `rgb(13, 110, 253)` → `rgb(18, 130, 125)` once the sheet is loaded, and does nothing without it.
20+
- **`data-lte-contrast="aa"`** (4.8.0, v3 sheet only) — flips text to black on the eight v3 colours that miss WCAG AA (blue, cyan, fuchsia, green, lightblue, olive, pink, teal). Verified: `.text-bg-lightblue` goes white → black.
21+
22+
### Added
23+
24+
- Docs for both of the above: a **Core `<html>` attributes** table in the README's Styling section, and **The extended palette** / **Print** sections on the in-app `/docs/theming` page. They document core CSS you opt into yourself — no new component props or APIs.
25+
26+
### Notes
27+
28+
- **Core's restyled search fields don't reach this port.** 4.4.0 restyles `.navbar-search` and `.sidebar-search` into quiet pills (a new `--lte-search-field-*` variable set). `@adminlte/react` renders neither: the topbar search is a command-palette trigger button and the sidebar has no filter, so the new rules are inert here — nothing regressed, nothing gained.
29+
- **Core 4.4.1's ApexCharts dark-mode fix is a recipe, not shipped CSS** — it was applied to core's own demo pages. The `ApexChart` wrapper still passes `config` through verbatim and sets no Apex `theme`, so callers wanting dark tooltips pass `theme: { mode }` themselves.
30+
- Core's JavaScript is still irrelevant to this port — `@adminlte/react` never loads `adminlte.js` (see the 0.3.0 notes).
31+
- No dependency other than `admin-lte` changed; peer dependency ranges are untouched.
32+
- Verified: library build, type-check, lint (0 errors, 13 pre-existing warnings) and 19 unit tests; demo type-check and production build; all 67 Playwright route-smoke + a11y tests.
33+
834
## [0.4.0] - 2026-08-13
935

1036
### Changed
@@ -186,6 +212,7 @@ Next.js App Router and React Server Components.
186212
- Heavy third-party libraries are never bundled eagerly — they load via dynamic
187213
`import()` inside the components that use them.
188214

215+
[0.5.0]: https://github.com/ColorlibHQ/adminlte-react/compare/v0.4.0...v0.5.0
189216
[0.4.0]: https://github.com/ColorlibHQ/adminlte-react/compare/v0.3.0...v0.4.0
190217
[0.3.0]: https://github.com/ColorlibHQ/adminlte-react/compare/v0.2.0...v0.3.0
191218
[0.2.0]: https://github.com/ColorlibHQ/adminlte-react/compare/v0.1.0...v0.2.0

‎README.md‎

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
A modern React/Next.js component library for building admin dashboards and web applications with AdminLTE 4 styling and Bootstrap 5.3 — built for the Next.js App Router and React Server Components by [Colorlib](https://colorlib.com).
1111

12-
**Status**: v0.4.0 (Early Release, AdminLTE core 4.3.1) · **Live demo:** [adminlte.io/themes/next-react](https://adminlte.io/themes/next-react/)
12+
**Status**: v0.5.0 (Early Release, AdminLTE core 4.8.1) · **Live demo:** [adminlte.io/themes/next-react](https://adminlte.io/themes/next-react/)
1313

1414
<p align="center">
1515
<a href="https://adminlte.io/themes/next-react/">
@@ -318,6 +318,33 @@ All components use Bootstrap 5.3 utility classes. Customize via CSS variables or
318318
}
319319
```
320320

321+
### Core `<html>` attributes
322+
323+
AdminLTE core 4.6–4.8 added three opt-in attributes you set on `<html>` yourself — there is no
324+
component prop for them, and they work with this port because they are plain CSS:
325+
326+
| Attribute | What it does | Stylesheet |
327+
| --- | --- | --- |
328+
| `data-lte-print="plain"` | Prints the page as a document: no `(https://…)` suffix after external links, no outline around buttons. | bundled — `@adminlte/react/css` |
329+
| `data-lte-primary="teal"` | Promotes any palette colour to Bootstrap's `primary`, so buttons, links, pagination, form focus rings, progress bars, list groups and dropdowns follow it. | opt-in — `admin-lte/dist/css/adminlte-colors.css` (or `…-v3.css`) |
330+
| `data-lte-contrast="aa"` | Flips text to black on the eight AdminLTE 3 colours (blue, cyan, fuchsia, green, lightblue, olive, pink, teal) that otherwise miss WCAG AA. | opt-in — `admin-lte/dist/css/adminlte-colors-v3.css` |
331+
332+
```tsx
333+
// app/layout.tsx — data-lte-print needs no extra CSS
334+
<html lang="en" data-lte-print="plain">
335+
```
336+
337+
The extended palettes are **not** bundled with `@adminlte/react/css`; add `admin-lte` as a
338+
dependency and import the sheet you want next to the library CSS:
339+
340+
```tsx
341+
import '@adminlte/react/css'
342+
import 'admin-lte/dist/css/adminlte-colors.css' // 14 extra colours + data-lte-primary
343+
```
344+
345+
Bootstrap's `d-print-none` also works on `.app-wrapper` and `.app-sidebar` now, so you can hide
346+
the shell chrome from printed pages.
347+
321348
## Type Safety
322349

323350
Full TypeScript support with exported types:

‎demo/app/(dashboard)/docs/theming/page.tsx‎

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,44 @@ function ThemeButtons() {
101101
}`}
102102
/>
103103

104+
<h2>The extended palette</h2>
105+
<p>
106+
AdminLTE core ships two <em>opt-in</em> palette stylesheets that this library does not
107+
bundle: <code>adminlte-colors.css</code> (14 extra colours, each with the{' '}
108+
<code>.bg-*</code> / <code>.text-bg-*</code> / <code>.text-*</code> /{' '}
109+
<code>.border-*</code> / <code>.link-*</code> / <code>.card-*</code> /{' '}
110+
<code>.callout-*</code> / <code>.direct-chat-*</code> families) and{' '}
111+
<code>adminlte-colors-v3.css</code> (the same families for the 18 AdminLTE 3 colours
112+
at their original values). Add <code>admin-lte</code> as a dependency
113+
and import the one you want alongside the library CSS.
114+
</p>
115+
<CodeBlock
116+
filename="app/layout.tsx"
117+
code={`import '@adminlte/react/css'
118+
import 'admin-lte/dist/css/adminlte-colors.css'`}
119+
/>
120+
<p>
121+
With a palette sheet loaded, <code>data-lte-primary</code> on <code>&lt;html&gt;</code>{' '}
122+
promotes any of its colours to Bootstrap&apos;s <code>primary</code> — buttons, links,
123+
pagination, form focus rings, progress bars, list groups and dropdowns all follow it.
124+
On the v3 sheet, <code>data-lte-contrast=&quot;aa&quot;</code> flips text to black on
125+
the eight colours (blue, cyan, fuchsia, green, lightblue, olive, pink, teal) that
126+
otherwise miss WCAG AA.
127+
</p>
128+
<CodeBlock language="html" code={`<html lang="en" data-lte-primary="teal" data-lte-contrast="aa">`} />
129+
130+
<h2>Print</h2>
131+
<p>
132+
Print styling is part of the bundled <code>@adminlte/react/css</code> — nothing extra to
133+
load. By default a printed page is treated as a screen artifact: external links get their
134+
URL appended and buttons keep an outline. Set{' '}
135+
<code>data-lte-print=&quot;plain&quot;</code> on <code>&lt;html&gt;</code> for pages that
136+
should print as documents (invoices, reports) to drop both. Bootstrap&apos;s{' '}
137+
<code>d-print-none</code> also works on the app wrapper and the sidebar, so you can hide
138+
the shell chrome from print.
139+
</p>
140+
<CodeBlock language="html" code={`<html lang="en" data-lte-print="plain">`} />
141+
104142
<h2>Sidebar theme</h2>
105143
<p>
106144
The sidebar has its own light/dark treatment, independent of the page color mode.

0 commit comments

Comments
 (0)