@dxos/plugin-chess 0.7.5-main.9d2a38b → 0.7.5-main.ff8607b

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.
Files changed (89) hide show
  1. package/dist/lib/browser/ChessContainer-LPMACR6Y.mjs +106 -0
  2. package/dist/lib/browser/ChessContainer-LPMACR6Y.mjs.map +7 -0
  3. package/dist/lib/browser/{chunk-VHSLLEH3.mjs → chunk-KC36U5TF.mjs} +6 -3
  4. package/dist/lib/browser/{chunk-VHSLLEH3.mjs.map → chunk-KC36U5TF.mjs.map} +3 -3
  5. package/dist/lib/browser/index.mjs +8 -8
  6. package/dist/lib/browser/index.mjs.map +3 -3
  7. package/dist/lib/browser/{intent-resolver-FUAOSHHX.mjs → intent-resolver-5CPSAZSA.mjs} +12 -9
  8. package/dist/lib/browser/{intent-resolver-FUAOSHHX.mjs.map → intent-resolver-5CPSAZSA.mjs.map} +3 -3
  9. package/dist/lib/browser/meta.json +1 -1
  10. package/dist/lib/browser/{react-surface-63EO2PZO.mjs → react-surface-6J2N3V5R.mjs} +3 -3
  11. package/dist/lib/browser/types/index.mjs +1 -1
  12. package/dist/lib/node/ChessContainer-ZFOCAXZL.cjs +131 -0
  13. package/dist/lib/node/ChessContainer-ZFOCAXZL.cjs.map +7 -0
  14. package/dist/lib/node/{chunk-3BLH7NRV.cjs → chunk-BEZSGC5V.cjs} +9 -6
  15. package/dist/lib/node/{chunk-3BLH7NRV.cjs.map → chunk-BEZSGC5V.cjs.map} +3 -3
  16. package/dist/lib/node/index.cjs +21 -21
  17. package/dist/lib/node/index.cjs.map +3 -3
  18. package/dist/lib/node/{intent-resolver-VTB6P3IL.cjs → intent-resolver-2YYMQ2H5.cjs} +15 -12
  19. package/dist/lib/node/{intent-resolver-VTB6P3IL.cjs.map → intent-resolver-2YYMQ2H5.cjs.map} +3 -3
  20. package/dist/lib/node/meta.json +1 -1
  21. package/dist/lib/node/{react-surface-PO42G64E.cjs → react-surface-IOAB5AXZ.cjs} +8 -8
  22. package/dist/lib/node/types/index.cjs +5 -5
  23. package/dist/lib/node/types/index.cjs.map +1 -1
  24. package/dist/lib/node-esm/ChessContainer-DF6IFM2R.mjs +108 -0
  25. package/dist/lib/node-esm/ChessContainer-DF6IFM2R.mjs.map +7 -0
  26. package/dist/lib/node-esm/{chunk-M2CRYWX5.mjs → chunk-A6KO5IFZ.mjs} +6 -3
  27. package/dist/lib/node-esm/{chunk-M2CRYWX5.mjs.map → chunk-A6KO5IFZ.mjs.map} +3 -3
  28. package/dist/lib/node-esm/index.mjs +8 -8
  29. package/dist/lib/node-esm/index.mjs.map +3 -3
  30. package/dist/lib/node-esm/{intent-resolver-MKEQFVZO.mjs → intent-resolver-XCT7HZ43.mjs} +12 -9
  31. package/dist/lib/node-esm/{intent-resolver-MKEQFVZO.mjs.map → intent-resolver-XCT7HZ43.mjs.map} +3 -3
  32. package/dist/lib/node-esm/meta.json +1 -1
  33. package/dist/lib/node-esm/{react-surface-CXEBEDLT.mjs → react-surface-47I77M7F.mjs} +3 -3
  34. package/dist/lib/node-esm/types/index.mjs +1 -1
  35. package/dist/types/src/ChessPlugin.d.ts.map +1 -1
  36. package/dist/types/src/capabilities/index.d.ts +2 -2
  37. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  38. package/dist/types/src/capabilities/intent-resolver.d.ts.map +1 -1
  39. package/dist/types/src/components/ChessContainer.d.ts +4 -3
  40. package/dist/types/src/components/ChessContainer.d.ts.map +1 -1
  41. package/dist/types/src/components/ChessPanel.d.ts +11 -0
  42. package/dist/types/src/components/ChessPanel.d.ts.map +1 -0
  43. package/dist/types/src/components/Chessboard.stories.d.ts +8 -0
  44. package/dist/types/src/components/Chessboard.stories.d.ts.map +1 -0
  45. package/dist/types/src/components/{Chess.d.ts → PlayerSelector.d.ts} +4 -5
  46. package/dist/types/src/components/PlayerSelector.d.ts.map +1 -0
  47. package/dist/types/src/components/index.d.ts +2 -1
  48. package/dist/types/src/components/index.d.ts.map +1 -1
  49. package/dist/types/src/meta.d.ts +1 -0
  50. package/dist/types/src/meta.d.ts.map +1 -1
  51. package/package.json +19 -20
  52. package/src/ChessPlugin.tsx +5 -13
  53. package/src/capabilities/intent-resolver.ts +8 -5
  54. package/src/components/ChessContainer.tsx +41 -4
  55. package/src/components/ChessPanel.tsx +67 -0
  56. package/src/components/Chessboard.stories.tsx +39 -0
  57. package/src/components/{Chess.tsx → PlayerSelector.tsx} +2 -49
  58. package/src/meta.ts +3 -1
  59. package/dist/lib/browser/ChessContainer-JYXOZIDK.mjs +0 -505
  60. package/dist/lib/browser/ChessContainer-JYXOZIDK.mjs.map +0 -7
  61. package/dist/lib/node/ChessContainer-XRP7D63X.cjs +0 -518
  62. package/dist/lib/node/ChessContainer-XRP7D63X.cjs.map +0 -7
  63. package/dist/lib/node-esm/ChessContainer-37QUCUTD.mjs +0 -507
  64. package/dist/lib/node-esm/ChessContainer-37QUCUTD.mjs.map +0 -7
  65. package/dist/types/src/components/Chess.d.ts.map +0 -1
  66. package/dist/types/src/components/Chessboard/Chessboard.d.ts +0 -37
  67. package/dist/types/src/components/Chessboard/Chessboard.d.ts.map +0 -1
  68. package/dist/types/src/components/Chessboard/Chessboard.stories.d.ts +0 -13
  69. package/dist/types/src/components/Chessboard/Chessboard.stories.d.ts.map +0 -1
  70. package/dist/types/src/components/Chessboard/index.d.ts +0 -2
  71. package/dist/types/src/components/Chessboard/index.d.ts.map +0 -1
  72. package/dist/types/src/components/Chessboard/pieces/custom.d.ts +0 -3
  73. package/dist/types/src/components/Chessboard/pieces/custom.d.ts.map +0 -1
  74. package/dist/types/src/components/Chessboard/pieces/index.d.ts +0 -4
  75. package/dist/types/src/components/Chessboard/pieces/index.d.ts.map +0 -1
  76. package/dist/types/src/components/Chessboard/pieces/phosphor.d.ts +0 -3
  77. package/dist/types/src/components/Chessboard/pieces/phosphor.d.ts.map +0 -1
  78. package/dist/types/src/components/Chessboard/pieces/riohacha.d.ts +0 -3
  79. package/dist/types/src/components/Chessboard/pieces/riohacha.d.ts.map +0 -1
  80. package/src/components/Chessboard/Chessboard.stories.tsx +0 -43
  81. package/src/components/Chessboard/Chessboard.tsx +0 -170
  82. package/src/components/Chessboard/index.ts +0 -5
  83. package/src/components/Chessboard/pieces/custom.tsx +0 -82
  84. package/src/components/Chessboard/pieces/index.ts +0 -7
  85. package/src/components/Chessboard/pieces/phosphor.tsx +0 -71
  86. package/src/components/Chessboard/pieces/riohacha.tsx +0 -166
  87. /package/dist/lib/browser/{react-surface-63EO2PZO.mjs.map → react-surface-6J2N3V5R.mjs.map} +0 -0
  88. /package/dist/lib/node/{react-surface-PO42G64E.cjs.map → react-surface-IOAB5AXZ.cjs.map} +0 -0
  89. /package/dist/lib/node-esm/{react-surface-CXEBEDLT.mjs.map → react-surface-47I77M7F.mjs.map} +0 -0
