@fugood/bricks-project 2.22.0-beta.12 → 2.22.0-beta.13
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 -1
- package/package.json +2 -2
- package/types/bricks.ts +24 -1
- package/types/data.ts +6 -0
- package/types/generators.ts +8 -3
|
@@ -257,6 +257,10 @@ export const templateActionNameMap = {
|
|
|
257
257
|
BRICK_WEBVIEW_INJECT_JAVASCRIPT: {
|
|
258
258
|
javascriptCode: 'BRICK_WEBVIEW_JAVASCRIPT_CODE',
|
|
259
259
|
},
|
|
260
|
+
BRICK_WEBVIEW_QUERY_SELECTOR: {
|
|
261
|
+
querySelector: 'BRICK_WEBVIEW_QUERY_SELECTOR',
|
|
262
|
+
expression: 'BRICK_WEBVIEW_EXPRESSION',
|
|
263
|
+
},
|
|
260
264
|
},
|
|
261
265
|
BRICK_CAMERA: {
|
|
262
266
|
BRICK_CAMERA_TAKE_PICTURE: {
|
|
@@ -594,8 +598,9 @@ export const templateActionNameMap = {
|
|
|
594
598
|
GENERATOR_LLM: {
|
|
595
599
|
GENERATOR_LLM_TOKENIZE: {
|
|
596
600
|
mode: 'GENERATOR_LLM_MODE',
|
|
597
|
-
messages: 'GENERATOR_LLM_MESSAGES',
|
|
598
601
|
prompt: 'GENERATOR_LLM_PROMPT',
|
|
602
|
+
promptImagePaths: 'GENERATOR_LLM_PROMPT_IMAGE_PATHS',
|
|
603
|
+
messages: 'GENERATOR_LLM_MESSAGES',
|
|
599
604
|
},
|
|
600
605
|
GENERATOR_LLM_DETOKENIZE: {
|
|
601
606
|
tokens: 'GENERATOR_LLM_TOKENS',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fugood/bricks-project",
|
|
3
|
-
"version": "2.22.0-beta.
|
|
3
|
+
"version": "2.22.0-beta.13",
|
|
4
4
|
"main": "index.ts",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "node scripts/build.js"
|
|
@@ -14,5 +14,5 @@
|
|
|
14
14
|
"lodash": "^4.17.4",
|
|
15
15
|
"uuid": "^8.3.1"
|
|
16
16
|
},
|
|
17
|
-
"gitHead": "
|
|
17
|
+
"gitHead": "0039a8fa08e89411caf8608a98ae80d5cca64cbe"
|
|
18
18
|
}
|
package/types/bricks.ts
CHANGED
|
@@ -2420,6 +2420,23 @@ export type BrickWebViewActionInjectJavascript = ActionWithParams & {
|
|
|
2420
2420
|
}>
|
|
2421
2421
|
}
|
|
2422
2422
|
|
|
2423
|
+
/* Query selector on the WebView */
|
|
2424
|
+
export type BrickWebViewActionQuerySelector = ActionWithParams & {
|
|
2425
|
+
__actionName: 'BRICK_WEBVIEW_QUERY_SELECTOR'
|
|
2426
|
+
params?: Array<
|
|
2427
|
+
| {
|
|
2428
|
+
input: 'querySelector'
|
|
2429
|
+
value?: string | DataLink | EventProperty
|
|
2430
|
+
mapping?: string
|
|
2431
|
+
}
|
|
2432
|
+
| {
|
|
2433
|
+
input: 'expression'
|
|
2434
|
+
value?: string | DataLink | EventProperty
|
|
2435
|
+
mapping?: string
|
|
2436
|
+
}
|
|
2437
|
+
>
|
|
2438
|
+
}
|
|
2439
|
+
|
|
2423
2440
|
/* Do go forward on the WebView */
|
|
2424
2441
|
export type BrickWebViewActionGoForward = Action & {
|
|
2425
2442
|
__actionName: 'BRICK_WEBVIEW_GO_FORWARD'
|
|
@@ -2502,6 +2519,12 @@ Default property:
|
|
|
2502
2519
|
/* Event of the webview on message by `window.ReactNativeWebView.postMessage` on you're injected javascript code */
|
|
2503
2520
|
onMessage?: Array<EventAction>
|
|
2504
2521
|
}
|
|
2522
|
+
outlets?: {
|
|
2523
|
+
/* The result of the query selector action */
|
|
2524
|
+
queryResult?: () => Data
|
|
2525
|
+
/* The error of the query selector action */
|
|
2526
|
+
queryError?: () => Data
|
|
2527
|
+
}
|
|
2505
2528
|
animation?: AnimationBasicEvents & {
|
|
2506
2529
|
onLoad?: Animation
|
|
2507
2530
|
onError?: Animation
|
|
@@ -2523,7 +2546,7 @@ export type BrickWebView = Brick &
|
|
|
2523
2546
|
| SwitchCondData
|
|
2524
2547
|
| {
|
|
2525
2548
|
__typename: 'SwitchCondInnerStateOutlet'
|
|
2526
|
-
outlet: ''
|
|
2549
|
+
outlet: 'queryResult' | 'queryError'
|
|
2527
2550
|
value: any
|
|
2528
2551
|
}
|
|
2529
2552
|
}>
|
package/types/data.ts
CHANGED
|
@@ -56,6 +56,11 @@ export type Data<T = any> = DataDef & {
|
|
|
56
56
|
| 'rich-text-content'
|
|
57
57
|
| 'sandbox-script'
|
|
58
58
|
| 'llm-prompt'
|
|
59
|
+
| 'llm-messages'
|
|
60
|
+
| 'llm-tools'
|
|
61
|
+
| 'mcp-server-resources'
|
|
62
|
+
| 'mcp-server-tools'
|
|
63
|
+
| 'mcp-server-prompts'
|
|
59
64
|
}
|
|
60
65
|
value: T
|
|
61
66
|
}
|
|
@@ -67,6 +72,7 @@ export type DataAssetKind = {
|
|
|
67
72
|
| 'media-resource-audio'
|
|
68
73
|
| 'media-resource-file'
|
|
69
74
|
| 'lottie-file-uri'
|
|
75
|
+
| 'rive-file-uri'
|
|
70
76
|
| 'ggml-model-asset'
|
|
71
77
|
| 'gguf-model-asset'
|
|
72
78
|
| 'binary-asset'
|
package/types/generators.ts
CHANGED
|
@@ -5919,13 +5919,18 @@ export type GeneratorLLMActionTokenize = ActionWithParams & {
|
|
|
5919
5919
|
mapping?: string
|
|
5920
5920
|
}
|
|
5921
5921
|
| {
|
|
5922
|
-
input: '
|
|
5922
|
+
input: 'prompt'
|
|
5923
|
+
value?: string | DataLink | EventProperty
|
|
5924
|
+
mapping?: string
|
|
5925
|
+
}
|
|
5926
|
+
| {
|
|
5927
|
+
input: 'promptImagePaths'
|
|
5923
5928
|
value?: Array<any> | DataLink | EventProperty
|
|
5924
5929
|
mapping?: string
|
|
5925
5930
|
}
|
|
5926
5931
|
| {
|
|
5927
|
-
input: '
|
|
5928
|
-
value?:
|
|
5932
|
+
input: 'messages'
|
|
5933
|
+
value?: Array<any> | DataLink | EventProperty
|
|
5929
5934
|
mapping?: string
|
|
5930
5935
|
}
|
|
5931
5936
|
>
|