@joystyk/cards-ui 0.0.0 → 0.2.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.
@@ -0,0 +1,106 @@
1
+ import { css } from "@gyral/core";
2
+ //#region src/face-styles.ts
3
+ var faceStyles = css`
4
+ @layer components {
5
+ .defs {
6
+ position: absolute;
7
+ inline-size: 0;
8
+ block-size: 0;
9
+ overflow: hidden;
10
+ }
11
+
12
+ .cface,
13
+ .cback {
14
+ box-sizing: border-box;
15
+ aspect-ratio: 5 / 7;
16
+ border-radius: 9%/6.5%;
17
+ box-shadow: 0 1px 2px oklch(0% 0 0 / 0.28);
18
+ }
19
+
20
+ .cface {
21
+ background: var(--card-paper, oklch(98.5% 0.008 90));
22
+ border: 1px solid color-mix(in oklch, var(--card-ink, oklch(24% 0.02 260)) 22%, transparent);
23
+ color: var(--card-ink, oklch(24% 0.02 260));
24
+ }
25
+
26
+ .cback {
27
+ background-color: var(--back-a, oklch(42% 0.07 250));
28
+ background-image:
29
+ radial-gradient(circle at 50% 50%, var(--back-c, oklch(80% 0.11 85)) 0 9%, transparent 10%),
30
+ repeating-linear-gradient(45deg, var(--back-b, oklch(62% 0.08 250)) 0 1.5px, transparent 1.5px 8px),
31
+ repeating-linear-gradient(-45deg, var(--back-b, oklch(62% 0.08 250)) 0 1.5px, transparent 1.5px 8px);
32
+ border: 1px solid color-mix(in oklch, var(--back-a, oklch(42% 0.07 250)) 70%, black);
33
+ }
34
+
35
+ .face {
36
+ display: block;
37
+ inline-size: 100%;
38
+ block-size: 100%;
39
+ fill: var(--suit);
40
+ font-family: var(--card-font, var(--jy-font-sans, system-ui, sans-serif));
41
+ font-weight: 700;
42
+ }
43
+
44
+ .face .index {
45
+ font-size: 21px;
46
+ letter-spacing: -0.5px;
47
+ }
48
+
49
+ .face .corner {
50
+ font-size: 14px;
51
+ }
52
+
53
+ .face .letter {
54
+ font-size: 11px;
55
+ font-weight: 600;
56
+ }
57
+
58
+ .face .monogram {
59
+ font-family: var(--card-serif, Georgia, 'Times New Roman', serif);
60
+ font-size: 46px;
61
+ }
62
+
63
+ .face .frame {
64
+ fill: color-mix(in oklch, var(--suit) 9%, transparent);
65
+ stroke: var(--suit);
66
+ stroke-width: 2.5;
67
+ }
68
+
69
+ .face .crest {
70
+ fill: var(--suit);
71
+ }
72
+
73
+ .s-S,
74
+ .s-C {
75
+ --suit: var(--suit-black, oklch(24% 0.02 260));
76
+ }
77
+
78
+ .s-H,
79
+ .s-D {
80
+ --suit: var(--suit-red, oklch(52% 0.2 25));
81
+ }
82
+
83
+ .four .s-D {
84
+ --suit: var(--suit-blue, oklch(47% 0.17 255));
85
+ }
86
+
87
+ .four .s-C {
88
+ --suit: var(--suit-green, oklch(48% 0.13 150));
89
+ }
90
+
91
+ @media (forced-colors: active) {
92
+ .face {
93
+ fill: CanvasText;
94
+ }
95
+
96
+ .cface,
97
+ .cback {
98
+ border-color: CanvasText;
99
+ }
100
+ }
101
+ }
102
+ `;
103
+ //#endregion
104
+ export { faceStyles };
105
+
106
+ //# sourceMappingURL=face-styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"face-styles.js","names":[],"sources":["../src/face-styles.ts"],"sourcesContent":["// The card art's styles on their own, for components that draw single cards rather than a\n// whole table: the hand widget (<jy-card-hand>) and a game's trick or discard area. Put\n// `suitDefs()` once in the same shadow root, then a card is\n// `<div class=\"cface s-${suit}\">${cardFace(rank, suit)}</div>` and a back is `<div class=\"cback\"></div>`.\n//\n// Every color has a fallback instead of a default on `:host`, so a game themes these cards by\n// setting the custom properties on its own element; they inherit into the hand's shadow root:\n// --card-paper, --card-ink, --suit-black, --suit-red, --suit-blue, --suit-green,\n// --back-a, --back-b, --back-c, --card-font, --card-serif.\n// A `.four` ancestor turns on the four-color deck (blue diamonds, green clubs); the suit's\n// shape and letter always carry the suit, so color is only a second cue.\nimport { css } from '@gyral/core';\n\nexport const faceStyles = css`\n @layer components {\n .defs {\n position: absolute;\n inline-size: 0;\n block-size: 0;\n overflow: hidden;\n }\n\n .cface,\n .cback {\n box-sizing: border-box;\n aspect-ratio: 5 / 7;\n border-radius: 9%/6.5%;\n box-shadow: 0 1px 2px oklch(0% 0 0 / 0.28);\n }\n\n .cface {\n background: var(--card-paper, oklch(98.5% 0.008 90));\n border: 1px solid color-mix(in oklch, var(--card-ink, oklch(24% 0.02 260)) 22%, transparent);\n color: var(--card-ink, oklch(24% 0.02 260));\n }\n\n .cback {\n background-color: var(--back-a, oklch(42% 0.07 250));\n background-image:\n radial-gradient(circle at 50% 50%, var(--back-c, oklch(80% 0.11 85)) 0 9%, transparent 10%),\n repeating-linear-gradient(45deg, var(--back-b, oklch(62% 0.08 250)) 0 1.5px, transparent 1.5px 8px),\n repeating-linear-gradient(-45deg, var(--back-b, oklch(62% 0.08 250)) 0 1.5px, transparent 1.5px 8px);\n border: 1px solid color-mix(in oklch, var(--back-a, oklch(42% 0.07 250)) 70%, black);\n }\n\n .face {\n display: block;\n inline-size: 100%;\n block-size: 100%;\n fill: var(--suit);\n font-family: var(--card-font, var(--jy-font-sans, system-ui, sans-serif));\n font-weight: 700;\n }\n\n .face .index {\n font-size: 21px;\n letter-spacing: -0.5px;\n }\n\n .face .corner {\n font-size: 14px;\n }\n\n .face .letter {\n font-size: 11px;\n font-weight: 600;\n }\n\n .face .monogram {\n font-family: var(--card-serif, Georgia, 'Times New Roman', serif);\n font-size: 46px;\n }\n\n .face .frame {\n fill: color-mix(in oklch, var(--suit) 9%, transparent);\n stroke: var(--suit);\n stroke-width: 2.5;\n }\n\n .face .crest {\n fill: var(--suit);\n }\n\n .s-S,\n .s-C {\n --suit: var(--suit-black, oklch(24% 0.02 260));\n }\n\n .s-H,\n .s-D {\n --suit: var(--suit-red, oklch(52% 0.2 25));\n }\n\n .four .s-D {\n --suit: var(--suit-blue, oklch(47% 0.17 255));\n }\n\n .four .s-C {\n --suit: var(--suit-green, oklch(48% 0.13 150));\n }\n\n @media (forced-colors: active) {\n .face {\n fill: CanvasText;\n }\n\n .cface,\n .cback {\n border-color: CanvasText;\n }\n }\n }\n`;\n"],"mappings":";;AAaA,IAAa,aAAa,GAAG"}
@@ -0,0 +1,11 @@
1
+ import type { Rank, Suit } from '@joystyk/kit/cards';
2
+ /** Suit shapes in a 100 × 100 box, each its own silhouette. */
3
+ export declare const SUIT_PATHS: Readonly<Record<Suit, string>>;
4
+ /** The rank as the card prints it: "A", "7", "10", "Q". */
5
+ export declare const rankLabel: (rank: Rank) => string;
6
+ /** The suit symbols, once per table; faces refer to them with `<use>`. */
7
+ export declare const suitDefs: () => import("@gyral/core").TemplateResult;
8
+ /** Pip centers for 2–10, in the area below the top strip. Lower pips print upside down. */
9
+ export declare const PIPS: Readonly<Record<number, readonly (readonly [number, number])[]>>;
10
+ /** A face-up card's art. Decoration only: the pile's accessible name says what the card is. */
11
+ export declare const cardFace: (rank: Rank, suit: Suit) => import("@gyral/core").TemplateResult;
package/dist/faces.js ADDED
@@ -0,0 +1,403 @@
1
+ import "@gyral/core";
2
+ import { compiled, compiledSvg } from "@gyral/core/compiled";
3
+ //#region src/faces.ts
4
+ var _gyral$t0 = {
5
+ "id": "22xok3v97av",
6
+ "html": "<svg class=\"defs\" width=\"0\" height=\"0\" aria-hidden=\"true\" focusable=\"false\"><defs><symbol id=\"suit-S\" viewBox=\"0 0 100 100\"><path/></symbol><symbol id=\"suit-H\" viewBox=\"0 0 100 100\"><path/></symbol><symbol id=\"suit-D\" viewBox=\"0 0 100 100\"><path/></symbol><symbol id=\"suit-C\" viewBox=\"0 0 100 100\"><path/></symbol></defs></svg>",
7
+ "parts": [
8
+ [
9
+ 3,
10
+ [
11
+ 0,
12
+ 0,
13
+ 0,
14
+ 0
15
+ ],
16
+ "d"
17
+ ],
18
+ [
19
+ 3,
20
+ [
21
+ 0,
22
+ 0,
23
+ 1,
24
+ 0
25
+ ],
26
+ "d"
27
+ ],
28
+ [
29
+ 3,
30
+ [
31
+ 0,
32
+ 0,
33
+ 2,
34
+ 0
35
+ ],
36
+ "d"
37
+ ],
38
+ [
39
+ 3,
40
+ [
41
+ 0,
42
+ 0,
43
+ 3,
44
+ 0
45
+ ],
46
+ "d"
47
+ ]
48
+ ],
49
+ "segments": [
50
+ "<svg class=\"defs\" width=\"0\" height=\"0\" aria-hidden=\"true\" focusable=\"false\"><defs><symbol id=\"suit-S\" viewBox=\"0 0 100 100\"><path",
51
+ {
52
+ "k": "attr",
53
+ "name": "d"
54
+ },
55
+ "/></symbol><symbol id=\"suit-H\" viewBox=\"0 0 100 100\"><path",
56
+ {
57
+ "k": "attr",
58
+ "name": "d"
59
+ },
60
+ "/></symbol><symbol id=\"suit-D\" viewBox=\"0 0 100 100\"><path",
61
+ {
62
+ "k": "attr",
63
+ "name": "d"
64
+ },
65
+ "/></symbol><symbol id=\"suit-C\" viewBox=\"0 0 100 100\"><path",
66
+ {
67
+ "k": "attr",
68
+ "name": "d"
69
+ },
70
+ "/></symbol></defs></svg>"
71
+ ]
72
+ };
73
+ var _gyral$t1 = {
74
+ "id": "j1b5og2pav",
75
+ "html": "<use/>",
76
+ "parts": [
77
+ [
78
+ 3,
79
+ [0],
80
+ "class"
81
+ ],
82
+ [
83
+ 3,
84
+ [0],
85
+ "href"
86
+ ],
87
+ [
88
+ 3,
89
+ [0],
90
+ "x"
91
+ ],
92
+ [
93
+ 3,
94
+ [0],
95
+ "y"
96
+ ],
97
+ [
98
+ 3,
99
+ [0],
100
+ "width"
101
+ ],
102
+ [
103
+ 3,
104
+ [0],
105
+ "height"
106
+ ],
107
+ [
108
+ 3,
109
+ [0],
110
+ "transform"
111
+ ]
112
+ ],
113
+ "svg": true,
114
+ "segments": [
115
+ "<use",
116
+ {
117
+ "k": "attr",
118
+ "name": "class"
119
+ },
120
+ {
121
+ "k": "attr",
122
+ "name": "href"
123
+ },
124
+ {
125
+ "k": "attr",
126
+ "name": "x"
127
+ },
128
+ {
129
+ "k": "attr",
130
+ "name": "y"
131
+ },
132
+ {
133
+ "k": "attr",
134
+ "name": "width"
135
+ },
136
+ {
137
+ "k": "attr",
138
+ "name": "height"
139
+ },
140
+ {
141
+ "k": "attr",
142
+ "name": "transform"
143
+ },
144
+ "/>"
145
+ ]
146
+ };
147
+ var _gyral$t2 = {
148
+ "id": "1fjawzfzu4a",
149
+ "html": "<path class=\"crest\" d=\"M30 62L34 44L42 54L50 38L58 54L66 44L70 62Z\"/>",
150
+ "parts": [],
151
+ "svg": true,
152
+ "segments": ["<path class=\"crest\" d=\"M30 62L34 44L42 54L50 38L58 54L66 44L70 62Z\"/>"]
153
+ };
154
+ var _gyral$t3 = {
155
+ "id": "1k3rr19hgb6",
156
+ "html": "<g class=\"crest\"><path d=\"M30 60Q50 40 70 60Z\"/><circle cx=\"30\" cy=\"54\" r=\"4\"/><circle cx=\"50\" cy=\"42\" r=\"4.5\"/><circle cx=\"70\" cy=\"54\" r=\"4\"/></g>",
157
+ "parts": [],
158
+ "svg": true,
159
+ "segments": ["<g class=\"crest\"><path d=\"M30 60Q50 40 70 60Z\"/><circle cx=\"30\" cy=\"54\" r=\"4\"/><circle cx=\"50\" cy=\"42\" r=\"4.5\"/><circle cx=\"70\" cy=\"54\" r=\"4\"/></g>"]
160
+ };
161
+ var _gyral$t4 = {
162
+ "id": "7d8qbh9elk",
163
+ "html": "<path class=\"crest\" d=\"M30 48L50 60L70 48L70 56L50 68L30 56Z\"/>",
164
+ "parts": [],
165
+ "svg": true,
166
+ "segments": ["<path class=\"crest\" d=\"M30 48L50 60L70 48L70 56L50 68L30 56Z\"/>"]
167
+ };
168
+ var _gyral$t5 = {
169
+ "id": "1sphrc3jsqw",
170
+ "html": "<rect class=\"frame\" x=\"17\" y=\"32\" width=\"66\" height=\"96\" rx=\"9\"/><!----> <text class=\"monogram\" x=\"50\" y=\"108\" text-anchor=\"middle\"></text> <!---->",
171
+ "parts": [
172
+ [
173
+ 2,
174
+ [],
175
+ 1
176
+ ],
177
+ [1, [3]],
178
+ [
179
+ 2,
180
+ [],
181
+ 5
182
+ ],
183
+ [0, []]
184
+ ],
185
+ "svg": true,
186
+ "segments": [
187
+ "<rect class=\"frame\" x=\"17\" y=\"32\" width=\"66\" height=\"96\" rx=\"9\"/>",
188
+ { "k": "child" },
189
+ "<!----> <text class=\"monogram\" x=\"50\" y=\"108\" text-anchor=\"middle\">",
190
+ {
191
+ "k": "child",
192
+ "in": "text",
193
+ "svg": true
194
+ },
195
+ "</text> ",
196
+ { "k": "child" },
197
+ "<!---->",
198
+ { "k": "child" }
199
+ ]
200
+ };
201
+ var _gyral$t6 = {
202
+ "id": "1b8fkoq43rf",
203
+ "html": "<svg class=\"face\" viewBox=\"0 0 100 140\" aria-hidden=\"true\" focusable=\"false\"><text class=\"index\" x=\"7\" y=\"22\"></text> <g class=\"middle\"></g><g transform=\"rotate(180 50 70)\"><text class=\"corner\" x=\"7\" y=\"16\"></text> <text class=\"letter\" x=\"7\" y=\"29\"></text></g></svg>",
204
+ "parts": [
205
+ [1, [0, 0]],
206
+ [
207
+ 2,
208
+ [0],
209
+ 2
210
+ ],
211
+ [1, [0, 2]],
212
+ [1, [
213
+ 0,
214
+ 3,
215
+ 0
216
+ ]],
217
+ [1, [
218
+ 0,
219
+ 3,
220
+ 2
221
+ ]]
222
+ ],
223
+ "segments": [
224
+ "<svg class=\"face\" viewBox=\"0 0 100 140\" aria-hidden=\"true\" focusable=\"false\"><text class=\"index\" x=\"7\" y=\"22\">",
225
+ {
226
+ "k": "child",
227
+ "in": "text",
228
+ "svg": true
229
+ },
230
+ "</text> ",
231
+ {
232
+ "k": "child",
233
+ "in": "svg",
234
+ "svg": true
235
+ },
236
+ "<g class=\"middle\">",
237
+ {
238
+ "k": "child",
239
+ "in": "g",
240
+ "svg": true
241
+ },
242
+ "</g><g transform=\"rotate(180 50 70)\"><text class=\"corner\" x=\"7\" y=\"16\">",
243
+ {
244
+ "k": "child",
245
+ "in": "text",
246
+ "svg": true
247
+ },
248
+ "</text> <text class=\"letter\" x=\"7\" y=\"29\">",
249
+ {
250
+ "k": "child",
251
+ "in": "text",
252
+ "svg": true
253
+ },
254
+ "</text></g></svg>"
255
+ ]
256
+ };
257
+ /** Suit shapes in a 100 × 100 box, each its own silhouette. */
258
+ var SUIT_PATHS = {
259
+ S: "M50 4C64 26 94 40 94 62C94 76 84 85 72 85C63 85 56 80 53 73C54 83 59 91 67 96H33C41 91 46 83 47 73C44 80 37 85 28 85C16 85 6 76 6 62C6 40 36 26 50 4Z",
260
+ H: "M50 92C22 70 4 52 4 30C4 14 16 4 29 4C39 4 46 10 50 19C54 10 61 4 71 4C84 4 96 14 96 30C96 52 78 70 50 92Z",
261
+ D: "M50 2Q64 28 88 50Q64 72 50 98Q36 72 12 50Q36 28 50 2Z",
262
+ C: "M50 8A19 19 0 1 1 49.9 8ZM27 38A19 19 0 1 1 26.9 38ZM73 38A19 19 0 1 1 72.9 38ZM46 58Q46 84 33 96H67Q54 84 54 58Z"
263
+ };
264
+ var RANK_LABELS = {
265
+ 1: "A",
266
+ 2: "2",
267
+ 3: "3",
268
+ 4: "4",
269
+ 5: "5",
270
+ 6: "6",
271
+ 7: "7",
272
+ 8: "8",
273
+ 9: "9",
274
+ 10: "10",
275
+ 11: "J",
276
+ 12: "Q",
277
+ 13: "K"
278
+ };
279
+ /** The rank as the card prints it: "A", "7", "10", "Q". */
280
+ var rankLabel = (rank) => RANK_LABELS[rank];
281
+ /** The suit symbols, once per table; faces refer to them with `<use>`. */
282
+ var suitDefs = () => compiled(_gyral$t0, [
283
+ SUIT_PATHS.S,
284
+ SUIT_PATHS.H,
285
+ SUIT_PATHS.D,
286
+ SUIT_PATHS.C
287
+ ]);
288
+ /** One suit shape, `size` wide, centered on (x, y); `flip` turns it upside down. */
289
+ var pip = (suit, x, y, size, flip = false, cls = null) => compiledSvg(_gyral$t1, [
290
+ cls,
291
+ `#suit-${suit}`,
292
+ x - size / 2,
293
+ y - size / 2,
294
+ size,
295
+ size,
296
+ flip ? `rotate(180 ${x} ${y})` : null
297
+ ]);
298
+ var L = 31;
299
+ var C = 50;
300
+ var R = 69;
301
+ /** Pip centers for 2–10, in the area below the top strip. Lower pips print upside down. */
302
+ var PIPS = {
303
+ 2: [[C, 44], [C, 118]],
304
+ 3: [
305
+ [C, 44],
306
+ [C, 81],
307
+ [C, 118]
308
+ ],
309
+ 4: [
310
+ [L, 44],
311
+ [R, 44],
312
+ [L, 118],
313
+ [R, 118]
314
+ ],
315
+ 5: [
316
+ [L, 44],
317
+ [R, 44],
318
+ [C, 81],
319
+ [L, 118],
320
+ [R, 118]
321
+ ],
322
+ 6: [
323
+ [L, 44],
324
+ [R, 44],
325
+ [L, 81],
326
+ [R, 81],
327
+ [L, 118],
328
+ [R, 118]
329
+ ],
330
+ 7: [
331
+ [L, 44],
332
+ [R, 44],
333
+ [C, 62],
334
+ [L, 81],
335
+ [R, 81],
336
+ [L, 118],
337
+ [R, 118]
338
+ ],
339
+ 8: [
340
+ [L, 44],
341
+ [R, 44],
342
+ [C, 62],
343
+ [L, 81],
344
+ [R, 81],
345
+ [C, 100],
346
+ [L, 118],
347
+ [R, 118]
348
+ ],
349
+ 9: [
350
+ [L, 44],
351
+ [R, 44],
352
+ [L, 69],
353
+ [R, 69],
354
+ [C, 81],
355
+ [L, 93],
356
+ [R, 93],
357
+ [L, 118],
358
+ [R, 118]
359
+ ],
360
+ 10: [
361
+ [L, 44],
362
+ [R, 44],
363
+ [C, 56],
364
+ [L, 69],
365
+ [R, 69],
366
+ [L, 93],
367
+ [R, 93],
368
+ [C, 106],
369
+ [L, 118],
370
+ [R, 118]
371
+ ]
372
+ };
373
+ /** A geometric crest above a court card's letter: a crown's points, a band of beads, a chevron. */
374
+ var crest = (rank) => {
375
+ switch (rank) {
376
+ case 13: return compiledSvg(_gyral$t2, []);
377
+ case 12: return compiledSvg(_gyral$t3, []);
378
+ case 11: return compiledSvg(_gyral$t4, []);
379
+ }
380
+ };
381
+ /** The middle of a face: pips, the ace's single large shape, or a court card's monogram. */
382
+ var middle = (rank, suit) => {
383
+ if (rank === 1) return pip(suit, 50, 82, 46);
384
+ if (rank >= 11) return compiledSvg(_gyral$t5, [
385
+ crest(rank),
386
+ RANK_LABELS[rank],
387
+ pip(suit, 27, 120, 12),
388
+ pip(suit, 73, 120, 12)
389
+ ]);
390
+ return (PIPS[rank] ?? []).map(([x, y]) => pip(suit, x, y, 17, y > 82));
391
+ };
392
+ /** A face-up card's art. Decoration only: the pile's accessible name says what the card is. */
393
+ var cardFace = (rank, suit) => compiled(_gyral$t6, [
394
+ RANK_LABELS[rank],
395
+ pip(suit, 82, 13, 22, false, "suit-index"),
396
+ middle(rank, suit),
397
+ RANK_LABELS[rank],
398
+ suit
399
+ ]);
400
+ //#endregion
401
+ export { PIPS, SUIT_PATHS, cardFace, rankLabel, suitDefs };
402
+
403
+ //# sourceMappingURL=faces.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"faces.js","names":["_gyral$compiled","_gyral$compiledSvg1","court"],"sources":["../src/faces.ts"],"sourcesContent":["// The card art, drawn for Joystyk (klondike.md, \"Theme\"): four suit shapes with distinct\n// silhouettes, number cards with pip layouts, and monogram court cards (a framed letter\n// under a simple geometric crest), never traditional court figures. Every face shows its\n// rank and suit shape in a top strip, the part a fanned column leaves visible, and the rank\n// with the suit's letter in the opposite corner, so a suit never depends on color or on one\n// glyph alone. Faces are SVG in a 100 × 140 box; the card's shape and back are CSS. The\n// strip's rank (`.index`) and suit (`.suit-index`) and the middle (`.middle`) carry classes,\n// so the card table can enlarge the strip on narrow cards (styles.ts).\nimport { html, svg } from '@gyral/core';\nimport type { Rank, Suit } from '@joystyk/kit/cards';\n\n/** Suit shapes in a 100 × 100 box, each its own silhouette. */\nexport const SUIT_PATHS: Readonly<Record<Suit, string>> = {\n // A spade: a pointed leaf over a flared stem.\n S: 'M50 4C64 26 94 40 94 62C94 76 84 85 72 85C63 85 56 80 53 73C54 83 59 91 67 96H33C41 91 46 83 47 73C44 80 37 85 28 85C16 85 6 76 6 62C6 40 36 26 50 4Z',\n // A heart: two round lobes meeting in a point.\n H: 'M50 92C22 70 4 52 4 30C4 14 16 4 29 4C39 4 46 10 50 19C54 10 61 4 71 4C84 4 96 14 96 30C96 52 78 70 50 92Z',\n // A diamond with gently curved sides.\n D: 'M50 2Q64 28 88 50Q64 72 50 98Q36 72 12 50Q36 28 50 2Z',\n // A club: three round leaves over a flared stem.\n C: 'M50 8A19 19 0 1 1 49.9 8ZM27 38A19 19 0 1 1 26.9 38ZM73 38A19 19 0 1 1 72.9 38ZM46 58Q46 84 33 96H67Q54 84 54 58Z',\n};\n\nconst RANK_LABELS: Readonly<Record<Rank, string>> = {\n 1: 'A',\n 2: '2',\n 3: '3',\n 4: '4',\n 5: '5',\n 6: '6',\n 7: '7',\n 8: '8',\n 9: '9',\n 10: '10',\n 11: 'J',\n 12: 'Q',\n 13: 'K',\n};\n\n/** The rank as the card prints it: \"A\", \"7\", \"10\", \"Q\". */\nexport const rankLabel = (rank: Rank): string => RANK_LABELS[rank];\n\n/** The suit symbols, once per table; faces refer to them with `<use>`. */\nexport const suitDefs = () =>\n html`<svg class=\"defs\" width=\"0\" height=\"0\" aria-hidden=\"true\" focusable=\"false\">\n <defs>\n <symbol id=\"suit-S\" viewBox=\"0 0 100 100\"><path d=${SUIT_PATHS.S} /></symbol>\n <symbol id=\"suit-H\" viewBox=\"0 0 100 100\"><path d=${SUIT_PATHS.H} /></symbol>\n <symbol id=\"suit-D\" viewBox=\"0 0 100 100\"><path d=${SUIT_PATHS.D} /></symbol>\n <symbol id=\"suit-C\" viewBox=\"0 0 100 100\"><path d=${SUIT_PATHS.C} /></symbol>\n </defs>\n </svg>`;\n\n/** One suit shape, `size` wide, centered on (x, y); `flip` turns it upside down. */\nconst pip = (suit: Suit, x: number, y: number, size: number, flip = false, cls: string | null = null) =>\n svg`<use class=${cls} href=${`#suit-${suit}`} x=${x - size / 2} y=${y - size / 2} width=${size} height=${size} transform=${flip ? `rotate(180 ${x} ${y})` : null} />`;\n\nconst L = 31;\nconst C = 50;\nconst R = 69;\n\n/** Pip centers for 2–10, in the area below the top strip. Lower pips print upside down. */\nexport const PIPS: Readonly<Record<number, readonly (readonly [number, number])[]>> = {\n 2: [\n [C, 44],\n [C, 118],\n ],\n 3: [\n [C, 44],\n [C, 81],\n [C, 118],\n ],\n 4: [\n [L, 44],\n [R, 44],\n [L, 118],\n [R, 118],\n ],\n 5: [\n [L, 44],\n [R, 44],\n [C, 81],\n [L, 118],\n [R, 118],\n ],\n 6: [\n [L, 44],\n [R, 44],\n [L, 81],\n [R, 81],\n [L, 118],\n [R, 118],\n ],\n 7: [\n [L, 44],\n [R, 44],\n [C, 62],\n [L, 81],\n [R, 81],\n [L, 118],\n [R, 118],\n ],\n 8: [\n [L, 44],\n [R, 44],\n [C, 62],\n [L, 81],\n [R, 81],\n [C, 100],\n [L, 118],\n [R, 118],\n ],\n 9: [\n [L, 44],\n [R, 44],\n [L, 69],\n [R, 69],\n [C, 81],\n [L, 93],\n [R, 93],\n [L, 118],\n [R, 118],\n ],\n 10: [\n [L, 44],\n [R, 44],\n [C, 56],\n [L, 69],\n [R, 69],\n [L, 93],\n [R, 93],\n [C, 106],\n [L, 118],\n [R, 118],\n ],\n};\n\n/** A geometric crest above a court card's letter: a crown's points, a band of beads, a chevron. */\nconst crest = (rank: 11 | 12 | 13) => {\n switch (rank) {\n case 13:\n return svg`<path class=\"crest\" d=\"M30 62L34 44L42 54L50 38L58 54L66 44L70 62Z\" />`;\n case 12:\n return svg`<g class=\"crest\">\n <path d=\"M30 60Q50 40 70 60Z\" />\n <circle cx=\"30\" cy=\"54\" r=\"4\" /><circle cx=\"50\" cy=\"42\" r=\"4.5\" /><circle cx=\"70\" cy=\"54\" r=\"4\" />\n </g>`;\n case 11:\n return svg`<path class=\"crest\" d=\"M30 48L50 60L70 48L70 56L50 68L30 56Z\" />`;\n }\n};\n\n/** The middle of a face: pips, the ace's single large shape, or a court card's monogram. */\nconst middle = (rank: Rank, suit: Suit) => {\n if (rank === 1) return pip(suit, 50, 82, 46);\n if (rank >= 11) {\n const court = rank as 11 | 12 | 13;\n return svg`<rect class=\"frame\" x=\"17\" y=\"32\" width=\"66\" height=\"96\" rx=\"9\" />\n ${crest(court)}\n <text class=\"monogram\" x=\"50\" y=\"108\" text-anchor=\"middle\">${RANK_LABELS[rank]}</text>\n ${pip(suit, 27, 120, 12)}${pip(suit, 73, 120, 12)}`;\n }\n return (PIPS[rank] ?? []).map(([x, y]) => pip(suit, x, y, 17, y > 82));\n};\n\n/** A face-up card's art. Decoration only: the pile's accessible name says what the card is. */\nexport const cardFace = (rank: Rank, suit: Suit) =>\n html`<svg class=\"face\" viewBox=\"0 0 100 140\" aria-hidden=\"true\" focusable=\"false\">\n <text class=\"index\" x=\"7\" y=\"22\">${RANK_LABELS[rank]}</text>\n ${pip(suit, 82, 13, 22, false, 'suit-index')}\n <g class=\"middle\">${middle(rank, suit)}</g>\n <g transform=\"rotate(180 50 70)\">\n <text class=\"corner\" x=\"7\" y=\"16\">${RANK_LABELS[rank]}</text>\n <text class=\"letter\" x=\"7\" y=\"29\">${suit}</text>\n </g>\n </svg>`;\n"],"mappings":";;;AAAA,IAAA,YAAA;CAAA,MAAA;CAAA,QAAA;CAAA,SAAA;EAAA;GAAA;GAAA;IAAA;IAAA;IAAA;IAAA;GAAA;GAAA;EAAA;EAAA;GAAA;GAAA;IAAA;IAAA;IAAA;IAAA;GAAA;GAAA;EAAA;EAAA;GAAA;GAAA;IAAA;IAAA;IAAA;IAAA;GAAA;GAAA;EAAA;EAAA;GAAA;GAAA;IAAA;IAAA;IAAA;IAAA;GAAA;GAAA;EAAA;CAAA;CAAA,YAAA;EAAA;EAAA;GAAA,KAAA;GAAA,QAAA;EAAA;EAAA;EAAA;GAAA,KAAA;GAAA,QAAA;EAAA;EAAA;EAAA;GAAA,KAAA;GAAA,QAAA;EAAA;EAAA;EAAA;GAAA,KAAA;GAAA,QAAA;EAAA;EAAA;CAAA;AAAA;AAAA,IAAA,YAAA;CAAA,MAAA;CAAA,QAAA;CAAA,SAAA;EAAA;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EACA,CAAA,GAAA,EAAA;EACA,CAAA,GAAA,EAAA;EACA,CAAA,GAAA,EAAA;EACA,CAAA,GAAA,EAAA;EACA,CAAA,GAAA,EAAA;EACA,CAAA,GAAA,GAAA;EACA,CAAA,GAAA,GAAA;EACA,CAAA,GAAA,GAAA;CACA;AACA;;AAGA,IAAA,SAAA,SAAA;CACA,QAAA,MAAA;EACA,KAAA,IACA,OAAaA,YAAA,WAAA,CAAA,CAAA;EACb,KAAA,IACA,OAAaA,YAAA,WAAA,CAAA,CAAA;EAIb,KAAA,IACA,OAAaA,YAAA,WAAA,CAAA,CAAA;CACb;AACA;;AAGA,IAAA,UAAA,MAAA,SAAA;CACA,IAAA,SAAA,GAAA,OAAA,IAAA,MAAA,IAAA,IAAA,EAAA;CACA,IAAA,QAAA,IAEA,OAAWA,YAAA,WAAA;EAAA,MACHC,IAAA;EAAY,YAC+C;EAAiB,IAC5E,MAAA,IAAA,KAAA,EAAA;EAAyB,IAAA,MAAA,IAAA,KAAA,EAAA;CAAsB,CAAA;CAEvD,QAAA,KAAA,SAAA,CAAA,EAAA,CAAA,KAAA,CAAA,GAAA,OAAA,IAAA,MAAA,GAAA,GAAA,IAAA,IAAA,EAAA,CAAA;AACA;;AAGA,IAAA,YAAA,MAAA,SACEF,SAAA,WAAA;CAAA,YACqC;CAAiB,IAClD,MAAA,IAAA,IAAA,IAAA,OAAA,YAAA;CAA0C,OACxB,MAAA,IAAA;CAAkB,YAEA;CAAiB;AACb,CAAA"}
@@ -0,0 +1 @@
1
+ export declare const handStyles: import("@gyral/core").StyleSource;
@@ -0,0 +1,121 @@
1
+ import { css } from "@gyral/core";
2
+ //#region src/hand-styles.ts
3
+ var counts = Array.from({ length: 32 }, (_, k) => `.n-${k + 1} { --n: ${k + 1}; }`).join("\n");
4
+ var handStyles = css`
5
+ @layer components {
6
+ ${counts}
7
+
8
+ :host {
9
+ display: block;
10
+ container-type: inline-size;
11
+ }
12
+
13
+ .hand {
14
+ --card-w: clamp(3.6rem, 16cqi, 6.5rem);
15
+ --card-h: calc(var(--card-w) * 1.4);
16
+ --step: clamp(2.75rem, calc((100cqi - var(--card-w) - 0.5rem) / max(1, var(--n, 1) - 1)), calc(var(--card-w) * 0.66));
17
+
18
+ display: flex;
19
+ flex-wrap: wrap;
20
+ justify-content: center;
21
+ row-gap: 0.4rem;
22
+ padding-block-start: calc(var(--card-h) * 0.2);
23
+ padding-inline-end: calc(var(--card-w) - var(--step));
24
+ user-select: none;
25
+ -webkit-user-select: none;
26
+ -webkit-tap-highlight-color: transparent;
27
+ }
28
+
29
+ .hand.tiles { --card-h: calc(var(--card-w) * 2); }
30
+ .hand.tiles .slot { touch-action: none; }
31
+ .hand.tiles .slot:not(.off) .cface { outline: 2px solid var(--hand-select, oklch(40% .06 170)); outline-offset: 1px; translate: 0 -.25rem; }
32
+
33
+ .slot {
34
+ position: relative;
35
+ flex: none;
36
+ inline-size: var(--step);
37
+ block-size: var(--card-h);
38
+ margin: 0;
39
+ padding: 0;
40
+ border: 0;
41
+ background: none;
42
+ color: inherit;
43
+ font: inherit;
44
+ cursor: pointer;
45
+ touch-action: manipulation;
46
+ }
47
+
48
+ .slot .cface {
49
+ position: absolute;
50
+ inset-block-start: 0;
51
+ inset-inline-start: 0;
52
+ inline-size: var(--card-w);
53
+ block-size: var(--card-h);
54
+ transition: translate 140ms ease-out;
55
+ }
56
+
57
+ .slot:focus-visible {
58
+ outline: none;
59
+ }
60
+
61
+ .slot:focus-visible .cface {
62
+ outline: 3px solid var(--hand-focus, oklch(55% 0.2 255));
63
+ outline-offset: 2px;
64
+ z-index: 1;
65
+ }
66
+
67
+ .chosen .cface {
68
+ translate: 0 calc(var(--card-h) * -0.18);
69
+ outline: 3px solid var(--hand-select, oklch(62% 0.19 45));
70
+ outline-offset: 1px;
71
+ }
72
+
73
+ .off .cface {
74
+ translate: 0 calc(var(--card-h) * 0.06);
75
+ cursor: not-allowed;
76
+ }
77
+
78
+ .off .cface::after {
79
+ content: '';
80
+ position: absolute;
81
+ inset: 0;
82
+ border-radius: inherit;
83
+ background: repeating-linear-gradient(135deg, oklch(40% 0.02 260 / 0.22) 0 3px, transparent 3px 7px);
84
+ pointer-events: none;
85
+ }
86
+
87
+ /* A noted card (just received) carries a corner tab, besides the word in its name. */
88
+ .noted .cface::before {
89
+ content: '';
90
+ position: absolute;
91
+ inset-block-start: -0.35rem;
92
+ inset-inline-end: 0.3rem;
93
+ inline-size: 0.7rem;
94
+ block-size: 0.7rem;
95
+ border-radius: 50%;
96
+ background: var(--hand-note, oklch(62% 0.19 45));
97
+ border: 2px solid var(--card-paper, oklch(98.5% 0.008 90));
98
+ }
99
+
100
+ .calm .slot .cface {
101
+ transition: none;
102
+ }
103
+
104
+ @media (prefers-reduced-motion: reduce) {
105
+ .slot .cface {
106
+ transition: none;
107
+ }
108
+ }
109
+
110
+ @media (forced-colors: active) {
111
+ .slot:focus-visible .cface,
112
+ .chosen .cface {
113
+ outline-color: Highlight;
114
+ }
115
+ }
116
+ }
117
+ `;
118
+ //#endregion
119
+ export { handStyles };
120
+
121
+ //# sourceMappingURL=hand-styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hand-styles.js","names":[],"sources":["../src/hand-styles.ts"],"sourcesContent":["// The hand widget's layout: a fan of overlapping cards that fits its container. Each card\n// shows at least a 44 px strip (hearts.md, \"Keyboard and pointer controls\"); when the fan\n// can't fit at that, it wraps onto another row. Chosen cards lift with an outline, cards that\n// can't be played sit lower behind a hatch, and the focused card gets a thick ring: none of\n// these rely on color alone. Theme with --hand-focus, --hand-select and --hand-note.\n// The site's Content Security Policy refuses style attributes, so the card count is a class.\nimport { css } from '@gyral/core';\n\nconst counts = Array.from({ length: 32 }, (_, k) => `.n-${k + 1} { --n: ${k + 1}; }`).join('\\n');\n\nexport const handStyles = css`\n @layer components {\n ${counts}\n\n :host {\n display: block;\n container-type: inline-size;\n }\n\n .hand {\n --card-w: clamp(3.6rem, 16cqi, 6.5rem);\n --card-h: calc(var(--card-w) * 1.4);\n --step: clamp(2.75rem, calc((100cqi - var(--card-w) - 0.5rem) / max(1, var(--n, 1) - 1)), calc(var(--card-w) * 0.66));\n\n display: flex;\n flex-wrap: wrap;\n justify-content: center;\n row-gap: 0.4rem;\n padding-block-start: calc(var(--card-h) * 0.2);\n padding-inline-end: calc(var(--card-w) - var(--step));\n user-select: none;\n -webkit-user-select: none;\n -webkit-tap-highlight-color: transparent;\n }\n\n .hand.tiles { --card-h: calc(var(--card-w) * 2); }\n .hand.tiles .slot { touch-action: none; }\n .hand.tiles .slot:not(.off) .cface { outline: 2px solid var(--hand-select, oklch(40% .06 170)); outline-offset: 1px; translate: 0 -.25rem; }\n\n .slot {\n position: relative;\n flex: none;\n inline-size: var(--step);\n block-size: var(--card-h);\n margin: 0;\n padding: 0;\n border: 0;\n background: none;\n color: inherit;\n font: inherit;\n cursor: pointer;\n touch-action: manipulation;\n }\n\n .slot .cface {\n position: absolute;\n inset-block-start: 0;\n inset-inline-start: 0;\n inline-size: var(--card-w);\n block-size: var(--card-h);\n transition: translate 140ms ease-out;\n }\n\n .slot:focus-visible {\n outline: none;\n }\n\n .slot:focus-visible .cface {\n outline: 3px solid var(--hand-focus, oklch(55% 0.2 255));\n outline-offset: 2px;\n z-index: 1;\n }\n\n .chosen .cface {\n translate: 0 calc(var(--card-h) * -0.18);\n outline: 3px solid var(--hand-select, oklch(62% 0.19 45));\n outline-offset: 1px;\n }\n\n .off .cface {\n translate: 0 calc(var(--card-h) * 0.06);\n cursor: not-allowed;\n }\n\n .off .cface::after {\n content: '';\n position: absolute;\n inset: 0;\n border-radius: inherit;\n background: repeating-linear-gradient(135deg, oklch(40% 0.02 260 / 0.22) 0 3px, transparent 3px 7px);\n pointer-events: none;\n }\n\n /* A noted card (just received) carries a corner tab, besides the word in its name. */\n .noted .cface::before {\n content: '';\n position: absolute;\n inset-block-start: -0.35rem;\n inset-inline-end: 0.3rem;\n inline-size: 0.7rem;\n block-size: 0.7rem;\n border-radius: 50%;\n background: var(--hand-note, oklch(62% 0.19 45));\n border: 2px solid var(--card-paper, oklch(98.5% 0.008 90));\n }\n\n .calm .slot .cface {\n transition: none;\n }\n\n @media (prefers-reduced-motion: reduce) {\n .slot .cface {\n transition: none;\n }\n }\n\n @media (forced-colors: active) {\n .slot:focus-visible .cface,\n .chosen .cface {\n outline-color: Highlight;\n }\n }\n }\n`;\n"],"mappings":";;AAQA,IAAM,SAAS,MAAM,KAAK,EAAE,QAAQ,GAAG,IAAI,GAAG,MAAM,MAAM,IAAI,EAAE,UAAU,IAAI,EAAE,IAAI,CAAC,CAAC,KAAK,IAAI;AAE/F,IAAa,aAAa,GAAG;;MAEvB,OAAO"}