@famibee/skynovel 1.65.0 → 2.0.1

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 (176) hide show
  1. package/README.md +3 -3
  2. package/dist/Button.js +131 -163
  3. package/dist/Button.js.map +1 -1
  4. package/dist/CallStack.js +19 -22
  5. package/dist/CallStack.js.map +1 -1
  6. package/dist/CmnInterface.js +91 -0
  7. package/dist/CmnInterface.js.map +1 -0
  8. package/dist/CmnLib.js +94 -0
  9. package/dist/CmnLib.js.map +1 -0
  10. package/dist/Config.js +26 -0
  11. package/dist/Config.js.map +1 -0
  12. package/dist/ConfigBase.js +152 -0
  13. package/dist/ConfigBase.js.map +1 -0
  14. package/dist/DebugMng.js +89 -102
  15. package/dist/DebugMng.js.map +1 -1
  16. package/dist/EventListenerCtn.js +21 -0
  17. package/dist/EventListenerCtn.js.map +1 -0
  18. package/dist/EventMng.js +1435 -1577
  19. package/dist/EventMng.js.map +1 -1
  20. package/dist/Grammar.js +194 -0
  21. package/dist/Grammar.js.map +1 -0
  22. package/dist/GrpLayer.js +163 -195
  23. package/dist/GrpLayer.js.map +1 -1
  24. package/dist/Layer.js +260 -0
  25. package/dist/Layer.js.map +1 -0
  26. package/dist/LayerMng.js +810 -991
  27. package/dist/LayerMng.js.map +1 -1
  28. package/dist/Main.js +144 -393
  29. package/dist/Main.js.map +1 -1
  30. package/dist/PropParser.js +936 -834
  31. package/dist/PropParser.js.map +1 -1
  32. package/dist/Reading.js +917 -786
  33. package/dist/Reading.js.map +1 -1
  34. package/dist/RubySpliter.js +59 -92
  35. package/dist/RubySpliter.js.map +1 -1
  36. package/dist/ScriptIterator.js +805 -1034
  37. package/dist/ScriptIterator.js.map +1 -1
  38. package/dist/SndBuf.js +1097 -1332
  39. package/dist/SndBuf.js.map +1 -1
  40. package/dist/SoundMng.js +124 -135
  41. package/dist/SoundMng.js.map +1 -1
  42. package/dist/SpritesMng.js +220 -232
  43. package/dist/SpritesMng.js.map +1 -1
  44. package/dist/SysBase.js +1729 -0
  45. package/dist/SysBase.js.map +1 -0
  46. package/dist/TxtLayer.js +1212 -1397
  47. package/dist/TxtLayer.js.map +1 -1
  48. package/dist/Variable.js +398 -466
  49. package/dist/Variable.js.map +1 -1
  50. package/dist/chunk.js +18 -0
  51. package/dist/gamepad.js +723 -511
  52. package/dist/gamepad.js.map +1 -1
  53. package/dist/pixi.js +13422 -0
  54. package/dist/pixi.js.map +1 -0
  55. package/dist/platform.js +424 -369
  56. package/dist/platform.js.map +1 -1
  57. package/dist/sn/AnalyzeTagArg.d.ts +1 -1
  58. package/dist/sn/AnalyzeTagArg.d.ts.map +1 -1
  59. package/dist/sn/CmnInterface.d.ts +3 -1
  60. package/dist/sn/CmnInterface.d.ts.map +1 -1
  61. package/dist/sn/CmnLib.d.ts.map +1 -1
  62. package/dist/sn/CmnTween.d.ts +3 -3
  63. package/dist/sn/CmnTween.d.ts.map +1 -1
  64. package/dist/sn/EventMng.d.ts.map +1 -1
  65. package/dist/sn/Grammar.d.ts +1 -1
  66. package/dist/sn/Grammar.d.ts.map +1 -1
  67. package/dist/sn/PropParser.d.ts +2 -2
  68. package/dist/sn/PropParser.d.ts.map +1 -1
  69. package/dist/sn/Reading.d.ts +6 -0
  70. package/dist/sn/Reading.d.ts.map +1 -1
  71. package/dist/sn/ScriptIterator.d.ts.map +1 -1
  72. package/dist/sn/SndBuf.d.ts +27 -16
  73. package/dist/sn/SndBuf.d.ts.map +1 -1
  74. package/dist/sn/SoundMng.d.ts +4 -1
  75. package/dist/sn/SoundMng.d.ts.map +1 -1
  76. package/dist/sn/SysBase.d.ts.map +1 -1
  77. package/dist/sn/TxtStage.d.ts +2 -1
  78. package/dist/sn/TxtStage.d.ts.map +1 -1
  79. package/dist/test/ValTest.d.ts +1 -1
  80. package/dist/test/ValTest.d.ts.map +1 -1
  81. package/dist/web.js +653 -8
  82. package/dist/web.js.map +1 -1
  83. package/dist_app/Button.js +131 -163
  84. package/dist_app/Button.js.map +1 -1
  85. package/dist_app/CallStack.js +19 -22
  86. package/dist_app/CallStack.js.map +1 -1
  87. package/dist_app/CmnInterface.js +91 -0
  88. package/dist_app/CmnInterface.js.map +1 -0
  89. package/dist_app/CmnLib.js +94 -0
  90. package/dist_app/CmnLib.js.map +1 -0
  91. package/dist_app/Config.js +26 -0
  92. package/dist_app/Config.js.map +1 -0
  93. package/dist_app/ConfigBase.js +152 -0
  94. package/dist_app/ConfigBase.js.map +1 -0
  95. package/dist_app/DebugMng.js +92 -0
  96. package/dist_app/DebugMng.js.map +1 -0
  97. package/dist_app/EventListenerCtn.js +21 -0
  98. package/dist_app/EventListenerCtn.js.map +1 -0
  99. package/dist_app/EventMng.js +1435 -1577
  100. package/dist_app/EventMng.js.map +1 -1
  101. package/dist_app/Grammar.js +194 -0
  102. package/dist_app/Grammar.js.map +1 -0
  103. package/dist_app/GrpLayer.js +163 -195
  104. package/dist_app/GrpLayer.js.map +1 -1
  105. package/dist_app/Layer.js +260 -0
  106. package/dist_app/Layer.js.map +1 -0
  107. package/dist_app/LayerMng.js +810 -991
  108. package/dist_app/LayerMng.js.map +1 -1
  109. package/dist_app/Main.js +144 -392
  110. package/dist_app/Main.js.map +1 -1
  111. package/dist_app/PropParser.js +936 -834
  112. package/dist_app/PropParser.js.map +1 -1
  113. package/dist_app/Reading.js +917 -786
  114. package/dist_app/Reading.js.map +1 -1
  115. package/dist_app/RubySpliter.js +59 -92
  116. package/dist_app/RubySpliter.js.map +1 -1
  117. package/dist_app/ScriptIterator.js +805 -1033
  118. package/dist_app/ScriptIterator.js.map +1 -1
  119. package/dist_app/SndBuf.js +1097 -1332
  120. package/dist_app/SndBuf.js.map +1 -1
  121. package/dist_app/SoundMng.js +124 -135
  122. package/dist_app/SoundMng.js.map +1 -1
  123. package/dist_app/SpritesMng.js +220 -231
  124. package/dist_app/SpritesMng.js.map +1 -1
  125. package/dist_app/SysBase.js +1729 -0
  126. package/dist_app/SysBase.js.map +1 -0
  127. package/dist_app/TxtLayer.js +1212 -1396
  128. package/dist_app/TxtLayer.js.map +1 -1
  129. package/dist_app/Variable.js +398 -466
  130. package/dist_app/Variable.js.map +1 -1
  131. package/dist_app/app.js +211 -8
  132. package/dist_app/app.js.map +1 -1
  133. package/dist_app/appMain.js +20 -21
  134. package/dist_app/appMain.js.map +1 -1
  135. package/dist_app/chunk.js +18 -0
  136. package/dist_app/gamepad.js +723 -511
  137. package/dist_app/gamepad.js.map +1 -1
  138. package/dist_app/pixi.js +11181 -0
  139. package/dist_app/pixi.js.map +1 -0
  140. package/dist_app/platform.js +424 -369
  141. package/dist_app/platform.js.map +1 -1
  142. package/dist_app/preload.js +2 -2
  143. package/dist_app/preload.js.map +1 -1
  144. package/dist_app/sn/AnalyzeTagArg.d.ts +1 -1
  145. package/dist_app/sn/AnalyzeTagArg.d.ts.map +1 -1
  146. package/dist_app/sn/CmnInterface.d.ts +3 -1
  147. package/dist_app/sn/CmnInterface.d.ts.map +1 -1
  148. package/dist_app/sn/CmnLib.d.ts.map +1 -1
  149. package/dist_app/sn/CmnTween.d.ts +3 -3
  150. package/dist_app/sn/CmnTween.d.ts.map +1 -1
  151. package/dist_app/sn/EventMng.d.ts.map +1 -1
  152. package/dist_app/sn/Grammar.d.ts +1 -1
  153. package/dist_app/sn/Grammar.d.ts.map +1 -1
  154. package/dist_app/sn/PropParser.d.ts +2 -2
  155. package/dist_app/sn/PropParser.d.ts.map +1 -1
  156. package/dist_app/sn/Reading.d.ts +6 -0
  157. package/dist_app/sn/Reading.d.ts.map +1 -1
  158. package/dist_app/sn/ScriptIterator.d.ts.map +1 -1
  159. package/dist_app/sn/SndBuf.d.ts +27 -16
  160. package/dist_app/sn/SndBuf.d.ts.map +1 -1
  161. package/dist_app/sn/SoundMng.d.ts +4 -1
  162. package/dist_app/sn/SoundMng.d.ts.map +1 -1
  163. package/dist_app/sn/SysBase.d.ts.map +1 -1
  164. package/dist_app/sn/TxtStage.d.ts +2 -1
  165. package/dist_app/sn/TxtStage.d.ts.map +1 -1
  166. package/dist_app/test/ValTest.d.ts +1 -1
  167. package/dist_app/test/ValTest.d.ts.map +1 -1
  168. package/package.json +23 -13
  169. package/dist/CmnTween.js +0 -1005
  170. package/dist/CmnTween.js.map +0 -1
  171. package/dist/web2.js +0 -21644
  172. package/dist/web2.js.map +0 -1
  173. package/dist_app/CmnTween.js +0 -1005
  174. package/dist_app/CmnTween.js.map +0 -1
  175. package/dist_app/app2.js +0 -18547
  176. package/dist_app/app2.js.map +0 -1
package/README.md CHANGED
@@ -45,9 +45,9 @@
45
45
  ## example
46
46
 
