@famibee/skynovel 1.64.22 → 1.65.0

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 (61) hide show
  1. package/dist/CmnTween.js +921 -109
  2. package/dist/CmnTween.js.map +1 -1
  3. package/dist/EventMng.js +1 -1
  4. package/dist/EventMng.js.map +1 -1
  5. package/dist/GrpLayer.js +1 -1
  6. package/dist/LayerMng.js +43 -44
  7. package/dist/LayerMng.js.map +1 -1
  8. package/dist/Main.js.map +1 -1
  9. package/dist/RubySpliter.js +18 -15
  10. package/dist/RubySpliter.js.map +1 -1
  11. package/dist/ScriptIterator.js +1 -2
  12. package/dist/ScriptIterator.js.map +1 -1
  13. package/dist/SndBuf.js +83 -77
  14. package/dist/SndBuf.js.map +1 -1
  15. package/dist/SpritesMng.js +1 -1
  16. package/dist/TxtLayer.js +96 -97
  17. package/dist/TxtLayer.js.map +1 -1
  18. package/dist/Variable.js +1 -1
  19. package/dist/sn/CmnTween.d.ts +4 -4
  20. package/dist/sn/CmnTween.d.ts.map +1 -1
  21. package/dist/sn/FocusMng.d.ts.map +1 -1
  22. package/dist/sn/Log.d.ts.map +1 -1
  23. package/dist/sn/Main.d.ts.map +1 -1
  24. package/dist/sn/Pages.d.ts.map +1 -1
  25. package/dist/sn/Reading.d.ts +1 -0
  26. package/dist/sn/Reading.d.ts.map +1 -1
  27. package/dist/sn/RubySpliter.d.ts.map +1 -1
  28. package/dist/sn/SndBuf.d.ts.map +1 -1
  29. package/dist/sn/TxtStage.d.ts +2 -0
  30. package/dist/sn/TxtStage.d.ts.map +1 -1
  31. package/dist_app/CmnTween.js +921 -109
  32. package/dist_app/CmnTween.js.map +1 -1
  33. package/dist_app/EventMng.js +1 -1
  34. package/dist_app/EventMng.js.map +1 -1
  35. package/dist_app/GrpLayer.js +1 -1
  36. package/dist_app/LayerMng.js +2 -3
  37. package/dist_app/LayerMng.js.map +1 -1
  38. package/dist_app/Main.js.map +1 -1
  39. package/dist_app/RubySpliter.js +18 -15
  40. package/dist_app/RubySpliter.js.map +1 -1
  41. package/dist_app/ScriptIterator.js +1 -2
  42. package/dist_app/ScriptIterator.js.map +1 -1
  43. package/dist_app/SndBuf.js +83 -77
  44. package/dist_app/SndBuf.js.map +1 -1
  45. package/dist_app/SpritesMng.js +1 -1
  46. package/dist_app/TxtLayer.js +96 -97
  47. package/dist_app/TxtLayer.js.map +1 -1
  48. package/dist_app/Variable.js +1 -1
  49. package/dist_app/sn/CmnTween.d.ts +4 -4
  50. package/dist_app/sn/CmnTween.d.ts.map +1 -1
  51. package/dist_app/sn/FocusMng.d.ts.map +1 -1
  52. package/dist_app/sn/Log.d.ts.map +1 -1
  53. package/dist_app/sn/Main.d.ts.map +1 -1
  54. package/dist_app/sn/Pages.d.ts.map +1 -1
  55. package/dist_app/sn/Reading.d.ts +1 -0
  56. package/dist_app/sn/Reading.d.ts.map +1 -1
  57. package/dist_app/sn/RubySpliter.d.ts.map +1 -1
  58. package/dist_app/sn/SndBuf.d.ts.map +1 -1
  59. package/dist_app/sn/TxtStage.d.ts +2 -0
  60. package/dist_app/sn/TxtStage.d.ts.map +1 -1
  61. package/package.json +3 -3
package/dist/TxtLayer.js CHANGED
@@ -1,15 +1,14 @@
1
- import { e as F, l as S, y as rt, q as P, a as j, R as A, G as B, x as G, M as X, z as tt, N as ot, w as V, S as et, u as M, r as ct } from "./web2.js";
2
- import { C as dt } from "./CmnTween.js";
3
- import { S as I } from "./SpritesMng.js";
1
+ import { e as F, l as S, y as ot, q as P, a as T, R as A, G as B, x as U, M as X, z as tt, N as ct, w as V, S as et, u as M, r as dt } from "./web2.js";
2
+ import { a as I, C as st, G as pt, T as ft } from "./CmnTween.js";
3
+ import { S as W } from "./SpritesMng.js";
4
4
  import { D as K } from "./DebugMng.js";
