@fugood/bricks-project 2.23.2 → 2.23.3

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 (88) hide show
  1. package/compile/index.ts +343 -125
  2. package/package.json +4 -2
  3. package/skills/bricks-project/rules/automations.md +7 -7
  4. package/tools/deploy.ts +39 -10
  5. package/tools/mcp-server.ts +12 -9
  6. package/tools/postinstall.ts +11 -6
  7. package/tsconfig.json +16 -0
  8. package/types/bricks/Camera.ts +1 -1
  9. package/types/bricks/Chart.ts +1 -1
  10. package/types/bricks/GenerativeMedia.ts +1 -1
  11. package/types/bricks/Icon.ts +1 -1
  12. package/types/bricks/Image.ts +1 -1
  13. package/types/bricks/Items.ts +1 -1
  14. package/types/bricks/Lottie.ts +1 -1
  15. package/types/bricks/Maps.ts +1 -1
  16. package/types/bricks/QrCode.ts +1 -1
  17. package/types/bricks/Rect.ts +1 -1
  18. package/types/bricks/RichText.ts +1 -1
  19. package/types/bricks/Rive.ts +1 -1
  20. package/types/bricks/Slideshow.ts +1 -1
  21. package/types/bricks/Svg.ts +1 -1
  22. package/types/bricks/Text.ts +1 -1
  23. package/types/bricks/TextInput.ts +1 -1
  24. package/types/bricks/Video.ts +1 -1
  25. package/types/bricks/VideoStreaming.ts +1 -1
  26. package/types/bricks/WebRtcStream.ts +1 -1
  27. package/types/bricks/WebView.ts +1 -1
  28. package/types/canvas.ts +2 -2
  29. package/types/common.ts +4 -4
  30. package/types/generators/AlarmClock.ts +1 -1
  31. package/types/generators/Assistant.ts +1 -1
  32. package/types/generators/BleCentral.ts +1 -1
  33. package/types/generators/BlePeripheral.ts +1 -1
  34. package/types/generators/CanvasMap.ts +1 -1
  35. package/types/generators/CastlesPay.ts +1 -1
  36. package/types/generators/DataBank.ts +1 -1
  37. package/types/generators/File.ts +1 -1
  38. package/types/generators/GraphQl.ts +1 -1
  39. package/types/generators/Http.ts +1 -1
  40. package/types/generators/HttpServer.ts +1 -1
  41. package/types/generators/Information.ts +1 -1
  42. package/types/generators/Intent.ts +1 -1
  43. package/types/generators/Iterator.ts +1 -1
  44. package/types/generators/Keyboard.ts +1 -1
  45. package/types/generators/LlmAnthropicCompat.ts +1 -1
  46. package/types/generators/LlmAppleBuiltin.ts +1 -1
  47. package/types/generators/LlmGgml.ts +1 -1
  48. package/types/generators/LlmOnnx.ts +1 -1
  49. package/types/generators/LlmOpenAiCompat.ts +1 -1
  50. package/types/generators/LlmQualcommAiEngine.ts +1 -1
  51. package/types/generators/Mcp.ts +1 -1
  52. package/types/generators/McpServer.ts +1 -1
  53. package/types/generators/MediaFlow.ts +1 -1
  54. package/types/generators/MqttBroker.ts +1 -1
  55. package/types/generators/MqttClient.ts +1 -1
  56. package/types/generators/Question.ts +1 -1
  57. package/types/generators/RealtimeTranscription.ts +1 -1
  58. package/types/generators/RerankerGgml.ts +1 -1
  59. package/types/generators/SerialPort.ts +1 -1
  60. package/types/generators/SoundPlayer.ts +1 -1
  61. package/types/generators/SoundRecorder.ts +1 -1
  62. package/types/generators/SpeechToTextGgml.ts +1 -1
  63. package/types/generators/SpeechToTextOnnx.ts +1 -1
  64. package/types/generators/SpeechToTextPlatform.ts +1 -1
  65. package/types/generators/SqLite.ts +1 -1
  66. package/types/generators/Step.ts +1 -1
  67. package/types/generators/SttAppleBuiltin.ts +1 -1
  68. package/types/generators/Tcp.ts +1 -1
  69. package/types/generators/TcpServer.ts +1 -1
  70. package/types/generators/TextToSpeechAppleBuiltin.ts +1 -1
  71. package/types/generators/TextToSpeechGgml.ts +1 -1
  72. package/types/generators/TextToSpeechOnnx.ts +1 -1
  73. package/types/generators/TextToSpeechOpenAiLike.ts +1 -1
  74. package/types/generators/ThermalPrinter.ts +1 -1
  75. package/types/generators/Tick.ts +1 -1
  76. package/types/generators/Udp.ts +1 -1
  77. package/types/generators/VadGgml.ts +1 -1
  78. package/types/generators/VadOnnx.ts +1 -1
  79. package/types/generators/VadTraditional.ts +1 -1
  80. package/types/generators/VectorStore.ts +1 -1
  81. package/types/generators/Watchdog.ts +1 -1
  82. package/types/generators/WebCrawler.ts +1 -1
  83. package/types/generators/WebRtc.ts +1 -1
  84. package/types/generators/WebSocket.ts +1 -1
  85. package/utils/calc.ts +16 -10
  86. package/utils/id.ts +4 -0
  87. package/api/index.ts +0 -1
  88. package/api/instance.ts +0 -213
