admin-lte 4.0.0 → 4.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/README.md +185 -111
  3. package/dist/UI/general.html +27 -3
  4. package/dist/UI/icons.html +27 -3
  5. package/dist/UI/timeline.html +27 -3
  6. package/dist/docs/browser-support.html +27 -3
  7. package/dist/docs/color-mode.html +27 -3
  8. package/dist/docs/components/main-header.html +27 -3
  9. package/dist/docs/components/main-sidebar.html +27 -3
  10. package/dist/docs/customization.html +27 -3
  11. package/dist/docs/deployment.html +27 -3
  12. package/dist/docs/faq.html +27 -3
  13. package/dist/docs/getting-started.html +27 -3
  14. package/dist/docs/how-to-contribute.html +27 -3
  15. package/dist/docs/integrations.html +27 -3
  16. package/dist/docs/introduction.html +27 -3
  17. package/dist/docs/javascript/accessibility.html +27 -3
  18. package/dist/docs/javascript/card-widget.html +27 -3
  19. package/dist/docs/javascript/direct-chat.html +27 -3
  20. package/dist/docs/javascript/fullscreen.html +27 -3
  21. package/dist/docs/javascript/layout.html +27 -3
  22. package/dist/docs/javascript/plugins-overview.html +27 -3
  23. package/dist/docs/javascript/pushmenu.html +27 -3
  24. package/dist/docs/javascript/treeview.html +27 -3
  25. package/dist/docs/layout-blueprint.html +27 -3
  26. package/dist/docs/layout.html +27 -3
  27. package/dist/docs/license.html +27 -3
  28. package/dist/docs/migration.html +27 -3
  29. package/dist/docs/recipes.html +27 -3
  30. package/dist/docs/rtl.html +27 -3
  31. package/dist/examples/lockscreen.html +26 -0
  32. package/dist/examples/login-v2.html +26 -0
  33. package/dist/examples/login.html +26 -0
  34. package/dist/examples/register-v2.html +26 -0
  35. package/dist/examples/register.html +26 -0
  36. package/dist/forms/elements.html +27 -3
  37. package/dist/forms/layout.html +27 -3
  38. package/dist/forms/validation.html +27 -3
  39. package/dist/forms/wizard.html +27 -3
  40. package/dist/generate/theme.html +26 -0
  41. package/dist/index.html +27 -3
  42. package/dist/index2.html +27 -3
  43. package/dist/index3.html +27 -3
  44. package/dist/js/adminlte.js +4 -1
  45. package/dist/js/adminlte.js.map +1 -1
  46. package/dist/js/adminlte.min.js +2 -2
  47. package/dist/js/adminlte.min.js.map +1 -1
  48. package/dist/layout/collapsed-sidebar-without-hover.html +27 -3
  49. package/dist/layout/collapsed-sidebar.html +27 -3
  50. package/dist/layout/fixed-complete.html +27 -3
  51. package/dist/layout/fixed-footer.html +27 -3
  52. package/dist/layout/fixed-header.html +27 -3
  53. package/dist/layout/fixed-sidebar.html +27 -3
  54. package/dist/layout/layout-custom-area.html +27 -3
  55. package/dist/layout/layout-rtl.html +27 -3
  56. package/dist/layout/logo-switch.html +26 -0
  57. package/dist/layout/sidebar-mini.html +27 -3
  58. package/dist/layout/unfixed-sidebar.html +27 -3
  59. package/dist/mailbox/compose.html +27 -3
  60. package/dist/mailbox/inbox.html +43 -11
  61. package/dist/mailbox/read.html +27 -3
  62. package/dist/pages/404.html +26 -0
  63. package/dist/pages/500.html +26 -0
  64. package/dist/pages/calendar.html +27 -3
  65. package/dist/pages/chat.html +27 -3
  66. package/dist/pages/faq.html +27 -3
  67. package/dist/pages/file-manager.html +27 -3
  68. package/dist/pages/invoice.html +27 -3
  69. package/dist/pages/kanban.html +27 -3
  70. package/dist/pages/maintenance.html +26 -0
  71. package/dist/pages/pricing.html +27 -3
  72. package/dist/pages/profile.html +27 -3
  73. package/dist/pages/projects.html +27 -3
  74. package/dist/pages/settings.html +27 -3
  75. package/dist/tables/data.html +27 -3
  76. package/dist/tables/simple.html +27 -3
  77. package/dist/widgets/cards.html +27 -3
  78. package/dist/widgets/info-box.html +27 -3
  79. package/dist/widgets/small-box.html +27 -3
  80. package/github-issue-response.md +40 -0
  81. package/package.json +14 -13
  82. package/src/ts/accessibility.ts +9 -1
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>Fullscreen Plugin | AdminLTE 4</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />
@@ -365,13 +391,11 @@
365
391
  <!--end::Sidebar Brand-->