5
- import { a as W, T as pt } from "./Reading.js";
6
- import { R as st } from "./RubySpliter.js";
7
- import { Button as ft } from "./Button.js";
8
- const H = "、。,.)]}〉」』】〕”〟ぁぃぅぇぉっゃゅょゎァィゥェォッャュョヮヵヶ!?!?‼⁉・ーゝゞヽヾ々", q = "[({〈「『【〔“〝", U = "─‥…", Y = H, it = new RegExp(`[${H}]`), ut = new RegExp(`[${q}]`), gt = new RegExp(`[${U}]`), _t = it;
9
- class yt {
5
+ import { R as it } from "./RubySpliter.js";
6
+ import { Button as ut } from "./Button.js";
7
+ const H = "、。,.)]}〉」』】〕”〟ぁぃぅぇぉっゃゅょゎァィゥェォッャュョヮヵヶ!?!?‼⁉・ーゝゞヽヾ々", G = "[({〈「『【〔“〝", q = "─‥…", Y = H, nt = new RegExp(`[${H}]`), gt = new RegExp(`[${G}]`), _t = new RegExp(`[${q}]`), yt = nt;
8
+ class mt {
10
9
  #c = H;
11
- #n = q;
12
- #r = U;
10
+ #n = G;
11
+ #r = q;
13
12
  #a = Y;
14
13
  get 行頭禁則() {
15
14
  return this.#c;
@@ -23,10 +22,10 @@ class yt {
23
22
  get ぶら下げ() {
24
23
  return this.#a;
25
24
  }
26
- #e = it;
27
- #h = ut;
28
- #p = gt;
29
- #k = _t;
25
+ #e = nt;
26
+ #h = gt;
27
+ #p = _t;
28
+ #k = yt;
30
29
  break_fixed = !1;
31
30
  break_fixed_left = 0;
32
31
  break_fixed_top = 0;
@@ -75,13 +74,13 @@ class yt {
75
74
  break_fixed_top: this.break_fixed_top,
76
75
  bura: this.bura
77
76
  };
78
- return this.#c === H && (t.行頭禁則 = this.#c), this.#n === q && (t.行末禁則 = this.#n), this.#r === U && (t.分割禁止 = this.#r), this.#a === Y && (t.ぶら下げ = this.#a), t;
77
+ return this.#c === H && (t.行頭禁則 = this.#c), this.#n === G && (t.行末禁則 = this.#n), this.#r === q && (t.分割禁止 = this.#r), this.#a === Y && (t.ぶら下げ = this.#a), t;
79
78
  }
80
79
  playback(t) {
81
80
  t && (this.#t(
82
81
  t.行頭禁則 ?? H,
83
- t.行末禁則 ?? q,
84
- t.分割禁止 ?? U,
82
+ t.行末禁則 ?? G,
83
+ t.分割禁止 ?? q,
85
84
  t.ぶら下げ ?? Y
86
85
  ), this.break_fixed = t.break_fixed, this.break_fixed_left = t.break_fixed_left, this.break_fixed_top = t.break_fixed_top, this.bura = t.bura);
87
86
  }
@@ -206,7 +205,7 @@ class yt {
206
205
  return { cont: !1, ins: a };
207
206
  }
208
207
  }
209
- function mt(Q, t, e, s, i, a = !0) {
208
+ function bt(Q, t, e, s, i, a = !0) {
210
209
  const n = {
211
210
  escape: (o) => o.replaceAll(/([.*+?^${}()|[\]/\\])/g, "\\$1"),
212
211
  mimeType: (o) => {
@@ -303,16 +302,16 @@ function mt(Q, t, e, s, i, a = !0) {
303
302
  });
304
303
  }
305
304
  function m(_, f, p, E) {
306
- return Promise.resolve(f).then((R) => p ? n.resolveUrl(R, p) : R).then(E || n.getAndEncode).then((R) => n.dataAsUrl(R, n.mimeType(f))).then((R) => _.replace(T(f), "$1" + R + "$3"));
307
- function T(R) {
305
+ return Promise.resolve(f).then((R) => p ? n.resolveUrl(R, p) : R).then(E || n.getAndEncode).then((R) => n.dataAsUrl(R, n.mimeType(f))).then((R) => _.replace(j(f), "$1" + R + "$3"));
306
+ function j(R) {
308
307
  return new RegExp(`(url\\(['"]?)(` + n.escape(R) + `)(['"]?\\))`, "g");
309
308
  }
310
309
  }
311
310
  function v(_, f, p) {
312
311
  if (E()) return Promise.resolve(_);
313
- return Promise.resolve(_).then(u).then((T) => {
312
+ return Promise.resolve(_).then(u).then((j) => {
314
313
  let R = Promise.resolve(_);
315
- for (const J of T) R = R.then((O) => m(O, J, f, p));
314
+ for (const J of j) R = R.then((O) => m(O, J, f, p));
316
315
  return R;
317
316
  });
318
317
  function E() {
@@ -372,13 +371,13 @@ function mt(Q, t, e, s, i, a = !0) {
372
371
  });
373
372
  }).then((o) => new Promise((d) => setTimeout(() => d(o), 100))).then((o) => {
374
373
  const d = document.createElement("canvas");
375
- d.width = e.$width, d.height = e.$height, d.getContext("2d").drawImage(o, 0, 0), Q(rt.from(d));
374
+ d.width = e.$width, d.height = e.$height, d.getContext("2d").drawImage(o, 0, 0), Q(ot.from(d));
376
375
  }).catch((o) => K.myTrace(`goTxt() = ${String(o)}`));
377
376
  }
378
377
  class c extends P {
379
378
  constructor(t, e, s) {
380
379
  super(), this.ctn = t, this.canFocus = e, this.sys = s, this.#e.classList.add("sn_tx"), this.#e.style.position = "absolute", c.#n.view.parentElement.appendChild(this.#e), this.addChild(this.#h), this.addChild(this.#p), this.#p.name = "grpDbgMasume";
381
- const i = j.debugLog ? ({ ch: a, rect: { x: n, y: l, width: h, height: r } }) => console.log(`🍌 masume ch:${a} x:${String(n)} y:${String(l)} w:${String(h)} h:${String(r)}`) : () => {
380
+ const i = T.debugLog ? ({ ch: a, rect: { x: n, y: l, width: h, height: r } }) => console.log(`🍌 masume ch:${a} x:${String(n)} y:${String(l)} w:${String(h)} h:${String(r)}`) : () => {
382
381
  };
383
382
  this.#g = c.#c.oCfg.debug.masume ? (a) => {
384
383
  i(a);
@@ -386,7 +385,7 @@ class c extends P {
386
385
  this.#p.beginFill(6737151, 0.5).lineStyle(2, 16724736, 1).drawRect(n, l, h, r).endFill();
387
386
  } : () => {
388
387
  }, this.noticeCompTxt = s.isApp && c.#c.oCfg.debug.dumpHtm ? () => {
389
- W.notifyEndProc(A);
388
+ I.notifyEndProc(A);
390
389
  const a = this.#e.innerHTML;
391
390
  if (a === "") return;
392
391
  const { fn: n, ln: l } = c.#a.nowScrFnLn(), h = `dumpHtm ${t.name.slice(0, -7).replaceAll(":", "=")}(fn=${n} line=${String(l)})`;
@@ -398,13 +397,14 @@ $1
398
397
  `).replaceAll(/<(br|\/span)>/g, `<$1>
399
398
  `)}`
400
399
  );
401
- } : () => W.notifyEndProc(A);
400
+ } : () => I.notifyEndProc(A);
402
401
  }
403
402
  static #c;
404
403
  static #n;
405
404
  static init(t, e) {
406
- c.#c = t, c.#n = e;
405
+ c.#c = t, c.#n = e, st.addGrp(c.grp);
407
406
  }
407
+ static grp = new pt();
408
408
  static #r;
409
409
  static #a;
410
410
  static setEvtMng(t, e) {
@@ -429,7 +429,7 @@ $1
429
429
  "margin-right": 0,
430
430
  "margin-top": 0
431
431
  };
432
- #l = new yt();
432
+ #l = new mt();
433
433
  noticeCompTxt = () => {
434
434
  };
435
435
  #g;
@@ -515,24 +515,24 @@ $1
515
515
  }
516
516
  #v = [];
517
517
  #y = 0;
518
- static #q = "<span class='sn_ch sn_ch_last'>&emsp;</span>";
518
+ static #G = "<span class='sn_ch sn_ch_last'>&emsp;</span>";
519
519
  #m(t, e) {
520
520
  c.#O.visible = !1;
521
521
  let s = this.#v.length, i = "";
522
522
  if (s === 0) {
523
- if (c.#c.oCfg.debug.masume && (j.debugLog && console.log(`🍌 masume ${this.name} v:${String(this.visible)} l:${String(this.x)} t:${String(this.y)} a:${String(this.alpha)} pl:${String(this.#t.pad_left)} pr:${String(this.#t.pad_right)} pt:${String(this.#t.pad_top)} pb:${String(this.#t.pad_bottom)} w:${String(this.#t.$width)} h:${String(this.#t.$height)}`), this.#p.clear().beginFill(3407616, 0.2).lineStyle(1, 3407616, 1).drawRect(-this.#t.pad_left, -this.#t.pad_top, this.#t.$width, this.#t.$height).endFill().beginFill(13311, 0.2).lineStyle(2, 13311, 1).drawRect(
523
+ if (c.#c.oCfg.debug.masume && (T.debugLog && console.log(`🍌 masume ${this.name} v:${String(this.visible)} l:${String(this.x)} t:${String(this.y)} a:${String(this.alpha)} pl:${String(this.#t.pad_left)} pr:${String(this.#t.pad_right)} pt:${String(this.#t.pad_top)} pb:${String(this.#t.pad_bottom)} w:${String(this.#t.$width)} h:${String(this.#t.$height)}`), this.#p.clear().beginFill(3407616, 0.2).lineStyle(1, 3407616, 1).drawRect(-this.#t.pad_left, -this.#t.pad_top, this.#t.$width, this.#t.$height).endFill().beginFill(13311, 0.2).lineStyle(2, 13311, 1).drawRect(
524
524
  0,
525
525
  0,
526
526
  this.#t.$width - this.#t.pad_left - this.#t.pad_right,
527
527
  this.#t.$height - this.#t.pad_top - this.#t.pad_bottom
528
- ).endFill()), this.#e.innerHTML = [...t].join("").replaceAll(/[\n\t]/g, "") + c.#q, !this.#l.break_fixed) {
528
+ ).endFill()), this.#e.innerHTML = [...t].join("").replaceAll(/[\n\t]/g, "") + c.#G, !this.#l.break_fixed) {
529
529
  const g = globalThis.getComputedStyle(this.#e), $ = parseFloat(g.fontSize);
530
530
  this.#f ? (this.#l.break_fixed_left = (this.#t.$width - this.#t.pad_left - this.#t.pad_right - $ * 1.5) * this.sys.cvsScale, this.#l.break_fixed_top = 0) : (this.#l.break_fixed_left = 0, this.#l.break_fixed_top = $ / 2 * this.sys.cvsScale);
531
531
  }
532
532
  } else