47
47
  - [機能ギャラリー 'sample gallery'](https://famibee.github.io/SKYNovel_gallery/)
48
- - [Novelgame(Yoko-gaki) sample project「初音館にて」](https://github.com/famibee/SKYNovel_hatsune)
49
- - [Novelgame(Tate-gaki) sample project「桜の樹の下には」](https://github.com/famibee/SKYNovel_uc)
50
- - [simple sample project](https://github.com/famibee/SKYNovel_sample)
48
+ - [Novelgame(Yoko-gaki) sample project「初音館にて」](https://github.com/famibee/tmp_cjs_hatsune)
49
+ - [Novelgame(Tate-gaki) sample project「桜の樹の下には」](https://github.com/famibee/tmp_cjs_uc)
50
+ - [simple sample project](https://github.com/famibee/tmp_cjs_sample)
51
51
 
52
52
  ---
53
53
  ## api (method)
package/dist/Button.js CHANGED
@@ -1,164 +1,132 @@
1
- import { q as S, l as n, u as f, e as v, O as k, K as m, P as C, z as b, G as g, M as p, y as u } from "./web2.js";
2
- import { S as _ } from "./SpritesMng.js";
3
- class r extends S {
4
- constructor(t, i, h, a) {
5
- if (super(), this.hArg = t, this.evtMng = i, this.resolve = h, this.canFocus = a, this.#t = {
6
- type: "pic",
7
- enabled: v(t, "enabled", !0),
8
- x: this.x = f(t.left ?? 0),
9
- y: this.y = f(t.top ?? 0),
10
- rotation: this.angle = n(t, "rotation", this.angle),
11
- // flash : rotation is in degrees.
12
- // pixijs: rotation is in radians, angle is in degrees.
13
- pivot_x: this.pivot.x = n(t, "pivot_x", this.pivot.x),
14
- pivot_y: this.pivot.y = n(t, "pivot_y", this.pivot.y),
15
- scale_x: this.scale.x = n(t, "scale_x", this.scale.x),
16
- scale_y: this.scale.y = n(t, "scale_y", this.scale.y),
17
- alpha: 1,
18
- text: "",
19
- b_pic: "",
20
- width: 0,
21
- height: 0
22
- }, this.getBtnBounds = () => (this.#e.x = this.#t.x, this.#e.y = this.#t.y, this.#e), this.#t.enabled && i.button(t, this, () => this.normal(), () => this.#s(), () => this.#h()), t.pic) {
23
- this.#t.type = "pic", this.#i = new _(
24
- t.pic,
25
- this,
26
- (e) => {
27
- this.#l(e), this.#e.width = e.width * this.#t.scale_x, this.#e.height = e.height * this.#t.scale_y;
28
- },
29
- (e) => h()
30
- );
31
- return;
32
- }
33
- if (!t.text) throw "textまたはpic属性は必須です";
34
- const o = n(t, "height", 30), c = new k({
35
- align: "center",
36
- dropShadow: !0,
37
- dropShadowAlpha: 0.7,
38
- dropShadowColor: "white",
39
- dropShadowBlur: 7,
40
- dropShadowDistance: 0,
41
- fill: this.#t.enabled ? "black" : "gray",
42
- fontFamily: r.fontFamily,
43
- fontSize: o,
44
- padding: 5
45
- });
46
- if (t.style) try {
47
- const e = JSON.parse(t.style);
48
- for (const [w, y] of Object.entries(e)) c[w] = y;
49
- this.#t = { ...this.#t, ...e };
50
- } catch (e) {
51
- throw e instanceof SyntaxError ? new Error(m(t, "style", e.message)) : "fn:Button.ts style";
52
- }
53
- const s = new C(t.text ?? "", c);
54
- s.alpha = n(t, "alpha", s.alpha), s.width = n(t, "width", 100), s.height = t.height = o, this.setText = (e) => {
55
- s.text = e;
56
- }, this.#t = {
57
- ...this.#t,
58
- type: "text",
59
- // dump用
60
- alpha: s.alpha,
61
- text: s.text,
62
- width: s.width,
63
- height: s.height
64
- };
65
- let d = !1;
66
- if (this.#t.width = this.width, this.#t.height = this.height, t.b_pic && (this.#t.b_pic = t.b_pic, this.#i = new _(
67
- t.b_pic,
68
- this,
69
- (e) => {
70
- this.#o(e, s), this.#t.width = this.width, this.#t.height = this.height;
71
- },
72
- (e) => {
73
- b.setBlendmode(this, t), e && h();
74
- }
75
- ), d = this.#i.ret), this.addChild(s), this.#e.width = s.width, this.#e.height = s.height, t.b_pic || b.setBlendmode(this, t), r.#a(this, s), !this.#t.enabled) {
76
- d || h();
77
- return;
78
- }
79
- const l = c.clone();
80
- if (t.style_hover) try {
81
- const e = JSON.parse(t.style_hover);
82
- for (const [w, y] of Object.entries(e)) l[w] = y;
83
- } catch (e) {
84
- throw e instanceof SyntaxError ? new Error(m(t, "style_hover", e.message)) : "fn:Button.ts style_hover";
85
- }
86
- else l.fill = "white";
87
- const x = l.clone();
88
- if (t.style_clicked) try {
89
- const e = JSON.parse(t.style_clicked);
90
- for (const [w, y] of Object.entries(e)) x[w] = y;
91
- } catch (e) {
92
- throw e instanceof SyntaxError ? new Error(m(t, "style_clicked", e.message)) : "fn:Button.ts style_clicked";
93
- }
94
- else x.dropShadow = !1;
95
- this.normal = () => {
96
- s.style = c;
97
- }, this.#s = () => a() ? (s.style = l, !0) : !1, this.#h = () => {
98
- s.style = x;
99
- }, d || h();
100
- }
101
- static fontFamily = "'Hiragino Sans', 'Hiragino Kaku Gothic ProN', '游ゴシック Medium', meiryo, sans-serif";
102
- static #a = (t, i) => {
103
- };
104
- static #n = (t, i, h, a) => {
105
- };
106
- static init(t) {
107
- t.oCfg.debug.masume && (r.#a = (i, h) => i.addChild(
108
- new g().beginFill(8926088, 0.2).lineStyle(1, 8926088, 1).drawRect(h.x, h.y, h.width, h.height).endFill()
109
- ), r.#n = (i, h, a, o) => i.addChild(
110
- new g().beginFill(8926088, 0.2).lineStyle(1, 8926088, 1).drawRect(h.x, h.y, a, o).endFill()
111
- ));
112
- }
113
- setText(t) {
114
- }
115
- getBtnBounds = () => this.#e;
116
- // 文字ボタンは背景画像を含まない位置指定なので、その当たり判定用
117
- #e = new p();
118
- #i = new _();
119
- // #idc : DesignCast;
120
- #t;
121
- destroy() {
122
- this.normal = () => {
123
- }, this.#s = () => !1, this.#h = () => {
124
- }, this.evtMng.unButton(this), this.#i.destroy(), super.destroy();
125
- }
126
- makeDesignCast(t) {
127
- }
128
- showDesignCast() {
129
- }
130
- // showDesignCast() {this.#idc.visible = true}
131
- cvsResize() {
132
- }
133
- #o(t, i) {
134
- this.setChildIndex(t, 0), t.alpha = i.alpha, t.setTransform(
135
- i.x,
136
- i.y,
137
- 1,
138
- 1,
139
- i.rotation,
140
- 0,
141
- 0,
142
- (t.width - i.width) / 2,
143
- (t.height - i.height) / 2
144
- ), t.name = i.name;
145
- }
146
- normal = () => {
147
- };
148
- #s = () => !1;
149
- #h = () => {
150
- };
151
- #l(t) {
152
- this.#t.alpha = t.alpha = n(this.hArg, "alpha", t.alpha);
153
- const i = t.width / 3, h = this.#t.enabled ? i : t.width, a = t.height, o = t.texture.baseTexture, c = new u(o, new p(0, 0, i, a)), s = new u(o, new p(i, 0, i, a)), d = new u(o, new p(i * 2, 0, i, a)), l = () => {
154
- t.texture = c;
155
- };
156
- this.#t.enabled && l(), this.normal = l, this.#s = () => this.canFocus() ? (t.texture = d, !0) : !1, this.#h = () => {
157
- t.texture = s;
158
- }, "width" in this.hArg ? (this.#t.width = f(this.hArg.width), this.scale.x *= this.#t.width / h) : this.#t.width = h, "height" in this.hArg ? (this.#t.height = f(this.hArg.height), this.scale.y *= this.#t.height / a) : this.#t.height = a, r.#n(this, t, h, a);
159
- }
160
- }
161
- export {
162
- r as Button
1
+ import { g as uint, l as argChk_Num, m as mesErrJSON, s as argChk_Boolean } from "./CmnLib.js";
2
+ import { a as TextStyle, f as Texture, h as Rectangle, i as Text, m as Container, s as Graphics } from "./pixi.js";
3
+ import "./EventListenerCtn.js";
4
+ import "./ConfigBase.js";
5
+ import { t as Layer } from "./Layer.js";
6
+ import "./DebugMng.js";
7
+ import "./Reading.js";
8
+ import { t as SpritesMng } from "./SpritesMng.js";
9
+ var Button = class f extends Container {
10
+ static fontFamily = "'Hiragino Sans', 'Hiragino Kaku Gothic ProN', '游ゴシック Medium', meiryo, sans-serif";
11
+ static #e = (e, t) => {};
12
+ static #t = (e, t, n, r) => {};
13
+ static init(e) {
14
+ e.oCfg.debug.masume && (f.#e = (e, t) => e.addChild(new Graphics().beginFill(8926088, .2).lineStyle(1, 8926088, 1).drawRect(t.x, t.y, t.width, t.height).endFill()), f.#t = (e, t, n, r) => e.addChild(new Graphics().beginFill(8926088, .2).lineStyle(1, 8926088, 1).drawRect(t.x, t.y, n, r).endFill()));
15
+ }
16
+ setText(e) {}
17
+ getBtnBounds = () => this.#n;
18
+ #n = new Rectangle();
19
+ #r = new SpritesMng();
20
+ #i;
21
+ constructor(a, o, c, l) {
22
+ if (super(), this.hArg = a, this.evtMng = o, this.resolve = c, this.canFocus = l, this.#i = {
23
+ type: "pic",
24
+ enabled: argChk_Boolean(a, "enabled", !0),
25
+ x: this.x = uint(a.left ?? 0),
26
+ y: this.y = uint(a.top ?? 0),
27
+ rotation: this.angle = argChk_Num(a, "rotation", this.angle),
28
+ pivot_x: this.pivot.x = argChk_Num(a, "pivot_x", this.pivot.x),
29
+ pivot_y: this.pivot.y = argChk_Num(a, "pivot_y", this.pivot.y),
30
+ scale_x: this.scale.x = argChk_Num(a, "scale_x", this.scale.x),
31
+ scale_y: this.scale.y = argChk_Num(a, "scale_y", this.scale.y),
32
+ alpha: 1,
33
+ text: "",
34
+ b_pic: "",
35
+ width: 0,
36
+ height: 0
37
+ }, this.getBtnBounds = () => (this.#n.x = this.#i.x, this.#n.y = this.#i.y, this.#n), this.#i.enabled && o.button(a, this, () => this.normal(), () => this.#o(), () => this.#s()), a.pic) {
38
+ this.#i.type = "pic", this.#r = new SpritesMng(a.pic, this, (e) => {
39
+ this.#c(e), this.#n.width = e.width * this.#i.scale_x, this.#n.height = e.height * this.#i.scale_y;
40
+ }, (e) => c());
41
+ return;
42
+ }
43
+ if (!a.text) throw "textまたはpic属性は必須です";
44
+ let p = argChk_Num(a, "height", 30), m = new TextStyle({
45
+ align: "center",
46
+ dropShadow: !0,
47
+ dropShadowAlpha: .7,
48
+ dropShadowColor: "white",
49
+ dropShadowBlur: 7,
50
+ dropShadowDistance: 0,
51
+ fill: this.#i.enabled ? "black" : "gray",
52
+ fontFamily: f.fontFamily,
53
+ fontSize: p,
54
+ padding: 5
55
+ });
56
+ if (a.style) try {
57
+ let e = JSON.parse(a.style);
58
+ for (let [t, n] of Object.entries(e)) m[t] = n;
59
+ this.#i = {
60
+ ...this.#i,
61
+ ...e
62
+ };
63
+ } catch (e) {
64
+ throw e instanceof SyntaxError ? Error(mesErrJSON(a, "style", e.message)) : "fn:Button.ts style";
65
+ }
66
+ let h = new Text(a.text ?? "", m);
67
+ h.alpha = argChk_Num(a, "alpha", h.alpha), h.width = argChk_Num(a, "width", 100), h.height = a.height = p, this.setText = (e) => {
68
+ h.text = e;
69
+ }, this.#i = {
70
+ ...this.#i,
71
+ type: "text",
72
+ alpha: h.alpha,
73
+ text: h.text,
74
+ width: h.width,
75
+ height: h.height
76
+ };
77
+ let g = !1;
78
+ if (this.#i.width = this.width, this.#i.height = this.height, a.b_pic && (this.#i.b_pic = a.b_pic, this.#r = new SpritesMng(a.b_pic, this, (e) => {
79
+ this.#a(e, h), this.#i.width = this.width, this.#i.height = this.height;
80
+ }, (e) => {
81
+ Layer.setBlendmode(this, a), e && c();
82
+ }), g = this.#r.ret), this.addChild(h), this.#n.width = h.width, this.#n.height = h.height, a.b_pic || Layer.setBlendmode(this, a), f.#e(this, h), !this.#i.enabled) {
83
+ g || c();
84
+ return;
85
+ }
86
+ let _ = m.clone();
87
+ if (a.style_hover) try {
88
+ let e = JSON.parse(a.style_hover);
89
+ for (let [t, n] of Object.entries(e)) _[t] = n;
90
+ } catch (e) {
91
+ throw e instanceof SyntaxError ? Error(mesErrJSON(a, "style_hover", e.message)) : "fn:Button.ts style_hover";
92
+ }
93
+ else _.fill = "white";
94
+ let v = _.clone();
95
+ if (a.style_clicked) try {
96
+ let e = JSON.parse(a.style_clicked);
97
+ for (let [t, n] of Object.entries(e)) v[t] = n;
98
+ } catch (e) {
99
+ throw e instanceof SyntaxError ? Error(mesErrJSON(a, "style_clicked", e.message)) : "fn:Button.ts style_clicked";
100
+ }
101
+ else v.dropShadow = !1;
102
+ this.normal = () => {
103
+ h.style = m;
104
+ }, this.#o = () => l() ? (h.style = _, !0) : !1, this.#s = () => {
105
+ h.style = v;
106
+ }, g || c();
107
+ }
108
+ destroy() {
109
+ this.normal = () => {}, this.#o = () => !1, this.#s = () => {}, this.evtMng.unButton(this), this.#r.destroy(), super.destroy();
110
+ }
111
+ makeDesignCast(e) {}
112
+ showDesignCast() {}
113
+ cvsResize() {}
114
+ #a(e, t) {
115
+ this.setChildIndex(e, 0), e.alpha = t.alpha, e.setTransform(t.x, t.y, 1, 1, t.rotation, 0, 0, (e.width - t.width) / 2, (e.height - t.height) / 2), e.name = t.name;
116
+ }
117
+ normal = () => {};
118
+ #o = () => !1;
119
+ #s = () => {};
120
+ #c(n) {
121
+ this.#i.alpha = n.alpha = argChk_Num(this.hArg, "alpha", n.alpha);
122
+ let r = n.width / 3, i = this.#i.enabled ? r : n.width, s = n.height, c = n.texture.baseTexture, l = new Texture(c, new Rectangle(0, 0, r, s)), u = new Texture(c, new Rectangle(r, 0, r, s)), d = new Texture(c, new Rectangle(r * 2, 0, r, s)), p = () => {
123
+ n.texture = l;
124
+ };
125
+ this.#i.enabled && p(), this.normal = p, this.#o = () => this.canFocus() ? (n.texture = d, !0) : !1, this.#s = () => {
126
+ n.texture = u;
127
+ }, "width" in this.hArg ? (this.#i.width = uint(this.hArg.width), this.scale.x *= this.#i.width / i) : this.#i.width = i, "height" in this.hArg ? (this.#i.height = uint(this.hArg.height), this.scale.y *= this.#i.height / s) : this.#i.height = s, f.#t(this, n, i, s);
128
+ }
163
129
  };
