@tx5dr/contracts 1.7.3 → 1.7.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (108) hide show
  1. package/dist/index.d.ts +4 -0
  2. package/dist/index.d.ts.map +1 -1
  3. package/dist/index.js +6 -0
  4. package/dist/index.js.map +1 -1
  5. package/dist/schema/__tests__/ability.test.d.ts +2 -0
  6. package/dist/schema/__tests__/ability.test.d.ts.map +1 -0
  7. package/dist/schema/__tests__/ability.test.js +32 -0
  8. package/dist/schema/__tests__/ability.test.js.map +1 -0
  9. package/dist/schema/__tests__/cw-decoder.schema.test.d.ts +2 -0
  10. package/dist/schema/__tests__/cw-decoder.schema.test.d.ts.map +1 -0
  11. package/dist/schema/__tests__/cw-decoder.schema.test.js +114 -0
  12. package/dist/schema/__tests__/cw-decoder.schema.test.js.map +1 -0
  13. package/dist/schema/__tests__/device-ui.schema.test.d.ts +2 -0
  14. package/dist/schema/__tests__/device-ui.schema.test.d.ts.map +1 -0
  15. package/dist/schema/__tests__/device-ui.schema.test.js +111 -0
  16. package/dist/schema/__tests__/device-ui.schema.test.js.map +1 -0
  17. package/dist/schema/__tests__/process-monitor.schema.test.js +96 -0
  18. package/dist/schema/__tests__/process-monitor.schema.test.js.map +1 -1
  19. package/dist/schema/__tests__/radio.schema.test.d.ts +2 -0
  20. package/dist/schema/__tests__/radio.schema.test.d.ts.map +1 -0
  21. package/dist/schema/__tests__/radio.schema.test.js +143 -0
  22. package/dist/schema/__tests__/radio.schema.test.js.map +1 -0
  23. package/dist/schema/ability.d.ts +3 -1
  24. package/dist/schema/ability.d.ts.map +1 -1
  25. package/dist/schema/ability.js +11 -0
  26. package/dist/schema/ability.js.map +1 -1
  27. package/dist/schema/api-response.schema.d.ts +168 -1
  28. package/dist/schema/api-response.schema.d.ts.map +1 -1
  29. package/dist/schema/api-response.schema.js +22 -0
  30. package/dist/schema/api-response.schema.js.map +1 -1
  31. package/dist/schema/cpu-profile.schema.d.ts +6 -6
  32. package/dist/schema/cw-decoder.schema.d.ts +2501 -0
  33. package/dist/schema/cw-decoder.schema.d.ts.map +1 -0
  34. package/dist/schema/cw-decoder.schema.js +196 -0
  35. package/dist/schema/cw-decoder.schema.js.map +1 -0
  36. package/dist/schema/cw-keyer.schema.d.ts +368 -0
  37. package/dist/schema/cw-keyer.schema.d.ts.map +1 -0
  38. package/dist/schema/cw-keyer.schema.js +143 -0
  39. package/dist/schema/cw-keyer.schema.js.map +1 -0
  40. package/dist/schema/desktop-https.schema.js +1 -1
  41. package/dist/schema/desktop-https.schema.js.map +1 -1
  42. package/dist/schema/device-ui.schema.d.ts +1782 -0
  43. package/dist/schema/device-ui.schema.d.ts.map +1 -0
  44. package/dist/schema/device-ui.schema.js +156 -0
  45. package/dist/schema/device-ui.schema.js.map +1 -0
  46. package/dist/schema/mode.schema.d.ts +1 -0
  47. package/dist/schema/mode.schema.d.ts.map +1 -1
  48. package/dist/schema/mode.schema.js +8 -0
  49. package/dist/schema/mode.schema.js.map +1 -1
  50. package/dist/schema/plugin.schema.d.ts +637 -54
  51. package/dist/schema/plugin.schema.d.ts.map +1 -1
  52. package/dist/schema/plugin.schema.js +22 -2
  53. package/dist/schema/plugin.schema.js.map +1 -1
  54. package/dist/schema/process-monitor.schema.d.ts +1948 -261
  55. package/dist/schema/process-monitor.schema.d.ts.map +1 -1
  56. package/dist/schema/process-monitor.schema.js +11 -0
  57. package/dist/schema/process-monitor.schema.js.map +1 -1
  58. package/dist/schema/radio-capability.schema.d.ts +1 -1
  59. package/dist/schema/radio-capability.schema.d.ts.map +1 -1
  60. package/dist/schema/radio-capability.schema.js +41 -0
  61. package/dist/schema/radio-capability.schema.js.map +1 -1
  62. package/dist/schema/radio-power.schema.d.ts +6 -0
  63. package/dist/schema/radio-power.schema.d.ts.map +1 -1
  64. package/dist/schema/radio-profile.schema.d.ts +86 -0
  65. package/dist/schema/radio-profile.schema.d.ts.map +1 -1
  66. package/dist/schema/radio.schema.d.ts +160 -3
  67. package/dist/schema/radio.schema.d.ts.map +1 -1
  68. package/dist/schema/radio.schema.js +82 -0
  69. package/dist/schema/radio.schema.js.map +1 -1
  70. package/dist/schema/realtime.schema.d.ts +6 -6
  71. package/dist/schema/voice.schema.d.ts +1 -1
  72. package/dist/schema/voice.schema.d.ts.map +1 -1
  73. package/dist/schema/voice.schema.js +1 -1
  74. package/dist/schema/voice.schema.js.map +1 -1
  75. package/dist/schema/websocket.schema.d.ts +5615 -412
  76. package/dist/schema/websocket.schema.d.ts.map +1 -1
  77. package/dist/schema/websocket.schema.js +102 -2
  78. package/dist/schema/websocket.schema.js.map +1 -1
  79. package/dist/utils/__tests__/cwTiming.test.d.ts +2 -0
  80. package/dist/utils/__tests__/cwTiming.test.d.ts.map +1 -0
  81. package/dist/utils/__tests__/cwTiming.test.js +74 -0
  82. package/dist/utils/__tests__/cwTiming.test.js.map +1 -0
  83. package/dist/utils/cwTiming.d.ts +36 -0
  84. package/dist/utils/cwTiming.d.ts.map +1 -0
  85. package/dist/utils/cwTiming.js +155 -0
  86. package/dist/utils/cwTiming.js.map +1 -0
  87. package/package.json +1 -1
  88. package/src/index.ts +8 -0
  89. package/src/schema/__tests__/ability.test.ts +40 -0
  90. package/src/schema/__tests__/cw-decoder.schema.test.ts +127 -0
  91. package/src/schema/__tests__/device-ui.schema.test.ts +122 -0
  92. package/src/schema/__tests__/process-monitor.schema.test.ts +99 -0
  93. package/src/schema/__tests__/radio.schema.test.ts +160 -0
  94. package/src/schema/ability.ts +13 -0
  95. package/src/schema/api-response.schema.ts +22 -0
  96. package/src/schema/cw-decoder.schema.ts +234 -0
  97. package/src/schema/cw-keyer.schema.ts +177 -0
  98. package/src/schema/desktop-https.schema.ts +1 -1
  99. package/src/schema/device-ui.schema.ts +182 -0
  100. package/src/schema/mode.schema.ts +8 -0
  101. package/src/schema/plugin.schema.ts +28 -2
  102. package/src/schema/process-monitor.schema.ts +18 -0
  103. package/src/schema/radio-capability.schema.ts +41 -0
  104. package/src/schema/radio.schema.ts +97 -0
  105. package/src/schema/voice.schema.ts +1 -1
  106. package/src/schema/websocket.schema.ts +131 -2
  107. package/src/utils/__tests__/cwTiming.test.ts +91 -0
  108. package/src/utils/cwTiming.ts +203 -0
