@fugood/bricks-project 2.22.0-beta.30 → 2.22.0-beta.32

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/index.ts CHANGED
@@ -59,7 +59,9 @@ const compileEventActionValue = (templateKey, eventKey, value, errorReference) =
59
59
  if (!props) return compileProperty(value, errorReference)
60
60
  if (props.includes(value)) return value
61
61
  if (value?.startsWith(templateKey)) {
62
- console.warn(`[Warning] Value start with template key but there is no event property: ${value} ${errorReference}`)
62
+ console.warn(
63
+ `[Warning] Value start with template key but there is no event property: ${value} ${errorReference}`,
64
+ )
63
65
  }
64
66
  return compileProperty(value, errorReference)
65
67
  }
@@ -223,6 +225,13 @@ const compileApplicationSettings = (settings: Application['settings']) => {
223
225
  selectable_border: settings.tvOptions.selectableBorder,
224
226
  }
225
227
  : undefined,
228
+ ai: settings?.ai
229
+ ? {
230
+ use_anthropic_api_key_system_data: settings.ai.useAnthropicApiKeySystemData,
231
+ use_openai_api_key_system_data: settings.ai.useOpenAiApiKeySystemData,
232
+ use_gemini_api_key_system_data: settings.ai.useGeminiApiKeySystemData,
233
+ }
234
+ : undefined,
226
235
  }
227
236
  }
228
237
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fugood/bricks-project",
3
- "version": "2.22.0-beta.30",
3
+ "version": "2.22.0-beta.32",
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": "85c33271ee69ace908930725489582434dad93b9"
17
+ "gitHead": "eb03a87549133fcfa8f9e8dd9bd3d32e19272ee9"
18
18
  }
@@ -62,6 +62,8 @@ export interface BrickBasicProperty {
62
62
  Disabled: Disabled even if event or animation is set.
63
63
  Bypass: Disable and bypass the touch event on the brick. */
64
64
  pressable?: 'enabled' | 'disabled' | 'bypass' | DataLink
65
+ /* Delay in milliseconds before long press is triggered */
66
+ delayLongPress?: number | DataLink
65
67
  }
66
68
 
67
69
  export interface BrickBasicEvents {
@@ -166,6 +166,8 @@ Default property:
166
166
  generativeMediaOnPressIn?: Array<EventAction>
167
167
  /* Event of the brick press out */
168
168
  generativeMediaOnPressOut?: Array<EventAction>
169
+ /* Event of the brick long press */
170
+ generativeMediaOnLongPress?: Array<EventAction>
169
171
  /* Event of the brick focus (Use TV Device with controller) */
170
172
  generativeMediaOnFocus?: Array<EventAction>
171
173
  /* Event of the brick blur (Use TV Device with controller) */
@@ -201,6 +203,7 @@ Default property:
201
203
  generativeMediaOnPress?: Animation
202
204
  generativeMediaOnPressIn?: Animation
203
205
  generativeMediaOnPressOut?: Animation
206
+ generativeMediaOnLongPress?: Animation
204
207
  generativeMediaOnFocus?: Animation
205
208
  generativeMediaOnBlur?: Animation
206
209
  onSuccess?: Animation
@@ -47,6 +47,8 @@ Default property:
47
47
  onPressIn?: Array<EventAction>
48
48
  /* Event of the brick press out */
49
49
  onPressOut?: Array<EventAction>
50
+ /* Event of the brick long press */
51
+ onLongPress?: Array<EventAction>
50
52
  /* Event of the brick focus (Use TV Device with controller) */
51
53
  onFocus?: Array<EventAction>
52
54
  /* Event of the brick blur (Use TV Device with controller) */
@@ -62,6 +64,7 @@ Default property:
62
64
  onPress?: Animation
63
65
  onPressIn?: Animation
64
66
  onPressOut?: Animation
67
+ onLongPress?: Animation
65
68
  onFocus?: Animation
66
69
  onBlur?: Animation
67
70
  }
@@ -52,6 +52,8 @@ Default property:
52
52
  onPressIn?: Array<EventAction>
53
53
  /* Event of the brick press out */
54
54
  onPressOut?: Array<EventAction>
55
+ /* Event of the brick long press */
56
+ onLongPress?: Array<EventAction>
55
57
  /* Event of the brick focus (Use TV Device with controller) */
56
58
  onFocus?: Array<EventAction>
57
59
  /* Event of the brick blur (Use TV Device with controller) */
@@ -71,6 +73,7 @@ Default property:
71
73
  onPress?: Animation
72
74
  onPressIn?: Animation
73
75
  onPressOut?: Animation
76
+ onLongPress?: Animation
74
77
  onFocus?: Animation
75
78
  onBlur?: Animation
76
79
  onLoad?: Animation
@@ -104,6 +104,8 @@ Default property:
104
104
  onPressIn?: Array<EventAction>
105
105
  /* Event of the brick press out */