164
- //# sourceMappingURL=Button.js.map
130
+ export { Button };
131
+
132
+ //# sourceMappingURL=Button.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Button.js","sources":["../src/sn/Button.ts"],"sourcesContent":["/* ***** BEGIN LICENSE BLOCK *****\n\tCopyright (c) 2018-2025 Famibee (famibee.blog38.fc2.com)\n\n\tThis software is released under the MIT License.\n\thttp://opensource.org/licenses/mit-license.php\n** ***** END LICENSE BLOCK ***** */\n\nimport {uint, type IEvtMng, argChk_Boolean, argChk_Num, mesErrJSON} from './CmnLib';\nimport type {TArg} from './Grammar';\nimport {SpritesMng} from './SpritesMng';\nimport {Layer} from './Layer';\nimport type {Config} from './Config';\nimport type {IMakeDesignCast} from './LayerMng';\n//import {DesignCast, TxtBtnDesignCast, PicBtnDesignCast} from './DesignCast';\n\nimport {Container, Text, Rectangle, Texture, TextStyle, type Sprite, Graphics} from 'pixi.js';\n\n\nexport class Button extends Container {\n\tstatic\tfontFamily\t= '\\'Hiragino Sans\\', \\'Hiragino Kaku Gothic ProN\\', \\'游ゴシック Medium\\', meiryo, sans-serif';\n\tstatic\t#procMasume4txt = (_me: Button, _txt: Text)=> { /* empty */ };\n\tstatic\t#procMasume4pic = (_me: Button, _sp: Sprite, _w3: number, _h: number)=> { /* empty */ };\n\tstatic\tinit(cfg: Config) {\n\t\tif (! cfg.oCfg.debug.masume) return;\n\n\t\tButton.#procMasume4txt = (me, txt)=> me.addChild(\n\t\t\t(new Graphics)\n\t\t\t.beginFill(0x883388, 0.2)\n\t\t\t.lineStyle(1, 0x883388, 1)\n\t\t\t.drawRect(txt.x, txt.y, txt.width, txt.height)\n\t\t\t.endFill()\n\t\t);\n\t\tButton.#procMasume4pic = (me, sp, w3, h)=> me.addChild(\n\t\t\t(new Graphics)\n\t\t\t.beginFill(0x883388, 0.2)\n\t\t\t.lineStyle(1, 0x883388, 1)\n\t\t\t.drawRect(sp.x, sp.y, w3, h)\n\t\t\t.endFill()\n\t\t);\n\t}\n\n\tsetText(_text: string) { /* empty */ }\n\tgetBtnBounds = ()=> this.#rctBtnTxt;\n\t\t// 文字ボタンは背景画像を含まない位置指定なので、その当たり判定用\n\t#rctBtnTxt\t= new Rectangle;\n\n\t#sps\t\t= new SpritesMng;\n\n//\t#idc\t\t: DesignCast;\n\treadonly\t#o\t: {\n\t\ttype\t: 'pic'|'text';\n\t\tenabled\t: boolean;\n\t\tx\t\t: number;\n\t\ty\t\t: number;\n\t\trotation: number;\n\t\t\t// flash : rotation is in degrees.\n\t\t\t// pixijs: rotation is in radians, angle is in degrees.\n\t\tpivot_x\t: number;\n\t\tpivot_y\t: number;\n\t\tscale_x\t: number;\n\t\tscale_y\t: number;\n\t\talpha\t: number;\n\t\ttext\t: string;\n\t\tb_pic\t: string;\n\t\twidth\t: number;\n\t\theight\t: number;\n\t};\n\n\tconstructor(private readonly hArg: TArg, readonly evtMng: IEvtMng, readonly resolve: ()=> void, private readonly canFocus: ()=> boolean) {\n\t\tsuper();\n/*\n\t\tif (CmnLib.isDbg) {\n\t\t\tthis.makeDesignCast = gdc=> gdc(this.#idc);\n\t\t\tthis.cvsResize = ()=> this.#idc.cvsResize();\n\t\t}\n*/\n\t\tthis.#o = {\n\t\t\ttype\t: 'pic',\n\t\t\tenabled\t: argChk_Boolean(hArg, 'enabled', true),\n\t\t\tx\t\t: this.x = uint(hArg.left ?? 0),\n\t\t\ty\t\t: this.y = uint(hArg.top ?? 0),\n\t\t\trotation: this.angle = argChk_Num(hArg, 'rotation', this.angle),\n\t\t\t\t// flash : rotation is in degrees.\n\t\t\t\t// pixijs: rotation is in radians, angle is in degrees.\n\t\t\tpivot_x\t: this.pivot.x = argChk_Num(hArg, 'pivot_x', this.pivot.x),\n\t\t\tpivot_y\t: this.pivot.y = argChk_Num(hArg, 'pivot_y', this.pivot.y),\n\t\t\tscale_x\t: this.scale.x = argChk_Num(hArg, 'scale_x', this.scale.x),\n\t\t\tscale_y\t: this.scale.y = argChk_Num(hArg, 'scale_y', this.scale.y),\n\t\t\talpha\t: 1,\n\t\t\ttext\t: '',\n\t\t\tb_pic\t: '',\n\t\t\twidth\t: 0,\n\t\t\theight\t: 0,\n\t\t};\n\t\tthis.getBtnBounds = ()=> {\n\t\t\tthis.#rctBtnTxt.x = this.#o.x;\n\t\t\tthis.#rctBtnTxt.y = this.#o.y;\n\t\t\treturn this.#rctBtnTxt;\n\t\t};\n\n\t\tif (this.#o.enabled) evtMng.button(hArg, this, ()=> this.normal(), ()=> this.#hover(), ()=> this.#clicked());\t// あとで差し替えるのでアロー必須\n\n\t\t// == 画像から生成\n\t\tif (hArg.pic) {\n\t\t\tthis.#o.type = 'pic';\t// dump用\n\t\t\t// this.#idc = new PicBtnDesignCast(this, hArg);\n\n\t\t\tthis.#sps = new SpritesMng(\n\t\t\t\thArg.pic,\n\t\t\t\tthis,\n\t\t\t\tsp=> {\n\t\t\t\t\tthis.#loaded_pic(sp);\n\t\t\t\t\tthis.#rctBtnTxt.width = sp.width * this.#o.scale_x;\n\t\t\t\t\tthis.#rctBtnTxt.height = sp.height * this.#o.scale_y;\n\t\t\t\t},\n\t\t\t\t_isStop=> resolve(),\n\t\t\t);\n\t\t\treturn;\n\t\t}\n\t\tif (! hArg.text) throw 'textまたはpic属性は必須です';\n\n\t\t// == 文字列から生成\n\t\tconst height = argChk_Num(hArg, 'height', 30);\n\t\tconst style = new TextStyle({\n\t\t\talign\t\t: 'center',\n\t\t\tdropShadow\t: true,\n\t\t\tdropShadowAlpha\t: 0.7,\n\t\t\tdropShadowColor\t: 'white',\n\t\t\tdropShadowBlur\t: 7,\n\t\t\tdropShadowDistance\t: 0,\n\t\t\tfill\t\t: this.#o.enabled ?'black' :'gray',\n\t\t\tfontFamily\t: Button.fontFamily,\n\t\t\tfontSize\t: height,\n\t\t\tpadding\t\t: 5,\n\t\t});\n\t\tif (hArg.style) try {\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n\t\t\tconst o = JSON.parse(hArg.style);\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-unsafe-member-access\n\t\t\tfor (const [nm, v] of Object.entries(o)) (<any>style)[nm] = v;\n\t\t//\tstyle = {...style, ...JSON.parse(hArg.style)};\t// 上手くいかない\n\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n\t\t\tthis.#o = {...this.#o, ...o};\n\t\t} catch (e) {\n\t\t\tif (e instanceof SyntaxError) throw new Error(mesErrJSON(hArg, 'style', e.message));\n\t\t\telse throw 'fn:Button.ts style';\n\t\t}\n\n\t\tconst txt = new Text(hArg.text ?? '', style);\n\t\ttxt.alpha = argChk_Num(hArg, 'alpha', txt.alpha);\t// 上にまとめない\n\t\ttxt.width = argChk_Num(hArg, 'width', 100);\n\t\ttxt.height = hArg.height = height;\n\t\tthis.setText = text=> {txt.text = text};\n\n\t\tthis.#o = {...this.#o,\n\t\t\ttype\t: 'text',\t// dump用\n\t\t\talpha\t: txt.alpha,\n\t\t\ttext\t: txt.text,\n\t\t\twidth\t: txt.width,\n\t\t\theight\t: txt.height,\n\t\t};\n//\t\tthis.#idc = new TxtBtnDesignCast(this, hArg, txt);\n\n\t\tlet isStop = false;\n\t\tthis.#o.width = this.width;\n\t\tthis.#o.height = this.height;\n\t\tif (hArg.b_pic) {\n\t\t\tthis.#o.b_pic = hArg.b_pic;\n\t\t\tthis.#sps = new SpritesMng(\n\t\t\t\thArg.b_pic,\n\t\t\t\tthis,\n\t\t\t\tsp=> {\n\t\t\t\t\tthis.#loaded_b_pic(sp, txt);\n\t\t\t\t\tthis.#o.width = this.width;\n\t\t\t\t\tthis.#o.height = this.height;\n\t\t\t\t\t// txt.name = JSON.stringify(this.#o);\n\t\t\t\t\t// DevTools 【メモリ】【重複する文字列】で悪さするので廃止\n\t\t\t\t},\n\t\t\t\tisStop=> {\n\t\t\t\t\tLayer.setBlendmode(this, hArg);\n\t\t\t\t\tif (isStop) resolve();\n\t\t\t\t},\n\t\t\t);\n\t\t\tisStop = this.#sps.ret;\n\t\t}\n\t\t// txt.name = JSON.stringify(this.#o);\n\t\t// DevTools 【メモリ】【重複する文字列】で悪さするので廃止\n\n\t\tthis.addChild(txt);\n\t\tthis.#rctBtnTxt.width = txt.width;\t// addChild()後に取得すること\n\t\tthis.#rctBtnTxt.height = txt.height;\n\t//x\tthis.#rctBtnTxt = txt.getBounds();\t// 上手くいかない\n\n\t\tif (! hArg.b_pic) Layer.setBlendmode(this, hArg);\t// 重なり順でここ\n\t\tButton.#procMasume4txt(this, txt);\n\t\tif (! this.#o.enabled) {if (! isStop) resolve(); return}\n\n\t\tconst style_hover = style.clone();\n\t\tif (hArg.style_hover) try {\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n\t\t\tconst o = JSON.parse(hArg.style_hover);\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-member-access\n\t\t\tfor (const [nm, v] of Object.entries(o)) (<any>style_hover)[nm] = v;\n\t\t} catch (e) {\n\t\t\tif (e instanceof SyntaxError) throw new Error(mesErrJSON(hArg, 'style_hover', e.message));\n\t\t\telse throw 'fn:Button.ts style_hover';\n\t\t}\n\t\telse style_hover.fill = 'white';\n\n\t\tconst style_clicked = style_hover.clone();\n\t\tif (hArg.style_clicked) try {\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n\t\t\tconst o = JSON.parse(hArg.style_clicked);\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-member-access\n\t\t\tfor (const [nm, v] of Object.entries(o)) (<any>style_clicked)[nm] = v;\n\t\t} catch (e) {\n\t\t\tif (e instanceof SyntaxError) throw new Error(mesErrJSON(hArg, 'style_clicked', e.message));\n\t\t\telse throw 'fn:Button.ts style_clicked';\n\t\t}\n\t\telse style_clicked.dropShadow = false;\n\n\t\tthis.normal = ()=> {txt.style = style};\n\t\tthis.#hover = ()=> {\n\t\t\tif (! canFocus()) return false;\n\t\t\ttxt.style = style_hover;\n\t\t\treturn true;\n\t\t};\n\t\tthis.#clicked = ()=> {txt.style = style_clicked};\n\n\t\tif (! isStop) resolve();\n\t}\n\n\toverride\tdestroy(): void {\n\t\tthis.normal\t\t= ()=> { /* empty */ };\n\t\tthis.#hover\t\t= ()=> false;\n\t\tthis.#clicked\t= ()=> { /* empty */ };\n\n\t\tthis.evtMng.unButton(this);\n\t\tthis.#sps.destroy();\n\t\tsuper.destroy();\n\t}\n\n\tmakeDesignCast(_gdc: IMakeDesignCast) { /* empty */ }\n\tshowDesignCast() { /* empty */ }\n//\tshowDesignCast() {this.#idc.visible = true}\n\tcvsResize() { /* empty */ }\n\n\t#loaded_b_pic(sp: Sprite, txt: Text) {\n\t\tthis.setChildIndex(sp, 0);\n\t\tsp.alpha = txt.alpha;\n\t\tsp.setTransform(\n\t\t\ttxt.x, txt.y,\n\t\t\t1, 1, txt.rotation, 0, 0,\n\t\t\t(sp.width -txt.width) /2,\n\t\t\t(sp.height -txt.height) /2,\n\t\t);\n\n\t\tsp.name = txt.name;\n\t}\n\n\tnormal\t\t: ()=> void\t\t= ()=> { /* empty */ };\n\t#hover\t\t: ()=> boolean\t= ()=> false;\n\t#clicked\t: ()=> void\t\t= ()=> { /* empty */ };\n\t#loaded_pic(sp: Sprite) {\n\t\tthis.#o.alpha = sp.alpha = argChk_Num(this.hArg, 'alpha', sp.alpha);\n//\t\t(this.#idc as PicBtnDesignCast).setSp(sp);\n\n\t\tconst w_3 = sp.width /3;\n\t\tconst w = this.#o.enabled ?w_3 :sp.width;\n\t\tconst h = sp.height;\n\t\tconst tx = sp.texture.baseTexture;\n\t\tconst txNormal = new Texture(tx, new Rectangle(0, 0, w_3, h));\n\t\tconst txClicked = new Texture(tx, new Rectangle(w_3, 0, w_3, h));\n\t\tconst txHover = new Texture(tx, new Rectangle(w_3 *2, 0, w_3, h));\n\t\tconst normal = ()=> {sp.texture = txNormal};\n\t\tif (this.#o.enabled) normal();\n\n\t\tthis.normal\t= normal;\n\t\tthis.#hover\t\t= ()=> {\n\t\t\tif (! this.canFocus()) return false;\n\t\t\tsp.texture = txHover;\n\t\t\treturn true;\n\t\t};\n\t\tthis.#clicked\t= ()=> {sp.texture = txClicked};\n\n\t\tif ('width' in this.hArg) {\n\t\t\tthis.#o.width = uint(this.hArg.width);\n\t\t\tthis.scale.x *= this.#o.width /w;\n\t\t}\n\t\telse this.#o.width = w;\n\t\tif ('height' in this.hArg) {\n\t\t\tthis.#o.height = uint(this.hArg.height);\n\t\t\tthis.scale.y *= this.#o.height /h;\n\t\t}\n\t\telse this.#o.height = h;\n\t\t// sp.name = JSON.stringify(this.#o);\t// dump用\n\t\t// DevTools 【メモリ】【重複する文字列】で悪さするので廃止\n\n\t\tButton.#procMasume4pic(this, sp, w, h);\n\t}\n\n}\n"],"names":["Button","Container","hArg","evtMng","resolve","canFocus","#o","argChk_Boolean","uint","argChk_Num","#rctBtnTxt","#hover","#clicked","#sps","SpritesMng","sp","#loaded_pic","height","style","TextStyle","o","nm","v","mesErrJSON","txt","Text","text","isStop","#loaded_b_pic","Layer","#procMasume4txt","style_hover","style_clicked","_me","_txt","#procMasume4pic","_sp","_w3","_h","cfg","me","Graphics","w3","h","_text","Rectangle","_gdc","w_3","w","tx","txNormal","Texture","txClicked","txHover","normal"],"mappings":";;AAkBO,MAAMA,UAAeC,EAAU;AAAA,EAkDrC,YAA6BC,GAAqBC,GAA0BC,GAAqCC,GAAwB;AAmCxI,QAlCA,MAAA,GAD4B,KAAA,OAAAH,GAAqB,KAAA,SAAAC,GAA0B,KAAA,UAAAC,GAAqC,KAAA,WAAAC,GAQhH,KAAKC,KAAK;AAAA,MACT,MAAO;AAAA,MACP,SAAUC,EAAeL,GAAM,WAAW,EAAI;AAAA,MAC9C,GAAK,KAAK,IAAIM,EAAKN,EAAK,QAAQ,CAAC;AAAA,MACjC,GAAK,KAAK,IAAIM,EAAKN,EAAK,OAAO,CAAC;AAAA,MAChC,UAAU,KAAK,QAAQO,EAAWP,GAAM,YAAY,KAAK,KAAK;AAAA;AAAA;AAAA,MAG9D,SAAU,KAAK,MAAM,IAAIO,EAAWP,GAAM,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,KAAKF,GAAG,QAAO0C,KAE3B,KAAK1C,GAAG,QAAQ0C,GACjB,YAAY,KAAK,QACpB,KAAK1C,GAAG,SAASE,EAAK,KAAK,KAAK,MAAM,GACtC,KAAK,MAAM,KAAK,KAAKF,GAAG,SAAQqC,KAE5B,KAAKrC,GAAG,SAASqC,GAItB3C,EAAOmC,GAAgB,MAAMpB,GAAIiC,GAAGL,CAAC;AAAA,EACtC;AAED;"}
1
+ {"version":3,"file":"Button.js","names":["#procMasume4txt","#procMasume4pic","#rctBtnTxt","#o","hArg: TArg","evtMng: IEvtMng","resolve: ()=> void","canFocus: ()=> boolean","#hover","#clicked","#sps","#loaded_pic","#loaded_b_pic"],"sources":["../src/sn/Button.ts"],"sourcesContent":["/* ***** BEGIN LICENSE BLOCK *****\n\tCopyright (c) 2018-2025 Famibee (famibee.blog38.fc2.com)\n\n\tThis software is released under the MIT License.\n\thttp://opensource.org/licenses/mit-license.php\n** ***** END LICENSE BLOCK ***** */\n\nimport {uint, type IEvtMng, argChk_Boolean, argChk_Num, mesErrJSON} from './CmnLib';\nimport type {TArg} from './Grammar';\nimport {SpritesMng} from './SpritesMng';\nimport {Layer} from './Layer';\nimport type {Config} from './Config';\nimport type {IMakeDesignCast} from './LayerMng';\n//import {DesignCast, TxtBtnDesignCast, PicBtnDesignCast} from './DesignCast';\n\nimport {Container, Text, Rectangle, Texture, TextStyle, type Sprite, Graphics} from 'pixi.js';\n\n\nexport class Button extends Container {\n\tstatic\tfontFamily\t= '\\'Hiragino Sans\\', \\'Hiragino Kaku Gothic ProN\\', \\'游ゴシック Medium\\', meiryo, sans-serif';\n\tstatic\t#procMasume4txt = (_me: Button, _txt: Text)=> { /* empty */ };\n\tstatic\t#procMasume4pic = (_me: Button, _sp: Sprite, _w3: number, _h: number)=> { /* empty */ };\n\tstatic\tinit(cfg: Config) {\n\t\tif (! cfg.oCfg.debug.masume) return;\n\n\t\tButton.#procMasume4txt = (me, txt)=> me.addChild(\n\t\t\t(new Graphics)\n\t\t\t.beginFill(0x883388, 0.2)\n\t\t\t.lineStyle(1, 0x883388, 1)\n\t\t\t.drawRect(txt.x, txt.y, txt.width, txt.height)\n\t\t\t.endFill()\n\t\t);\n\t\tButton.#procMasume4pic = (me, sp, w3, h)=> me.addChild(\n\t\t\t(new Graphics)\n\t\t\t.beginFill(0x883388, 0.2)\n\t\t\t.lineStyle(1, 0x883388, 1)\n\t\t\t.drawRect(sp.x, sp.y, w3, h)\n\t\t\t.endFill()\n\t\t);\n\t}\n\n\tsetText(_text: string) { /* empty */ }\n\tgetBtnBounds = ()=> this.#rctBtnTxt;\n\t\t// 文字ボタンは背景画像を含まない位置指定なので、その当たり判定用\n\t#rctBtnTxt\t= new Rectangle;\n\n\t#sps\t\t= new SpritesMng;\n\n//\t#idc\t\t: DesignCast;\n\treadonly\t#o\t: {\n\t\ttype\t: 'pic'|'text';\n\t\tenabled\t: boolean;\n\t\tx\t\t: number;\n\t\ty\t\t: number;\n\t\trotation: number;\n\t\t\t// flash : rotation is in degrees.\n\t\t\t// pixijs: rotation is in radians, angle is in degrees.\n\t\tpivot_x\t: number;\n\t\tpivot_y\t: number;\n\t\tscale_x\t: number;\n\t\tscale_y\t: number;\n\t\talpha\t: number;\n\t\ttext\t: string;\n\t\tb_pic\t: string;\n\t\twidth\t: number;\n\t\theight\t: number;\n\t};\n\n\tconstructor(private readonly hArg: TArg, readonly evtMng: IEvtMng, readonly resolve: ()=> void, private readonly canFocus: ()=> boolean) {\n\t\tsuper();\n/*\n\t\tif (CmnLib.isDbg) {\n\t\t\tthis.makeDesignCast = gdc=> gdc(this.#idc);\n\t\t\tthis.cvsResize = ()=> this.#idc.cvsResize();\n\t\t}\n*/\n\t\tthis.#o = {\n\t\t\ttype\t: 'pic',\n\t\t\tenabled\t: argChk_Boolean(hArg, 'enabled', true),\n\t\t\tx\t\t: this.x = uint(hArg.left ?? 0),\n\t\t\ty\t\t: this.y = uint(hArg.top ?? 0),\n\t\t\trotation: this.angle = argChk_Num(hArg, 'rotation', this.angle),\n\t\t\t\t// flash : rotation is in degrees.\n\t\t\t\t// pixijs: rotation is in radians, angle is in degrees.\n\t\t\tpivot_x\t: this.pivot.x = argChk_Num(hArg, 'pivot_x', this.pivot.x),\n\t\t\tpivot_y\t: this.pivot.y = argChk_Num(hArg, 'pivot_y', this.pivot.y),\n\t\t\tscale_x\t: this.scale.x = argChk_Num(hArg, 'scale_x', this.scale.x),\n\t\t\tscale_y\t: this.scale.y = argChk_Num(hArg, 'scale_y', this.scale.y),\n\t\t\talpha\t: 1,\n\t\t\ttext\t: '',\n\t\t\tb_pic\t: '',\n\t\t\twidth\t: 0,\n\t\t\theight\t: 0,\n\t\t};\n\t\tthis.getBtnBounds = ()=> {\n\t\t\tthis.#rctBtnTxt.x = this.#o.x;\n\t\t\tthis.#rctBtnTxt.y = this.#o.y;\n\t\t\treturn this.#rctBtnTxt;\n\t\t};\n\n\t\tif (this.#o.enabled) evtMng.button(hArg, this, ()=> this.normal(), ()=> this.#hover(), ()=> this.#clicked());\t// あとで差し替えるのでアロー必須\n\n\t\t// == 画像から生成\n\t\tif (hArg.pic) {\n\t\t\tthis.#o.type = 'pic';\t// dump用\n\t\t\t// this.#idc = new PicBtnDesignCast(this, hArg);\n\n\t\t\tthis.#sps = new SpritesMng(\n\t\t\t\thArg.pic,\n\t\t\t\tthis,\n\t\t\t\tsp=> {\n\t\t\t\t\tthis.#loaded_pic(sp);\n\t\t\t\t\tthis.#rctBtnTxt.width = sp.width * this.#o.scale_x;\n\t\t\t\t\tthis.#rctBtnTxt.height = sp.height * this.#o.scale_y;\n\t\t\t\t},\n\t\t\t\t_isStop=> resolve(),\n\t\t\t);\n\t\t\treturn;\n\t\t}\n\t\tif (! hArg.text) throw 'textまたはpic属性は必須です';\n\n\t\t// == 文字列から生成\n\t\tconst height = argChk_Num(hArg, 'height', 30);\n\t\tconst style = new TextStyle({\n\t\t\talign\t\t: 'center',\n\t\t\tdropShadow\t: true,\n\t\t\tdropShadowAlpha\t: 0.7,\n\t\t\tdropShadowColor\t: 'white',\n\t\t\tdropShadowBlur\t: 7,\n\t\t\tdropShadowDistance\t: 0,\n\t\t\tfill\t\t: this.#o.enabled ?'black' :'gray',\n\t\t\tfontFamily\t: Button.fontFamily,\n\t\t\tfontSize\t: height,\n\t\t\tpadding\t\t: 5,\n\t\t});\n\t\tif (hArg.style) try {\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n\t\t\tconst o = JSON.parse(hArg.style);\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-unsafe-member-access\n\t\t\tfor (const [nm, v] of Object.entries(o)) (<any>style)[nm] = v;\n\t\t//\tstyle = {...style, ...JSON.parse(hArg.style)};\t// 上手くいかない\n\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n\t\t\tthis.#o = {...this.#o, ...o};\n\t\t} catch (e) {\n\t\t\tif (e instanceof SyntaxError) throw new Error(mesErrJSON(hArg, 'style', e.message));\n\t\t\telse throw 'fn:Button.ts style';\n\t\t}\n\n\t\tconst txt = new Text(hArg.text ?? '', style);\n\t\ttxt.alpha = argChk_Num(hArg, 'alpha', txt.alpha);\t// 上にまとめない\n\t\ttxt.width = argChk_Num(hArg, 'width', 100);\n\t\ttxt.height = hArg.height = height;\n\t\tthis.setText = text=> {txt.text = text};\n\n\t\tthis.#o = {...this.#o,\n\t\t\ttype\t: 'text',\t// dump用\n\t\t\talpha\t: txt.alpha,\n\t\t\ttext\t: txt.text,\n\t\t\twidth\t: txt.width,\n\t\t\theight\t: txt.height,\n\t\t};\n//\t\tthis.#idc = new TxtBtnDesignCast(this, hArg, txt);\n\n\t\tlet isStop = false;\n\t\tthis.#o.width = this.width;\n\t\tthis.#o.height = this.height;\n\t\tif (hArg.b_pic) {\n\t\t\tthis.#o.b_pic = hArg.b_pic;\n\t\t\tthis.#sps = new SpritesMng(\n\t\t\t\thArg.b_pic,\n\t\t\t\tthis,\n\t\t\t\tsp=> {\n\t\t\t\t\tthis.#loaded_b_pic(sp, txt);\n\t\t\t\t\tthis.#o.width = this.width;\n\t\t\t\t\tthis.#o.height = this.height;\n\t\t\t\t\t// txt.name = JSON.stringify(this.#o);\n\t\t\t\t\t// DevTools 【メモリ】【重複する文字列】で悪さするので廃止\n\t\t\t\t},\n\t\t\t\tisStop=> {\n\t\t\t\t\tLayer.setBlendmode(this, hArg);\n\t\t\t\t\tif (isStop) resolve();\n\t\t\t\t},\n\t\t\t);\n\t\t\tisStop = this.#sps.ret;\n\t\t}\n\t\t// txt.name = JSON.stringify(this.#o);\n\t\t// DevTools 【メモリ】【重複する文字列】で悪さするので廃止\n\n\t\tthis.addChild(txt);\n\t\tthis.#rctBtnTxt.width = txt.width;\t// addChild()後に取得すること\n\t\tthis.#rctBtnTxt.height = txt.height;\n\t//x\tthis.#rctBtnTxt = txt.getBounds();\t// 上手くいかない\n\n\t\tif (! hArg.b_pic) Layer.setBlendmode(this, hArg);\t// 重なり順でここ\n\t\tButton.#procMasume4txt(this, txt);\n\t\tif (! this.#o.enabled) {if (! isStop) resolve(); return}\n\n\t\tconst style_hover = style.clone();\n\t\tif (hArg.style_hover) try {\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n\t\t\tconst o = JSON.parse(hArg.style_hover);\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-member-access\n\t\t\tfor (const [nm, v] of Object.entries(o)) (<any>style_hover)[nm] = v;\n\t\t} catch (e) {\n\t\t\tif (e instanceof SyntaxError) throw new Error(mesErrJSON(hArg, 'style_hover', e.message));\n\t\t\telse throw 'fn:Button.ts style_hover';\n\t\t}\n\t\telse style_hover.fill = 'white';\n\n\t\tconst style_clicked = style_hover.clone();\n\t\tif (hArg.style_clicked) try {\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n\t\t\tconst o = JSON.parse(hArg.style_clicked);\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-member-access\n\t\t\tfor (const [nm, v] of Object.entries(o)) (<any>style_clicked)[nm] = v;\n\t\t} catch (e) {\n\t\t\tif (e instanceof SyntaxError) throw new Error(mesErrJSON(hArg, 'style_clicked', e.message));\n\t\t\telse throw 'fn:Button.ts style_clicked';\n\t\t}\n\t\telse style_clicked.dropShadow = false;\n\n\t\tthis.normal = ()=> {txt.style = style};\n\t\tthis.#hover = ()=> {\n\t\t\tif (! canFocus()) return false;\n\t\t\ttxt.style = style_hover;\n\t\t\treturn true;\n\t\t};\n\t\tthis.#clicked = ()=> {txt.style = style_clicked};\n\n\t\tif (! isStop) resolve();\n\t}\n\n\toverride\tdestroy(): void {\n\t\tthis.normal\t\t= ()=> { /* empty */ };\n\t\tthis.#hover\t\t= ()=> false;\n\t\tthis.#clicked\t= ()=> { /* empty */ };\n\n\t\tthis.evtMng.unButton(this);\n\t\tthis.#sps.destroy();\n\t\tsuper.destroy();\n\t}\n\n\tmakeDesignCast(_gdc: IMakeDesignCast) { /* empty */ }\n\tshowDesignCast() { /* empty */ }\n//\tshowDesignCast() {this.#idc.visible = true}\n\tcvsResize() { /* empty */ }\n\n\t#loaded_b_pic(sp: Sprite, txt: Text) {\n\t\tthis.setChildIndex(sp, 0);\n\t\tsp.alpha = txt.alpha;\n\t\tsp.setTransform(\n\t\t\ttxt.x, txt.y,\n\t\t\t1, 1, txt.rotation, 0, 0,\n\t\t\t(sp.width -txt.width) /2,\n\t\t\t(sp.height -txt.height) /2,\n\t\t);\n\n\t\tsp.name = txt.name;\n\t}\n\n\tnormal\t\t: ()=> void\t\t= ()=> { /* empty */ };\n\t#hover\t\t: ()=> boolean\t= ()=> false;\n\t#clicked\t: ()=> void\t\t= ()=> { /* empty */ };\n\t#loaded_pic(sp: Sprite) {\n\t\tthis.#o.alpha = sp.alpha = argChk_Num(this.hArg, 'alpha', sp.alpha);\n//\t\t(this.#idc as PicBtnDesignCast).setSp(sp);\n\n\t\tconst w_3 = sp.width /3;\n\t\tconst w = this.#o.enabled ?w_3 :sp.width;\n\t\tconst h = sp.height;\n\t\tconst tx = sp.texture.baseTexture;\n\t\tconst txNormal = new Texture(tx, new Rectangle(0, 0, w_3, h));\n\t\tconst txClicked = new Texture(tx, new Rectangle(w_3, 0, w_3, h));\n\t\tconst txHover = new Texture(tx, new Rectangle(w_3 *2, 0, w_3, h));\n\t\tconst normal = ()=> {sp.texture = txNormal};\n\t\tif (this.#o.enabled) normal();\n\n\t\tthis.normal\t= normal;\n\t\tthis.#hover\t\t= ()=> {\n\t\t\tif (! this.canFocus()) return false;\n\t\t\tsp.texture = txHover;\n\t\t\treturn true;\n\t\t};\n\t\tthis.#clicked\t= ()=> {sp.texture = txClicked};\n\n\t\tif ('width' in this.hArg) {\n\t\t\tthis.#o.width = uint(this.hArg.width);\n\t\t\tthis.scale.x *= this.#o.width /w;\n\t\t}\n\t\telse this.#o.width = w;\n\t\tif ('height' in this.hArg) {\n\t\t\tthis.#o.height = uint(this.hArg.height);\n\t\t\tthis.scale.y *= this.#o.height /h;\n\t\t}\n\t\telse this.#o.height = h;\n\t\t// sp.name = JSON.stringify(this.#o);\t// dump用\n\t\t// DevTools 【メモリ】【重複する文字列】で悪さするので廃止\n\n\t\tButton.#procMasume4pic(this, sp, w, h);\n\t}\n\n}\n"],"mappings":";;;;;;;;AAkBA,IAAa,SAAb,MAAa,UAAe,UAAU;CACrC,OAAO,aAAa;CACpB,QAAA,KAA0B,GAAa,MAAc;CACrD,QAAA,KAA0B,GAAa,GAAa,GAAa,MAAc;CAC/E,OAAO,KAAK,GAAa;AAClB,IAAI,KAAK,MAAM,WAErB,GAAA,KAA0B,GAAI,MAAO,EAAG,SACtC,IAAI,UAAQ,CACZ,UAAU,SAAU,GAAI,CACxB,UAAU,GAAG,SAAU,EAAE,CACzB,SAAS,EAAI,GAAG,EAAI,GAAG,EAAI,OAAO,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AAK,MAAM,EACrC,KAAK,MAAM,KAAK,MAAA,EAAQ,QAAO,KAE3B,MAAA,EAAQ,QAAQ,GACjB,YAAY,KAAK,QACpB,MAAA,EAAQ,SAAS,KAAK,KAAK,KAAK,OAAO,EACvC,KAAK,MAAM,KAAK,MAAA,EAAQ,SAAQ,KAE5B,MAAA,EAAQ,SAAS,GAItB,GAAA,EAAuB,MAAM,GAAI,GAAG,EAAE"}
package/dist/CallStack.js CHANGED
@@ -1,25 +1,22 @@
1
- function r() {
2
- return {
3
- "const.sn.macro": "{}",
4
- "const.sn.me_call_scriptFn": ""
5
- };
1
+ function creMP() {
2
+ return {
3
+ "const.sn.macro": "{}",
4
+ "const.sn.me_call_scriptFn": ""
5
+ };
6
6
  }
7
- function c() {
8
- return {
9
- ":hEvt1Time": {},
10
- ":hMp": r(),
11
- ":lenIfStk": 1
12
- };
7
+ function creCSArg() {
8
+ return {
9
+ ":hEvt1Time": {},
10
+ ":hMp": creMP(),
11
+ ":lenIfStk": 1
12
+ };
13
13
  }
14
- class a {
15
- constructor(t = "", s = 0, n = c()) {
16
- this.fn = t, this.idx = s, this.csArg = n;
17
- }
18
- toString = () => `[fn:${this.fn}, idx:${String(this.idx)}, csArg:${JSON.stringify(this.csArg)}]`;
19
- }
20
- export {
21
- a as C,
22
- r as a,
23
- c
14
+ var CallStack = class {
15
+ constructor(e = "", n = 0, r = creCSArg()) {
16
+ this.fn = e, this.idx = n, this.csArg = r;
17
+ }
18
+ toString = () => `[fn:${this.fn}, idx:${String(this.idx)}, csArg:${JSON.stringify(this.csArg)}]`;
24
19
  };
25
- //# sourceMappingURL=CallStack.js.map
20
+ export { creCSArg as n, creMP as r, CallStack as t };
21
+
22
+ //# sourceMappingURL=CallStack.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"CallStack.js","sources":["../src/sn/CallStack.ts"],"sourcesContent":["/* ***** BEGIN LICENSE BLOCK *****\n\tCopyright (c) 2018-2025 Famibee (famibee.blog38.fc2.com)\n\n\tThis software is released under the MIT License.\n\thttp://opensource.org/licenses/mit-license.php\n** ***** END LICENSE BLOCK ***** */\n\nimport type {T_HEvt2Fnc} from './CmnInterface';\nimport type {TArg} from './Grammar';\n\n\n// マクロ変数(mp:)\nexport type T_H_VAL_MP = {\n\t'const.sn.macro'\t\t\t: string;\t// (json)実行中マクロのスクリプター用情報\n\t'const.sn.me_call_scriptFn'\t: string;\t// マクロの呼び元スクリプト\n}\nexport function creMP(): T_H_VAL_MP {return {\n\t\t'const.sn.macro'\t\t\t: '{}',\n\t\t'const.sn.me_call_scriptFn'\t: '',\n}}\n\nexport type ICallStackArg = TArg & {\n\t':resvToken'?\t: string;\t\t// call元のtoken\n\t':hEvt1Time'?\t: T_HEvt2Fnc;\t// call元のローカル予約イベント\n\t':hMp'\t\t\t: T_H_VAL_MP;\t// call元のmp:\n\t':タグ名'?\t\t: string;\n\t':lenIfStk'\t\t: number;\n}\nexport function creCSArg(): ICallStackArg {return {\n\t':hEvt1Time': {},\n\t':hMp'\t\t: creMP(),\n\t':lenIfStk'\t: 1,\n}}\n\n\nexport class CallStack {\n\tconstructor(readonly fn = '', readonly idx = 0, readonly csArg: ICallStackArg = creCSArg()) {}\n\n\treadonly\ttoString = ()=> `[fn:${this.fn}, idx:${String(this.idx)}, csArg:${JSON.stringify(this.csArg)}]`;\n\n}\n"],"names":["creMP","creCSArg","CallStack","fn","idx","csArg"],"mappings":"AAgBO,SAASA,IAAoB;AAAC,SAAO;AAAA,IAC1C,kBAAqB;AAAA,IACrB,6BAA8B;AAAA,EAAA;AAC/B;AASM,SAASC,IAA0B;AAAC,SAAO;AAAA,IACjD,cAAc,CAAA;AAAA,IACd,QAAUD,EAAA;AAAA,IACV,aAAc;AAAA,EAAA;AACd;AAGM,MAAME,EAAU;AAAA,EACtB,YAAqBC,IAAK,IAAaC,IAAM,GAAYC,IAAuBJ,KAAY;AAAvE,SAAA,KAAAE,GAAkB,KAAA,MAAAC,GAAkB,KAAA,QAAAC;AAAA,EAAoC;AAAA,EAEpF,WAAW,MAAK,OAAO,KAAK,EAAE,SAAS,OAAO,KAAK,GAAG,CAAC,WAAW,KAAK,UAAU,KAAK,KAAK,CAAC;AAEtG;"}
1
+ {"version":3,"file":"CallStack.js","names":["csArg: ICallStackArg"],"sources":["../src/sn/CallStack.ts"],"sourcesContent":["/* ***** BEGIN LICENSE BLOCK *****\n\tCopyright (c) 2018-2025 Famibee (famibee.blog38.fc2.com)\n\n\tThis software is released under the MIT License.\n\thttp://opensource.org/licenses/mit-license.php\n** ***** END LICENSE BLOCK ***** */\n\nimport type {T_HEvt2Fnc} from './CmnInterface';\nimport type {TArg} from './Grammar';\n\n\n// マクロ変数(mp:)\nexport type T_H_VAL_MP = {\n\t'const.sn.macro'\t\t\t: string;\t// (json)実行中マクロのスクリプター用情報\n\t'const.sn.me_call_scriptFn'\t: string;\t// マクロの呼び元スクリプト\n}\nexport function creMP(): T_H_VAL_MP {return {\n\t\t'const.sn.macro'\t\t\t: '{}',\n\t\t'const.sn.me_call_scriptFn'\t: '',\n}}\n\nexport type ICallStackArg = TArg & {\n\t':resvToken'?\t: string;\t\t// call元のtoken\n\t':hEvt1Time'?\t: T_HEvt2Fnc;\t// call元のローカル予約イベント\n\t':hMp'\t\t\t: T_H_VAL_MP;\t// call元のmp:\n\t':タグ名'?\t\t: string;\n\t':lenIfStk'\t\t: number;\n}\nexport function creCSArg(): ICallStackArg {return {\n\t':hEvt1Time': {},\n\t':hMp'\t\t: creMP(),\n\t':lenIfStk'\t: 1,\n}}\n\n\nexport class CallStack {\n\tconstructor(readonly fn = '', readonly idx = 0, readonly csArg: ICallStackArg = creCSArg()) {}\n\n\treadonly\ttoString = ()=> `[fn:${this.fn}, idx:${String(this.idx)}, csArg:${JSON.stringify(this.csArg)}]`;\n\n}\n"],"mappings":"AAgBA,SAAgB,QAAoB;AAAC,QAAO;EAC1C,kBAAqB;EACrB,6BAA8B;EAC/B;;AASD,SAAgB,WAA0B;AAAC,QAAO;EACjD,cAAc,EAAE;EAChB,QAAU,OAAO;EACjB,aAAc;EACd;;AAGD,IAAa,YAAb,MAAuB;CACtB,YAAY,IAAc,IAAI,IAAe,GAAG,IAAgC,UAAU,EAAE;AAAnC,EAApC,KAAA,KAAA,GAAkB,KAAA,MAAA,GAAkB,KAAA,QAAA;;CAEzD,iBAAyB,OAAO,KAAK,GAAG,QAAQ,OAAO,KAAK,IAAI,CAAC,UAAU,KAAK,UAAU,KAAK,MAAM,CAAC"}
@@ -0,0 +1,91 @@
1
+ import { t as CmnLib, u as getDateStr } from "./CmnLib.js";
2
+ function creSAVEDATA() {
3
+ return {
4
+ "sn.userFnTail": "",
5
+ "const.sn.autowc.enabled": !1,
6
+ "const.sn.autowc.text": "",
7
+ "const.sn.autowc.time": 0,
8
+ "const.sn.mesLayer": "",
9
+ "const.sn.styPaging": "color: yellow; text-shadow: 1px 1px 0 #000, -1px 1px 0 #000, 1px -1px 0 #000, -1px -1px 0 #000;",
10
+ "sn.doRecLog": !1,
11
+ "const.sn.sLog": "[]",
12
+ "const.sn.loopPlaying": "{}",
13
+ "const.sn.scriptFn": "",
14
+ "const.sn.scriptIdx": 0
15
+ };
16
+ }
17
+ function creSYS_DATA() {
18
+ return {
19
+ "const.sn.cfg.ns": "",
20
+ "const.sn.aPageLog": "[]",
21
+ "const.sn.nativeWindow.x": 0,
22
+ "const.sn.nativeWindow.y": 0,
23
+ "const.sn.nativeWindow.w": CmnLib.stageW,
24
+ "const.sn.nativeWindow.h": CmnLib.stageH,
25
+ "const.sn.save.place": 1,
26
+ "const.sn.sound.BGM.volume": 1,
27
+ "const.sn.sound.SE.volume": 1,
28
+ "const.sn.sound.SYS.volume": 1,
29
+ "sn.auto.msecLineWait": 500,
30
+ "sn.auto.msecLineWait_Kidoku": 500,
31
+ "sn.auto.msecPageWait": 3500,
32
+ "sn.auto.msecPageWait_Kidoku": 3500,
33
+ "sn.skip.mode": "s",
34
+ "sn.sound.BGM.vol_mul_talking": 1,
35
+ "sn.sound.global_volume": (e, i) => 1,
36
+ "sn.sound.movie_volume": (e, i) => 1,
37
+ "sn.tagCh.canskip": !0,
38
+ "sn.tagCh.doWait": !0,
39
+ "sn.tagCh.doWait_Kidoku": !0,
40
+ "sn.tagCh.msecWait": 10,
41
+ "sn.tagCh.msecWait_Kidoku": 10,
42
+ "TextLayer.Back.Alpha": .5
43
+ };
44
+ }
45
+ function creTMP_DATA() {
46
+ return {
47
+ "const.Date.getDateStr": () => getDateStr(),
48
+ "const.Date.getTime": () => (/* @__PURE__ */ new Date()).getTime(),
49
+ "const.sn.bookmark.json": "[]",
50
+ "const.sn.config.window.width": 0,
51
+ "const.sn.config.window.height": 0,
52
+ "const.sn.config.book.title": "",
53
+ "const.sn.config.book.version": "",
54
+ "const.sn.displayState": !1,
55
+ "const.sn.isApp": !1,
56
+ "const.sn.isDbg": !1,
57
+ "const.sn.isPackaged": !1,
58
+ "const.sn.isPaging": !1,
59
+ "const.sn.isDarkMode": !1,
60
+ "const.sn.isDebugger": !0,
61
+ "const.sn.isFirstBoot": !0,
62
+ "const.sn.isKidoku": !0,
63
+ "const.sn.key.alternate": !1,
64
+ "const.sn.key.back": !1,
65
+ "const.sn.key.command": !1,
66
+ "const.sn.key.control": !1,
67
+ "const.sn.key.end": !1,
68
+ "const.sn.key.escape": !1,
69
+ "const.sn.last_page_plain_text": "",
70
+ "const.sn.last_page_text": "",
71
+ "const.sn.Math.PI": Math.PI,
72
+ "const.sn.navigator.language": "jp",
73
+ "const.sn.needClick2Play": !1,
74
+ "const.sn.platform": CmnLib.platform,
75
+ "const.sn.screenResolutionX": screen.availWidth,
76
+ "const.sn.screenResolutionY": screen.availHeight,
77
+ "const.sn.sound.codecs": "",
78
+ "const.sn.aIfStk.length": 1,
79
+ "const.sn.vctCallStk.length": 0,
80
+ "sn.auto.enabled": !1,
81
+ "sn.button.fontFamily": "'Hiragino Sans', 'Hiragino Kaku Gothic ProN', '游ゴシック Medium', meiryo, sans-serif",
82
+ "sn.eventArg": "",
83
+ "sn.eventLabel": "",
84
+ "sn.skip.all": !1,
85
+ "sn.skip.enabled": !1,
86
+ "sn.tagL.enabled": !0
87
+ };
88
+ }
89
+ export { creSYS_DATA as n, creTMP_DATA as r, creSAVEDATA as t };
90
+
91
+ //# sourceMappingURL=CmnInterface.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CmnInterface.js","names":[],"sources":["../src/sn/CmnInterface.ts"],"sourcesContent":["/* ***** BEGIN LICENSE BLOCK *****\n\tCopyright (c) 2018-2025 Famibee (famibee.blog38.fc2.com)\n\n\tThis software is released under the MIT License.\n\thttp://opensource.org/licenses/mit-license.php\n** ***** END LICENSE BLOCK ***** */\n\nimport type {T_HSysBaseArg, T_SEARCHPATH} from './ConfigBase';\nimport type {TArg, TTag} from './Grammar';\nimport type {Areas, T_H_Areas} from './Areas';\nimport type {T_H_VAL_MP} from './CallStack';\nimport type {Layer, T_RecordPlayBack_lay} from './Layer';\nimport {CmnLib, getDateStr} from './CmnLib';\n\nimport type {DisplayObject, RenderTexture} from 'pixi.js';\n\n\n// 特定のプロパティだけrequiredにする型を作ってみる #TypeScript - Qiita https://qiita.com/islandryu/items/490414a537c203b151f7\nexport type T_PRequired<T,K extends keyof T> = T & {\n\t[P in K]-?: T[P]\n}\n\n// =============== PropParser\nexport type T_PropParser = {\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\tparse(s: string): any;\n\tgetValAmpersand(val: string): string;\n}\n\n\n// =============== Plugin\nexport type T_PLUGIN_DECAB_RET = {\n\text_num\t: number;\n\tab\t\t: ArrayBuffer;\n};\nexport type T_PLUGIN_INFO = {\n\twindow: {\n\t\twidth\t: number;\n\t\theight\t: number;\n\t},\n}\nexport type T_PluginInitArg = {\n\tgetInfo(): T_PLUGIN_INFO;\n\taddTag(tag_name: string, tag_fnc: TTag): void;\n\taddLayCls(cls: string, fnc: T_LayerFactory): void;\n\tsearchPath: T_SEARCHPATH;\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\tgetVal(arg_name: string, def?: number | string): any;\n\tresume(fnc?: ()=> void): void;\n\trender(dsp: DisplayObject, renTx?: RenderTexture, clear?: boolean): void;\n\tsetDec(fnc: (ext: string, tx: string)=> Promise<string>): void;\n\tsetDecAB(fnc: (ab: ArrayBuffer)=> Promise<T_PLUGIN_DECAB_RET>): void;\n\tsetEnc(fnc: (tx: string)=> Promise<string>): void;\n\tgetStK(fnc: ()=> string): void;\n\tgetHash(fnc: (str: string)=> string): void;\n}\nexport type T_Plugin = {\n\tinit(pia: T_PluginInitArg): Promise<void>;\n}\nexport type T_HPlugin = {[name: string]: T_Plugin;}\n\nexport type T_LayerFactory = ()=> Layer\n\n\n// =============== SysBase\nexport type T_SysBaseParams = [\n\thPlg\t: T_HPlugin,\n\targ?\t: T_HSysBaseArg,\n];\nexport type T_SysBaseLoadedParams = [\n\thPlg\t: T_HPlugin,\n\targ\t\t: T_HSysBaseArg,\n];\n\n\nexport type SYS_DEC_RET = HTMLImageElement | HTMLVideoElement | ArrayBuffer;\nexport type T_SysBase = {\n\tinitVal(hTmp: T_H_TMP_DATA, comp: (data: T_Data4Vari)=> void): Promise<void>;\n\tflush(): void;\n\n\taddHook(fnc: T_FncHook): void;\n\tcallHook: T_FncHook;\n\tsend2Dbg: T_FncHook;\n\n\tcopyBMFolder(from: number, to: number): void;\n\teraseBMFolder(place: number): void;\n\n\tdestroy(): void;\n}\n\nexport type T_Fire = (KEY: string, e: Event)=> void;\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport type T_FncHook = (type: string, o: any)=> void;\n\n\n// =============== Main\nexport type T_Main = {\n\terrScript(mes: string, isThrow? :boolean): void;\n\tcvs\t\t\t: HTMLCanvasElement;\n\tresume(fnc?: ()=> void): void;\n\tresumeByJumpOrCall(hArg: TArg): void;\n\tstop(): void;\n\tsetLoop(v: boolean, mes?: string): void;\n\tdestroy(): void;\n}\n\n\n// =============== Variable\nexport type T_VAL_BSN = boolean | string | number;\nexport type T_VAL_BSNU = T_VAL_BSN | undefined;\n\n\n// 汎用的に変数\nexport type T_VAL_DATA = T_VAL_BSNU | null;\nexport type T_VAL_DATA_FNC = T_VAL_DATA | (()=> boolean) | (()=> string) | (()=> number)\nexport type T_H_VAL_DATA = {[val_name: string]: T_VAL_DATA_FNC}\n\n// セーブ変数(save:)\nexport type T_H_SAVE_DATA = {\n\t'sn.userFnTail'\t\t: string;\n\n\t'const.sn.autowc.enabled'\t: boolean;\n\t'const.sn.autowc.text'\t\t: string;\n\t'const.sn.autowc.time'\t\t: number;\n\t'const.sn.mesLayer'\t\t: string;\n\t// 'const.sn.sound.【buf】.fn'\t\t: string;\n\t// 'const.sn.sound.【buf】.volume'\t: number;\n\t'const.sn.styPaging'\t: string;\n\t'sn.doRecLog'\t\t\t: boolean;\n\t'const.sn.sLog'\t\t\t: string;\n\t'const.sn.loopPlaying'\t: string;\n\t'const.sn.scriptFn'\t\t: string;\n\t'const.sn.scriptIdx'\t: number;\n\t// 'const.sn.layer.(文字レイヤ名).enabled'\t: boolean;\n\n\t// [val_name: string]: T_VAL_DATA;\n}\nexport function creSAVEDATA(): T_H_SAVE_DATA {return {\n\t'sn.userFnTail'\t\t: '',\n\n\t'const.sn.autowc.enabled': false,// (文字ごとのウェイト)enabled属性で指定した値。\n\t'const.sn.autowc.text'\t: '',\t// (文字ごとのウェイト)同名属性で指定した値。\n\t'const.sn.autowc.time'\t: 0,\t// textとtimeは常に同数にすること\n\t'const.sn.mesLayer'\t: '',\t// デフォルト文字レイヤ\n\t// 'const.sn.sound.【buf】.fn'\t: '',\t// サウンドバッファの再生ファイル名\n\t// 'const.sn.sound.【buf】.volume'\t: 1,// サウンドバッファの目標音量\n\t'const.sn.styPaging'\t: 'color: yellow; text-shadow: 1px 1px 0 #000, -1px 1px 0 #000, 1px -1px 0 #000, -1px -1px 0 #000;',\n\t\t// ページ遷移中 CSS スタイル\n\t'sn.doRecLog'\t\t: false,\t// テキストを履歴に記録するか\n\t'const.sn.sLog'\t: '[]',\t// 履歴テキスト(JSON文字列)\n\t'const.sn.loopPlaying'\t: '{}',\t// ループ中のサウンドバッファ\n\t'const.sn.scriptFn'\t: '',\t// 最後に[record_place]したスクリプト名\n\t'const.sn.scriptIdx'\t: 0,\t// 最後に[record_place]したスクリプトインデックス(行番号ではなく内部トークン単位)\n\t// 'const.sn.layer.(文字レイヤ名).enabled'\t: true,\t// 文字レイヤのenabled値\n}}\n\n\n// システム変数(sys:)\nexport type T_H_SYS_DATA = {\n\t'const.sn.cfg.ns'\t\t\t: string;\t// [import]時のチェック用\n\n\t'const.sn.aPageLog'\t\t\t: string;\t// ページ遷移用情報(JSON文字列)\n\t'const.sn.nativeWindow.x'\t: number;\t// 実数;横座標\n\t'const.sn.nativeWindow.y'\t: number;\t// 実数;縦座標\n\t'const.sn.nativeWindow.w'\t: number;\t// 実数;横幅\n\t'const.sn.nativeWindow.h'\t: number;\t// 実数;縦幅\n\t'const.sn.save.place'\t\t: number;\t// 次のセーブplaceを示す\n\t'const.sn.sound.BGM.volume'\t: number;\t// BGMの基準音量(buf=\"BGM\"の効果音)\n\t'const.sn.sound.SE.volume'\t: number;\t// 効果音の基準音量(buf=\"SE\"の効果音)\n\t'const.sn.sound.SYS.volume'\t: number;\t// システムの基準音量(buf=\"SYS\"の効果音)\n\t// 'const.sn.sound.【buf】.volume'\t: number;\t// システムの基準音量(buf=\"【buf】\"の効果音)\n\t'sn.auto.msecLineWait'\t\t: number;\t// 未読テキストの改行待ち時間(ミリ秒)\n\t'sn.auto.msecLineWait_Kidoku': number;\t// 既読テキストの改行待ち時間(ミリ秒)\n\t'sn.auto.msecPageWait'\t\t: number;\t// 未読テキストの改ページ待ち時間(ミリ秒)\n\t'sn.auto.msecPageWait_Kidoku': number;\t// 既読テキストの改ページ待ち時間(ミリ秒)\n\t'sn.skip.mode'\t\t\t\t: string;\t// スキップモード。\n\t'sn.sound.BGM.vol_mul_talking': number;\t// ボイス(VOICEバッファの音声)再生中のBGM音量への乗数\n\t'sn.sound.global_volume'\t: T_fncSetVal;\t// 全体的な音量を設定する\n\t'sn.sound.movie_volume'\t\t: T_fncSetVal;\t// ムービー音量を設定する\n\t'sn.tagCh.canskip'\t\t\t: boolean;\t// テキストをクリックなどでスキップ可能か\n\t'sn.tagCh.doWait'\t\t\t: boolean;\t// 未読テキストにウェイトを掛けるか\n\t'sn.tagCh.doWait_Kidoku'\t: boolean;\t// 既読テキストにウェイトを掛けるか\n\t'sn.tagCh.msecWait'\t\t\t: number;\t// 未読テキスト待ち時間(ミリ秒)\n\t'sn.tagCh.msecWait_Kidoku'\t: number;\t// 既読テキスト待ち時間(ミリ秒)\n\t'TextLayer.Back.Alpha'\t\t: number;\t// バック不透明度。テキストウインドウの背景の濃\n\n\t// [val_name: string]\t\t: T_VAL_DATA;\n}\nexport function creSYS_DATA(): T_H_SYS_DATA {return {\n\t'const.sn.cfg.ns'\t\t\t: '',\t// [import]時のチェック用\n\n\t'const.sn.aPageLog'\t\t\t: '[]',\t// ページ遷移用情報(JSON文字列)\n\t'const.sn.nativeWindow.x'\t: 0,\t// 実数;横座標\n\t'const.sn.nativeWindow.y'\t: 0,\t// 実数;縦座標\n\t'const.sn.nativeWindow.w'\t: CmnLib.stageW,\t// 実数;横幅\n\t'const.sn.nativeWindow.h'\t: CmnLib.stageH,\t// 実数;縦幅\n\t'const.sn.save.place'\t\t: 1,\t// 次のセーブplaceを示す\n\t'const.sn.sound.BGM.volume'\t: 1,\t// BGMの基準音量(buf=\"BGM\"の効果音)\n\t'const.sn.sound.SE.volume'\t: 1,\t// 効果音の基準音量(buf=\"SE\"の効果音)\n\t'const.sn.sound.SYS.volume'\t: 1,\t// システムの基準音量(buf=\"SYS\"の効果音)\n\t// 'const.sn.sound.【buf】.volume': 1,\t// システムの基準音量(buf=\"【buf】\"の効果音)\n\t'sn.auto.msecLineWait'\t\t: 500,\t// 未読テキストの改行待ち時間(ミリ秒)\n\t'sn.auto.msecLineWait_Kidoku': 500,\t// 既読テキストの改行待ち時間(ミリ秒)\n\t'sn.auto.msecPageWait'\t\t: 3500,\t// 未読テキストの改ページ待ち時間(ミリ秒)\n\t'sn.auto.msecPageWait_Kidoku': 3500,// 既読テキストの改ページ待ち時間(ミリ秒)\n\t'sn.skip.mode'\t\t\t\t: 's',\t// スキップモード。\n\t'sn.sound.BGM.vol_mul_talking': 1.0,// ボイス(VOICEバッファの音声)再生中のBGM音量への乗数\n\t'sn.sound.global_volume'\t: (_, _2)=> 1,\t// 全体的な音量を設定する\n\t'sn.sound.movie_volume'\t\t: (_, _2)=> 1,\t// ムービー音量を設定する\n\t'sn.tagCh.canskip'\t\t\t: true,\t// テキストをクリックなどでスキップ可能か\n\t'sn.tagCh.doWait'\t\t\t: true,\t// 未読テキストにウェイトを掛けるか\n\t'sn.tagCh.doWait_Kidoku'\t: true,\t// 既読テキストにウェイトを掛けるか\n\t'sn.tagCh.msecWait'\t\t\t: 10,\t// 未読テキスト待ち時間(ミリ秒)\n\t'sn.tagCh.msecWait_Kidoku'\t: 10,\t// 既読テキスト待ち時間(ミリ秒)\n\t'TextLayer.Back.Alpha'\t\t: 0.5,\t// バック不透明度。テキストウインドウの背景の濃度。0.0で透明、1.0で不透明\n}}\n\n\n// 雑用変数(tmp:)\nexport type T_H_TMP_DATA = {\n\t'const.Date.getDateStr'\t\t: ()=> string;\n\t'const.Date.getTime'\t\t: ()=> number;\n\t'const.sn.bookmark.json'\t: string;\n\n\t// 'const.sn.config.(略)'\t\t: string;\n\t'const.sn.config.window.width'\t: number;\n\t'const.sn.config.window.height'\t: number;\n\t'const.sn.config.book.title'\t: string;\n\t'const.sn.config.book.version'\t: string;\n\n\t'const.sn.displayState'\t: boolean;\n\t\t\t// const.flash.display.Stage.displayState\n\n\t// 'const.sn.frm.(フレーム名)'\t\t: boolean;\n\t// 'const.sn.frm.(フレーム名).alpha'\t: number;\n\t// 'const.sn.frm.(フレーム名).x'\t\t: number;\n\t// 'const.sn.frm.(フレーム名).y'\t\t: number;\n\t// 'const.sn.frm.(フレーム名).scale_x'\t: number;\n\t// 'const.sn.frm.(フレーム名).scale_y'\t: number;\n\t// 'const.sn.frm.(フレーム名).rotate'\t\t: number;\n\t// 'const.sn.frm.(フレーム名).width'\t\t: number;\n\t// 'const.sn.frm.(フレーム名).height'\t\t: number;\n\t// 'const.sn.frm.(フレーム名).visible'\t: boolean;\n\n\t'const.sn.isApp'\t: boolean;\n\t'const.sn.isDbg'\t: boolean;\n\t'const.sn.isPackaged'\t: boolean;\n\t'const.sn.isPaging'\t\t: boolean;\n\t'const.sn.isDarkMode'\t: boolean;\n\t'const.sn.isDebugger'\t: boolean;\n\t'const.sn.isFirstBoot'\t: boolean;\n\t'const.sn.isKidoku'\t\t: boolean;\n\t'const.sn.key.alternate': boolean;\n\t'const.sn.key.back'\t\t: boolean;\n\t'const.sn.key.command'\t: boolean;\n\t'const.sn.key.control'\t: boolean;\n\t'const.sn.key.end'\t\t: boolean;\n\t'const.sn.key.escape'\t: boolean;\n\t'const.sn.last_page_plain_text'\t: string;\n\t'const.sn.last_page_text'\t\t: string;\n\t// 'const.sn.lay.(レイヤ名)'\t\t\t\t\t\t: boolean;\n\t// 'const.sn.lay.(レイヤ名).(foreかback).alpha'\t: number;\n\t// 'const.sn.lay.(レイヤ名).(foreかback).width'\t: number;\n\t// 'const.sn.lay.(レイヤ名).(foreかback).height'\t: number;\n\t// 'const.sn.lay.(レイヤ名).(foreかback).visible'\t: boolean;\n\t// 'const.sn.lay.(レイヤ名).(foreかback).x'\t\t: number;\n\t// 'const.sn.lay.(レイヤ名).(foreかback).y'\t\t: number;\n\t'const.sn.Math.PI'\t\t: number;\n\t'const.sn.navigator.language'\t: string;\n\t'const.sn.needClick2Play'\t\t: boolean;\n\t'const.sn.platform'\t\t\t\t: string;\n\t'const.sn.screenResolutionX'\t: number;\n\t'const.sn.screenResolutionY'\t: number;\n\t'const.sn.sound.codecs'\t\t\t: string;\n\t// 'const.sn.sound.【buf】.playing': boolean;\n\t'const.sn.aIfStk.length'\t\t: number;\n\t'const.sn.vctCallStk.length'\t: number;\n\t'sn.auto.enabled'\t\t: boolean;\n\t'sn.button.fontFamily'\t: string;\n\t// 'sn.event.domdata.(任意)'\t: string;\n\t'sn.eventArg'\t\t: string;\n\t'sn.eventLabel'\t\t: string;\n\t'sn.skip.all'\t\t: boolean;\n\t'sn.skip.enabled'\t: boolean;\n\t'sn.tagL.enabled'\t: boolean;\n}\nexport function creTMP_DATA(): T_H_TMP_DATA {return {\n\t'const.Date.getDateStr'\t\t: ()=> getDateStr(),\t// 変数参照時の日時を返す\n\t'const.Date.getTime'\t\t: ()=> (new Date).getTime(),\n\t'const.sn.bookmark.json'\t: '[]',\t// SKYNovel内部によるsave:の管理用\n\n\t// 'const.sn.config.(略)'\t: ,\t// prj.jsonの内容を返す\n\t'const.sn.config.window.width'\t: 0,\n\t'const.sn.config.window.height'\t: 0,\n\t'const.sn.config.book.title'\t: '',\n\t'const.sn.config.book.version'\t: '',\n\n\t'const.sn.displayState'\t\t: false,\t// ウインドウ・フルスクリーン状態。trueならフルスクリーン\n\n\t// 'const.sn.frm.(フレーム名)'\t: true,\t// [add_frame]でロードされた id属性が存在するか\n\t// 'const.sn.frm.(フレーム名).alpha'\t: 1,\t// フレームの不透明度\n\t// 'const.sn.frm.(フレーム名).x'\t\t: 0,\t// フレームの座標。画面左上を(0, 0)とする座標。leftやtopでないことに注意\n\t// 'const.sn.frm.(フレーム名).y'\t\t: 0,\t// 実数;縦座標\n\t// 'const.sn.frm.(フレーム名).scale_x': 1,\t// cssでのtransform: scaleの値\n\t// 'const.sn.frm.(フレーム名).scale_y': 1,\t// cssでのtransform: scaleの値\n\t// 'const.sn.frm.(フレーム名).rotate'\t: 0,\t// cssでのrotate、回転角度(単位:deg 度)、正の値は時計回り\n\t// 'const.sn.frm.(フレーム名).width'\t: prjのアプリ横幅画面サイズ,\t// フレームの横幅\n\t// 'const.sn.frm.(フレーム名).height'\t: prjのアプリ縦幅画面サイズ,\t// フレームの縦幅\n\t// 'const.sn.frm.(フレーム名).visible': true,\t// フレームが表示されているか。visible属性の値を返す\n\n\t'const.sn.isApp'\t\t: false,\t// アプリ版か\n\t'const.sn.isDbg'\t\t: false,\t// デバッグモードか\n\t'const.sn.isPackaged'\t: false,\t// パッケージされたアプリか(Electron API - app.isPackaged)\n\t'const.sn.isPaging'\t\t: false,\t// ページ遷移状態か\n\t'const.sn.isDarkMode'\t: false,\t// ダークモードか\n\t'const.sn.isDebugger'\t: true,\t\t// ブラウザ実行、それもVSCode・npmによる「起動:ブラウザ版」上での実行か\n\t'const.sn.isFirstBoot'\t: true,\t\t// ゲームがインストールされてから、初めての起動か(起動されるまでデータが空だったか)\n\t'const.sn.isKidoku'\t\t: true,\t\t// この変数を参照した位置は既読か。参照「後」必ず既読になる点に注意\n\t'const.sn.key.alternate': false,\t// ALTキー(MacならOptionキー)が押されているか\n\t'const.sn.key.back'\t\t: false,\t// back 〃\n\t'const.sn.key.command'\t: false,\t// command 〃\n\t'const.sn.key.control'\t: false,\t// control 〃\n\t'const.sn.key.end'\t\t: false,\t// end 〃\n\t'const.sn.key.escape'\t: false,\t// escape 〃\n\t'const.sn.last_page_plain_text'\t: '',\t// そのページの履歴テキスト(《》文法とルビを含まない)\n\t'const.sn.last_page_text'\t\t: '',\t// そのページの履歴テキスト(《》文法もそのまま)\n\t// 'const.sn.lay.(レイヤ名)'\t\t: true,\t// レイヤが[add_lay]され存在するか\n\t// 'const.sn.lay.(レイヤ名).(foreかback).alpha'\t\t: 0.0〜1.0,\t// レイヤの不透明度\n\t// 'const.sn.lay.(レイヤ名).(foreかback).width'\t\t: 1,\t// レイヤの横幅。ただし文字レイヤの場合は1、画像レイヤの場合、画像読込後でないと0\n\t// 'const.sn.lay.(レイヤ名).(foreかback).height'\t\t: 1,\t// レイヤの縦幅。ただし文字レイヤの場合は1、画像レイヤの場合、画像読込後でないと0\n\t// 'const.sn.lay.(レイヤ名).(foreかback).visible'\t\t: true,\t// レイヤが表示されているか。visible属性の値を返す\n\t// 'const.sn.lay.(レイヤ名).(foreかback).x'\t\t: 0,\t// 実数;横座標</td><td rowspan=\"2\">レイヤの座標。画面左上を(0, 0)とする座標。leftやtopでないことに注意\n\t// 'const.sn.lay.(レイヤ名).(foreかback).y'\t\t: 0,\t// 実数;縦座標\n\t'const.sn.Math.PI'\t\t: Math.PI,\t// 円周率\n\t'const.sn.navigator.language': 'jp',\t// ユーザーが最優先に設定している言語設定\n\t'const.sn.needClick2Play'\t: false,\n\t\t// ブラウザ実行で、クリックされるまで音声再生が差し止められている状態か。なにかクリックされれば falseになる\n\t'const.sn.platform'\t\t\t: CmnLib.platform,\t// 環境による\n\n\t'const.sn.screenResolutionX': screen.availWidth,\t// 画面の最大水平解像度\n\t'const.sn.screenResolutionY': screen.availHeight,\t// 画面の最大垂直解像度\n\t\t// ここでは正確な値は分からない。保存していた前回終了時の位置にウインドウを動かしてから、そのディスプレイののサイズを取得するまでは。\n\n\t'const.sn.sound.codecs'\t\t: '',\t// ゲーム実行環境がどのコーデックをサポートしているか\n\t// 'const.sn.sound.【buf】.playing'\t\t: 再生状態による,\t// サウンドバッファが再生中か<br/>\n\t'const.sn.aIfStk.length'\t: 1,\t// IFスタックの深さ([if]するたびに増)\n\t'const.sn.vctCallStk.length': 0,\t// コールスタックの深さ([call]するたびに増)\n\t'sn.auto.enabled'\t\t: false,\t// 自動読みすすみモードかどうか\n\t'sn.button.fontFamily'\t: '\\'Hiragino Sans\\', \\'Hiragino Kaku Gothic ProN\\', \\'游ゴシック Medium\\', meiryo, sans-serif',\t// 文字ボタンフォントを指定\n\t// 'sn.event.domdata.(任意)'\t\t: ''[event]でフレーム内のHTML要素に登録したイベントで、そのイベント発生時、HTML要素のdata-(任意)属性で指定された値。使い道は開発者が自由に決めていい\n\t'sn.eventArg'\t\t: '',\t// [button]等のイベント発生時、そのボタンタグのarg属性で指定された値。使い道は開発者が自由に決めていい\n\t'sn.eventLabel'\t\t: '',\t// [button]等のイベント発生時、そのボタンタグのlabel属性で指定された値。使い道は開発者が自由に決めていい\n\t'sn.skip.all'\t\t: false,\t// false(初期値)なら既読のみをスキップ\n\t'sn.skip.enabled'\t: false,\t// 次の選択肢(/未読)まで進む が有効か\n\t'sn.tagL.enabled'\t: true,\t\t// 頁末まで一気に読み進むか(l無視)\n}}\n\n\nexport type Scope = 'tmp'|'save'|'sys'|'mp';\n\nexport type T_ProcVal = ()=> T_VAL_BSN;\n\nexport type T_fncSetVal = (arg_name: string, val: T_VAL_BSN, autocast?: boolean)=> void;\n\nexport type T_Variable = {\n\tinit(): Promise<void>;\n\tflush(): void;\n\tsetDoRecProc(doRecProc: (doRec: boolean)=> void): void;\n\n\tgetVal(arg_name: string, def?: number | string, touch?: boolean): T_VAL_DATA;\n\tsetVal_Nochk(scope: Scope, nm: string, val: T_VAL_BSNU, autocast?: boolean): void;\n\n\tdefTmp(name: string, fnc: T_ProcVal): void;\n\tcloneMp(): T_H_VAL_MP;\n\tsetMp(mp: T_H_VAL_MP): void;\n\tsetMark(place: number, mark: T_Mark): void;\n\tgetMark(place: number): T_Mark | undefined;\n\tcloneSave(): T_H_SAVE_DATA;\n\tmark2save(mark: T_Mark): void;\n\n\ttouchAreaKidoku(fn: string): Areas;\n\tgetAreaKidoku(fn: string): Areas | undefined;\n\tsaveKidoku(): void;\n\tupdateData(data: T_Data4Vari): void;\n\n\tdefValTrg(name: string, fnc: T_fncSetVal): void;\n\n\tdoRecLog(): boolean;\n\n\tget tagCh_doWait(): boolean;\n\tget tagCh_doWait_Kidoku(): boolean;\n\tget tagCh_msecWait(): number;\n\tget tagCh_msecWait_Kidoku(): number;\n}\n\nexport type T_H_VAL_MARK\t= {[place: number]: T_Mark};\nexport type T_H_VAL_KIDOKU\t= {[fn: string]: T_H_Areas};\n\n\nexport type T_Data4Vari = {\n\tsys\t\t: T_H_SYS_DATA;\n\tmark\t: T_H_VAL_MARK;\n\tkidoku\t: T_H_VAL_KIDOKU;\n}\n\nexport type T_Mark = {\n\thSave\t: T_H_SAVE_DATA;\n\thPages\t: T_HPage;\n\taIfStk\t: number[];\n\tjson?\t: TArg;\n}\n\n\n// =============== EventMng\nexport type T_Evt2Fnc\t= (e: Event)=> void;\nexport type T_HEvt2Fnc\t= {[name: string]: T_Evt2Fnc;};\n\n\n// =============== FrameMng, LayerMng\nexport type T_GetFrm = {\n\tgetFrmDisabled\t: (id: string)=> boolean;\n};\n\n\n// =============== Pages\nexport type T_HPage = {[name: string]: T_Page};\nexport type T_Page = {\n\tcls\t\t: string;\n\tfore\t: T_RecordPlayBack_lay;\n\tback\t: T_RecordPlayBack_lay;\n}\n\n\n// =============== RubySpliter\nexport type T_PutCh = (ch: string, ruby: string)=> void\n\n\n// =============== Volume change event notification (GrpLayer)\nexport type T_NoticeChgVolume = (vol: number)=> void\n"],"mappings":";AAyIA,SAAgB,cAA6B;AAAC,QAAO;EACpD,iBAAmB;EAEnB,2BAA2B;EAC3B,wBAAyB;EACzB,wBAAyB;EACzB,qBAAsB;EAGtB,sBAAuB;EAEvB,eAAiB;EACjB,iBAAkB;EAClB,wBAAyB;EACzB,qBAAsB;EACtB,sBAAuB;EAEvB;;AAkCD,SAAgB,cAA4B;AAAC,QAAO;EACnD,mBAAsB;EAEtB,qBAAwB;EACxB,2BAA4B;EAC5B,2BAA4B;EAC5B,2BAA4B,OAAO;EACnC,2BAA4B,OAAO;EACnC,uBAAyB;EACzB,6BAA8B;EAC9B,4BAA6B;EAC7B,6BAA8B;EAE9B,wBAA0B;EAC1B,+BAA+B;EAC/B,wBAA0B;EAC1B,+BAA+B;EAC/B,gBAAoB;EACpB,gCAAgC;EAChC,2BAA4B,GAAG,MAAM;EACrC,0BAA4B,GAAG,MAAM;EACrC,oBAAuB;EACvB,mBAAsB;EACtB,0BAA2B;EAC3B,qBAAwB;EACxB,4BAA6B;EAC7B,wBAA0B;EAC1B;;AAuED,SAAgB,cAA4B;AAAC,QAAO;EACnD,+BAAgC,YAAY;EAC5C,6CAA8B,IAAI,MAAI,EAAE,SAAS;EACjD,0BAA2B;EAG3B,gCAAiC;EACjC,iCAA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