@@ -48,7 +48,7 @@ export type PluginPanelComponent = z.infer<typeof PluginPanelComponentSchema>;
48
48
  * These values control both validation expectations and default frontend
49
49
  * rendering in plugin settings UIs.
50
50
  */
51
- export declare const PluginSettingTypeSchema: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "info"]>;
51
+ export declare const PluginSettingTypeSchema: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "keyedStringArrays", "info"]>;
52
52
  /**
53
53
  * Supported generated-form field types for plugin settings.
54
54
  */
@@ -93,6 +93,65 @@ export declare const PluginObjectArrayFieldSchema: z.ZodObject<{
93
93
  required?: boolean | undefined;
94
94
  }>;
95
95
  export type PluginObjectArrayField = z.infer<typeof PluginObjectArrayFieldSchema>;
96
+ export declare const PluginKeyedStringArrayKeySchema: z.ZodObject<{
97
+ key: z.ZodString;
98
+ label: z.ZodString;
99
+ description: z.ZodOptional<z.ZodString>;
100
+ }, "strip", z.ZodTypeAny, {
101
+ label: string;
102
+ key: string;
103
+ description?: string | undefined;
104
+ }, {
105
+ label: string;
106
+ key: string;
107
+ description?: string | undefined;
108
+ }>;
109
+ export type PluginKeyedStringArrayKey = z.infer<typeof PluginKeyedStringArrayKeySchema>;
110
+ export declare const PluginSettingConditionSchema: z.ZodObject<{
111
+ setting: z.ZodString;
112
+ equals: z.ZodOptional<z.ZodUnknown>;
113
+ notEquals: z.ZodOptional<z.ZodUnknown>;
114
+ }, "strip", z.ZodTypeAny, {
115
+ setting: string;
116
+ equals?: unknown;
117
+ notEquals?: unknown;
118
+ }, {
119
+ setting: string;
120
+ equals?: unknown;
121
+ notEquals?: unknown;
122
+ }>;
123
+ export type PluginSettingCondition = z.infer<typeof PluginSettingConditionSchema>;
124
+ export declare const PluginSettingConditionalDescriptionSchema: z.ZodObject<{
125
+ when: z.ZodObject<{
126
+ setting: z.ZodString;
127
+ equals: z.ZodOptional<z.ZodUnknown>;
128
+ notEquals: z.ZodOptional<z.ZodUnknown>;
129
+ }, "strip", z.ZodTypeAny, {
130
+ setting: string;
131
+ equals?: unknown;
132
+ notEquals?: unknown;
133
+ }, {
134
+ setting: string;
135
+ equals?: unknown;
136
+ notEquals?: unknown;
137
+ }>;
138
+ description: z.ZodString;
139
+ }, "strip", z.ZodTypeAny, {
140
+ description: string;
141
+ when: {
142
+ setting: string;
143
+ equals?: unknown;
144
+ notEquals?: unknown;
145
+ };
146
+ }, {
147
+ description: string;
148
+ when: {
149
+ setting: string;
150
+ equals?: unknown;
151
+ notEquals?: unknown;
152
+ };
153
+ }>;
154
+ export type PluginSettingConditionalDescription = z.infer<typeof PluginSettingConditionalDescriptionSchema>;
96
155
  /**
97
156
  * Persistence and UI scope for a plugin setting.
98
157
  *
@@ -113,7 +172,7 @@ export type PluginSettingScope = z.infer<typeof PluginSettingScopeSchema>;
113
172
  * and resolve default values before injecting them into `ctx.config`.
114
173
  */
115
174
  export declare const PluginSettingDescriptorSchema: z.ZodObject<{
116
- type: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "info"]>;
175
+ type: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "keyedStringArrays", "info"]>;
117
176
  default: z.ZodUnknown;
118
177
  label: z.ZodString;
119
178
  description: z.ZodOptional<z.ZodString>;
@@ -152,14 +211,78 @@ export declare const PluginSettingDescriptorSchema: z.ZodObject<{
152
211
  placeholder?: string | undefined;
153
212
  required?: boolean | undefined;
154
213
  }>, "many">>;
214
+ /** Fixed key list used by generated editors for `keyedStringArrays` settings. */
215
+ keys: z.ZodOptional<z.ZodArray<z.ZodObject<{
216
+ key: z.ZodString;
217
+ label: z.ZodString;
218
+ description: z.ZodOptional<z.ZodString>;
219
+ }, "strip", z.ZodTypeAny, {
220
+ label: string;
221
+ key: string;
222
+ description?: string | undefined;
223
+ }, {
224
+ label: string;
225
+ key: string;
226
+ description?: string | undefined;
227
+ }>, "many">>;
228
+ /** Conditionally show the field based on another setting in the same form. */
229
+ visibleWhen: z.ZodOptional<z.ZodObject<{
230
+ setting: z.ZodString;
231
+ equals: z.ZodOptional<z.ZodUnknown>;
232
+ notEquals: z.ZodOptional<z.ZodUnknown>;
233
+ }, "strip", z.ZodTypeAny, {
234
+ setting: string;
235
+ equals?: unknown;
236
+ notEquals?: unknown;
237
+ }, {
238
+ setting: string;
239
+ equals?: unknown;
240
+ notEquals?: unknown;
241
+ }>>;
242
+ /** Conditionally override the field description based on another setting. */
243
+ descriptionWhen: z.ZodOptional<z.ZodArray<z.ZodObject<{
244
+ when: z.ZodObject<{
245
+ setting: z.ZodString;
246
+ equals: z.ZodOptional<z.ZodUnknown>;
247
+ notEquals: z.ZodOptional<z.ZodUnknown>;
248
+ }, "strip", z.ZodTypeAny, {
249
+ setting: string;
250
+ equals?: unknown;
251
+ notEquals?: unknown;
252
+ }, {
253
+ setting: string;
254
+ equals?: unknown;
255
+ notEquals?: unknown;
256
+ }>;
257
+ description: z.ZodString;
258
+ }, "strip", z.ZodTypeAny, {
259
+ description: string;
260
+ when: {
261
+ setting: string;
262
+ equals?: unknown;
263
+ notEquals?: unknown;
264
+ };
265
+ }, {
266
+ description: string;
267
+ when: {
268
+ setting: string;
269
+ equals?: unknown;
270
+ notEquals?: unknown;
271
+ };
272
+ }>, "many">>;
155
273
  /** Internal settings are persisted/injected but hidden from generated UIs. */
156
274
  hidden: z.ZodOptional<z.ZodBoolean>;
157
275
  /** 设置作用域:global(所有操作员共享)或 operator(每操作员独立),默认 global */
158
276
  scope: z.ZodDefault<z.ZodOptional<z.ZodEnum<["global", "operator"]>>>;