366
392
  <!--begin::Sidebar Wrapper-->
367
393
  <div class="sidebar-wrapper">
368
- <nav class="mt-2">
394
+ <nav class="mt-2" aria-label="Documentation navigation">
369
395
  <!--begin::Sidebar Menu-->
370
396
  <ul
371
397
  class="nav sidebar-menu flex-column"
372
398
  data-lte-toggle="treeview"
373
- role="navigation"
374
- aria-label="Documentation navigation"
375
399
  data-accordion="false"
376
400
  id="docs-navigation"
377
401
  >
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>Layout Plugin | AdminLTE 4</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />
@@ -365,13 +391,11 @@
365
391
  <!--end::Sidebar Brand-->
366
392
  <!--begin::Sidebar Wrapper-->
367
393
  <div class="sidebar-wrapper">
368
- <nav class="mt-2">
394
+ <nav class="mt-2" aria-label="Documentation navigation">
369
395
  <!--begin::Sidebar Menu-->
370
396
  <ul
371
397
  class="nav sidebar-menu flex-column"
372
398
  data-lte-toggle="treeview"
373
- role="navigation"
374
- aria-label="Documentation navigation"
375
399
  data-accordion="false"
376
400
  id="docs-navigation"
377
401
  >
@@ -4,6 +4,32 @@
4
4
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
5
  <title>JavaScript Plugins Overview | AdminLTE 4</title>
6
6
 
7
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
8
+ <script>
9
+ (() => {
10
+ 'use strict';
11
+ const STORAGE_KEY = 'lte-theme';
12
+ let stored = null;
13
+ try {
14
+ stored = localStorage.getItem(STORAGE_KEY);
15
+ } catch {
16
+ // localStorage may be unavailable (private mode, sandboxed iframe).
17
+ }
18
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
19
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
20
+ // otherwise ("auto" or unset) fall back to the OS preference.
21
+ let resolved = 'light';
22
+ if (stored === 'dark' || stored === 'light') {
23
+ resolved = stored;
24
+ } else if (prefersDark) {
25
+ resolved = 'dark';
26
+ }
27
+ document.documentElement.setAttribute('data-bs-theme', resolved);
28
+ document.documentElement.style.colorScheme = resolved;
29
+ })();
30
+ </script>
31
+ <!--end::Theme Init-->
32
+
7
33
  <!--begin::Accessibility Meta Tags-->
8
34
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
9
35
  <meta name="color-scheme" content="light dark" />
@@ -361,13 +387,11 @@
361
387
  <!--end::Sidebar Brand-->
362
388
  <!--begin::Sidebar Wrapper-->
363
389
  <div class="sidebar-wrapper">
364
- <nav class="mt-2">
390
+ <nav class="mt-2" aria-label="Documentation navigation">
365
391
  <!--begin::Sidebar Menu-->
366
392
  <ul
367
393
  class="nav sidebar-menu flex-column"
368
394
  data-lte-toggle="treeview"
369
- role="navigation"
370
- aria-label="Documentation navigation"
371
395
  data-accordion="false"
