@iyulab/modern-app 0.18.3 → 0.18.4

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.18.4] - 2026-08-23
4
+
5
+ ### Fixed
6
+
7
+ - **`App.load()` now initializes the theme before checking the `auth` gate.** When `auth.me()`
8
+ resolves to `null`, `load()` calls `auth.renderLogin()` and returns before the shell is built —
9
+ but `Theme.init()` used to run only after the auth check passed, so any `renderLogin` screen
10
+ that relies on `--u-*` design tokens (background, spacing, accent colors) rendered with no
11
+ stylesheet in the document at all. `Theme.init()` and `iconBasepath` setup are pure display
12
+ configuration independent of auth state, so they now run unconditionally before the gate —
13
+ every render path, including the pre-auth login screen, has tokens available.
14
+
3
15
  ## [0.18.3] - 2026-08-22
4
16
 
5
17
  ### Fixed
package/dist/App.js CHANGED
@@ -28,7 +28,7 @@ var o = class o {
28
28
  return t;
29
29
  }
30
30
  async load(a) {
31
- if (this.unload(), this._config = a, a.auth) {
31
+ if (this.unload(), this._config = a, await i.init(a.theme), a.iconBasepath && r(a.iconBasepath), a.auth) {
32
32
  let e = await a.auth.me();
33
33
  if (e == null) {
34
34
  let e = a.root || document.body, t = a.auth.renderLogin({
@@ -42,7 +42,7 @@ var o = class o {
42
42
  }
43
43
  this._user = e, await a.auth.onAuthenticated?.(e);
44
44
  }
45
- if (await i.init(a.theme), a.iconBasepath && r(a.iconBasepath), a.i18n) {
45
+ if (a.i18n) {
46
46
  for (let e of a.i18n.plugins || []) t.use(e);
47
47
  await t.init(a.i18n);
48
48
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@iyulab/modern-app",
3
3
  "description": "web-framework by iyulab based on lit-element",
4
- "version": "0.18.3",
4
+ "version": "0.18.4",
5
5
  "keywords": [
6
6
  "iyulab",
7
7
  "web-framework",