159
277
  }, "strip", z.ZodTypeAny, {
160
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
278
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
161
279
  label: string;
162
280
  scope: "operator" | "global";
281
+ keys?: {
282
+ label: string;
283
+ key: string;
284
+ description?: string | undefined;
285
+ }[] | undefined;
163
286
  options?: {
164
287
  value: string;
165
288
  label: string;
@@ -176,10 +299,28 @@ export declare const PluginSettingDescriptorSchema: z.ZodObject<{
176
299
  placeholder?: string | undefined;
177
300
  required?: boolean | undefined;
178
301
  }[] | undefined;
302
+ visibleWhen?: {
303
+ setting: string;
304
+ equals?: unknown;
305
+ notEquals?: unknown;
306
+ } | undefined;
307
+ descriptionWhen?: {
308
+ description: string;
309
+ when: {
310
+ setting: string;
311
+ equals?: unknown;
312
+ notEquals?: unknown;
313
+ };
314
+ }[] | undefined;
179
315
  hidden?: boolean | undefined;
180
316
  }, {
181
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
317
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
182
318
  label: string;
319
+ keys?: {
320
+ label: string;
321
+ key: string;
322
+ description?: string | undefined;
323
+ }[] | undefined;
183
324
  options?: {
184
325
  value: string;
185
326
  label: string;
@@ -196,6 +337,19 @@ export declare const PluginSettingDescriptorSchema: z.ZodObject<{
196
337
  placeholder?: string | undefined;
197
338
  required?: boolean | undefined;
198
339
  }[] | undefined;
340
+ visibleWhen?: {
341
+ setting: string;
342
+ equals?: unknown;
343
+ notEquals?: unknown;
344
+ } | undefined;
345
+ descriptionWhen?: {
346
+ description: string;
347
+ when: {
348
+ setting: string;
349
+ equals?: unknown;
350
+ notEquals?: unknown;
351
+ };
352
+ }[] | undefined;
199
353
  hidden?: boolean | undefined;
200
354
  scope?: "operator" | "global" | undefined;
201
355
  }>;
@@ -267,7 +421,7 @@ export type PluginCapability = z.infer<typeof PluginCapabilitySchema>;
267
421
  * - `voice-left-top`: shown above the voice frequency control card.
268
422
  * - `voice-right-top`: shown in the tabbed top area of the voice right panel.
269
423
  */
270
- export declare const PluginPanelSlotSchema: z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top"]>;
424
+ export declare const PluginPanelSlotSchema: z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top", "cw-right-top"]>;
271
425
  /**
272
426
  * Rendering slot that determines where a panel appears in the UI.
273
427
  */
@@ -301,7 +455,7 @@ export declare const PluginPanelDescriptorSchema: z.ZodObject<{
301
455
  /** Optional string params forwarded to iframe panels as URL/init params. */
302
456
  params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
303
457
  /** Where the panel renders. Defaults to `'operator'` (operator card live-panel area). */
304
- slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top"]>>;
458
+ slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top", "cw-right-top"]>>;
305
459
  /** Preferred width hint. Defaults to `'half'`. */
306
460
  width: z.ZodOptional<z.ZodEnum<["half", "full"]>>;
307
461
  }, "strip", z.ZodTypeAny, {
@@ -310,7 +464,7 @@ export declare const PluginPanelDescriptorSchema: z.ZodObject<{
310
464
  component: "table" | "key-value" | "chart" | "log" | "iframe";
311
465
  params?: Record<string, string> | undefined;
312
466
  pageId?: string | undefined;
313
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
467
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
314
468
  width?: "full" | "half" | undefined;
315
469
  }, {
316
470
  id: string;
@@ -318,7 +472,7 @@ export declare const PluginPanelDescriptorSchema: z.ZodObject<{
318
472
  component: "table" | "key-value" | "chart" | "log" | "iframe";
319
473
  params?: Record<string, string> | undefined;
320
474
  pageId?: string | undefined;
321
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
475
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
322
476
  width?: "full" | "half" | undefined;
323
477
  }>;
324
478
  /**
@@ -379,7 +533,7 @@ export declare const PluginUIPanelContributionGroupSchema: z.ZodObject<{
379
533
  /** Optional string params forwarded to iframe panels as URL/init params. */
380
534
  params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
381
535
  /** Where the panel renders. Defaults to `'operator'` (operator card live-panel area). */
382
- slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top"]>>;
536
+ slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top", "cw-right-top"]>>;
383
537
  /** Preferred width hint. Defaults to `'half'`. */
384
538
  width: z.ZodOptional<z.ZodEnum<["half", "full"]>>;
385
539
  }, "strip", z.ZodTypeAny, {
@@ -388,7 +542,7 @@ export declare const PluginUIPanelContributionGroupSchema: z.ZodObject<{
388
542
  component: "table" | "key-value" | "chart" | "log" | "iframe";
389
543
  params?: Record<string, string> | undefined;
390
544
  pageId?: string | undefined;
391
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
545
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
392
546
  width?: "full" | "half" | undefined;
393
547
  }, {
394
548
  id: string;
@@ -396,7 +550,7 @@ export declare const PluginUIPanelContributionGroupSchema: z.ZodObject<{
396
550
  component: "table" | "key-value" | "chart" | "log" | "iframe";
397
551
  params?: Record<string, string> | undefined;
398
552
  pageId?: string | undefined;
399
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
553
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
400
554
  width?: "full" | "half" | undefined;
401
555
  }>, "many">;
402
556
  }, "strip", z.ZodTypeAny, {
@@ -409,7 +563,7 @@ export declare const PluginUIPanelContributionGroupSchema: z.ZodObject<{
409
563
  component: "table" | "key-value" | "chart" | "log" | "iframe";
410
564
  params?: Record<string, string> | undefined;
411
565
  pageId?: string | undefined;
412
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
566
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
413
567
  width?: "full" | "half" | undefined;
414
568
  }[];
415
569
  instanceTarget?: {
@@ -428,7 +582,7 @@ export declare const PluginUIPanelContributionGroupSchema: z.ZodObject<{
428
582
  component: "table" | "key-value" | "chart" | "log" | "iframe";
429
583
  params?: Record<string, string> | undefined;
430
584
  pageId?: string | undefined;
431
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
585
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
432
586
  width?: "full" | "half" | undefined;
433
587
  }[];
434
588
  instanceTarget?: {
@@ -575,7 +729,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
575
729
  description: z.ZodOptional<z.ZodString>;
576
730
  permissions: z.ZodOptional<z.ZodArray<z.ZodEnum<["network", "radio:read", "radio:control", "radio:power", "settings:ft8", "settings:decode-windows", "settings:realtime", "settings:frequency-presets", "settings:station", "settings:psk-reporter", "settings:ntp"]>, "many">>;
577
731
  settings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
578
- type: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "info"]>;
732
+ type: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "keyedStringArrays", "info"]>;
579
733
  default: z.ZodUnknown;
580
734
  label: z.ZodString;
581
735
  description: z.ZodOptional<z.ZodString>;
@@ -614,14 +768,78 @@ export declare const PluginManifestSchema: z.ZodObject<{
614
768
  placeholder?: string | undefined;
615
769
  required?: boolean | undefined;
616
770
  }>, "many">>;
771
+ /** Fixed key list used by generated editors for `keyedStringArrays` settings. */
772
+ keys: z.ZodOptional<z.ZodArray<z.ZodObject<{
773
+ key: z.ZodString;
774
+ label: z.ZodString;
775
+ description: z.ZodOptional<z.ZodString>;
776
+ }, "strip", z.ZodTypeAny, {
777
+ label: string;
778
+ key: string;
779
+ description?: string | undefined;
780
+ }, {
781
+ label: string;
782
+ key: string;
783
+ description?: string | undefined;
784
+ }>, "many">>;
785
+ /** Conditionally show the field based on another setting in the same form. */
786
+ visibleWhen: z.ZodOptional<z.ZodObject<{
787
+ setting: z.ZodString;
788
+ equals: z.ZodOptional<z.ZodUnknown>;
789
+ notEquals: z.ZodOptional<z.ZodUnknown>;
790
+ }, "strip", z.ZodTypeAny, {
791
+ setting: string;
792
+ equals?: unknown;
793
+ notEquals?: unknown;
794
+ }, {
795
+ setting: string;
796
+ equals?: unknown;
797
+ notEquals?: unknown;
798
+ }>>;
799
+ /** Conditionally override the field description based on another setting. */
800
+ descriptionWhen: z.ZodOptional<z.ZodArray<z.ZodObject<{
801
+ when: z.ZodObject<{
802
+ setting: z.ZodString;
803
+ equals: z.ZodOptional<z.ZodUnknown>;
804
+ notEquals: z.ZodOptional<z.ZodUnknown>;
805
+ }, "strip", z.ZodTypeAny, {
806
+ setting: string;
807
+ equals?: unknown;
808
+ notEquals?: unknown;
809
+ }, {
810
+ setting: string;
811
+ equals?: unknown;
812
+ notEquals?: unknown;
813
+ }>;
814
+ description: z.ZodString;
815
+ }, "strip", z.ZodTypeAny, {
816
+ description: string;
817
+ when: {
818
+ setting: string;
819
+ equals?: unknown;
820
+ notEquals?: unknown;
821
+ };
822
+ }, {
823
+ description: string;
824
+ when: {
825
+ setting: string;
826
+ equals?: unknown;
827
+ notEquals?: unknown;
828
+ };
829
+ }>, "many">>;
617
830
  /** Internal settings are persisted/injected but hidden from generated UIs. */
618
831
  hidden: z.ZodOptional<z.ZodBoolean>;
619
832
  /** 设置作用域:global(所有操作员共享)或 operator(每操作员独立),默认 global */
620
833
  scope: z.ZodDefault<z.ZodOptional<z.ZodEnum<["global", "operator"]>>>;
621
834
  }, "strip", z.ZodTypeAny, {
622
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
835
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
623
836
  label: string;
624
837
  scope: "operator" | "global";
838
+ keys?: {
839
+ label: string;
840
+ key: string;
841
+ description?: string | undefined;
842
+ }[] | undefined;
625
843
  options?: {
626
844
  value: string;
627
845
  label: string;
@@ -638,10 +856,28 @@ export declare const PluginManifestSchema: z.ZodObject<{
638
856
  placeholder?: string | undefined;
639
857
  required?: boolean | undefined;
640
858
  }[] | undefined;
859
+ visibleWhen?: {
860
+ setting: string;
861
+ equals?: unknown;
862
+ notEquals?: unknown;
863
+ } | undefined;
864
+ descriptionWhen?: {
865
+ description: string;
866
+ when: {
867
+ setting: string;
868
+ equals?: unknown;
869
+ notEquals?: unknown;
870
+ };
871
+ }[] | undefined;
641
872
  hidden?: boolean | undefined;
642
873
  }, {
643
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
874
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
644
875
  label: string;
876
+ keys?: {
877
+ label: string;
878
+ key: string;
879
+ description?: string | undefined;
880
+ }[] | undefined;
645
881
  options?: {
646
882
  value: string;
647
883
  label: string;
@@ -658,6 +894,19 @@ export declare const PluginManifestSchema: z.ZodObject<{
658
894
  placeholder?: string | undefined;
659
895
  required?: boolean | undefined;
660
896
  }[] | undefined;
897
+ visibleWhen?: {
898
+ setting: string;
899
+ equals?: unknown;
900
+ notEquals?: unknown;
901
+ } | undefined;
902
+ descriptionWhen?: {
903
+ description: string;
904
+ when: {
905
+ setting: string;
906
+ equals?: unknown;
907
+ notEquals?: unknown;
908
+ };
909
+ }[] | undefined;
661
910
  hidden?: boolean | undefined;
662
911
  scope?: "operator" | "global" | undefined;
663
912
  }>>>;
@@ -690,7 +939,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
690
939
  /** Optional string params forwarded to iframe panels as URL/init params. */
691
940
  params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
692
941
  /** Where the panel renders. Defaults to `'operator'` (operator card live-panel area). */
693
- slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top"]>>;
942
+ slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top", "cw-right-top"]>>;
694
943
  /** Preferred width hint. Defaults to `'half'`. */
695
944
  width: z.ZodOptional<z.ZodEnum<["half", "full"]>>;
696
945
  }, "strip", z.ZodTypeAny, {
@@ -699,7 +948,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
699
948
  component: "table" | "key-value" | "chart" | "log" | "iframe";
700
949
  params?: Record<string, string> | undefined;
701
950
  pageId?: string | undefined;
702
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
951
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
703
952
  width?: "full" | "half" | undefined;
704
953
  }, {
705
954
  id: string;
@@ -707,7 +956,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
707
956
  component: "table" | "key-value" | "chart" | "log" | "iframe";
708
957
  params?: Record<string, string> | undefined;
709
958
  pageId?: string | undefined;
710
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
959
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
711
960
  width?: "full" | "half" | undefined;
712
961
  }>, "many">>;
713
962
  storage: z.ZodOptional<z.ZodObject<{
@@ -782,7 +1031,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
782
1031
  component: "table" | "key-value" | "chart" | "log" | "iframe";
783
1032
  params?: Record<string, string> | undefined;
784
1033
  pageId?: string | undefined;
785
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
1034
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
786
1035
  width?: "full" | "half" | undefined;
787
1036
  }[] | undefined;
788
1037
  ui?: {
@@ -798,9 +1047,14 @@ export declare const PluginManifestSchema: z.ZodObject<{
798
1047
  } | undefined;
799
1048
  permissions?: ("network" | "radio:read" | "radio:control" | "radio:power" | "settings:ft8" | "settings:decode-windows" | "settings:realtime" | "settings:frequency-presets" | "settings:station" | "settings:psk-reporter" | "settings:ntp")[] | undefined;
800
1049
  settings?: Record<string, {
801
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
1050
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
802
1051
  label: string;
803
1052
  scope: "operator" | "global";
1053
+ keys?: {
1054
+ label: string;
1055
+ key: string;
1056
+ description?: string | undefined;
1057
+ }[] | undefined;
804
1058
  options?: {
805
1059
  value: string;
806
1060
  label: string;
@@ -817,6 +1071,19 @@ export declare const PluginManifestSchema: z.ZodObject<{
817
1071
  placeholder?: string | undefined;
818
1072
  required?: boolean | undefined;
819
1073
  }[] | undefined;
1074
+ visibleWhen?: {
1075
+ setting: string;
1076
+ equals?: unknown;
1077
+ notEquals?: unknown;
1078
+ } | undefined;
1079
+ descriptionWhen?: {
1080
+ description: string;
1081
+ when: {
1082
+ setting: string;
1083
+ equals?: unknown;
1084
+ notEquals?: unknown;
1085
+ };
1086
+ }[] | undefined;
820
1087
  hidden?: boolean | undefined;
821
1088
  }> | undefined;
822
1089
  quickActions?: {
@@ -841,7 +1108,7 @@ export declare const PluginManifestSchema: z.ZodObject<{
841
1108
  component: "table" | "key-value" | "chart" | "log" | "iframe";
842
1109
  params?: Record<string, string> | undefined;
843
1110
  pageId?: string | undefined;
844
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
1111
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
845
1112
  width?: "full" | "half" | undefined;
846
1113
  }[] | undefined;
847
1114
  ui?: {
@@ -858,8 +1125,13 @@ export declare const PluginManifestSchema: z.ZodObject<{
858
1125
  instanceScope?: "operator" | "global" | undefined;
859
1126
  permissions?: ("network" | "radio:read" | "radio:control" | "radio:power" | "settings:ft8" | "settings:decode-windows" | "settings:realtime" | "settings:frequency-presets" | "settings:station" | "settings:psk-reporter" | "settings:ntp")[] | undefined;
860
1127
  settings?: Record<string, {
861
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
1128
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
862
1129
  label: string;
1130
+ keys?: {
1131
+ label: string;
1132
+ key: string;
1133
+ description?: string | undefined;
1134
+ }[] | undefined;
863
1135
  options?: {
864
1136
  value: string;
865
1137
  label: string;
@@ -876,6 +1148,19 @@ export declare const PluginManifestSchema: z.ZodObject<{
876
1148
  placeholder?: string | undefined;
877
1149
  required?: boolean | undefined;
878
1150
  }[] | undefined;
1151
+ visibleWhen?: {
1152
+ setting: string;
1153
+ equals?: unknown;
1154
+ notEquals?: unknown;
1155
+ } | undefined;
1156
+ descriptionWhen?: {
1157
+ description: string;
1158
+ when: {
1159
+ setting: string;
1160
+ equals?: unknown;
1161
+ notEquals?: unknown;
1162
+ };
1163
+ }[] | undefined;
879
1164
  hidden?: boolean | undefined;
880
1165
  scope?: "operator" | "global" | undefined;
881
1166
  }> | undefined;
@@ -944,7 +1229,7 @@ export declare const PluginStatusSchema: z.ZodObject<{
944
1229
  /** 仅对 strategy 插件有意义:当前被哪些 operator 选中 */
945
1230
  assignedOperatorIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
946
1231
  settings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
947
- type: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "info"]>;
1232
+ type: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "keyedStringArrays", "info"]>;
948
1233
  default: z.ZodUnknown;
949
1234
  label: z.ZodString;
950
1235
  description: z.ZodOptional<z.ZodString>;
@@ -983,14 +1268,78 @@ export declare const PluginStatusSchema: z.ZodObject<{
983
1268
  placeholder?: string | undefined;
984
1269
  required?: boolean | undefined;
985
1270
  }>, "many">>;
1271
+ /** Fixed key list used by generated editors for `keyedStringArrays` settings. */
1272
+ keys: z.ZodOptional<z.ZodArray<z.ZodObject<{
1273
+ key: z.ZodString;
1274
+ label: z.ZodString;
1275
+ description: z.ZodOptional<z.ZodString>;
1276
+ }, "strip", z.ZodTypeAny, {
1277
+ label: string;
1278
+ key: string;
1279
+ description?: string | undefined;
1280
+ }, {
1281
+ label: string;
1282
+ key: string;
1283
+ description?: string | undefined;
1284
+ }>, "many">>;
1285
+ /** Conditionally show the field based on another setting in the same form. */
1286
+ visibleWhen: z.ZodOptional<z.ZodObject<{
1287
+ setting: z.ZodString;
1288
+ equals: z.ZodOptional<z.ZodUnknown>;
1289
+ notEquals: z.ZodOptional<z.ZodUnknown>;
1290
+ }, "strip", z.ZodTypeAny, {
1291
+ setting: string;
1292
+ equals?: unknown;
1293
+ notEquals?: unknown;
1294
+ }, {
1295
+ setting: string;
1296
+ equals?: unknown;
1297
+ notEquals?: unknown;
1298
+ }>>;
1299
+ /** Conditionally override the field description based on another setting. */
1300
+ descriptionWhen: z.ZodOptional<z.ZodArray<z.ZodObject<{
1301
+ when: z.ZodObject<{
1302
+ setting: z.ZodString;
1303
+ equals: z.ZodOptional<z.ZodUnknown>;
1304
+ notEquals: z.ZodOptional<z.ZodUnknown>;
1305
+ }, "strip", z.ZodTypeAny, {
1306
+ setting: string;
1307
+ equals?: unknown;
1308
+ notEquals?: unknown;
1309
+ }, {
1310
+ setting: string;
1311
+ equals?: unknown;
1312
+ notEquals?: unknown;
1313
+ }>;
1314
+ description: z.ZodString;
1315
+ }, "strip", z.ZodTypeAny, {
1316
+ description: string;
1317
+ when: {
1318
+ setting: string;
1319
+ equals?: unknown;
1320
+ notEquals?: unknown;
1321
+ };
1322
+ }, {
1323
+ description: string;
1324
+ when: {
1325
+ setting: string;
1326
+ equals?: unknown;
1327
+ notEquals?: unknown;
1328
+ };
1329
+ }>, "many">>;
986
1330
  /** Internal settings are persisted/injected but hidden from generated UIs. */
987
1331
  hidden: z.ZodOptional<z.ZodBoolean>;
988
1332
  /** 设置作用域:global(所有操作员共享)或 operator(每操作员独立),默认 global */
989
1333
  scope: z.ZodDefault<z.ZodOptional<z.ZodEnum<["global", "operator"]>>>;
990
1334
  }, "strip", z.ZodTypeAny, {
991
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
1335
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
992
1336
  label: string;
993
1337
  scope: "operator" | "global";
1338
+ keys?: {
1339
+ label: string;
1340
+ key: string;
1341
+ description?: string | undefined;
1342
+ }[] | undefined;
994
1343
  options?: {
995
1344
  value: string;
996
1345
  label: string;
@@ -1007,10 +1356,28 @@ export declare const PluginStatusSchema: z.ZodObject<{
1007
1356
  placeholder?: string | undefined;
1008
1357
  required?: boolean | undefined;
1009
1358
  }[] | undefined;
1359
+ visibleWhen?: {
1360
+ setting: string;
1361
+ equals?: unknown;
1362
+ notEquals?: unknown;
1363
+ } | undefined;
1364
+ descriptionWhen?: {
1365
+ description: string;
1366
+ when: {
1367
+ setting: string;
1368
+ equals?: unknown;
1369
+ notEquals?: unknown;
1370
+ };
1371
+ }[] | undefined;
1010
1372
  hidden?: boolean | undefined;
1011
1373
  }, {
1012
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
1374
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
1013
1375
  label: string;
1376
+ keys?: {
1377
+ label: string;
1378
+ key: string;
1379
+ description?: string | undefined;
1380
+ }[] | undefined;
1014
1381
  options?: {
1015
1382
  value: string;
1016
1383
  label: string;
@@ -1027,6 +1394,19 @@ export declare const PluginStatusSchema: z.ZodObject<{
1027
1394
  placeholder?: string | undefined;
1028
1395
  required?: boolean | undefined;
1029
1396
  }[] | undefined;
1397
+ visibleWhen?: {
1398
+ setting: string;
1399
+ equals?: unknown;
1400
+ notEquals?: unknown;
1401
+ } | undefined;
1402
+ descriptionWhen?: {
1403
+ description: string;
1404
+ when: {
1405
+ setting: string;
1406
+ equals?: unknown;
1407
+ notEquals?: unknown;
1408
+ };
1409
+ }[] | undefined;
1030
1410
  hidden?: boolean | undefined;
1031
1411
  scope?: "operator" | "global" | undefined;
1032
1412
  }>>>;
@@ -1059,7 +1439,7 @@ export declare const PluginStatusSchema: z.ZodObject<{
1059
1439
  /** Optional string params forwarded to iframe panels as URL/init params. */
1060
1440
  params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1061
1441
  /** Where the panel renders. Defaults to `'operator'` (operator card live-panel area). */
1062
- slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top"]>>;
1442
+ slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top", "cw-right-top"]>>;
1063
1443
  /** Preferred width hint. Defaults to `'half'`. */
1064
1444
  width: z.ZodOptional<z.ZodEnum<["half", "full"]>>;
1065
1445
  }, "strip", z.ZodTypeAny, {
@@ -1068,7 +1448,7 @@ export declare const PluginStatusSchema: z.ZodObject<{
1068
1448
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1069
1449
  params?: Record<string, string> | undefined;
1070
1450
  pageId?: string | undefined;
1071
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
1451
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1072
1452
  width?: "full" | "half" | undefined;
1073
1453
  }, {
1074
1454
  id: string;
@@ -1076,7 +1456,7 @@ export declare const PluginStatusSchema: z.ZodObject<{
1076
1456
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1077
1457
  params?: Record<string, string> | undefined;
1078
1458
  pageId?: string | undefined;
1079
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
1459
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1080
1460
  width?: "full" | "half" | undefined;
1081
1461
  }>, "many">>;
1082
1462
  permissions: z.ZodOptional<z.ZodArray<z.ZodEnum<["network", "radio:read", "radio:control", "radio:power", "settings:ft8", "settings:decode-windows", "settings:realtime", "settings:frequency-presets", "settings:station", "settings:psk-reporter", "settings:ntp"]>, "many">>;
@@ -1182,7 +1562,7 @@ export declare const PluginStatusSchema: z.ZodObject<{
1182
1562
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1183
1563
  params?: Record<string, string> | undefined;
1184
1564
  pageId?: string | undefined;
1185
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
1565
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1186
1566
  width?: "full" | "half" | undefined;
1187
1567
  }[] | undefined;
1188
1568
  ui?: {
@@ -1198,9 +1578,14 @@ export declare const PluginStatusSchema: z.ZodObject<{
1198
1578
  } | undefined;
1199
1579
  permissions?: ("network" | "radio:read" | "radio:control" | "radio:power" | "settings:ft8" | "settings:decode-windows" | "settings:realtime" | "settings:frequency-presets" | "settings:station" | "settings:psk-reporter" | "settings:ntp")[] | undefined;
1200
1580
  settings?: Record<string, {
1201
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
1581
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
1202
1582
  label: string;
1203
1583
  scope: "operator" | "global";
1584
+ keys?: {
1585
+ label: string;
1586
+ key: string;
1587
+ description?: string | undefined;
1588
+ }[] | undefined;
1204
1589
  options?: {
1205
1590
  value: string;
1206
1591
  label: string;
@@ -1217,6 +1602,19 @@ export declare const PluginStatusSchema: z.ZodObject<{
1217
1602
  placeholder?: string | undefined;
1218
1603
  required?: boolean | undefined;
1219
1604
  }[] | undefined;
1605
+ visibleWhen?: {
1606
+ setting: string;
1607
+ equals?: unknown;
1608
+ notEquals?: unknown;
1609
+ } | undefined;
1610
+ descriptionWhen?: {
1611
+ description: string;
1612
+ when: {
1613
+ setting: string;
1614
+ equals?: unknown;
1615
+ notEquals?: unknown;
1616
+ };
1617
+ }[] | undefined;
1220
1618
  hidden?: boolean | undefined;
1221
1619
  }> | undefined;
1222
1620
  quickActions?: {
@@ -1253,7 +1651,7 @@ export declare const PluginStatusSchema: z.ZodObject<{
1253
1651
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1254
1652
  params?: Record<string, string> | undefined;
1255
1653
  pageId?: string | undefined;
1256
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
1654
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1257
1655
  width?: "full" | "half" | undefined;
1258
1656
  }[] | undefined;
1259
1657
  ui?: {
@@ -1270,8 +1668,13 @@ export declare const PluginStatusSchema: z.ZodObject<{
1270
1668
  instanceScope?: "operator" | "global" | undefined;
1271
1669
  permissions?: ("network" | "radio:read" | "radio:control" | "radio:power" | "settings:ft8" | "settings:decode-windows" | "settings:realtime" | "settings:frequency-presets" | "settings:station" | "settings:psk-reporter" | "settings:ntp")[] | undefined;
1272
1670
  settings?: Record<string, {
1273
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
1671
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
1274
1672
  label: string;
1673
+ keys?: {
1674
+ label: string;
1675
+ key: string;
1676
+ description?: string | undefined;
1677
+ }[] | undefined;
1275
1678
  options?: {
1276
1679
  value: string;
1277
1680
  label: string;
@@ -1288,6 +1691,19 @@ export declare const PluginStatusSchema: z.ZodObject<{
1288
1691
  placeholder?: string | undefined;
1289
1692
  required?: boolean | undefined;
1290
1693
  }[] | undefined;
1694
+ visibleWhen?: {
1695
+ setting: string;
1696
+ equals?: unknown;
1697
+ notEquals?: unknown;
1698
+ } | undefined;
1699
+ descriptionWhen?: {
1700
+ description: string;
1701
+ when: {
1702
+ setting: string;
1703
+ equals?: unknown;
1704
+ notEquals?: unknown;
1705
+ };
1706
+ }[] | undefined;
1291
1707
  hidden?: boolean | undefined;
1292
1708
  scope?: "operator" | "global" | undefined;
1293
1709
  }> | undefined;
@@ -1388,7 +1804,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1388
1804
  /** 仅对 strategy 插件有意义:当前被哪些 operator 选中 */
1389
1805
  assignedOperatorIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1390
1806
  settings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
1391
- type: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "info"]>;
1807
+ type: z.ZodEnum<["boolean", "number", "string", "string[]", "object[]", "keyedStringArrays", "info"]>;
1392
1808
  default: z.ZodUnknown;
1393
1809
  label: z.ZodString;
1394
1810
  description: z.ZodOptional<z.ZodString>;
@@ -1427,14 +1843,78 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1427
1843
  placeholder?: string | undefined;
1428
1844
  required?: boolean | undefined;
1429
1845
  }>, "many">>;
1846
+ /** Fixed key list used by generated editors for `keyedStringArrays` settings. */
1847
+ keys: z.ZodOptional<z.ZodArray<z.ZodObject<{
1848
+ key: z.ZodString;
1849
+ label: z.ZodString;
1850
+ description: z.ZodOptional<z.ZodString>;
1851
+ }, "strip", z.ZodTypeAny, {
1852
+ label: string;
1853
+ key: string;
1854
+ description?: string | undefined;
1855
+ }, {
1856
+ label: string;
1857
+ key: string;
1858
+ description?: string | undefined;
1859
+ }>, "many">>;
1860
+ /** Conditionally show the field based on another setting in the same form. */
1861
+ visibleWhen: z.ZodOptional<z.ZodObject<{
1862
+ setting: z.ZodString;
1863
+ equals: z.ZodOptional<z.ZodUnknown>;
1864
+ notEquals: z.ZodOptional<z.ZodUnknown>;
1865
+ }, "strip", z.ZodTypeAny, {
1866
+ setting: string;
1867
+ equals?: unknown;
1868
+ notEquals?: unknown;
1869
+ }, {
1870
+ setting: string;
1871
+ equals?: unknown;
1872
+ notEquals?: unknown;
1873
+ }>>;
1874
+ /** Conditionally override the field description based on another setting. */
1875
+ descriptionWhen: z.ZodOptional<z.ZodArray<z.ZodObject<{
1876
+ when: z.ZodObject<{
1877
+ setting: z.ZodString;
1878
+ equals: z.ZodOptional<z.ZodUnknown>;
1879
+ notEquals: z.ZodOptional<z.ZodUnknown>;
1880
+ }, "strip", z.ZodTypeAny, {
1881
+ setting: string;
1882
+ equals?: unknown;
1883
+ notEquals?: unknown;
1884
+ }, {
1885
+ setting: string;
1886
+ equals?: unknown;
1887
+ notEquals?: unknown;
1888
+ }>;
1889
+ description: z.ZodString;
1890
+ }, "strip", z.ZodTypeAny, {
1891
+ description: string;
1892
+ when: {
1893
+ setting: string;
1894
+ equals?: unknown;
1895
+ notEquals?: unknown;
1896
+ };
1897
+ }, {
1898
+ description: string;
1899
+ when: {
1900
+ setting: string;
1901
+ equals?: unknown;
1902
+ notEquals?: unknown;
1903
+ };
1904
+ }>, "many">>;
1430
1905
  /** Internal settings are persisted/injected but hidden from generated UIs. */
1431
1906
  hidden: z.ZodOptional<z.ZodBoolean>;
1432
1907
  /** 设置作用域:global(所有操作员共享)或 operator(每操作员独立),默认 global */
1433
1908
  scope: z.ZodDefault<z.ZodOptional<z.ZodEnum<["global", "operator"]>>>;
1434
1909
  }, "strip", z.ZodTypeAny, {
1435
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
1910
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
1436
1911
  label: string;
1437
1912
  scope: "operator" | "global";
1913
+ keys?: {
1914
+ label: string;
1915
+ key: string;
1916
+ description?: string | undefined;
1917
+ }[] | undefined;
1438
1918
  options?: {
1439
1919
  value: string;
1440
1920
  label: string;
@@ -1451,10 +1931,28 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1451
1931
  placeholder?: string | undefined;
1452
1932
  required?: boolean | undefined;
1453
1933
  }[] | undefined;
1934
+ visibleWhen?: {
1935
+ setting: string;
1936
+ equals?: unknown;
1937
+ notEquals?: unknown;
1938
+ } | undefined;
1939
+ descriptionWhen?: {
1940
+ description: string;
1941
+ when: {
1942
+ setting: string;
1943
+ equals?: unknown;
1944
+ notEquals?: unknown;
1945
+ };
1946
+ }[] | undefined;
1454
1947
  hidden?: boolean | undefined;
1455
1948
  }, {
1456
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
1949
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
1457
1950
  label: string;
1951
+ keys?: {
1952
+ label: string;
1953
+ key: string;
1954
+ description?: string | undefined;
1955
+ }[] | undefined;
1458
1956
  options?: {
1459
1957
  value: string;
1460
1958
  label: string;
@@ -1471,6 +1969,19 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1471
1969
  placeholder?: string | undefined;
1472
1970
  required?: boolean | undefined;
1473
1971
  }[] | undefined;
1972
+ visibleWhen?: {
1973
+ setting: string;
1974
+ equals?: unknown;
1975
+ notEquals?: unknown;
1976
+ } | undefined;
1977
+ descriptionWhen?: {
1978
+ description: string;
1979
+ when: {
1980
+ setting: string;
1981
+ equals?: unknown;
1982
+ notEquals?: unknown;
1983
+ };
1984
+ }[] | undefined;
1474
1985
  hidden?: boolean | undefined;
1475
1986
  scope?: "operator" | "global" | undefined;
1476
1987
  }>>>;
@@ -1503,7 +2014,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1503
2014
  /** Optional string params forwarded to iframe panels as URL/init params. */
1504
2015
  params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1505
2016
  /** Where the panel renders. Defaults to `'operator'` (operator card live-panel area). */
1506
- slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top"]>>;
2017
+ slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top", "cw-right-top"]>>;
1507
2018
  /** Preferred width hint. Defaults to `'half'`. */
1508
2019
  width: z.ZodOptional<z.ZodEnum<["half", "full"]>>;
1509
2020
  }, "strip", z.ZodTypeAny, {
@@ -1512,7 +2023,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1512
2023
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1513
2024
  params?: Record<string, string> | undefined;
1514
2025
  pageId?: string | undefined;
1515
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2026
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1516
2027
  width?: "full" | "half" | undefined;
1517
2028
  }, {
1518
2029
  id: string;
@@ -1520,7 +2031,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1520
2031
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1521
2032
  params?: Record<string, string> | undefined;
1522
2033
  pageId?: string | undefined;
1523
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2034
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1524
2035
  width?: "full" | "half" | undefined;
1525
2036
  }>, "many">>;
1526
2037
  permissions: z.ZodOptional<z.ZodArray<z.ZodEnum<["network", "radio:read", "radio:control", "radio:power", "settings:ft8", "settings:decode-windows", "settings:realtime", "settings:frequency-presets", "settings:station", "settings:psk-reporter", "settings:ntp"]>, "many">>;
@@ -1626,7 +2137,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1626
2137
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1627
2138
  params?: Record<string, string> | undefined;
1628
2139
  pageId?: string | undefined;
1629
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2140
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1630
2141
  width?: "full" | "half" | undefined;
1631
2142
  }[] | undefined;
1632
2143
  ui?: {
@@ -1642,9 +2153,14 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1642
2153
  } | undefined;
1643
2154
  permissions?: ("network" | "radio:read" | "radio:control" | "radio:power" | "settings:ft8" | "settings:decode-windows" | "settings:realtime" | "settings:frequency-presets" | "settings:station" | "settings:psk-reporter" | "settings:ntp")[] | undefined;
1644
2155
  settings?: Record<string, {
1645
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
2156
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
1646
2157
  label: string;
1647
2158
  scope: "operator" | "global";
2159
+ keys?: {
2160
+ label: string;
2161
+ key: string;
2162
+ description?: string | undefined;
2163
+ }[] | undefined;
1648
2164
  options?: {
1649
2165
  value: string;
1650
2166
  label: string;
@@ -1661,6 +2177,19 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1661
2177
  placeholder?: string | undefined;
1662
2178
  required?: boolean | undefined;
1663
2179
  }[] | undefined;
2180
+ visibleWhen?: {
2181
+ setting: string;
2182
+ equals?: unknown;
2183
+ notEquals?: unknown;
2184
+ } | undefined;
2185
+ descriptionWhen?: {
2186
+ description: string;
2187
+ when: {
2188
+ setting: string;
2189
+ equals?: unknown;
2190
+ notEquals?: unknown;
2191
+ };
2192
+ }[] | undefined;
1664
2193
  hidden?: boolean | undefined;
1665
2194
  }> | undefined;
1666
2195
  quickActions?: {
@@ -1697,7 +2226,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1697
2226
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1698
2227
  params?: Record<string, string> | undefined;
1699
2228
  pageId?: string | undefined;
1700
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2229
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1701
2230
  width?: "full" | "half" | undefined;
1702
2231
  }[] | undefined;
1703
2232
  ui?: {
@@ -1714,8 +2243,13 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1714
2243
  instanceScope?: "operator" | "global" | undefined;
1715
2244
  permissions?: ("network" | "radio:read" | "radio:control" | "radio:power" | "settings:ft8" | "settings:decode-windows" | "settings:realtime" | "settings:frequency-presets" | "settings:station" | "settings:psk-reporter" | "settings:ntp")[] | undefined;
1716
2245
  settings?: Record<string, {
1717
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
2246
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
1718
2247
  label: string;
2248
+ keys?: {
2249
+ label: string;
2250
+ key: string;
2251
+ description?: string | undefined;
2252
+ }[] | undefined;
1719
2253
  options?: {
1720
2254
  value: string;
1721
2255
  label: string;
@@ -1732,6 +2266,19 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1732
2266
  placeholder?: string | undefined;
1733
2267
  required?: boolean | undefined;
1734
2268
  }[] | undefined;
2269
+ visibleWhen?: {
2270
+ setting: string;
2271
+ equals?: unknown;
2272
+ notEquals?: unknown;
2273
+ } | undefined;
2274
+ descriptionWhen?: {
2275
+ description: string;
2276
+ when: {
2277
+ setting: string;
2278
+ equals?: unknown;
2279
+ notEquals?: unknown;
2280
+ };
2281
+ }[] | undefined;
1735
2282
  hidden?: boolean | undefined;
1736
2283
  scope?: "operator" | "global" | undefined;
1737
2284
  }> | undefined;
@@ -1815,7 +2362,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1815
2362
  /** Optional string params forwarded to iframe panels as URL/init params. */
1816
2363
  params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1817
2364
  /** Where the panel renders. Defaults to `'operator'` (operator card live-panel area). */
1818
- slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top"]>>;
2365
+ slot: z.ZodOptional<z.ZodEnum<["operator", "automation", "main-right", "voice-left-top", "voice-right-top", "cw-right-top"]>>;
1819
2366
  /** Preferred width hint. Defaults to `'half'`. */
1820
2367
  width: z.ZodOptional<z.ZodEnum<["half", "full"]>>;
1821
2368
  }, "strip", z.ZodTypeAny, {
@@ -1824,7 +2371,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1824
2371
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1825
2372
  params?: Record<string, string> | undefined;
1826
2373
  pageId?: string | undefined;
1827
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2374
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1828
2375
  width?: "full" | "half" | undefined;
1829
2376
  }, {
1830
2377
  id: string;
@@ -1832,7 +2379,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1832
2379
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1833
2380
  params?: Record<string, string> | undefined;
1834
2381
  pageId?: string | undefined;
1835
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2382
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1836
2383
  width?: "full" | "half" | undefined;
1837
2384
  }>, "many">;
1838
2385
  }, "strip", z.ZodTypeAny, {
@@ -1845,7 +2392,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1845
2392
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1846
2393
  params?: Record<string, string> | undefined;
1847
2394
  pageId?: string | undefined;
1848
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2395
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1849
2396
  width?: "full" | "half" | undefined;
1850
2397
  }[];
1851
2398
  instanceTarget?: {
@@ -1864,7 +2411,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1864
2411
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1865
2412
  params?: Record<string, string> | undefined;
1866
2413
  pageId?: string | undefined;
1867
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2414
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1868
2415
  width?: "full" | "half" | undefined;
1869
2416
  }[];
1870
2417
  instanceTarget?: {
@@ -1903,7 +2450,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1903
2450
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1904
2451
  params?: Record<string, string> | undefined;
1905
2452
  pageId?: string | undefined;
1906
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2453
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1907
2454
  width?: "full" | "half" | undefined;
1908
2455
  }[] | undefined;
1909
2456
  ui?: {
@@ -1919,9 +2466,14 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1919
2466
  } | undefined;
1920
2467
  permissions?: ("network" | "radio:read" | "radio:control" | "radio:power" | "settings:ft8" | "settings:decode-windows" | "settings:realtime" | "settings:frequency-presets" | "settings:station" | "settings:psk-reporter" | "settings:ntp")[] | undefined;
1921
2468
  settings?: Record<string, {
1922
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
2469
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
1923
2470
  label: string;
1924
2471
  scope: "operator" | "global";
2472
+ keys?: {
2473
+ label: string;
2474
+ key: string;
2475
+ description?: string | undefined;
2476
+ }[] | undefined;
1925
2477
  options?: {
1926
2478
  value: string;
1927
2479
  label: string;
@@ -1938,6 +2490,19 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1938
2490
  placeholder?: string | undefined;
1939
2491
  required?: boolean | undefined;
1940
2492
  }[] | undefined;
2493
+ visibleWhen?: {
2494
+ setting: string;
2495
+ equals?: unknown;
2496
+ notEquals?: unknown;
2497
+ } | undefined;
2498
+ descriptionWhen?: {
2499
+ description: string;
2500
+ when: {
2501
+ setting: string;
2502
+ equals?: unknown;
2503
+ notEquals?: unknown;
2504
+ };
2505
+ }[] | undefined;
1941
2506
  hidden?: boolean | undefined;
1942
2507
  }> | undefined;
1943
2508
  quickActions?: {
@@ -1973,7 +2538,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
1973
2538
  component: "table" | "key-value" | "chart" | "log" | "iframe";
1974
2539
  params?: Record<string, string> | undefined;
1975
2540
  pageId?: string | undefined;
1976
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2541
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
1977
2542
  width?: "full" | "half" | undefined;
1978
2543
  }[];
1979
2544
  instanceTarget?: {
@@ -2009,7 +2574,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
2009
2574
  component: "table" | "key-value" | "chart" | "log" | "iframe";
2010
2575
  params?: Record<string, string> | undefined;
2011
2576
  pageId?: string | undefined;
2012
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2577
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
2013
2578
  width?: "full" | "half" | undefined;
2014
2579
  }[] | undefined;
2015
2580
  ui?: {
@@ -2026,8 +2591,13 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
2026
2591
  instanceScope?: "operator" | "global" | undefined;
2027
2592
  permissions?: ("network" | "radio:read" | "radio:control" | "radio:power" | "settings:ft8" | "settings:decode-windows" | "settings:realtime" | "settings:frequency-presets" | "settings:station" | "settings:psk-reporter" | "settings:ntp")[] | undefined;
2028
2593
  settings?: Record<string, {
2029
- type: "string" | "number" | "boolean" | "string[]" | "object[]" | "info";
2594
+ type: "string" | "number" | "boolean" | "string[]" | "object[]" | "keyedStringArrays" | "info";
2030
2595
  label: string;
2596
+ keys?: {
2597
+ label: string;
2598
+ key: string;
2599
+ description?: string | undefined;
2600
+ }[] | undefined;
2031
2601
  options?: {
2032
2602
  value: string;
2033
2603
  label: string;
@@ -2044,6 +2614,19 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
2044
2614
  placeholder?: string | undefined;
2045
2615
  required?: boolean | undefined;
2046
2616
  }[] | undefined;
2617
+ visibleWhen?: {
2618
+ setting: string;
2619
+ equals?: unknown;
2620
+ notEquals?: unknown;
2621
+ } | undefined;
2622
+ descriptionWhen?: {
2623
+ description: string;
2624
+ when: {
2625
+ setting: string;
2626
+ equals?: unknown;
2627
+ notEquals?: unknown;
2628
+ };
2629
+ }[] | undefined;
2047
2630
  hidden?: boolean | undefined;
2048
2631
  scope?: "operator" | "global" | undefined;
2049
2632
  }> | undefined;
@@ -2083,7 +2666,7 @@ export declare const PluginSystemSnapshotSchema: z.ZodObject<{
2083
2666
  component: "table" | "key-value" | "chart" | "log" | "iframe";
2084
2667
  params?: Record<string, string> | undefined;
2085
2668
  pageId?: string | undefined;
2086
- slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | undefined;
2669
+ slot?: "operator" | "automation" | "main-right" | "voice-left-top" | "voice-right-top" | "cw-right-top" | undefined;
2087
2670
  width?: "full" | "half" | undefined;
2088
2671
  }[];
2089
2672
  instanceTarget?: {