372
396
  id="docs-navigation"
373
397
  >
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>Pushmenu Plugin | AdminLTE 4</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />
@@ -365,13 +391,11 @@
365
391
  <!--end::Sidebar Brand-->
366
392
  <!--begin::Sidebar Wrapper-->
367
393
  <div class="sidebar-wrapper">
368
- <nav class="mt-2">
394
+ <nav class="mt-2" aria-label="Documentation navigation">
369
395
  <!--begin::Sidebar Menu-->
370
396
  <ul
371
397
  class="nav sidebar-menu flex-column"
372
398
  data-lte-toggle="treeview"
373
- role="navigation"
374
- aria-label="Documentation navigation"
375
399
  data-accordion="false"
376
400
  id="docs-navigation"
377
401
  >
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>Treeview Plugin | AdminLTE 4</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />
@@ -365,13 +391,11 @@
365
391
  <!--end::Sidebar Brand-->
366
392
  <!--begin::Sidebar Wrapper-->
367
393
  <div class="sidebar-wrapper">
368
- <nav class="mt-2">
394
+ <nav class="mt-2" aria-label="Documentation navigation">
369
395
  <!--begin::Sidebar Menu-->
370
396
  <ul
371
397
  class="nav sidebar-menu flex-column"
372
398
  data-lte-toggle="treeview"
373
- role="navigation"
374
- aria-label="Documentation navigation"
375
399
  data-accordion="false"
376
400
  id="docs-navigation"
377
401
  >
@@ -4,6 +4,32 @@
4
4
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
5
  <title>Layout Blueprint | AdminLTE 4</title>
6
6
 
7
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
8
+ <script>
9
+ (() => {
10
+ 'use strict';
11
+ const STORAGE_KEY = 'lte-theme';
12
+ let stored = null;
13
+ try {
14
+ stored = localStorage.getItem(STORAGE_KEY);
15
+ } catch {
16
+ // localStorage may be unavailable (private mode, sandboxed iframe).
17
+ }
18
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
19
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
20
+ // otherwise ("auto" or unset) fall back to the OS preference.
21
+ let resolved = 'light';
22
+ if (stored === 'dark' || stored === 'light') {
23
+ resolved = stored;
24
+ } else if (prefersDark) {
25
+ resolved = 'dark';
26
+ }
27
+ document.documentElement.setAttribute('data-bs-theme', resolved);
28
+ document.documentElement.style.colorScheme = resolved;
29
+ })();
30
+ </script>
31
+ <!--end::Theme Init-->
32
+
7
33
  <!--begin::Accessibility Meta Tags-->
8
34
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
9
35
  <meta name="color-scheme" content="light dark" />
@@ -361,13 +387,11 @@
361
387
  <!--end::Sidebar Brand-->
362
388
  <!--begin::Sidebar Wrapper-->
363
389
  <div class="sidebar-wrapper">
364
- <nav class="mt-2">
390
+ <nav class="mt-2" aria-label="Documentation navigation">
365
391
  <!--begin::Sidebar Menu-->
366
392
  <ul
367
393
  class="nav sidebar-menu flex-column"
368
394
  data-lte-toggle="treeview"
369
- role="navigation"
370
- aria-label="Documentation navigation"
371
395
  data-accordion="false"
372
396
  id="docs-navigation"
373
397
  >
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>Layout | AdminLTE 4</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />
@@ -365,13 +391,11 @@
365
391
  <!--end::Sidebar Brand-->
366
392
  <!--begin::Sidebar Wrapper-->
367
393
  <div class="sidebar-wrapper">
368
- <nav class="mt-2">
394
+ <nav class="mt-2" aria-label="Documentation navigation">
369
395
  <!--begin::Sidebar Menu-->
370
396
  <ul
371
397
  class="nav sidebar-menu flex-column"
372
398
  data-lte-toggle="treeview"
373
- role="navigation"
374
- aria-label="Documentation navigation"
375
399
  data-accordion="false"