533
533
  i = this.#e.innerHTML, --s, this.#e.getElementsByClassName("sn_ch_last").item(0)?.remove(), this.#e.querySelectorAll(":scope > br").forEach((g) => g.remove()), this.#e.insertAdjacentHTML(
534
534
  "beforeend",
535
- t.slice(this.#y).join("").replaceAll(/[\n\t]/g, "") + c.#q
535
+ t.slice(this.#y).join("").replaceAll(/[\n\t]/g, "") + c.#G
536
536
  // 末尾改行削除挙動対策
537
537
  );
538
538
  this.#e.querySelectorAll(".sn_ch:has(> ruby)").forEach((g) => {
@@ -563,34 +563,34 @@ $1
563
563
  }
564
564
  const [b, y] = this.#l.hyph(this.#e, r, this.#f, s, i);
565
565
  this.#v = b;
566
- const w = dt.ease(this.#C);
566
+ const w = st.ease(this.#C);
567
567
  for (let g = s; g < y; ++g) {
568
568
  const $ = this.#v[g], { elm: { dataset: o, parentElement: d }, rect: u } = $, m = JSON.parse(o.arg ?? '{"delay": 0}'), v = JSON.parse(o.add ?? "{}"), _ = c.#$[v.ch_in_style];
569
569
  if (this.#g($), o.cmd === "grp") {
570
570
  const f = new P();
571
- this.#h.addChild(f), new I(m.pic, f, (p) => {
571
+ this.#h.addChild(f), new W(m.pic, f, (p) => {
572
572
  this.#B(f, m, v, u, w, _ ?? {}), f.parent || f.removeChild(p);
573
573
  });
574
574
  }
575
575
  if (o.lnk) {
576
576
  const f = d.closest("[data-arg]"), p = JSON.parse(f.dataset.arg ?? "{}");
577
577
  p.key = `lnk=[${String(g)}] ` + this.name;
578
- const E = new G();
578
+ const E = new U();
579
579
  this.#B(E, p, v, u, w, _ ?? {});
580
- const T = p.style ?? "", R = T + (p.style_hover ?? ""), J = T + (p.style_clicked ?? ""), O = p.r_style ?? "", nt = O + (p.r_style_hover ?? ""), at = O + (p.r_style_clicked ?? ""), Z = Array.from(f.getElementsByTagName("rt"));
580
+ const j = p.style ?? "", R = j + (p.style_hover ?? ""), J = j + (p.style_clicked ?? ""), O = p.r_style ?? "", at = O + (p.r_style_hover ?? ""), ht = O + (p.r_style_clicked ?? ""), Z = Array.from(f.getElementsByTagName("rt"));
581
581
  for (const z of Z) z.dataset.st_r_bk = z.style.cssText;
582
- const ht = f.style.cssText, D = (z, lt) => {
583
- f.style.cssText = ht + z;
584
- for (const L of Z) L.style.cssText = L.dataset.st_r_bk + lt;
582
+ const lt = f.style.cssText, D = (z, rt) => {
583
+ f.style.cssText = lt + z;
584
+ for (const L of Z) L.style.cssText = L.dataset.st_r_bk + rt;
585
585
  };
586
586
  F(p, "enabled", !0) ? c.#r.button(
587
587
  p,
588
588
  E,
589
- () => D(T, O),
590
- () => this.canFocus() ? (D(R, nt), !0) : !1,
591
- () => D(J, at)
589
+ () => D(j, O),
590
+ () => this.canFocus() ? (D(R, at), !0) : !1,
591
+ () => D(J, ht)
592
592
  ) : D(
593
- T + (p.style_disable ?? "color: gray;"),
593
+ j + (p.style_disable ?? "color: gray;"),
594
594
  O + (p.r_style_disable ?? "color: gray;")
595
595
  ), this.#h.addChild(E);
596
596
  }
@@ -634,13 +634,12 @@ $1
634
634
  // eslint-disable-next-line @typescript-eslint/no-unsafe-call
635
635
  n.y.startsWith("=") ? i.y + t.height * n.ny : n.ny
636
636
  ) : t.position.set(i.x, i.y);
