speakid-hangman 1.0.8 → 1.0.9
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.
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { jsx as o, jsxs as
|
|
2
|
-
import { useState as
|
|
1
|
+
import { jsx as o, jsxs as m, Fragment as G } from "react/jsx-runtime";
|
|
2
|
+
import { useState as h, useMemo as Q, useCallback as ue, useEffect as me } from "react";
|
|
3
3
|
const a = {
|
|
4
4
|
gmCenterScreen: {
|
|
5
5
|
position: "relative",
|
|
@@ -205,12 +205,12 @@ const a = {
|
|
|
205
205
|
}
|
|
206
206
|
};
|
|
207
207
|
function He({
|
|
208
|
-
mistakes:
|
|
208
|
+
mistakes: r,
|
|
209
209
|
maxMistakes: J,
|
|
210
210
|
size: _ = 200
|
|
211
211
|
}) {
|
|
212
|
-
const c = _, g = _ * 1.25, w = Math.max(3, _ / 100), C = 10 * (c / 200), x = 240 * (g / 250), y = 150 * (c / 200), b = 80 * (c / 200), ee = 20 * (g / 250), N = 240 * (g / 250), M = 80 * (c / 200), P = 20 * (g / 250), L = 150 * (c / 200), H = 150 * (c / 200), v = 20 * (g / 250), I = 50 * (g / 250), F = 150 * (c / 200), R = 70 * (g / 250), V = 20 * (c / 200), T = 150 * (c / 200), te = 90 * (g / 250), A = 150 * (g / 250), f = 150 * (c / 200), B = 110 * (g / 250), p = 130 * (c / 200), O = 130 * (g / 250), ne = 150 * (c / 200), E = 110 * (g / 250),
|
|
213
|
-
return /* @__PURE__ */
|
|
212
|
+
const c = _, g = _ * 1.25, w = Math.max(3, _ / 100), C = 10 * (c / 200), x = 240 * (g / 250), y = 150 * (c / 200), b = 80 * (c / 200), ee = 20 * (g / 250), N = 240 * (g / 250), M = 80 * (c / 200), P = 20 * (g / 250), L = 150 * (c / 200), H = 150 * (c / 200), v = 20 * (g / 250), I = 50 * (g / 250), F = 150 * (c / 200), R = 70 * (g / 250), V = 20 * (c / 200), T = 150 * (c / 200), te = 90 * (g / 250), A = 150 * (g / 250), f = 150 * (c / 200), B = 110 * (g / 250), p = 130 * (c / 200), O = 130 * (g / 250), ne = 150 * (c / 200), E = 110 * (g / 250), he = 170 * (c / 200), z = 130 * (g / 250), oe = 150 * (c / 200), Z = 150 * (g / 250), d = 130 * (c / 200), re = 190 * (g / 250), j = 150 * (c / 200), ie = 150 * (g / 250), u = 170 * (c / 200), ae = 190 * (g / 250), k = r === 0 || r <= J * 0.5 ? "#1f2937" : r <= J * 0.75 ? "#f59e0b" : "#ec4c44";
|
|
213
|
+
return /* @__PURE__ */ m(
|
|
214
214
|
"svg",
|
|
215
215
|
{
|
|
216
216
|
width: c,
|
|
@@ -227,7 +227,7 @@ function He({
|
|
|
227
227
|
// ✅ Включение аппаратного ускорения на iOS
|
|
228
228
|
},
|
|
229
229
|
children: [
|
|
230
|
-
|
|
230
|
+
r > 0 && /* @__PURE__ */ o(
|
|
231
231
|
"line",
|
|
232
232
|
{
|
|
233
233
|
x1: C,
|
|
@@ -238,7 +238,7 @@ function He({
|
|
|
238
238
|
strokeWidth: w
|
|
239
239
|
}
|
|
240
240
|
),
|
|
241
|
-
|
|
241
|
+
r > 1 && /* @__PURE__ */ o(
|
|
242
242
|
"line",
|
|
243
243
|
{
|
|
244
244
|
x1: b,
|
|
@@ -249,7 +249,7 @@ function He({
|
|
|
249
249
|
strokeWidth: w
|
|
250
250
|
}
|
|
251
251
|
),
|
|
252
|
-
|
|
252
|
+
r > 2 && /* @__PURE__ */ o(
|
|
253
253
|
"line",
|
|
254
254
|
{
|
|
255
255
|
x1: M,
|
|
@@ -260,7 +260,7 @@ function He({
|
|
|
260
260
|
strokeWidth: w
|
|
261
261
|
}
|
|
262
262
|
),
|
|
263
|
-
|
|
263
|
+
r > 3 && /* @__PURE__ */ o(
|
|
264
264
|
"line",
|
|
265
265
|
{
|
|
266
266
|
x1: H,
|
|
@@ -271,7 +271,7 @@ function He({
|
|
|
271
271
|
strokeWidth: w
|
|
272
272
|
}
|
|
273
273
|
),
|
|
274
|
-
|
|
274
|
+
r > 4 && /* @__PURE__ */ o(
|
|
275
275
|
"circle",
|
|
276
276
|
{
|
|
277
277
|
cx: F,
|
|
@@ -282,7 +282,7 @@ function He({
|
|
|
282
282
|
strokeWidth: w
|
|
283
283
|
}
|
|
284
284
|
),
|
|
285
|
-
|
|
285
|
+
r > 5 && /* @__PURE__ */ o(
|
|
286
286
|
"line",
|
|
287
287
|
{
|
|
288
288
|
x1: T,
|
|
@@ -293,7 +293,7 @@ function He({
|
|
|
293
293
|
strokeWidth: w
|
|
294
294
|
}
|
|
295
295
|
),
|
|
296
|
-
|
|
296
|
+
r > 6 && /* @__PURE__ */ o(
|
|
297
297
|
"line",
|
|
298
298
|
{
|
|
299
299
|
x1: f,
|
|
@@ -304,18 +304,18 @@ function He({
|
|
|
304
304
|
strokeWidth: w
|
|
305
305
|
}
|
|
306
306
|
),
|
|
307
|
-
|
|
307
|
+
r > 7 && /* @__PURE__ */ o(
|
|
308
308
|
"line",
|
|
309
309
|
{
|
|
310
310
|
x1: ne,
|
|
311
311
|
y1: E,
|
|
312
|
-
x2:
|
|
312
|
+
x2: he,
|
|
313
313
|
y2: z,
|
|
314
314
|
stroke: k,
|
|
315
315
|
strokeWidth: w
|
|
316
316
|
}
|
|
317
317
|
),
|
|
318
|
-
|
|
318
|
+
r > 8 && /* @__PURE__ */ o(
|
|
319
319
|
"line",
|
|
320
320
|
{
|
|
321
321
|
x1: oe,
|
|
@@ -326,7 +326,7 @@ function He({
|
|
|
326
326
|
strokeWidth: w
|
|
327
327
|
}
|
|
328
328
|
),
|
|
329
|
-
|
|
329
|
+
r > 9 && /* @__PURE__ */ o(
|
|
330
330
|
"line",
|
|
331
331
|
{
|
|
332
332
|
x1: j,
|
|
@@ -342,7 +342,7 @@ function He({
|
|
|
342
342
|
);
|
|
343
343
|
}
|
|
344
344
|
function Ye({
|
|
345
|
-
gameCubeSize:
|
|
345
|
+
gameCubeSize: r = 400,
|
|
346
346
|
screenHeight: J = 800,
|
|
347
347
|
screenWidth: _ = 800,
|
|
348
348
|
logoUrl: c,
|
|
@@ -367,10 +367,10 @@ function Ye({
|
|
|
367
367
|
Environment: ["tree", "forest", "air", "water", "pollution", "recycle", "nature", "clean", "waste", "plastic", "energy", "animal", "climate", "earth", "ocean", "river", "planet", "save", "green", "environment", "litter", "organic"],
|
|
368
368
|
Space: ["planet", "star", "sun", "moon", "astronaut", "rocket", "space", "galaxy", "universe", "telescope", "comet", "asteroid", "orbit", "gravity", "alien", "spaceship", "mars", "satellite", "sky", "eclipse"],
|
|
369
369
|
Devices: ["computer", "laptop", "phone", "tablet", "tv", "keyboard", "mouse", "printer", "camera", "headphones", "charger", "screen", "watch", "microphone", "speaker", "console", "router", "battery", "cable", "remote"]
|
|
370
|
-
}, [x, y] =
|
|
371
|
-
const e = (p ||
|
|
370
|
+
}, [x, y] = h("lobby"), [b, ee] = h(""), [N] = h("Normal"), [M, P] = h(0), [L, H] = h(1), [v, I] = h(""), [F, R] = h([]), [V, T] = h(0), [te, A] = h(0), [f, B] = h(null), [p, O] = h(null), [ne, E] = h(1), [he, z] = h([]), oe = N === "Easy" ? 8 : N === "Normal" ? 6 : 4, Z = w || (typeof window < "u" && window.origin ? `${window.origin}/cloud/speakid/games/hangman` : "/cloud/speakid/games/hangman"), [d, re] = h(!1), [j, ie] = h(!1), [u, ae] = h(!1), [$, k] = h(!1), s = Q(() => {
|
|
371
|
+
const e = (p || r || 1e3) / 400, t = u ? 0.8 : 1, i = $ ? 0.9 : 1, l = t * i;
|
|
372
372
|
return {
|
|
373
|
-
headline1: d ? Math.max(24, Math.min(30, 30 * e * l)) : Math.max(28, Math.min(32, 32 * e *
|
|
373
|
+
headline1: d ? Math.max(24, Math.min(30, 30 * e * l)) : Math.max(28, Math.min(32, 32 * e * i)),
|
|
374
374
|
// Desktop: 32px
|
|
375
375
|
headline2: Math.max(20, Math.min(28, 24 * e * l)),
|
|
376
376
|
// Desktop: 24px
|
|
@@ -387,25 +387,25 @@ function Ye({
|
|
|
387
387
|
button: Math.max(12, Math.min(18, 16 * e * l))
|
|
388
388
|
// Desktop: 16px
|
|
389
389
|
};
|
|
390
|
-
}, [d, p,
|
|
391
|
-
const e = (p ||
|
|
392
|
-
return j ? Math.max(8, Math.min(12, 10 * e)) : Math.max(12, Math.min(24, 16 * e)) * t *
|
|
393
|
-
}, [j, p,
|
|
394
|
-
const e = (p ||
|
|
395
|
-
return j ? Math.max(3, Math.min(6, 5 * e)) : Math.max(4, Math.min(12, 8 * e)) * t *
|
|
396
|
-
}, [j, p,
|
|
397
|
-
const e = (p ||
|
|
390
|
+
}, [d, p, r, u, $]), fe = Q(() => {
|
|
391
|
+
const e = (p || r || 1e3) / 400, t = u ? 0.65 : 1, i = $ ? 0.85 : 1;
|
|
392
|
+
return j ? Math.max(8, Math.min(12, 10 * e)) : Math.max(12, Math.min(24, 16 * e)) * t * i;
|
|
393
|
+
}, [j, p, r, u, $]), n = Q(() => {
|
|
394
|
+
const e = (p || r || 1e3) / 400, t = u ? 0.65 : 1, i = $ ? 0.85 : 1;
|
|
395
|
+
return j ? Math.max(3, Math.min(6, 5 * e)) : Math.max(4, Math.min(12, 8 * e)) * t * i;
|
|
396
|
+
}, [j, p, r, u, $]), S = Q(() => {
|
|
397
|
+
const e = (p || r || 1e3) / 400, t = $ ? 0.9 : 1;
|
|
398
398
|
return Math.max(6, Math.min(10, 8 * e * t));
|
|
399
|
-
}, [p,
|
|
399
|
+
}, [p, r, $]), we = (e, t) => e.split("").every((i) => t.includes(i)), ke = (e, t) => e.split("").map((i) => t.includes(i) ? i : "_").join(" "), Me = (e) => "abcdefghijklmnopqrstuvwxyz".split("").filter((i) => !e.includes(i)), U = (e, t = []) => {
|
|
400
400
|
var q;
|
|
401
401
|
if (!e || !C[e]) {
|
|
402
402
|
const W = Object.keys(C)[0];
|
|
403
403
|
return ((q = C[W]) == null ? void 0 : q[0]) || "";
|
|
404
404
|
}
|
|
405
|
-
const
|
|
406
|
-
if (!
|
|
405
|
+
const i = C[e];
|
|
406
|
+
if (!i || i.length === 0)
|
|
407
407
|
return "";
|
|
408
|
-
const l =
|
|
408
|
+
const l = i.filter((W) => !t.includes(W)), Y = l.length > 0 ? l : i;
|
|
409
409
|
if (Y.length === 0)
|
|
410
410
|
return "";
|
|
411
411
|
let D;
|
|
@@ -429,11 +429,11 @@ function Ye({
|
|
|
429
429
|
}, se = ue((e) => {
|
|
430
430
|
if (x !== "game" || f !== null) return;
|
|
431
431
|
const t = e.toLowerCase();
|
|
432
|
-
/^[a-z]$/.test(t) && (R((
|
|
432
|
+
/^[a-z]$/.test(t) && (R((i) => i.includes(t) ? i : [...i, t]), I((i) => (i && !i.includes(t) && T((l) => l + 1), i)));
|
|
433
433
|
}, [x, f]), le = ue((e) => {
|
|
434
434
|
se(e.key);
|
|
435
435
|
}, [se]);
|
|
436
|
-
|
|
436
|
+
me(() => {
|
|
437
437
|
if (x === "game")
|
|
438
438
|
return window.addEventListener("keydown", le), () => window.removeEventListener("keydown", le);
|
|
439
439
|
}, [x, le]);
|
|
@@ -447,7 +447,7 @@ function Ye({
|
|
|
447
447
|
return t ? (I(t), [...e, t]) : e;
|
|
448
448
|
}), R([]), T(0), B(null);
|
|
449
449
|
}, [b, L, M]);
|
|
450
|
-
|
|
450
|
+
me(() => {
|
|
451
451
|
if (xe && f === null) {
|
|
452
452
|
B("win"), A((t) => t + 1);
|
|
453
453
|
const e = setTimeout(() => {
|
|
@@ -473,23 +473,23 @@ function Ye({
|
|
|
473
473
|
return t ? (I(t), [...e, t]) : e;
|
|
474
474
|
}), R([]), T(0), B(null);
|
|
475
475
|
};
|
|
476
|
-
|
|
476
|
+
me(() => {
|
|
477
477
|
const e = () => {
|
|
478
|
-
const t = window.innerWidth,
|
|
478
|
+
const t = window.innerWidth, i = window.innerHeight, l = t < 768 || t === 926 && i === 428 || t === 932 && i === 430, Y = i < 700, D = t / i > 1.8, q = t === 1024 && i === 600, W = l && t > i, ge = t >= 1200 && t <= 1400;
|
|
479
479
|
if (re(l), ie(q), ae(W), k(ge), l)
|
|
480
480
|
O(null), E(1);
|
|
481
481
|
else if (Y)
|
|
482
482
|
O(null), E(1);
|
|
483
483
|
else {
|
|
484
|
-
const ze = t - 80, We =
|
|
484
|
+
const ze = t - 80, We = i - 80, be = Math.min(ze, We);
|
|
485
485
|
let pe;
|
|
486
|
-
|
|
486
|
+
r && r >= 320 ? pe = Math.min(r, be) : pe = Math.min(1e3, be * 0.9);
|
|
487
487
|
const Ce = Math.max(400, Math.min(1200, pe));
|
|
488
488
|
O(Ce), E(D ? 0.85 : 1);
|
|
489
489
|
}
|
|
490
490
|
};
|
|
491
491
|
return e(), window.addEventListener("resize", e), () => window.removeEventListener("resize", e);
|
|
492
|
-
}, [
|
|
492
|
+
}, [r]);
|
|
493
493
|
const K = `
|
|
494
494
|
<svg width="100%" height="100%" xmlns="http://www.w3.org/2000/svg" style="position: absolute; top: 0; left: 0; pointer-events: none; opacity: 0.2;">
|
|
495
495
|
<!-- Каракули мелками и фломастерами -->
|
|
@@ -548,22 +548,24 @@ function Ye({
|
|
|
548
548
|
background: "transparent"
|
|
549
549
|
}, X = Q(
|
|
550
550
|
() => {
|
|
551
|
-
|
|
552
|
-
if (d && e > t || t < 700 || !de)
|
|
551
|
+
if (!de)
|
|
553
552
|
return null;
|
|
554
|
-
const
|
|
555
|
-
|
|
553
|
+
const e = window.innerWidth;
|
|
554
|
+
if (d && e > window.innerHeight)
|
|
555
|
+
return null;
|
|
556
|
+
const t = c || (typeof window < "u" && window.origin ? `${window.origin}/cloud/speakid/games/hangman/logo` : "/cloud/speakid/games/hangman/logo");
|
|
557
|
+
return /* @__PURE__ */ o("div", { style: a.gmLogoFixed, children: /* @__PURE__ */ m("picture", { children: [
|
|
556
558
|
/* @__PURE__ */ o(
|
|
557
559
|
"source",
|
|
558
560
|
{
|
|
559
|
-
srcSet: `${
|
|
561
|
+
srcSet: `${t}.svg`,
|
|
560
562
|
type: "image/svg+xml"
|
|
561
563
|
}
|
|
562
564
|
),
|
|
563
565
|
/* @__PURE__ */ o(
|
|
564
566
|
"img",
|
|
565
567
|
{
|
|
566
|
-
src: `${
|
|
568
|
+
src: `${t}.png`,
|
|
567
569
|
alt: "SPEAKID Logo",
|
|
568
570
|
style: a.gmLogoImg,
|
|
569
571
|
loading: "lazy"
|
|
@@ -572,7 +574,7 @@ function Ye({
|
|
|
572
574
|
] }) });
|
|
573
575
|
},
|
|
574
576
|
[d, de, c, x]
|
|
575
|
-
), Be = () => x === "lobby" ? /* @__PURE__ */
|
|
577
|
+
), Be = () => x === "lobby" ? /* @__PURE__ */ m(G, { children: [
|
|
576
578
|
X,
|
|
577
579
|
/* @__PURE__ */ o("div", { dangerouslySetInnerHTML: { __html: K } }),
|
|
578
580
|
/* @__PURE__ */ o("h1", { style: {
|
|
@@ -582,7 +584,7 @@ function Ye({
|
|
|
582
584
|
position: "relative",
|
|
583
585
|
zIndex: 1
|
|
584
586
|
}, children: "HANGMAN" }),
|
|
585
|
-
/* @__PURE__ */
|
|
587
|
+
/* @__PURE__ */ m(
|
|
586
588
|
"button",
|
|
587
589
|
{
|
|
588
590
|
onClick: () => y("category"),
|
|
@@ -639,7 +641,7 @@ function Ye({
|
|
|
639
641
|
]
|
|
640
642
|
}
|
|
641
643
|
),
|
|
642
|
-
/* @__PURE__ */
|
|
644
|
+
/* @__PURE__ */ m("div", { style: {
|
|
643
645
|
position: "absolute",
|
|
644
646
|
top: "50%",
|
|
645
647
|
left: "50%",
|
|
@@ -659,7 +661,7 @@ function Ye({
|
|
|
659
661
|
left: d ? "-10%" : "5%",
|
|
660
662
|
top: "20%",
|
|
661
663
|
width: "auto",
|
|
662
|
-
height: d ? `${Math.min(window.innerHeight * 0.33, 200)}px` : `${Math.min((p ||
|
|
664
|
+
height: d ? `${Math.min(window.innerHeight * 0.33, 200)}px` : `${Math.min((p || r || 1e3) * 0.33, 300)}px`,
|
|
663
665
|
maxHeight: "33vh",
|
|
664
666
|
objectFit: "contain",
|
|
665
667
|
opacity: 0.6
|
|
@@ -676,7 +678,7 @@ function Ye({
|
|
|
676
678
|
right: d ? "5%" : "10%",
|
|
677
679
|
bottom: "10%",
|
|
678
680
|
width: "auto",
|
|
679
|
-
height: d ? `${Math.min(window.innerHeight * 0.33, 200)}px` : `${Math.min((p ||
|
|
681
|
+
height: d ? `${Math.min(window.innerHeight * 0.33, 200)}px` : `${Math.min((p || r || 1e3) * 0.33, 300)}px`,
|
|
680
682
|
maxHeight: "33vh",
|
|
681
683
|
objectFit: "contain",
|
|
682
684
|
opacity: 0.6
|
|
@@ -684,7 +686,7 @@ function Ye({
|
|
|
684
686
|
}
|
|
685
687
|
)
|
|
686
688
|
] })
|
|
687
|
-
] }) : x === "category" ? /* @__PURE__ */
|
|
689
|
+
] }) : x === "category" ? /* @__PURE__ */ m(G, { children: [
|
|
688
690
|
X,
|
|
689
691
|
/* @__PURE__ */ o("div", { dangerouslySetInnerHTML: { __html: K } }),
|
|
690
692
|
/* @__PURE__ */ o(
|
|
@@ -744,7 +746,7 @@ function Ye({
|
|
|
744
746
|
},
|
|
745
747
|
e
|
|
746
748
|
)) })
|
|
747
|
-
] }) : x === "rounds" ? /* @__PURE__ */
|
|
749
|
+
] }) : x === "rounds" ? /* @__PURE__ */ m(G, { children: [
|
|
748
750
|
X,
|
|
749
751
|
/* @__PURE__ */ o("div", { dangerouslySetInnerHTML: { __html: K } }),
|
|
750
752
|
/* @__PURE__ */ o(
|
|
@@ -805,30 +807,30 @@ function Ye({
|
|
|
805
807
|
},
|
|
806
808
|
e
|
|
807
809
|
)) })
|
|
808
|
-
] }) : x === "game" ? /* @__PURE__ */
|
|
810
|
+
] }) : x === "game" ? /* @__PURE__ */ m(G, { children: [
|
|
809
811
|
X,
|
|
810
812
|
!u && /* @__PURE__ */ o("div", { dangerouslySetInnerHTML: { __html: K } }),
|
|
811
813
|
" ",
|
|
812
|
-
/* @__PURE__ */
|
|
814
|
+
/* @__PURE__ */ m("div", { style: {
|
|
813
815
|
...a.gmInfoBox,
|
|
814
816
|
padding: `${u ? n * 0.6 : n * 0.8}px`,
|
|
815
817
|
// ✅ Уменьшаем padding в landscape
|
|
816
818
|
marginBottom: `${u ? n * 0.3 : n * 0.5}px`,
|
|
817
819
|
// ✅ Уменьшаем margin в landscape
|
|
818
|
-
maxWidth: `${(p ||
|
|
820
|
+
maxWidth: `${(p || r) * 0.9}px`
|
|
819
821
|
}, children: [
|
|
820
|
-
/* @__PURE__ */
|
|
822
|
+
/* @__PURE__ */ m("h3", { style: { ...a.gmHeadline3, fontSize: `${s.headline3}px`, marginBottom: `${n * 0.5}px` }, children: [
|
|
821
823
|
"Category: ",
|
|
822
824
|
b
|
|
823
825
|
] }),
|
|
824
|
-
/* @__PURE__ */
|
|
826
|
+
/* @__PURE__ */ m("p", { style: { ...a.gmBodyM, fontSize: `${s.bodyM}px`, marginBottom: "0px" }, children: [
|
|
825
827
|
"Round ",
|
|
826
828
|
L,
|
|
827
829
|
" of ",
|
|
828
830
|
M
|
|
829
831
|
] })
|
|
830
832
|
] }),
|
|
831
|
-
v && /* @__PURE__ */
|
|
833
|
+
v && /* @__PURE__ */ m("p", { style: {
|
|
832
834
|
...a.gmBodyS,
|
|
833
835
|
fontSize: `${s.bodyS}px`,
|
|
834
836
|
marginTop: `${u ? n * 0.3 : n * 0.5}px`,
|
|
@@ -851,7 +853,7 @@ function Ye({
|
|
|
851
853
|
{
|
|
852
854
|
mistakes: V,
|
|
853
855
|
maxMistakes: oe,
|
|
854
|
-
size: j ? Math.max(80, Math.min(110, (p ||
|
|
856
|
+
size: j ? Math.max(80, Math.min(110, (p || r) * 0.16)) : d ? u ? Math.max(70, Math.min(120, Math.min(window.innerWidth * 0.25, window.innerHeight * 0.15))) : Math.max(100, Math.min(150, Math.min(window.innerWidth * 0.3, window.innerHeight * 0.2))) : Math.max(100, Math.min(150, (p || r) * 0.2))
|
|
855
857
|
}
|
|
856
858
|
) }),
|
|
857
859
|
/* @__PURE__ */ o("div", { style: {
|
|
@@ -862,7 +864,7 @@ function Ye({
|
|
|
862
864
|
letterSpacing: `${n * 0.8}px`,
|
|
863
865
|
minHeight: `${Math.max(16, Math.min(24, s.wordDisplay * 0.9)) * 1.2}px`
|
|
864
866
|
}, children: Se || "Loading..." }),
|
|
865
|
-
/* @__PURE__ */
|
|
867
|
+
/* @__PURE__ */ m("div", { style: {
|
|
866
868
|
...a.gmInfoBox,
|
|
867
869
|
padding: `${u ? n * 0.6 : n}px`,
|
|
868
870
|
// ✅ Уменьшаем padding в landscape
|
|
@@ -870,7 +872,7 @@ function Ye({
|
|
|
870
872
|
// ✅ Уменьшаем margin в landscape
|
|
871
873
|
marginBottom: `${u ? n * 0.5 : n}px`,
|
|
872
874
|
// ✅ Уменьшаем margin в landscape
|
|
873
|
-
maxWidth: `${(p ||
|
|
875
|
+
maxWidth: `${(p || r) * 0.95}px`
|
|
874
876
|
}, children: [
|
|
875
877
|
/* @__PURE__ */ o("p", { style: {
|
|
876
878
|
...a.gmBodyS,
|
|
@@ -903,7 +905,7 @@ function Ye({
|
|
|
903
905
|
background: "#f9f9f9",
|
|
904
906
|
color: "#1f2937",
|
|
905
907
|
border: "1px solid #e5e7eb",
|
|
906
|
-
minWidth: `${Math.max(n * 1.5, (p ||
|
|
908
|
+
minWidth: `${Math.max(n * 1.5, (p || r) * 0.04)}px`,
|
|
907
909
|
textAlign: "center",
|
|
908
910
|
display: "inline-block",
|
|
909
911
|
cursor: f === null ? "pointer" : "default",
|
|
@@ -921,7 +923,7 @@ function Ye({
|
|
|
921
923
|
fontSize: `${Math.max(10, Math.min(12, s.bodyS * 0.85))}px`,
|
|
922
924
|
marginTop: `${n * 0.5}px`,
|
|
923
925
|
marginBottom: "2px"
|
|
924
|
-
}, children: /* @__PURE__ */
|
|
926
|
+
}, children: /* @__PURE__ */ m("span", { style: { color: "#6b7280" }, children: [
|
|
925
927
|
"Guessed letters: ",
|
|
926
928
|
/* @__PURE__ */ o("strong", { children: F.join(", ") })
|
|
927
929
|
] }) }),
|
|
@@ -930,7 +932,7 @@ function Ye({
|
|
|
930
932
|
fontSize: `${s.bodyL}px`,
|
|
931
933
|
margin: "2px 0"
|
|
932
934
|
}, children: "🎉 You won this round!" }),
|
|
933
|
-
f === "lose" && /* @__PURE__ */
|
|
935
|
+
f === "lose" && /* @__PURE__ */ m("div", { style: {
|
|
934
936
|
...a.gmStatusLose,
|
|
935
937
|
fontSize: `${s.bodyL}px`,
|
|
936
938
|
margin: "2px 0"
|
|
@@ -982,14 +984,14 @@ function Ye({
|
|
|
982
984
|
marginTop: `${n}px`,
|
|
983
985
|
marginBottom: `${n}px`
|
|
984
986
|
}, children: "Type a letter on your keyboard" })
|
|
985
|
-
] }) : x === "result" ? /* @__PURE__ */
|
|
987
|
+
] }) : x === "result" ? /* @__PURE__ */ m(G, { children: [
|
|
986
988
|
X,
|
|
987
989
|
/* @__PURE__ */ o("h1", { style: {
|
|
988
990
|
...a.gmHeadline1,
|
|
989
991
|
fontSize: `${s.headline1}px`,
|
|
990
992
|
marginBottom: `${n * 2}px`
|
|
991
993
|
}, children: "🎊 Game Finished!" }),
|
|
992
|
-
/* @__PURE__ */
|
|
994
|
+
/* @__PURE__ */ m("p", { style: {
|
|
993
995
|
...a.gmBodyL,
|
|
994
996
|
fontSize: `${s.bodyL}px`,
|
|
995
997
|
marginBottom: `${n * 2}px`
|
|
@@ -1000,7 +1002,7 @@ function Ye({
|
|
|
1000
1002
|
/* @__PURE__ */ o("strong", { children: M }),
|
|
1001
1003
|
" words correctly."
|
|
1002
1004
|
] }),
|
|
1003
|
-
/* @__PURE__ */
|
|
1005
|
+
/* @__PURE__ */ m("div", { style: {
|
|
1004
1006
|
display: "flex",
|
|
1005
1007
|
flexDirection: "column",
|
|
1006
1008
|
gap: `${n}px`,
|
|
@@ -1078,8 +1080,8 @@ function Ye({
|
|
|
1078
1080
|
"div",
|
|
1079
1081
|
{
|
|
1080
1082
|
style: {
|
|
1081
|
-
width: d ? "100%" : p ||
|
|
1082
|
-
height: d ? "100%" : p ||
|
|
1083
|
+
width: d ? "100%" : p || r || 1e3,
|
|
1084
|
+
height: d ? "100%" : p || r || 1e3,
|
|
1083
1085
|
display: "flex",
|
|
1084
1086
|
justifyContent: "center",
|
|
1085
1087
|
alignItems: "center",
|