| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| Parent folder | |||
| admin-lte-v4.2.0.zip | 2026-08-06 | 4.5 MB | |
| AdminLTE 4.2.0 source code.tar.gz | 2026-08-06 | 13.2 MB | |
| AdminLTE 4.2.0 source code.zip | 2026-08-06 | 13.4 MB | |
| README.md | 2026-08-06 | 3.9 kB | |
| Totals: 4 Items | 31.2 MB | 0 | |
AdminLTE 4.2.0 is a focused release that mostly answers one question the community kept asking: how do I stop AdminLTE from managing my theme? It also ships the lifecycle API that client-side rendered layouts have been waiting for, plus three new demo pages.
Highlights
Color mode gets out of your way
Applications with their own theming — a custom Bootstrap theme, a per-user preference rendered by Laravel or Django, or simply your own switcher — can now turn the bundled module off with a single attribute. No JavaScript, no load-order concerns, works straight from dist:
:::html
<html data-lte-color-mode="off">
ColorMode then never writes data-bs-theme: not on load, not when a [data-bs-theme-value] toggle is clicked, not when the OS preference changes. The pre-paint snippet in <head> honours it too, so nothing touches your theme before first paint either.
And if all you need is a server-rendered default, you no longer have to opt out at all. The theme is now resolved from the visitor's stored choice → the theme your page declared → the OS preference, so this survives both page load and later OS preference changes:
:::html
<html lang="en" data-bs-theme="dark">
It stays a default: the moment a visitor picks a theme themselves, their choice wins on that device.
Thanks to @cytech for the report (#6084), and to @dfsmania (#6093) for putting markup-as-a-preference on the table in the first place.
initialize() / teardown() for client-side rendered layouts
Frameworks that build the layout after DOMContentLoaded into a persistent <body> — GWT and similar widget toolkits — used to find no sidebar and no menu when AdminLTE ran its init pass. Two new exports fix that:
:::js
import { initialize, teardown } from "admin-lte"
initialize() // re-run every plugin's init against the DOM as it stands right now
teardown() // drop this cycle's listeners when you unmount the layout
initialize() is safe to call repeatedly — it tears the previous cycle down first, so listeners never stack. Thanks @themarioga (#6083).
New demo pages
forms/advanced.html— the recommended Tom Select and Flatpickr integrationsforms/editors.html— Quill 2 in both the snow (toolbar) and bubble (inline) themeslayout/top-nav.html— a sidebar-less layout with primary navigation in the app-header
Fixes
- A sidebar rendered as
<body class="sidebar-collapse">no longer springs open on wide screens — the responsive pass was overwriting the state declared in the markup (#6076, thanks @dfsmania) - The Color Mode docs page no longer runs two switchers at once: it still carried the pre-4.1 inline toggler, which bound its own handlers to the same buttons as the bundled module and persisted to a different
localStoragekey
Maintenance
Every dev dependency refreshed to its latest release, including the eslint-plugin-astro 3 and eslint-plugin-unicorn 73 majors. TypeScript stays on 6.0.3 for now — 7.0 has shipped, but typescript-eslint and @astrojs/check both still cap the peer range, so installing it breaks npm ci outright. The unit suite grew to 51 tests, 13 of them covering the new color-mode precedence chain and the opt-out.
Install
:::bash
npm install admin-lte@4.2.0
:::html
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/admin-lte@4.2.0/dist/css/adminlte.min.css" />
<script src="https://cdn.jsdelivr.net/npm/admin-lte@4.2.0/dist/js/adminlte.min.js"></script>
:::js
// Or as a module
import { PushMenu, ColorMode } from "admin-lte"
Full details in the [CHANGELOG](https://github.com/ColorlibHQ/AdminLTE/blob/master/CHANGELOG.md#420.