package/package.json CHANGED
@@ -1,17 +1,19 @@
1
1
  {
2
2
  "name": "@fugood/bricks-project",
3
- "version": "2.23.2",
3
+ "version": "2.23.3",
4
4
  "main": "index.ts",
5
5
  "scripts": {
6
+ "typecheck": "tsc --noEmit",
6
7
  "build": "bun scripts/build.js"
7
8
  },
8
9
  "dependencies": {
9
- "@fugood/bricks-cli": "^2.23.0",
10
+ "@fugood/bricks-cli": "^2.23.2",
10
11
  "@huggingface/gguf": "^0.3.2",
11
12
  "@iarna/toml": "^3.0.0",
12
13
  "@modelcontextprotocol/sdk": "^1.15.0",
13
14
  "@toon-format/toon": "^2.1.0",
14
15
  "@types/escodegen": "^0.0.10",
16
+ "@types/bun": "^1.3.9",
15
17
  "@types/lodash": "^4.17.12",
16
18
  "acorn": "^8.13.0",
17
19
  "escodegen": "2.1.0",
@@ -35,14 +35,14 @@ Automations can validate:
35
35
  ```typescript
36
36
  const testLoginFlow: AutomationTest = {
37
37
  __typename: 'AutomationTest',
38
- id: 'test-login-flow',
38
+ id: makeId('test'),
39
39
  title: 'Test Login Flow',
40
40
  timeout: 30000,
41
41
  trigger_type: 'launch',
42
42
  cases: [
43
43
  {
44
44
  __typename: 'TestCase',
45
- id: 'wait-login-canvas',
45
+ id: makeId('test_case'),
46
46
  name: 'Wait for login canvas',
47
47
  run: ['wait_until_canvas_change', () => mainSubspace, () => loginCanvas, 5000],
48
48
  exit_on_failed: true,
@@ -53,7 +53,7 @@ const testLoginFlow: AutomationTest = {
53
53
  },
54
54
  {
55
55
  __typename: 'TestCase',
56
- id: 'press-username',
56
+ id: makeId('test_case'),
57
57
  name: 'Press username input',
58
58
  run: ['brick_press', () => mainSubspace, () => usernameInput],
59
59
  exit_on_failed: true,
@@ -64,7 +64,7 @@ const testLoginFlow: AutomationTest = {
64
64
  },
65
65
  {
66
66
  __typename: 'TestCase',
67
- id: 'assert-username',
67
+ id: makeId('test_case'),
68
68
  name: 'Assert username value',
69
69
  run: ['assert_property', () => mainSubspace, () => usernameData, 'testuser'],
70
70
  exit_on_failed: true,
@@ -75,7 +75,7 @@ const testLoginFlow: AutomationTest = {
75
75
  },
76
76
  {
77
77
  __typename: 'TestCase',
78
- id: 'press-login',
78
+ id: makeId('test_case'),
79
79
  name: 'Press login button',
80
80
  run: ['brick_press', () => mainSubspace, () => loginButton],
81
81
  exit_on_failed: true,
@@ -86,7 +86,7 @@ const testLoginFlow: AutomationTest = {
86
86
  },
87
87
  {
88
88
  __typename: 'TestCase',
89
- id: 'wait-dashboard',
89
+ id: makeId('test_case'),
90
90
  name: 'Wait for dashboard',
91
91
  run: ['wait_until_canvas_change', () => mainSubspace, () => dashboardCanvas, 10000],
92
92
  exit_on_failed: true,
@@ -182,7 +182,7 @@ Visual regression testing with screenshot comparison:
182
182
  ```typescript
183
183
  {
184
184
  __typename: 'TestCase',
185
- id: 'screenshot-dashboard',
185
+ id: makeId('test_case'),
186
186
  name: 'Match dashboard screenshot',
187
187
  run: ['match_screenshot', 'dashboard-initial-state', 0.01, 3],
188
188
  exit_on_failed: true,
package/tools/deploy.ts CHANGED
@@ -4,29 +4,40 @@ import { parseArgs } from 'util'
4
4
  const cwd = process.cwd()
5
5
 
6
6
  const {
7
- values: { changelogs: changelogsArg, 'changelogs-file': changelogsFile, yes },
7
+ values: {
8
+ changelogs: changelogsArg,
9
+ 'changelogs-file': changelogsFile,
10
+ 'auto-commit': autoCommit,
11
+ yes,
12
+ help,
13
+ },
8
14
  } = parseArgs({
9
15
  args: Bun.argv.slice(2),
10
16
  options: {
11
17
  changelogs: { type: 'string' },
12
18
  'changelogs-file': { type: 'string' },
19
+ 'auto-commit': { type: 'boolean' },
13
20
  yes: { type: 'boolean', short: 'y' },
21
+ help: { type: 'boolean', short: 'h' },
14
22
  },
15
23
  allowPositionals: true,
16
24
  })
17
25
 
26
+ if (help) {
27
+ console.log(`Options:
28
+ --changelogs <text> Changelogs text for the release
29
+ --changelogs-file <path> Read changelogs from a file
30
+ --auto-commit Auto-commit unstaged changes before deploying
31
+ -y, --yes Skip all prompts
32
+ -h, --help Show this help message`)
33
+ process.exit(0) // eslint-disable-line unicorn/no-process-exit
34
+ }
35
+
18
36
  // Check git status
19
- const { exitCode } = await $`cd ${cwd} && git status`.nothrow()
37
+ const { exitCode } = await $`cd ${cwd} && git status`.quiet().nothrow()
20
38
  const isGitRepo = exitCode === 0
21
39
 
22
- let commitId = ''
23
- if (isGitRepo) {
24
- const unstagedChanges = await $`cd ${cwd} && git diff --name-only --diff-filter=ACMR`.text()
25
- if (unstagedChanges)
26
- throw new Error('Unstaged changes found, please commit or stash your changes before deploying')
27
-
28
- commitId = (await $`cd ${cwd} && git rev-parse HEAD`.text()).trim()
29
- } else if (!yes) {
40
+ if (!isGitRepo && !yes) {
30
41
  const confirmContinue = prompt('No git repository found, continue? (y/n)')
31
42
  if (confirmContinue !== 'y') throw new Error('Deployment cancelled')
32
43
  }
@@ -53,6 +64,24 @@ if (changelogsArg) {
53
64
  changelogs = prompt('Enter changelogs (optional, press Enter to skip):') || ''
54
65
  }
55
66
 
67
+ // Handle unstaged changes
68
+ let commitId = ''
69
+ if (isGitRepo) {
70
+ const unstagedChanges = await $`cd ${cwd} && git diff --name-only --diff-filter=ACMR`.text()
71
+ if (unstagedChanges) {
72
+ if (autoCommit) {
73
+ const commitMsg = `chore: release ${version || 'new version'}`
74
+ const commitBody = changelogs || '[no changelogs]'
75
+ await $`cd ${cwd} && git add -A && git commit -m ${commitMsg} -m ${commitBody}`
76
+ } else {
77
+ throw new Error(
78
+ 'Unstaged changes found, please commit or stash your changes before deploying',
79
+ )
80
+ }
81
+ }
82
+ commitId = (await $`cd ${cwd} && git rev-parse HEAD`.text()).trim()
83
+ }
84
+
56
85
  // Ask for confirmation
57
86
  if (!yes) {
58
87
  const confirm = prompt('Are you sure you want to deploy? (y/n)')
@@ -172,20 +172,23 @@ server.tool(
172
172
  log = `${err.stdout.toString()}\n${err.stderr.toString()}`
173
173
  error = true
174
174
  }
175
- let screenshotBase64: any = null
175
+ let screenshotBase64: string | null = null
176
176
  if (!error && responseImage) {
177
177
  const screenshot = await Bun.file(`${dirname}/screenshot.jpg`).arrayBuffer()
178
178
  screenshotBase64 = Buffer.from(screenshot).toString('base64')
179
179
  }
180
+ const content: Array<
181
+ { type: 'text'; text: string } | { type: 'image'; data: string; mimeType: string }
182
+ > = [{ type: 'text', text: log }]
183
+ if (screenshotBase64) {
184
+ content.push({
185
+ type: 'image',
186
+ data: screenshotBase64,
187
+ mimeType: 'image/jpeg',
188
+ })
189
+ }
180
190
  return {
181
- content: [
182
- { type: 'text', text: log },
183
- screenshotBase64 && {
184
- type: 'image',
185
- data: screenshotBase64,
186
- mimeType: 'image/jpeg',
187
- },
188
- ].filter(Boolean),
191
+ content,
189
192
  }
190
193
  },
191
194
  )
@@ -30,6 +30,10 @@ const projectMcpServer = {
30
30
  args: [`${cwd}/node_modules/@fugood/bricks-project/tools/mcp-server.ts`],
31
31
  }
32
32
 
33
+ type CodexMcpConfig = {
34
+ mcp_servers: Record<string, typeof projectMcpServer>
35
+ }
36
+
33
37
  const defaultMcpConfig = {
34
38
  mcpServers: {
35
39
  'bricks-project': projectMcpServer,
@@ -44,7 +48,7 @@ const handleMcpConfigOverride = async (mcpConfigPath: string) => {
44
48
  mcpConfig = JSON.parse(configStr)
45
49
  if (!mcpConfig?.mcpServers) throw new Error('mcpServers is not defined')
46
50
  mcpConfig.mcpServers['bricks-project'] = projectMcpServer
47
- } catch (e) {
51
+ } catch {
48
52
  mcpConfig = defaultMcpConfig
49
53
  }
50
54
  } else {
@@ -104,21 +108,22 @@ if (hasAgentsMd) {
104
108
  }
105
109
 
106
110
  const handleCodexMcpConfigOverride = async (mcpConfigPath: string) => {
107
- let mcpConfig: { mcp_servers: Record<string, typeof projectMcpServer> } | null = null
111
+ let mcpConfig: CodexMcpConfig | null = null
108
112
  if (await exists(mcpConfigPath)) {
109
113
  const configStr = await readFile(mcpConfigPath, 'utf-8')
110
114
  try {
111
- mcpConfig = TOML.parse(configStr)
112
- if (!mcpConfig?.mcp_servers) throw new Error('mcp_servers is not defined')
115
+ const parsed = TOML.parse(configStr) as Partial<CodexMcpConfig>
116
+ if (!parsed?.mcp_servers) throw new Error('mcp_servers is not defined')
117
+ mcpConfig = { mcp_servers: parsed.mcp_servers }
113
118
  mcpConfig.mcp_servers['bricks-project'] = projectMcpServer
114
- } catch (e) {
119
+ } catch {
115
120
  mcpConfig = defaultCodexMcpConfig
116
121
  }
117
122
  } else {
118
123
  mcpConfig = defaultCodexMcpConfig
119
124
  }
120
125
 
121
- await writeFile(mcpConfigPath, `${TOML.stringify(mcpConfig, null, 2)}\n`)
126
+ await writeFile(mcpConfigPath, `${TOML.stringify(mcpConfig)}\n`)
122
127
 
123
128
  console.log(`Updated ${mcpConfigPath}`)
124
129
  }
package/tsconfig.json ADDED
@@ -0,0 +1,16 @@
1
+ {
2
+ "compilerOptions": {
3
+ "lib": ["ESNext"],
4
+ "target": "ESNext",
5
+ "module": "ESNext",
6
+ "moduleDetection": "force",
7
+ "allowJs": true,
8
+ "resolveJsonModule": true,
9
+ "moduleResolution": "bundler",
10
+ "allowImportingTsExtensions": true,
11
+ "verbatimModuleSyntax": true,
12
+ "noEmit": true,
13
+ "skipLibCheck": true,
14
+ },
15
+ "exclude": ["node_modules"],
16
+ }
@@ -192,7 +192,7 @@ Default property:
192
192
  export type BrickCamera = Brick &
193
193
  BrickCameraDef & {
194
194
  templateKey: 'BRICK_CAMERA'
195
- switches: Array<
195
+ switches?: Array<
196
196
  SwitchDef &
197
197
  BrickCameraDef & {
198
198
  conds?: Array<{
@@ -347,7 +347,7 @@ Default property:
347
347
  export type BrickChart = Brick &
348
348
  BrickChartDef & {
349
349
  templateKey: 'BRICK_CHART'
350
- switches: Array<
350
+ switches?: Array<
351
351
  SwitchDef &
352
352
  BrickChartDef & {
353
353
  conds?: Array<{
@@ -241,7 +241,7 @@ Default property:
241
241
  export type GenerativeMedia = Brick &
242
242
  GenerativeMediaDef & {
243
243
  templateKey: 'BRICK_GENERATIVE_MEDIA'
244
- switches: Array<
244
+ switches?: Array<
245
245
  SwitchDef &
246
246
  GenerativeMediaDef & {
247
247
  conds?: Array<{
@@ -75,7 +75,7 @@ Default property:
75
75
  export type BrickIcon = Brick &
76
76
  BrickIconDef & {
77
77
  templateKey: 'BRICK_ICON'
78
- switches: Array<
78
+ switches?: Array<
79
79
  SwitchDef &
80
80
  BrickIconDef & {
81
81
  conds?: Array<{
@@ -91,7 +91,7 @@ Default property:
91
91
  export type BrickImage = Brick &
92
92
  BrickImageDef & {
93
93
  templateKey: 'BRICK_IMAGE'
94
- switches: Array<
94
+ switches?: Array<
95
95
  SwitchDef &
96
96
  BrickImageDef & {
97
97
  conds?: Array<{
@@ -437,7 +437,7 @@ Default property:
437
437
  export type BrickItems = Brick &
438
438
  BrickItemsDef & {
439
439
  templateKey: 'BRICK_ITEMS'
440
- switches: Array<
440
+ switches?: Array<
441
441
  SwitchDef &
442
442
  BrickItemsDef & {
443
443
  conds?: Array<{
@@ -141,7 +141,7 @@ Default property:
141
141
  export type BrickLottie = Brick &
142
142
  BrickLottieDef & {
143
143
  templateKey: 'BRICK_LOTTIE'
144
- switches: Array<
144
+ switches?: Array<
145
145
  SwitchDef &
146
146
  BrickLottieDef & {
147
147
  conds?: Array<{
@@ -235,7 +235,7 @@ Default property:
235
235
  export type BrickMaps = Brick &
236
236
  BrickMapsDef & {
237
237
  templateKey: 'BRICK_MAPS'
238
- switches: Array<
238
+ switches?: Array<
239
239
  SwitchDef &
240
240
  BrickMapsDef & {
241
241
  conds?: Array<{
@@ -94,7 +94,7 @@ Default property:
94
94
  export type BrickQrcode = Brick &
95
95
  BrickQrcodeDef & {
96
96
  templateKey: 'BRICK_QRCODE'
97
- switches: Array<
97
+ switches?: Array<
98
98
  SwitchDef &
99
99
  BrickQrcodeDef & {
100
100
  conds?: Array<{
@@ -92,7 +92,7 @@ Default property:
92
92
  export type BrickRect = Brick &
93
93
  BrickRectDef & {
94
94
  templateKey: 'BRICK_RECT'
95
- switches: Array<
95
+ switches?: Array<
96
96
  SwitchDef &
97
97
  BrickRectDef & {
98
98
  conds?: Array<{
@@ -105,7 +105,7 @@ Default property:
105
105
  export type BrickRichText = Brick &
106
106
  BrickRichTextDef & {
107
107
  templateKey: 'BRICK_RICH_TEXT'
108
- switches: Array<
108
+ switches?: Array<
109
109
  SwitchDef &
110
110
  BrickRichTextDef & {
111
111
  conds?: Array<{
@@ -191,7 +191,7 @@ Default property:
191
191
  export type BrickRive = Brick &
192
192
  BrickRiveDef & {
193
193
  templateKey: 'BRICK_RIVE'
194
- switches: Array<
194
+ switches?: Array<
195
195
  SwitchDef &
196
196
  BrickRiveDef & {
197
197
  conds?: Array<{
@@ -172,7 +172,7 @@ Default property:
172
172
  export type BrickSlideshow = Brick &
173
173
  BrickSlideshowDef & {
174
174
  templateKey: 'BRICK_SLIDESHOW'
175
- switches: Array<
175
+ switches?: Array<
176
176
  SwitchDef &
177
177
  BrickSlideshowDef & {
178
178
  conds?: Array<{
@@ -76,7 +76,7 @@ Default property:
76
76
  export type BrickSvg = Brick &
77
77
  BrickSvgDef & {
78
78
  templateKey: 'BRICK_SVG'
79
- switches: Array<
79
+ switches?: Array<
80
80
  SwitchDef &
81
81
  BrickSvgDef & {
82
82
  conds?: Array<{
@@ -125,7 +125,7 @@ Default property:
125
125
  export type BrickText = Brick &
126
126
  BrickTextDef & {
127
127
  templateKey: 'BRICK_TEXT'
128
- switches: Array<
128
+ switches?: Array<
129
129
  SwitchDef &
130
130
  BrickTextDef & {
131
131
  conds?: Array<{
@@ -213,7 +213,7 @@ Default property:
213
213
  export type BrickTextInput = Brick &
214
214
  BrickTextInputDef & {
215
215
  templateKey: 'BRICK_TEXT_INPUT'
216
- switches: Array<
216
+ switches?: Array<
217
217
  SwitchDef &
218
218
  BrickTextInputDef & {
219
219
  conds?: Array<{
@@ -152,7 +152,7 @@ Default property:
152
152
  export type BrickVideo = Brick &
153
153
  BrickVideoDef & {
154
154
  templateKey: 'BRICK_VIDEO'
155
- switches: Array<
155
+ switches?: Array<
156
156
  SwitchDef &
157
157
  BrickVideoDef & {
158
158
  conds?: Array<{
@@ -89,7 +89,7 @@ Default property:
89
89
  export type BrickVideoStreaming = Brick &
90
90
  BrickVideoStreamingDef & {
91
91
  templateKey: 'BRICK_VIDEO_STREAMING'
92
- switches: Array<
92
+ switches?: Array<
93
93
  SwitchDef &
94
94
  BrickVideoStreamingDef & {
95
95
  conds?: Array<{
@@ -42,7 +42,7 @@ Default property:
42
42
  export type BrickWebRTCStream = Brick &
43
43
  BrickWebRTCStreamDef & {
44
44
  templateKey: 'BRICK_WEBRTC_STREAM'
45
- switches: Array<
45
+ switches?: Array<
46
46
  SwitchDef &
47
47
  BrickWebRTCStreamDef & {
48
48
  conds?: Array<{
@@ -145,7 +145,7 @@ Default property:
145
145
  export type BrickWebView = Brick &
146
146
  BrickWebViewDef & {
147
147
  templateKey: 'BRICK_WEBVIEW'
148
- switches: Array<
148
+ switches?: Array<
149
149
  SwitchDef &
150
150
  BrickWebViewDef & {
151
151
  conds?: Array<{
package/types/canvas.ts CHANGED
@@ -36,9 +36,9 @@ interface CanvasDef {
36
36
  export type Canvas = CanvasDef & {
37
37
  __typename: 'Canvas'
38
38
  id: string
39
- title: string
39
+ title?: string
40
40
  description?: string
41
- switches: Array<
41
+ switches?: Array<
42
42
  SwitchDef &
43
43
  CanvasDef & {
44
44
  conds?: Array<{
package/types/common.ts CHANGED
@@ -7,8 +7,8 @@ export interface Brick {
7
7
  __typename: 'Brick'
8
8
  id: string
9
9
  templateKey: string
10
- title: string
11
- description: string
10
+ title?: string
11
+ description?: string
12
12
  property?: {}
13
13
  events: {}
14
14
  outlets?: {}
@@ -25,8 +25,8 @@ export interface Generator {
25
25
  __typename: 'Generator'
26
26
  id: string
27
27
  templateKey: string
28
- title: string
29
- description: string
28
+ title?: string
29
+ description?: string
30
30
  localSyncRunMode?: LocalSyncStrategy
31
31
  property?: {}
32
32
  events: {}
@@ -85,7 +85,7 @@ Default property:
85
85
  export type GeneratorAlarmClock = Generator &
86
86
  GeneratorAlarmClockDef & {
87
87
  templateKey: 'GENERATOR_ALARM_CLOCK'
88
- switches: Array<
88
+ switches?: Array<
89
89
  SwitchDef &
90
90
  GeneratorAlarmClockDef & {
91
91
  conds?: Array<{
@@ -544,7 +544,7 @@ Default property:
544
544
  export type GeneratorAssistant = Generator &
545
545
  GeneratorAssistantDef & {
546
546
  templateKey: 'GENERATOR_ASSISTANT'
547
- switches: Array<
547
+ switches?: Array<
548
548
  SwitchDef &
549
549
  GeneratorAssistantDef & {
550
550
  conds?: Array<{
@@ -208,7 +208,7 @@ Default property:
208
208
  export type GeneratorBleCentral = Generator &
209
209
  GeneratorBleCentralDef & {
210
210
  templateKey: 'GENERATOR_BLE_CENTRAL'
211
- switches: Array<
211
+ switches?: Array<
212
212
  SwitchDef &
213
213
  GeneratorBleCentralDef & {
214
214
  conds?: Array<{
@@ -185,7 +185,7 @@ Default property:
185
185
  export type GeneratorBlePeripheral = Generator &
186
186
  GeneratorBlePeripheralDef & {
187
187
  templateKey: 'GENERATOR_BLE_PERIPHERAL'
188
- switches: Array<
188
+ switches?: Array<
189
189
  SwitchDef &
190
190
  GeneratorBlePeripheralDef & {
191
191
  conds?: Array<{
@@ -51,7 +51,7 @@ Default property:
51
51
  export type GeneratorCanvasMap = Generator &
52
52
  GeneratorCanvasMapDef & {
53
53
  templateKey: 'GENERATOR_CANVAS_MAP'
54
- switches: Array<
54
+ switches?: Array<
55
55
  SwitchDef &
56
56
  GeneratorCanvasMapDef & {
57
57
  conds?: Array<{
@@ -60,7 +60,7 @@ Default property:
60
60
  export type GeneratorCastlesPay = Generator &
61
61
  GeneratorCastlesPayDef & {
62
62
  templateKey: 'GENERATOR_CASTLES_PAY'
63
- switches: Array<
63
+ switches?: Array<
64
64
  SwitchDef &
65
65
  GeneratorCastlesPayDef & {
66
66
  conds?: Array<{
@@ -106,7 +106,7 @@ Default property:
106
106
  export type GeneratorDataBank = Generator &
107
107
  GeneratorDataBankDef & {
108
108
  templateKey: 'GENERATOR_DATA_BANK'
109
- switches: Array<
109
+ switches?: Array<
110
110
  SwitchDef &
111
111
  GeneratorDataBankDef & {
112
112
  conds?: Array<{
@@ -321,7 +321,7 @@ Default property:
321
321
  export type GeneratorFile = Generator &
322
322
  GeneratorFileDef & {
323
323
  templateKey: 'GENERATOR_FILE'
324
- switches: Array<
324
+ switches?: Array<
325
325
  SwitchDef &
326
326
  GeneratorFileDef & {
327
327
  conds?: Array<{
@@ -107,7 +107,7 @@ Default property:
107
107
  export type GeneratorGraphQL = Generator &
108
108
  GeneratorGraphQLDef & {
109
109
  templateKey: 'GENERATOR_GRAPHQL'
110
- switches: Array<
110
+ switches?: Array<
111
111
  SwitchDef &
112
112
  GeneratorGraphQLDef & {
113
113
  conds?: Array<{
@@ -174,7 +174,7 @@ Default property:
174
174
  export type GeneratorHTTP = Generator &
175
175
  GeneratorHTTPDef & {
176
176
  templateKey: 'GENERATOR_HTTP'
177
- switches: Array<
177
+ switches?: Array<
178
178
  SwitchDef &
179
179
  GeneratorHTTPDef & {
180
180
  conds?: Array<{
@@ -149,7 +149,7 @@ Default property:
149
149
  export type GeneratorHTTPServer = Generator &
150
150
  GeneratorHTTPServerDef & {
151
151
  templateKey: 'GENERATOR_HTTP_SERVER'
152
- switches: Array<
152
+ switches?: Array<
153
153
  SwitchDef &
154
154
  GeneratorHTTPServerDef & {
155
155
  conds?: Array<{
@@ -80,7 +80,7 @@ Default property:
80
80
  export type GeneratorInformation = Generator &
81
81
  GeneratorInformationDef & {
82
82
  templateKey: 'GENERATOR_INFORMATION'
83
- switches: Array<
83
+ switches?: Array<
84
84
  SwitchDef &
85
85
  GeneratorInformationDef & {
86
86
  conds?: Array<{
@@ -139,7 +139,7 @@ Default property:
139
139
  export type GeneratorIntent = Generator &
140
140
  GeneratorIntentDef & {
141
141
  templateKey: 'GENERATOR_INTENT'
142
- switches: Array<
142
+ switches?: Array<
143
143
  SwitchDef &
144
144
  GeneratorIntentDef & {
145
145
  conds?: Array<{
@@ -85,7 +85,7 @@ Default property:
85
85
  export type GeneratorIterator = Generator &
86
86
  GeneratorIteratorDef & {
87
87
  templateKey: 'GENERATOR_ITERATOR'
88
- switches: Array<
88
+ switches?: Array<
89
89
  SwitchDef &
90
90
  GeneratorIteratorDef & {
91
91
  conds?: Array<{
@@ -67,7 +67,7 @@ Default property:
67
67
  export type GeneratorKeyboard = Generator &
68
68
  GeneratorKeyboardDef & {
69
69
  templateKey: 'GENERATOR_KEYBOARD'
70
- switches: Array<
70
+ switches?: Array<
71
71
  SwitchDef &
72
72
  GeneratorKeyboardDef & {
73
73
  conds?: Array<{