@johnmorrisdotca/kazu 1.1.0 → 1.3.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.
- package/CHANGELOG.md +39 -0
- package/README.md +424 -10
- package/dist/akari-draw-entry.d.ts +2 -0
- package/dist/akari-draw-entry.js +1 -0
- package/dist/akari-entry.d.ts +13 -0
- package/dist/akari-entry.js +11 -0
- package/dist/akari-play-entry.d.ts +2 -0
- package/dist/akari-play-entry.js +1 -0
- package/dist/akari.constants.d.ts +7 -0
- package/dist/akari.constants.js +7 -0
- package/dist/akari.types.d.ts +52 -0
- package/dist/akari.types.js +1 -0
- package/dist/akariBoard.d.ts +11 -0
- package/dist/akariBoard.js +96 -0
- package/dist/akariDraw.d.ts +4 -0
- package/dist/akariDraw.js +38 -0
- package/dist/akariGame.d.ts +15 -0
- package/dist/akariGame.js +71 -0
- package/dist/akariGenerate.d.ts +10 -0
- package/dist/akariGenerate.js +101 -0
- package/dist/akariLogic.d.ts +10 -0
- package/dist/akariLogic.js +84 -0
- package/dist/akariMount.d.ts +3 -0
- package/dist/akariMount.js +214 -0
- package/dist/akariPlay.types.d.ts +25 -0
- package/dist/akariPlay.types.js +1 -0
- package/dist/akariRate.d.ts +6 -0
- package/dist/akariRate.js +34 -0
- package/dist/akariSolve.d.ts +6 -0
- package/dist/akariSolve.js +18 -0
- package/dist/akariStrings.d.ts +98 -0
- package/dist/akariStrings.js +53 -0
- package/dist/akariStyle.d.ts +1 -0
- package/dist/akariStyle.js +9 -0
- package/dist/akariTemplate.d.ts +7 -0
- package/dist/akariTemplate.js +78 -0
- package/dist/csp.d.ts +63 -0
- package/dist/csp.js +162 -0
- package/dist/fillomino-draw-entry.d.ts +2 -0
- package/dist/fillomino-draw-entry.js +1 -0
- package/dist/fillomino-entry.d.ts +9 -0
- package/dist/fillomino-entry.js +8 -0
- package/dist/fillomino-play-entry.d.ts +4 -0
- package/dist/fillomino-play-entry.js +3 -0
- package/dist/fillomino.constants.d.ts +9 -0
- package/dist/fillomino.constants.js +9 -0
- package/dist/fillomino.types.d.ts +47 -0
- package/dist/fillomino.types.js +1 -0
- package/dist/fillominoBoard.d.ts +6 -0
- package/dist/fillominoBoard.js +84 -0
- package/dist/fillominoBuild.d.ts +10 -0
- package/dist/fillominoBuild.js +78 -0
- package/dist/fillominoDraw.d.ts +3 -0
- package/dist/fillominoDraw.js +31 -0
- package/dist/fillominoGame.d.ts +13 -0
- package/dist/fillominoGame.js +65 -0
- package/dist/fillominoGenerate.d.ts +9 -0
- package/dist/fillominoGenerate.js +93 -0
- package/dist/fillominoLogic.d.ts +14 -0
- package/dist/fillominoLogic.js +177 -0
- package/dist/fillominoMount.d.ts +2 -0
- package/dist/fillominoMount.js +214 -0
- package/dist/fillominoPlay.types.d.ts +25 -0
- package/dist/fillominoPlay.types.js +1 -0
- package/dist/fillominoRate.d.ts +3 -0
- package/dist/fillominoRate.js +57 -0
- package/dist/fillominoSolve.d.ts +6 -0
- package/dist/fillominoSolve.js +38 -0
- package/dist/fillominoStrings.d.ts +102 -0
- package/dist/fillominoStrings.js +13 -0
- package/dist/fillominoStyle.d.ts +1 -0
- package/dist/fillominoStyle.js +13 -0
- package/dist/fillominoWorker.d.ts +1 -0
- package/dist/fillominoWorker.js +10 -0
- package/dist/heyawake-draw-entry.d.ts +2 -0
- package/dist/heyawake-draw-entry.js +1 -0
- package/dist/heyawake-entry.d.ts +13 -0
- package/dist/heyawake-entry.js +11 -0
- package/dist/heyawake-play-entry.d.ts +2 -0
- package/dist/heyawake-play-entry.js +1 -0
- package/dist/heyawake.constants.d.ts +5 -0
- package/dist/heyawake.constants.js +5 -0
- package/dist/heyawake.types.d.ts +35 -0
- package/dist/heyawake.types.js +1 -0
- package/dist/heyawakeBoard.d.ts +7 -0
- package/dist/heyawakeBoard.js +116 -0
- package/dist/heyawakeDraw.d.ts +3 -0
- package/dist/heyawakeDraw.js +27 -0
- package/dist/heyawakeGame.d.ts +12 -0
- package/dist/heyawakeGame.js +51 -0
- package/dist/heyawakeGenerate.d.ts +2 -0
- package/dist/heyawakeGenerate.js +114 -0
- package/dist/heyawakeMount.d.ts +2 -0
- package/dist/heyawakeMount.js +106 -0
- package/dist/heyawakePlay.types.d.ts +24 -0
- package/dist/heyawakePlay.types.js +1 -0
- package/dist/heyawakeSolve.d.ts +5 -0
- package/dist/heyawakeSolve.js +52 -0
- package/dist/heyawakeStrings.d.ts +19 -0
- package/dist/heyawakeStrings.js +7 -0
- package/dist/heyawakeStyle.d.ts +1 -0
- package/dist/heyawakeStyle.js +2 -0
- package/dist/heyawakeWorker.d.ts +1 -0
- package/dist/heyawakeWorker.js +10 -0
- package/dist/hitori-draw-entry.d.ts +2 -0
- package/dist/hitori-draw-entry.js +1 -0
- package/dist/hitori-entry.d.ts +7 -0
- package/dist/hitori-entry.js +7 -0
- package/dist/hitori-play-entry.d.ts +4 -0
- package/dist/hitori-play-entry.js +3 -0
- package/dist/hitori.constants.d.ts +8 -0
- package/dist/hitori.constants.js +8 -0
- package/dist/hitori.types.d.ts +37 -0
- package/dist/hitori.types.js +1 -0
- package/dist/hitoriBoard.d.ts +8 -0
- package/dist/hitoriBoard.js +73 -0
- package/dist/hitoriBuild.d.ts +12 -0
- package/dist/hitoriBuild.js +117 -0
- package/dist/hitoriDraw.d.ts +4 -0
- package/dist/hitoriDraw.js +25 -0
- package/dist/hitoriGame.d.ts +10 -0
- package/dist/hitoriGame.js +48 -0
- package/dist/hitoriGenerate.d.ts +10 -0
- package/dist/hitoriGenerate.js +65 -0
- package/dist/hitoriLogic.d.ts +12 -0
- package/dist/hitoriLogic.js +189 -0
- package/dist/hitoriMount.d.ts +3 -0
- package/dist/hitoriMount.js +111 -0
- package/dist/hitoriPlay.types.d.ts +25 -0
- package/dist/hitoriPlay.types.js +1 -0
- package/dist/hitoriRate.d.ts +3 -0
- package/dist/hitoriRate.js +32 -0
- package/dist/hitoriSolve.d.ts +9 -0
- package/dist/hitoriSolve.js +18 -0
- package/dist/hitoriStrings.d.ts +70 -0
- package/dist/hitoriStrings.js +17 -0
- package/dist/hitoriStyle.d.ts +1 -0
- package/dist/hitoriStyle.js +9 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +11 -0
- package/dist/juosan-draw-entry.d.ts +2 -0
- package/dist/juosan-draw-entry.js +1 -0
- package/dist/juosan-entry.d.ts +11 -0
- package/dist/juosan-entry.js +10 -0
- package/dist/juosan-play-entry.d.ts +4 -0
- package/dist/juosan-play-entry.js +3 -0
- package/dist/juosan.constants.d.ts +4 -0
- package/dist/juosan.constants.js +4 -0
- package/dist/juosan.types.d.ts +33 -0
- package/dist/juosan.types.js +1 -0
- package/dist/juosanBoard.d.ts +7 -0
- package/dist/juosanBoard.js +102 -0
- package/dist/juosanDraw.d.ts +4 -0
- package/dist/juosanDraw.js +49 -0
- package/dist/juosanGame.d.ts +20 -0
- package/dist/juosanGame.js +86 -0
- package/dist/juosanGenerate.d.ts +3 -0
- package/dist/juosanGenerate.js +31 -0
- package/dist/juosanMount.d.ts +3 -0
- package/dist/juosanMount.js +206 -0
- package/dist/juosanPlay.types.d.ts +24 -0
- package/dist/juosanPlay.types.js +1 -0
- package/dist/juosanSolve.d.ts +3 -0
- package/dist/juosanSolve.js +82 -0
- package/dist/juosanStrings.d.ts +77 -0
- package/dist/juosanStrings.js +43 -0
- package/dist/juosanStyle.d.ts +1 -0
- package/dist/juosanStyle.js +1 -0
- package/dist/kakuro-draw-entry.d.ts +2 -0
- package/dist/kakuro-draw-entry.js +1 -0
- package/dist/kakuro-entry.d.ts +13 -0
- package/dist/kakuro-entry.js +11 -0
- package/dist/kakuro-play-entry.d.ts +4 -0
- package/dist/kakuro-play-entry.js +3 -0
- package/dist/kakuro.constants.d.ts +11 -0
- package/dist/kakuro.constants.js +11 -0
- package/dist/kakuro.types.d.ts +65 -0
- package/dist/kakuro.types.js +1 -0
- package/dist/kakuroBoard.d.ts +8 -0
- package/dist/kakuroBoard.js +117 -0
- package/dist/kakuroBuild.d.ts +30 -0
- package/dist/kakuroBuild.js +337 -0
- package/dist/kakuroDraw.d.ts +10 -0
- package/dist/kakuroDraw.js +21 -0
- package/dist/kakuroGame.d.ts +12 -0
- package/dist/kakuroGame.js +74 -0
- package/dist/kakuroGenerate.d.ts +10 -0
- package/dist/kakuroGenerate.js +62 -0
- package/dist/kakuroLogic.d.ts +13 -0
- package/dist/kakuroLogic.js +153 -0
- package/dist/kakuroMount.d.ts +2 -0
- package/dist/kakuroMount.js +109 -0
- package/dist/kakuroPlay.types.d.ts +20 -0
- package/dist/kakuroPlay.types.js +1 -0
- package/dist/kakuroRate.d.ts +3 -0
- package/dist/kakuroRate.js +40 -0
- package/dist/kakuroSolve.d.ts +6 -0
- package/dist/kakuroSolve.js +33 -0
- package/dist/kakuroStrings.d.ts +82 -0
- package/dist/kakuroStrings.js +5 -0
- package/dist/kakuroStyle.d.ts +1 -0
- package/dist/kakuroStyle.js +1 -0
- package/dist/kakuroTemplate.d.ts +3 -0
- package/dist/kakuroTemplate.js +130 -0
- package/dist/masyu-draw-entry.d.ts +2 -0
- package/dist/masyu-draw-entry.js +1 -0
- package/dist/masyu-entry.d.ts +6 -0
- package/dist/masyu-entry.js +6 -0
- package/dist/masyu-play-entry.d.ts +4 -0
- package/dist/masyu-play-entry.js +3 -0
- package/dist/masyu.constants.d.ts +2 -0
- package/dist/masyu.constants.js +2 -0
- package/dist/masyu.types.d.ts +46 -0
- package/dist/masyu.types.js +1 -0
- package/dist/masyuBoard.d.ts +10 -0
- package/dist/masyuBoard.js +88 -0
- package/dist/masyuDraw.d.ts +2 -0
- package/dist/masyuDraw.js +33 -0
- package/dist/masyuGame.d.ts +9 -0
- package/dist/masyuGame.js +46 -0
- package/dist/masyuGenerate.d.ts +3 -0
- package/dist/masyuGenerate.js +56 -0
- package/dist/masyuMount.d.ts +2 -0
- package/dist/masyuMount.js +118 -0
- package/dist/masyuPlay.types.d.ts +1 -0
- package/dist/masyuPlay.types.js +1 -0
- package/dist/masyuSolve.d.ts +6 -0
- package/dist/masyuSolve.js +88 -0
- package/dist/masyuStrings.d.ts +28 -0
- package/dist/masyuStrings.js +4 -0
- package/dist/masyuStyle.d.ts +1 -0
- package/dist/masyuStyle.js +11 -0
- package/dist/nurikabe-draw-entry.d.ts +2 -0
- package/dist/nurikabe-draw-entry.js +1 -0
- package/dist/nurikabe-entry.d.ts +6 -0
- package/dist/nurikabe-entry.js +6 -0
- package/dist/nurikabe-play-entry.d.ts +4 -0
- package/dist/nurikabe-play-entry.js +3 -0
- package/dist/nurikabe.constants.d.ts +2 -0
- package/dist/nurikabe.constants.js +2 -0
- package/dist/nurikabe.types.d.ts +20 -0
- package/dist/nurikabe.types.js +1 -0
- package/dist/nurikabeBoard.d.ts +8 -0
- package/dist/nurikabeBoard.js +72 -0
- package/dist/nurikabeDraw.d.ts +4 -0
- package/dist/nurikabeDraw.js +15 -0
- package/dist/nurikabeGame.d.ts +8 -0
- package/dist/nurikabeGame.js +40 -0
- package/dist/nurikabeGenerate.d.ts +3 -0
- package/dist/nurikabeGenerate.js +31 -0
- package/dist/nurikabeMount.d.ts +3 -0
- package/dist/nurikabeMount.js +99 -0
- package/dist/nurikabePlay.types.d.ts +25 -0
- package/dist/nurikabePlay.types.js +1 -0
- package/dist/nurikabeSolve.d.ts +6 -0
- package/dist/nurikabeSolve.js +75 -0
- package/dist/nurikabeStrings.d.ts +70 -0
- package/dist/nurikabeStrings.js +5 -0
- package/dist/nurikabeStyle.d.ts +1 -0
- package/dist/nurikabeStyle.js +9 -0
- package/dist/ripple-draw-entry.d.ts +2 -0
- package/dist/ripple-draw-entry.js +1 -0
- package/dist/ripple-entry.d.ts +12 -0
- package/dist/ripple-entry.js +11 -0
- package/dist/ripple-play-entry.d.ts +4 -0
- package/dist/ripple-play-entry.js +3 -0
- package/dist/ripple.constants.d.ts +4 -0
- package/dist/ripple.constants.js +4 -0
- package/dist/ripple.types.d.ts +34 -0
- package/dist/ripple.types.js +1 -0
- package/dist/rippleBoard.d.ts +7 -0
- package/dist/rippleBoard.js +99 -0
- package/dist/rippleDraw.d.ts +3 -0
- package/dist/rippleDraw.js +32 -0
- package/dist/rippleGame.d.ts +13 -0
- package/dist/rippleGame.js +85 -0
- package/dist/rippleGenerate.d.ts +3 -0
- package/dist/rippleGenerate.js +57 -0
- package/dist/rippleMount.d.ts +2 -0
- package/dist/rippleMount.js +179 -0
- package/dist/ripplePlay.types.d.ts +23 -0
- package/dist/ripplePlay.types.js +1 -0
- package/dist/rippleSolve.d.ts +6 -0
- package/dist/rippleSolve.js +83 -0
- package/dist/rippleStrings.d.ts +86 -0
- package/dist/rippleStrings.js +5 -0
- package/dist/rippleStyle.d.ts +1 -0
- package/dist/rippleStyle.js +1 -0
- package/dist/shikaku-entry.d.ts +2 -0
- package/dist/shikaku-entry.js +2 -0
- package/dist/shikaku.constants.d.ts +5 -2
- package/dist/shikaku.constants.js +5 -2
- package/dist/shikaku.types.d.ts +18 -1
- package/dist/shikakuBuild.d.ts +21 -0
- package/dist/shikakuBuild.js +135 -0
- package/dist/shikakuGenerate.d.ts +6 -1
- package/dist/shikakuGenerate.js +50 -35
- package/dist/shikakuLogic.d.ts +13 -0
- package/dist/shikakuLogic.js +84 -0
- package/dist/shikakuPacks.d.ts +27 -0
- package/dist/shikakuPacks.js +26 -0
- package/dist/shikakuRate.d.ts +3 -0
- package/dist/shikakuRate.js +27 -0
- package/dist/shikakuSolve.d.ts +1 -1
- package/dist/shikakuSolve.js +23 -44
- package/dist/shikakuTemplate.d.ts +3 -0
- package/dist/shikakuTemplate.js +43 -0
- package/dist/slitherlink-draw-entry.d.ts +2 -0
- package/dist/slitherlink-draw-entry.js +1 -0
- package/dist/slitherlink-entry.d.ts +12 -0
- package/dist/slitherlink-entry.js +10 -0
- package/dist/slitherlink-play-entry.d.ts +4 -0
- package/dist/slitherlink-play-entry.js +3 -0
- package/dist/slitherlink.constants.d.ts +7 -0
- package/dist/slitherlink.constants.js +7 -0
- package/dist/slitherlink.types.d.ts +52 -0
- package/dist/slitherlink.types.js +1 -0
- package/dist/slitherlinkBoard.d.ts +12 -0
- package/dist/slitherlinkBoard.js +132 -0
- package/dist/slitherlinkDraw.d.ts +4 -0
- package/dist/slitherlinkDraw.js +51 -0
- package/dist/slitherlinkGame.d.ts +8 -0
- package/dist/slitherlinkGame.js +63 -0
- package/dist/slitherlinkGenerate.d.ts +10 -0
- package/dist/slitherlinkGenerate.js +182 -0
- package/dist/slitherlinkLogic.d.ts +10 -0
- package/dist/slitherlinkLogic.js +267 -0
- package/dist/slitherlinkMount.d.ts +3 -0
- package/dist/slitherlinkMount.js +267 -0
- package/dist/slitherlinkPlay.types.d.ts +23 -0
- package/dist/slitherlinkPlay.types.js +1 -0
- package/dist/slitherlinkRate.d.ts +3 -0
- package/dist/slitherlinkRate.js +26 -0
- package/dist/slitherlinkSolve.d.ts +6 -0
- package/dist/slitherlinkSolve.js +19 -0
- package/dist/slitherlinkStrings.d.ts +86 -0
- package/dist/slitherlinkStrings.js +47 -0
- package/dist/slitherlinkStyle.d.ts +1 -0
- package/dist/slitherlinkStyle.js +18 -0
- package/dist/slitherlinkTemplate.d.ts +3 -0
- package/dist/slitherlinkTemplate.js +101 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/yajilin-draw-entry.d.ts +2 -0
- package/dist/yajilin-draw-entry.js +1 -0
- package/dist/yajilin-entry.d.ts +6 -0
- package/dist/yajilin-entry.js +6 -0
- package/dist/yajilin-play-entry.d.ts +4 -0
- package/dist/yajilin-play-entry.js +3 -0
- package/dist/yajilin.constants.d.ts +2 -0
- package/dist/yajilin.constants.js +2 -0
- package/dist/yajilin.types.d.ts +63 -0
- package/dist/yajilin.types.js +1 -0
- package/dist/yajilinBoard.d.ts +9 -0
- package/dist/yajilinBoard.js +91 -0
- package/dist/yajilinDraw.d.ts +2 -0
- package/dist/yajilinDraw.js +33 -0
- package/dist/yajilinGame.d.ts +15 -0
- package/dist/yajilinGame.js +58 -0
- package/dist/yajilinGenerate.d.ts +3 -0
- package/dist/yajilinGenerate.js +224 -0
- package/dist/yajilinMount.d.ts +2 -0
- package/dist/yajilinMount.js +162 -0
- package/dist/yajilinPlay.types.d.ts +1 -0
- package/dist/yajilinPlay.types.js +1 -0
- package/dist/yajilinSolve.d.ts +6 -0
- package/dist/yajilinSolve.js +82 -0
- package/dist/yajilinStrings.d.ts +32 -0
- package/dist/yajilinStrings.js +4 -0
- package/dist/yajilinStyle.d.ts +1 -0
- package/dist/yajilinStyle.js +12 -0
- package/package.json +180 -3
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
import { checkYajilin, yajilinNeighbors } from "./yajilinBoard.js";
|
|
2
|
+
import { decodeYajilin, encodeYajilin, hintYajilin, newYajilin, restartYajilin, toggleYajilinEdge, toggleYajilinShade, undoYajilin } from "./yajilinGame.js";
|
|
3
|
+
import { drawYajilin } from "./yajilinDraw.js";
|
|
4
|
+
import { YAJILIN_PLAY_STYLE } from "./yajilinStyle.js";
|
|
5
|
+
import { YAJILIN_STRINGS } from "./yajilinStrings.js";
|
|
6
|
+
export function mountYajilin(element, initial) {
|
|
7
|
+
const document = element.ownerDocument, style = document.createElement("style");
|
|
8
|
+
style.textContent = YAJILIN_PLAY_STYLE;
|
|
9
|
+
const root = document.createElement("section");
|
|
10
|
+
root.className = "kazu-yajilin";
|
|
11
|
+
const help = document.createElement("p"), board = document.createElement("div");
|
|
12
|
+
board.className = "ky-board";
|
|
13
|
+
const modes = document.createElement("div");
|
|
14
|
+
modes.className = "ky-tools ky-modes";
|
|
15
|
+
const tools = document.createElement("div");
|
|
16
|
+
tools.className = "ky-tools";
|
|
17
|
+
const status = document.createElement("p");
|
|
18
|
+
status.className = "ky-status";
|
|
19
|
+
status.setAttribute("aria-live", "polite");
|
|
20
|
+
root.append(help, modes, board, tools, status);
|
|
21
|
+
element.replaceChildren(style, root);
|
|
22
|
+
let options = { ...initial };
|
|
23
|
+
let game = initial.progress ? decodeYajilin(initial.progress) : null;
|
|
24
|
+
const sameBoard = game && game.board.width === initial.board.width && game.board.height === initial.board.height
|
|
25
|
+
&& game.board.clues.every((clue, cell) => JSON.stringify(clue) === JSON.stringify(initial.board.clues[cell]));
|
|
26
|
+
if (!sameBoard)
|
|
27
|
+
game = newYajilin(initial.board);
|
|
28
|
+
let selected = 0, anchor = null, mode = "line";
|
|
29
|
+
let errors = [], message = "", dead = false;
|
|
30
|
+
const words = () => YAJILIN_STRINGS[options.language ?? "en"];
|
|
31
|
+
const copy = () => ({ ...game, board: { ...game.board, clues: game.board.clues.map(clue => clue ? { ...clue } : null) }, shaded: [...game.shaded], edges: [...game.edges], history: game.history.map(turn => ({ shaded: [...turn.shaded], edges: [...turn.edges] })) });
|
|
32
|
+
const changed = () => { options.onChange?.(copy()); if (checkYajilin(game.board, game.shaded, game.edges).ok)
|
|
33
|
+
options.onFinish?.(copy()); };
|
|
34
|
+
const toggleBetween = (first, second) => {
|
|
35
|
+
const edge = yajilinNeighbors(game.board, first).find(next => next.cell === second)?.edge;
|
|
36
|
+
if (edge === undefined)
|
|
37
|
+
return;
|
|
38
|
+
game = toggleYajilinEdge(game, edge);
|
|
39
|
+
anchor = second;
|
|
40
|
+
selected = second;
|
|
41
|
+
errors = [];
|
|
42
|
+
message = "";
|
|
43
|
+
render();
|
|
44
|
+
changed();
|
|
45
|
+
};
|
|
46
|
+
const render = () => {
|
|
47
|
+
if (dead)
|
|
48
|
+
return;
|
|
49
|
+
const w = words();
|
|
50
|
+
help.textContent = w.help;
|
|
51
|
+
board.innerHTML = drawYajilin(game.board, { ...options, shaded: game.shaded, edges: game.edges, selected, errors });
|
|
52
|
+
const controls = document.createElement("div");
|
|
53
|
+
controls.className = "ky-cells";
|
|
54
|
+
controls.style.gridTemplateColumns = `repeat(${game.board.width}, 1fr)`;
|
|
55
|
+
controls.style.gridTemplateRows = `repeat(${game.board.height}, 1fr)`;
|
|
56
|
+
game.board.clues.forEach((clue, cell) => {
|
|
57
|
+
const button = document.createElement("button");
|
|
58
|
+
button.type = "button";
|
|
59
|
+
button.className = "ky-cell";
|
|
60
|
+
button.dataset.cell = String(cell);
|
|
61
|
+
if (clue)
|
|
62
|
+
button.dataset.clue = "true";
|
|
63
|
+
button.textContent = clue ? `${clue.direction} ${clue.count}` : String(cell + 1);
|
|
64
|
+
button.setAttribute("aria-label", clue ? `${clue.direction} ${clue.count}` : `row ${Math.floor(cell / game.board.width) + 1}, column ${cell % game.board.width + 1}${game.shaded[cell] ? ", shaded" : ""}`);
|
|
65
|
+
button.setAttribute("aria-pressed", String(selected === cell));
|
|
66
|
+
button.tabIndex = selected === cell ? 0 : -1;
|
|
67
|
+
button.onclick = () => {
|
|
68
|
+
selected = cell;
|
|
69
|
+
if (mode === "shade") {
|
|
70
|
+
game = toggleYajilinShade(game, cell);
|
|
71
|
+
errors = [];
|
|
72
|
+
changed();
|
|
73
|
+
}
|
|
74
|
+
else if (anchor === null)
|
|
75
|
+
anchor = cell;
|
|
76
|
+
else if (anchor !== cell)
|
|
77
|
+
toggleBetween(anchor, cell);
|
|
78
|
+
render();
|
|
79
|
+
};
|
|
80
|
+
button.onkeydown = event => {
|
|
81
|
+
const x = cell % game.board.width, y = Math.floor(cell / game.board.width);
|
|
82
|
+
const moves = { ArrowUp: [0, -1], ArrowDown: [0, 1], ArrowLeft: [-1, 0], ArrowRight: [1, 0] };
|
|
83
|
+
if (event.key in moves) {
|
|
84
|
+
event.preventDefault();
|
|
85
|
+
const [dx, dy] = moves[event.key], nextX = x + dx, nextY = y + dy;
|
|
86
|
+
if (nextX >= 0 && nextX < game.board.width && nextY >= 0 && nextY < game.board.height) {
|
|
87
|
+
selected = nextY * game.board.width + nextX;
|
|
88
|
+
render();
|
|
89
|
+
board.querySelectorAll(".ky-cell")[selected]?.focus();
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
else if (event.key === "Enter") {
|
|
93
|
+
event.preventDefault();
|
|
94
|
+
if (mode === "shade") {
|
|
95
|
+
game = toggleYajilinShade(game, cell);
|
|
96
|
+
errors = [];
|
|
97
|
+
changed();
|
|
98
|
+
}
|
|
99
|
+
else if (anchor === null)
|
|
100
|
+
anchor = cell;
|
|
101
|
+
else if (anchor !== cell)
|
|
102
|
+
toggleBetween(anchor, cell);
|
|
103
|
+
render();
|
|
104
|
+
board.querySelectorAll(".ky-cell")[selected]?.focus();
|
|
105
|
+
}
|
|
106
|
+
else if (event.key === " ") {
|
|
107
|
+
event.preventDefault();
|
|
108
|
+
mode = "shade";
|
|
109
|
+
game = toggleYajilinShade(game, cell);
|
|
110
|
+
errors = [];
|
|
111
|
+
changed();
|
|
112
|
+
render();
|
|
113
|
+
board.querySelectorAll(".ky-cell")[selected]?.focus();
|
|
114
|
+
}
|
|
115
|
+
else if (event.key.toLowerCase() === "l") {
|
|
116
|
+
mode = "line";
|
|
117
|
+
render();
|
|
118
|
+
board.querySelectorAll(".ky-cell")[selected]?.focus();
|
|
119
|
+
}
|
|
120
|
+
else if (event.key.toLowerCase() === "s") {
|
|
121
|
+
mode = "shade";
|
|
122
|
+
render();
|
|
123
|
+
board.querySelectorAll(".ky-cell")[selected]?.focus();
|
|
124
|
+
}
|
|
125
|
+
};
|
|
126
|
+
controls.append(button);
|
|
127
|
+
});
|
|
128
|
+
board.append(controls);
|
|
129
|
+
modes.replaceChildren();
|
|
130
|
+
tools.replaceChildren();
|
|
131
|
+
const add = (host, label, action, pressed) => {
|
|
132
|
+
const button = document.createElement("button");
|
|
133
|
+
button.type = "button";
|
|
134
|
+
button.textContent = label;
|
|
135
|
+
if (pressed !== undefined)
|
|
136
|
+
button.setAttribute("aria-pressed", String(pressed));
|
|
137
|
+
button.onclick = action;
|
|
138
|
+
host.append(button);
|
|
139
|
+
};
|
|
140
|
+
add(modes, w.line, () => { mode = "line"; render(); }, mode === "line");
|
|
141
|
+
add(modes, w.shade, () => { mode = "shade"; render(); }, mode === "shade");
|
|
142
|
+
add(tools, w.undo, () => { game = undoYajilin(game); errors = []; message = ""; render(); changed(); });
|
|
143
|
+
add(tools, w.hint, () => {
|
|
144
|
+
const hint = hintYajilin(game);
|
|
145
|
+
if (!hint)
|
|
146
|
+
message = w.bad;
|
|
147
|
+
else {
|
|
148
|
+
game = hint.type === "shade" ? toggleYajilinShade(game, hint.cell) : toggleYajilinEdge(game, hint.edge);
|
|
149
|
+
game = { ...game, helped: true };
|
|
150
|
+
selected = hint.type === "shade" ? hint.cell : selected;
|
|
151
|
+
message = w.good;
|
|
152
|
+
changed();
|
|
153
|
+
}
|
|
154
|
+
render();
|
|
155
|
+
});
|
|
156
|
+
add(tools, w.check, () => { errors = checkYajilin(game.board, game.shaded, game.edges).errors; message = errors.length ? w.bad : w.good; render(); });
|
|
157
|
+
add(tools, w.restart, () => { game = restartYajilin(game); anchor = null; errors = []; message = ""; render(); changed(); });
|
|
158
|
+
status.textContent = checkYajilin(game.board, game.shaded, game.edges).ok ? (game.helped ? w.helped : w.won) : message;
|
|
159
|
+
};
|
|
160
|
+
render();
|
|
161
|
+
return { game: copy, progress: () => encodeYajilin(game), set: next => { options = { ...options, ...next }; render(); }, restart: () => { game = restartYajilin(game); anchor = null; render(); changed(); }, destroy: () => { dead = true; element.replaceChildren(); } };
|
|
162
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type { YajilinDrawOptions as YajilinDrawOptions, YajilinMount as YajilinMount, YajilinMountOptions as YajilinMountOptions } from "./yajilin.types.ts";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { YajilinBoard, YajilinSolve } from "./yajilin.types.ts";
|
|
2
|
+
/** Counts public shade patterns whose remaining cells form the single required loop. */
|
|
3
|
+
export declare function solveYajilin(board: YajilinBoard, options?: {
|
|
4
|
+
limit?: number;
|
|
5
|
+
nodes?: number;
|
|
6
|
+
}): YajilinSolve;
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import { YAJILIN_NODE_BUDGET } from "./yajilin.constants.js";
|
|
2
|
+
import { checkYajilin, isYajilinBoard, yajilinNeighbors, yajilinRay } from "./yajilinBoard.js";
|
|
3
|
+
/** Counts public shade patterns whose remaining cells form the single required loop. */
|
|
4
|
+
export function solveYajilin(board, options = {}) {
|
|
5
|
+
if (!isYajilinBoard(board))
|
|
6
|
+
throw new RangeError("Invalid Yajilin board");
|
|
7
|
+
const limit = options.limit ?? 2, budget = options.nodes ?? YAJILIN_NODE_BUDGET;
|
|
8
|
+
if (!Number.isInteger(limit) || limit < 1 || !Number.isInteger(budget) || budget < 1)
|
|
9
|
+
throw new RangeError("Invalid search bounds");
|
|
10
|
+
const total = board.width * board.height, state = Array(total).fill(-1), shadeable = [];
|
|
11
|
+
const rays = board.clues.flatMap((clue, cell) => clue ? [{ cell, clue, cells: yajilinRay(board, cell, clue.direction) }] : []);
|
|
12
|
+
board.clues.forEach((clue, cell) => { if (clue)
|
|
13
|
+
state[cell] = 2;
|
|
14
|
+
else
|
|
15
|
+
shadeable.push(cell); });
|
|
16
|
+
let count = 0, nodes = 0, complete = true, solution = null;
|
|
17
|
+
const candidateEdges = (shaded) => {
|
|
18
|
+
const edges = [];
|
|
19
|
+
for (let cell = 0; cell < total; cell += 1) {
|
|
20
|
+
if (board.clues[cell] || shaded[cell])
|
|
21
|
+
continue;
|
|
22
|
+
for (const next of yajilinNeighbors(board, cell))
|
|
23
|
+
if (cell < next.cell && !board.clues[next.cell] && !shaded[next.cell])
|
|
24
|
+
edges.push(next.edge);
|
|
25
|
+
}
|
|
26
|
+
return edges;
|
|
27
|
+
};
|
|
28
|
+
const raysPossible = () => rays.every(({ clue, cells }) => {
|
|
29
|
+
const shaded = cells.filter(cell => state[cell] === 1).length;
|
|
30
|
+
const unknown = cells.filter(cell => state[cell] === -1).length;
|
|
31
|
+
return shaded <= clue.count && shaded + unknown >= clue.count;
|
|
32
|
+
});
|
|
33
|
+
const visit = (depth) => {
|
|
34
|
+
if (++nodes > budget) {
|
|
35
|
+
complete = false;
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
if (!raysPossible())
|
|
39
|
+
return;
|
|
40
|
+
if (depth === shadeable.length) {
|
|
41
|
+
const shaded = state.map(value => value === 1), edges = candidateEdges(shaded);
|
|
42
|
+
if (!checkYajilin(board, shaded, edges).ok)
|
|
43
|
+
return;
|
|
44
|
+
count += 1;
|
|
45
|
+
solution ?? (solution = { shaded, edges });
|
|
46
|
+
if (count >= limit)
|
|
47
|
+
complete = false;
|
|
48
|
+
return;
|
|
49
|
+
}
|
|
50
|
+
let chosen = -1, bestScore = -1;
|
|
51
|
+
for (const cell of shadeable) {
|
|
52
|
+
if (state[cell] !== -1)
|
|
53
|
+
continue;
|
|
54
|
+
let score = 0;
|
|
55
|
+
for (const clue of rays)
|
|
56
|
+
if (clue.cells.includes(cell))
|
|
57
|
+
score += 1;
|
|
58
|
+
if (score > bestScore) {
|
|
59
|
+
chosen = cell;
|
|
60
|
+
bestScore = score;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
if (chosen < 0)
|
|
64
|
+
return;
|
|
65
|
+
state[chosen] = 0;
|
|
66
|
+
visit(depth + 1);
|
|
67
|
+
if (!complete) {
|
|
68
|
+
state[chosen] = -1;
|
|
69
|
+
return;
|
|
70
|
+
}
|
|
71
|
+
const x = chosen % board.width, y = Math.floor(chosen / board.width);
|
|
72
|
+
const touchesShade = (x > 0 && state[chosen - 1] === 1) || (x + 1 < board.width && state[chosen + 1] === 1)
|
|
73
|
+
|| (y > 0 && state[chosen - board.width] === 1) || (y + 1 < board.height && state[chosen + board.width] === 1);
|
|
74
|
+
if (!touchesShade) {
|
|
75
|
+
state[chosen] = 1;
|
|
76
|
+
visit(depth + 1);
|
|
77
|
+
}
|
|
78
|
+
state[chosen] = -1;
|
|
79
|
+
};
|
|
80
|
+
visit(0);
|
|
81
|
+
return { count, solution, complete, nodes };
|
|
82
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
export declare const YAJILIN_STRINGS: {
|
|
2
|
+
readonly en: {
|
|
3
|
+
readonly title: "Yajilin";
|
|
4
|
+
readonly help: "Shade the number of cells each arrow points to. Shaded cells cannot touch. Every other empty cell is part of one loop.";
|
|
5
|
+
readonly line: "Line";
|
|
6
|
+
readonly shade: "Shade";
|
|
7
|
+
readonly undo: "Undo";
|
|
8
|
+
readonly hint: "Hint";
|
|
9
|
+
readonly check: "Check";
|
|
10
|
+
readonly restart: "Restart";
|
|
11
|
+
readonly won: "Solved!";
|
|
12
|
+
readonly helped: "Solved with help.";
|
|
13
|
+
readonly good: "Keep going; the loop is not complete yet.";
|
|
14
|
+
readonly bad: "Check the marked cells, arrows, and line.";
|
|
15
|
+
readonly cell: "cell";
|
|
16
|
+
};
|
|
17
|
+
readonly ja: {
|
|
18
|
+
readonly title: "やじりん";
|
|
19
|
+
readonly help: "矢印の先にある黒マスの数を合わせます。黒マスは辺で隣り合えません。残りの空きマスを一つの輪にします。";
|
|
20
|
+
readonly line: "線";
|
|
21
|
+
readonly shade: "黒マス";
|
|
22
|
+
readonly undo: "戻す";
|
|
23
|
+
readonly hint: "ヒント";
|
|
24
|
+
readonly check: "確認";
|
|
25
|
+
readonly restart: "やり直す";
|
|
26
|
+
readonly won: "完成!";
|
|
27
|
+
readonly helped: "ヒントを使って完成。";
|
|
28
|
+
readonly good: "輪はまだ完成していません。続けましょう。";
|
|
29
|
+
readonly bad: "印のついたマス、矢印、線を確認してください。";
|
|
30
|
+
readonly cell: "マス";
|
|
31
|
+
};
|
|
32
|
+
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export const YAJILIN_STRINGS = {
|
|
2
|
+
en: { title: "Yajilin", help: "Shade the number of cells each arrow points to. Shaded cells cannot touch. Every other empty cell is part of one loop.", line: "Line", shade: "Shade", undo: "Undo", hint: "Hint", check: "Check", restart: "Restart", won: "Solved!", helped: "Solved with help.", good: "Keep going; the loop is not complete yet.", bad: "Check the marked cells, arrows, and line.", cell: "cell" },
|
|
3
|
+
ja: { title: "やじりん", help: "矢印の先にある黒マスの数を合わせます。黒マスは辺で隣り合えません。残りの空きマスを一つの輪にします。", line: "線", shade: "黒マス", undo: "戻す", hint: "ヒント", check: "確認", restart: "やり直す", won: "完成!", helped: "ヒントを使って完成。", good: "輪はまだ完成していません。続けましょう。", bad: "印のついたマス、矢印、線を確認してください。", cell: "マス" },
|
|
4
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const YAJILIN_PLAY_STYLE = "\n.kazu-yajilin { color:var(--kz-ink,#1f2320); font:16px/1.4 system-ui,sans-serif; }\n.kazu-yajilin .ky-board { position:relative; max-width:440px; margin:auto; }\n.kazu-yajilin svg { border:1px solid var(--kz-frame,#a98954); border-radius:4px; }\n.kazu-yajilin .ky-cells { position:absolute; inset:6%; display:grid; }\n.kazu-yajilin .ky-cell { border:0; background:transparent; color:transparent; cursor:pointer; }\n.kazu-yajilin .ky-cell:focus-visible { outline:3px solid var(--kz-focus,#c57d2d); outline-offset:-5px; }\n.kazu-yajilin .ky-tools { display:flex; flex-wrap:wrap; gap:.5rem; justify-content:center; margin:.8rem 0; }\n.kazu-yajilin button { font:inherit; padding:.45rem .8rem; }\n.kazu-yajilin .ky-status { min-height:1.5em; text-align:center; }\n.kazu-yajilin .ky-modes [aria-pressed=\"true\"] { outline:2px solid var(--kz-frame,#a98954); }\n";
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export const YAJILIN_PLAY_STYLE = `
|
|
2
|
+
.kazu-yajilin { color:var(--kz-ink,#1f2320); font:16px/1.4 system-ui,sans-serif; }
|
|
3
|
+
.kazu-yajilin .ky-board { position:relative; max-width:440px; margin:auto; }
|
|
4
|
+
.kazu-yajilin svg { border:1px solid var(--kz-frame,#a98954); border-radius:4px; }
|
|
5
|
+
.kazu-yajilin .ky-cells { position:absolute; inset:6%; display:grid; }
|
|
6
|
+
.kazu-yajilin .ky-cell { border:0; background:transparent; color:transparent; cursor:pointer; }
|
|
7
|
+
.kazu-yajilin .ky-cell:focus-visible { outline:3px solid var(--kz-focus,#c57d2d); outline-offset:-5px; }
|
|
8
|
+
.kazu-yajilin .ky-tools { display:flex; flex-wrap:wrap; gap:.5rem; justify-content:center; margin:.8rem 0; }
|
|
9
|
+
.kazu-yajilin button { font:inherit; padding:.45rem .8rem; }
|
|
10
|
+
.kazu-yajilin .ky-status { min-height:1.5em; text-align:center; }
|
|
11
|
+
.kazu-yajilin .ky-modes [aria-pressed="true"] { outline:2px solid var(--kz-frame,#a98954); }
|
|
12
|
+
`;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@johnmorrisdotca/kazu",
|
|
3
|
-
"version": "1.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "1.3.0",
|
|
4
|
+
"description": "Grid number and logic puzzles for JavaScript and TypeScript: Sudoku and its variants, Futoshiki, Skyscrapers, Shikaku, Hitori, Nurikabe, Akari, Juosan, Slitherlink, Masyu, Yajilin, Ripple Effect, Kakuro, Fillomino and Heyawake. Dedicated typed engines, independently checked puzzles, SVG boards and bilingual touch and keyboard players. Zero runtime dependencies.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"puzzle",
|
|
7
7
|
"sudoku",
|
|
@@ -24,7 +24,19 @@
|
|
|
24
24
|
"browser",
|
|
25
25
|
"node",
|
|
26
26
|
"itsutsu",
|
|
27
|
-
"shikaku"
|
|
27
|
+
"shikaku",
|
|
28
|
+
"hitori",
|
|
29
|
+
"nurikabe",
|
|
30
|
+
"akari",
|
|
31
|
+
"light-puzzle",
|
|
32
|
+
"juosan",
|
|
33
|
+
"slitherlink",
|
|
34
|
+
"masyu",
|
|
35
|
+
"yajilin",
|
|
36
|
+
"ripple-effect",
|
|
37
|
+
"kakuro",
|
|
38
|
+
"fillomino",
|
|
39
|
+
"heyawake"
|
|
28
40
|
],
|
|
29
41
|
"homepage": "https://github.com/johnmorrisdotca/kazu#readme",
|
|
30
42
|
"repository": {
|
|
@@ -83,6 +95,171 @@
|
|
|
83
95
|
"types": "./dist/shikaku-draw-entry.d.ts",
|
|
84
96
|
"import": "./dist/shikaku-draw-entry.js",
|
|
85
97
|
"default": "./dist/shikaku-draw-entry.js"
|
|
98
|
+
},
|
|
99
|
+
"./hitori": {
|
|
100
|
+
"types": "./dist/hitori-entry.d.ts",
|
|
101
|
+
"import": "./dist/hitori-entry.js",
|
|
102
|
+
"default": "./dist/hitori-entry.js"
|
|
103
|
+
},
|
|
104
|
+
"./hitori/play": {
|
|
105
|
+
"types": "./dist/hitori-play-entry.d.ts",
|
|
106
|
+
"import": "./dist/hitori-play-entry.js",
|
|
107
|
+
"default": "./dist/hitori-play-entry.js"
|
|
108
|
+
},
|
|
109
|
+
"./hitori/draw": {
|
|
110
|
+
"types": "./dist/hitori-draw-entry.d.ts",
|
|
111
|
+
"import": "./dist/hitori-draw-entry.js",
|
|
112
|
+
"default": "./dist/hitori-draw-entry.js"
|
|
113
|
+
},
|
|
114
|
+
"./nurikabe": {
|
|
115
|
+
"types": "./dist/nurikabe-entry.d.ts",
|
|
116
|
+
"import": "./dist/nurikabe-entry.js",
|
|
117
|
+
"default": "./dist/nurikabe-entry.js"
|
|
118
|
+
},
|
|
119
|
+
"./nurikabe/play": {
|
|
120
|
+
"types": "./dist/nurikabe-play-entry.d.ts",
|
|
121
|
+
"import": "./dist/nurikabe-play-entry.js",
|
|
122
|
+
"default": "./dist/nurikabe-play-entry.js"
|
|
123
|
+
},
|
|
124
|
+
"./nurikabe/draw": {
|
|
125
|
+
"types": "./dist/nurikabe-draw-entry.d.ts",
|
|
126
|
+
"import": "./dist/nurikabe-draw-entry.js",
|
|
127
|
+
"default": "./dist/nurikabe-draw-entry.js"
|
|
128
|
+
},
|
|
129
|
+
"./akari": {
|
|
130
|
+
"types": "./dist/akari-entry.d.ts",
|
|
131
|
+
"import": "./dist/akari-entry.js",
|
|
132
|
+
"default": "./dist/akari-entry.js"
|
|
133
|
+
},
|
|
134
|
+
"./akari/play": {
|
|
135
|
+
"types": "./dist/akari-play-entry.d.ts",
|
|
136
|
+
"import": "./dist/akari-play-entry.js",
|
|
137
|
+
"default": "./dist/akari-play-entry.js"
|
|
138
|
+
},
|
|
139
|
+
"./akari/draw": {
|
|
140
|
+
"types": "./dist/akari-draw-entry.d.ts",
|
|
141
|
+
"import": "./dist/akari-draw-entry.js",
|
|
142
|
+
"default": "./dist/akari-draw-entry.js"
|
|
143
|
+
},
|
|
144
|
+
"./juosan": {
|
|
145
|
+
"types": "./dist/juosan-entry.d.ts",
|
|
146
|
+
"import": "./dist/juosan-entry.js",
|
|
147
|
+
"default": "./dist/juosan-entry.js"
|
|
148
|
+
},
|
|
149
|
+
"./juosan/play": {
|
|
150
|
+
"types": "./dist/juosan-play-entry.d.ts",
|
|
151
|
+
"import": "./dist/juosan-play-entry.js",
|
|
152
|
+
"default": "./dist/juosan-play-entry.js"
|
|
153
|
+
},
|
|
154
|
+
"./juosan/draw": {
|
|
155
|
+
"types": "./dist/juosan-draw-entry.d.ts",
|
|
156
|
+
"import": "./dist/juosan-draw-entry.js",
|
|
157
|
+
"default": "./dist/juosan-draw-entry.js"
|
|
158
|
+
},
|
|
159
|
+
"./slitherlink": {
|
|
160
|
+
"types": "./dist/slitherlink-entry.d.ts",
|
|
161
|
+
"import": "./dist/slitherlink-entry.js",
|
|
162
|
+
"default": "./dist/slitherlink-entry.js"
|
|
163
|
+
},
|
|
164
|
+
"./slitherlink/play": {
|
|
165
|
+
"types": "./dist/slitherlink-play-entry.d.ts",
|
|
166
|
+
"import": "./dist/slitherlink-play-entry.js",
|
|
167
|
+
"default": "./dist/slitherlink-play-entry.js"
|
|
168
|
+
},
|
|
169
|
+
"./slitherlink/draw": {
|
|
170
|
+
"types": "./dist/slitherlink-draw-entry.d.ts",
|
|
171
|
+
"import": "./dist/slitherlink-draw-entry.js",
|
|
172
|
+
"default": "./dist/slitherlink-draw-entry.js"
|
|
173
|
+
},
|
|
174
|
+
"./masyu": {
|
|
175
|
+
"types": "./dist/masyu-entry.d.ts",
|
|
176
|
+
"import": "./dist/masyu-entry.js",
|
|
177
|
+
"default": "./dist/masyu-entry.js"
|
|
178
|
+
},
|
|
179
|
+
"./masyu/play": {
|
|
180
|
+
"types": "./dist/masyu-play-entry.d.ts",
|
|
181
|
+
"import": "./dist/masyu-play-entry.js",
|
|
182
|
+
"default": "./dist/masyu-play-entry.js"
|
|
183
|
+
},
|
|
184
|
+
"./masyu/draw": {
|
|
185
|
+
"types": "./dist/masyu-draw-entry.d.ts",
|
|
186
|
+
"import": "./dist/masyu-draw-entry.js",
|
|
187
|
+
"default": "./dist/masyu-draw-entry.js"
|
|
188
|
+
},
|
|
189
|
+
"./yajilin": {
|
|
190
|
+
"types": "./dist/yajilin-entry.d.ts",
|
|
191
|
+
"import": "./dist/yajilin-entry.js",
|
|
192
|
+
"default": "./dist/yajilin-entry.js"
|
|
193
|
+
},
|
|
194
|
+
"./yajilin/play": {
|
|
195
|
+
"types": "./dist/yajilin-play-entry.d.ts",
|
|
196
|
+
"import": "./dist/yajilin-play-entry.js",
|
|
197
|
+
"default": "./dist/yajilin-play-entry.js"
|
|
198
|
+
},
|
|
199
|
+
"./yajilin/draw": {
|
|
200
|
+
"types": "./dist/yajilin-draw-entry.d.ts",
|
|
201
|
+
"import": "./dist/yajilin-draw-entry.js",
|
|
202
|
+
"default": "./dist/yajilin-draw-entry.js"
|
|
203
|
+
},
|
|
204
|
+
"./ripple": {
|
|
205
|
+
"types": "./dist/ripple-entry.d.ts",
|
|
206
|
+
"import": "./dist/ripple-entry.js",
|
|
207
|
+
"default": "./dist/ripple-entry.js"
|
|
208
|
+
},
|
|
209
|
+
"./ripple/play": {
|
|
210
|
+
"types": "./dist/ripple-play-entry.d.ts",
|
|
211
|
+
"import": "./dist/ripple-play-entry.js",
|
|
212
|
+
"default": "./dist/ripple-play-entry.js"
|
|
213
|
+
},
|
|
214
|
+
"./ripple/draw": {
|
|
215
|
+
"types": "./dist/ripple-draw-entry.d.ts",
|
|
216
|
+
"import": "./dist/ripple-draw-entry.js",
|
|
217
|
+
"default": "./dist/ripple-draw-entry.js"
|
|
218
|
+
},
|
|
219
|
+
"./kakuro": {
|
|
220
|
+
"types": "./dist/kakuro-entry.d.ts",
|
|
221
|
+
"import": "./dist/kakuro-entry.js",
|
|
222
|
+
"default": "./dist/kakuro-entry.js"
|
|
223
|
+
},
|
|
224
|
+
"./kakuro/play": {
|
|
225
|
+
"types": "./dist/kakuro-play-entry.d.ts",
|
|
226
|
+
"import": "./dist/kakuro-play-entry.js",
|
|
227
|
+
"default": "./dist/kakuro-play-entry.js"
|
|
228
|
+
},
|
|
229
|
+
"./kakuro/draw": {
|
|
230
|
+
"types": "./dist/kakuro-draw-entry.d.ts",
|
|
231
|
+
"import": "./dist/kakuro-draw-entry.js",
|
|
232
|
+
"default": "./dist/kakuro-draw-entry.js"
|
|
233
|
+
},
|
|
234
|
+
"./fillomino": {
|
|
235
|
+
"types": "./dist/fillomino-entry.d.ts",
|
|
236
|
+
"import": "./dist/fillomino-entry.js",
|
|
237
|
+
"default": "./dist/fillomino-entry.js"
|
|
238
|
+
},
|
|
239
|
+
"./fillomino/play": {
|
|
240
|
+
"types": "./dist/fillomino-play-entry.d.ts",
|
|
241
|
+
"import": "./dist/fillomino-play-entry.js",
|
|
242
|
+
"default": "./dist/fillomino-play-entry.js"
|
|
243
|
+
},
|
|
244
|
+
"./fillomino/draw": {
|
|
245
|
+
"types": "./dist/fillomino-draw-entry.d.ts",
|
|
246
|
+
"import": "./dist/fillomino-draw-entry.js",
|
|
247
|
+
"default": "./dist/fillomino-draw-entry.js"
|
|
248
|
+
},
|
|
249
|
+
"./heyawake": {
|
|
250
|
+
"types": "./dist/heyawake-entry.d.ts",
|
|
251
|
+
"import": "./dist/heyawake-entry.js",
|
|
252
|
+
"default": "./dist/heyawake-entry.js"
|
|
253
|
+
},
|
|
254
|
+
"./heyawake/play": {
|
|
255
|
+
"types": "./dist/heyawake-play-entry.d.ts",
|
|
256
|
+
"import": "./dist/heyawake-play-entry.js",
|
|
257
|
+
"default": "./dist/heyawake-play-entry.js"
|
|
258
|
+
},
|
|
259
|
+
"./heyawake/draw": {
|
|
260
|
+
"types": "./dist/heyawake-draw-entry.d.ts",
|
|
261
|
+
"import": "./dist/heyawake-draw-entry.js",
|
|
262
|
+
"default": "./dist/heyawake-draw-entry.js"
|
|
86
263
|
}
|
|
87
264
|
},
|
|
88
265
|
"files": [
|