tinker-gomoku 0.1.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.
Binary file
Binary file
@@ -0,0 +1,113 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8" />
5
+ <meta
6
+ name="viewport"
7
+ content="width=device-width, initial-scale=1.0, viewport-fit=cover"
8
+ />
9
+ <title>Gomoku</title>
10
+ <script type="module" crossorigin src="./assets/index-Y7WQZDVc.js"></script>
11
+ <link rel="stylesheet" crossorigin href="./assets/index-D4Xg2blJ.css">
12
+ </head>
13
+ <body>
14
+ <main id="app">
15
+ <div id="ui">
16
+ <header class="topbar">
17
+ <button id="menuButton" class="ghost-button" type="button">
18
+ Menu
19
+ </button>
20
+ <div class="turn-pill" id="turnPill">
21
+ <span class="turn-stone black" id="turnStone"></span>
22
+ <span id="turnText">Black to move</span>
23
+ </div>
24
+ <div class="top-actions">
25
+ <button
26
+ id="soundButton"
27
+ class="ghost-button icon-button"
28
+ type="button"
29
+ aria-label="Sound"
30
+ aria-pressed="true"
31
+ >
32
+ <svg class="sound-icon" viewBox="0 0 24 24" aria-hidden="true">
33
+ <path d="M4 9v6h4l5 4V5L8 9H4Z" />
34
+ <path
35
+ class="sound-waves"
36
+ d="M16 9a4 4 0 0 1 0 6M18.5 6.5a7.5 7.5 0 0 1 0 11"
37
+ />
38
+ <path class="sound-off-line" d="m17 9 4 6m0-6-4 6" />
39
+ </svg>
40
+ </button>
41
+ </div>
42
+ </header>
43
+
44
+ <section id="menu" class="overlay">
45
+ <div class="menu-panel">
46
+ <div class="settings-grid">
47
+ <div class="setting">
48
+ <label data-i18n="mode">MODE</label>
49
+ <div class="segmented">
50
+ <button class="choice selected" data-mode="pvp" type="button">
51
+ <span data-i18n="local">LOCAL 2P</span>
52
+ </button>
53
+ <button class="choice" data-mode="pve" type="button">
54
+ <span data-i18n="computer">VS CPU</span>
55
+ </button>
56
+ </div>
57
+ </div>
58
+ <div class="setting" id="difficultySetting">
59
+ <label data-i18n="difficulty">DIFFICULTY</label>
60
+ <div class="segmented">
61
+ <button class="choice" data-difficulty="easy" type="button">
62
+ <span data-i18n="easy">EASY</span>
63
+ </button>
64
+ <button
65
+ class="choice selected"
66
+ data-difficulty="normal"
67
+ type="button"
68
+ >
69
+ <span data-i18n="normal">NORMAL</span>
70
+ </button>
71
+ <button class="choice" data-difficulty="hard" type="button">
72
+ <span data-i18n="hard">HARD</span>
73
+ </button>
74
+ </div>
75
+ </div>
76
+ </div>
77
+ <button id="startButton" class="primary-button" type="button">
78
+ <span data-i18n="start">START MATCH</span>
79
+ </button>
80
+ </div>
81
+ </section>
82
+
83
+ <section id="result" class="overlay hidden">
84
+ <div class="result-panel">
85
+ <h2 id="resultTitle">Black wins</h2>
86
+ <p id="resultText">Five stones, one clean line.</p>
87
+ <div class="result-actions">
88
+ <button id="againButton" class="primary-button" type="button">
89
+ <span data-i18n="playAgain">PLAY AGAIN</span>
90
+ </button>
91
+ <button
92
+ id="resultMenuButton"
93
+ class="secondary-button"
94
+ type="button"
95
+ data-i18n="changeMode"
96
+ >
97
+ CHANGE MODE
98
+ </button>
99
+ </div>
100
+ </div>
101
+ </section>
102
+
103
+ <div class="mobile-controls" aria-label="Board controls">
104
+ <button data-direction="up" type="button">↑</button>
105
+ <button data-direction="left" type="button">←</button>
106
+ <button data-action="place" type="button">●</button>
107
+ <button data-direction="right" type="button">→</button>
108
+ <button data-direction="down" type="button">↓</button>
109
+ </div>
110
+ </div>
111
+ </main>
112
+ </body>
113
+ </html>
Binary file
package/icon.png ADDED
Binary file
package/package.json ADDED
@@ -0,0 +1,30 @@
1
+ {
2
+ "name": "tinker-gomoku",
3
+ "version": "0.1.0",
4
+ "description": "Gomoku Game Plugin for TINKER",
5
+ "files": [
6
+ "dist/",
7
+ "icon.png"
8
+ ],
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "git+https://github.com/liriliri/tinker-games.git"
12
+ },
13
+ "tinker": {
14
+ "name": "Gomoku",
15
+ "description": "Play five in a row against a friend or the computer.",
16
+ "main": "dist/index.html",
17
+ "icon": "icon.png",
18
+ "locales": {
19
+ "zh-CN": {
20
+ "name": "五子棋",
21
+ "description": "和朋友或电脑对弈,连成五子即可获胜。"
22
+ }
23
+ }
24
+ },
25
+ "scripts": {
26
+ "dev": "vite",
27
+ "build": "vite build",
28
+ "format": "prettier \"src/**/*.ts\" \"*.{html,json,ts}\" --write"
29
+ }
30
+ }