637
- const l = {
638
- sp: t,
639
- tw: new pt(t).to({ alpha: 1, x: i.x, y: i.y, width: i.width, height: i.height, angle: 0 }, n.wait ?? 0).easing(a).delay((s.wait ?? 0) + (e.delay ?? 0)).onComplete(() => {
640
- l.tw = void 0;
641
- }).start()
642
- };
643
- this.#P.push(l);
637
+ const l = new ft(t).to({ alpha: 1, x: i.x, y: i.y, width: i.width, height: i.height, angle: 0 }, n.wait ?? 0).easing(a).delay((s.wait ?? 0) + (e.delay ?? 0)).onComplete(() => {
638
+ h.tw = void 0;
639
+ }).start();
640
+ c.grp.add(l);
641
+ const h = { sp: t, tw: l };
642
+ this.#P.push(h);
644
643
  }
645
644
  #P = [];
646
645
  skipChIn() {
@@ -723,11 +722,11 @@ $1
723
722
  };
724
723
  }
725
724
  static #O = new P();
726
- static #H = new I();
725
+ static #H = new W();
727
726
  dispBreak(t) {
728
727
  c.delBreak();
729
728
  const e = c.#O;
730
- e.visible = !1, this.addChild(e), c.#H.destroy(), c.#H = new I(t.pic, e, (s) => {
729
+ e.visible = !1, this.addChild(e), c.#H.destroy(), c.#H = new W(t.pic, e, (s) => {
731
730
  e.parent ? (s.x = S(t, "x", 0), s.y = S(t, "y", 0), s.width = S(t, "width", this.#t.fontsize), s.height = S(t, "height", this.#t.fontsize)) : e.removeChild(s);
732
731
  });
733
732
  }
@@ -811,8 +810,8 @@ $1
811
810
  }
812
811
  #d = void 0;