106
106
  onPressOut?: Array<EventAction>
107
+ /* Event of the brick long press */
108
+ onLongPress?: Array<EventAction>
107
109
  /* Event of the brick focus (Use TV Device with controller) */
108
110
  onFocus?: Array<EventAction>
109
111
  /* Event of the brick blur (Use TV Device with controller) */
@@ -125,6 +127,7 @@ Default property:
125
127
  onPress?: Animation
126
128
  onPressIn?: Animation
127
129
  onPressOut?: Animation
130
+ onLongPress?: Animation
128
131
  onFocus?: Animation
129
132
  onBlur?: Animation
130
133
  onAnimationFinish?: Animation
@@ -66,6 +66,8 @@ Default property:
66
66
  onPressIn?: Array<EventAction>
67
67
  /* Event of the brick press out */
68
68
  onPressOut?: Array<EventAction>
69
+ /* Event of the brick long press */
70
+ onLongPress?: Array<EventAction>
69
71
  /* Event of the brick focus (Use TV Device with controller) */
70
72
  onFocus?: Array<EventAction>
71
73
  /* Event of the brick blur (Use TV Device with controller) */
@@ -81,6 +83,7 @@ Default property:
81
83
  onPress?: Animation
82
84
  onPressIn?: Animation
83
85
  onPressOut?: Animation
86
+ onLongPress?: Animation
84
87
  onFocus?: Animation
85
88
  onBlur?: Animation
86
89
  }
@@ -64,6 +64,8 @@ Default property:
64
64
  onPressIn?: Array<EventAction>
65
65
  /* Event of the brick press out */
66
66
  onPressOut?: Array<EventAction>
67
+ /* Event of the brick long press */
68
+ onLongPress?: Array<EventAction>
67
69
  /* Event of the brick focus (Use TV Device with controller) */
68
70
  onFocus?: Array<EventAction>
69
71
  /* Event of the brick blur (Use TV Device with controller) */
@@ -79,6 +81,7 @@ Default property:
79
81
  onPress?: Animation
80
82
  onPressIn?: Animation
81
83
  onPressOut?: Animation
84
+ onLongPress?: Animation
82
85
  onFocus?: Animation
83
86
  onBlur?: Animation
84
87
  }
@@ -77,6 +77,8 @@ Default property:
77
77
  onPressIn?: Array<EventAction>
78
78
  /* Event of the brick press out */
79
79
  onPressOut?: Array<EventAction>
80
+ /* Event of the brick long press */
81
+ onLongPress?: Array<EventAction>
80
82
  /* Event of the brick focus (Use TV Device with controller) */
81
83
  onFocus?: Array<EventAction>
82
84
  /* Event of the brick blur (Use TV Device with controller) */
@@ -92,6 +94,7 @@ Default property:
92
94
  onPress?: Animation
93
95
  onPressIn?: Animation
94
96
  onPressOut?: Animation
97
+ onLongPress?: Animation
95
98
  onFocus?: Animation
96
99
  onBlur?: Animation
97
100
  }
@@ -48,6 +48,8 @@ Default property:
48
48
  onPressIn?: Array<EventAction>
49
49
  /* Event of the brick press out */
50
50
  onPressOut?: Array<EventAction>
51
+ /* Event of the brick long press */
52
+ onLongPress?: Array<EventAction>
51
53
  /* Event of the brick focus (Use TV Device with controller) */
52
54
  onFocus?: Array<EventAction>
53
55
  /* Event of the brick blur (Use TV Device with controller) */
@@ -63,6 +65,7 @@ Default property:
63
65
  onPress?: Animation
64
66
  onPressIn?: Animation
65
67
  onPressOut?: Animation
68
+ onLongPress?: Animation
66
69
  onFocus?: Animation
67
70
  onBlur?: Animation
68
71
  }
@@ -91,6 +91,8 @@ Default property:
91
91
  onPressIn?: Array<EventAction>
92
92
  /* Event of the brick press out */
93
93
  onPressOut?: Array<EventAction>
94
+ /* Event of the brick long press */
95
+ onLongPress?: Array<EventAction>
94
96
  /* Event of the brick focus (Use TV Device with controller) */
95
97
  onFocus?: Array<EventAction>
96
98
  /* Event of the brick blur (Use TV Device with controller) */
@@ -110,6 +112,7 @@ Default property:
110
112
  onPress?: Animation
111
113
  onPressIn?: Animation
112
114
  onPressOut?: Animation
115
+ onLongPress?: Animation
113
116
  onFocus?: Animation
114
117
  onBlur?: Animation
115
118
  beforeValueChange?: Animation
@@ -109,6 +109,8 @@ Default property:
109
109
  onPressIn?: Array<EventAction>
110
110
  /* Event of the brick press out */
111
111
  onPressOut?: Array<EventAction>