@@ -16,8 +16,8 @@ var __copyProps = (to, from, except, desc) => {
16
16
  return to;
17
17
  };
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var chunk_3BLH7NRV_exports = {};
20
- __export(chunk_3BLH7NRV_exports, {
19
+ var chunk_BEZSGC5V_exports = {};
20
+ __export(chunk_BEZSGC5V_exports, {
21
21
  CHESS_PLUGIN: () => CHESS_PLUGIN,
22
22
  ChessAction: () => ChessAction,
23
23
  GameType: () => GameType,
@@ -25,7 +25,7 @@ __export(chunk_3BLH7NRV_exports, {
25
25
  isObject: () => isObject,
26
26
  meta: () => meta
27
27
  });
28
- module.exports = __toCommonJS(chunk_3BLH7NRV_exports);
28
+ module.exports = __toCommonJS(chunk_BEZSGC5V_exports);
29
29
  var import_echo_schema = require("@dxos/echo-schema");
30
30
  var import_echo_schema2 = require("@dxos/echo-schema");
31
31
  var import_live_object = require("@dxos/live-object");
@@ -51,9 +51,12 @@ var CHESS_PLUGIN = "dxos.org/plugin/chess";
51
51
  var meta = {
52
52
  id: CHESS_PLUGIN,
53
53
  name: "Chess",
54
- description: "Play 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
55
  icon: "ph--shield-chevron--regular",
56
- source: "https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-chess"
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
+ ]
57
60
  };
58
61
  var ChessAction;
59
62
  (function(ChessAction2) {
@@ -81,4 +84,4 @@ var isObject = (object) => {
81
84
  isObject,
82
85
  meta
83
86
  });
84
- //# sourceMappingURL=chunk-3BLH7NRV.cjs.map
87
+ //# sourceMappingURL=chunk-BEZSGC5V.cjs.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/types/schema.ts", "../../../src/types/types.ts", "../../../src/meta.ts"],
4
- "sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { S, TypedObject } from '@dxos/echo-schema';\n\nexport const MoveSchema = S.mutable(\n S.partial(\n S.Struct({\n source: S.String,\n target: S.String,\n piece: S.String,\n }),\n ),\n);\n\nexport class GameType extends TypedObject({ typename: 'dxos.org/type/Chess', version: '0.1.0' })(\n {\n name: S.optional(S.String),\n playerWhite: S.String,\n playerBlack: S.String,\n moves: S.mutable(S.Array(S.String)),\n pgn: S.String,\n },\n { partial: true },\n) {}\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { S } from '@dxos/echo-schema';\nimport { isReactiveObject } from '@dxos/live-object';\n\nimport { GameType } from './schema';\nimport { CHESS_PLUGIN } from '../meta';\n\nexport namespace ChessAction {\n const CHESS_ACTION = `${CHESS_PLUGIN}/action`;\n\n export class Create extends S.TaggedClass<Create>()(`${CHESS_ACTION}/create`, {\n input: S.Struct({\n name: S.optional(S.String),\n }),\n output: S.Struct({\n object: GameType,\n }),\n }) {}\n}\n\nexport const isObject = (object: unknown): object is GameType => {\n return isReactiveObject(object) && object instanceof GameType;\n};\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 = {\n id: CHESS_PLUGIN,\n name: 'Chess',\n description: 'Play chess.',\n icon: 'ph--shield-chevron--regular',\n source: 'https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-chess',\n} satisfies PluginMeta;\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,yBAA+B;ACA/B,IAAAA,sBAAkB;AAClB,yBAAiC;ADC1B,IAAMC,aAAaC,qBAAEC,QAC1BD,qBAAEE,QACAF,qBAAEG,OAAO;EACPC,QAAQJ,qBAAEK;EACVC,QAAQN,qBAAEK;EACVE,OAAOP,qBAAEK;AACX,CAAA,CAAA,CAAA;AAIG,IAAMG,WAAN,kBAAuBC,gCAAY;EAAEC,UAAU;EAAuBC,SAAS;AAAQ,CAAA,EAC5F;EACEC,MAAMZ,qBAAEa,SAASb,qBAAEK,MAAM;EACzBS,aAAad,qBAAEK;EACfU,aAAaf,qBAAEK;EACfW,OAAOhB,qBAAEC,QAAQD,qBAAEiB,MAAMjB,qBAAEK,MAAM,CAAA;EACjCa,KAAKlB,qBAAEK;AACT,GACA;EAAEH,SAAS;AAAK,CAAA,EAAA;AACf;AEnBI,IAAMiB,eAAe;AAErB,IAAMC,OAAO;EAClBC,IAAIF;EACJP,MAAM;EACNU,aAAa;EACbC,MAAM;EACNnB,QAAQ;AACV;;UDJiBoB,cAAAA;AACf,QAAMC,eAAe,GAAGN,YAAAA;EAEjB,MAAMO,eAAe1B,oBAAAA,EAAE2B,YAAW,EAAW,GAAGF,YAAAA,WAAuB;IAC5EG,OAAO5B,oBAAAA,EAAEG,OAAO;MACdS,MAAMZ,oBAAAA,EAAEa,SAASb,oBAAAA,EAAEK,MAAM;IAC3B,CAAA;IACAwB,QAAQ7B,oBAAAA,EAAEG,OAAO;MACf2B,QAAQtB;IACV,CAAA;EACF,CAAA,EAAA;EAAI;eAPSkB,SAAAA;AAQf,GAXiBF,gBAAAA,cAAAA,CAAAA,EAAAA;AAaV,IAAMO,WAAW,CAACD,WAAAA;AACvB,aAAOE,qCAAiBF,MAAAA,KAAWA,kBAAkBtB;AACvD;",
6
- "names": ["import_echo_schema", "MoveSchema", "S", "mutable", "partial", "Struct", "source", "String", "target", "piece", "GameType", "TypedObject", "typename", "version", "name", "optional", "playerWhite", "playerBlack", "moves", "Array", "pgn", "CHESS_PLUGIN", "meta", "id", "description", "icon", "ChessAction", "CHESS_ACTION", "Create", "TaggedClass", "input", "output", "object", "isObject", "isReactiveObject"]
4
+ "sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { S, TypedObject } from '@dxos/echo-schema';\n\nexport const MoveSchema = S.mutable(\n S.partial(\n S.Struct({\n source: S.String,\n target: S.String,\n piece: S.String,\n }),\n ),\n);\n\nexport class GameType extends TypedObject({ typename: 'dxos.org/type/Chess', version: '0.1.0' })(\n {\n name: S.optional(S.String),\n playerWhite: S.String,\n playerBlack: S.String,\n moves: S.mutable(S.Array(S.String)),\n pgn: S.String,\n },\n { partial: true },\n) {}\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { S } from '@dxos/echo-schema';\nimport { isReactiveObject } from '@dxos/live-object';\n\nimport { GameType } from './schema';\nimport { CHESS_PLUGIN } from '../meta';\n\nexport namespace ChessAction {\n const CHESS_ACTION = `${CHESS_PLUGIN}/action`;\n\n export class Create extends S.TaggedClass<Create>()(`${CHESS_ACTION}/create`, {\n input: S.Struct({\n name: S.optional(S.String),\n }),\n output: S.Struct({\n object: GameType,\n }),\n }) {}\n}\n\nexport const isObject = (object: unknown): object is GameType => {\n return isReactiveObject(object) && object instanceof GameType;\n};\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 = {\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} satisfies PluginMeta;\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,yBAA+B;ACA/B,IAAAA,sBAAkB;AAClB,yBAAiC;ADC1B,IAAMC,aAAaC,qBAAEC,QAC1BD,qBAAEE,QACAF,qBAAEG,OAAO;EACPC,QAAQJ,qBAAEK;EACVC,QAAQN,qBAAEK;EACVE,OAAOP,qBAAEK;AACX,CAAA,CAAA,CAAA;AAIG,IAAMG,WAAN,kBAAuBC,gCAAY;EAAEC,UAAU;EAAuBC,SAAS;AAAQ,CAAA,EAC5F;EACEC,MAAMZ,qBAAEa,SAASb,qBAAEK,MAAM;EACzBS,aAAad,qBAAEK;EACfU,aAAaf,qBAAEK;EACfW,OAAOhB,qBAAEC,QAAQD,qBAAEiB,MAAMjB,qBAAEK,MAAM,CAAA;EACjCa,KAAKlB,qBAAEK;AACT,GACA;EAAEH,SAAS;AAAK,CAAA,EAAA;AACf;AEnBI,IAAMiB,eAAe;AAErB,IAAMC,OAAO;EAClBC,IAAIF;EACJP,MAAM;EACNU,aACE;EACFC,MAAM;EACNnB,QAAQ;EACRoB,aAAa;IAAC;;AAChB;;UDNiBC,cAAAA;AACf,QAAMC,eAAe,GAAGP,YAAAA;EAEjB,MAAMQ,eAAe3B,oBAAAA,EAAE4B,YAAW,EAAW,GAAGF,YAAAA,WAAuB;IAC5EG,OAAO7B,oBAAAA,EAAEG,OAAO;MACdS,MAAMZ,oBAAAA,EAAEa,SAASb,oBAAAA,EAAEK,MAAM;IAC3B,CAAA;IACAyB,QAAQ9B,oBAAAA,EAAEG,OAAO;MACf4B,QAAQvB;IACV,CAAA;EACF,CAAA,EAAA;EAAI;eAPSmB,SAAAA;AAQf,GAXiBF,gBAAAA,cAAAA,CAAAA,EAAAA;AAaV,IAAMO,WAAW,CAACD,WAAAA;AACvB,aAAOE,qCAAiBF,MAAAA,KAAWA,kBAAkBvB;AACvD;",
6
+ "names": ["import_echo_schema", "MoveSchema", "S", "mutable", "partial", "Struct", "source", "String", "target", "piece", "GameType", "TypedObject", "typename", "version", "name", "optional", "playerWhite", "playerBlack", "moves", "Array", "pgn", "CHESS_PLUGIN", "meta", "id", "description", "icon", "screenshots", "ChessAction", "CHESS_ACTION", "Create", "TaggedClass", "input", "output", "object", "isObject", "isReactiveObject"]
7
7
  }
@@ -28,24 +28,24 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
29
  var node_exports = {};
30
30
  __export(node_exports, {
31
- CHESS_PLUGIN: () => import_chunk_3BLH7NRV.CHESS_PLUGIN,
31
+ CHESS_PLUGIN: () => import_chunk_BEZSGC5V.CHESS_PLUGIN,
32
32
  ChessPlugin: () => ChessPlugin,
33
- meta: () => import_chunk_3BLH7NRV.meta
33
+ meta: () => import_chunk_BEZSGC5V.meta
34
34
  });
35
35
  module.exports = __toCommonJS(node_exports);
36
- var import_chunk_3BLH7NRV = require("./chunk-3BLH7NRV.cjs");
36
+ var import_chunk_BEZSGC5V = require("./chunk-BEZSGC5V.cjs");
37
37
  var import_app_framework = require("@dxos/app-framework");
38
38
  var import_plugin_client = require("@dxos/plugin-client");
39
39
  var import_app_framework2 = require("@dxos/app-framework");
40
- var IntentResolver = (0, import_app_framework2.lazy)(() => import("./intent-resolver-VTB6P3IL.cjs"));
41
- var ReactSurface = (0, import_app_framework2.lazy)(() => import("./react-surface-PO42G64E.cjs"));
40
+ var IntentResolver = (0, import_app_framework2.lazy)(() => import("./intent-resolver-2YYMQ2H5.cjs"));
41
+ var ReactSurface = (0, import_app_framework2.lazy)(() => import("./react-surface-IOAB5AXZ.cjs"));
42
42
  var translations_default = [
43
43
  {
44
44
  "en-US": {
45
- [import_chunk_3BLH7NRV.GameType.typename]: {
45
+ [import_chunk_BEZSGC5V.GameType.typename]: {
46
46
  "typename label": "Game"
47
47
  },
48
- [import_chunk_3BLH7NRV.CHESS_PLUGIN]: {
48
+ [import_chunk_BEZSGC5V.CHESS_PLUGIN]: {
49
49
  "plugin name": "Chess",
50
50
  "game title placeholder": "New game",
51
51
  "create game label": "Create game",
@@ -54,23 +54,23 @@ var translations_default = [
54
54
  }
55
55
  }
56
56
  ];
57
- var ChessPlugin = () => (0, import_app_framework.definePlugin)(import_chunk_3BLH7NRV.meta, [
57
+ var ChessPlugin = () => (0, import_app_framework.definePlugin)(import_chunk_BEZSGC5V.meta, [
58
58
  (0, import_app_framework.defineModule)({
59
- id: `${import_chunk_3BLH7NRV.meta.id}/module/translations`,
59
+ id: `${import_chunk_BEZSGC5V.meta.id}/module/translations`,
60
60
  activatesOn: import_app_framework.Events.SetupTranslations,
61
61
  activate: () => (0, import_app_framework.contributes)(import_app_framework.Capabilities.Translations, translations_default)
62
62
  }),
63
63
  (0, import_app_framework.defineModule)({
64
- id: `${import_chunk_3BLH7NRV.meta.id}/module/metadata`,
65
- activatesOn: (0, import_app_framework.oneOf)(import_app_framework.Events.Startup, import_app_framework.Events.SetupAppGraph),
64
+ id: `${import_chunk_BEZSGC5V.meta.id}/module/metadata`,
65
+ activatesOn: import_app_framework.Events.SetupMetadata,
66
66
  activate: () => (0, import_app_framework.contributes)(import_app_framework.Capabilities.Metadata, {
67
- id: import_chunk_3BLH7NRV.GameType.typename,
67
+ id: import_chunk_BEZSGC5V.GameType.typename,
68
68
  metadata: {
69
- createObject: (props) => (0, import_app_framework.createIntent)(import_chunk_3BLH7NRV.ChessAction.Create, props),
69
+ createObject: (props) => (0, import_app_framework.createIntent)(import_chunk_BEZSGC5V.ChessAction.Create, props),
70
70
  placeholder: [
71
71
  "game title placeholder",
72
72
  {
73
- ns: import_chunk_3BLH7NRV.CHESS_PLUGIN
73
+ ns: import_chunk_BEZSGC5V.CHESS_PLUGIN
74
74
  }
75
75
  ],
76
76
  icon: "ph--shield-chevron--regular"
@@ -78,20 +78,20 @@ var ChessPlugin = () => (0, import_app_framework.definePlugin)(import_chunk_3BLH
78
78
  })
79
79
  }),
80
80
  (0, import_app_framework.defineModule)({
81
- id: `${import_chunk_3BLH7NRV.meta.id}/module/schema`,
82
- activatesOn: import_plugin_client.ClientEvents.SetupClient,
81
+ id: `${import_chunk_BEZSGC5V.meta.id}/module/schema`,
82
+ activatesOn: import_plugin_client.ClientEvents.SetupSchema,
83
83
  activate: () => (0, import_app_framework.contributes)(import_plugin_client.ClientCapabilities.Schema, [
84
- import_chunk_3BLH7NRV.GameType
84
+ import_chunk_BEZSGC5V.GameType
85
85
  ])
86
86
  }),
87
87
  (0, import_app_framework.defineModule)({
88
- id: `${import_chunk_3BLH7NRV.meta.id}/module/react-surface`,
89
- activatesOn: import_app_framework.Events.Startup,
88
+ id: `${import_chunk_BEZSGC5V.meta.id}/module/react-surface`,
89
+ activatesOn: import_app_framework.Events.SetupSurfaces,
90
90
  activate: ReactSurface
91
91
  }),
92
92
  (0, import_app_framework.defineModule)({
93
- id: `${import_chunk_3BLH7NRV.meta.id}/module/intent-resolver`,
94
- activatesOn: import_app_framework.Events.Startup,
93
+ id: `${import_chunk_BEZSGC5V.meta.id}/module/intent-resolver`,
94
+ activatesOn: import_app_framework.Events.SetupIntents,
95
95
  activate: IntentResolver
96
96
  })
97
97
  ]);
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/ChessPlugin.tsx", "../../../src/capabilities/index.ts", "../../../src/translations.ts"],
4
- "sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport {\n Capabilities,\n contributes,\n createIntent,\n defineModule,\n definePlugin,\n Events,\n oneOf,\n} from '@dxos/app-framework';\nimport { ClientCapabilities, ClientEvents } from '@dxos/plugin-client';\n\nimport { IntentResolver, ReactSurface } from './capabilities';\nimport { CHESS_PLUGIN, meta } from './meta';\nimport translations from './translations';\nimport { ChessAction, GameType } 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: oneOf(Events.Startup, Events.SetupAppGraph),\n activate: () =>\n contributes(Capabilities.Metadata, {\n id: GameType.typename,\n metadata: {\n createObject: (props: { name?: string }) => createIntent(ChessAction.Create, props),\n placeholder: ['game title placeholder', { ns: CHESS_PLUGIN }],\n icon: 'ph--shield-chevron--regular',\n },\n }),\n }),\n defineModule({\n id: `${meta.id}/module/schema`,\n activatesOn: ClientEvents.SetupClient,\n activate: () => contributes(ClientCapabilities.Schema, [GameType]),\n }),\n defineModule({\n id: `${meta.id}/module/react-surface`,\n activatesOn: Events.Startup,\n activate: ReactSurface,\n }),\n defineModule({\n id: `${meta.id}/module/intent-resolver`,\n activatesOn: Events.Startup,\n activate: IntentResolver,\n }),\n ]);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { lazy } from '@dxos/app-framework';\n\nexport const IntentResolver = lazy(() => import('./intent-resolver'));\nexport const ReactSurface = lazy(() => import('./react-surface'));\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { CHESS_PLUGIN } from './meta';\nimport { GameType } from './types';\n\nexport default [\n {\n 'en-US': {\n [GameType.typename]: {\n 'typename label': 'Game',\n },\n [CHESS_PLUGIN]: {\n 'plugin name': 'Chess',\n 'game title placeholder': 'New game',\n 'create game label': 'Create game',\n 'delete game label': 'Delete',\n },\n },\n },\n];\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,2BAQO;AACP,2BAAiD;ACTjD,IAAAA,wBAAqB;AAEd,IAAMC,qBAAiBC,4BAAK,MAAM,OAAO,gCAAA,CAAA;AACzC,IAAMC,mBAAeD,4BAAK,MAAM,OAAO,8BAAA,CAAA;ACA9C,IAAA,uBAAe;EACb;IACE,SAAS;MACP,CAACE,+BAASC,QAAQ,GAAG;QACnB,kBAAkB;MACpB;MACA,CAACC,kCAAAA,GAAe;QACd,eAAe;QACf,0BAA0B;QAC1B,qBAAqB;QACrB,qBAAqB;MACvB;IACF;EACF;;AFAK,IAAMC,cAAc,UACzBC,mCAAaC,4BAAM;MACjBC,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,4BAAOC;IACpBC,UAAU,UAAMC,kCAAYC,kCAAaC,cAAcC,oBAAAA;EACzD,CAAA;MACAT,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,iBAAaQ,4BAAMP,4BAAOQ,SAASR,4BAAOS,aAAa;IACvDP,UAAU,UACRC,kCAAYC,kCAAaM,UAAU;MACjCZ,IAAIP,+BAASC;MACbmB,UAAU;QACRC,cAAc,CAACC,cAA6BC,mCAAaC,kCAAYC,QAAQH,KAAAA;QAC7EI,aAAa;UAAC;UAA0B;YAAEC,IAAIzB;UAAa;;QAC3D0B,MAAM;MACR;IACF,CAAA;EACJ,CAAA;MACAtB,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaqB,kCAAaC;IAC1BnB,UAAU,UAAMC,kCAAYmB,wCAAmBC,QAAQ;MAAChC;KAAS;EACnE,CAAA;MACAM,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,4BAAOQ;IACpBN,UAAUZ;EACZ,CAAA;MACAO,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,4BAAOQ;IACpBN,UAAUd;EACZ,CAAA;CACD;",
6
- "names": ["import_app_framework", "IntentResolver", "lazy", "ReactSurface", "GameType", "typename", "CHESS_PLUGIN", "ChessPlugin", "definePlugin", "meta", "defineModule", "id", "activatesOn", "Events", "SetupTranslations", "activate", "contributes", "Capabilities", "Translations", "translations", "oneOf", "Startup", "SetupAppGraph", "Metadata", "metadata", "createObject", "props", "createIntent", "ChessAction", "Create", "placeholder", "ns", "icon", "ClientEvents", "SetupClient", "ClientCapabilities", "Schema"]
4
+ "sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { Capabilities, contributes, createIntent, defineModule, definePlugin, Events } from '@dxos/app-framework';\nimport { ClientCapabilities, ClientEvents } from '@dxos/plugin-client';\n\nimport { IntentResolver, ReactSurface } from './capabilities';\nimport { CHESS_PLUGIN, meta } from './meta';\nimport translations from './translations';\nimport { ChessAction, GameType } 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: GameType.typename,\n metadata: {\n createObject: (props: { name?: string }) => createIntent(ChessAction.Create, props),\n placeholder: ['game title placeholder', { ns: CHESS_PLUGIN }],\n icon: 'ph--shield-chevron--regular',\n },\n }),\n }),\n defineModule({\n id: `${meta.id}/module/schema`,\n activatesOn: ClientEvents.SetupSchema,\n activate: () => contributes(ClientCapabilities.Schema, [GameType]),\n }),\n defineModule({\n id: `${meta.id}/module/react-surface`,\n activatesOn: Events.SetupSurfaces,\n activate: ReactSurface,\n }),\n defineModule({\n id: `${meta.id}/module/intent-resolver`,\n activatesOn: Events.SetupIntents,\n activate: IntentResolver,\n }),\n ]);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { lazy } from '@dxos/app-framework';\n\nexport const IntentResolver = lazy(() => import('./intent-resolver'));\nexport const ReactSurface = lazy(() => import('./react-surface'));\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { CHESS_PLUGIN } from './meta';\nimport { GameType } from './types';\n\nexport default [\n {\n 'en-US': {\n [GameType.typename]: {\n 'typename label': 'Game',\n },\n [CHESS_PLUGIN]: {\n 'plugin name': 'Chess',\n 'game title placeholder': 'New game',\n 'create game label': 'Create game',\n 'delete game label': 'Delete',\n },\n },\n },\n];\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,2BAA4F;AAC5F,2BAAiD;ACDjD,IAAAA,wBAAqB;AAEd,IAAMC,qBAAiBC,4BAAK,MAAM,OAAO,gCAAA,CAAA;AACzC,IAAMC,mBAAeD,4BAAK,MAAM,OAAO,8BAAA,CAAA;ACA9C,IAAA,uBAAe;EACb;IACE,SAAS;MACP,CAACE,+BAASC,QAAQ,GAAG;QACnB,kBAAkB;MACpB;MACA,CAACC,kCAAAA,GAAe;QACd,eAAe;QACf,0BAA0B;QAC1B,qBAAqB;QACrB,qBAAqB;MACvB;IACF;EACF;;AFRK,IAAMC,cAAc,UACzBC,mCAAaC,4BAAM;MACjBC,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,4BAAOC;IACpBC,UAAU,UAAMC,kCAAYC,kCAAaC,cAAcC,oBAAAA;EACzD,CAAA;MACAT,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,4BAAOO;IACpBL,UAAU,UACRC,kCAAYC,kCAAaI,UAAU;MACjCV,IAAIP,+BAASC;MACbiB,UAAU;QACRC,cAAc,CAACC,cAA6BC,mCAAaC,kCAAYC,QAAQH,KAAAA;QAC7EI,aAAa;UAAC;UAA0B;YAAEC,IAAIvB;UAAa;;QAC3DwB,MAAM;MACR;IACF,CAAA;EACJ,CAAA;MACApB,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAamB,kCAAaC;IAC1BjB,UAAU,UAAMC,kCAAYiB,wCAAmBC,QAAQ;MAAC9B;KAAS;EACnE,CAAA;MACAM,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,4BAAOsB;IACpBpB,UAAUZ;EACZ,CAAA;MACAO,mCAAa;IACXC,IAAI,GAAGF,2BAAKE,EAAE;IACdC,aAAaC,4BAAOuB;IACpBrB,UAAUd;EACZ,CAAA;CACD;",
6
+ "names": ["import_app_framework", "IntentResolver", "lazy", "ReactSurface", "GameType", "typename", "CHESS_PLUGIN", "ChessPlugin", "definePlugin", "meta", "defineModule", "id", "activatesOn", "Events", "SetupTranslations", "activate", "contributes", "Capabilities", "Translations", "translations", "SetupMetadata", "Metadata", "metadata", "createObject", "props", "createIntent", "ChessAction", "Create", "placeholder", "ns", "icon", "ClientEvents", "SetupSchema", "ClientCapabilities", "Schema", "SetupSurfaces", "SetupIntents"]
7
7
  }
@@ -16,19 +16,22 @@ var __copyProps = (to, from, except, desc) => {
16
16
  return to;
17
17
  };
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var intent_resolver_VTB6P3IL_exports = {};
20
- __export(intent_resolver_VTB6P3IL_exports, {
19
+ var intent_resolver_2YYMQ2H5_exports = {};
20
+ __export(intent_resolver_2YYMQ2H5_exports, {
21
21
  default: () => intent_resolver_default
22
22
  });
23
- module.exports = __toCommonJS(intent_resolver_VTB6P3IL_exports);
24
- var import_chunk_3BLH7NRV = require("./chunk-3BLH7NRV.cjs");
23
+ module.exports = __toCommonJS(intent_resolver_2YYMQ2H5_exports);
24
+ var import_chunk_BEZSGC5V = require("./chunk-BEZSGC5V.cjs");
25
25
  var import_app_framework = require("@dxos/app-framework");
26
26
  var import_live_object = require("@dxos/live-object");
27
- var intent_resolver_default = () => (0, import_app_framework.contributes)(import_app_framework.Capabilities.IntentResolver, (0, import_app_framework.createResolver)(import_chunk_3BLH7NRV.ChessAction.Create, ({ name }) => ({
28
- data: {
29
- object: (0, import_live_object.create)(import_chunk_3BLH7NRV.GameType, {
30
- name
31
- })
32
- }
33
- })));
34
- //# sourceMappingURL=intent-resolver-VTB6P3IL.cjs.map
27
+ var intent_resolver_default = () => (0, import_app_framework.contributes)(import_app_framework.Capabilities.IntentResolver, (0, import_app_framework.createResolver)({
28
+ intent: import_chunk_BEZSGC5V.ChessAction.Create,
29
+ resolve: ({ name }) => ({
30
+ data: {
31
+ object: (0, import_live_object.create)(import_chunk_BEZSGC5V.GameType, {
32
+ name
33
+ })
34
+ }
35
+ })
36
+ }));
37
+ //# sourceMappingURL=intent-resolver-2YYMQ2H5.cjs.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/capabilities/intent-resolver.ts"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capabilities, contributes, createResolver } from '@dxos/app-framework';\nimport { create } from '@dxos/live-object';\n\nimport { ChessAction, GameType } from '../types';\n\nexport default () =>\n contributes(\n Capabilities.IntentResolver,\n createResolver(ChessAction.Create, ({ name }) => ({\n data: {\n object: create(GameType, { name }),\n },\n })),\n );\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAIA,2BAA0D;AAC1D,yBAAuB;AAIvB,IAAA,0BAAe,UACbA,kCACEC,kCAAaC,oBACbC,qCAAeC,kCAAYC,QAAQ,CAAC,EAAEC,KAAI,OAAQ;EAChDC,MAAM;IACJC,YAAQC,2BAAOC,gCAAU;MAAEJ;IAAK,CAAA;EAClC;AACF,EAAA,CAAA;",
6
- "names": ["contributes", "Capabilities", "IntentResolver", "createResolver", "ChessAction", "Create", "name", "data", "object", "create", "GameType"]
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capabilities, contributes, createResolver } from '@dxos/app-framework';\nimport { create } from '@dxos/live-object';\n\nimport { ChessAction, GameType } from '../types';\n\nexport default () =>\n contributes(\n Capabilities.IntentResolver,\n createResolver({\n intent: ChessAction.Create,\n resolve: ({ name }) => ({\n data: {\n object: create(GameType, { name }),\n },\n }),\n }),\n );\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAIA,2BAA0D;AAC1D,yBAAuB;AAIvB,IAAA,0BAAe,UACbA,kCACEC,kCAAaC,oBACbC,qCAAe;EACbC,QAAQC,kCAAYC;EACpBC,SAAS,CAAC,EAAEC,KAAI,OAAQ;IACtBC,MAAM;MACJC,YAAQC,2BAAOC,gCAAU;QAAEJ;MAAK,CAAA;IAClC;EACF;AACF,CAAA,CAAA;",
6
+ "names": ["contributes", "Capabilities", "IntentResolver", "createResolver", "intent", "ChessAction", "Create", "resolve", "name", "data", "object", "create", "GameType"]
7
7
  }
@@ -1 +1 @@
1
- {"inputs":{"packages/plugins/plugin-chess/src/types/schema.ts":{"bytes":2461,"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-chess/src/meta.ts":{"bytes":1411,"imports":[],"format":"esm"},"packages/plugins/plugin-chess/src/types/types.ts":{"bytes":2799,"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/live-object","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":586,"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/intent-resolver.ts":{"bytes":1974,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/live-object","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/Chessboard/pieces/custom.tsx":{"bytes":32344,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-chess/src/components/Chessboard/pieces/phosphor.tsx":{"bytes":6674,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-chess/src/components/Chessboard/pieces/riohacha.tsx":{"bytes":30948,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-chess/src/components/Chessboard/pieces/index.ts":{"bytes":704,"imports":[{"path":"packages/plugins/plugin-chess/src/components/Chessboard/pieces/custom.tsx","kind":"import-statement","original":"./custom"},{"path":"packages/plugins/plugin-chess/src/components/Chessboard/pieces/phosphor.tsx","kind":"import-statement","original":"./phosphor"},{"path":"packages/plugins/plugin-chess/src/components/Chessboard/pieces/riohacha.tsx","kind":"import-statement","original":"./riohacha"}],"format":"esm"},"packages/plugins/plugin-chess/src/components/Chessboard/Chessboard.tsx":{"bytes":15769,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"chess.js","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-chessboard","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/src/components/Chessboard/pieces/index.ts","kind":"import-statement","original":"./pieces"}],"format":"esm"},"packages/plugins/plugin-chess/src/components/Chessboard/index.ts":{"bytes":529,"imports":[{"path":"packages/plugins/plugin-chess/src/components/Chessboard/Chessboard.tsx","kind":"import-statement","original":"./Chessboard"}],"format":"esm"},"packages/plugins/plugin-chess/src/components/Chess.tsx":{"bytes":14027,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"chess.js","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/display-name","kind":"import-statement","external":true},{"path":"@dxos/invariant","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},{"path":"packages/plugins/plugin-chess/src/components/Chessboard/index.ts","kind":"import-statement","original":"./Chessboard"}],"format":"esm"},"packages/plugins/plugin-chess/src/components/ChessContainer.tsx":{"bytes":2405,"imports":[{"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/Chess.tsx","kind":"import-statement","original":"./Chess"}],"format":"esm"},"packages/plugins/plugin-chess/src/components/index.ts":{"bytes":798,"imports":[{"path":"react","kind":"import-statement","external":true},{"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":2649,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","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/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":1080,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"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":1819,"imports":[{"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":6788,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","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":592,"imports":[{"path":"packages/plugins/plugin-chess/src/ChessPlugin.tsx","kind":"import-statement","original":"./ChessPlugin"},{"path":"packages/plugins/plugin-chess/src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"}},"outputs":{"packages/plugins/plugin-chess/dist/lib/node/index.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":4360},"packages/plugins/plugin-chess/dist/lib/node/index.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-3BLH7NRV.cjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/dist/lib/node/intent-resolver-VTB6P3IL.cjs","kind":"dynamic-import"},{"path":"packages/plugins/plugin-chess/dist/lib/node/react-surface-PO42G64E.cjs","kind":"dynamic-import"}],"exports":["CHESS_PLUGIN","ChessPlugin","meta"],"entryPoint":"packages/plugins/plugin-chess/src/index.ts","inputs":{"packages/plugins/plugin-chess/src/ChessPlugin.tsx":{"bytesInOutput":1355},"packages/plugins/plugin-chess/src/capabilities/index.ts":{"bytesInOutput":190},"packages/plugins/plugin-chess/src/translations.ts":{"bytesInOutput":324},"packages/plugins/plugin-chess/src/index.ts":{"bytesInOutput":0}},"bytes":2266},"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-3BLH7NRV.cjs","kind":"import-statement"}],"exports":["ChessAction","GameType","MoveSchema","isObject"],"entryPoint":"packages/plugins/plugin-chess/src/types/index.ts","inputs":{},"bytes":192},"packages/plugins/plugin-chess/dist/lib/node/intent-resolver-VTB6P3IL.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":978},"packages/plugins/plugin-chess/dist/lib/node/intent-resolver-VTB6P3IL.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-3BLH7NRV.cjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/live-object","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":323}},"bytes":562},"packages/plugins/plugin-chess/dist/lib/node/ChessContainer-XRP7D63X.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":47068},"packages/plugins/plugin-chess/dist/lib/node/ChessContainer-XRP7D63X.cjs":{"imports":[{"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":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"chess.js","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/display-name","kind":"import-statement","external":true},{"path":"@dxos/invariant","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},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"chess.js","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-chessboard","kind":"import-statement","external":true},{"path":"react-resize-detector","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react","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":495},"packages/plugins/plugin-chess/src/components/Chess.tsx":{"bytesInOutput":3989},"packages/plugins/plugin-chess/src/components/Chessboard/Chessboard.tsx":{"bytesInOutput":2364},"packages/plugins/plugin-chess/src/components/Chessboard/pieces/custom.tsx":{"bytesInOutput":12536},"packages/plugins/plugin-chess/src/components/Chessboard/pieces/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-chess/src/components/Chessboard/pieces/phosphor.tsx":{"bytesInOutput":1678},"packages/plugins/plugin-chess/src/components/Chessboard/pieces/riohacha.tsx":{"bytesInOutput":11516},"packages/plugins/plugin-chess/src/components/Chessboard/index.ts":{"bytesInOutput":0}},"bytes":33320},"packages/plugins/plugin-chess/dist/lib/node/react-surface-PO42G64E.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1559},"packages/plugins/plugin-chess/dist/lib/node/react-surface-PO42G64E.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-3BLH7NRV.cjs","kind":"import-statement"},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/dist/lib/node/ChessContainer-XRP7D63X.cjs","kind":"dynamic-import"}],"exports":["default"],"entryPoint":"packages/plugins/plugin-chess/src/capabilities/react-surface.tsx","inputs":{"packages/plugins/plugin-chess/src/capabilities/react-surface.tsx":{"bytesInOutput":434},"packages/plugins/plugin-chess/src/components/index.ts":{"bytesInOutput":104}},"bytes":900},"packages/plugins/plugin-chess/dist/lib/node/chunk-3BLH7NRV.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":3210},"packages/plugins/plugin-chess/dist/lib/node/chunk-3BLH7NRV.cjs":{"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/live-object","kind":"import-statement","external":true}],"exports":["CHESS_PLUGIN","ChessAction","GameType","MoveSchema","isObject","meta"],"inputs":{"packages/plugins/plugin-chess/src/types/schema.ts":{"bytesInOutput":430},"packages/plugins/plugin-chess/src/types/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-chess/src/types/types.ts":{"bytesInOutput":558},"packages/plugins/plugin-chess/src/meta.ts":{"bytesInOutput":247}},"bytes":1573}}}
1
+ {"inputs":{"packages/plugins/plugin-chess/src/types/schema.ts":{"bytes":2461,"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-chess/src/meta.ts":{"bytes":2089,"imports":[],"format":"esm"},"packages/plugins/plugin-chess/src/types/types.ts":{"bytes":2799,"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/live-object","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":586,"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/intent-resolver.ts":{"bytes":2167,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/live-object","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/PlayerSelector.tsx":{"bytes":8757,"imports":[{"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":6004,"imports":[{"path":"chess.js","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-gameboard","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"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":798,"imports":[{"path":"react","kind":"import-statement","external":true},{"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":2649,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","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/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":1080,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"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":1819,"imports":[{"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":6685,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","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":592,"imports":[{"path":"packages/plugins/plugin-chess/src/ChessPlugin.tsx","kind":"import-statement","original":"./ChessPlugin"},{"path":"packages/plugins/plugin-chess/src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"}},"outputs":{"packages/plugins/plugin-chess/dist/lib/node/index.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":4298},"packages/plugins/plugin-chess/dist/lib/node/index.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-BEZSGC5V.cjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/dist/lib/node/intent-resolver-2YYMQ2H5.cjs","kind":"dynamic-import"},{"path":"packages/plugins/plugin-chess/dist/lib/node/react-surface-IOAB5AXZ.cjs","kind":"dynamic-import"}],"exports":["CHESS_PLUGIN","ChessPlugin","meta"],"entryPoint":"packages/plugins/plugin-chess/src/index.ts","inputs":{"packages/plugins/plugin-chess/src/ChessPlugin.tsx":{"bytesInOutput":1336},"packages/plugins/plugin-chess/src/capabilities/index.ts":{"bytesInOutput":190},"packages/plugins/plugin-chess/src/translations.ts":{"bytesInOutput":324},"packages/plugins/plugin-chess/src/index.ts":{"bytesInOutput":0}},"bytes":2247},"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-BEZSGC5V.cjs","kind":"import-statement"}],"exports":["ChessAction","GameType","MoveSchema","isObject"],"entryPoint":"packages/plugins/plugin-chess/src/types/index.ts","inputs":{},"bytes":192},"packages/plugins/plugin-chess/dist/lib/node/intent-resolver-2YYMQ2H5.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1071},"packages/plugins/plugin-chess/dist/lib/node/intent-resolver-2YYMQ2H5.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-BEZSGC5V.cjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/live-object","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":360}},"bytes":599},"packages/plugins/plugin-chess/dist/lib/node/ChessContainer-ZFOCAXZL.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":7737},"packages/plugins/plugin-chess/dist/lib/node/ChessContainer-ZFOCAXZL.cjs":{"imports":[{"path":"chess.js","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-gameboard","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","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":1501},"packages/plugins/plugin-chess/src/components/PlayerSelector.tsx":{"bytesInOutput":2299}},"bytes":4104},"packages/plugins/plugin-chess/dist/lib/node/react-surface-IOAB5AXZ.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1559},"packages/plugins/plugin-chess/dist/lib/node/react-surface-IOAB5AXZ.cjs":{"imports":[{"path":"packages/plugins/plugin-chess/dist/lib/node/chunk-BEZSGC5V.cjs","kind":"import-statement"},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-chess/dist/lib/node/ChessContainer-ZFOCAXZL.cjs","kind":"dynamic-import"}],"exports":["default"],"entryPoint":"packages/plugins/plugin-chess/src/capabilities/react-surface.tsx","inputs":{"packages/plugins/plugin-chess/src/capabilities/react-surface.tsx":{"bytesInOutput":434},"packages/plugins/plugin-chess/src/components/index.ts":{"bytesInOutput":104}},"bytes":900},"packages/plugins/plugin-chess/dist/lib/node/chunk-BEZSGC5V.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":3507},"packages/plugins/plugin-chess/dist/lib/node/chunk-BEZSGC5V.cjs":{"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/live-object","kind":"import-statement","external":true}],"exports":["CHESS_PLUGIN","ChessAction","GameType","MoveSchema","isObject","meta"],"inputs":{"packages/plugins/plugin-chess/src/types/schema.ts":{"bytesInOutput":430},"packages/plugins/plugin-chess/src/types/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-chess/src/types/types.ts":{"bytesInOutput":558},"packages/plugins/plugin-chess/src/meta.ts":{"bytesInOutput":513}},"bytes":1839}}}
@@ -26,26 +26,26 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var react_surface_PO42G64E_exports = {};
30
- __export(react_surface_PO42G64E_exports, {
29
+ var react_surface_IOAB5AXZ_exports = {};
30
+ __export(react_surface_IOAB5AXZ_exports, {
31
31
  default: () => react_surface_default
32
32
  });
33
- module.exports = __toCommonJS(react_surface_PO42G64E_exports);
34
- var import_chunk_3BLH7NRV = require("./chunk-3BLH7NRV.cjs");
33
+ module.exports = __toCommonJS(react_surface_IOAB5AXZ_exports);
34
+ var import_chunk_BEZSGC5V = require("./chunk-BEZSGC5V.cjs");
35
35
  var import_react = __toESM(require("react"));
36
36
  var import_app_framework = require("@dxos/app-framework");
37
37
  var import_react2 = require("react");
38
- var ChessContainer = (0, import_react2.lazy)(() => import("./ChessContainer-XRP7D63X.cjs"));
38
+ var ChessContainer = (0, import_react2.lazy)(() => import("./ChessContainer-ZFOCAXZL.cjs"));
39
39
  var react_surface_default = () => (0, import_app_framework.contributes)(import_app_framework.Capabilities.ReactSurface, (0, import_app_framework.createSurface)({
40
- id: import_chunk_3BLH7NRV.CHESS_PLUGIN,
40
+ id: import_chunk_BEZSGC5V.CHESS_PLUGIN,
41
41
  role: [
42
42
  "article",
43
43
  "section"
44
44
  ],
45
- filter: (data) => (0, import_chunk_3BLH7NRV.isObject)(data.subject),
45
+ filter: (data) => (0, import_chunk_BEZSGC5V.isObject)(data.subject),
46
46
  component: ({ data, role }) => /* @__PURE__ */ import_react.default.createElement(ChessContainer, {
47
47
  game: data.subject,
48
48
  role
49
49
  })
50
50
  }));
51
- //# sourceMappingURL=react-surface-PO42G64E.cjs.map
51
+ //# sourceMappingURL=react-surface-IOAB5AXZ.cjs.map
@@ -18,13 +18,13 @@ var __copyProps = (to, from, except, desc) => {
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
19
  var types_exports = {};
20
20
  __export(types_exports, {
21
- ChessAction: () => import_chunk_3BLH7NRV.ChessAction,
22
- GameType: () => import_chunk_3BLH7NRV.GameType,
23
- MoveSchema: () => import_chunk_3BLH7NRV.MoveSchema,
24
- isObject: () => import_chunk_3BLH7NRV.isObject
21
+ ChessAction: () => import_chunk_BEZSGC5V.ChessAction,
22
+ GameType: () => import_chunk_BEZSGC5V.GameType,
23
+ MoveSchema: () => import_chunk_BEZSGC5V.MoveSchema,
24
+ isObject: () => import_chunk_BEZSGC5V.isObject
25
25
  });
26
26
  module.exports = __toCommonJS(types_exports);
27
- var import_chunk_3BLH7NRV = require("../chunk-3BLH7NRV.cjs");
27
+ var import_chunk_BEZSGC5V = require("../chunk-BEZSGC5V.cjs");
28
28
  // Annotate the CommonJS export names for ESM import in node:
29
29
  0 && (module.exports = {
30
30
  ChessAction,
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["index.cjs"],
4
- "sourcesContent": ["import {\n ChessAction,\n GameType,\n MoveSchema,\n isObject\n} from \"../chunk-3BLH7NRV.cjs\";\nexport {\n ChessAction,\n GameType,\n MoveSchema,\n isObject\n};\n//# sourceMappingURL=index.cjs.map\n"],
4
+ "sourcesContent": ["import {\n ChessAction,\n GameType,\n MoveSchema,\n isObject\n} from \"../chunk-BEZSGC5V.cjs\";\nexport {\n ChessAction,\n GameType,\n MoveSchema,\n isObject\n};\n//# sourceMappingURL=index.cjs.map\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,4BAKO;",
6
6
  "names": []
7
7
  }
@@ -0,0 +1,108 @@
1
+ import { createRequire } from 'node:module';const require = createRequire(import.meta.url);
2
+
3
+ // packages/plugins/plugin-chess/src/components/ChessContainer.tsx
4
+ import { Chess } from "chess.js";
5
+ import React2, { useCallback, useEffect, useMemo } from "react";
6
+ import { getSpace } from "@dxos/react-client/echo";
7
+ import { ChessModel, Board, Chessboard } from "@dxos/react-ui-gameboard";
8
+ import { StackItem } from "@dxos/react-ui-stack";
9
+
10
+ // packages/plugins/plugin-chess/src/components/PlayerSelector.tsx
11
+ import { CrownCross } from "@phosphor-icons/react";
12
+ import React from "react";
13
+ import { generateName } from "@dxos/display-name";
14
+ import { useMembers } from "@dxos/react-client/echo";
15
+ import { Input, Select, useThemeContext } from "@dxos/react-ui";
16
+ import { getSize, mx } from "@dxos/react-ui-theme";
17
+ var PlayerSelector = ({ game, space }) => {
18
+ const members = useMembers(space.key);
19
+ return /* @__PURE__ */ React.createElement("div", {
20
+ role: "none",
21
+ className: "grid grid-cols-2 gap-8"
22
+ }, /* @__PURE__ */ React.createElement("div", {
23
+ role: "none",
24
+ className: "flex flex-row-reverse items-center gap-2"
25
+ }, /* @__PURE__ */ React.createElement(PlayerSelect, {
26
+ side: "white",
27
+ value: game.playerWhite,
28
+ onValueChange: (player) => game.playerWhite = player,
29
+ members
30
+ })), /* @__PURE__ */ React.createElement("div", {
31
+ role: "none",
32
+ className: "flex flex-row items-center gap-2"
33
+ }, /* @__PURE__ */ React.createElement(PlayerSelect, {
34
+ side: "black",
35
+ value: game.playerBlack,
36
+ onValueChange: (player) => game.playerBlack = player,
37
+ members
38
+ })));
39
+ };
40
+ var PlayerSelect = ({ side, value, onValueChange, members }) => {
41
+ const { themeMode } = useThemeContext();
42
+ const iconFillMode = side === "black" && themeMode === "light" || side === "white" && themeMode === "dark" ? "fill" : void 0;
43
+ return /* @__PURE__ */ React.createElement(Input.Root, null, /* @__PURE__ */ React.createElement(Input.Label, null, /* @__PURE__ */ React.createElement(CrownCross, {
44
+ className: mx(getSize(6)),
45
+ weight: iconFillMode,
46
+ "aria-label": `Chess icon for side ${side}`
47
+ })), /* @__PURE__ */ React.createElement(Select.Root, {
48
+ value,
49
+ onValueChange
50
+ }, /* @__PURE__ */ React.createElement(Select.TriggerButton, {
51
+ placeholder: "Select player"
52
+ }), /* @__PURE__ */ React.createElement(Select.Portal, null, /* @__PURE__ */ React.createElement(Select.Content, null, /* @__PURE__ */ React.createElement(Select.Viewport, null, members.map((member) => {
53
+ const memberKey = member.identity.identityKey.toHex();
54
+ const displayName = member.identity?.profile?.displayName || generateName(memberKey);
55
+ return /* @__PURE__ */ React.createElement(Select.Option, {
56
+ key: memberKey,
57
+ value: memberKey
58
+ }, displayName);
59
+ }))))));
60
+ };
61
+
62
+ // packages/plugins/plugin-chess/src/components/ChessContainer.tsx
63
+ var ChessContainer = ({ game }) => {
64
+ const model = useMemo(() => new ChessModel(), []);
65
+ useEffect(() => {
66
+ if (!model || game.pgn !== model?.game.pgn()) {
67
+ const chess = new Chess();
68
+ if (game.pgn) {
69
+ chess.loadPgn(game.pgn);
70
+ }
71
+ model.initialize(chess.fen());
72
+ }
73
+ }, [
74
+ game.pgn
75
+ ]);
76
+ const space = getSpace(game);
77
+ if (!space) {
78
+ return null;
79
+ }
80
+ const handleDrop = useCallback((move) => {
81
+ if (model.makeMove(move)) {
82
+ game.pgn = model.game.pgn();
83
+ return true;
84
+ }
85
+ return false;
86
+ }, [
87
+ model
88
+ ]);
89
+ return /* @__PURE__ */ React2.createElement(StackItem.Content, {
90
+ toolbar: false
91
+ }, /* @__PURE__ */ React2.createElement("div", {
92
+ role: "none",
93
+ className: "grid grid-rows-[60px_1fr_60px] grow overflow-hidden"
94
+ }, /* @__PURE__ */ React2.createElement("div", null), /* @__PURE__ */ React2.createElement("div", {
95
+ className: "flex m-4 overflow-hidden"
96
+ }, /* @__PURE__ */ React2.createElement(Board.Root, {
97
+ model,
98
+ onDrop: handleDrop
99
+ }, /* @__PURE__ */ React2.createElement(Chessboard, null))), /* @__PURE__ */ React2.createElement(PlayerSelector, {
100
+ space,
101
+ game
102
+ })));
103
+ };
104
+ var ChessContainer_default = ChessContainer;
105
+ export {
106
+ ChessContainer_default as default
107
+ };
108
+ //# sourceMappingURL=ChessContainer-DF6IFM2R.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/components/ChessContainer.tsx", "../../../src/components/PlayerSelector.tsx"],
4
+ "sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { Chess } from 'chess.js';\nimport React, { useCallback, useEffect, useMemo } from 'react';\n\nimport { getSpace } from '@dxos/react-client/echo';\nimport { ChessModel, Board, Chessboard, type BoardRootProps } from '@dxos/react-ui-gameboard';\nimport { StackItem } from '@dxos/react-ui-stack';\n\nimport { PlayerSelector } from './PlayerSelector';\nimport { type GameType } from '../types';\n\nconst ChessContainer = ({ game }: { game: GameType; role?: string }) => {\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 chess.loadPgn(game.pgn);\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 return true;\n }\n\n return false;\n },\n [model],\n );\n\n return (\n <StackItem.Content toolbar={false}>\n <div role='none' className='grid grid-rows-[60px_1fr_60px] grow overflow-hidden'>\n <div />\n\n <div className='flex m-4 overflow-hidden'>\n <Board.Root model={model} onDrop={handleDrop}>\n <Chessboard />\n </Board.Root>\n </div>\n\n <PlayerSelector space={space} game={game} />\n </div>\n </StackItem.Content>\n );\n};\n\nexport default ChessContainer;\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { CrownCross } from '@phosphor-icons/react';\nimport React from 'react';\n\nimport { generateName } from '@dxos/display-name';\nimport { useMembers, type Space, type SpaceMember } from '@dxos/react-client/echo';\nimport { Input, Select, useThemeContext } from '@dxos/react-ui';\nimport { getSize, mx } from '@dxos/react-ui-theme';\n\nimport { type GameType } from '../types';\n\nexport const PlayerSelector = ({ game, space }: { game: GameType; space: Space }) => {\n const members = useMembers(space.key);\n\n return (\n <div role='none' className='grid grid-cols-2 gap-8'>\n <div role='none' className='flex flex-row-reverse items-center gap-2'>\n <PlayerSelect\n side='white'\n value={game.playerWhite}\n onValueChange={(player) => (game.playerWhite = player)}\n members={members}\n />\n </div>\n <div role='none' className='flex flex-row items-center gap-2'>\n <PlayerSelect\n side='black'\n value={game.playerBlack}\n onValueChange={(player) => (game.playerBlack = player)}\n members={members}\n />\n </div>\n </div>\n );\n};\n\nconst PlayerSelect = ({\n side,\n value,\n onValueChange,\n members,\n}: {\n side: 'white' | 'black';\n value: string | undefined;\n onValueChange: (player: string) => void;\n members: SpaceMember[];\n}) => {\n const { themeMode } = useThemeContext();\n const iconFillMode =\n (side === 'black' && themeMode === 'light') || (side === 'white' && themeMode === 'dark') ? 'fill' : undefined;\n\n return (\n <Input.Root>\n <Input.Label>\n <CrownCross className={mx(getSize(6))} weight={iconFillMode} aria-label={`Chess icon for side ${side}`} />\n </Input.Label>\n <Select.Root value={value} onValueChange={onValueChange}>\n <Select.TriggerButton placeholder={'Select player'} />\n <Select.Portal>\n <Select.Content>\n <Select.Viewport>\n {members.map((member) => {\n const memberKey = member.identity.identityKey.toHex();\n const displayName = member.identity?.profile?.displayName || generateName(memberKey);\n return (\n <Select.Option key={memberKey} value={memberKey}>\n {displayName}\n </Select.Option>\n );\n })}\n </Select.Viewport>\n </Select.Content>\n </Select.Portal>\n </Select.Root>\n </Input.Root>\n );\n};\n"],
5
+ "mappings": ";;;AAIA,SAASA,aAAa;AACtB,OAAOC,UAASC,aAAaC,WAAWC,eAAe;AAEvD,SAASC,gBAAgB;AACzB,SAASC,YAAYC,OAAOC,kBAAuC;AACnE,SAASC,iBAAiB;;;ACL1B,SAASC,kBAAkB;AAC3B,OAAOC,WAAW;AAElB,SAASC,oBAAoB;AAC7B,SAASC,kBAAgD;AACzD,SAASC,OAAOC,QAAQC,uBAAuB;AAC/C,SAASC,SAASC,UAAU;AAIrB,IAAMC,iBAAiB,CAAC,EAAEC,MAAMC,MAAK,MAAoC;AAC9E,QAAMC,UAAUC,WAAWF,MAAMG,GAAG;AAEpC,SACE,sBAAA,cAACC,OAAAA;IAAIC,MAAK;IAAOC,WAAU;KACzB,sBAAA,cAACF,OAAAA;IAAIC,MAAK;IAAOC,WAAU;KACzB,sBAAA,cAACC,cAAAA;IACCC,MAAK;IACLC,OAAOV,KAAKW;IACZC,eAAe,CAACC,WAAYb,KAAKW,cAAcE;IAC/CX;OAGJ,sBAAA,cAACG,OAAAA;IAAIC,MAAK;IAAOC,WAAU;KACzB,sBAAA,cAACC,cAAAA;IACCC,MAAK;IACLC,OAAOV,KAAKc;IACZF,eAAe,CAACC,WAAYb,KAAKc,cAAcD;IAC/CX;;AAKV;AAEA,IAAMM,eAAe,CAAC,EACpBC,MACAC,OACAE,eACAV,QAAO,MAMR;AACC,QAAM,EAAEa,UAAS,IAAKC,gBAAAA;AACtB,QAAMC,eACHR,SAAS,WAAWM,cAAc,WAAaN,SAAS,WAAWM,cAAc,SAAU,SAASG;AAEvG,SACE,sBAAA,cAACC,MAAMC,MAAI,MACT,sBAAA,cAACD,MAAME,OAAK,MACV,sBAAA,cAACC,YAAAA;IAAWf,WAAWgB,GAAGC,QAAQ,CAAA,CAAA;IAAKC,QAAQR;IAAcS,cAAY,uBAAuBjB,IAAAA;OAElG,sBAAA,cAACkB,OAAOP,MAAI;IAACV;IAAcE;KACzB,sBAAA,cAACe,OAAOC,eAAa;IAACC,aAAa;MACnC,sBAAA,cAACF,OAAOG,QAAM,MACZ,sBAAA,cAACH,OAAOI,SAAO,MACb,sBAAA,cAACJ,OAAOK,UAAQ,MACb9B,QAAQ+B,IAAI,CAACC,WAAAA;AACZ,UAAMC,YAAYD,OAAOE,SAASC,YAAYC,MAAK;AACnD,UAAMC,cAAcL,OAAOE,UAAUI,SAASD,eAAeE,aAAaN,SAAAA;AAC1E,WACE,sBAAA,cAACR,OAAOe,QAAM;MAACtC,KAAK+B;MAAWzB,OAAOyB;OACnCI,WAAAA;EAGP,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAOd;;;ADjEA,IAAMI,iBAAiB,CAAC,EAAEC,KAAI,MAAqC;AACjE,QAAMC,QAAQC,QAAQ,MAAM,IAAIC,WAAAA,GAAc,CAAA,CAAE;AAChDC,YAAU,MAAA;AACR,QAAI,CAACH,SAASD,KAAKK,QAAQJ,OAAOD,KAAKK,IAAAA,GAAO;AAC5C,YAAMC,QAAQ,IAAIC,MAAAA;AAClB,UAAIP,KAAKK,KAAK;AACZC,cAAME,QAAQR,KAAKK,GAAG;MACxB;AAEAJ,YAAMQ,WAAWH,MAAMI,IAAG,CAAA;IAC5B;EACF,GAAG;IAACV,KAAKK;GAAI;AAEb,QAAMM,QAAQC,SAASZ,IAAAA;AACvB,MAAI,CAACW,OAAO;AACV,WAAO;EACT;AAEA,QAAME,aAAaC,YACjB,CAACC,SAAAA;AACC,QAAId,MAAMe,SAASD,IAAAA,GAAO;AACxBf,WAAKK,MAAMJ,MAAMD,KAAKK,IAAG;AACzB,aAAO;IACT;AAEA,WAAO;EACT,GACA;IAACJ;GAAM;AAGT,SACE,gBAAAgB,OAAA,cAACC,UAAUC,SAAO;IAACC,SAAS;KAC1B,gBAAAH,OAAA,cAACI,OAAAA;IAAIC,MAAK;IAAOC,WAAU;KACzB,gBAAAN,OAAA,cAACI,OAAAA,IAAAA,GAED,gBAAAJ,OAAA,cAACI,OAAAA;IAAIE,WAAU;KACb,gBAAAN,OAAA,cAACO,MAAMC,MAAI;IAACxB;IAAcyB,QAAQb;KAChC,gBAAAI,OAAA,cAACU,YAAAA,IAAAA,CAAAA,CAAAA,GAIL,gBAAAV,OAAA,cAACW,gBAAAA;IAAejB;IAAcX;;AAItC;AAEA,IAAA,yBAAeD;",
6
+ "names": ["Chess", "React", "useCallback", "useEffect", "useMemo", "getSpace", "ChessModel", "Board", "Chessboard", "StackItem", "CrownCross", "React", "generateName", "useMembers", "Input", "Select", "useThemeContext", "getSize", "mx", "PlayerSelector", "game", "space", "members", "useMembers", "key", "div", "role", "className", "PlayerSelect", "side", "value", "playerWhite", "onValueChange", "player", "playerBlack", "themeMode", "useThemeContext", "iconFillMode", "undefined", "Input", "Root", "Label", "CrownCross", "mx", "getSize", "weight", "aria-label", "Select", "TriggerButton", "placeholder", "Portal", "Content", "Viewport", "map", "member", "memberKey", "identity", "identityKey", "toHex", "displayName", "profile", "generateName", "Option", "ChessContainer", "game", "model", "useMemo", "ChessModel", "useEffect", "pgn", "chess", "Chess", "loadPgn", "initialize", "fen", "space", "getSpace", "handleDrop", "useCallback", "move", "makeMove", "React", "StackItem", "Content", "toolbar", "div", "role", "className", "Board", "Root", "onDrop", "Chessboard", "PlayerSelector"]
7
+ }
@@ -30,9 +30,12 @@ var CHESS_PLUGIN = "dxos.org/plugin/chess";
30
30
  var meta = {
31
31
  id: CHESS_PLUGIN,
32
32
  name: "Chess",
33
- description: "Play chess.",
33
+ 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. ",
34
34
  icon: "ph--shield-chevron--regular",
35
- source: "https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-chess"
35
+ source: "https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-chess",
36
+ screenshots: [
37
+ "https://dxos.network/plugin-details-chess-dark.png"
38
+ ]
36
39
  };
37
40
 
38
41
  // packages/plugins/plugin-chess/src/types/types.ts
@@ -62,4 +65,4 @@ export {
62
65
  ChessAction,
63
66
  isObject
64
67
  };
65
- //# sourceMappingURL=chunk-M2CRYWX5.mjs.map
68
+ //# sourceMappingURL=chunk-A6KO5IFZ.mjs.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/types/schema.ts", "../../../src/types/types.ts", "../../../src/meta.ts"],
4
- "sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { S, TypedObject } from '@dxos/echo-schema';\n\nexport const MoveSchema = S.mutable(\n S.partial(\n S.Struct({\n source: S.String,\n target: S.String,\n piece: S.String,\n }),\n ),\n);\n\nexport class GameType extends TypedObject({ typename: 'dxos.org/type/Chess', version: '0.1.0' })(\n {\n name: S.optional(S.String),\n playerWhite: S.String,\n playerBlack: S.String,\n moves: S.mutable(S.Array(S.String)),\n pgn: S.String,\n },\n { partial: true },\n) {}\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { S } from '@dxos/echo-schema';\nimport { isReactiveObject } from '@dxos/live-object';\n\nimport { GameType } from './schema';\nimport { CHESS_PLUGIN } from '../meta';\n\nexport namespace ChessAction {\n const CHESS_ACTION = `${CHESS_PLUGIN}/action`;\n\n export class Create extends S.TaggedClass<Create>()(`${CHESS_ACTION}/create`, {\n input: S.Struct({\n name: S.optional(S.String),\n }),\n output: S.Struct({\n object: GameType,\n }),\n }) {}\n}\n\nexport const isObject = (object: unknown): object is GameType => {\n return isReactiveObject(object) && object instanceof GameType;\n};\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 = {\n id: CHESS_PLUGIN,\n name: 'Chess',\n description: 'Play chess.',\n icon: 'ph--shield-chevron--regular',\n source: 'https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-chess',\n} satisfies PluginMeta;\n"],
5
- "mappings": ";;;AAIA,SAASA,GAAGC,mBAAmB;AAExB,IAAMC,aAAaC,EAAEC,QAC1BD,EAAEE,QACAF,EAAEG,OAAO;EACPC,QAAQJ,EAAEK;EACVC,QAAQN,EAAEK;EACVE,OAAOP,EAAEK;AACX,CAAA,CAAA,CAAA;AAIG,IAAMG,WAAN,cAAuBC,YAAY;EAAEC,UAAU;EAAuBC,SAAS;AAAQ,CAAA,EAC5F;EACEC,MAAMZ,EAAEa,SAASb,EAAEK,MAAM;EACzBS,aAAad,EAAEK;EACfU,aAAaf,EAAEK;EACfW,OAAOhB,EAAEC,QAAQD,EAAEiB,MAAMjB,EAAEK,MAAM,CAAA;EACjCa,KAAKlB,EAAEK;AACT,GACA;EAAEH,SAAS;AAAK,CAAA,EAAA;AACf;;;ACrBH,SAASiB,KAAAA,UAAS;AAClB,SAASC,wBAAwB;;;ACC1B,IAAMC,eAAe;AAErB,IAAMC,OAAO;EAClBC,IAAIF;EACJG,MAAM;EACNC,aAAa;EACbC,MAAM;EACNC,QAAQ;AACV;;;;UDJiBC,cAAAA;AACf,QAAMC,eAAe,GAAGC,YAAAA;EAEjB,MAAMC,eAAeC,GAAEC,YAAW,EAAW,GAAGJ,YAAAA,WAAuB;IAC5EK,OAAOF,GAAEG,OAAO;MACdC,MAAMJ,GAAEK,SAASL,GAAEM,MAAM;IAC3B,CAAA;IACAC,QAAQP,GAAEG,OAAO;MACfK,QAAQC;IACV,CAAA;EACF,CAAA,EAAA;EAAI;eAPSV,SAAAA;AAQf,GAXiBH,gBAAAA,cAAAA,CAAAA,EAAAA;AAaV,IAAMc,WAAW,CAACF,WAAAA;AACvB,SAAOG,iBAAiBH,MAAAA,KAAWA,kBAAkBC;AACvD;",
6
- "names": ["S", "TypedObject", "MoveSchema", "S", "mutable", "partial", "Struct", "source", "String", "target", "piece", "GameType", "TypedObject", "typename", "version", "name", "optional", "playerWhite", "playerBlack", "moves", "Array", "pgn", "S", "isReactiveObject", "CHESS_PLUGIN", "meta", "id", "name", "description", "icon", "source", "ChessAction", "CHESS_ACTION", "CHESS_PLUGIN", "Create", "S", "TaggedClass", "input", "Struct", "name", "optional", "String", "output", "object", "GameType", "isObject", "isReactiveObject"]
4
+ "sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { S, TypedObject } from '@dxos/echo-schema';\n\nexport const MoveSchema = S.mutable(\n S.partial(\n S.Struct({\n source: S.String,\n target: S.String,\n piece: S.String,\n }),\n ),\n);\n\nexport class GameType extends TypedObject({ typename: 'dxos.org/type/Chess', version: '0.1.0' })(\n {\n name: S.optional(S.String),\n playerWhite: S.String,\n playerBlack: S.String,\n moves: S.mutable(S.Array(S.String)),\n pgn: S.String,\n },\n { partial: true },\n) {}\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { S } from '@dxos/echo-schema';\nimport { isReactiveObject } from '@dxos/live-object';\n\nimport { GameType } from './schema';\nimport { CHESS_PLUGIN } from '../meta';\n\nexport namespace ChessAction {\n const CHESS_ACTION = `${CHESS_PLUGIN}/action`;\n\n export class Create extends S.TaggedClass<Create>()(`${CHESS_ACTION}/create`, {\n input: S.Struct({\n name: S.optional(S.String),\n }),\n output: S.Struct({\n object: GameType,\n }),\n }) {}\n}\n\nexport const isObject = (object: unknown): object is GameType => {\n return isReactiveObject(object) && object instanceof GameType;\n};\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 = {\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} satisfies PluginMeta;\n"],
5
+ "mappings": ";;;AAIA,SAASA,GAAGC,mBAAmB;AAExB,IAAMC,aAAaC,EAAEC,QAC1BD,EAAEE,QACAF,EAAEG,OAAO;EACPC,QAAQJ,EAAEK;EACVC,QAAQN,EAAEK;EACVE,OAAOP,EAAEK;AACX,CAAA,CAAA,CAAA;AAIG,IAAMG,WAAN,cAAuBC,YAAY;EAAEC,UAAU;EAAuBC,SAAS;AAAQ,CAAA,EAC5F;EACEC,MAAMZ,EAAEa,SAASb,EAAEK,MAAM;EACzBS,aAAad,EAAEK;EACfU,aAAaf,EAAEK;EACfW,OAAOhB,EAAEC,QAAQD,EAAEiB,MAAMjB,EAAEK,MAAM,CAAA;EACjCa,KAAKlB,EAAEK;AACT,GACA;EAAEH,SAAS;AAAK,CAAA,EAAA;AACf;;;ACrBH,SAASiB,KAAAA,UAAS;AAClB,SAASC,wBAAwB;;;ACC1B,IAAMC,eAAe;AAErB,IAAMC,OAAO;EAClBC,IAAIF;EACJG,MAAM;EACNC,aACE;EACFC,MAAM;EACNC,QAAQ;EACRC,aAAa;IAAC;;AAChB;;;;UDNiBC,cAAAA;AACf,QAAMC,eAAe,GAAGC,YAAAA;EAEjB,MAAMC,eAAeC,GAAEC,YAAW,EAAW,GAAGJ,YAAAA,WAAuB;IAC5EK,OAAOF,GAAEG,OAAO;MACdC,MAAMJ,GAAEK,SAASL,GAAEM,MAAM;IAC3B,CAAA;IACAC,QAAQP,GAAEG,OAAO;MACfK,QAAQC;IACV,CAAA;EACF,CAAA,EAAA;EAAI;eAPSV,SAAAA;AAQf,GAXiBH,gBAAAA,cAAAA,CAAAA,EAAAA;AAaV,IAAMc,WAAW,CAACF,WAAAA;AACvB,SAAOG,iBAAiBH,MAAAA,KAAWA,kBAAkBC;AACvD;",
6
+ "names": ["S", "TypedObject", "MoveSchema", "S", "mutable", "partial", "Struct", "source", "String", "target", "piece", "GameType", "TypedObject", "typename", "version", "name", "optional", "playerWhite", "playerBlack", "moves", "Array", "pgn", "S", "isReactiveObject", "CHESS_PLUGIN", "meta", "id", "name", "description", "icon", "source", "screenshots", "ChessAction", "CHESS_ACTION", "CHESS_PLUGIN", "Create", "S", "TaggedClass", "input", "Struct", "name", "optional", "String", "output", "object", "GameType", "isObject", "isReactiveObject"]
7
7
  }