376
400
  id="docs-navigation"
377
401
  >
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>License | AdminLTE 4</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />
@@ -365,13 +391,11 @@
365
391
  <!--end::Sidebar Brand-->
366
392
  <!--begin::Sidebar Wrapper-->
367
393
  <div class="sidebar-wrapper">
368
- <nav class="mt-2">
394
+ <nav class="mt-2" aria-label="Documentation navigation">
369
395
  <!--begin::Sidebar Menu-->
370
396
  <ul
371
397
  class="nav sidebar-menu flex-column"
372
398
  data-lte-toggle="treeview"
373
- role="navigation"
374
- aria-label="Documentation navigation"
375
399
  data-accordion="false"
376
400
  id="docs-navigation"
377
401
  >
@@ -4,6 +4,32 @@
4
4
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
5
  <title>Migration from v3 | AdminLTE 4</title>
6
6
 
7
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
8
+ <script>
9
+ (() => {
10
+ 'use strict';
11
+ const STORAGE_KEY = 'lte-theme';
12
+ let stored = null;
13
+ try {
14
+ stored = localStorage.getItem(STORAGE_KEY);
15
+ } catch {
16
+ // localStorage may be unavailable (private mode, sandboxed iframe).
17
+ }
18
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
19
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
20
+ // otherwise ("auto" or unset) fall back to the OS preference.
21
+ let resolved = 'light';
22
+ if (stored === 'dark' || stored === 'light') {
23
+ resolved = stored;
24
+ } else if (prefersDark) {
25
+ resolved = 'dark';
26
+ }
27
+ document.documentElement.setAttribute('data-bs-theme', resolved);
28
+ document.documentElement.style.colorScheme = resolved;
29
+ })();
30
+ </script>
31
+ <!--end::Theme Init-->
32
+
7
33
  <!--begin::Accessibility Meta Tags-->
8
34
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
9
35
  <meta name="color-scheme" content="light dark" />
@@ -361,13 +387,11 @@
361
387
  <!--end::Sidebar Brand-->
362
388
  <!--begin::Sidebar Wrapper-->
363
389
  <div class="sidebar-wrapper">
364
- <nav class="mt-2">
390
+ <nav class="mt-2" aria-label="Documentation navigation">
365
391
  <!--begin::Sidebar Menu-->
366
392
  <ul
367
393
  class="nav sidebar-menu flex-column"
368
394
  data-lte-toggle="treeview"
369
- role="navigation"
370
- aria-label="Documentation navigation"
371
395
  data-accordion="false"
372
396
  id="docs-navigation"
373
397
  >
@@ -4,6 +4,32 @@
4
4
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
5
  <title>Common Patterns &amp; Recipes | AdminLTE 4</title>
6
6
 
7
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
8
+ <script>
9
+ (() => {
10
+ 'use strict';
11
+ const STORAGE_KEY = 'lte-theme';
12
+ let stored = null;
13
+ try {
14
+ stored = localStorage.getItem(STORAGE_KEY);
15
+ } catch {
16
+ // localStorage may be unavailable (private mode, sandboxed iframe).
17
+ }
18
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
19
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
20
+ // otherwise ("auto" or unset) fall back to the OS preference.
21
+ let resolved = 'light';
22
+ if (stored === 'dark' || stored === 'light') {
23
+ resolved = stored;
24
+ } else if (prefersDark) {
25
+ resolved = 'dark';
26
+ }
27
+ document.documentElement.setAttribute('data-bs-theme', resolved);
28
+ document.documentElement.style.colorScheme = resolved;
29
+ })();
30
+ </script>
31
+ <!--end::Theme Init-->
32
+
7
33
  <!--begin::Accessibility Meta Tags-->
8
34
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
9
35
  <meta name="color-scheme" content="light dark" />
@@ -361,13 +387,11 @@
361
387
  <!--end::Sidebar Brand-->
