@energy8platform/shell 0.11.4 → 0.11.5

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/dist/html.cjs.js CHANGED
@@ -1754,7 +1754,7 @@ function keyboardCapable(win = typeof window === 'undefined' ? undefined : windo
1754
1754
 
1755
1755
  // AUTO-GENERATED by scripts/gen-version.mjs — do not edit. Mirrors package.json "version".
1756
1756
  /** The @energy8platform/shell package version, stamped into the game-info footer. */
1757
- const PACKAGE_VERSION = '0.11.4';
1757
+ const PACKAGE_VERSION = '0.11.5';
1758
1758
 
1759
1759
  /** Apply defaults to the raw config (the mount target lives on the renderer, not here). */
1760
1760
  function resolveConfig(config) {
package/dist/html.d.ts CHANGED
@@ -641,7 +641,7 @@ declare class ShellController extends EventEmitter<ShellEvents> implements Shell
641
641
  tokens: ShellTokens;
642
642
  layout: ShellLayoutMode;
643
643
  soundOn: boolean;
644
- readonly engineVersion = "0.11.4";
644
+ readonly engineVersion = "0.11.5";
645
645
  readonly actions: ShellActions;
646
646
  private renderer;
647
647
  private i18n;
@@ -800,7 +800,7 @@ declare function createI18n(opts: I18nOptions): I18n;
800
800
  declare const DISCLAIMER_LINES: readonly string[];
801
801
 
802
802
  /** The @energy8platform/shell package version, stamped into the game-info footer. */
803
- declare const PACKAGE_VERSION = "0.11.4";
803
+ declare const PACKAGE_VERSION = "0.11.5";
804
804
 
805
805
  /**
806
806
  * What a scrollable region should ADVERTISE about itself.
package/dist/html.esm.js CHANGED
@@ -1752,7 +1752,7 @@ function keyboardCapable(win = typeof window === 'undefined' ? undefined : windo
1752
1752
 
1753
1753
  // AUTO-GENERATED by scripts/gen-version.mjs — do not edit. Mirrors package.json "version".
1754
1754
  /** The @energy8platform/shell package version, stamped into the game-info footer. */
1755
- const PACKAGE_VERSION = '0.11.4';
1755
+ const PACKAGE_VERSION = '0.11.5';
1756
1756
 
1757
1757
  /** Apply defaults to the raw config (the mount target lives on the renderer, not here). */
1758
1758
  function resolveConfig(config) {
package/dist/index.cjs.js CHANGED
@@ -1728,7 +1728,7 @@ function keyboardCapable(win = typeof window === 'undefined' ? undefined : windo
1728
1728
 
1729
1729
  // AUTO-GENERATED by scripts/gen-version.mjs — do not edit. Mirrors package.json "version".
1730
1730
  /** The @energy8platform/shell package version, stamped into the game-info footer. */
1731
- const PACKAGE_VERSION = '0.11.4';
1731
+ const PACKAGE_VERSION = '0.11.5';
1732
1732
 
1733
1733
  /** Apply defaults to the raw config (the mount target lives on the renderer, not here). */
1734
1734
  function resolveConfig(config) {
package/dist/index.d.ts CHANGED
@@ -641,7 +641,7 @@ declare class ShellController extends EventEmitter<ShellEvents> implements Shell
641
641
  tokens: ShellTokens;
642
642
  layout: ShellLayoutMode;
643
643
  soundOn: boolean;
644
- readonly engineVersion = "0.11.4";
644
+ readonly engineVersion = "0.11.5";
645
645
  readonly actions: ShellActions;
646
646
  private renderer;
647
647
  private i18n;
@@ -800,7 +800,7 @@ declare function createI18n(opts: I18nOptions): I18n;
800
800
  declare const DISCLAIMER_LINES: readonly string[];
801
801
 
802
802
  /** The @energy8platform/shell package version, stamped into the game-info footer. */
803
- declare const PACKAGE_VERSION = "0.11.4";
803
+ declare const PACKAGE_VERSION = "0.11.5";
804
804
 
805
805
  /**
806
806
  * What a scrollable region should ADVERTISE about itself.
package/dist/index.esm.js CHANGED
@@ -1726,7 +1726,7 @@ function keyboardCapable(win = typeof window === 'undefined' ? undefined : windo
1726
1726
 
1727
1727
  // AUTO-GENERATED by scripts/gen-version.mjs — do not edit. Mirrors package.json "version".
1728
1728
  /** The @energy8platform/shell package version, stamped into the game-info footer. */
1729
- const PACKAGE_VERSION = '0.11.4';
1729
+ const PACKAGE_VERSION = '0.11.5';
1730
1730
 
1731
1731
  /** Apply defaults to the raw config (the mount target lives on the renderer, not here). */
1732
1732
  function resolveConfig(config) {
package/dist/pixi.cjs.js CHANGED
@@ -1755,7 +1755,7 @@ function keyboardCapable(win = typeof window === 'undefined' ? undefined : windo
1755
1755
 
1756
1756
  // AUTO-GENERATED by scripts/gen-version.mjs — do not edit. Mirrors package.json "version".
1757
1757
  /** The @energy8platform/shell package version, stamped into the game-info footer. */
1758
- const PACKAGE_VERSION = '0.11.4';
1758
+ const PACKAGE_VERSION = '0.11.5';
1759
1759
 
1760
1760
  /** Apply defaults to the raw config (the mount target lives on the renderer, not here). */
1761
1761
  function resolveConfig(config) {
@@ -7214,6 +7214,10 @@ class PixiRenderer {
7214
7214
  bar;
7215
7215
  currentLayer = null;
7216
7216
  backdrop;
7217
+ /** Whether `currentLayer` asked for a frosted backdrop. Light-dismiss layers (the menu popover)
7218
+ * pass `{ backdrop: false }`, and that answer has to survive past the open: a resize re-snapshots
7219
+ * the backdrop, and without this it re-snapshotted for layers that never wanted one. */
7220
+ layerBackdrop = false;
7217
7221
  moneyAnims = [];
7218
7222
  destroyed = false;
7219
7223
  constructor(opts) {
@@ -7371,7 +7375,8 @@ class PixiRenderer {
7371
7375
  this.clearLayer();
7372
7376
  // Light-dismiss layers (the menu popover) opt out with `{ backdrop: false }` — no frosted
7373
7377
  // snapshot, the game stays visible behind them. Every other caller is unaffected (defaults on).
7374
- if (opts?.backdrop !== false)
7378
+ this.layerBackdrop = opts?.backdrop !== false;
7379
+ if (this.layerBackdrop)
7375
7380
  this.makeBackdrop(); // frosted snapshot (the DOM's backdrop-filter:blur)
7376
7381
  this.currentLayer = node;
7377
7382
  this.modalLayer.addChild(node);
@@ -7394,6 +7399,7 @@ class PixiRenderer {
7394
7399
  this.currentLayer.destroy({ children: true });
7395
7400
  this.currentLayer = null;
7396
7401
  }
7402
+ this.layerBackdrop = false;
7397
7403
  this.removeBackdrop();
7398
7404
  }
7399
7405
  fitModals() {
@@ -7417,7 +7423,10 @@ class PixiRenderer {
7417
7423
  // reads as more frost, never sharp game.
7418
7424
  node.addChild(new pixi_js.Graphics().rect(0, 0, w, h).fill(0x0c111c));
7419
7425
  this.modalLayer.addChild(node);
7420
- this.backdrop = { node, texture: pixi_js.RenderTexture.create({ width: w, height: h, resolution: 0.25 }) };
7426
+ this.backdrop = {
7427
+ node,
7428
+ texture: pixi_js.RenderTexture.create({ width: w, height: h, resolution: 0.25 }),
7429
+ };
7421
7430
  try {
7422
7431
  // Heavy downscale (¼ res) is the blur-STRENGTH lever (each texel covers more screen), far cheaper
7423
7432
  // than a full-res large-radius blur and smooth over fine detail. Effective on-screen blur ≈
@@ -7475,9 +7484,15 @@ class PixiRenderer {
7475
7484
  this.host.notifyResize(this.screenW, this.screenH);
7476
7485
  if (this.currentLayer) {
7477
7486
  this.currentLayer.resize?.(this.screenW, this.screenH);
7478
- this.makeBackdrop(); // re-snapshot at the new size
7479
- if (this.backdrop)
7480
- this.modalLayer.setChildIndex(this.backdrop.node, 0); // keep it below the layer
7487
+ // Only for a layer that ASKED for the frost. A rotation with the bar menu open used to slap a
7488
+ // backdrop under a light-dismiss popover that had opted out of one — and since modalLayer
7489
+ // draws above barLayer, that frozen blurred snapshot covered the game AND the bar until the
7490
+ // menu was closed. That is the "UI is not adopted on rotation while the menu is open" remark.
7491
+ if (this.layerBackdrop) {
7492
+ this.makeBackdrop(); // re-snapshot at the new size
7493
+ if (this.backdrop)
7494
+ this.modalLayer.setChildIndex(this.backdrop.node, 0); // keep it below the layer
7495
+ }
7481
7496
  }
7482
7497
  };
7483
7498
  // ── PixiComponentContext factory ──────────────────────────────────────────────
@@ -7489,13 +7504,27 @@ class PixiRenderer {
7489
7504
  const self = this;
7490
7505
  const ctx = {
7491
7506
  // — core ShellHost (forwarded) —
7492
- get state() { return host.state; },
7493
- get config() { return host.config; },
7494
- get tokens() { return host.tokens; },
7495
- get layout() { return host.layout; },
7496
- get soundOn() { return host.soundOn; },
7497
- get menu() { return host.menu; },
7498
- get actions() { return host.actions; },
7507
+ get state() {
7508
+ return host.state;
7509
+ },
7510
+ get config() {
7511
+ return host.config;
7512
+ },
7513
+ get tokens() {
7514
+ return host.tokens;
7515
+ },
7516
+ get layout() {
7517
+ return host.layout;
7518
+ },
7519
+ get soundOn() {
7520
+ return host.soundOn;
7521
+ },
7522
+ get menu() {
7523
+ return host.menu;
7524
+ },
7525
+ get actions() {
7526
+ return host.actions;
7527
+ },
7499
7528
  openReplay: (opts) => host.openReplay(opts),
7500
7529
  t: (s) => host.t(s),
7501
7530
  formatCurrency: (n, win) => host.formatCurrency(n, win),
@@ -7508,10 +7537,18 @@ class PixiRenderer {
7508
7537
  setMenuValue: (id, v) => host.setMenuValue(id, v),
7509
7538
  setMenuRefresh: (fn) => host.setMenuRefresh(fn),
7510
7539
  // — Pixi-specific surface —
7511
- get ticker() { return self.app.ticker; },
7512
- get canvas() { return self.app.canvas; },
7513
- get screenW() { return self.app.screen.width; },
7514
- get screenH() { return self.app.screen.height; },
7540
+ get ticker() {
7541
+ return self.app.ticker;
7542
+ },
7543
+ get canvas() {
7544
+ return self.app.canvas;
7545
+ },
7546
+ get screenW() {
7547
+ return self.app.screen.width;
7548
+ },
7549
+ get screenH() {
7550
+ return self.app.screen.height;
7551
+ },
7515
7552
  render: () => self.renderBar(),
7516
7553
  pushLayer: (node, opts) => self.pushLayer(node, opts),
7517
7554
  // Route component-initiated closes through the controller (not straight to self.closeLayer) so