@fugood/bricks-project 2.23.6 → 2.23.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/compile/action-name-map.ts +6 -0
- package/compile/index.ts +64 -43
- package/compile/util.ts +2 -0
- package/package.json +2 -2
- package/skills/bricks-design/LICENSE.txt +180 -0
- package/skills/bricks-design/SKILL.md +66 -0
- package/tools/deploy.ts +2 -2
- package/tools/preview.ts +1 -1
- package/types/automation.ts +1 -1
- package/types/bricks/Camera.ts +15 -7
- package/types/bricks/Chart.ts +9 -3
- package/types/bricks/GenerativeMedia.ts +24 -8
- package/types/bricks/Icon.ts +6 -2
- package/types/bricks/Image.ts +7 -3
- package/types/bricks/Items.ts +22 -8
- package/types/bricks/Lottie.ts +12 -4
- package/types/bricks/Maps.ts +13 -5
- package/types/bricks/QrCode.ts +6 -2
- package/types/bricks/Rect.ts +6 -2
- package/types/bricks/RichText.ts +6 -2
- package/types/bricks/Rive.ts +20 -10
- package/types/bricks/Slideshow.ts +17 -7
- package/types/bricks/Svg.ts +5 -1
- package/types/bricks/Text.ts +6 -2
- package/types/bricks/TextInput.ts +13 -7
- package/types/bricks/Video.ts +8 -4
- package/types/bricks/VideoStreaming.ts +5 -1
- package/types/bricks/WebRtcStream.ts +6 -2
- package/types/bricks/WebView.ts +9 -5
- package/types/common.ts +10 -8
- package/types/generators/AlarmClock.ts +12 -6
- package/types/generators/Assistant.ts +12 -6
- package/types/generators/BleCentral.ts +19 -7
- package/types/generators/BlePeripheral.ts +6 -2
- package/types/generators/CanvasMap.ts +6 -2
- package/types/generators/CastlesPay.ts +12 -4
- package/types/generators/DataBank.ts +13 -5
- package/types/generators/File.ts +46 -16
- package/types/generators/GraphQl.ts +9 -3
- package/types/generators/Http.ts +6 -2
- package/types/generators/HttpServer.ts +14 -6
- package/types/generators/Information.ts +7 -3
- package/types/generators/Intent.ts +7 -3
- package/types/generators/Iterator.ts +9 -5
- package/types/generators/Keyboard.ts +9 -5
- package/types/generators/LlmAnthropicCompat.ts +21 -5
- package/types/generators/LlmAppleBuiltin.ts +19 -4
- package/types/generators/LlmGgml.ts +65 -6
- package/types/generators/LlmMediaTekNeuroPilot.ts +16 -5
- package/types/generators/LlmMlx.ts +22 -5
- package/types/generators/LlmOnnx.ts +16 -5
- package/types/generators/LlmOpenAiCompat.ts +25 -5
- package/types/generators/LlmQualcommAiEngine.ts +13 -5
- package/types/generators/Mcp.ts +43 -17
- package/types/generators/McpServer.ts +20 -8
- package/types/generators/MediaFlow.ts +12 -4
- package/types/generators/MqttBroker.ts +19 -7
- package/types/generators/MqttClient.ts +8 -4
- package/types/generators/Question.ts +7 -3
- package/types/generators/RealtimeTranscription.ts +26 -8
- package/types/generators/RerankerGgml.ts +20 -3
- package/types/generators/SerialPort.ts +12 -4
- package/types/generators/SoundPlayer.ts +8 -2
- package/types/generators/SoundRecorder.ts +7 -3
- package/types/generators/SpeechToTextGgml.ts +18 -4
- package/types/generators/SpeechToTextOnnx.ts +10 -3
- package/types/generators/SpeechToTextPlatform.ts +11 -3
- package/types/generators/SqLite.ts +10 -4
- package/types/generators/Step.ts +6 -2
- package/types/generators/SttAppleBuiltin.ts +16 -3
- package/types/generators/Tcp.ts +8 -4
- package/types/generators/TcpServer.ts +13 -7
- package/types/generators/TextToSpeechAppleBuiltin.ts +16 -3
- package/types/generators/TextToSpeechGgml.ts +21 -3
- package/types/generators/TextToSpeechOnnx.ts +10 -3
- package/types/generators/TextToSpeechOpenAiLike.ts +9 -3
- package/types/generators/ThermalPrinter.ts +7 -3
- package/types/generators/Tick.ts +8 -4
- package/types/generators/Udp.ts +8 -4
- package/types/generators/VadGgml.ts +12 -4
- package/types/generators/VadOnnx.ts +11 -4
- package/types/generators/VadTraditional.ts +13 -4
- package/types/generators/VectorStore.ts +7 -3
- package/types/generators/Watchdog.ts +8 -4
- package/types/generators/WebCrawler.ts +6 -2
- package/types/generators/WebRtc.ts +13 -5
- package/types/generators/WebSocket.ts +6 -2
- package/types/subspace.ts +2 -0
- package/utils/event-props.ts +833 -1059
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Generative Media brick - Generate images and videos using AI
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface GenerativeMediaDef {
|
|
17
21
|
/*
|
|
@@ -191,21 +195,33 @@ Default property:
|
|
|
191
195
|
/* Event of the brick blur (Use TV Device with controller) */
|
|
192
196
|
generativeMediaOnBlur?: Array<EventAction>
|
|
193
197
|
/* Event when media generation succeeds */
|
|
194
|
-
onSuccess?: Array<
|
|
198
|
+
onSuccess?: Array<
|
|
199
|
+
EventAction<string & keyof TemplateEventPropsMap['GenerativeMedia']['onSuccess']>
|
|
200
|
+
>
|
|
195
201
|
/* Event when media generation fails */
|
|
196
|
-
onError?: Array<EventAction
|
|
202
|
+
onError?: Array<EventAction<string & keyof TemplateEventPropsMap['GenerativeMedia']['onError']>>
|
|
197
203
|
/* Event when media prompt request starts */
|
|
198
|
-
promptStart?: Array<
|
|
204
|
+
promptStart?: Array<
|
|
205
|
+
EventAction<string & keyof TemplateEventPropsMap['GenerativeMedia']['promptStart']>
|
|
206
|
+
>
|
|
199
207
|
/* Event when media prompt request succeeds */
|
|
200
|
-
promptSuccess?: Array<
|
|
208
|
+
promptSuccess?: Array<
|
|
209
|
+
EventAction<string & keyof TemplateEventPropsMap['GenerativeMedia']['promptSuccess']>
|
|
210
|
+
>
|
|
201
211
|
/* Event when media prompt request fails */
|
|
202
|
-
promptError?: Array<
|
|
212
|
+
promptError?: Array<
|
|
213
|
+
EventAction<string & keyof TemplateEventPropsMap['GenerativeMedia']['promptError']>
|
|
214
|
+
>
|
|
203
215
|
/* Event when media loading starts */
|
|
204
216
|
loadStart?: Array<EventAction>
|
|
205
217
|
/* Event when media loading succeeds */
|
|
206
|
-
loadSuccess?: Array<
|
|
218
|
+
loadSuccess?: Array<
|
|
219
|
+
EventAction<string & keyof TemplateEventPropsMap['GenerativeMedia']['loadSuccess']>
|
|
220
|
+
>
|
|
207
221
|
/* Event when media loading fails */
|
|
208
|
-
loadError?: Array<
|
|
222
|
+
loadError?: Array<
|
|
223
|
+
EventAction<string & keyof TemplateEventPropsMap['GenerativeMedia']['loadError']>
|
|
224
|
+
>
|
|
209
225
|
}
|
|
210
226
|
outlets?: {
|
|
211
227
|
/* Brick is pressing */
|
package/types/bricks/Icon.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Display Font Awesome 6 Pro icons. Supports Solid, Regular, Light, Duotone, Thin, Brands, and Sharp styles
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface BrickIconDef {
|
|
17
21
|
/*
|
|
@@ -71,7 +75,7 @@ Default property:
|
|
|
71
75
|
}
|
|
72
76
|
}
|
|
73
77
|
|
|
74
|
-
/*
|
|
78
|
+
/* Display Font Awesome 6 Pro icons. Supports Solid, Regular, Light, Duotone, Thin, Brands, and Sharp styles */
|
|
75
79
|
export type BrickIcon = Brick &
|
|
76
80
|
BrickIconDef & {
|
|
77
81
|
templateKey: 'BRICK_ICON'
|
package/types/bricks/Image.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Display images from URL or local assets with resize modes and caching
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface BrickImageDef {
|
|
17
21
|
/*
|
|
@@ -67,7 +71,7 @@ Default property:
|
|
|
67
71
|
/* Event of the image on load */
|
|
68
72
|
onLoad?: Array<EventAction>
|
|
69
73
|
/* Event of the image on error */
|
|
70
|
-
onError?: Array<EventAction
|
|
74
|
+
onError?: Array<EventAction<string & keyof TemplateEventPropsMap['Image']['onError']>>
|
|
71
75
|
}
|
|
72
76
|
outlets?: {
|
|
73
77
|
/* Brick is pressing */
|
|
@@ -87,7 +91,7 @@ Default property:
|
|
|
87
91
|
}
|
|
88
92
|
}
|
|
89
93
|
|
|
90
|
-
/*
|
|
94
|
+
/* Display images from URL or local assets with resize modes and caching */
|
|
91
95
|
export type BrickImage = Brick &
|
|
92
96
|
BrickImageDef & {
|
|
93
97
|
templateKey: 'BRICK_IMAGE'
|
package/types/bricks/Items.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Data-driven list/grid. Maps items array to brick templates via propertyMapping, with pagination and detail mode support
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
/* prev page */
|
|
17
21
|
export type BrickItemsActionPrevPage = Action & {
|
|
@@ -397,17 +401,27 @@ Default property:
|
|
|
397
401
|
| DataLink
|
|
398
402
|
events?: BrickBasicEventsForItem & {
|
|
399
403
|
/* Event on page render finished */
|
|
400
|
-
onPageRender?: Array<
|
|
404
|
+
onPageRender?: Array<
|
|
405
|
+
EventActionForItem<string & keyof TemplateEventPropsMap['Items']['onPageRender']>
|
|
406
|
+
>
|
|
401
407
|
/* Event on page change. */
|
|
402
|
-
onPageChange?: Array<
|
|
408
|
+
onPageChange?: Array<
|
|
409
|
+
EventActionForItem<string & keyof TemplateEventPropsMap['Items']['onPageChange']>
|
|
410
|
+
>
|
|
403
411
|
/* Event on page index out of bound. */
|
|
404
|
-
onPageOutOfBound?: Array<
|
|
412
|
+
onPageOutOfBound?: Array<
|
|
413
|
+
EventActionForItem<string & keyof TemplateEventPropsMap['Items']['onPageOutOfBound']>
|
|
414
|
+
>
|
|
405
415
|
/* Event on into `detail` mode */
|
|
406
|
-
onIntoDetailMode?: Array<
|
|
416
|
+
onIntoDetailMode?: Array<
|
|
417
|
+
EventActionForItem<string & keyof TemplateEventPropsMap['Items']['onIntoDetailMode']>
|
|
418
|
+
>
|
|
407
419
|
/* Event on into `list` mode. */
|
|
408
|
-
onIntoListMode?: Array<
|
|
420
|
+
onIntoListMode?: Array<
|
|
421
|
+
EventActionForItem<string & keyof TemplateEventPropsMap['Items']['onIntoListMode']>
|
|
422
|
+
>
|
|
409
423
|
/* Event on render error */
|
|
410
|
-
onError?: Array<EventActionForItem
|
|
424
|
+
onError?: Array<EventActionForItem<string & keyof TemplateEventPropsMap['Items']['onError']>>
|
|
411
425
|
}
|
|
412
426
|
outlets?: {
|
|
413
427
|
/* Catched error message */
|
|
@@ -433,7 +447,7 @@ Default property:
|
|
|
433
447
|
}
|
|
434
448
|
}
|
|
435
449
|
|
|
436
|
-
/*
|
|
450
|
+
/* Data-driven list/grid. Maps items array to brick templates via propertyMapping, with pagination and detail mode support */
|
|
437
451
|
export type BrickItems = Brick &
|
|
438
452
|
BrickItemsDef & {
|
|
439
453
|
templateKey: 'BRICK_ITEMS'
|
package/types/bricks/Lottie.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Lottie animation player supporting .json and .dotlottie formats. Supports speed, loop, frame range control, color/text filters, and hardware rendering
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
/* Play animation */
|
|
17
21
|
export type BrickLottieActionPlay = ActionWithParams & {
|
|
@@ -112,9 +116,13 @@ Default property:
|
|
|
112
116
|
/* Event of the brick blur (Use TV Device with controller) */
|
|
113
117
|
onBlur?: Array<EventAction>
|
|
114
118
|
/* Event of the animation finished */
|
|
115
|
-
onAnimationFinish?: Array<
|
|
119
|
+
onAnimationFinish?: Array<
|
|
120
|
+
EventAction<string & keyof TemplateEventPropsMap['Lottie']['onAnimationFinish']>
|
|
121
|
+
>
|
|
116
122
|
/* Event of the uri on load failed */
|
|
117
|
-
onAnimationFailure?: Array<
|
|
123
|
+
onAnimationFailure?: Array<
|
|
124
|
+
EventAction<string & keyof TemplateEventPropsMap['Lottie']['onAnimationFailure']>
|
|
125
|
+
>
|
|
118
126
|
/* Event of the animation on loop */
|
|
119
127
|
onAnimationLoop?: Array<EventAction>
|
|
120
128
|
}
|
|
@@ -137,7 +145,7 @@ Default property:
|
|
|
137
145
|
}
|
|
138
146
|
}
|
|
139
147
|
|
|
140
|
-
/* Lottie
|
|
148
|
+
/* Lottie animation player supporting .json and .dotlottie formats. Supports speed, loop, frame range control, color/text filters, and hardware rendering */
|
|
141
149
|
export type BrickLottie = Brick &
|
|
142
150
|
BrickLottieDef & {
|
|
143
151
|
templateKey: 'BRICK_LOTTIE'
|
package/types/bricks/Maps.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Interactive map with markers, paths, and location tracking. Supports Google Maps (iOS/Android/Desktop/Web) and Apple Maps (iOS/tvOS)
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
/* Zoom in the map */
|
|
17
21
|
export type BrickMapsActionZoomIn = Action & {
|
|
@@ -203,11 +207,15 @@ Default property:
|
|
|
203
207
|
/* Event of the brick blur (Use TV Device with controller) */
|
|
204
208
|
onBlur?: Array<EventAction>
|
|
205
209
|
/* Event when a marker is pressed */
|
|
206
|
-
onMarkerPress?: Array<
|
|
210
|
+
onMarkerPress?: Array<
|
|
211
|
+
EventAction<string & keyof TemplateEventPropsMap['Maps']['onMarkerPress']>
|
|
212
|
+
>
|
|
207
213
|
/* Event when the map is pressed */
|
|
208
|
-
onMapPress?: Array<EventAction
|
|
214
|
+
onMapPress?: Array<EventAction<string & keyof TemplateEventPropsMap['Maps']['onMapPress']>>
|
|
209
215
|
/* Event when the map region changes */
|
|
210
|
-
onRegionChange?: Array<
|
|
216
|
+
onRegionChange?: Array<
|
|
217
|
+
EventAction<string & keyof TemplateEventPropsMap['Maps']['onRegionChange']>
|
|
218
|
+
>
|
|
211
219
|
/* Event when the map is ready */
|
|
212
220
|
onReady?: Array<EventAction>
|
|
213
221
|
}
|
|
@@ -231,7 +239,7 @@ Default property:
|
|
|
231
239
|
}
|
|
232
240
|
}
|
|
233
241
|
|
|
234
|
-
/* Maps
|
|
242
|
+
/* Interactive map with markers, paths, and location tracking. Supports Google Maps (iOS/Android/Desktop/Web) and Apple Maps (iOS/tvOS) */
|
|
235
243
|
export type BrickMaps = Brick &
|
|
236
244
|
BrickMapsDef & {
|
|
237
245
|
templateKey: 'BRICK_MAPS'
|
package/types/bricks/QrCode.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Generate and display QR codes from text or URL values
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface BrickQrcodeDef {
|
|
17
21
|
/*
|
|
@@ -90,7 +94,7 @@ Default property:
|
|
|
90
94
|
}
|
|
91
95
|
}
|
|
92
96
|
|
|
93
|
-
/*
|
|
97
|
+
/* Generate and display QR codes from text or URL values */
|
|
94
98
|
export type BrickQrcode = Brick &
|
|
95
99
|
BrickQrcodeDef & {
|
|
96
100
|
templateKey: 'BRICK_QRCODE'
|
package/types/bricks/Rect.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Rectangle shape with customizable fill, border, radius, and shadow
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface BrickRectDef {
|
|
17
21
|
/*
|
|
@@ -88,7 +92,7 @@ Default property:
|
|
|
88
92
|
}
|
|
89
93
|
}
|
|
90
94
|
|
|
91
|
-
/*
|
|
95
|
+
/* Rectangle shape with customizable fill, border, radius, and shadow */
|
|
92
96
|
export type BrickRect = Brick &
|
|
93
97
|
BrickRectDef & {
|
|
94
98
|
templateKey: 'BRICK_RECT'
|
package/types/bricks/RichText.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Rich text with HTML content rendering, multiple fonts, colors, heading levels (h1-h6), and inline images
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface BrickRichTextDef {
|
|
17
21
|
/*
|
|
@@ -101,7 +105,7 @@ Default property:
|
|
|
101
105
|
}
|
|
102
106
|
}
|
|
103
107
|
|
|
104
|
-
/*
|
|
108
|
+
/* Rich text with HTML content rendering, multiple fonts, colors, heading levels (h1-h6), and inline images */
|
|
105
109
|
export type BrickRichText = Brick &
|
|
106
110
|
BrickRichTextDef & {
|
|
107
111
|
templateKey: 'BRICK_RICH_TEXT'
|
package/types/bricks/Rive.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Render Rive (.riv) animations with state machine input control, text run updates, and artboard selection
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
/* Play animation */
|
|
17
21
|
export type BrickRiveActionPlay = ActionWithParams & {
|
|
@@ -159,21 +163,27 @@ Default property:
|
|
|
159
163
|
}
|
|
160
164
|
events?: BrickBasicEvents & {
|
|
161
165
|
/* Event of animation play */
|
|
162
|
-
onPlay?: Array<EventAction
|
|
166
|
+
onPlay?: Array<EventAction<string & keyof TemplateEventPropsMap['Rive']['onPlay']>>
|
|
163
167
|
/* Event of animation pause */
|
|
164
|
-
onPause?: Array<EventAction
|
|
168
|
+
onPause?: Array<EventAction<string & keyof TemplateEventPropsMap['Rive']['onPause']>>
|
|
165
169
|
/* Event of animation stop */
|
|
166
|
-
onStop?: Array<EventAction
|
|
170
|
+
onStop?: Array<EventAction<string & keyof TemplateEventPropsMap['Rive']['onStop']>>
|
|
167
171
|
/* Event of animation loop end */
|
|
168
|
-
onLoopEnd?: Array<EventAction
|
|
172
|
+
onLoopEnd?: Array<EventAction<string & keyof TemplateEventPropsMap['Rive']['onLoopEnd']>>
|
|
169
173
|
/* Event of state changed */
|
|
170
|
-
onStateChanged?: Array<
|
|
174
|
+
onStateChanged?: Array<
|
|
175
|
+
EventAction<string & keyof TemplateEventPropsMap['Rive']['onStateChanged']>
|
|
176
|
+
>
|
|
171
177
|
/* Event of error */
|
|
172
|
-
onError?: Array<EventAction
|
|
178
|
+
onError?: Array<EventAction<string & keyof TemplateEventPropsMap['Rive']['onError']>>
|
|
173
179
|
/* Event of Rive general event received */
|
|
174
|
-
onRiveGeneralEvent?: Array<
|
|
180
|
+
onRiveGeneralEvent?: Array<
|
|
181
|
+
EventAction<string & keyof TemplateEventPropsMap['Rive']['onRiveGeneralEvent']>
|
|
182
|
+
>
|
|
175
183
|
/* Event of Rive open-url event received */
|
|
176
|
-
onRiveOpenUrlEvent?: Array<
|
|
184
|
+
onRiveOpenUrlEvent?: Array<
|
|
185
|
+
EventAction<string & keyof TemplateEventPropsMap['Rive']['onRiveOpenUrlEvent']>
|
|
186
|
+
>
|
|
177
187
|
}
|
|
178
188
|
animation?: AnimationBasicEvents & {
|
|
179
189
|
onPlay?: Animation
|
|
@@ -187,7 +197,7 @@ Default property:
|
|
|
187
197
|
}
|
|
188
198
|
}
|
|
189
199
|
|
|
190
|
-
/* Rive
|
|
200
|
+
/* Render Rive (.riv) animations with state machine input control, text run updates, and artboard selection */
|
|
191
201
|
export type BrickRive = Brick &
|
|
192
202
|
BrickRiveDef & {
|
|
193
203
|
templateKey: 'BRICK_RIVE'
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Auto-advancing slideshow of child bricks with transition effects
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
/* Jump to a specific index in the slideshow */
|
|
17
21
|
export type BrickSlideshowActionJumpToIndex = ActionWithParams & {
|
|
@@ -146,17 +150,23 @@ Default property:
|
|
|
146
150
|
}
|
|
147
151
|
events?: BrickBasicEvents & {
|
|
148
152
|
/* Event of the next slideshow on change start */
|
|
149
|
-
changeStart?: Array<
|
|
153
|
+
changeStart?: Array<
|
|
154
|
+
EventAction<string & keyof TemplateEventPropsMap['Slideshow']['changeStart']>
|
|
155
|
+
>
|
|
150
156
|
/* Event of the next slideshow on change end */
|
|
151
|
-
changeEnd?: Array<EventAction
|
|
157
|
+
changeEnd?: Array<EventAction<string & keyof TemplateEventPropsMap['Slideshow']['changeEnd']>>
|
|
152
158
|
/* Event on paths change */
|
|
153
|
-
contentChange?: Array<
|
|
159
|
+
contentChange?: Array<
|
|
160
|
+
EventAction<string & keyof TemplateEventPropsMap['Slideshow']['contentChange']>
|
|
161
|
+
>
|
|
154
162
|
/* Event on plays of paths are end */
|
|
155
|
-
roundEnd?: Array<EventAction
|
|
163
|
+
roundEnd?: Array<EventAction<string & keyof TemplateEventPropsMap['Slideshow']['roundEnd']>>
|
|
156
164
|
/* Event of the slideshow on load */
|
|
157
165
|
mediaOnLoad?: Array<EventAction>
|
|
158
166
|
/* Event of the slideshow media loading error */
|
|
159
|
-
mediaOnError?: Array<
|
|
167
|
+
mediaOnError?: Array<
|
|
168
|
+
EventAction<string & keyof TemplateEventPropsMap['Slideshow']['mediaOnError']>
|
|
169
|
+
>
|
|
160
170
|
}
|
|
161
171
|
animation?: AnimationBasicEvents & {
|
|
162
172
|
changeStart?: Animation
|
|
@@ -168,7 +178,7 @@ Default property:
|
|
|
168
178
|
}
|
|
169
179
|
}
|
|
170
180
|
|
|
171
|
-
/*
|
|
181
|
+
/* Auto-advancing slideshow of child bricks with transition effects */
|
|
172
182
|
export type BrickSlideshow = Brick &
|
|
173
183
|
BrickSlideshowDef & {
|
|
174
184
|
templateKey: 'BRICK_SLIDESHOW'
|
package/types/bricks/Svg.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* SVG is an XML-based vector image format for 2D graphics
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface BrickSvgDef {
|
|
17
21
|
/*
|
package/types/bricks/Text.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Display styled text with font, color, alignment, and truncation controls
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface BrickTextDef {
|
|
17
21
|
/*
|
|
@@ -121,7 +125,7 @@ Default property:
|
|
|
121
125
|
}
|
|
122
126
|
}
|
|
123
127
|
|
|
124
|
-
/*
|
|
128
|
+
/* Display styled text with font, color, alignment, and truncation controls */
|
|
125
129
|
export type BrickText = Brick &
|
|
126
130
|
BrickTextDef & {
|
|
127
131
|
templateKey: 'BRICK_TEXT'
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Editable text input field with keyboard type, placeholder, and validation support
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
/* Focus TextInput */
|
|
17
21
|
export type BrickTextInputActionFocus = Action & {
|
|
@@ -172,15 +176,17 @@ Default property:
|
|
|
172
176
|
/* Event of the TextInput is empty */
|
|
173
177
|
onEmpty?: Array<EventAction>
|
|
174
178
|
/* Event of the TextInput value change */
|
|
175
|
-
onChange?: Array<EventAction
|
|
179
|
+
onChange?: Array<EventAction<string & keyof TemplateEventPropsMap['TextInput']['onChange']>>
|
|
176
180
|
/* Event of the TextInput submit */
|
|
177
|
-
onSubmit?: Array<EventAction
|
|
181
|
+
onSubmit?: Array<EventAction<string & keyof TemplateEventPropsMap['TextInput']['onSubmit']>>
|
|
178
182
|
/* Event of the TextInput match regex (check every value change) */
|
|
179
|
-
onMatch?: Array<EventAction
|
|
183
|
+
onMatch?: Array<EventAction<string & keyof TemplateEventPropsMap['TextInput']['onMatch']>>
|
|
180
184
|
/* Event of the TextInput not match regex (check every value change) */
|
|
181
|
-
onNotMatch?: Array<EventAction
|
|
185
|
+
onNotMatch?: Array<EventAction<string & keyof TemplateEventPropsMap['TextInput']['onNotMatch']>>
|
|
182
186
|
/* Event of the TextInput not match regex (check every submit) */
|
|
183
|
-
onResultNotMatch?: Array<
|
|
187
|
+
onResultNotMatch?: Array<
|
|
188
|
+
EventAction<string & keyof TemplateEventPropsMap['TextInput']['onResultNotMatch']>
|
|
189
|
+
>
|
|
184
190
|
/* Event of the TextInput reach max length or match regex */
|
|
185
191
|
onFullFill?: Array<EventAction>
|
|
186
192
|
}
|
|
@@ -213,7 +219,7 @@ Default property:
|
|
|
213
219
|
}
|
|
214
220
|
}
|
|
215
221
|
|
|
216
|
-
/*
|
|
222
|
+
/* Editable text input field with keyboard type, placeholder, and validation support */
|
|
217
223
|
export type BrickTextInput = Brick &
|
|
218
224
|
BrickTextInputDef & {
|
|
219
225
|
templateKey: 'BRICK_TEXT_INPUT'
|
package/types/bricks/Video.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Video playback with play/pause controls and streaming support
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
/* Play the video */
|
|
17
21
|
export type BrickVideoActionPlay = Action & {
|
|
@@ -117,7 +121,7 @@ Default property:
|
|
|
117
121
|
/* Event of the brick blur (Use TV Device with controller) */
|
|
118
122
|
onBlur?: Array<EventAction>
|
|
119
123
|
/* Event of the next video on change start */
|
|
120
|
-
nextVideo?: Array<EventAction
|
|
124
|
+
nextVideo?: Array<EventAction<string & keyof TemplateEventPropsMap['Video']['nextVideo']>>
|
|
121
125
|
/* Event on plays of path are totally end */
|
|
122
126
|
roundEnd?: Array<EventAction>
|
|
123
127
|
/* Event on video load */
|
|
@@ -125,7 +129,7 @@ Default property:
|
|
|
125
129
|
/* Event of the video playing error */
|
|
126
130
|
onError?: Array<EventAction>
|
|
127
131
|
/* Event of the video progress interval */
|
|
128
|
-
onProgress?: Array<EventAction
|
|
132
|
+
onProgress?: Array<EventAction<string & keyof TemplateEventPropsMap['Video']['onProgress']>>
|
|
129
133
|
}
|
|
130
134
|
outlets?: {
|
|
131
135
|
/* Brick is pressing */
|
|
@@ -148,7 +152,7 @@ Default property:
|
|
|
148
152
|
}
|
|
149
153
|
}
|
|
150
154
|
|
|
151
|
-
/* Video
|
|
155
|
+
/* Video playback with play/pause controls and streaming support */
|
|
152
156
|
export type BrickVideo = Brick &
|
|
153
157
|
BrickVideoDef & {
|
|
154
158
|
templateKey: 'BRICK_VIDEO'
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Brick video streaming component, supports RTSP / RTMP streaming.
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface BrickVideoStreamingDef {
|
|
17
21
|
/*
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
/* Auto generated by build script
|
|
1
|
+
/* Auto generated by build script
|
|
2
|
+
*
|
|
3
|
+
* Display WebRTC video/audio stream from a WebRTC generator connection
|
|
4
|
+
*/
|
|
2
5
|
import type { SwitchCondInnerStateCurrentCanvas, SwitchCondData, SwitchDef } from '../switch'
|
|
3
6
|
import type { Data, DataLink } from '../data'
|
|
4
7
|
import type { Animation, AnimationBasicEvents } from '../animation'
|
|
@@ -12,6 +15,7 @@ import type {
|
|
|
12
15
|
EventProperty,
|
|
13
16
|
} from '../common'
|
|
14
17
|
import type { BrickBasicProperty, BrickBasicEvents, BrickBasicEventsForItem } from '../brick-base'
|
|
18
|
+
import type { TemplateEventPropsMap } from '../../utils/event-props'
|
|
15
19
|
|
|
16
20
|
interface BrickWebRTCStreamDef {
|
|
17
21
|
/*
|
|
@@ -38,7 +42,7 @@ Default property:
|
|
|
38
42
|
}
|
|
39
43
|
}
|
|
40
44
|
|
|
41
|
-
/*
|
|
45
|
+
/* Display WebRTC video/audio stream from a WebRTC generator connection */
|
|
42
46
|
export type BrickWebRTCStream = Brick &
|
|
43
47
|
BrickWebRTCStreamDef & {
|
|
44
48
|
templateKey: 'BRICK_WEBRTC_STREAM'
|