112
+ /* Event of the brick long press */
113
+ onLongPress?: Array<EventAction>
112
114
  /* Event of the brick focus (Use TV Device with controller) */
113
115
  onFocus?: Array<EventAction>
114
116
  /* Event of the brick blur (Use TV Device with controller) */
@@ -134,6 +136,7 @@ Default property:
134
136
  onPress?: Animation
135
137
  onPressIn?: Animation
136
138
  onPressOut?: Animation
139
+ onLongPress?: Animation
137
140
  onFocus?: Animation
138
141
  onBlur?: Animation
139
142
  nextVideo?: Animation
@@ -52,6 +52,8 @@ Default property:
52
52
  onPressIn?: Array<EventAction>
53
53
  /* Event of the brick press out */
54
54
  onPressOut?: Array<EventAction>
55
+ /* Event of the brick long press */
56
+ onLongPress?: Array<EventAction>
55
57
  /* Event of the brick focus (Use TV Device with controller) */
56
58
  onFocus?: Array<EventAction>
57
59
  /* Event of the brick blur (Use TV Device with controller) */
@@ -73,6 +75,7 @@ Default property:
73
75
  onPress?: Animation
74
76
  onPressIn?: Animation
75
77
  onPressOut?: Animation
78
+ onLongPress?: Animation
76
79
  onFocus?: Animation
77
80
  onBlur?: Animation
78
81
  onEnd?: Animation
package/types/common.ts CHANGED
@@ -115,6 +115,11 @@ export type ApplicationSettings = {
115
115
  borderBottomRightRadius?: number
116
116
  }
117
117
  }
118
+ ai?: {
119
+ useAnthropicApiKeySystemData?: boolean
120
+ useOpenAiApiKeySystemData?: boolean
121
+ useGeminiApiKeySystemData?: boolean
122
+ }
118
123
  }
119
124
 
120
125
  export type Application = {
@@ -40,7 +40,9 @@ Default property:
40
40
  "authType": "none",
41
41
  "asyncMode": false,
42
42
  "resStatusCode": 200,
43
- "resContentType": "text/plain"
43
+ "resContentType": "text/plain",
44
+ "tls": false,
45
+ "tlsKeyPairPassword": ""
44
46
  }
45
47
  */
46
48
  property?: {
@@ -108,6 +110,12 @@ Default property:
108
110
  sseEvent?: string | DataLink
109
111
  /* SSE single request mode, block new request until the previous request is processed */
110
112
  sseSingleRequest?: boolean | DataLink
113
+ /* Enable TLS (HTTPS) */
114
+ tls?: boolean | DataLink
115
+ /* Server side key pair (Base64 encoded PKCS #12) */
116
+ tlsKeyPair?: string | DataLink
117
+ /* Password of key pair, leave empty if no password */
118
+ tlsKeyPairPassword?: string | DataLink
111
119
  }
112
120
  events?: {
113
121
  /* Event of HTTP server is ready */
@@ -87,6 +87,7 @@ Default property:
87
87
  | DataLink
88
88
  additionalParams?: {} | DataLink
89
89
  }
90
+ responseType?: 'text' | 'object' | DataLink
90
91
  }
91
92
  >
92
93
  | DataLink
@@ -132,6 +133,7 @@ Default property:
132
133
  | DataLink
133
134
  additionalParams?: {} | DataLink
134
135
  }
136
+ responseType?: 'text' | 'object' | DataLink
135
137
  }
136
138
  >
137
139
  | DataLink
@@ -177,6 +179,7 @@ Default property:
177
179
  | DataLink
178
180
  additionalParams?: {} | DataLink
179
181
  }
182
+ responseType?: 'text' | 'object' | DataLink
180
183
  }
181
184
  >
182
185
  | DataLink
@@ -49,7 +49,9 @@ Default property:
49
49
  "testMode": false,
50
50
  "testPlaybackSpeed": 1,
51
51
  "testChunkDurationMs": 100,
52
- "testLoop": false
52
+ "testLoop": false,
53
+ "beginTranscribeEnabled": false,
54
+ "beginTranscribeScript": "\/\* Global variable: inputs = { sliceIndex, duration, vadEvent, variables } \*\/\nreturn true"
53
55
  }
54
56
  */
55
57
  property?: {
@@ -106,6 +108,12 @@ Default property:
106
108
  testChunkDurationMs?: number | DataLink
107
109
  /* Loop test audio file */
108
110
  testLoop?: boolean | DataLink
111
+ /* Enable Begin Transcribe Script to determine transcription */
112
+ beginTranscribeEnabled?: boolean | DataLink
113
+ /* Script to determine whether to proceed with transcription */
114
+ beginTranscribeScript?: string | DataLink
115
+ /* Data to be used in Begin Transcribe Script (object) */
116
+ beginTranscribeScriptData?: {} | DataLink
109
117
  }
110
118
  events?: {
111
119
  /* Event triggered when transcription starts, processes, or ends */