@stina/extension-api 1.17.0 → 1.18.0

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.
@@ -1,7 +1,7 @@
1
1
  import "../chunk-DGUM43GV.js";
2
2
 
3
3
  // src/schemas/manifest.schema.ts
4
- import { z as z4 } from "zod";
4
+ import { z as z5 } from "zod";
5
5
 
6
6
  // src/schemas/permissions.schema.ts
7
7
  import { z } from "zod";
@@ -88,11 +88,17 @@ function isValidPermission(permission) {
88
88
  }
89
89
 
90
90
  // src/schemas/contributions.schema.ts
91
- import { z as z3 } from "zod";
91
+ import { z as z4 } from "zod";
92
92
 
93
93
  // src/schemas/components.schema.ts
94
+ import { z as z3 } from "zod";
95
+
96
+ // src/schemas/localization.schema.ts
94
97
  import { z as z2 } from "zod";
95
- var AllowedCSSPropertySchema = z2.enum([
98
+ var LocalizedStringSchema = z2.union([z2.string(), z2.record(z2.string())]).describe("String or localized string map");
99
+
100
+ // src/schemas/components.schema.ts
101
+ var AllowedCSSPropertySchema = z3.enum([
96
102
  // Colors
97
103
  "color",
98
104
  "background-color",
@@ -164,252 +170,252 @@ var AllowedCSSPropertySchema = z2.enum([
164
170
  "border-collapse",
165
171
  "border-spacing"
166
172
  ]);
167
- var ExtensionComponentStyleSchema = z2.record(AllowedCSSPropertySchema, z2.string()).describe("Safe CSS styles for the component");
168
- var ExtensionComponentDataSchema = z2.lazy(
169
- () => z2.object({
170
- component: z2.string().describe("Component type name"),
173
+ var ExtensionComponentStyleSchema = z3.record(AllowedCSSPropertySchema, z3.string()).describe("Safe CSS styles for the component");
174
+ var ExtensionComponentDataSchema = z3.lazy(
175
+ () => z3.object({
176
+ component: z3.string().describe("Component type name"),
171
177
  style: ExtensionComponentStyleSchema.optional()
172
178
  }).passthrough().describe("Extension component definition")
173
179
  );
174
- var ExtensionActionCallSchema = z2.object({
175
- action: z2.string().describe("Name of the registered action"),
176
- params: z2.record(z2.unknown()).optional().describe("Parameters to pass")
180
+ var ExtensionActionCallSchema = z3.object({
181
+ action: z3.string().describe("Name of the registered action"),
182
+ params: z3.record(z3.unknown()).optional().describe("Parameters to pass")
177
183
  }).describe("Action call with parameters");
178
- var ExtensionActionRefSchema = z2.union([z2.string(), ExtensionActionCallSchema]).describe("Action reference");
179
- var ExtensionComponentIteratorSchema = z2.object({
180
- each: z2.union([z2.string(), z2.array(z2.unknown())]).describe("Data source to iterate over"),
181
- as: z2.string().describe("Variable name for current item in scope"),
182
- items: z2.array(ExtensionComponentDataSchema).describe("Components to render for each item")
184
+ var ExtensionActionRefSchema = z3.union([z3.string(), ExtensionActionCallSchema]).describe("Action reference");
185
+ var ExtensionComponentIteratorSchema = z3.object({
186
+ each: z3.union([z3.string(), z3.array(z3.unknown())]).describe("Data source to iterate over"),
187
+ as: z3.string().describe("Variable name for current item in scope"),
188
+ items: z3.array(ExtensionComponentDataSchema).describe("Components to render for each item")
183
189
  }).describe("Iterator for rendering lists");
184
- var ExtensionComponentChildrenSchema = z2.union([z2.array(ExtensionComponentDataSchema), ExtensionComponentIteratorSchema]).describe("Child components or iterator");
185
- var ExtensionDataSourceSchema = z2.object({
186
- action: z2.string().describe("Action to call for fetching data"),
187
- params: z2.record(z2.unknown()).optional().describe("Parameters to pass to the action"),
188
- refreshOn: z2.array(z2.string()).optional().describe("Event names that trigger a refresh")
190
+ var ExtensionComponentChildrenSchema = z3.union([z3.array(ExtensionComponentDataSchema), ExtensionComponentIteratorSchema]).describe("Child components or iterator");
191
+ var ExtensionDataSourceSchema = z3.object({
192
+ action: z3.string().describe("Action to call for fetching data"),
193
+ params: z3.record(z3.unknown()).optional().describe("Parameters to pass to the action"),
194
+ refreshOn: z3.array(z3.string()).optional().describe("Event names that trigger a refresh")
189
195
  }).describe("Data source definition");
190
- var HeaderPropsSchema = z2.object({
191
- component: z2.literal("Header"),
192
- level: z2.number().min(1).max(6).describe("Heading level (1-6)"),
193
- title: z2.string().describe("Header title"),
194
- description: z2.union([z2.string(), z2.array(z2.string())]).optional().describe("Description text"),
195
- icon: z2.string().optional().describe("Icon name"),
196
+ var HeaderPropsSchema = z3.object({
197
+ component: z3.literal("Header"),
198
+ level: z3.number().min(1).max(6).describe("Heading level (1-6)"),
199
+ title: LocalizedStringSchema.describe("Header title"),
200
+ description: z3.union([LocalizedStringSchema, z3.array(LocalizedStringSchema)]).optional().describe("Description text"),
201
+ icon: z3.string().optional().describe("Icon name"),
196
202
  style: ExtensionComponentStyleSchema.optional()
197
203
  }).passthrough().describe("Header component");
198
- var LabelPropsSchema = z2.object({
199
- component: z2.literal("Label"),
200
- text: z2.string().describe("Label text"),
204
+ var LabelPropsSchema = z3.object({
205
+ component: z3.literal("Label"),
206
+ text: LocalizedStringSchema.describe("Label text"),
201
207
  style: ExtensionComponentStyleSchema.optional()
202
208
  }).passthrough().describe("Label component");
203
- var ClockPropsSchema = z2.object({
204
- component: z2.literal("Clock"),
209
+ var ClockPropsSchema = z3.object({
210
+ component: z3.literal("Clock"),
205
211
  style: ExtensionComponentStyleSchema.optional()
206
212
  }).passthrough().describe("Clock component: the current date and time where the user is");
207
- var ParagraphPropsSchema = z2.object({
208
- component: z2.literal("Paragraph"),
209
- text: z2.string().describe("Paragraph text"),
213
+ var ParagraphPropsSchema = z3.object({
214
+ component: z3.literal("Paragraph"),
215
+ text: LocalizedStringSchema.describe("Paragraph text"),
210
216
  style: ExtensionComponentStyleSchema.optional()
211
217
  }).passthrough().describe("Paragraph component");
212
- var ButtonPropsSchema = z2.object({
213
- component: z2.literal("Button"),
214
- text: z2.string().describe("Button text"),
215
- type: z2.enum(["normal", "primary", "danger", "accent"]).optional().describe("Visual style"),
216
- title: z2.string().optional().describe("Tooltip shown on hover"),
217
- disabled: z2.boolean().optional().describe("Disable the button"),
218
+ var ButtonPropsSchema = z3.object({
219
+ component: z3.literal("Button"),
220
+ text: LocalizedStringSchema.describe("Button text"),
221
+ type: z3.enum(["normal", "primary", "danger", "accent"]).optional().describe("Visual style"),
222
+ title: LocalizedStringSchema.optional().describe("Tooltip shown on hover"),
223
+ disabled: z3.boolean().optional().describe("Disable the button"),
218
224
  onClickAction: ExtensionActionRefSchema.describe("Action to call on click"),
219
225
  style: ExtensionComponentStyleSchema.optional()
220
226
  }).passthrough().describe("Button component");
221
- var TextInputPropsSchema = z2.object({
222
- component: z2.literal("TextInput"),
223
- label: z2.string().describe("Input label"),
224
- placeholder: z2.string().optional().describe("Placeholder text"),
225
- value: z2.string().optional().describe("Current value"),
227
+ var TextInputPropsSchema = z3.object({
228
+ component: z3.literal("TextInput"),
229
+ label: LocalizedStringSchema.describe("Input label"),
230
+ placeholder: LocalizedStringSchema.optional().describe("Placeholder text"),
231
+ value: z3.string().optional().describe("Current value"),
226
232
  onChangeAction: ExtensionActionRefSchema.optional().describe("Action to call on change"),
227
233
  style: ExtensionComponentStyleSchema.optional()
228
234
  }).passthrough().describe("TextInput component");
229
- var PasswordInputPropsSchema = z2.object({
230
- component: z2.literal("PasswordInput"),
231
- label: z2.string().describe("Input label"),
232
- placeholder: z2.string().optional().describe("Placeholder text"),
233
- value: z2.string().optional().describe("Current value"),
235
+ var PasswordInputPropsSchema = z3.object({
236
+ component: z3.literal("PasswordInput"),
237
+ label: LocalizedStringSchema.describe("Input label"),
238
+ placeholder: LocalizedStringSchema.optional().describe("Placeholder text"),
239
+ value: z3.string().optional().describe("Current value"),
234
240
  onChangeAction: ExtensionActionRefSchema.optional().describe("Action to call on change"),
235
241
  style: ExtensionComponentStyleSchema.optional()
236
242
  }).passthrough().describe("Password input component (text is masked)");
237
- var NumberInputPropsSchema = z2.object({
238
- component: z2.literal("NumberInput"),
239
- label: z2.string().describe("Input label"),
240
- placeholder: z2.string().optional().describe("Placeholder text"),
241
- value: z2.union([z2.string(), z2.number()]).optional().describe("Current value"),
242
- min: z2.number().optional().describe("Minimum value"),
243
- max: z2.number().optional().describe("Maximum value"),
244
- step: z2.number().optional().describe("Step"),
243
+ var NumberInputPropsSchema = z3.object({
244
+ component: z3.literal("NumberInput"),
245
+ label: LocalizedStringSchema.describe("Input label"),
246
+ placeholder: LocalizedStringSchema.optional().describe("Placeholder text"),
247
+ value: z3.union([z3.string(), z3.number()]).optional().describe("Current value"),
248
+ min: z3.number().optional().describe("Minimum value"),
249
+ max: z3.number().optional().describe("Maximum value"),
250
+ step: z3.number().optional().describe("Step"),
245
251
  onChangeAction: ExtensionActionRefSchema.optional().describe("Action to call on change"),
246
252
  style: ExtensionComponentStyleSchema.optional()
247
253
  }).passthrough().describe("Numeric input component");
248
- var TextAreaPropsSchema = z2.object({
249
- component: z2.literal("TextArea"),
250
- label: z2.string().describe("Input label"),
251
- placeholder: z2.string().optional().describe("Placeholder text"),
252
- value: z2.string().optional().describe("Current value"),
253
- rows: z2.number().int().positive().optional().describe("Number of visible text rows"),
254
+ var TextAreaPropsSchema = z3.object({
255
+ component: z3.literal("TextArea"),
256
+ label: LocalizedStringSchema.describe("Input label"),
257
+ placeholder: LocalizedStringSchema.optional().describe("Placeholder text"),
258
+ value: z3.string().optional().describe("Current value"),
259
+ rows: z3.number().int().positive().optional().describe("Number of visible text rows"),
254
260
  onChangeAction: ExtensionActionRefSchema.optional().describe("Action to call on change"),
255
261
  style: ExtensionComponentStyleSchema.optional()
256
262
  }).passthrough().describe("TextArea component for multi-line text input");
257
- var DateTimeInputPropsSchema = z2.object({
258
- component: z2.literal("DateTimeInput"),
259
- label: z2.string().describe("Input label"),
260
- value: z2.string().optional().describe("Current value"),
263
+ var DateTimeInputPropsSchema = z3.object({
264
+ component: z3.literal("DateTimeInput"),
265
+ label: LocalizedStringSchema.describe("Input label"),
266
+ value: z3.string().optional().describe("Current value"),
261
267
  onChangeAction: ExtensionActionRefSchema.optional().describe("Action to call on change"),
262
268
  style: ExtensionComponentStyleSchema.optional()
263
269
  }).passthrough().describe("DateTimeInput component");
264
- var SelectPropsSchema = z2.object({
265
- component: z2.literal("Select"),
266
- label: z2.string().describe("Select label"),
267
- options: z2.array(z2.object({ label: z2.string(), value: z2.string() })).describe("Available options"),
268
- selectedValue: z2.string().optional().describe("Currently selected value"),
270
+ var SelectPropsSchema = z3.object({
271
+ component: z3.literal("Select"),
272
+ label: LocalizedStringSchema.describe("Select label"),
273
+ options: z3.array(z3.object({ label: LocalizedStringSchema, value: z3.string() })).describe("Available options"),
274
+ selectedValue: z3.string().optional().describe("Currently selected value"),
269
275
  onChangeAction: ExtensionActionRefSchema.optional().describe("Action to call on change"),
270
276
  style: ExtensionComponentStyleSchema.optional()
271
277
  }).passthrough().describe("Select component");
272
- var IconPickerPropsSchema = z2.object({
273
- component: z2.literal("IconPicker"),
274
- label: z2.string().optional().describe("Picker label"),
275
- value: z2.string().optional().describe("Currently selected icon name"),
278
+ var IconPickerPropsSchema = z3.object({
279
+ component: z3.literal("IconPicker"),
280
+ label: LocalizedStringSchema.optional().describe("Picker label"),
281
+ value: z3.string().optional().describe("Currently selected icon name"),
276
282
  onChangeAction: ExtensionActionRefSchema.optional().describe("Action to call on change"),
277
283
  style: ExtensionComponentStyleSchema.optional()
278
284
  }).passthrough().describe("IconPicker component");
279
- var VerticalStackPropsSchema = z2.object({
280
- component: z2.literal("VerticalStack"),
281
- gap: z2.number().optional().describe("Gap between children"),
285
+ var VerticalStackPropsSchema = z3.object({
286
+ component: z3.literal("VerticalStack"),
287
+ gap: z3.number().optional().describe("Gap between children"),
282
288
  children: ExtensionComponentChildrenSchema.describe("Child components"),
283
289
  style: ExtensionComponentStyleSchema.optional()
284
290
  }).passthrough().describe("VerticalStack layout component");
285
- var HorizontalStackPropsSchema = z2.object({
286
- component: z2.literal("HorizontalStack"),
287
- gap: z2.number().optional().describe("Gap between children"),
291
+ var HorizontalStackPropsSchema = z3.object({
292
+ component: z3.literal("HorizontalStack"),
293
+ gap: z3.number().optional().describe("Gap between children"),
288
294
  children: ExtensionComponentChildrenSchema.describe("Child components"),
289
295
  style: ExtensionComponentStyleSchema.optional()
290
296
  }).passthrough().describe("HorizontalStack layout component");
291
- var GridPropsSchema = z2.object({
292
- component: z2.literal("Grid"),
293
- columns: z2.number().describe("Number of columns"),
294
- gap: z2.number().optional().describe("Gap between items"),
297
+ var GridPropsSchema = z3.object({
298
+ component: z3.literal("Grid"),
299
+ columns: z3.number().describe("Number of columns"),
300
+ gap: z3.number().optional().describe("Gap between items"),
295
301
  children: ExtensionComponentChildrenSchema.describe("Child components"),
296
302
  style: ExtensionComponentStyleSchema.optional()
297
303
  }).passthrough().describe("Grid layout component");
298
- var DividerPropsSchema = z2.object({
299
- component: z2.literal("Divider"),
304
+ var DividerPropsSchema = z3.object({
305
+ component: z3.literal("Divider"),
300
306
  style: ExtensionComponentStyleSchema.optional()
301
307
  }).passthrough().describe("Divider component");
302
- var IconPropsSchema = z2.object({
303
- component: z2.literal("Icon"),
304
- name: z2.string().describe("Icon name"),
305
- title: z2.string().optional().describe("Icon title"),
308
+ var IconPropsSchema = z3.object({
309
+ component: z3.literal("Icon"),
310
+ name: z3.string().describe("Icon name"),
311
+ title: LocalizedStringSchema.optional().describe("Icon title"),
306
312
  style: ExtensionComponentStyleSchema.optional()
307
313
  }).passthrough().describe("Icon component");
308
- var IconButtonTypeSchema = z2.enum(["normal", "primary", "danger", "accent"]).describe("Button type");
309
- var IconButtonPropsSchema = z2.object({
310
- component: z2.literal("IconButton"),
311
- icon: z2.string().describe("Icon name"),
312
- tooltip: z2.string().describe("Tooltip text"),
313
- active: z2.boolean().optional().describe("Whether the button is active"),
314
- disabled: z2.boolean().optional().describe("Whether the button is disabled"),
314
+ var IconButtonTypeSchema = z3.enum(["normal", "primary", "danger", "accent"]).describe("Button type");
315
+ var IconButtonPropsSchema = z3.object({
316
+ component: z3.literal("IconButton"),
317
+ icon: z3.string().describe("Icon name"),
318
+ tooltip: LocalizedStringSchema.describe("Tooltip text"),
319
+ active: z3.boolean().optional().describe("Whether the button is active"),
320
+ disabled: z3.boolean().optional().describe("Whether the button is disabled"),
315
321
  type: IconButtonTypeSchema.optional().describe("Button style type"),
316
322
  onClickAction: ExtensionActionRefSchema.describe("Action to call on click"),
317
323
  style: ExtensionComponentStyleSchema.optional()
318
324
  }).passthrough().describe("IconButton component");
319
- var PanelActionSchema = z2.object({
320
- icon: z2.string().describe("Icon name"),
321
- tooltip: z2.string().describe("Tooltip text"),
325
+ var PanelActionSchema = z3.object({
326
+ icon: z3.string().describe("Icon name"),
327
+ tooltip: LocalizedStringSchema.describe("Tooltip text"),
322
328
  action: ExtensionActionRefSchema.describe("Action to call"),
323
329
  type: IconButtonTypeSchema.optional().describe("Button style type")
324
330
  }).describe("Panel action button");
325
- var PanelPropsSchema = z2.object({
326
- component: z2.literal("Panel"),
327
- title: z2.string().describe("Panel title"),
328
- description: z2.union([z2.string(), z2.array(z2.string())]).optional().describe("Description text"),
329
- icon: z2.string().optional().describe("Icon name"),
330
- actions: z2.array(PanelActionSchema).optional().describe("Action buttons"),
331
+ var PanelPropsSchema = z3.object({
332
+ component: z3.literal("Panel"),
333
+ title: LocalizedStringSchema.describe("Panel title"),
334
+ description: z3.union([LocalizedStringSchema, z3.array(LocalizedStringSchema)]).optional().describe("Description text"),
335
+ icon: z3.string().optional().describe("Icon name"),
336
+ actions: z3.array(PanelActionSchema).optional().describe("Action buttons"),
331
337
  content: ExtensionComponentDataSchema.optional().describe("Panel content"),
332
338
  style: ExtensionComponentStyleSchema.optional()
333
339
  }).passthrough().describe("Panel component");
334
- var TogglePropsSchema = z2.object({
335
- component: z2.literal("Toggle"),
336
- label: z2.string().optional().describe("Toggle label"),
337
- description: z2.string().optional().describe("Description text"),
338
- checked: z2.boolean().optional().describe("Whether the toggle is checked"),
339
- disabled: z2.boolean().optional().describe("Whether the toggle is disabled"),
340
+ var TogglePropsSchema = z3.object({
341
+ component: z3.literal("Toggle"),
342
+ label: LocalizedStringSchema.optional().describe("Toggle label"),
343
+ description: LocalizedStringSchema.optional().describe("Description text"),
344
+ checked: z3.boolean().optional().describe("Whether the toggle is checked"),
345
+ disabled: z3.boolean().optional().describe("Whether the toggle is disabled"),
340
346
  onChangeAction: ExtensionActionRefSchema.optional().describe("Action to call on change"),
341
347
  style: ExtensionComponentStyleSchema.optional()
342
348
  }).passthrough().describe("Toggle component");
343
- var CollapsiblePropsSchema = z2.object({
344
- component: z2.literal("Collapsible"),
345
- title: z2.string().describe("Title displayed in the header"),
346
- description: z2.union([z2.string(), z2.array(z2.string())]).optional().describe("Description text"),
347
- icon: z2.string().optional().describe("Icon name"),
348
- defaultExpanded: z2.boolean().optional().describe("Whether expanded by default"),
349
+ var CollapsiblePropsSchema = z3.object({
350
+ component: z3.literal("Collapsible"),
351
+ title: LocalizedStringSchema.describe("Title displayed in the header"),
352
+ description: z3.union([LocalizedStringSchema, z3.array(LocalizedStringSchema)]).optional().describe("Description text"),
353
+ icon: z3.string().optional().describe("Icon name"),
354
+ defaultExpanded: z3.boolean().optional().describe("Whether expanded by default"),
349
355
  content: ExtensionComponentDataSchema.optional().describe("Content when expanded"),
350
356
  style: ExtensionComponentStyleSchema.optional()
351
357
  }).passthrough().describe("Collapsible component");
352
- var PillVariantSchema = z2.enum(["default", "primary", "success", "warning", "danger", "accent"]).describe("Pill color variant");
353
- var PillPropsSchema = z2.object({
354
- component: z2.literal("Pill"),
355
- text: z2.string().describe("Pill text"),
356
- icon: z2.string().optional().describe("Icon name"),
358
+ var PillVariantSchema = z3.enum(["default", "primary", "success", "warning", "danger", "accent"]).describe("Pill color variant");
359
+ var PillPropsSchema = z3.object({
360
+ component: z3.literal("Pill"),
361
+ text: LocalizedStringSchema.describe("Pill text"),
362
+ icon: z3.string().optional().describe("Icon name"),
357
363
  variant: PillVariantSchema.optional().describe("Color variant"),
358
364
  style: ExtensionComponentStyleSchema.optional()
359
365
  }).passthrough().describe("Pill component");
360
- var CheckboxPropsSchema = z2.object({
361
- component: z2.literal("Checkbox"),
362
- label: z2.string().describe("Checkbox label"),
363
- checked: z2.boolean().optional().describe("Whether the checkbox is checked"),
364
- disabled: z2.boolean().optional().describe("Whether the checkbox is disabled"),
365
- strikethrough: z2.boolean().optional().describe("Strike through label when checked"),
366
+ var CheckboxPropsSchema = z3.object({
367
+ component: z3.literal("Checkbox"),
368
+ label: LocalizedStringSchema.describe("Checkbox label"),
369
+ checked: z3.boolean().optional().describe("Whether the checkbox is checked"),
370
+ disabled: z3.boolean().optional().describe("Whether the checkbox is disabled"),
371
+ strikethrough: z3.boolean().optional().describe("Strike through label when checked"),
366
372
  onChangeAction: ExtensionActionRefSchema.optional().describe("Action to call on change"),
367
373
  style: ExtensionComponentStyleSchema.optional()
368
374
  }).passthrough().describe("Checkbox component");
369
- var MarkdownPropsSchema = z2.object({
370
- component: z2.literal("Markdown"),
371
- content: z2.string().describe("Markdown content"),
375
+ var MarkdownPropsSchema = z3.object({
376
+ component: z3.literal("Markdown"),
377
+ content: LocalizedStringSchema.describe("Markdown content"),
372
378
  style: ExtensionComponentStyleSchema.optional()
373
379
  }).passthrough().describe("Markdown component");
374
- var TextPreviewPropsSchema = z2.object({
375
- component: z2.literal("TextPreview"),
376
- content: z2.string().describe("Markdown content"),
377
- maxLines: z2.number().optional().describe("Max visible lines before truncating (default 5)"),
380
+ var TextPreviewPropsSchema = z3.object({
381
+ component: z3.literal("TextPreview"),
382
+ content: z3.string().describe("Markdown content"),
383
+ maxLines: z3.number().optional().describe("Max visible lines before truncating (default 5)"),
378
384
  style: ExtensionComponentStyleSchema.optional()
379
385
  }).passthrough().describe("TextPreview component");
380
- var ModalPropsSchema = z2.object({
381
- component: z2.literal("Modal"),
382
- title: z2.string().describe("Modal title"),
383
- open: z2.boolean().optional().describe("Whether the modal is open"),
384
- maxWidth: z2.string().optional().describe("Max width of the modal"),
386
+ var ModalPropsSchema = z3.object({
387
+ component: z3.literal("Modal"),
388
+ title: LocalizedStringSchema.describe("Modal title"),
389
+ open: z3.boolean().optional().describe("Whether the modal is open"),
390
+ maxWidth: z3.string().optional().describe("Max width of the modal"),
385
391
  body: ExtensionComponentDataSchema.optional().describe("Modal body content"),
386
392
  footer: ExtensionComponentDataSchema.optional().describe("Modal footer content"),
387
393
  onCloseAction: ExtensionActionRefSchema.optional().describe("Action to call on close"),
388
394
  style: ExtensionComponentStyleSchema.optional()
389
395
  }).passthrough().describe("Modal component");
390
- var ConditionalGroupPropsSchema = z2.object({
391
- component: z2.literal("ConditionalGroup"),
392
- condition: z2.string().describe("Condition expression to evaluate"),
396
+ var ConditionalGroupPropsSchema = z3.object({
397
+ component: z3.literal("ConditionalGroup"),
398
+ condition: z3.string().describe("Condition expression to evaluate"),
393
399
  children: ExtensionComponentChildrenSchema.describe("Children to render when condition is true"),
394
400
  style: ExtensionComponentStyleSchema.optional()
395
401
  }).passthrough().describe("ConditionalGroup component");
396
- var FrameVariantSchema = z2.enum(["border", "solid"]).describe("Frame visual variant");
397
- var FramePropsSchema = z2.object({
398
- component: z2.literal("Frame"),
399
- title: z2.union([z2.string(), ExtensionComponentChildrenSchema]).optional().describe("Optional title (string or components)"),
400
- icon: z2.string().optional().describe("Icon name"),
401
- collapsible: z2.boolean().optional().describe("Whether content can be toggled"),
402
- defaultExpanded: z2.boolean().optional().describe("Whether expanded by default"),
402
+ var FrameVariantSchema = z3.enum(["border", "solid"]).describe("Frame visual variant");
403
+ var FramePropsSchema = z3.object({
404
+ component: z3.literal("Frame"),
405
+ title: z3.union([LocalizedStringSchema, ExtensionComponentChildrenSchema]).optional().describe("Optional title (string or components)"),
406
+ icon: z3.string().optional().describe("Icon name"),
407
+ collapsible: z3.boolean().optional().describe("Whether content can be toggled"),
408
+ defaultExpanded: z3.boolean().optional().describe("Whether expanded by default"),
403
409
  variant: FrameVariantSchema.optional().describe("Visual variant"),
404
410
  children: ExtensionComponentChildrenSchema.describe("Child components"),
405
411
  style: ExtensionComponentStyleSchema.optional()
406
412
  }).passthrough().describe("Frame container component");
407
- var ListPropsSchema = z2.object({
408
- component: z2.literal("List"),
413
+ var ListPropsSchema = z3.object({
414
+ component: z3.literal("List"),
409
415
  children: ExtensionComponentChildrenSchema.describe("Child components rendered as list items"),
410
416
  style: ExtensionComponentStyleSchema.optional()
411
417
  }).passthrough().describe("List component");
412
- var WeatherConditionSchema = z2.enum([
418
+ var WeatherConditionSchema = z3.enum([
413
419
  "clear",
414
420
  "partly-cloudy",
415
421
  "cloudy",
@@ -426,164 +432,164 @@ var WeatherConditionSchema = z2.enum([
426
432
  "hail",
427
433
  "windy"
428
434
  ]).describe("Weather condition");
429
- var WeatherWindSchema = z2.object({
430
- speed: z2.number().describe("Sustained wind speed"),
431
- unit: z2.string().optional().describe("Unit written after the speed. Defaults to m/s"),
432
- direction: z2.string().optional().describe("Compass direction, in the caller's own words"),
433
- gust: z2.number().optional().describe("Gust speed, in the same unit")
435
+ var WeatherWindSchema = z3.object({
436
+ speed: z3.number().describe("Sustained wind speed"),
437
+ unit: z3.string().optional().describe("Unit written after the speed. Defaults to m/s"),
438
+ direction: z3.string().optional().describe("Compass direction, in the caller's own words"),
439
+ gust: z3.number().optional().describe("Gust speed, in the same unit")
434
440
  }).passthrough().describe("Wind reading");
435
- var WeatherNowPropsSchema = z2.object({
436
- component: z2.literal("WeatherNow"),
437
- place: z2.string().describe("Where the reading is from"),
441
+ var WeatherNowPropsSchema = z3.object({
442
+ component: z3.literal("WeatherNow"),
443
+ place: z3.string().describe("Where the reading is from"),
438
444
  condition: WeatherConditionSchema,
439
- conditionLabel: z2.string().optional().describe("The condition in the user's own language"),
440
- temperature: z2.number().describe("Current temperature"),
441
- feelsLike: z2.number().optional().describe("Apparent temperature"),
442
- unit: z2.string().optional().describe("Written after every temperature. Defaults to \xB0"),
445
+ conditionLabel: z3.string().optional().describe("The condition in the user's own language"),
446
+ temperature: z3.number().describe("Current temperature"),
447
+ feelsLike: z3.number().optional().describe("Apparent temperature"),
448
+ unit: z3.string().optional().describe("Written after every temperature. Defaults to \xB0"),
443
449
  wind: WeatherWindSchema.optional(),
444
- night: z2.boolean().optional().describe("Draw the night variant of the icon"),
445
- summary: z2.string().optional().describe("One line of context under the numbers"),
450
+ night: z3.boolean().optional().describe("Draw the night variant of the icon"),
451
+ summary: z3.string().optional().describe("One line of context under the numbers"),
446
452
  style: ExtensionComponentStyleSchema.optional()
447
453
  }).passthrough().describe("Current weather component");
448
- var WeatherForecastStepSchema = z2.object({
449
- label: z2.string().describe("Short step label, e.g. 14 or Tors"),
454
+ var WeatherForecastStepSchema = z3.object({
455
+ label: z3.string().describe("Short step label, e.g. 14 or Tors"),
450
456
  condition: WeatherConditionSchema,
451
- conditionLabel: z2.string().optional(),
452
- high: z2.number().describe("The warmer temperature, or the only one"),
453
- low: z2.number().optional().describe("The colder temperature"),
454
- night: z2.boolean().optional(),
455
- precipitation: z2.number().min(0).max(100).optional().describe("Chance of precipitation, 0-100"),
456
- current: z2.boolean().optional().describe("The step the reader is at; drawn larger")
457
+ conditionLabel: z3.string().optional(),
458
+ high: z3.number().describe("The warmer temperature, or the only one"),
459
+ low: z3.number().optional().describe("The colder temperature"),
460
+ night: z3.boolean().optional(),
461
+ precipitation: z3.number().min(0).max(100).optional().describe("Chance of precipitation, 0-100"),
462
+ current: z3.boolean().optional().describe("The step the reader is at; drawn larger")
457
463
  }).passthrough().describe("One forecast step");
458
- var WeatherForecastPropsSchema = z2.object({
459
- component: z2.literal("WeatherForecast"),
460
- title: z2.string().optional().describe("Heading above the row"),
461
- icon: z2.string().optional().describe("Icon shown to the left of the title"),
462
- unit: z2.string().optional().describe("Written after every temperature. Defaults to \xB0"),
463
- steps: z2.array(WeatherForecastStepSchema).min(1).describe("Steps, hourly or daily"),
464
+ var WeatherForecastPropsSchema = z3.object({
465
+ component: z3.literal("WeatherForecast"),
466
+ title: LocalizedStringSchema.optional().describe("Heading above the row"),
467
+ icon: z3.string().optional().describe("Icon shown to the left of the title"),
468
+ unit: z3.string().optional().describe("Written after every temperature. Defaults to \xB0"),
469
+ steps: z3.array(WeatherForecastStepSchema).min(1).describe("Steps, hourly or daily"),
464
470
  style: ExtensionComponentStyleSchema.optional()
465
471
  }).passthrough().describe("Weather forecast component");
466
- var ChartKindSchema = z2.enum(["line", "bar", "area"]).describe("How the chart draws");
467
- var ChartSeriesSchema = z2.object({
468
- name: z2.string().optional().describe("Named in the legend"),
469
- points: z2.array(z2.number().nullable()).describe("One value per label. null is a gap, drawn as one")
472
+ var ChartKindSchema = z3.enum(["line", "bar", "area"]).describe("How the chart draws");
473
+ var ChartSeriesSchema = z3.object({
474
+ name: z3.string().optional().describe("Named in the legend"),
475
+ points: z3.array(z3.number().nullable()).describe("One value per label. null is a gap, drawn as one")
470
476
  }).passthrough().describe("One chart series");
471
- var ChartPropsSchema = z2.object({
472
- component: z2.literal("Chart"),
477
+ var ChartPropsSchema = z3.object({
478
+ component: z3.literal("Chart"),
473
479
  chart: ChartKindSchema.optional().describe("Defaults to line"),
474
- series: z2.array(ChartSeriesSchema).min(1).max(8).describe("At most eight series"),
475
- labels: z2.array(z2.string()).optional().describe("One per point, along the horizontal axis"),
476
- title: z2.string().optional().describe("Heading above the plot"),
477
- icon: z2.string().optional().describe("Icon shown to the left of the title"),
478
- unit: z2.string().optional().describe("Written after every value"),
479
- zeroBaseline: z2.boolean().optional().describe("Force the value axis to include zero"),
480
- height: z2.number().min(4).max(24).optional().describe("Plot height in rem. Defaults to 9"),
480
+ series: z3.array(ChartSeriesSchema).min(1).max(8).describe("At most eight series"),
481
+ labels: z3.array(z3.string()).optional().describe("One per point, along the horizontal axis"),
482
+ title: LocalizedStringSchema.optional().describe("Heading above the plot"),
483
+ icon: z3.string().optional().describe("Icon shown to the left of the title"),
484
+ unit: z3.string().optional().describe("Written after every value"),
485
+ zeroBaseline: z3.boolean().optional().describe("Force the value axis to include zero"),
486
+ height: z3.number().min(4).max(24).optional().describe("Plot height in rem. Defaults to 9"),
481
487
  style: ExtensionComponentStyleSchema.optional()
482
488
  }).passthrough().describe("Chart component");
483
- var StatTrendSchema = z2.enum(["up", "down", "flat"]).describe("Direction of change");
484
- var StatTilePropsSchema = z2.object({
485
- component: z2.literal("StatTile"),
486
- label: z2.string().describe("What the number is"),
487
- value: z2.union([z2.string(), z2.number()]).describe("The number itself"),
488
- unit: z2.string().optional().describe("Written after the value in smaller type"),
489
- caption: z2.string().optional().describe("One quiet line under the number"),
490
- icon: z2.string().optional().describe("Icon name"),
489
+ var StatTrendSchema = z3.enum(["up", "down", "flat"]).describe("Direction of change");
490
+ var StatTilePropsSchema = z3.object({
491
+ component: z3.literal("StatTile"),
492
+ label: LocalizedStringSchema.describe("What the number is"),
493
+ value: z3.union([z3.string(), z3.number()]).describe("The number itself"),
494
+ unit: z3.string().optional().describe("Written after the value in smaller type"),
495
+ caption: LocalizedStringSchema.optional().describe("One quiet line under the number"),
496
+ icon: z3.string().optional().describe("Icon name"),
491
497
  trend: StatTrendSchema.optional(),
492
- trendLabel: z2.string().optional().describe("The change in words"),
493
- trendIsGood: z2.boolean().optional().describe("Whether up is the good direction. Defaults to true"),
498
+ trendLabel: z3.string().optional().describe("The change in words"),
499
+ trendIsGood: z3.boolean().optional().describe("Whether up is the good direction. Defaults to true"),
494
500
  style: ExtensionComponentStyleSchema.optional()
495
501
  }).passthrough().describe("Single-number stat tile component");
496
- var ProgressShapeSchema = z2.enum(["bar", "circle"]).describe("Drawn as a rail or as a ring");
497
- var ProgressColorSchema = z2.enum(["accent", "success", "warning", "danger", "info", "neutral"]).describe("One of the theme colours");
498
- var ProgressBarPropsSchema = z2.object({
499
- component: z2.literal("ProgressBar"),
500
- label: z2.string().describe("What is being measured"),
501
- value: z2.number().describe("Where the reading sits. Clamped to the range"),
502
- min: z2.number().optional().describe("Bottom of the range. Defaults to 0"),
503
- max: z2.number().optional().describe("Top of the range. Defaults to 100"),
502
+ var ProgressShapeSchema = z3.enum(["bar", "circle"]).describe("Drawn as a rail or as a ring");
503
+ var ProgressColorSchema = z3.enum(["accent", "success", "warning", "danger", "info", "neutral"]).describe("One of the theme colours");
504
+ var ProgressBarPropsSchema = z3.object({
505
+ component: z3.literal("ProgressBar"),
506
+ label: LocalizedStringSchema.describe("What is being measured"),
507
+ value: z3.number().describe("Where the reading sits. Clamped to the range"),
508
+ min: z3.number().optional().describe("Bottom of the range. Defaults to 0"),
509
+ max: z3.number().optional().describe("Top of the range. Defaults to 100"),
504
510
  shape: ProgressShapeSchema.optional().describe("Defaults to bar"),
505
511
  color: ProgressColorSchema.optional().describe("Defaults to accent"),
506
- unit: z2.string().optional().describe("Written after the value"),
507
- valueLabel: z2.string().optional().describe("The readout in words, replacing value and unit"),
508
- caption: z2.string().optional().describe("One quiet line under the reading"),
509
- icon: z2.string().optional().describe("Icon name"),
512
+ unit: z3.string().optional().describe("Written after the value"),
513
+ valueLabel: z3.string().optional().describe("The readout in words, replacing value and unit"),
514
+ caption: LocalizedStringSchema.optional().describe("One quiet line under the reading"),
515
+ icon: z3.string().optional().describe("Icon name"),
510
516
  style: ExtensionComponentStyleSchema.optional()
511
517
  }).passthrough().describe("Progress component");
512
- var KeyValueRowSchema = z2.object({
513
- label: z2.string(),
514
- value: z2.string(),
515
- icon: z2.string().optional().describe("Icon name")
518
+ var KeyValueRowSchema = z3.object({
519
+ label: z3.string(),
520
+ value: z3.string(),
521
+ icon: z3.string().optional().describe("Icon name")
516
522
  }).passthrough().describe("One key/value row");
517
- var KeyValueListPropsSchema = z2.object({
518
- component: z2.literal("KeyValueList"),
519
- rows: z2.array(KeyValueRowSchema).min(1).describe("Facts in two aligned columns"),
523
+ var KeyValueListPropsSchema = z3.object({
524
+ component: z3.literal("KeyValueList"),
525
+ rows: z3.array(KeyValueRowSchema).min(1).describe("Facts in two aligned columns"),
520
526
  style: ExtensionComponentStyleSchema.optional()
521
527
  }).passthrough().describe("Key/value list component");
522
- var TimelineVariantSchema = z2.enum(["default", "accent", "success", "warning", "danger"]).describe("How much a timeline entry stands out");
523
- var TimelineEntrySchema = z2.object({
524
- time: z2.string().describe("When it happens, worded as it should be read"),
525
- title: z2.string(),
526
- description: z2.string().optional().describe("A line under the title"),
527
- icon: z2.string().optional().describe("Icon name"),
528
- duration: z2.string().optional().describe("How long it lasts, in words"),
529
- badge: z2.string().optional().describe("Trailing badge"),
530
- current: z2.boolean().optional().describe("The entry the reader is at"),
531
- past: z2.boolean().optional().describe("Already behind us; drawn recessive"),
528
+ var TimelineVariantSchema = z3.enum(["default", "accent", "success", "warning", "danger"]).describe("How much a timeline entry stands out");
529
+ var TimelineEntrySchema = z3.object({
530
+ time: z3.string().describe("When it happens, worded as it should be read"),
531
+ title: z3.string(),
532
+ description: z3.string().optional().describe("A line under the title"),
533
+ icon: z3.string().optional().describe("Icon name"),
534
+ duration: z3.string().optional().describe("How long it lasts, in words"),
535
+ badge: z3.string().optional().describe("Trailing badge"),
536
+ current: z3.boolean().optional().describe("The entry the reader is at"),
537
+ past: z3.boolean().optional().describe("Already behind us; drawn recessive"),
532
538
  variant: TimelineVariantSchema.optional()
533
539
  }).passthrough().describe("One timeline entry");
534
- var TimelinePropsSchema = z2.object({
535
- component: z2.literal("Timeline"),
536
- title: z2.string().optional().describe("Heading above the rail"),
537
- icon: z2.string().optional().describe("Icon shown to the left of the title"),
538
- entries: z2.array(TimelineEntrySchema).min(1).describe("Entries, in the order they happen"),
540
+ var TimelinePropsSchema = z3.object({
541
+ component: z3.literal("Timeline"),
542
+ title: LocalizedStringSchema.optional().describe("Heading above the rail"),
543
+ icon: z3.string().optional().describe("Icon shown to the left of the title"),
544
+ entries: z3.array(TimelineEntrySchema).min(1).describe("Entries, in the order they happen"),
539
545
  style: ExtensionComponentStyleSchema.optional()
540
546
  }).passthrough().describe("Vertical timeline component");
541
- var NoteVariantSchema = z2.enum(["default", "accent", "success", "warning", "danger"]).describe("How much a note stands out");
542
- var NotePropsSchema = z2.object({
543
- component: z2.literal("Note"),
544
- title: z2.string().optional(),
545
- icon: z2.string().optional().describe("Icon shown to the left of the title"),
546
- badge: z2.string().optional().describe("Trailing badge next to the title"),
547
- content: z2.string().describe("The body, as markdown"),
548
- footer: z2.string().optional().describe("One quiet line at the bottom"),
547
+ var NoteVariantSchema = z3.enum(["default", "accent", "success", "warning", "danger"]).describe("How much a note stands out");
548
+ var NotePropsSchema = z3.object({
549
+ component: z3.literal("Note"),
550
+ title: LocalizedStringSchema.optional(),
551
+ icon: z3.string().optional().describe("Icon shown to the left of the title"),
552
+ badge: z3.string().optional().describe("Trailing badge next to the title"),
553
+ content: z3.string().describe("The body, as markdown"),
554
+ footer: z3.string().optional().describe("One quiet line at the bottom"),
549
555
  variant: NoteVariantSchema.optional(),
550
556
  style: ExtensionComponentStyleSchema.optional()
551
557
  }).passthrough().describe("Titled block of prose component");
552
- var CalendarEventStatusSchema = z2.enum(["confirmed", "tentative", "cancelled"]).describe("Whether an event is going ahead");
553
- var CalendarEventPropsSchema = z2.object({
554
- component: z2.literal("CalendarEvent"),
555
- title: z2.string(),
556
- start: z2.string().describe("ISO 8601 with an offset"),
557
- end: z2.string().optional().describe("ISO 8601 with an offset"),
558
- allDay: z2.boolean().optional(),
559
- location: z2.string().optional(),
560
- organizer: z2.string().optional(),
561
- attendees: z2.array(z2.string()).optional(),
562
- calendar: z2.string().optional().describe("Which calendar it sits in; shown as a badge"),
558
+ var CalendarEventStatusSchema = z3.enum(["confirmed", "tentative", "cancelled"]).describe("Whether an event is going ahead");
559
+ var CalendarEventPropsSchema = z3.object({
560
+ component: z3.literal("CalendarEvent"),
561
+ title: z3.string(),
562
+ start: z3.string().describe("ISO 8601 with an offset"),
563
+ end: z3.string().optional().describe("ISO 8601 with an offset"),
564
+ allDay: z3.boolean().optional(),
565
+ location: z3.string().optional(),
566
+ organizer: z3.string().optional(),
567
+ attendees: z3.array(z3.string()).optional(),
568
+ calendar: z3.string().optional().describe("Which calendar it sits in; shown as a badge"),
563
569
  status: CalendarEventStatusSchema.optional(),
564
- recurrence: z2.string().optional().describe("How it repeats, in words"),
565
- notes: z2.string().optional(),
570
+ recurrence: z3.string().optional().describe("How it repeats, in words"),
571
+ notes: z3.string().optional(),
566
572
  style: ExtensionComponentStyleSchema.optional()
567
573
  }).passthrough().describe("Single calendar event component");
568
- var AgendaEventSchema = z2.object({
569
- id: z2.string().optional().describe("Handed back to onEventClickAction as $event.id"),
570
- title: z2.string(),
571
- start: z2.string().describe("ISO 8601 with an offset"),
572
- end: z2.string().optional().describe("ISO 8601 with an offset"),
573
- allDay: z2.boolean().optional(),
574
- detail: z2.string().optional().describe("One quiet line under the title")
574
+ var AgendaEventSchema = z3.object({
575
+ id: z3.string().optional().describe("Handed back to onEventClickAction as $event.id"),
576
+ title: z3.string(),
577
+ start: z3.string().describe("ISO 8601 with an offset"),
578
+ end: z3.string().optional().describe("ISO 8601 with an offset"),
579
+ allDay: z3.boolean().optional(),
580
+ detail: z3.string().optional().describe("One quiet line under the title")
575
581
  }).passthrough().describe("One agenda event");
576
- var AgendaDaySchema = z2.object({
577
- label: z2.string().describe("The day heading"),
578
- date: z2.string().optional().describe("A quieter line beside the heading"),
579
- events: z2.array(AgendaEventSchema)
582
+ var AgendaDaySchema = z3.object({
583
+ label: z3.string().describe("The day heading"),
584
+ date: z3.string().optional().describe("A quieter line beside the heading"),
585
+ events: z3.array(AgendaEventSchema)
580
586
  }).passthrough().describe("One agenda day");
581
- var AgendaPropsSchema = z2.object({
582
- component: z2.literal("Agenda"),
583
- title: z2.string().optional(),
584
- icon: z2.string().optional().describe("Icon shown to the left of the title"),
585
- days: z2.array(AgendaDaySchema),
586
- warnOverlaps: z2.boolean().optional().describe("Word clashes between events"),
587
+ var AgendaPropsSchema = z3.object({
588
+ component: z3.literal("Agenda"),
589
+ title: LocalizedStringSchema.optional(),
590
+ icon: z3.string().optional().describe("Icon shown to the left of the title"),
591
+ days: z3.array(AgendaDaySchema),
592
+ warnOverlaps: z3.boolean().optional().describe("Word clashes between events"),
587
593
  onEventClickAction: ExtensionActionRefSchema.optional().describe(
588
594
  "Action to call when an event is clicked, with the event as $event"
589
595
  ),
@@ -591,370 +597,369 @@ var AgendaPropsSchema = z2.object({
591
597
  }).passthrough().describe("Schedule component that tracks the current time");
592
598
 
593
599
  // src/schemas/contributions.schema.ts
594
- var LocalizedStringSchema = z3.union([z3.string(), z3.record(z3.string())]).describe("String or localized string map");
595
- var ToolSettingsListMappingSchema = z3.object({
596
- itemsKey: z3.string().describe("Key for items array in tool result data"),
597
- countKey: z3.string().optional().describe("Key for total count"),
598
- idKey: z3.string().describe("Key for item ID"),
599
- labelKey: z3.string().describe("Key for item label"),
600
- descriptionKey: z3.string().optional().describe("Key for item description"),
601
- secondaryKey: z3.string().optional().describe("Key for secondary label")
600
+ var ToolSettingsListMappingSchema = z4.object({
601
+ itemsKey: z4.string().describe("Key for items array in tool result data"),
602
+ countKey: z4.string().optional().describe("Key for total count"),
603
+ idKey: z4.string().describe("Key for item ID"),
604
+ labelKey: z4.string().describe("Key for item label"),
605
+ descriptionKey: z4.string().optional().describe("Key for item description"),
606
+ secondaryKey: z4.string().optional().describe("Key for secondary label")
602
607
  }).describe("Mapping from tool list data to UI fields");
603
- var ToolSettingsActionDataSourceSchema = z3.object({
604
- action: z3.string().describe("Action ID to call for fetching data"),
605
- params: z3.record(z3.unknown()).optional().describe("Parameters to pass to the action"),
606
- refreshOn: z3.array(z3.string()).optional().describe("Event names that trigger refresh")
608
+ var ToolSettingsActionDataSourceSchema = z4.object({
609
+ action: z4.string().describe("Action ID to call for fetching data"),
610
+ params: z4.record(z4.unknown()).optional().describe("Parameters to pass to the action"),
611
+ refreshOn: z4.array(z4.string()).optional().describe("Event names that trigger refresh")
607
612
  }).describe("Action-based data source");
608
- var ToolSettingsListGroupBySchema = z3.object({
609
- key: z3.string().describe("Key in each item used to determine group membership"),
610
- order: z3.array(z3.string()).optional().describe("Explicit ordering of group values; unlisted groups appear afterwards alphabetically"),
611
- labels: z3.record(z3.string()).optional().describe("Human-friendly labels per group value (rendered as section headers)")
613
+ var ToolSettingsListGroupBySchema = z4.object({
614
+ key: z4.string().describe("Key in each item used to determine group membership"),
615
+ order: z4.array(z4.string()).optional().describe("Explicit ordering of group values; unlisted groups appear afterwards alphabetically"),
616
+ labels: z4.record(LocalizedStringSchema).optional().describe("Human-friendly labels per group value (rendered as section headers)")
612
617
  }).describe("List view grouping configuration");
613
- var ToolSettingsListViewSchema = z3.object({
614
- kind: z3.literal("list").describe("View kind"),
615
- listToolId: z3.string().describe("Tool ID for listing items"),
616
- getToolId: z3.string().optional().describe("Tool ID for fetching details"),
617
- upsertToolId: z3.string().optional().describe("Tool ID for creating/updating items"),
618
- deleteToolId: z3.string().optional().describe("Tool ID for deleting items"),
618
+ var ToolSettingsListViewSchema = z4.object({
619
+ kind: z4.literal("list").describe("View kind"),
620
+ listToolId: z4.string().describe("Tool ID for listing items"),
621
+ getToolId: z4.string().optional().describe("Tool ID for fetching details"),
622
+ upsertToolId: z4.string().optional().describe("Tool ID for creating/updating items"),
623
+ deleteToolId: z4.string().optional().describe("Tool ID for deleting items"),
619
624
  mapping: ToolSettingsListMappingSchema.describe("Mapping from tool data to UI"),
620
- searchParam: z3.string().optional().describe("Param name for search query"),
621
- limitParam: z3.string().optional().describe("Param name for limit"),
622
- idParam: z3.string().optional().describe("Param name for get/delete ID"),
623
- listParams: z3.record(z3.unknown()).optional().describe("Static params for list tool"),
624
- editView: z3.object({
625
+ searchParam: z4.string().optional().describe("Param name for search query"),
626
+ limitParam: z4.string().optional().describe("Param name for limit"),
627
+ idParam: z4.string().optional().describe("Param name for get/delete ID"),
628
+ listParams: z4.record(z4.unknown()).optional().describe("Static params for list tool"),
629
+ editView: z4.object({
625
630
  content: ExtensionComponentDataSchema.describe("Root component for the create/edit modal")
626
631
  }).optional().describe("Component-tree create/edit form bound to $item.<key>"),
627
632
  groupBy: ToolSettingsListGroupBySchema.optional().describe(
628
633
  "Optional grouping configuration; when set, items are visually grouped by this field"
629
634
  )
630
635
  }).describe("List view backed by tools");
631
- var ToolSettingsComponentViewSchema = z3.object({
632
- kind: z3.literal("component").describe("View kind"),
633
- data: z3.record(ToolSettingsActionDataSourceSchema).optional().describe("Data sources"),
636
+ var ToolSettingsComponentViewSchema = z4.object({
637
+ kind: z4.literal("component").describe("View kind"),
638
+ data: z4.record(ToolSettingsActionDataSourceSchema).optional().describe("Data sources"),
634
639
  content: ExtensionComponentDataSchema.describe("Root component to render")
635
640
  }).describe("Component-based tool settings view");
636
- var ToolSettingsViewSchema = z3.union([ToolSettingsListViewSchema, ToolSettingsComponentViewSchema]).describe("Tool settings view");
637
- var ToolSettingsViewDefinitionSchema = z3.object({
638
- id: z3.string().describe("Unique view ID within the extension"),
639
- title: z3.string().describe("Display title"),
640
- description: z3.string().optional().describe("Help text"),
641
+ var ToolSettingsViewSchema = z4.union([ToolSettingsListViewSchema, ToolSettingsComponentViewSchema]).describe("Tool settings view");
642
+ var ToolSettingsViewDefinitionSchema = z4.object({
643
+ id: z4.string().describe("Unique view ID within the extension"),
644
+ title: LocalizedStringSchema.describe("Display title"),
645
+ description: LocalizedStringSchema.optional().describe("Help text"),
641
646
  // A string rather than the known topics: one this host does not know yet must not stop
642
647
  // the extension installing, it only lands on the extension's own page.
643
- topic: z3.string().optional().describe(
648
+ topic: z4.string().optional().describe(
644
649
  "What the view is about, which decides where Stina shows it: accounts, notifications, personal or tracking. Without one, or with one Stina does not know, the view is shown on the extension's own page."
645
650
  ),
646
651
  view: ToolSettingsViewSchema.describe("View configuration")
647
652
  }).describe("Tool settings view definition");
648
- var PanelActionDataSourceSchema = z3.object({
649
- action: z3.string().describe("Action ID to call for fetching data"),
650
- params: z3.record(z3.unknown()).optional().describe("Parameters to pass to the action"),
651
- refreshOn: z3.array(z3.string()).optional().describe("Event names that trigger refresh")
653
+ var PanelActionDataSourceSchema = z4.object({
654
+ action: z4.string().describe("Action ID to call for fetching data"),
655
+ params: z4.record(z4.unknown()).optional().describe("Parameters to pass to the action"),
656
+ refreshOn: z4.array(z4.string()).optional().describe("Event names that trigger refresh")
652
657
  }).describe("Panel data source");
653
- var PanelComponentViewSchema = z3.object({
654
- kind: z3.literal("component").describe("View kind"),
655
- data: z3.record(PanelActionDataSourceSchema).optional().describe("Data sources"),
658
+ var PanelComponentViewSchema = z4.object({
659
+ kind: z4.literal("component").describe("View kind"),
660
+ data: z4.record(PanelActionDataSourceSchema).optional().describe("Data sources"),
656
661
  content: ExtensionComponentDataSchema.describe("Root component to render")
657
662
  }).describe("Component-based panel view");
658
- var PanelUnknownViewSchema = z3.object({
659
- kind: z3.string().describe("View kind")
663
+ var PanelUnknownViewSchema = z4.object({
664
+ kind: z4.string().describe("View kind")
660
665
  }).passthrough().describe("Unknown panel view");
661
- var PanelViewSchema = z3.union([PanelComponentViewSchema, PanelUnknownViewSchema]).describe("Panel view");
662
- var PanelDefinitionSchema = z3.object({
663
- id: z3.string().describe("Unique panel ID within the extension"),
664
- title: z3.string().describe("Display title"),
665
- icon: z3.string().optional().describe("Icon name (from huge-icons)"),
666
+ var PanelViewSchema = z4.union([PanelComponentViewSchema, PanelUnknownViewSchema]).describe("Panel view");
667
+ var PanelDefinitionSchema = z4.object({
668
+ id: z4.string().describe("Unique panel ID within the extension"),
669
+ title: LocalizedStringSchema.describe("Display title"),
670
+ icon: z4.string().optional().describe("Icon name (from huge-icons)"),
666
671
  view: PanelViewSchema.describe("Panel view schema")
667
672
  }).describe("Panel definition");
668
- var StatusCardDefinitionSchema = z3.object({
669
- id: z3.string().describe("Unique card ID within the extension"),
670
- title: z3.string().describe("What it is called where the user picks it"),
671
- icon: z3.string().optional().describe("Icon name (from huge-icons)"),
672
- size: z3.enum(["line", "block"]).describe("How much room it may take: one row, or up to three"),
673
+ var StatusCardDefinitionSchema = z4.object({
674
+ id: z4.string().describe("Unique card ID within the extension"),
675
+ title: LocalizedStringSchema.describe("What it is called where the user picks it"),
676
+ icon: z4.string().optional().describe("Icon name (from huge-icons)"),
677
+ size: z4.enum(["line", "block"]).describe("How much room it may take: one row, or up to three"),
673
678
  view: PanelComponentViewSchema.describe("What it draws, and where the data comes from")
674
679
  }).describe("Status card definition");
675
- var ProviderConfigViewSchema = z3.object({
680
+ var ProviderConfigViewSchema = z4.object({
676
681
  content: ExtensionComponentDataSchema.describe("Root component to render")
677
682
  }).describe("Provider configuration view (component tree)");
678
- var ProviderDefinitionSchema = z3.object({
679
- id: z3.string().describe("Provider ID"),
680
- name: z3.string().describe("Display name"),
681
- description: z3.string().optional().describe("Description"),
682
- suggestedDefaultModel: z3.string().optional().describe("Suggested default model"),
683
- defaultSettings: z3.record(z3.unknown()).optional().describe("Default settings"),
683
+ var ProviderDefinitionSchema = z4.object({
684
+ id: z4.string().describe("Provider ID"),
685
+ name: z4.string().describe("Display name"),
686
+ description: z4.string().optional().describe("Description"),
687
+ suggestedDefaultModel: z4.string().optional().describe("Suggested default model"),
688
+ defaultSettings: z4.record(z4.unknown()).optional().describe("Default settings"),
684
689
  configView: ProviderConfigViewSchema.optional().describe("Component-tree configuration view")
685
690
  }).describe("Provider definition");
686
- var ToolDefinitionSchema = z3.object({
687
- id: z3.string().describe("Tool ID"),
691
+ var ToolDefinitionSchema = z4.object({
692
+ id: z4.string().describe("Tool ID"),
688
693
  name: LocalizedStringSchema.describe("Display name"),
689
694
  description: LocalizedStringSchema.describe("Description for Stina"),
690
- parameters: z3.record(z3.unknown()).optional().describe("Parameter schema (JSON Schema)"),
691
- requiresConfirmation: z3.boolean().optional().describe("Whether this tool requires user confirmation before execution (default: true)"),
695
+ parameters: z4.record(z4.unknown()).optional().describe("Parameter schema (JSON Schema)"),
696
+ requiresConfirmation: z4.boolean().optional().describe("Whether this tool requires user confirmation before execution (default: true)"),
692
697
  confirmationPrompt: LocalizedStringSchema.optional().describe("Custom confirmation prompt")
693
698
  }).describe("Tool definition");
694
- var CommandDefinitionSchema = z3.object({
695
- id: z3.string().describe('Command ID (e.g., "weather" for /weather)'),
696
- name: z3.string().describe("Display name"),
697
- description: z3.string().describe("Description")
699
+ var CommandDefinitionSchema = z4.object({
700
+ id: z4.string().describe('Command ID (e.g., "weather" for /weather)'),
701
+ name: z4.string().describe("Display name"),
702
+ description: z4.string().describe("Description")
698
703
  }).describe("Command definition");
699
- var PromptSectionSchema = z3.enum(["system", "behavior", "tools"]).describe("Prompt section placement");
700
- var PromptContributionSchema = z3.object({
701
- id: z3.string().describe("Unique ID within the extension"),
702
- title: z3.string().optional().describe("Optional title for the prompt chunk"),
704
+ var PromptSectionSchema = z4.enum(["system", "behavior", "tools"]).describe("Prompt section placement");
705
+ var PromptContributionSchema = z4.object({
706
+ id: z4.string().describe("Unique ID within the extension"),
707
+ title: z4.string().optional().describe("Optional title for the prompt chunk"),
703
708
  section: PromptSectionSchema.optional().describe("Prompt section placement"),
704
- text: z3.string().optional().describe("Plain text prompt content"),
705
- i18n: z3.record(z3.string()).optional().describe("Localized prompt content"),
706
- order: z3.number().optional().describe("Ordering hint (lower comes first)")
709
+ text: z4.string().optional().describe("Plain text prompt content"),
710
+ i18n: z4.record(z4.string()).optional().describe("Localized prompt content"),
711
+ order: z4.number().optional().describe("Ordering hint (lower comes first)")
707
712
  }).describe("Prompt contribution");
708
- var StorageCollectionConfigSchema = z3.object({
709
- indexes: z3.array(z3.string()).optional().describe("Fields to index for fast queries")
713
+ var StorageCollectionConfigSchema = z4.object({
714
+ indexes: z4.array(z4.string()).optional().describe("Fields to index for fast queries")
710
715
  }).describe("Collection configuration");
711
- var StorageContributionsSchema = z3.object({
712
- collections: z3.record(StorageCollectionConfigSchema).describe("Collection definitions")
716
+ var StorageContributionsSchema = z4.object({
717
+ collections: z4.record(StorageCollectionConfigSchema).describe("Collection definitions")
713
718
  }).describe("Storage contributions");
714
719
  var GRAPH_SCOPE_PATTERN = /^[A-Za-z]+(\.[A-Za-z]+)+$/;
715
720
  var HOST_ACCOUNT_SCOPES = ["offline_access", "User.Read", "openid", "profile", "email"];
716
- var AccountProviderSchema = z3.enum(["microsoft"]).describe("External account provider");
717
- var AccountContributionSchema = z3.object({
721
+ var AccountProviderSchema = z4.enum(["microsoft"]).describe("External account provider");
722
+ var AccountContributionSchema = z4.object({
718
723
  provider: AccountProviderSchema,
719
- scopes: z3.array(
720
- z3.string().regex(GRAPH_SCOPE_PATTERN, 'Must be a Microsoft Graph permission name, such as "Mail.Read"').refine(
724
+ scopes: z4.array(
725
+ z4.string().regex(GRAPH_SCOPE_PATTERN, 'Must be a Microsoft Graph permission name, such as "Mail.Read"').refine(
721
726
  (scope) => !HOST_ACCOUNT_SCOPES.some((hostScope) => hostScope.toLowerCase() === scope.toLowerCase()),
722
727
  { message: "Requested by the host already; leave it out" }
723
728
  )
724
729
  ).min(1).describe("Microsoft Graph delegated permissions"),
725
730
  reason: LocalizedStringSchema.optional().describe("Why the extension needs them")
726
731
  }).describe("An external account the extension works through");
727
- var ExtensionContributionsSchema = z3.object({
728
- toolSettings: z3.array(ToolSettingsViewDefinitionSchema).optional().describe("Tool settings views"),
729
- panels: z3.array(PanelDefinitionSchema).optional().describe("Right panel contributions"),
730
- statusCards: z3.array(StatusCardDefinitionSchema).optional().describe("Cards for the strip above the conversation list"),
731
- providers: z3.array(ProviderDefinitionSchema).optional().describe("AI providers"),
732
- tools: z3.array(ToolDefinitionSchema).optional().describe("Tools for Stina to use"),
733
- commands: z3.array(CommandDefinitionSchema).optional().describe("Slash commands"),
734
- prompts: z3.array(PromptContributionSchema).optional().describe("Prompt contributions"),
732
+ var ExtensionContributionsSchema = z4.object({
733
+ toolSettings: z4.array(ToolSettingsViewDefinitionSchema).optional().describe("Tool settings views"),
734
+ panels: z4.array(PanelDefinitionSchema).optional().describe("Right panel contributions"),
735
+ statusCards: z4.array(StatusCardDefinitionSchema).optional().describe("Cards for the strip above the conversation list"),
736
+ providers: z4.array(ProviderDefinitionSchema).optional().describe("AI providers"),
737
+ tools: z4.array(ToolDefinitionSchema).optional().describe("Tools for Stina to use"),
738
+ commands: z4.array(CommandDefinitionSchema).optional().describe("Slash commands"),
739
+ prompts: z4.array(PromptContributionSchema).optional().describe("Prompt contributions"),
735
740
  storage: StorageContributionsSchema.optional().describe("Storage collection declarations"),
736
- accounts: z3.array(AccountContributionSchema).optional().describe("External accounts the extension works through, signed in once in Stina's settings")
741
+ accounts: z4.array(AccountContributionSchema).optional().describe("External accounts the extension works through, signed in once in Stina's settings")
737
742
  }).describe("What an extension can contribute to Stina");
738
743
 
739
744
  // src/schemas/manifest.schema.ts
740
- var PlatformSchema = z4.enum(["web", "electron", "tui"]).describe("Supported platform");
741
- var AuthorSchema = z4.object({
742
- name: z4.string().min(1).describe("Author name"),
743
- url: z4.string().url().optional().describe("Author URL")
745
+ var PlatformSchema = z5.enum(["web", "electron", "tui"]).describe("Supported platform");
746
+ var AuthorSchema = z5.object({
747
+ name: z5.string().min(1).describe("Author name"),
748
+ url: z5.string().url().optional().describe("Author URL")
744
749
  }).describe("Author information");
745
- var EnginesSchema = z4.object({
746
- stina: z4.string().describe("Minimum Stina version required")
750
+ var EnginesSchema = z5.object({
751
+ stina: z5.string().describe("Minimum Stina version required")
747
752
  }).describe("Engine requirements");
748
- var ExtensionManifestSchema = z4.object({
749
- id: z4.string().regex(/^[a-z0-9-]+$/, "ID must be lowercase alphanumeric with hyphens").describe('Unique identifier (e.g., "ollama-provider")'),
750
- name: z4.string().min(1).describe("Human-readable name"),
751
- version: z4.string().regex(/^\d+\.\d+\.\d+/, 'Must be semver format (e.g., "1.0.0")').describe("Version string (semver)"),
752
- description: z4.string().min(1).describe("Short description"),
753
+ var ExtensionManifestSchema = z5.object({
754
+ id: z5.string().regex(/^[a-z0-9-]+$/, "ID must be lowercase alphanumeric with hyphens").describe('Unique identifier (e.g., "ollama-provider")'),
755
+ name: z5.string().min(1).describe("Human-readable name"),
756
+ version: z5.string().regex(/^\d+\.\d+\.\d+/, 'Must be semver format (e.g., "1.0.0")').describe("Version string (semver)"),
757
+ description: z5.string().min(1).describe("Short description"),
753
758
  // Optional icon (Hugeicons name) used as the default icon for proactive
754
759
  // conversation list entries this extension triggers. Kept optional so the
755
760
  // field is preserved (not stripped) when a manifest is parsed at load time.
756
- icon: z4.string().optional().describe("Icon (Hugeicons name) representing the extension"),
761
+ icon: z5.string().optional().describe("Icon (Hugeicons name) representing the extension"),
757
762
  author: AuthorSchema.describe("Author information"),
758
- repository: z4.string().url().optional().describe("Repository URL"),
759
- license: z4.string().optional().describe("License identifier"),
763
+ repository: z5.string().url().optional().describe("Repository URL"),
764
+ license: z5.string().optional().describe("License identifier"),
760
765
  engines: EnginesSchema.optional().describe("Minimum Stina version required"),
761
- platforms: z4.array(PlatformSchema).optional().describe("Supported platforms"),
762
- main: z4.string().describe("Entry point file (relative to extension root)"),
763
- permissions: z4.array(PermissionSchema).describe("Required permissions"),
766
+ platforms: z5.array(PlatformSchema).optional().describe("Supported platforms"),
767
+ main: z5.string().describe("Entry point file (relative to extension root)"),
768
+ permissions: z5.array(PermissionSchema).describe("Required permissions"),
764
769
  contributes: ExtensionContributionsSchema.optional().describe("What the extension contributes")
765
770
  }).describe("Extension manifest format");
766
771
 
767
772
  // src/schemas/card.schema.ts
768
- import { z as z5 } from "zod";
773
+ import { z as z6 } from "zod";
769
774
  var style = ExtensionComponentStyleSchema.optional();
770
- var children = z5.lazy(
771
- () => z5.array(ChatCardComponentSchema).max(40)
775
+ var children = z6.lazy(
776
+ () => z6.array(ChatCardComponentSchema).max(40)
772
777
  );
773
- var VerticalStackCardSchema = z5.object({
774
- component: z5.literal("VerticalStack"),
778
+ var VerticalStackCardSchema = z6.object({
779
+ component: z6.literal("VerticalStack"),
775
780
  children,
776
781
  style
777
782
  }).strict();
778
- var HorizontalStackCardSchema = z5.object({
779
- component: z5.literal("HorizontalStack"),
783
+ var HorizontalStackCardSchema = z6.object({
784
+ component: z6.literal("HorizontalStack"),
780
785
  children,
781
786
  style
782
787
  }).strict();
783
- var GridCardSchema = z5.object({
784
- component: z5.literal("Grid"),
785
- columns: z5.number().min(1).max(6),
788
+ var GridCardSchema = z6.object({
789
+ component: z6.literal("Grid"),
790
+ columns: z6.number().min(1).max(6),
786
791
  children,
787
792
  style
788
793
  }).strict();
789
- var FrameCardSchema = z5.object({
790
- component: z5.literal("Frame"),
794
+ var FrameCardSchema = z6.object({
795
+ component: z6.literal("Frame"),
791
796
  // Only the string form: the components form of a title is for panels that
792
797
  // put controls in their header, which a card has no business doing.
793
- title: z5.string().optional(),
794
- collapsible: z5.boolean().optional(),
795
- defaultExpanded: z5.boolean().optional(),
798
+ title: LocalizedStringSchema.optional(),
799
+ collapsible: z6.boolean().optional(),
800
+ defaultExpanded: z6.boolean().optional(),
796
801
  variant: FrameVariantSchema.optional(),
797
802
  children,
798
803
  style
799
804
  }).strict();
800
- var ListCardSchema = z5.object({ component: z5.literal("List"), children, style }).strict();
801
- var DividerCardSchema = z5.object({ component: z5.literal("Divider"), style }).strict();
802
- var HeaderCardSchema = z5.object({
803
- component: z5.literal("Header"),
804
- level: z5.number().min(1).max(6),
805
- title: z5.string(),
806
- description: z5.union([z5.string(), z5.array(z5.string())]).optional(),
807
- icon: z5.string().optional(),
805
+ var ListCardSchema = z6.object({ component: z6.literal("List"), children, style }).strict();
806
+ var DividerCardSchema = z6.object({ component: z6.literal("Divider"), style }).strict();
807
+ var HeaderCardSchema = z6.object({
808
+ component: z6.literal("Header"),
809
+ level: z6.number().min(1).max(6),
810
+ title: LocalizedStringSchema,
811
+ description: z6.union([LocalizedStringSchema, z6.array(LocalizedStringSchema)]).optional(),
812
+ icon: z6.string().optional(),
808
813
  style
809
814
  }).strict();
810
- var LabelCardSchema = z5.object({ component: z5.literal("Label"), text: z5.string(), style }).strict();
811
- var ParagraphCardSchema = z5.object({ component: z5.literal("Paragraph"), text: z5.string(), style }).strict();
812
- var MarkdownCardSchema = z5.object({ component: z5.literal("Markdown"), content: z5.string(), style }).strict();
813
- var IconCardSchema = z5.object({
814
- component: z5.literal("Icon"),
815
- name: z5.string(),
816
- title: z5.string().optional(),
815
+ var LabelCardSchema = z6.object({ component: z6.literal("Label"), text: z6.string(), style }).strict();
816
+ var ParagraphCardSchema = z6.object({ component: z6.literal("Paragraph"), text: z6.string(), style }).strict();
817
+ var MarkdownCardSchema = z6.object({ component: z6.literal("Markdown"), content: z6.string(), style }).strict();
818
+ var IconCardSchema = z6.object({
819
+ component: z6.literal("Icon"),
820
+ name: z6.string(),
821
+ title: LocalizedStringSchema.optional(),
817
822
  style
818
823
  }).strict();
819
- var PillCardSchema = z5.object({
820
- component: z5.literal("Pill"),
821
- text: z5.string(),
822
- icon: z5.string().optional(),
824
+ var PillCardSchema = z6.object({
825
+ component: z6.literal("Pill"),
826
+ text: LocalizedStringSchema,
827
+ icon: z6.string().optional(),
823
828
  variant: PillVariantSchema.optional(),
824
829
  style
825
830
  }).strict();
826
- var WeatherNowCardSchema = z5.object({
827
- component: z5.literal("WeatherNow"),
828
- place: z5.string(),
831
+ var WeatherNowCardSchema = z6.object({
832
+ component: z6.literal("WeatherNow"),
833
+ place: z6.string(),
829
834
  condition: WeatherConditionSchema,
830
- conditionLabel: z5.string().optional(),
831
- temperature: z5.number(),
832
- feelsLike: z5.number().optional(),
833
- unit: z5.string().optional(),
835
+ conditionLabel: z6.string().optional(),
836
+ temperature: z6.number(),
837
+ feelsLike: z6.number().optional(),
838
+ unit: z6.string().optional(),
834
839
  wind: WeatherWindSchema.optional(),
835
- night: z5.boolean().optional(),
836
- summary: z5.string().optional(),
840
+ night: z6.boolean().optional(),
841
+ summary: z6.string().optional(),
837
842
  style
838
843
  }).strict();
839
- var WeatherForecastCardSchema = z5.object({
840
- component: z5.literal("WeatherForecast"),
841
- title: z5.string().optional(),
842
- icon: z5.string().optional(),
843
- unit: z5.string().optional(),
844
- steps: z5.array(
845
- z5.object({
846
- label: z5.string(),
844
+ var WeatherForecastCardSchema = z6.object({
845
+ component: z6.literal("WeatherForecast"),
846
+ title: LocalizedStringSchema.optional(),
847
+ icon: z6.string().optional(),
848
+ unit: z6.string().optional(),
849
+ steps: z6.array(
850
+ z6.object({
851
+ label: z6.string(),
847
852
  condition: WeatherConditionSchema,
848
- conditionLabel: z5.string().optional(),
849
- high: z5.number(),
850
- low: z5.number().optional(),
851
- night: z5.boolean().optional(),
852
- precipitation: z5.number().min(0).max(100).optional(),
853
- current: z5.boolean().optional()
853
+ conditionLabel: z6.string().optional(),
854
+ high: z6.number(),
855
+ low: z6.number().optional(),
856
+ night: z6.boolean().optional(),
857
+ precipitation: z6.number().min(0).max(100).optional(),
858
+ current: z6.boolean().optional()
854
859
  }).strict()
855
860
  ).min(1).max(24),
856
861
  style
857
862
  }).strict();
858
- var ChartCardSchema = z5.object({
859
- component: z5.literal("Chart"),
863
+ var ChartCardSchema = z6.object({
864
+ component: z6.literal("Chart"),
860
865
  chart: ChartKindSchema.optional(),
861
- series: z5.array(
862
- z5.object({
863
- name: z5.string().optional(),
864
- points: z5.array(z5.number().nullable()).min(1).max(200)
866
+ series: z6.array(
867
+ z6.object({
868
+ name: z6.string().optional(),
869
+ points: z6.array(z6.number().nullable()).min(1).max(200)
865
870
  }).strict()
866
871
  ).min(1).max(8),
867
- labels: z5.array(z5.string()).max(200).optional(),
868
- title: z5.string().optional(),
869
- icon: z5.string().optional(),
870
- unit: z5.string().optional(),
871
- zeroBaseline: z5.boolean().optional(),
872
- height: z5.number().min(4).max(24).optional(),
872
+ labels: z6.array(z6.string()).max(200).optional(),
873
+ title: LocalizedStringSchema.optional(),
874
+ icon: z6.string().optional(),
875
+ unit: z6.string().optional(),
876
+ zeroBaseline: z6.boolean().optional(),
877
+ height: z6.number().min(4).max(24).optional(),
873
878
  style
874
879
  }).strict();
875
- var StatTileCardSchema = z5.object({
876
- component: z5.literal("StatTile"),
877
- label: z5.string(),
878
- value: z5.union([z5.string(), z5.number()]),
879
- unit: z5.string().optional(),
880
- caption: z5.string().optional(),
881
- icon: z5.string().optional(),
880
+ var StatTileCardSchema = z6.object({
881
+ component: z6.literal("StatTile"),
882
+ label: LocalizedStringSchema,
883
+ value: z6.union([z6.string(), z6.number()]),
884
+ unit: z6.string().optional(),
885
+ caption: LocalizedStringSchema.optional(),
886
+ icon: z6.string().optional(),
882
887
  trend: StatTrendSchema.optional(),
883
- trendLabel: z5.string().optional(),
884
- trendIsGood: z5.boolean().optional(),
888
+ trendLabel: z6.string().optional(),
889
+ trendIsGood: z6.boolean().optional(),
885
890
  style
886
891
  }).strict();
887
- var ProgressBarCardSchema = z5.object({
888
- component: z5.literal("ProgressBar"),
889
- label: z5.string(),
890
- value: z5.number(),
891
- min: z5.number().optional(),
892
- max: z5.number().optional(),
892
+ var ProgressBarCardSchema = z6.object({
893
+ component: z6.literal("ProgressBar"),
894
+ label: LocalizedStringSchema,
895
+ value: z6.number(),
896
+ min: z6.number().optional(),
897
+ max: z6.number().optional(),
893
898
  shape: ProgressShapeSchema.optional(),
894
899
  color: ProgressColorSchema.optional(),
895
- unit: z5.string().optional(),
896
- valueLabel: z5.string().optional(),
897
- caption: z5.string().optional(),
898
- icon: z5.string().optional(),
900
+ unit: z6.string().optional(),
901
+ valueLabel: z6.string().optional(),
902
+ caption: LocalizedStringSchema.optional(),
903
+ icon: z6.string().optional(),
899
904
  style
900
905
  }).strict();
901
- var KeyValueListCardSchema = z5.object({
902
- component: z5.literal("KeyValueList"),
903
- rows: z5.array(
904
- z5.object({ label: z5.string(), value: z5.string(), icon: z5.string().optional() }).strict()
906
+ var KeyValueListCardSchema = z6.object({
907
+ component: z6.literal("KeyValueList"),
908
+ rows: z6.array(
909
+ z6.object({ label: z6.string(), value: z6.string(), icon: z6.string().optional() }).strict()
905
910
  ).min(1).max(40),
906
911
  style
907
912
  }).strict();
908
- var TimelineCardSchema = z5.object({
909
- component: z5.literal("Timeline"),
910
- title: z5.string().optional(),
911
- icon: z5.string().optional(),
912
- entries: z5.array(
913
- z5.object({
914
- time: z5.string(),
915
- title: z5.string(),
916
- description: z5.string().optional(),
917
- icon: z5.string().optional(),
918
- duration: z5.string().optional(),
919
- badge: z5.string().optional(),
920
- current: z5.boolean().optional(),
921
- past: z5.boolean().optional(),
913
+ var TimelineCardSchema = z6.object({
914
+ component: z6.literal("Timeline"),
915
+ title: LocalizedStringSchema.optional(),
916
+ icon: z6.string().optional(),
917
+ entries: z6.array(
918
+ z6.object({
919
+ time: z6.string(),
920
+ title: z6.string(),
921
+ description: z6.string().optional(),
922
+ icon: z6.string().optional(),
923
+ duration: z6.string().optional(),
924
+ badge: z6.string().optional(),
925
+ current: z6.boolean().optional(),
926
+ past: z6.boolean().optional(),
922
927
  variant: TimelineVariantSchema.optional()
923
928
  }).strict()
924
929
  ).min(1).max(40),
925
930
  style
926
931
  }).strict();
927
- var NoteCardSchema = z5.object({
928
- component: z5.literal("Note"),
929
- title: z5.string().optional(),
930
- icon: z5.string().optional(),
931
- badge: z5.string().optional(),
932
- content: z5.string(),
933
- footer: z5.string().optional(),
932
+ var NoteCardSchema = z6.object({
933
+ component: z6.literal("Note"),
934
+ title: LocalizedStringSchema.optional(),
935
+ icon: z6.string().optional(),
936
+ badge: z6.string().optional(),
937
+ content: z6.string(),
938
+ footer: z6.string().optional(),
934
939
  variant: NoteVariantSchema.optional(),
935
940
  style
936
941
  }).strict();
937
- var QuoteCardSchema = z5.object({
938
- component: z5.literal("Quote"),
939
- text: z5.string(),
940
- source: z5.string().optional(),
941
- context: z5.string().optional(),
942
- footer: z5.string().optional(),
942
+ var QuoteCardSchema = z6.object({
943
+ component: z6.literal("Quote"),
944
+ text: z6.string(),
945
+ source: z6.string().optional(),
946
+ context: z6.string().optional(),
947
+ footer: z6.string().optional(),
943
948
  style
944
949
  }).strict();
945
- var CalendarEventCardSchema = z5.object({
946
- component: z5.literal("CalendarEvent"),
947
- title: z5.string(),
948
- start: z5.string(),
949
- end: z5.string().optional(),
950
- allDay: z5.boolean().optional(),
951
- location: z5.string().optional(),
952
- organizer: z5.string().optional(),
953
- attendees: z5.array(z5.string()).max(40).optional(),
954
- calendar: z5.string().optional(),
950
+ var CalendarEventCardSchema = z6.object({
951
+ component: z6.literal("CalendarEvent"),
952
+ title: z6.string(),
953
+ start: z6.string(),
954
+ end: z6.string().optional(),
955
+ allDay: z6.boolean().optional(),
956
+ location: z6.string().optional(),
957
+ organizer: z6.string().optional(),
958
+ attendees: z6.array(z6.string()).max(40).optional(),
959
+ calendar: z6.string().optional(),
955
960
  status: CalendarEventStatusSchema.optional(),
956
- recurrence: z5.string().optional(),
957
- notes: z5.string().optional(),
961
+ recurrence: z6.string().optional(),
962
+ notes: z6.string().optional(),
958
963
  style
959
964
  }).strict();
960
965
  var CHAT_CARD_COMPONENTS = [
@@ -1014,8 +1019,8 @@ var CHAT_CARD_PROPS = Object.freeze(
1014
1019
  })
1015
1020
  )
1016
1021
  );
1017
- var ChatCardComponentSchema = z5.lazy(
1018
- () => z5.discriminatedUnion(
1022
+ var ChatCardComponentSchema = z6.lazy(
1023
+ () => z6.discriminatedUnion(
1019
1024
  "component",
1020
1025
  CARD_MEMBERS
1021
1026
  )