@dxos/plugin-chess 0.8.3 → 0.8.4-main.1c7ec43d41
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/dist/lib/browser/blueprints/index.mjs +14 -0
- package/dist/lib/browser/blueprints/index.mjs.map +7 -0
- package/dist/lib/browser/chunk-5FHUZILG.mjs +63 -0
- package/dist/lib/browser/chunk-5FHUZILG.mjs.map +7 -0
- package/dist/lib/browser/chunk-BCTL5GYK.mjs +88 -0
- package/dist/lib/browser/chunk-BCTL5GYK.mjs.map +7 -0
- package/dist/lib/browser/chunk-J5LGTIGS.mjs +10 -0
- package/dist/lib/browser/chunk-J5LGTIGS.mjs.map +7 -0
- package/dist/lib/browser/chunk-ORLWKOYE.mjs +26 -0
- package/dist/lib/browser/chunk-ORLWKOYE.mjs.map +7 -0
- package/dist/lib/browser/chunk-YER5TC5N.mjs +35 -0
- package/dist/lib/browser/chunk-YER5TC5N.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +31 -86
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/move-BH3WZUJH.mjs +39 -0
- package/dist/lib/browser/move-BH3WZUJH.mjs.map +7 -0
- package/dist/lib/browser/operations/index.mjs +17 -0
- package/dist/lib/browser/operations/index.mjs.map +7 -0
- package/dist/lib/browser/play-IM4BDFSY.mjs +48 -0
- package/dist/lib/browser/play-IM4BDFSY.mjs.map +7 -0
- package/dist/lib/browser/print-M3ZO2XZT.mjs +30 -0
- package/dist/lib/browser/print-M3ZO2XZT.mjs.map +7 -0
- package/dist/lib/browser/translations.mjs +34 -0
- package/dist/lib/browser/translations.mjs.map +7 -0
- package/dist/lib/browser/types/index.mjs +4 -9
- package/dist/lib/node-esm/blueprints/index.mjs +15 -0
- package/dist/lib/node-esm/blueprints/index.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-A3P4HC7O.mjs +89 -0
- package/dist/lib/node-esm/chunk-A3P4HC7O.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-B42KRPBJ.mjs +37 -0
- package/dist/lib/node-esm/chunk-B42KRPBJ.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-HSLMI22Q.mjs +11 -0
- package/dist/lib/node-esm/chunk-HSLMI22Q.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-WSHXDK3W.mjs +27 -0
- package/dist/lib/node-esm/chunk-WSHXDK3W.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-YRW4LYGF.mjs +64 -0
- package/dist/lib/node-esm/chunk-YRW4LYGF.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +31 -86
- package/dist/lib/node-esm/index.mjs.map +4 -4
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/move-53HLCSAL.mjs +40 -0
- package/dist/lib/node-esm/move-53HLCSAL.mjs.map +7 -0
- package/dist/lib/node-esm/operations/index.mjs +18 -0
- package/dist/lib/node-esm/operations/index.mjs.map +7 -0
- package/dist/lib/node-esm/play-YXXPG5SO.mjs +49 -0
- package/dist/lib/node-esm/play-YXXPG5SO.mjs.map +7 -0
- package/dist/lib/node-esm/print-L2LUM3IW.mjs +31 -0
- package/dist/lib/node-esm/print-L2LUM3IW.mjs.map +7 -0
- package/dist/lib/node-esm/translations.mjs +35 -0
- package/dist/lib/node-esm/translations.mjs.map +7 -0
- package/dist/lib/node-esm/types/index.mjs +4 -9
- package/dist/types/src/ChessPlugin.d.ts +3 -1
- package/dist/types/src/ChessPlugin.d.ts.map +1 -1
- package/dist/types/src/ChessPlugin.node.d.ts +8 -0
- package/dist/types/src/ChessPlugin.node.d.ts.map +1 -0
- package/dist/types/src/ChessPlugin.test.d.ts +2 -0
- package/dist/types/src/ChessPlugin.test.d.ts.map +1 -0
- package/dist/types/src/blueprints/chess-blueprint.d.ts +4 -0
- package/dist/types/src/blueprints/chess-blueprint.d.ts.map +1 -0
- package/dist/types/src/blueprints/index.d.ts +3 -0
- package/dist/types/src/blueprints/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/blueprint-definition.d.ts +6 -0
- package/dist/types/src/capabilities/blueprint-definition.d.ts.map +1 -0
- package/dist/types/src/capabilities/game-variant.d.ts +6 -0
- package/dist/types/src/capabilities/game-variant.d.ts.map +1 -0
- package/dist/types/src/capabilities/index.d.ts +5 -3
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/node.d.ts +10 -0
- package/dist/types/src/capabilities/node.d.ts.map +1 -0
- package/dist/types/src/capabilities/operation-handler.d.ts +6 -0
- package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -0
- package/dist/types/src/components/Chessboard/Chessboard.d.ts +38 -0
- package/dist/types/src/components/Chessboard/Chessboard.d.ts.map +1 -0
- package/dist/types/src/components/Chessboard/Chessboard.stories.d.ts +57 -0
- package/dist/types/src/components/Chessboard/Chessboard.stories.d.ts.map +1 -0
- package/dist/types/src/components/Chessboard/Info.d.ts +20 -0
- package/dist/types/src/components/Chessboard/Info.d.ts.map +1 -0
- package/dist/types/src/components/Chessboard/index.d.ts +2 -0
- package/dist/types/src/components/Chessboard/index.d.ts.map +1 -0
- package/dist/types/src/components/Chessboard/types.d.ts +8 -0
- package/dist/types/src/components/Chessboard/types.d.ts.map +1 -0
- package/dist/types/src/components/index.d.ts +1 -5
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/containers/ChessArticle/ChessArticle.d.ts +5 -0
- package/dist/types/src/containers/ChessArticle/ChessArticle.d.ts.map +1 -0
- package/dist/types/src/containers/ChessArticle/ChessArticle.stories.d.ts +56 -0
- package/dist/types/src/containers/ChessArticle/ChessArticle.stories.d.ts.map +1 -0
- package/dist/types/src/containers/ChessArticle/index.d.ts +2 -0
- package/dist/types/src/containers/ChessArticle/index.d.ts.map +1 -0
- package/dist/types/src/containers/ChessCard/ChessCard.d.ts +5 -0
- package/dist/types/src/containers/ChessCard/ChessCard.d.ts.map +1 -0
- package/dist/types/src/containers/ChessCard/ChessCard.stories.d.ts +15 -0
- package/dist/types/src/containers/ChessCard/ChessCard.stories.d.ts.map +1 -0
- package/dist/types/src/containers/ChessCard/index.d.ts +2 -0
- package/dist/types/src/containers/ChessCard/index.d.ts.map +1 -0
- package/dist/types/src/containers/index.d.ts +4 -0
- package/dist/types/src/containers/index.d.ts.map +1 -0
- package/dist/types/src/index.d.ts +4 -3
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +2 -3
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/operations/definitions.d.ts +24 -0
- package/dist/types/src/operations/definitions.d.ts.map +1 -0
- package/dist/types/src/operations/index.d.ts +4 -0
- package/dist/types/src/operations/index.d.ts.map +1 -0
- package/dist/types/src/operations/move.d.ts +5 -0
- package/dist/types/src/operations/move.d.ts.map +1 -0
- package/dist/types/src/operations/play.d.ts +5 -0
- package/dist/types/src/operations/play.d.ts.map +1 -0
- package/dist/types/src/operations/print.d.ts +5 -0
- package/dist/types/src/operations/print.d.ts.map +1 -0
- package/dist/types/src/translations.d.ts +34 -23
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types/Chess.d.ts +18 -0
- package/dist/types/src/types/Chess.d.ts.map +1 -0
- package/dist/types/src/types/index.d.ts +1 -2
- package/dist/types/src/types/index.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +86 -42
- package/src/ChessPlugin.node.ts +23 -0
- package/src/ChessPlugin.test.ts +49 -0
- package/src/ChessPlugin.tsx +20 -54
- package/src/blueprints/chess-blueprint.ts +33 -0
- package/src/blueprints/index.ts +6 -0
- package/src/capabilities/blueprint-definition.ts +19 -0
- package/src/capabilities/game-variant.ts +42 -0
- package/src/capabilities/index.ts +9 -4
- package/src/capabilities/node.ts +18 -0
- package/src/capabilities/operation-handler.ts +14 -0
- package/src/components/Chessboard/Chessboard.stories.tsx +94 -0
- package/src/components/Chessboard/Chessboard.tsx +180 -0
- package/src/components/Chessboard/Info.tsx +193 -0
- package/src/components/Chessboard/index.ts +5 -0
- package/src/components/Chessboard/types.ts +18 -0
- package/src/components/index.ts +2 -6
- package/src/containers/ChessArticle/ChessArticle.stories.tsx +59 -0
- package/src/containers/ChessArticle/ChessArticle.tsx +108 -0
- package/src/containers/ChessArticle/index.ts +5 -0
- package/src/containers/ChessCard/ChessCard.stories.tsx +47 -0
- package/src/containers/ChessCard/ChessCard.tsx +27 -0
- package/src/containers/ChessCard/index.ts +5 -0
- package/src/containers/index.ts +8 -0
- package/src/index.ts +7 -3
- package/src/meta.ts +9 -7
- package/src/operations/definitions.ts +83 -0
- package/src/operations/index.ts +15 -0
- package/src/operations/move.ts +37 -0
- package/src/operations/play.ts +46 -0
- package/src/operations/print.ts +28 -0
- package/src/translations.ts +22 -14
- package/src/types/Chess.ts +59 -0
- package/src/types/index.ts +1 -2
- package/dist/lib/browser/ChessContainer-S72CLKGK.mjs +0 -101
- package/dist/lib/browser/ChessContainer-S72CLKGK.mjs.map +0 -7
- package/dist/lib/browser/artifact-definition-NLIDMZ42.mjs +0 -182
- package/dist/lib/browser/artifact-definition-NLIDMZ42.mjs.map +0 -7
- package/dist/lib/browser/chunk-5QBQW62M.mjs +0 -8
- package/dist/lib/browser/chunk-5QBQW62M.mjs.map +0 -7
- package/dist/lib/browser/chunk-6XPI4FTK.mjs +0 -61
- package/dist/lib/browser/chunk-6XPI4FTK.mjs.map +0 -7
- package/dist/lib/browser/chunk-KA3H3Z76.mjs +0 -65
- package/dist/lib/browser/chunk-KA3H3Z76.mjs.map +0 -7
- package/dist/lib/browser/intent-resolver-65W3KVTW.mjs +0 -28
- package/dist/lib/browser/intent-resolver-65W3KVTW.mjs.map +0 -7
- package/dist/lib/browser/react-surface-GYE5E74A.mjs +0 -42
- package/dist/lib/browser/react-surface-GYE5E74A.mjs.map +0 -7
- package/dist/lib/node/ChessContainer-EQUVXDJC.cjs +0 -123
- package/dist/lib/node/ChessContainer-EQUVXDJC.cjs.map +0 -7
- package/dist/lib/node/artifact-definition-VHJ54X2P.cjs +0 -196
- package/dist/lib/node/artifact-definition-VHJ54X2P.cjs.map +0 -7
- package/dist/lib/node/chunk-OTMP6HPY.cjs +0 -93
- package/dist/lib/node/chunk-OTMP6HPY.cjs.map +0 -7
- package/dist/lib/node/chunk-R6JAL3RE.cjs +0 -40
- package/dist/lib/node/chunk-R6JAL3RE.cjs.map +0 -7
- package/dist/lib/node/chunk-THN2FKB3.cjs +0 -86
- package/dist/lib/node/chunk-THN2FKB3.cjs.map +0 -7
- package/dist/lib/node/index.cjs +0 -121
- package/dist/lib/node/index.cjs.map +0 -7
- package/dist/lib/node/intent-resolver-BQGAQM27.cjs +0 -43
- package/dist/lib/node/intent-resolver-BQGAQM27.cjs.map +0 -7
- package/dist/lib/node/meta.json +0 -1
- package/dist/lib/node/react-surface-TZDWBTEY.cjs +0 -62
- package/dist/lib/node/react-surface-TZDWBTEY.cjs.map +0 -7
- package/dist/lib/node/types/index.cjs +0 -35
- package/dist/lib/node/types/index.cjs.map +0 -7
- package/dist/lib/node-esm/ChessContainer-KSLGJHPW.mjs +0 -102
- package/dist/lib/node-esm/ChessContainer-KSLGJHPW.mjs.map +0 -7
- package/dist/lib/node-esm/artifact-definition-CZGGG56Q.mjs +0 -183
- package/dist/lib/node-esm/artifact-definition-CZGGG56Q.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-4V3WNUDH.mjs +0 -67
- package/dist/lib/node-esm/chunk-4V3WNUDH.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-KHMDMPR2.mjs +0 -10
- package/dist/lib/node-esm/chunk-KHMDMPR2.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-MVMMCPHE.mjs +0 -63
- package/dist/lib/node-esm/chunk-MVMMCPHE.mjs.map +0 -7
- package/dist/lib/node-esm/intent-resolver-6TYVNVEU.mjs +0 -29
- package/dist/lib/node-esm/intent-resolver-6TYVNVEU.mjs.map +0 -7
- package/dist/lib/node-esm/react-surface-LRFYFOFF.mjs +0 -43
- package/dist/lib/node-esm/react-surface-LRFYFOFF.mjs.map +0 -7
- package/dist/types/src/capabilities/artifact-definition.d.ts +0 -11
- package/dist/types/src/capabilities/artifact-definition.d.ts.map +0 -1
- package/dist/types/src/capabilities/intent-resolver.d.ts +0 -4
- package/dist/types/src/capabilities/intent-resolver.d.ts.map +0 -1
- package/dist/types/src/capabilities/react-surface.d.ts +0 -4
- package/dist/types/src/capabilities/react-surface.d.ts.map +0 -1
- package/dist/types/src/components/ChessComponent.d.ts +0 -6
- package/dist/types/src/components/ChessComponent.d.ts.map +0 -1
- package/dist/types/src/components/ChessContainer.d.ts +0 -8
- package/dist/types/src/components/ChessContainer.d.ts.map +0 -1
- package/dist/types/src/components/ChessPanel.d.ts +0 -11
- package/dist/types/src/components/ChessPanel.d.ts.map +0 -1
- package/dist/types/src/components/Chessboard.stories.d.ts +0 -8
- package/dist/types/src/components/Chessboard.stories.d.ts.map +0 -1
- package/dist/types/src/components/PlayerSelector.d.ts +0 -8
- package/dist/types/src/components/PlayerSelector.d.ts.map +0 -1
- package/dist/types/src/types/schema.d.ts +0 -29
- package/dist/types/src/types/schema.d.ts.map +0 -1
- package/dist/types/src/types/types.d.ts +0 -40
- package/dist/types/src/types/types.d.ts.map +0 -1
- package/src/capabilities/artifact-definition.ts +0 -124
- package/src/capabilities/intent-resolver.ts +0 -26
- package/src/capabilities/react-surface.tsx +0 -29
- package/src/components/ChessComponent.tsx +0 -54
- package/src/components/ChessContainer.tsx +0 -35
- package/src/components/ChessPanel.tsx +0 -67
- package/src/components/Chessboard.stories.tsx +0 -39
- package/src/components/PlayerSelector.tsx +0 -80
- package/src/types/schema.ts +0 -34
- package/src/types/types.ts +0 -26
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/capabilities/artifact-definition.ts"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Chess } from 'chess.js';\nimport { pipe, Schema } from 'effect';\n\nimport { createTool, ToolResult } from '@dxos/ai';\nimport { Capabilities, chain, contributes, createIntent, type PromiseIntentDispatcher } from '@dxos/app-framework';\nimport { ArtifactId, defineArtifact } from '@dxos/artifact';\nimport { createArtifactElement, VersionPin } from '@dxos/assistant';\nimport { Obj } from '@dxos/echo';\nimport { invariant } from '@dxos/invariant';\nimport { SpaceAction } from '@dxos/plugin-space/types';\nimport { Filter, type Space } from '@dxos/react-client/echo';\n\nimport { meta } from '../meta';\nimport { ChessAction, ChessType } from '../types';\n\n// TODO(burdon): Factor out.\ndeclare global {\n interface ToolContextExtensions {\n space?: Space;\n dispatch?: PromiseIntentDispatcher;\n }\n}\n\nexport default () => {\n const definition = defineArtifact({\n id: `artifact:${meta.id}`,\n name: meta.name,\n description: 'Provides a simple chess engine.',\n instructions: `\n - If the user's message relates to a chess game, you must return the chess game inside the artifact tag as a valid FEN string with no additional text.\n - Always inspect the chess game at the start of every prompt realting to a chess game, as it might have changed since the interaction.\n `,\n schema: ChessType,\n tools: [\n createTool(meta.id, {\n name: 'create',\n description: 'Create a new chess game. Returns the artifact definition for the game.',\n caption: 'Creating chess game...',\n schema: Schema.Struct({\n fen: Schema.String.annotations({ description: 'The state of the chess game in the FEN format.' }),\n }),\n execute: async ({ fen }, { extensions }) => {\n invariant(extensions?.space, 'No space');\n invariant(extensions?.dispatch, 'No intent dispatcher');\n const intent = pipe(\n createIntent(ChessAction.Create, { fen }),\n chain(SpaceAction.AddObject, { target: extensions.space }),\n );\n const { data, error } = await extensions.dispatch(intent);\n if (!data || error) {\n return ToolResult.Error(error?.message ?? 'Failed to create chess game');\n }\n\n return ToolResult.Success(createArtifactElement(data.id), [\n VersionPin.createBlock(VersionPin.fromObject(data.object)),\n ]);\n },\n }),\n createTool(meta.id, {\n name: 'list',\n description: 'Query all active chess games.',\n caption: 'Getting games...',\n schema: Schema.Struct({}),\n execute: async (_, { extensions }) => {\n invariant(extensions?.space, 'No space');\n const { objects: games } = await extensions.space.db.query(Filter.type(ChessType)).run();\n invariant(games.length > 0, 'No chess games found');\n\n return ToolResult.Success(games);\n },\n }),\n createTool(meta.id, {\n name: 'inspect',\n description: 'Get the current state of the chess game.',\n caption: 'Inspecting game...',\n schema: Schema.Struct({ id: ArtifactId }),\n execute: async ({ id }, { extensions }) => {\n invariant(extensions?.space, 'No space');\n const game = await extensions.space.db\n .query(Filter.ids(ArtifactId.toDXN(id, extensions.space.id).toString()))\n .first();\n invariant(Obj.instanceOf(ChessType, game));\n\n return ToolResult.Success(game.fen);\n },\n }),\n createTool(meta.id, {\n name: 'move',\n description: 'Make a move in the chess game.',\n caption: 'Making chess move...',\n schema: Schema.Struct({\n id: ArtifactId,\n move: Schema.String.annotations({\n description: 'The move to make in the chess game.',\n examples: ['e4', 'Bf3'],\n }),\n }),\n execute: async ({ id, move }, { extensions }) => {\n invariant(extensions?.space, 'No space');\n const game = await extensions.space.db\n .query(Filter.ids(ArtifactId.toDXN(id, extensions.space.id).toString()))\n .first();\n invariant(Obj.instanceOf(ChessType, game));\n\n const board = new Chess(game.fen);\n try {\n board.move(move);\n } catch (error: any) {\n return ToolResult.Error(error.message);\n }\n game.pgn = board.pgn();\n game.fen = board.fen();\n return ToolResult.Success(game.fen);\n },\n }),\n ],\n });\n\n return contributes(Capabilities.ArtifactDefinition, definition);\n};\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAIA,mBAAsB;AACtB,oBAA6B;AAE7B,gBAAuC;AACvC,2BAA6F;AAC7F,sBAA2C;AAC3C,uBAAkD;AAClD,kBAAoB;AACpB,uBAA0B;AAC1B,mBAA4B;AAC5B,IAAAA,eAAmC;;AAanC,IAAA,8BAAe,MAAA;AACb,QAAMC,iBAAaC,gCAAe;IAChCC,IAAI,YAAYC,2BAAKD,EAAE;IACvBE,MAAMD,2BAAKC;IACXC,aAAa;IACbC,cAAc;;;;IAIdC,QAAQC;IACRC,OAAO;UACLC,sBAAWP,2BAAKD,IAAI;QAClBE,MAAM;QACNC,aAAa;QACbM,SAAS;QACTJ,QAAQK,qBAAOC,OAAO;UACpBC,KAAKF,qBAAOG,OAAOC,YAAY;YAAEX,aAAa;UAAiD,CAAA;QACjG,CAAA;QACAY,SAAS,OAAO,EAAEH,IAAG,GAAI,EAAEI,WAAU,MAAE;AACrCC,0CAAUD,YAAYE,OAAO,YAAA;;;;;;;;;AAC7BD,0CAAUD,YAAYG,UAAU,wBAAA;;;;;;;;;AAChC,gBAAMC,aAASC,wBACbC,mCAAaC,kCAAYC,QAAQ;YAAEZ;UAAI,CAAA,OACvCa,4BAAMC,yBAAYC,WAAW;YAAEC,QAAQZ,WAAWE;UAAM,CAAA,CAAA;AAE1D,gBAAM,EAAEW,MAAMC,MAAK,IAAK,MAAMd,WAAWG,SAASC,MAAAA;AAClD,cAAI,CAACS,QAAQC,OAAO;AAClB,mBAAOC,qBAAWC,MAAMF,OAAOG,WAAW,6BAAA;UAC5C;AAEA,iBAAOF,qBAAWG,YAAQC,wCAAsBN,KAAK7B,EAAE,GAAG;YACxDoC,4BAAWC,YAAYD,4BAAWE,WAAWT,KAAKU,MAAM,CAAA;WACzD;QACH;MACF,CAAA;UACA/B,sBAAWP,2BAAKD,IAAI;QAClBE,MAAM;QACNC,aAAa;QACbM,SAAS;QACTJ,QAAQK,qBAAOC,OAAO,CAAC,CAAA;QACvBI,SAAS,OAAOyB,GAAG,EAAExB,WAAU,MAAE;AAC/BC,0CAAUD,YAAYE,OAAO,YAAA;;;;;;;;;AAC7B,gBAAM,EAAEuB,SAASC,MAAK,IAAK,MAAM1B,WAAWE,MAAMyB,GAAGC,MAAMC,oBAAOC,KAAKxC,+BAAAA,CAAAA,EAAYyC,IAAG;AACtF9B,0CAAUyB,MAAMM,SAAS,GAAG,wBAAA;;;;;;;;;AAE5B,iBAAOjB,qBAAWG,QAAQQ,KAAAA;QAC5B;MACF,CAAA;UACAlC,sBAAWP,2BAAKD,IAAI;QAClBE,MAAM;QACNC,aAAa;QACbM,SAAS;QACTJ,QAAQK,qBAAOC,OAAO;UAAEX,IAAIiD;QAAW,CAAA;QACvClC,SAAS,OAAO,EAAEf,GAAE,GAAI,EAAEgB,WAAU,MAAE;AACpCC,0CAAUD,YAAYE,OAAO,YAAA;;;;;;;;;AAC7B,gBAAMgC,OAAO,MAAMlC,WAAWE,MAAMyB,GACjCC,MAAMC,oBAAOM,IAAIF,2BAAWG,MAAMpD,IAAIgB,WAAWE,MAAMlB,EAAE,EAAEqD,SAAQ,CAAA,CAAA,EACnEC,MAAK;AACRrC,0CAAUsC,gBAAIC,WAAWlD,iCAAW4C,IAAAA,GAAAA,QAAAA;;;;;;;;;AAEpC,iBAAOnB,qBAAWG,QAAQgB,KAAKtC,GAAG;QACpC;MACF,CAAA;UACAJ,sBAAWP,2BAAKD,IAAI;QAClBE,MAAM;QACNC,aAAa;QACbM,SAAS;QACTJ,QAAQK,qBAAOC,OAAO;UACpBX,IAAIiD;UACJQ,MAAM/C,qBAAOG,OAAOC,YAAY;YAC9BX,aAAa;YACbuD,UAAU;cAAC;cAAM;;UACnB,CAAA;QACF,CAAA;QACA3C,SAAS,OAAO,EAAEf,IAAIyD,KAAI,GAAI,EAAEzC,WAAU,MAAE;AAC1CC,0CAAUD,YAAYE,OAAO,YAAA;;;;;;;;;AAC7B,gBAAMgC,OAAO,MAAMlC,WAAWE,MAAMyB,GACjCC,MAAMC,oBAAOM,IAAIF,2BAAWG,MAAMpD,IAAIgB,WAAWE,MAAMlB,EAAE,EAAEqD,SAAQ,CAAA,CAAA,EACnEC,MAAK;AACRrC,0CAAUsC,gBAAIC,WAAWlD,iCAAW4C,IAAAA,GAAAA,QAAAA;;;;;;;;;AAEpC,gBAAMS,QAAQ,IAAIC,mBAAMV,KAAKtC,GAAG;AAChC,cAAI;AACF+C,kBAAMF,KAAKA,IAAAA;UACb,SAAS3B,OAAY;AACnB,mBAAOC,qBAAWC,MAAMF,MAAMG,OAAO;UACvC;AACAiB,eAAKW,MAAMF,MAAME,IAAG;AACpBX,eAAKtC,MAAM+C,MAAM/C,IAAG;AACpB,iBAAOmB,qBAAWG,QAAQgB,KAAKtC,GAAG;QACpC;MACF,CAAA;;EAEJ,CAAA;AAEA,aAAOkD,kCAAYC,kCAAaC,oBAAoBlE,UAAAA;AACtD;",
|
|
6
|
-
"names": ["import_echo", "definition", "defineArtifact", "id", "meta", "name", "description", "instructions", "schema", "ChessType", "tools", "createTool", "caption", "Schema", "Struct", "fen", "String", "annotations", "execute", "extensions", "invariant", "space", "dispatch", "intent", "pipe", "createIntent", "ChessAction", "Create", "chain", "SpaceAction", "AddObject", "target", "data", "error", "ToolResult", "Error", "message", "Success", "createArtifactElement", "VersionPin", "createBlock", "fromObject", "object", "_", "objects", "games", "db", "query", "Filter", "type", "run", "length", "ArtifactId", "game", "ids", "toDXN", "toString", "first", "Obj", "instanceOf", "move", "examples", "board", "Chess", "pgn", "contributes", "Capabilities", "ArtifactDefinition"]
|
|
7
|
-
}
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
|
-
var __copyProps = (to, from, except, desc) => {
|
|
13
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
-
for (let key of __getOwnPropNames(from))
|
|
15
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
-
}
|
|
18
|
-
return to;
|
|
19
|
-
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var chunk_OTMP6HPY_exports = {};
|
|
30
|
-
__export(chunk_OTMP6HPY_exports, {
|
|
31
|
-
ChessComponent: () => ChessComponent
|
|
32
|
-
});
|
|
33
|
-
module.exports = __toCommonJS(chunk_OTMP6HPY_exports);
|
|
34
|
-
var import_tracking = require("@preact-signals/safe-react/tracking");
|
|
35
|
-
var import_chess = require("chess.js");
|
|
36
|
-
var import_react = __toESM(require("react"));
|
|
37
|
-
var import_log = require("@dxos/log");
|
|
38
|
-
var import_echo = require("@dxos/react-client/echo");
|
|
39
|
-
var import_react_ui_gameboard = require("@dxos/react-ui-gameboard");
|
|
40
|
-
var __dxlog_file = "/home/runner/work/dxos/dxos/packages/plugins/plugin-chess/src/components/ChessComponent.tsx";
|
|
41
|
-
var ChessComponent = ({ game }) => {
|
|
42
|
-
var _effect = (0, import_tracking.useSignals)();
|
|
43
|
-
try {
|
|
44
|
-
const model = (0, import_react.useMemo)(() => new import_react_ui_gameboard.ChessModel(), []);
|
|
45
|
-
(0, import_react.useEffect)(() => {
|
|
46
|
-
if (!model || game.pgn !== model?.game.pgn()) {
|
|
47
|
-
const chess = new import_chess.Chess();
|
|
48
|
-
if (game.pgn) {
|
|
49
|
-
try {
|
|
50
|
-
chess.loadPgn(game.pgn);
|
|
51
|
-
} catch (err) {
|
|
52
|
-
import_log.log.catch(err, {
|
|
53
|
-
game
|
|
54
|
-
}, {
|
|
55
|
-
F: __dxlog_file,
|
|
56
|
-
L: 23,
|
|
57
|
-
S: void 0,
|
|
58
|
-
C: (f, a) => f(...a)
|
|
59
|
-
});
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
model.initialize(chess.fen());
|
|
63
|
-
}
|
|
64
|
-
}, [
|
|
65
|
-
game.pgn
|
|
66
|
-
]);
|
|
67
|
-
const space = (0, import_echo.getSpace)(game);
|
|
68
|
-
if (!space) {
|
|
69
|
-
return null;
|
|
70
|
-
}
|
|
71
|
-
const handleDrop = (0, import_react.useCallback)((move) => {
|
|
72
|
-
if (model.makeMove(move)) {
|
|
73
|
-
game.pgn = model.game.pgn();
|
|
74
|
-
game.fen = model.game.fen();
|
|
75
|
-
return true;
|
|
76
|
-
}
|
|
77
|
-
return false;
|
|
78
|
-
}, [
|
|
79
|
-
model
|
|
80
|
-
]);
|
|
81
|
-
return /* @__PURE__ */ import_react.default.createElement(import_react_ui_gameboard.Board.Root, {
|
|
82
|
-
model,
|
|
83
|
-
onDrop: handleDrop
|
|
84
|
-
}, /* @__PURE__ */ import_react.default.createElement(import_react_ui_gameboard.Chessboard, null));
|
|
85
|
-
} finally {
|
|
86
|
-
_effect.f();
|
|
87
|
-
}
|
|
88
|
-
};
|
|
89
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
90
|
-
0 && (module.exports = {
|
|
91
|
-
ChessComponent
|
|
92
|
-
});
|
|
93
|
-
//# sourceMappingURL=chunk-OTMP6HPY.cjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/components/ChessComponent.tsx"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { Chess } from 'chess.js';\nimport React, { useCallback, useEffect, useMemo } from 'react';\n\nimport { log } from '@dxos/log';\nimport { getSpace } from '@dxos/react-client/echo';\nimport { ChessModel, Board, Chessboard, type BoardRootProps } from '@dxos/react-ui-gameboard';\n\nimport { type ChessType } from '../types';\n\nexport const ChessComponent = ({ game }: { game: ChessType }) => {\n const model = useMemo(() => new ChessModel(), []);\n useEffect(() => {\n if (!model || game.pgn !== model?.game.pgn()) {\n const chess = new Chess();\n if (game.pgn) {\n try {\n chess.loadPgn(game.pgn);\n } catch (err) {\n log.catch(err, { game });\n }\n }\n\n model.initialize(chess.fen());\n }\n }, [game.pgn]);\n\n const space = getSpace(game);\n if (!space) {\n return null;\n }\n\n const handleDrop = useCallback<NonNullable<BoardRootProps['onDrop']>>(\n (move) => {\n if (model.makeMove(move)) {\n game.pgn = model.game.pgn();\n game.fen = model.game.fen();\n return true;\n }\n\n return false;\n },\n [model],\n );\n\n return (\n <Board.Root model={model} onDrop={handleDrop}>\n <Chessboard />\n </Board.Root>\n );\n};\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,mBAAsB;AACtB,mBAAuD;AAEvD,iBAAoB;AACpB,kBAAyB;AACzB,gCAAmE;;AAI5D,IAAMA,iBAAiB,CAAC,EAAEC,KAAI,MAAuB;;;AAC1D,UAAMC,YAAQC,sBAAQ,MAAM,IAAIC,qCAAAA,GAAc,CAAA,CAAE;AAChDC,gCAAU,MAAA;AACR,UAAI,CAACH,SAASD,KAAKK,QAAQJ,OAAOD,KAAKK,IAAAA,GAAO;AAC5C,cAAMC,QAAQ,IAAIC,mBAAAA;AAClB,YAAIP,KAAKK,KAAK;AACZ,cAAI;AACFC,kBAAME,QAAQR,KAAKK,GAAG;UACxB,SAASI,KAAK;AACZC,2BAAIC,MAAMF,KAAK;cAAET;YAAK,GAAA;;;;;;UACxB;QACF;AAEAC,cAAMW,WAAWN,MAAMO,IAAG,CAAA;MAC5B;IACF,GAAG;MAACb,KAAKK;KAAI;AAEb,UAAMS,YAAQC,sBAASf,IAAAA;AACvB,QAAI,CAACc,OAAO;AACV,aAAO;IACT;AAEA,UAAME,iBAAaC,0BACjB,CAACC,SAAAA;AACC,UAAIjB,MAAMkB,SAASD,IAAAA,GAAO;AACxBlB,aAAKK,MAAMJ,MAAMD,KAAKK,IAAG;AACzBL,aAAKa,MAAMZ,MAAMD,KAAKa,IAAG;AACzB,eAAO;MACT;AAEA,aAAO;IACT,GACA;MAACZ;KAAM;AAGT,WACE,6BAAAmB,QAAA,cAACC,gCAAMC,MAAI;MAACrB;MAAcsB,QAAQP;OAChC,6BAAAI,QAAA,cAACI,sCAAAA,IAAAA,CAAAA;;;;AAGP;",
|
|
6
|
-
"names": ["ChessComponent", "game", "model", "useMemo", "ChessModel", "useEffect", "pgn", "chess", "Chess", "loadPgn", "err", "log", "catch", "initialize", "fen", "space", "getSpace", "handleDrop", "useCallback", "move", "makeMove", "React", "Board", "Root", "onDrop", "Chessboard"]
|
|
7
|
-
}
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
|
-
var __copyProps = (to, from, except, desc) => {
|
|
13
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
-
for (let key of __getOwnPropNames(from))
|
|
15
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
-
}
|
|
18
|
-
return to;
|
|
19
|
-
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var chunk_R6JAL3RE_exports = {};
|
|
30
|
-
__export(chunk_R6JAL3RE_exports, {
|
|
31
|
-
ChessContainer: () => ChessContainer
|
|
32
|
-
});
|
|
33
|
-
module.exports = __toCommonJS(chunk_R6JAL3RE_exports);
|
|
34
|
-
var import_react = require("react");
|
|
35
|
-
var ChessContainer = (0, import_react.lazy)(() => import("./ChessContainer-EQUVXDJC.cjs"));
|
|
36
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
37
|
-
0 && (module.exports = {
|
|
38
|
-
ChessContainer
|
|
39
|
-
});
|
|
40
|
-
//# sourceMappingURL=chunk-R6JAL3RE.cjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/components/index.ts"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { lazy } from 'react';\n\nexport * from './ChessComponent';\n\nexport const ChessContainer = lazy(() => import('./ChessContainer'));\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,mBAAqB;AAId,IAAMA,qBAAiBC,mBAAK,MAAM,OAAO,+BAAA,CAAA;",
|
|
6
|
-
"names": ["ChessContainer", "lazy"]
|
|
7
|
-
}
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var chunk_THN2FKB3_exports = {};
|
|
20
|
-
__export(chunk_THN2FKB3_exports, {
|
|
21
|
-
CHESS_PLUGIN: () => CHESS_PLUGIN,
|
|
22
|
-
ChessAction: () => ChessAction,
|
|
23
|
-
ChessType: () => ChessType,
|
|
24
|
-
MoveSchema: () => MoveSchema,
|
|
25
|
-
isObject: () => isObject,
|
|
26
|
-
meta: () => meta
|
|
27
|
-
});
|
|
28
|
-
module.exports = __toCommonJS(chunk_THN2FKB3_exports);
|
|
29
|
-
var import_effect = require("effect");
|
|
30
|
-
var import_echo = require("@dxos/echo");
|
|
31
|
-
var import_effect2 = require("effect");
|
|
32
|
-
var import_echo2 = require("@dxos/echo");
|
|
33
|
-
var MoveSchema = import_effect.Schema.mutable(import_effect.Schema.partial(import_effect.Schema.Struct({
|
|
34
|
-
source: import_effect.Schema.String,
|
|
35
|
-
target: import_effect.Schema.String,
|
|
36
|
-
piece: import_effect.Schema.String
|
|
37
|
-
})));
|
|
38
|
-
var ChessType = import_effect.Schema.Struct({
|
|
39
|
-
name: import_effect.Schema.optional(import_effect.Schema.String),
|
|
40
|
-
playerWhite: import_effect.Schema.String,
|
|
41
|
-
playerBlack: import_effect.Schema.String,
|
|
42
|
-
moves: import_effect.Schema.mutable(import_effect.Schema.Array(import_effect.Schema.String)),
|
|
43
|
-
// TODO(wittjosiah): Remove. Redundant with moves.
|
|
44
|
-
pgn: import_effect.Schema.String,
|
|
45
|
-
fen: import_effect.Schema.String
|
|
46
|
-
}).pipe(import_effect.Schema.partial, import_echo.Type.Obj({
|
|
47
|
-
typename: "dxos.org/type/Chess",
|
|
48
|
-
version: "0.1.0"
|
|
49
|
-
}));
|
|
50
|
-
var CHESS_PLUGIN = "dxos.org/plugin/chess";
|
|
51
|
-
var meta = {
|
|
52
|
-
id: CHESS_PLUGIN,
|
|
53
|
-
name: "Chess",
|
|
54
|
-
description: "Chess is a simple plugin which allows you to render an interactive chessboard inside of a plank. This chessboard can be used for collaborative chess games, or for practice experiments with the LLM. ",
|
|
55
|
-
icon: "ph--shield-chevron--regular",
|
|
56
|
-
source: "https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-chess",
|
|
57
|
-
screenshots: [
|
|
58
|
-
"https://dxos.network/plugin-details-chess-dark.png"
|
|
59
|
-
]
|
|
60
|
-
};
|
|
61
|
-
(function(ChessAction2) {
|
|
62
|
-
const CHESS_ACTION = `${CHESS_PLUGIN}/action`;
|
|
63
|
-
class Create extends import_effect2.Schema.TaggedClass()(`${CHESS_ACTION}/create`, {
|
|
64
|
-
input: import_effect2.Schema.Struct({
|
|
65
|
-
name: import_effect2.Schema.optional(import_effect2.Schema.String),
|
|
66
|
-
fen: import_effect2.Schema.optional(import_effect2.Schema.String)
|
|
67
|
-
}),
|
|
68
|
-
output: import_effect2.Schema.Struct({
|
|
69
|
-
object: ChessType
|
|
70
|
-
})
|
|
71
|
-
}) {
|
|
72
|
-
}
|
|
73
|
-
ChessAction2.Create = Create;
|
|
74
|
-
})(ChessAction || (ChessAction = {}));
|
|
75
|
-
var isObject = import_echo2.Obj.instanceOf(ChessType);
|
|
76
|
-
var ChessAction;
|
|
77
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
78
|
-
0 && (module.exports = {
|
|
79
|
-
CHESS_PLUGIN,
|
|
80
|
-
ChessAction,
|
|
81
|
-
ChessType,
|
|
82
|
-
MoveSchema,
|
|
83
|
-
isObject,
|
|
84
|
-
meta
|
|
85
|
-
});
|
|
86
|
-
//# sourceMappingURL=chunk-THN2FKB3.cjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/types/schema.ts", "../../../src/types/types.ts", "../../../src/meta.ts"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { Schema } from 'effect';\n\nimport { Type } from '@dxos/echo';\n\nexport const MoveSchema = Schema.mutable(\n Schema.partial(\n Schema.Struct({\n source: Schema.String,\n target: Schema.String,\n piece: Schema.String,\n }),\n ),\n);\n\nexport const ChessType = Schema.Struct({\n name: Schema.optional(Schema.String),\n playerWhite: Schema.String,\n playerBlack: Schema.String,\n moves: Schema.mutable(Schema.Array(Schema.String)),\n // TODO(wittjosiah): Remove. Redundant with moves.\n pgn: Schema.String,\n fen: Schema.String,\n}).pipe(\n Schema.partial,\n Type.Obj({\n typename: 'dxos.org/type/Chess',\n version: '0.1.0',\n }),\n);\nexport interface ChessType extends Schema.Schema.Type<typeof ChessType> {}\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { Schema } from 'effect';\n\nimport { Obj } from '@dxos/echo';\n\nimport { ChessType } from './schema';\nimport { CHESS_PLUGIN } from '../meta';\n\nexport namespace ChessAction {\n const CHESS_ACTION = `${CHESS_PLUGIN}/action`;\n\n export class Create extends Schema.TaggedClass<Create>()(`${CHESS_ACTION}/create`, {\n input: Schema.Struct({\n name: Schema.optional(Schema.String),\n fen: Schema.optional(Schema.String),\n }),\n output: Schema.Struct({\n object: ChessType,\n }),\n }) {}\n}\n\nexport const isObject = Obj.instanceOf(ChessType);\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { type PluginMeta } from '@dxos/app-framework';\n\nexport const CHESS_PLUGIN = 'dxos.org/plugin/chess';\n\nexport const meta: PluginMeta = {\n id: CHESS_PLUGIN,\n name: 'Chess',\n description:\n 'Chess is a simple plugin which allows you to render an interactive chessboard inside of a plank. This chessboard can be used for collaborative chess games, or for practice experiments with the LLM. ',\n icon: 'ph--shield-chevron--regular',\n source: 'https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-chess',\n screenshots: ['https://dxos.network/plugin-details-chess-dark.png'],\n};\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,oBAAuB;AAEvB,kBAAqB;ACFrB,IAAAA,iBAAuB;AAEvB,IAAAC,eAAoB;ADEb,IAAMC,aAAaC,qBAAOC,QAC/BD,qBAAOE,QACLF,qBAAOG,OAAO;EACZC,QAAQJ,qBAAOK;EACfC,QAAQN,qBAAOK;EACfE,OAAOP,qBAAOK;AAChB,CAAA,CAAA,CAAA;AAIG,IAAMG,YAAYR,qBAAOG,OAAO;EACrCM,MAAMT,qBAAOU,SAASV,qBAAOK,MAAM;EACnCM,aAAaX,qBAAOK;EACpBO,aAAaZ,qBAAOK;EACpBQ,OAAOb,qBAAOC,QAAQD,qBAAOc,MAAMd,qBAAOK,MAAM,CAAA;;EAEhDU,KAAKf,qBAAOK;EACZW,KAAKhB,qBAAOK;AACd,CAAA,EAAGY,KACDjB,qBAAOE,SACPgB,iBAAKC,IAAI;EACPC,UAAU;EACVC,SAAS;AACX,CAAA,CAAA;AEzBK,IAAMC,eAAe;AAErB,IAAMC,OAAmB;EAC9BC,IAAIF;EACJb,MAAM;EACNgB,aACE;EACFC,MAAM;EACNtB,QAAQ;EACRuB,aAAa;IAAC;;AAChB;UDLiBC,cAAAA;AACf,QAAMC,eAAe,GAAGP,YAAAA;EAEjB,MAAMQ,eAAe9B,eAAAA,OAAO+B,YAAW,EAAW,GAAGF,YAAAA,WAAuB;IACjFG,OAAOhC,eAAAA,OAAOG,OAAO;MACnBM,MAAMT,eAAAA,OAAOU,SAASV,eAAAA,OAAOK,MAAM;MACnCW,KAAKhB,eAAAA,OAAOU,SAASV,eAAAA,OAAOK,MAAM;IACpC,CAAA;IACA4B,QAAQjC,eAAAA,OAAOG,OAAO;MACpB+B,QAAQ1B;IACV,CAAA;EACF,CAAA,EAAA;EAAI;eARSsB,SAAAA;AASf,GAZiBF,gBAAAA,cAAAA,CAAAA,EAAAA;AAcV,IAAMO,WAAWhB,iBAAIiB,WAAW5B,SAAAA;;",
|
|
6
|
-
"names": ["import_effect", "import_echo", "MoveSchema", "Schema", "mutable", "partial", "Struct", "source", "String", "target", "piece", "ChessType", "name", "optional", "playerWhite", "playerBlack", "moves", "Array", "pgn", "fen", "pipe", "Type", "Obj", "typename", "version", "CHESS_PLUGIN", "meta", "id", "description", "icon", "screenshots", "ChessAction", "CHESS_ACTION", "Create", "TaggedClass", "input", "output", "object", "isObject", "instanceOf"]
|
|
7
|
-
}
|
package/dist/lib/node/index.cjs
DELETED
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
|
-
var __copyProps = (to, from, except, desc) => {
|
|
13
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
-
for (let key of __getOwnPropNames(from))
|
|
15
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
-
}
|
|
18
|
-
return to;
|
|
19
|
-
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var node_exports = {};
|
|
30
|
-
__export(node_exports, {
|
|
31
|
-
ArtifactDefinition: () => ArtifactDefinition,
|
|
32
|
-
CHESS_PLUGIN: () => import_chunk_THN2FKB3.CHESS_PLUGIN,
|
|
33
|
-
ChessComponent: () => import_chunk_OTMP6HPY.ChessComponent,
|
|
34
|
-
ChessContainer: () => import_chunk_R6JAL3RE.ChessContainer,
|
|
35
|
-
ChessPlugin: () => ChessPlugin,
|
|
36
|
-
IntentResolver: () => IntentResolver,
|
|
37
|
-
ReactSurface: () => ReactSurface,
|
|
38
|
-
meta: () => import_chunk_THN2FKB3.meta
|
|
39
|
-
});
|
|
40
|
-
module.exports = __toCommonJS(node_exports);
|
|
41
|
-
var import_chunk_R6JAL3RE = require("./chunk-R6JAL3RE.cjs");
|
|
42
|
-
var import_chunk_THN2FKB3 = require("./chunk-THN2FKB3.cjs");
|
|
43
|
-
var import_chunk_OTMP6HPY = require("./chunk-OTMP6HPY.cjs");
|
|
44
|
-
var import_app_framework = require("@dxos/app-framework");
|
|
45
|
-
var import_app_framework2 = require("@dxos/app-framework");
|
|
46
|
-
var import_plugin_client = require("@dxos/plugin-client");
|
|
47
|
-
var import_plugin_space = require("@dxos/plugin-space");
|
|
48
|
-
var import_types = require("@dxos/plugin-space/types");
|
|
49
|
-
var import_echo = require("@dxos/echo");
|
|
50
|
-
var ArtifactDefinition = (0, import_app_framework.lazy)(() => import("./artifact-definition-VHJ54X2P.cjs"));
|
|
51
|
-
var IntentResolver = (0, import_app_framework.lazy)(() => import("./intent-resolver-BQGAQM27.cjs"));
|
|
52
|
-
var ReactSurface = (0, import_app_framework.lazy)(() => import("./react-surface-TZDWBTEY.cjs"));
|
|
53
|
-
var translations_default = [
|
|
54
|
-
{
|
|
55
|
-
"en-US": {
|
|
56
|
-
[import_echo.Type.getTypename(import_chunk_THN2FKB3.ChessType)]: {
|
|
57
|
-
"typename label": "Game",
|
|
58
|
-
"typename label_zero": "Games",
|
|
59
|
-
"typename label_one": "Game",
|
|
60
|
-
"typename label_other": "Games",
|
|
61
|
-
"object name placeholder": "New game"
|
|
62
|
-
},
|
|
63
|
-
[import_chunk_THN2FKB3.CHESS_PLUGIN]: {
|
|
64
|
-
"plugin name": "Chess",
|
|
65
|
-
"delete game label": "Delete"
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
];
|
|
70
|
-
var ChessPlugin = () => (0, import_app_framework2.definePlugin)(import_chunk_THN2FKB3.meta, [
|
|
71
|
-
(0, import_app_framework2.defineModule)({
|
|
72
|
-
id: `${import_chunk_THN2FKB3.meta.id}/module/translations`,
|
|
73
|
-
activatesOn: import_app_framework2.Events.SetupTranslations,
|
|
74
|
-
activate: () => (0, import_app_framework2.contributes)(import_app_framework2.Capabilities.Translations, translations_default)
|
|
75
|
-
}),
|
|
76
|
-
(0, import_app_framework2.defineModule)({
|
|
77
|
-
id: `${import_chunk_THN2FKB3.meta.id}/module/metadata`,
|
|
78
|
-
activatesOn: import_app_framework2.Events.SetupMetadata,
|
|
79
|
-
activate: () => (0, import_app_framework2.contributes)(import_app_framework2.Capabilities.Metadata, {
|
|
80
|
-
id: import_chunk_THN2FKB3.ChessType.typename,
|
|
81
|
-
metadata: {
|
|
82
|
-
icon: "ph--shield-chevron--regular"
|
|
83
|
-
}
|
|
84
|
-
})
|
|
85
|
-
}),
|
|
86
|
-
(0, import_app_framework2.defineModule)({
|
|
87
|
-
id: `${import_chunk_THN2FKB3.meta.id}/module/object-form`,
|
|
88
|
-
activatesOn: import_plugin_client.ClientEvents.SetupSchema,
|
|
89
|
-
activate: () => (0, import_app_framework2.contributes)(import_plugin_space.SpaceCapabilities.ObjectForm, (0, import_types.defineObjectForm)({
|
|
90
|
-
objectSchema: import_chunk_THN2FKB3.ChessType,
|
|
91
|
-
getIntent: () => (0, import_app_framework2.createIntent)(import_chunk_THN2FKB3.ChessAction.Create)
|
|
92
|
-
}))
|
|
93
|
-
}),
|
|
94
|
-
(0, import_app_framework2.defineModule)({
|
|
95
|
-
id: `${import_chunk_THN2FKB3.meta.id}/module/react-surface`,
|
|
96
|
-
activatesOn: import_app_framework2.Events.SetupReactSurface,
|
|
97
|
-
activate: ReactSurface
|
|
98
|
-
}),
|
|
99
|
-
(0, import_app_framework2.defineModule)({
|
|
100
|
-
id: `${import_chunk_THN2FKB3.meta.id}/module/intent-resolver`,
|
|
101
|
-
activatesOn: import_app_framework2.Events.SetupIntentResolver,
|
|
102
|
-
activate: IntentResolver
|
|
103
|
-
}),
|
|
104
|
-
(0, import_app_framework2.defineModule)({
|
|
105
|
-
id: `${import_chunk_THN2FKB3.meta.id}/module/artifact-definition`,
|
|
106
|
-
activatesOn: import_app_framework2.Events.SetupArtifactDefinition,
|
|
107
|
-
activate: ArtifactDefinition
|
|
108
|
-
})
|
|
109
|
-
]);
|
|
110
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
111
|
-
0 && (module.exports = {
|
|
112
|
-
ArtifactDefinition,
|
|
113
|
-
CHESS_PLUGIN,
|
|
114
|
-
ChessComponent,
|
|
115
|
-
ChessContainer,
|
|
116
|
-
ChessPlugin,
|
|
117
|
-
IntentResolver,
|
|
118
|
-
ReactSurface,
|
|
119
|
-
meta
|
|
120
|
-
});
|
|
121
|
-
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/capabilities/index.ts", "../../../src/ChessPlugin.tsx", "../../../src/translations.ts"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { lazy } from '@dxos/app-framework';\n\nexport const ArtifactDefinition = lazy(() => import('./artifact-definition'));\nexport const IntentResolver = lazy(() => import('./intent-resolver'));\nexport const ReactSurface = lazy(() => import('./react-surface'));\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { Capabilities, contributes, createIntent, defineModule, definePlugin, Events } from '@dxos/app-framework';\nimport { ClientEvents } from '@dxos/plugin-client';\nimport { SpaceCapabilities } from '@dxos/plugin-space';\nimport { defineObjectForm } from '@dxos/plugin-space/types';\n\nimport { ArtifactDefinition, IntentResolver, ReactSurface } from './capabilities';\nimport { meta } from './meta';\nimport translations from './translations';\nimport { ChessAction, ChessType } from './types';\n\nexport const ChessPlugin = () =>\n definePlugin(meta, [\n defineModule({\n id: `${meta.id}/module/translations`,\n activatesOn: Events.SetupTranslations,\n activate: () => contributes(Capabilities.Translations, translations),\n }),\n defineModule({\n id: `${meta.id}/module/metadata`,\n activatesOn: Events.SetupMetadata,\n activate: () =>\n contributes(Capabilities.Metadata, {\n id: ChessType.typename,\n metadata: {\n icon: 'ph--shield-chevron--regular',\n },\n }),\n }),\n defineModule({\n id: `${meta.id}/module/object-form`,\n activatesOn: ClientEvents.SetupSchema,\n activate: () =>\n contributes(\n SpaceCapabilities.ObjectForm,\n defineObjectForm({\n objectSchema: ChessType,\n getIntent: () => createIntent(ChessAction.Create),\n }),\n ),\n }),\n defineModule({\n id: `${meta.id}/module/react-surface`,\n activatesOn: Events.SetupReactSurface,\n activate: ReactSurface,\n }),\n defineModule({\n id: `${meta.id}/module/intent-resolver`,\n activatesOn: Events.SetupIntentResolver,\n activate: IntentResolver,\n }),\n defineModule({\n id: `${meta.id}/module/artifact-definition`,\n activatesOn: Events.SetupArtifactDefinition,\n activate: ArtifactDefinition,\n }),\n ]);\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { Type } from '@dxos/echo';\n\nimport { CHESS_PLUGIN } from './meta';\nimport { ChessType } from './types';\n\nexport default [\n {\n 'en-US': {\n [Type.getTypename(ChessType)]: {\n 'typename label': 'Game',\n 'typename label_zero': 'Games',\n 'typename label_one': 'Game',\n 'typename label_other': 'Games',\n 'object name placeholder': 'New game',\n },\n [CHESS_PLUGIN]: {\n 'plugin name': 'Chess',\n 'delete game label': 'Delete',\n },\n },\n },\n];\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,2BAAqB;ACArB,IAAAA,wBAA4F;AAC5F,2BAA6B;AAC7B,0BAAkC;AAClC,mBAAiC;ACHjC,kBAAqB;AFEd,IAAMC,yBAAqBC,2BAAK,MAAM,OAAO,oCAAA,CAAA;AAC7C,IAAMC,qBAAiBD,2BAAK,MAAM,OAAO,gCAAA,CAAA;AACzC,IAAME,mBAAeF,2BAAK,MAAM,OAAO,8BAAA,CAAA;AEC9C,IAAA,uBAAe;EACb;IACE,SAAS;MACP,CAACG,iBAAKC,YAAYC,+BAAAA,CAAAA,GAAa;QAC7B,kBAAkB;QAClB,uBAAuB;QACvB,sBAAsB;QACtB,wBAAwB;QACxB,2BAA2B;MAC7B;MACA,CAACC,kCAAAA,GAAe;QACd,eAAe;QACf,qBAAqB;MACvB;IACF;EACF;;ADVK,IAAMC,cAAc,UACzBC,oCAAaC,4BAAM;MACjBC,oCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,6BAAOC;IACpBC,UAAU,UAAMC,mCAAYC,mCAAaC,cAAcC,oBAAAA;EACzD,CAAA;MACAT,oCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,6BAAOO;IACpBL,UAAU,UACRC,mCAAYC,mCAAaI,UAAU;MACjCV,IAAIN,gCAAUiB;MACdC,UAAU;QACRC,MAAM;MACR;IACF,CAAA;EACJ,CAAA;MACAd,oCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaa,kCAAaC;IAC1BX,UAAU,UACRC,mCACEW,sCAAkBC,gBAClBC,+BAAiB;MACfC,cAAczB;MACd0B,WAAW,UAAMC,oCAAaC,kCAAYC,MAAM;IAClD,CAAA,CAAA;EAEN,CAAA;MACAxB,oCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,6BAAOsB;IACpBpB,UAAUb;EACZ,CAAA;MACAQ,oCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,6BAAOuB;IACpBrB,UAAUd;EACZ,CAAA;MACAS,oCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,6BAAOwB;IACpBtB,UAAUhB;EACZ,CAAA;CACD;",
|
|
6
|
-
"names": ["import_app_framework", "ArtifactDefinition", "lazy", "IntentResolver", "ReactSurface", "Type", "getTypename", "ChessType", "CHESS_PLUGIN", "ChessPlugin", "definePlugin", "meta", "defineModule", "id", "activatesOn", "Events", "SetupTranslations", "activate", "contributes", "Capabilities", "Translations", "translations", "SetupMetadata", "Metadata", "typename", "metadata", "icon", "ClientEvents", "SetupSchema", "SpaceCapabilities", "ObjectForm", "defineObjectForm", "objectSchema", "getIntent", "createIntent", "ChessAction", "Create", "SetupReactSurface", "SetupIntentResolver", "SetupArtifactDefinition"]
|
|
7
|
-
}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var intent_resolver_BQGAQM27_exports = {};
|
|
20
|
-
__export(intent_resolver_BQGAQM27_exports, {
|
|
21
|
-
default: () => intent_resolver_default
|
|
22
|
-
});
|
|
23
|
-
module.exports = __toCommonJS(intent_resolver_BQGAQM27_exports);
|
|
24
|
-
var import_chunk_THN2FKB3 = require("./chunk-THN2FKB3.cjs");
|
|
25
|
-
var import_chess = require("chess.js");
|
|
26
|
-
var import_app_framework = require("@dxos/app-framework");
|
|
27
|
-
var import_echo = require("@dxos/echo");
|
|
28
|
-
var intent_resolver_default = () => (0, import_app_framework.contributes)(import_app_framework.Capabilities.IntentResolver, (0, import_app_framework.createResolver)({
|
|
29
|
-
intent: import_chunk_THN2FKB3.ChessAction.Create,
|
|
30
|
-
resolve: ({ name, fen }) => {
|
|
31
|
-
const pgn = fen ? new import_chess.Chess(fen).pgn() : void 0;
|
|
32
|
-
return {
|
|
33
|
-
data: {
|
|
34
|
-
object: import_echo.Obj.make(import_chunk_THN2FKB3.ChessType, {
|
|
35
|
-
name,
|
|
36
|
-
fen,
|
|
37
|
-
pgn
|
|
38
|
-
})
|
|
39
|
-
}
|
|
40
|
-
};
|
|
41
|
-
}
|
|
42
|
-
}));
|
|
43
|
-
//# sourceMappingURL=intent-resolver-BQGAQM27.cjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/capabilities/intent-resolver.ts"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Chess } from 'chess.js';\n\nimport { Capabilities, contributes, createResolver } from '@dxos/app-framework';\nimport { Obj } from '@dxos/echo';\n\nimport { ChessAction, ChessType } from '../types';\n\nexport default () =>\n contributes(\n Capabilities.IntentResolver,\n createResolver({\n intent: ChessAction.Create,\n resolve: ({ name, fen }) => {\n const pgn = fen ? new Chess(fen).pgn() : undefined;\n return {\n data: {\n object: Obj.make(ChessType, { name, fen, pgn }),\n },\n };\n },\n }),\n );\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAIA,mBAAsB;AAEtB,2BAA0D;AAC1D,kBAAoB;AAIpB,IAAA,0BAAe,UACbA,kCACEC,kCAAaC,oBACbC,qCAAe;EACbC,QAAQC,kCAAYC;EACpBC,SAAS,CAAC,EAAEC,MAAMC,IAAG,MAAE;AACrB,UAAMC,MAAMD,MAAM,IAAIE,mBAAMF,GAAAA,EAAKC,IAAG,IAAKE;AACzC,WAAO;MACLC,MAAM;QACJC,QAAQC,gBAAIC,KAAKC,iCAAW;UAAET;UAAMC;UAAKC;QAAI,CAAA;MAC/C;IACF;EACF;AACF,CAAA,CAAA;",
|
|
6
|
-
"names": ["contributes", "Capabilities", "IntentResolver", "createResolver", "intent", "ChessAction", "Create", "resolve", "name", "fen", "pgn", "Chess", "undefined", "data", "object", "Obj", "make", "ChessType"]
|
|
7
|
-
}
|
package/dist/lib/node/meta.json
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"inputs":{"packages/plugins/plugin-chess/src/meta.ts":{"bytes":2033,"imports":[],"format":"esm"},"packages/plugins/plugin-chess/src/types/schema.ts":{"bytes":3044,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-chess/src/types/types.ts":{"bytes":2702,"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/types/schema.ts","kind":"import-statement","original":"./schema"},{"path":"packages/plugins/plugin-chess/src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"packages/plugins/plugin-chess/src/types/index.ts":{"bytes":554,"imports":[{"path":"packages/plugins/plugin-chess/src/types/schema.ts","kind":"import-statement","original":"./schema"},{"path":"packages/plugins/plugin-chess/src/types/types.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-chess/src/capabilities/artifact-definition.ts":{"bytes":19082,"imports":[{"path":"chess.js","kind":"import-statement","external":true},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/ai","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/artifact","kind":"import-statement","external":true},{"path":"@dxos/assistant","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-chess/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-chess/src/capabilities/intent-resolver.ts":{"bytes":2692,"imports":[{"path":"chess.js","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-chess/src/components/ChessComponent.tsx":{"bytes":5508,"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"chess.js","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui-gameboard","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-chess/src/components/PlayerSelector.tsx":{"bytes":9084,"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/display-name","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-chess/src/components/ChessContainer.tsx":{"bytes":3431,"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/components/ChessComponent.tsx","kind":"import-statement","original":"./ChessComponent"},{"path":"packages/plugins/plugin-chess/src/components/PlayerSelector.tsx","kind":"import-statement","original":"./PlayerSelector"}],"format":"esm"},"packages/plugins/plugin-chess/src/components/index.ts":{"bytes":872,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/components/ChessComponent.tsx","kind":"import-statement","original":"./ChessComponent"},{"path":"packages/plugins/plugin-chess/src/components/ChessContainer.tsx","kind":"dynamic-import","original":"./ChessContainer"}],"format":"esm"},"packages/plugins/plugin-chess/src/capabilities/react-surface.tsx":{"bytes":3766,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/components/index.ts","kind":"import-statement","original":"../components"},{"path":"packages/plugins/plugin-chess/src/components/ChessComponent.tsx","kind":"import-statement","original":"../components/ChessComponent"},{"path":"packages/plugins/plugin-chess/src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-chess/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-chess/src/capabilities/index.ts":{"bytes":1329,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/capabilities/artifact-definition.ts","kind":"dynamic-import","original":"./artifact-definition"},{"path":"packages/plugins/plugin-chess/src/capabilities/intent-resolver.ts","kind":"dynamic-import","original":"./intent-resolver"},{"path":"packages/plugins/plugin-chess/src/capabilities/react-surface.tsx","kind":"dynamic-import","original":"./react-surface"}],"format":"esm"},"packages/plugins/plugin-chess/src/translations.ts":{"bytes":2169,"imports":[{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-chess/src/types/index.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-chess/src/ChessPlugin.tsx":{"bytes":7256,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"packages/plugins/plugin-chess/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-chess/src/translations.ts","kind":"import-statement","original":"./translations"},{"path":"packages/plugins/plugin-chess/src/types/index.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-chess/src/index.ts":{"bytes":754,"imports":[{"path":"packages/plugins/plugin-chess/src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"packages/plugins/plugin-chess/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/plugins/plugin-chess/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-chess/src/ChessPlugin.tsx","kind":"import-statement","original":"./ChessPlugin"}],"format":"esm"}},"outputs":{"packages/plugins/plugin-chess/dist/lib/node/index.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":5094},"packages/plugins/plugin-chess/dist/lib/node/index.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-R6JAL3RE.cjs","kind":"import-statement"},{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-THN2FKB3.cjs","kind":"import-statement"},{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-OTMP6HPY.cjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/dist/lib/node/artifact-definition-VHJ54X2P.cjs","kind":"dynamic-import"},{"path":"packages/plugins/plugin-chess/dist/lib/node/intent-resolver-BQGAQM27.cjs","kind":"dynamic-import"},{"path":"packages/plugins/plugin-chess/dist/lib/node/react-surface-TZDWBTEY.cjs","kind":"dynamic-import"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true}],"exports":["ArtifactDefinition","CHESS_PLUGIN","ChessComponent","ChessContainer","ChessPlugin","IntentResolver","ReactSurface","meta"],"entryPoint":"packages/plugins/plugin-chess/src/index.ts","inputs":{"packages/plugins/plugin-chess/src/capabilities/index.ts":{"bytesInOutput":273},"packages/plugins/plugin-chess/src/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-chess/src/ChessPlugin.tsx":{"bytesInOutput":1500},"packages/plugins/plugin-chess/src/translations.ts":{"bytesInOutput":445}},"bytes":2822},"packages/plugins/plugin-chess/dist/lib/node/types/index.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"packages/plugins/plugin-chess/dist/lib/node/types/index.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-THN2FKB3.cjs","kind":"import-statement"}],"exports":["ChessAction","ChessType","MoveSchema","isObject"],"entryPoint":"packages/plugins/plugin-chess/src/types/index.ts","inputs":{},"bytes":194},"packages/plugins/plugin-chess/dist/lib/node/artifact-definition-VHJ54X2P.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":8478},"packages/plugins/plugin-chess/dist/lib/node/artifact-definition-VHJ54X2P.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-THN2FKB3.cjs","kind":"import-statement"},{"path":"chess.js","kind":"import-statement","external":true},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/ai","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/artifact","kind":"import-statement","external":true},{"path":"@dxos/assistant","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-chess/src/capabilities/artifact-definition.ts","inputs":{"packages/plugins/plugin-chess/src/capabilities/artifact-definition.ts":{"bytesInOutput":5956}},"bytes":6216},"packages/plugins/plugin-chess/dist/lib/node/intent-resolver-BQGAQM27.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1374},"packages/plugins/plugin-chess/dist/lib/node/intent-resolver-BQGAQM27.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-THN2FKB3.cjs","kind":"import-statement"},{"path":"chess.js","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-chess/src/capabilities/intent-resolver.ts","inputs":{"packages/plugins/plugin-chess/src/capabilities/intent-resolver.ts":{"bytesInOutput":503}},"bytes":743},"packages/plugins/plugin-chess/dist/lib/node/ChessContainer-EQUVXDJC.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":6167},"packages/plugins/plugin-chess/dist/lib/node/ChessContainer-EQUVXDJC.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-OTMP6HPY.cjs","kind":"import-statement"},{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/display-name","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-chess/src/components/ChessContainer.tsx","inputs":{"packages/plugins/plugin-chess/src/components/ChessContainer.tsx":{"bytesInOutput":978},"packages/plugins/plugin-chess/src/components/PlayerSelector.tsx":{"bytesInOutput":2608}},"bytes":3948},"packages/plugins/plugin-chess/dist/lib/node/react-surface-TZDWBTEY.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1789},"packages/plugins/plugin-chess/dist/lib/node/react-surface-TZDWBTEY.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-R6JAL3RE.cjs","kind":"import-statement"},{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-THN2FKB3.cjs","kind":"import-statement"},{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-OTMP6HPY.cjs","kind":"import-statement"},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-chess/src/capabilities/react-surface.tsx","inputs":{"packages/plugins/plugin-chess/src/capabilities/react-surface.tsx":{"bytesInOutput":715}},"bytes":1077},"packages/plugins/plugin-chess/dist/lib/node/chunk-R6JAL3RE.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":402},"packages/plugins/plugin-chess/dist/lib/node/chunk-R6JAL3RE.cjs":{"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/dist/lib/node/ChessContainer-EQUVXDJC.cjs","kind":"dynamic-import"}],"exports":["ChessContainer"],"inputs":{"packages/plugins/plugin-chess/src/components/index.ts":{"bytesInOutput":104}},"bytes":235},"packages/plugins/plugin-chess/dist/lib/node/chunk-THN2FKB3.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":3763},"packages/plugins/plugin-chess/dist/lib/node/chunk-THN2FKB3.cjs":{"imports":[{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/echo","kind":"import-statement","external":true}],"exports":["CHESS_PLUGIN","ChessAction","ChessType","MoveSchema","isObject","meta"],"inputs":{"packages/plugins/plugin-chess/src/types/schema.ts":{"bytesInOutput":586},"packages/plugins/plugin-chess/src/types/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-chess/src/types/types.ts":{"bytesInOutput":553},"packages/plugins/plugin-chess/src/meta.ts":{"bytesInOutput":513}},"bytes":1991},"packages/plugins/plugin-chess/dist/lib/node/chunk-OTMP6HPY.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2588},"packages/plugins/plugin-chess/dist/lib/node/chunk-OTMP6HPY.cjs":{"imports":[{"path":"@preact-signals/safe-react/tracking","kind":"import-statement","external":true},{"path":"chess.js","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui-gameboard","kind":"import-statement","external":true}],"exports":["ChessComponent"],"inputs":{"packages/plugins/plugin-chess/src/components/ChessComponent.tsx":{"bytesInOutput":1601}},"bytes":1742}}}
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
|
-
var __copyProps = (to, from, except, desc) => {
|
|
13
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
-
for (let key of __getOwnPropNames(from))
|
|
15
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
-
}
|
|
18
|
-
return to;
|
|
19
|
-
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var react_surface_TZDWBTEY_exports = {};
|
|
30
|
-
__export(react_surface_TZDWBTEY_exports, {
|
|
31
|
-
default: () => react_surface_default
|
|
32
|
-
});
|
|
33
|
-
module.exports = __toCommonJS(react_surface_TZDWBTEY_exports);
|
|
34
|
-
var import_chunk_R6JAL3RE = require("./chunk-R6JAL3RE.cjs");
|
|
35
|
-
var import_chunk_THN2FKB3 = require("./chunk-THN2FKB3.cjs");
|
|
36
|
-
var import_chunk_OTMP6HPY = require("./chunk-OTMP6HPY.cjs");
|
|
37
|
-
var import_react = __toESM(require("react"));
|
|
38
|
-
var import_app_framework = require("@dxos/app-framework");
|
|
39
|
-
var import_echo = require("@dxos/echo");
|
|
40
|
-
var react_surface_default = () => (0, import_app_framework.contributes)(import_app_framework.Capabilities.ReactSurface, [
|
|
41
|
-
(0, import_app_framework.createSurface)({
|
|
42
|
-
id: import_chunk_THN2FKB3.CHESS_PLUGIN,
|
|
43
|
-
role: [
|
|
44
|
-
"article",
|
|
45
|
-
"section"
|
|
46
|
-
],
|
|
47
|
-
filter: (data) => (0, import_chunk_THN2FKB3.isObject)(data.subject),
|
|
48
|
-
component: ({ data, role }) => /* @__PURE__ */ import_react.default.createElement(import_chunk_R6JAL3RE.ChessContainer, {
|
|
49
|
-
game: data.subject,
|
|
50
|
-
role
|
|
51
|
-
})
|
|
52
|
-
}),
|
|
53
|
-
(0, import_app_framework.createSurface)({
|
|
54
|
-
id: "plugin-chess",
|
|
55
|
-
role: "canvas-node",
|
|
56
|
-
filter: import_echo.Obj.instanceOf(import_chunk_THN2FKB3.ChessType),
|
|
57
|
-
component: ({ data }) => /* @__PURE__ */ import_react.default.createElement(import_chunk_OTMP6HPY.ChessComponent, {
|
|
58
|
-
game: data
|
|
59
|
-
})
|
|
60
|
-
})
|
|
61
|
-
]);
|
|
62
|
-
//# sourceMappingURL=react-surface-TZDWBTEY.cjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/capabilities/react-surface.tsx"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport React from 'react';\n\nimport { Capabilities, contributes, createSurface } from '@dxos/app-framework';\nimport { Obj } from '@dxos/echo';\n\nimport { ChessContainer } from '../components';\nimport { ChessComponent } from '../components/ChessComponent';\nimport { CHESS_PLUGIN } from '../meta';\nimport { ChessType, isObject } from '../types';\n\nexport default () =>\n contributes(Capabilities.ReactSurface, [\n createSurface({\n id: CHESS_PLUGIN,\n role: ['article', 'section'],\n filter: (data): data is { subject: ChessType } => isObject(data.subject),\n component: ({ data, role }) => <ChessContainer game={data.subject} role={role} />,\n }),\n createSurface({\n id: 'plugin-chess',\n role: 'canvas-node',\n filter: Obj.instanceOf(ChessType),\n component: ({ data }) => <ChessComponent game={data} />,\n }),\n ]);\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,mBAAkB;AAElB,2BAAyD;AACzD,kBAAoB;AAOpB,IAAA,wBAAe,UACbA,kCAAYC,kCAAaC,cAAc;MACrCC,oCAAc;IACZC,IAAIC;IACJC,MAAM;MAAC;MAAW;;IAClBC,QAAQ,CAACC,aAAyCC,gCAASD,KAAKE,OAAO;IACvEC,WAAW,CAAC,EAAEH,MAAMF,KAAI,MAAO,6BAAAM,QAAA,cAACC,sCAAAA;MAAeC,MAAMN,KAAKE;MAASJ;;EACrE,CAAA;MACAH,oCAAc;IACZC,IAAI;IACJE,MAAM;IACNC,QAAQQ,gBAAIC,WAAWC,+BAAAA;IACvBN,WAAW,CAAC,EAAEH,KAAI,MAAO,6BAAAI,QAAA,cAACM,sCAAAA;MAAeJ,MAAMN;;EACjD,CAAA;CACD;",
|
|
6
|
-
"names": ["contributes", "Capabilities", "ReactSurface", "createSurface", "id", "CHESS_PLUGIN", "role", "filter", "data", "isObject", "subject", "component", "React", "ChessContainer", "game", "Obj", "instanceOf", "ChessType", "ChessComponent"]
|
|
7
|
-
}
|