362
388
  <!--begin::Sidebar Wrapper-->
363
389
  <div class="sidebar-wrapper">
364
- <nav class="mt-2">
390
+ <nav class="mt-2" aria-label="Documentation navigation">
365
391
  <!--begin::Sidebar Menu-->
366
392
  <ul
367
393
  class="nav sidebar-menu flex-column"
368
394
  data-lte-toggle="treeview"
369
- role="navigation"
370
- aria-label="Documentation navigation"
371
395
  data-accordion="false"
372
396
  id="docs-navigation"
373
397
  >
@@ -4,6 +4,32 @@
4
4
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
5
  <title>RTL Support | AdminLTE 4</title>
6
6
 
7
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
8
+ <script>
9
+ (() => {
10
+ 'use strict';
11
+ const STORAGE_KEY = 'lte-theme';
12
+ let stored = null;
13
+ try {
14
+ stored = localStorage.getItem(STORAGE_KEY);
15
+ } catch {
16
+ // localStorage may be unavailable (private mode, sandboxed iframe).
17
+ }
18
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
19
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
20
+ // otherwise ("auto" or unset) fall back to the OS preference.
21
+ let resolved = 'light';
22
+ if (stored === 'dark' || stored === 'light') {
23
+ resolved = stored;
24
+ } else if (prefersDark) {
25
+ resolved = 'dark';
26
+ }
27
+ document.documentElement.setAttribute('data-bs-theme', resolved);
28
+ document.documentElement.style.colorScheme = resolved;
29
+ })();
30
+ </script>
31
+ <!--end::Theme Init-->
32
+
7
33
  <!--begin::Accessibility Meta Tags-->
8
34
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
9
35
  <meta name="color-scheme" content="light dark" />
@@ -361,13 +387,11 @@
361
387
  <!--end::Sidebar Brand-->
362
388
  <!--begin::Sidebar Wrapper-->
363
389
  <div class="sidebar-wrapper">
364
- <nav class="mt-2">
390
+ <nav class="mt-2" aria-label="Documentation navigation">
365
391
  <!--begin::Sidebar Menu-->
366
392
  <ul
367
393
  class="nav sidebar-menu flex-column"
368
394
  data-lte-toggle="treeview"
369
- role="navigation"
370
- aria-label="Documentation navigation"
371
395
  data-accordion="false"
372
396
  id="docs-navigation"
373
397
  >
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>AdminLTE 4 | Lockscreen</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>AdminLTE 4 | Login Page v2</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>AdminLTE 4 | Login Page</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />
@@ -5,6 +5,32 @@
5
5
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
6
  <title>AdminLTE 4 | Register Page v2</title>
7
7
 
8
+ <!--begin::Theme Init (prevents flash of incorrect theme on load, #6043)-->
9
+ <script>
10
+ (() => {
11
+ 'use strict';
12
+ const STORAGE_KEY = 'lte-theme';
13
+ let stored = null;
14
+ try {
15
+ stored = localStorage.getItem(STORAGE_KEY);
16
+ } catch {
17
+ // localStorage may be unavailable (private mode, sandboxed iframe).
18
+ }
19
+ const prefersDark = globalThis.matchMedia('(prefers-color-scheme: dark)').matches;
20
+ // Mirror the resolution in _scripts.astro: explicit "dark"/"light" win,
21
+ // otherwise ("auto" or unset) fall back to the OS preference.
22
+ let resolved = 'light';
23
+ if (stored === 'dark' || stored === 'light') {
24
+ resolved = stored;
25
+ } else if (prefersDark) {
26
+ resolved = 'dark';
27
+ }
28
+ document.documentElement.setAttribute('data-bs-theme', resolved);
29
+ document.documentElement.style.colorScheme = resolved;
30
+ })();
31
+ </script>
32
+ <!--end::Theme Init-->
33
+
8
34
  <!--begin::Accessibility Meta Tags-->
9
35
  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
10
36
  <meta name="color-scheme" content="light dark" />