813
812
  snapshot(t, e) {
814
- mt((s) => {
815
- this.#d = G.from(s), this.#f && (this.#d.x += j.stageW - (this.#o + this.#t.$width)), this.#d.y -= this.#b, this.#d.texture.frame = new X(
813
+ bt((s) => {
814
+ this.#d = U.from(s), this.#f && (this.#d.x += T.stageW - (this.#o + this.#t.$width)), this.#d.y -= this.#b, this.#d.texture.frame = new X(
816
815
  0,
817
816
  0,
818
817
  Math.min(this.#d.width, this.#t.$width - this.#o),
@@ -847,7 +846,7 @@ class k extends tt {
847
846
  static #r;
848
847
  static #a;
849
848
  static init(t, e, s, i, a, n) {
850
- this.#c = t, c.init(t, n), this.#n = s, this.#a = i, this.#r = a, s.setDoRecProc((l) => this.chgDoRec(l)), e.autowc = (l) => this.#u(l), e.autowc({ enabled: !1, text: "", time: 0 }), e.ch_in_style = (l) => this.#e(l), e.ch_out_style = (l) => this.#h(l), c.initChStyle(), ot(), V(
849
+ this.#c = t, c.init(t, n), this.#n = s, this.#a = i, this.#r = a, s.setDoRecProc((l) => this.chgDoRec(l)), e.autowc = (l) => this.#u(l), e.autowc({ enabled: !1, text: "", time: 0 }), e.ch_in_style = (l) => this.#e(l), e.ch_out_style = (l) => this.#h(l), c.initChStyle(), ct(), V(
851
850
  t.matchPath(".+", et.FONT).flatMap((l) => Object.values(l).map((h) => `
852
851
  @font-face {
853
852
  font-family: '${String(h)}';
@@ -964,10 +963,10 @@ class k extends tt {
964
963
  // 背景画像無し(=単色塗り)
965
964
  // 文字表示
966
965
  #s = new c(this.ctn, () => this.canFocus(), k.#l);
967
- #v = new st();
966
+ #v = new it();
968
967
  #y = document.createElement("span");
969
968
  // cssチェック・保存用
970
- static #q = {
969
+ static #G = {
971
970
  "text-align": 0,
972
971
  "text-align-last": 0,
973
972
  height: 0,
@@ -979,7 +978,7 @@ class k extends tt {
979
978
  };
980
979
  #m = new P();
981
980
  constructor() {
982
- super(), this.ctn.addChild(this.#s), this.#v.init(this.#Y), this.ctn.addChild(this.#m), this.#m.name = "cntBtn", this.lay({ style: `width: ${String(j.stageW)}px; height: ${String(j.stageH)}px; font-family: 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', '游ゴシック Medium', meiryo, sans-serif; color: white; font-size: 24px; line-height: 1.5; padding: ${String(16)}px;`, in_style: "default", out_style: "default", back_clear: "true" });
981
+ super(), this.ctn.addChild(this.#s), this.#v.init(this.#Y), this.ctn.addChild(this.#m), this.#m.name = "cntBtn", this.lay({ style: `width: ${String(T.stageW)}px; height: ${String(T.stageH)}px; font-family: 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', '游ゴシック Medium', meiryo, sans-serif; color: white; font-size: 24px; line-height: 1.5; padding: ${String(16)}px;`, in_style: "default", out_style: "default", back_clear: "true" });
983
982
  }
984
983
  destroy() {
985
984
  this.#i && (this.ctn.removeChild(this.#i).destroy(), this.#i = void 0), k.#a.pagebreak(), this.#s.destroy();
@@ -1007,14 +1006,14 @@ class k extends tt {
1007
1006
  this.#s.lay({ y: t });
1008
1007
  }
1009
1008
  lay(t) {
1010
- if (super.lay(t), tt.setXY(this.ctn, t, this.ctn), t[":id_tag"] = this.name_.slice(0, -7), st.setting(t), this.#H(t), this.#s.lay(t), "r_align" in t && (this.#x = t.r_align ?? ""), this.#d = j.isSafari ? this.#s.tategaki ? (i, a) => `text-align: start; height: ${String(a)}em; padding-top: ${i}; padding-bottom: ${i};` : (i, a) => `text-align: start; width: ${String(a)}em; padding-left: ${i}; padding-right: ${i};` : this.#s.tategaki ? (i) => `text-align: justify; text-align-last: justify; padding-top: ${i}; padding-bottom: ${i};` : (i) => `text-align: justify; text-align-last: justify; padding-left: ${i}; padding-right: ${i};`, j.isFirefox && (this.#U = this.#Z), "r_style" in t)
1009
+ if (super.lay(t), tt.setXY(this.ctn, t, this.ctn), t[":id_tag"] = this.name_.slice(0, -7), it.setting(t), this.#H(t), this.#s.lay(t), "r_align" in t && (this.#x = t.r_align ?? ""), this.#d = T.isSafari ? this.#s.tategaki ? (i, a) => `text-align: start; height: ${String(a)}em; padding-top: ${i}; padding-bottom: ${i};` : (i, a) => `text-align: start; width: ${String(a)}em; padding-left: ${i}; padding-right: ${i};` : this.#s.tategaki ? (i) => `text-align: justify; text-align-last: justify; padding-top: ${i}; padding-bottom: ${i};` : (i) => `text-align: justify; text-align-last: justify; padding-left: ${i}; padding-right: ${i};`, T.isFirefox && (this.#q = this.#Z), "r_style" in t)
1011
1010
  if (t.r_style) {
1012
1011
  const i = document.createElement("span");
1013
1012
  i.style.cssText = t.r_style;
1014
1013
  const a = i.style.length, n = this.#y.style;
1015
1014
  for (let l = 0; l < a; ++l) {
1016
1015
  const h = i.style[l];
1017
- if (h in k.#q) {
1016
+ if (h in k.#G) {
1018
1017
  K.myTrace(`${String(h)}は指定できません`, "W");
1019
1018
  continue;
1020
1019
  }
@@ -1024,10 +1023,10 @@ class k extends tt {
1024
1023
  } else this.#y.style.cssText = "";
1025
1024
  if ("alpha" in t) for (const i of this.#m.children) i.alpha = this.ctn.alpha;
1026
1025
  this.#S(t), this.#$(t);
1027
- const e = W.procID + `TxtLayer lay name:${this.name_}`, s = this.#O(t, (i) => {
1028
- i && W.endProc(e);
1026
+ const e = I.procID + `TxtLayer lay name:${this.name_}`, s = this.#O(t, (i) => {
1027
+ i && I.endProc(e);
1029
1028
  });
1030
- return s && W.beginProc(e), s;
1029
+ return s && I.beginProc(e), s;
1031
1030
  }
1032
1031
  #S(t) {
1033
1032
  const { in_style: e } = t;
@@ -1051,7 +1050,7 @@ class k extends tt {
1051
1050
  this.#W = e;
1052
1051
  }
1053
1052
  #W = "";
1054
- #E = new I();
1053
+ #E = new W();
1055
1054
  #O(t, e) {
1056
1055
  if ("back_clear" in t)
1057
1056
  return F(t, "back_clear", !1) && (this.#_ = 0, this.#o = 0, this.#f = !1, this.#b = ""), e(!1), !1;
@@ -1059,10 +1058,10 @@ class k extends tt {
1059
1058
  const s = (this.#f ? 1 : Number(k.#n.getVal("sys:TextLayer.Back.Alpha"))) * this.#o;
1060
1059
  if (t.b_pic) {
1061
1060
  if (this.#b !== t.b_pic)
1062
- return this.#b = t.b_pic, this.#i && (this.ctn.removeChild(this.#i), this.#i.destroy()), this.#E = new I(this.#b, this.ctn, (i) => {
1061
+ return this.#b = t.b_pic, this.#i && (this.ctn.removeChild(this.#i), this.#i.destroy()), this.#E = new W(this.#b, this.ctn, (i) => {
1063
1062
  this.#i = i, i.name = "back(pic)", i.visible = s > 0, i.alpha = s, this.#s.setMySize(i.width, i.height), this.ctn.setChildIndex(i, 0), e(!0);
1064
1063
  }), this.#E.ret;
1065
- } else "b_color" in t && (this.#_ = ct(t, "b_color", 0), this.#i && (this.ctn.removeChild(this.#i), this.#i.destroy()), this.#b = "", this.ctn.addChildAt(
1064
+ } else "b_color" in t && (this.#_ = dt(t, "b_color", 0), this.#i && (this.ctn.removeChild(this.#i), this.#i.destroy()), this.#b = "", this.ctn.addChildAt(
1066
1065
  (this.#i = new B()).beginFill(this.#_, s).lineStyle(void 0).drawRect(0, 0, this.#s.getWidth, this.#s.getHeight).endFill(),
1067
1066
  0
1068
1067
  ), this.#i.name = "back(color)");
@@ -1090,7 +1089,7 @@ class k extends tt {
1090
1089
  static #F = (t) => t;
1091
1090
  isCur = !1;
1092
1091
  #d = () => "";
1093
- #U = (t, e, s, i = "") => {
1092
+ #q = (t, e, s, i = "") => {
1094
1093
  if (!s) return ` style='${i}'`;
1095
1094
  const a = t.length * 2;
1096
1095
  if (a - e.length < 0) return ` style='text-align: ${s}; ${i}'`;
@@ -1193,36 +1192,36 @@ class k extends tt {
1193
1192
  break;
1194
1193
  case "gotxt":
1195
1194
  this.#V(), this.#w ? (this.isCur && k.#a.recText(
1196
- this.#T.join("").replace(/^<ruby>&emsp;<rt>&emsp;<\/rt><\/ruby>(<br\/>)+/, "").replaceAll(/style='(anim\S+ [^;]+;\s*)+/g, "style='").replaceAll(/( style=''| data-(add|arg|cmd)='[^']+'|\n+|\t+)/g, "").replaceAll(/class='sn_ch[^']+/g, "class='sn_ch").replaceAll("display: none;", "").replaceAll("class='offrec'", "style='display: none;'")
1197
- ), this.#s.goTxt(this.#T, this.#I === 0), this.#w = !1, this.#I = 0) : this.isCur && this.#s.noticeCompTxt();
1195
+ this.#j.join("").replace(/^<ruby>&emsp;<rt>&emsp;<\/rt><\/ruby>(<br\/>)+/, "").replaceAll(/style='(anim\S+ [^;]+;\s*)+/g, "style='").replaceAll(/( style=''| data-(add|arg|cmd)='[^']+'|\n+|\t+)/g, "").replaceAll(/class='sn_ch[^']+/g, "class='sn_ch").replaceAll("display: none;", "").replaceAll("class='offrec'", "style='display: none;'")
1196
+ ), this.#s.goTxt(this.#j, this.#I === 0), this.#w = !1, this.#I = 0) : this.isCur && this.#s.noticeCompTxt();
1198
1197
  return;
1199
1198
  // breakではない
1200
1199
  case "add":
1201
1200
  {
1202
1201
  const r = JSON.parse(h), { style: b = "", wait: y = null } = r, { cl: w, sty: C } = this.#D(!0, y ? M(y) : null);
1203
- this.#T.push(`<span${w} style='${C} display: inline; ${b}'>`), delete r.style, this.#K(r);
1202
+ this.#j.push(`<span${w} style='${C} display: inline; ${b}'>`), delete r.style, this.#K(r);
1204
1203
  }
1205
1204
  return;
1206
1205
  // breakではない
1207
1206
  case "add_close":
1208
- this.#T.push("</span>"), this.#V();
1207
+ this.#j.push("</span>"), this.#V();
1209
1208
  return;
1210
1209
  // breakではない
1211
1210
  case "grp":
1212
1211
  this.#w = !0;
1213
1212
  {
1214
1213
  const r = JSON.parse(h);
1215
- if (r.id ??= String(this.#T.length), r.id === "break") {
1214
+ if (r.id ??= String(this.#j.length), r.id === "break") {
1216
1215
  this.#s.dispBreak(r);
1217
1216
  return;
1218
1217
  }
1219
1218
  this.#M = !1, r.delay = this.#I, r.r ??= "", r.style ??= "", r.r_style ??= "";
1220
1219
  const { r: b, wait: y = null, r_style: w } = r, { cl: C, sty: x, lnk: N } = this.#D(!0, y ? M(y) : null);
1221
- a = `<span${C} style='${x} ${r.style}'><ruby><span data-cmd='grp' data-arg='${JSON.stringify(r)}'${N} style='${x} display: inline;'>&emsp;</span><rt${N}${this.#U(
1220
+ a = `<span${C} style='${x} ${r.style}'><ruby><span data-cmd='grp' data-arg='${JSON.stringify(r)}'${N} style='${x} display: inline;'>&emsp;</span><rt${N}${this.#q(
1222
1221
  " ",
1223
1222
  b,
1224
1223
  this.#x,
1225
- this.#y.style.cssText + (this.#j.at(-1)?.o.r_style ?? "") + w
1224
+ this.#y.style.cssText + (this.#T.at(-1)?.o.r_style ?? "") + w
1226
1225
  )}>${r.r}</rt></ruby></span>`;
1227
1226
  }
1228
1227
  break;
@@ -1230,13 +1229,13 @@ class k extends tt {
1230
1229
  this.#M = !1, this.#w = !0;
1231
1230
  {
1232
1231
  const { t: r = "", r: b = "", wait: y = null, style: w = "", r_style: C = "" } = JSON.parse(h);
1233
- k.#n.doRecLog() && (this.#G += t + (s ? `《${s}》` : ""), this.#J += r);
1234
- const x = j.isSafari ? b.replaceAll(/[A-Za-z0-9]/g, (o) => String.fromCharCode(o.charCodeAt(0) + 65248)) : b, { cl: N, sty: g, lnk: $ } = this.#D(!0, y ? M(y) : null);
1235
- a = `<span${N} style='${g}${this.#R(r)} ${w}'><ruby><span${$} style='${g} display: inline; text-combine-upright: all;'>${r}</span><rt${$}${this.#U(
1232
+ k.#n.doRecLog() && (this.#U += t + (s ? `《${s}》` : ""), this.#J += r);
1233
+ const x = T.isSafari ? b.replaceAll(/[A-Za-z0-9]/g, (o) => String.fromCharCode(o.charCodeAt(0) + 65248)) : b, { cl: N, sty: g, lnk: $ } = this.#D(!0, y ? M(y) : null);
1234
+ a = `<span${N} style='${g}${this.#R(r)} ${w}'><ruby><span${$} style='${g} display: inline; text-combine-upright: all;'>${r}</span><rt${$}${this.#q(
1236
1235
  r,
1237
1236
  x,
1238
1237
  this.#x,
1239
- this.#y.style.cssText + (this.#j.at(-1)?.o.r_style ?? "") + C
1238
+ this.#y.style.cssText + (this.#T.at(-1)?.o.r_style ?? "") + C
1240
1239
  )}>${x}</rt></ruby></span>`;
1241
1240
  }
1242
1241
  break;
@@ -1254,12 +1253,12 @@ class k extends tt {
1254
1253
  const r = JSON.parse(h);
1255
1254
  r[":link"] = " data-lnk='@'";
1256
1255
  const { cl: b, sty: y, curpos: w } = this.#D(!1, r.wait ? M(r.wait) : null);
1257
- this.#T.push(`<span${b} style='${y} display: inline; ${r.style ?? ""}' ${w} data-arg='${h}'>`), delete r.style, this.#Q(r);
1256
+ this.#j.push(`<span${b} style='${y} display: inline; ${r.style ?? ""}' ${w} data-arg='${h}'>`), delete r.style, this.#Q(r);
1258
1257
  }
1259
1258
  return;
1260
1259
  // breakではない
1261
1260
  case "endlink":
1262
- this.#w = !0, this.#T.push("</span>"), this.#V();
1261
+ this.#w = !0, this.#j.push("</span>"), this.#V();
1263
1262
  return;
1264
1263
  // breakではない
1265
1264
  default:
@@ -1267,40 +1266,40 @@ class k extends tt {
1267
1266
  }
1268
1267
  break;
1269
1268
  }
1270
- this.#T.push(k.#F(a));
1269
+ this.#j.push(k.#F(a));
1271
1270
  };
1272
1271
  #X(t, e, s) {
1273
1272
  const i = t === " " ? "&nbsp;" : t === " " ? "&emsp;" : t;
1274
- k.#n.doRecLog() && (this.#G += i + (e ? `《${e}》` : ""), t !== " " && (this.#J += t));
1273
+ k.#n.doRecLog() && (this.#U += i + (e ? `《${e}》` : ""), t !== " " && (this.#J += t));
1275
1274
  const { cl: a, sty: n, lnk: l } = this.#D(!0, null, t);
1276
1275
  return e ? `<span${a} style='${n} ${this.#R(t)}'><ruby>${// 文字個別に出現させるため以下にも ${cl} が必要
1277
- Array.from(t).map((h, r) => `<span${a}${l} style='${r > 0 ? this.#D(!0, null, t).sty : n} display: inline;'>${h === " " ? "&nbsp;" : h === " " ? "&emsp;" : h}</span>`).join("")}<rt${l}${this.#U(
1276
+ Array.from(t).map((h, r) => `<span${a}${l} style='${r > 0 ? this.#D(!0, null, t).sty : n} display: inline;'>${h === " " ? "&nbsp;" : h === " " ? "&emsp;" : h}</span>`).join("")}<rt${l}${this.#q(
1278
1277
  t,
1279
1278
  e,
1280
1279
  s,
1281
- this.#y.style.cssText + (this.#j.at(-1)?.o.r_style ?? "")
1280
+ this.#y.style.cssText + (this.#T.at(-1)?.o.r_style ?? "")
1282
1281
  )}>${e}</rt></ruby></span>` : `<span${a} style='${n} ${this.#R(t)}'${l}>${i}</span>`;
1283
1282
  }
1284
1283
  #D(t, e, s = `
1285
1284
  `) {
1286
- const i = this.#P ? e ?? this.#j.at(0)?.o.wait ?? (k.#g ? k.#t[s.at(0) ?? ""] ?? 0 : k.msecChWait) : 0;
1285
+ const i = this.#P ? e ?? this.#T.at(0)?.o.wait ?? (k.#g ? k.#t[s.at(0) ?? ""] ?? 0 : k.msecChWait) : 0;
1287
1286
  k.#k.isSkipping ? this.#I = 0 : t && this.#P && (this.#I += M(i));
1288
1287
  const a = `data-add='{"ch_in_style":"${this.#B}", "ch_out_style":"${this.#W}"}'`;
1289
1288
  return {
1290
1289
  cl: ` class='sn_ch sn_ch_yet sn_ch_in_${this.#B}'`,
1291
1290
  // TxtStage.goTxt()はこれ単位で文字出現させる
1292
- sty: `animation-delay: ${String(this.#I)}ms;${this.#j.at(-1)?.o.style ?? ""}`,
1291
+ sty: `animation-delay: ${String(this.#I)}ms;${this.#T.at(-1)?.o.style ?? ""}`,
1293
1292
  // TxtStage.goTxt()はこれ単位で文字出現させる
1294
- lnk: (this.#j.at(0)?.o[":link"] ?? "") + " " + a,
1293
+ lnk: (this.#T.at(0)?.o[":link"] ?? "") + " " + a,
1295
1294
  curpos: a
1296
1295
  };
1297
1296
  }
1298
1297
  #I = 0;
1299
1298
  #M = !0;
1300
- #T = [];
1301
1299
  #j = [];
1300
+ #T = [];
1302
1301
  #K(t) {
1303
- this.#j.push({
1302
+ this.#T.push({
1304
1303
  o: t,
1305
1304
  r_align: this.#x,
1306
1305
  ch_in_style: this.#B,
@@ -1308,11 +1307,11 @@ class k extends tt {
1308
1307
  }), t.r_align && (this.#x = t.r_align), this.#S(t), this.#$(t);
1309
1308
  }
1310
1309
  #V() {
1311
- const t = this.#j.pop();
1310
+ const t = this.#T.pop();
1312
1311
  t && (this.#x = t.r_align, this.#S({ in_style: t.ch_in_style }), this.#$({ out_style: t.ch_out_style }));
1313
1312
  }
1314
1313
  #Q(t) {
1315
- const e = this.#j.at(-1);
1314
+ const e = this.#T.at(-1);
1316
1315
  if (!e) {
1317
1316
  this.#K(t);
1318
1317
  return;
@@ -1321,12 +1320,12 @@ class k extends tt {
1321
1320
  }
1322
1321
  click = () => !this.ctn.interactiveChildren || !this.ctn.visible ? !1 : this.#s.skipChIn();
1323
1322
  clearText() {
1324
- this.ctn.removeChild(this.#s), this.ctn.addChild(this.#s = this.#s.reNew()), this.#I = 0, this.#M = !0, this.#T = [], this.#G = "", this.#J = "", k.#a.pagebreak();
1323
+ this.ctn.removeChild(this.#s), this.ctn.addChild(this.#s = this.#s.reNew()), this.#I = 0, this.#M = !0, this.#j = [], this.#U = "", this.#J = "", k.#a.pagebreak();
1325
1324
  }
1326
- #G = "";
1325
+ #U = "";
1327
1326
  #J = "";
1328
1327
  get pageText() {
1329
- return this.#G.replace("《&emsp;》", "");
1328
+ return this.#U.replace("《&emsp;》", "");
1330
1329
  }
1331
1330
  get pagePlainText() {
1332
1331
  return this.#J;
@@ -1339,7 +1338,7 @@ class k extends tt {
1339
1338
  }
1340
1339
  addButton = (t) => new Promise((e) => {
1341
1340
  t.key = `btn=[${String(this.#m.children.length)}] ` + this.name_, t[":id_tag"] = t.key.slice(0, -7), F(t, "hint_tate", this.#s.tategaki);
1342
- const s = new ft(t, k.#k, () => e(), () => this.canFocus());
1341
+ const s = new ut(t, k.#k, () => e(), () => this.canFocus());
1343
1342
  s.name = JSON.stringify(t).replaceAll('"', "'"), this.#m.addChild(s);
1344
1343
  });
1345
1344
  canFocus() {
@@ -1355,7 +1354,7 @@ class k extends tt {
1355
1354
  r_cssText: this.#y.style.cssText,
1356
1355
  r_align: this.#x,
1357
1356
  // バック
1358
- b_do: this.#i === void 0 ? void 0 : this.#i instanceof G ? "Sprite" : "Graphics",
1357
+ b_do: this.#i === void 0 ? void 0 : this.#i instanceof U ? "Sprite" : "Graphics",
1359
1358
  b_pic: this.#b,
1360
1359
  b_color: this.#_,
1361
1360
  b_alpha: this.#o,
@@ -1402,7 +1401,7 @@ class k extends tt {
1402
1401
  for (const t of this.#m.children) t.showDesignCast();
1403
1402
  }
1404
1403
  dump() {
1405
- return this.#Y("", "gotxt|"), super.dump() + `, "enabled":"${String(this.enabled)}", ${this.#s.dump()}, "b_pic":"${this.#b}", "b_color":"${String(this.#_)}", "b_alpha":${String(this.#o)}, "b_alpha_isfixed":"${String(this.#f)}", "width":${String(this.#s.getWidth)}, "height":${String(this.#s.getHeight)}, "pixi_obj":[${this.ctn.children.map((t) => `{"class":"${t instanceof G ? "Sprite" : t instanceof B ? "Graphics" : t instanceof P ? "Container" : "?"}", "name":"${t.name}", "alpha":${String(t.alpha)}, "x":${String(t.x)}, "y":${String(t.y)}, "visible":"${String(t.visible)}"}`).join(",")}], "button":[${this.#m.children.map((t) => t.children[0]?.name ?? "{}").join(",")}]`;
1404
+ return this.#Y("", "gotxt|"), super.dump() + `, "enabled":"${String(this.enabled)}", ${this.#s.dump()}, "b_pic":"${this.#b}", "b_color":"${String(this.#_)}", "b_alpha":${String(this.#o)}, "b_alpha_isfixed":"${String(this.#f)}", "width":${String(this.#s.getWidth)}, "height":${String(this.#s.getHeight)}, "pixi_obj":[${this.ctn.children.map((t) => `{"class":"${t instanceof U ? "Sprite" : t instanceof B ? "Graphics" : t instanceof P ? "Container" : "?"}", "name":"${t.name}", "alpha":${String(t.alpha)}, "x":${String(t.x)}, "y":${String(t.y)}, "visible":"${String(t.visible)}"}`).join(",")}], "button":[${this.#m.children.map((t) => t.children[0]?.name ?? "{}").join(",")}]`;
1406
1405
  }
1407
1406
  }
1408
1407
  const Et = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({