@vicinae/api 0.3.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.
Files changed (113) hide show
  1. package/README.md +37 -0
  2. package/bin/run.js +9 -0
  3. package/dist/api/ai.d.ts +110 -0
  4. package/dist/api/ai.js +120 -0
  5. package/dist/api/alert.d.ts +22 -0
  6. package/dist/api/alert.js +61 -0
  7. package/dist/api/bus.d.ts +95 -0
  8. package/dist/api/bus.js +211 -0
  9. package/dist/api/cache.d.ts +117 -0
  10. package/dist/api/cache.js +52 -0
  11. package/dist/api/clipboard.d.ts +34 -0
  12. package/dist/api/clipboard.js +52 -0
  13. package/dist/api/color.d.ts +24 -0
  14. package/dist/api/color.js +24 -0
  15. package/dist/api/components/action-pannel.d.ts +23 -0
  16. package/dist/api/components/action-pannel.js +30 -0
  17. package/dist/api/components/actions.d.ts +52 -0
  18. package/dist/api/components/actions.js +81 -0
  19. package/dist/api/components/detail.d.ts +21 -0
  20. package/dist/api/components/detail.js +12 -0
  21. package/dist/api/components/dropdown.d.ts +36 -0
  22. package/dist/api/components/dropdown.js +21 -0
  23. package/dist/api/components/empty-view.d.ts +9 -0
  24. package/dist/api/components/empty-view.js +12 -0
  25. package/dist/api/components/form.d.ts +81 -0
  26. package/dist/api/components/form.js +53 -0
  27. package/dist/api/components/grid.d.ts +117 -0
  28. package/dist/api/components/grid.js +80 -0
  29. package/dist/api/components/index.d.ts +7 -0
  30. package/dist/api/components/index.js +23 -0
  31. package/dist/api/components/list.d.ts +109 -0
  32. package/dist/api/components/list.js +53 -0
  33. package/dist/api/components/menu-bar.d.ts +26 -0
  34. package/dist/api/components/menu-bar.js +25 -0
  35. package/dist/api/components/metadata.d.ts +23 -0
  36. package/dist/api/components/metadata.js +27 -0
  37. package/dist/api/components/tag.d.ts +16 -0
  38. package/dist/api/components/tag.js +28 -0
  39. package/dist/api/context/index.d.ts +1 -0
  40. package/dist/api/context/index.js +17 -0
  41. package/dist/api/context/navigation-context.d.ts +7 -0
  42. package/dist/api/context/navigation-context.js +8 -0
  43. package/dist/api/context/navigation-provider.d.ts +4 -0
  44. package/dist/api/context/navigation-provider.js +40 -0
  45. package/dist/api/controls.d.ts +3 -0
  46. package/dist/api/controls.js +20 -0
  47. package/dist/api/environment.d.ts +118 -0
  48. package/dist/api/environment.js +17 -0
  49. package/dist/api/hooks/index.d.ts +2 -0
  50. package/dist/api/hooks/index.js +18 -0
  51. package/dist/api/hooks/use-applications.d.ts +2 -0
  52. package/dist/api/hooks/use-applications.js +19 -0
  53. package/dist/api/hooks/use-imperative-form-handle.d.ts +3 -0
  54. package/dist/api/hooks/use-imperative-form-handle.js +25 -0
  55. package/dist/api/hooks/use-navigation.d.ts +4 -0
  56. package/dist/api/hooks/use-navigation.js +13 -0
  57. package/dist/api/hooks.d.ts +1 -0
  58. package/dist/api/hooks.js +24 -0
  59. package/dist/api/icon.d.ts +444 -0
  60. package/dist/api/icon.js +448 -0
  61. package/dist/api/image.d.ts +35 -0
  62. package/dist/api/image.js +84 -0
  63. package/dist/api/index.d.ts +19 -0
  64. package/dist/api/index.js +35 -0
  65. package/dist/api/keyboard.d.ts +16 -0
  66. package/dist/api/keyboard.js +12 -0
  67. package/dist/api/lib/result.d.ts +9 -0
  68. package/dist/api/lib/result.js +11 -0
  69. package/dist/api/local-storage.d.ts +13 -0
  70. package/dist/api/local-storage.js +31 -0
  71. package/dist/api/oauth.d.ts +319 -0
  72. package/dist/api/oauth.js +166 -0
  73. package/dist/api/preference.d.ts +5 -0
  74. package/dist/api/preference.js +18 -0
  75. package/dist/api/proto/application.d.ts +48 -0
  76. package/dist/api/proto/application.js +378 -0
  77. package/dist/api/proto/clipboard.d.ts +65 -0
  78. package/dist/api/proto/clipboard.js +614 -0
  79. package/dist/api/proto/common.d.ts +28 -0
  80. package/dist/api/proto/common.js +102 -0
  81. package/dist/api/proto/extension.d.ts +68 -0
  82. package/dist/api/proto/extension.js +604 -0
  83. package/dist/api/proto/google/protobuf/struct.d.ts +107 -0
  84. package/dist/api/proto/google/protobuf/struct.js +456 -0
  85. package/dist/api/proto/ipc.d.ts +64 -0
  86. package/dist/api/proto/ipc.js +604 -0
  87. package/dist/api/proto/manager.d.ts +82 -0
  88. package/dist/api/proto/manager.js +689 -0
  89. package/dist/api/proto/oauth.d.ts +55 -0
  90. package/dist/api/proto/oauth.js +379 -0
  91. package/dist/api/proto/storage.d.ts +80 -0
  92. package/dist/api/proto/storage.js +804 -0
  93. package/dist/api/proto/ui.d.ts +186 -0
  94. package/dist/api/proto/ui.js +1993 -0
  95. package/dist/api/toast.d.ts +168 -0
  96. package/dist/api/toast.js +152 -0
  97. package/dist/api/utils.d.ts +15 -0
  98. package/dist/api/utils.js +64 -0
  99. package/dist/commands/build/index.d.ts +11 -0
  100. package/dist/commands/build/index.js +123 -0
  101. package/dist/commands/develop/index.d.ts +10 -0
  102. package/dist/commands/develop/index.js +193 -0
  103. package/dist/index.d.ts +1 -0
  104. package/dist/index.js +17 -0
  105. package/dist/schemas/manifest.d.ts +75 -0
  106. package/dist/schemas/manifest.js +4 -0
  107. package/dist/utils/logger.d.ts +13 -0
  108. package/dist/utils/logger.js +38 -0
  109. package/dist/utils/utils.d.ts +2 -0
  110. package/dist/utils/utils.js +19 -0
  111. package/dist/utils/vicinae.d.ts +12 -0
  112. package/dist/utils/vicinae.js +33 -0
  113. package/package.json +73 -0
@@ -0,0 +1,689 @@
1
+ "use strict";
2
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
3
+ // versions:
4
+ // protoc-gen-ts_proto v2.7.5
5
+ // protoc v6.31.1
6
+ // source: manager.proto
7
+ Object.defineProperty(exports, "__esModule", { value: true });
8
+ exports.ManagerLoadResponseData = exports.ManagerUnloadCommand = exports.ManagerLoadCommand_ArgumentValuesEntry = exports.ManagerLoadCommand_PreferenceValuesEntry = exports.ManagerLoadCommand = exports.ResponseData = exports.ManagerPingRequestData = exports.RequestData = exports.CommandEnv = exports.CommandMode = exports.protobufPackage = void 0;
9
+ exports.commandModeFromJSON = commandModeFromJSON;
10
+ exports.commandModeToJSON = commandModeToJSON;
11
+ exports.commandEnvFromJSON = commandEnvFromJSON;
12
+ exports.commandEnvToJSON = commandEnvToJSON;
13
+ /* eslint-disable */
14
+ const wire_1 = require("@bufbuild/protobuf/wire");
15
+ const common_1 = require("./common");
16
+ const struct_1 = require("./google/protobuf/struct");
17
+ exports.protobufPackage = "proto.ext.manager";
18
+ var CommandMode;
19
+ (function (CommandMode) {
20
+ CommandMode[CommandMode["View"] = 0] = "View";
21
+ CommandMode[CommandMode["NoView"] = 1] = "NoView";
22
+ CommandMode[CommandMode["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
23
+ })(CommandMode || (exports.CommandMode = CommandMode = {}));
24
+ function commandModeFromJSON(object) {
25
+ switch (object) {
26
+ case 0:
27
+ case "View":
28
+ return CommandMode.View;
29
+ case 1:
30
+ case "NoView":
31
+ return CommandMode.NoView;
32
+ case -1:
33
+ case "UNRECOGNIZED":
34
+ default:
35
+ return CommandMode.UNRECOGNIZED;
36
+ }
37
+ }
38
+ function commandModeToJSON(object) {
39
+ switch (object) {
40
+ case CommandMode.View:
41
+ return "View";
42
+ case CommandMode.NoView:
43
+ return "NoView";
44
+ case CommandMode.UNRECOGNIZED:
45
+ default:
46
+ return "UNRECOGNIZED";
47
+ }
48
+ }
49
+ var CommandEnv;
50
+ (function (CommandEnv) {
51
+ CommandEnv[CommandEnv["Development"] = 0] = "Development";
52
+ CommandEnv[CommandEnv["Production"] = 1] = "Production";
53
+ CommandEnv[CommandEnv["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
54
+ })(CommandEnv || (exports.CommandEnv = CommandEnv = {}));
55
+ function commandEnvFromJSON(object) {
56
+ switch (object) {
57
+ case 0:
58
+ case "Development":
59
+ return CommandEnv.Development;
60
+ case 1:
61
+ case "Production":
62
+ return CommandEnv.Production;
63
+ case -1:
64
+ case "UNRECOGNIZED":
65
+ default:
66
+ return CommandEnv.UNRECOGNIZED;
67
+ }
68
+ }
69
+ function commandEnvToJSON(object) {
70
+ switch (object) {
71
+ case CommandEnv.Development:
72
+ return "Development";
73
+ case CommandEnv.Production:
74
+ return "Production";
75
+ case CommandEnv.UNRECOGNIZED:
76
+ default:
77
+ return "UNRECOGNIZED";
78
+ }
79
+ }
80
+ function createBaseRequestData() {
81
+ return { ping: undefined, load: undefined, unload: undefined };
82
+ }
83
+ exports.RequestData = {
84
+ encode(message, writer = new wire_1.BinaryWriter()) {
85
+ if (message.ping !== undefined) {
86
+ exports.ManagerPingRequestData.encode(message.ping, writer.uint32(10).fork()).join();
87
+ }
88
+ if (message.load !== undefined) {
89
+ exports.ManagerLoadCommand.encode(message.load, writer.uint32(18).fork()).join();
90
+ }
91
+ if (message.unload !== undefined) {
92
+ exports.ManagerUnloadCommand.encode(message.unload, writer.uint32(26).fork()).join();
93
+ }
94
+ return writer;
95
+ },
96
+ decode(input, length) {
97
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
98
+ const end = length === undefined ? reader.len : reader.pos + length;
99
+ const message = createBaseRequestData();
100
+ while (reader.pos < end) {
101
+ const tag = reader.uint32();
102
+ switch (tag >>> 3) {
103
+ case 1: {
104
+ if (tag !== 10) {
105
+ break;
106
+ }
107
+ message.ping = exports.ManagerPingRequestData.decode(reader, reader.uint32());
108
+ continue;
109
+ }
110
+ case 2: {
111
+ if (tag !== 18) {
112
+ break;
113
+ }
114
+ message.load = exports.ManagerLoadCommand.decode(reader, reader.uint32());
115
+ continue;
116
+ }
117
+ case 3: {
118
+ if (tag !== 26) {
119
+ break;
120
+ }
121
+ message.unload = exports.ManagerUnloadCommand.decode(reader, reader.uint32());
122
+ continue;
123
+ }
124
+ }
125
+ if ((tag & 7) === 4 || tag === 0) {
126
+ break;
127
+ }
128
+ reader.skip(tag & 7);
129
+ }
130
+ return message;
131
+ },
132
+ fromJSON(object) {
133
+ return {
134
+ ping: isSet(object.ping) ? exports.ManagerPingRequestData.fromJSON(object.ping) : undefined,
135
+ load: isSet(object.load) ? exports.ManagerLoadCommand.fromJSON(object.load) : undefined,
136
+ unload: isSet(object.unload) ? exports.ManagerUnloadCommand.fromJSON(object.unload) : undefined,
137
+ };
138
+ },
139
+ toJSON(message) {
140
+ const obj = {};
141
+ if (message.ping !== undefined) {
142
+ obj.ping = exports.ManagerPingRequestData.toJSON(message.ping);
143
+ }
144
+ if (message.load !== undefined) {
145
+ obj.load = exports.ManagerLoadCommand.toJSON(message.load);
146
+ }
147
+ if (message.unload !== undefined) {
148
+ obj.unload = exports.ManagerUnloadCommand.toJSON(message.unload);
149
+ }
150
+ return obj;
151
+ },
152
+ create(base) {
153
+ return exports.RequestData.fromPartial(base ?? {});
154
+ },
155
+ fromPartial(object) {
156
+ const message = createBaseRequestData();
157
+ message.ping = (object.ping !== undefined && object.ping !== null)
158
+ ? exports.ManagerPingRequestData.fromPartial(object.ping)
159
+ : undefined;
160
+ message.load = (object.load !== undefined && object.load !== null)
161
+ ? exports.ManagerLoadCommand.fromPartial(object.load)
162
+ : undefined;
163
+ message.unload = (object.unload !== undefined && object.unload !== null)
164
+ ? exports.ManagerUnloadCommand.fromPartial(object.unload)
165
+ : undefined;
166
+ return message;
167
+ },
168
+ };
169
+ function createBaseManagerPingRequestData() {
170
+ return {};
171
+ }
172
+ exports.ManagerPingRequestData = {
173
+ encode(_, writer = new wire_1.BinaryWriter()) {
174
+ return writer;
175
+ },
176
+ decode(input, length) {
177
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
178
+ const end = length === undefined ? reader.len : reader.pos + length;
179
+ const message = createBaseManagerPingRequestData();
180
+ while (reader.pos < end) {
181
+ const tag = reader.uint32();
182
+ switch (tag >>> 3) {
183
+ }
184
+ if ((tag & 7) === 4 || tag === 0) {
185
+ break;
186
+ }
187
+ reader.skip(tag & 7);
188
+ }
189
+ return message;
190
+ },
191
+ fromJSON(_) {
192
+ return {};
193
+ },
194
+ toJSON(_) {
195
+ const obj = {};
196
+ return obj;
197
+ },
198
+ create(base) {
199
+ return exports.ManagerPingRequestData.fromPartial(base ?? {});
200
+ },
201
+ fromPartial(_) {
202
+ const message = createBaseManagerPingRequestData();
203
+ return message;
204
+ },
205
+ };
206
+ function createBaseResponseData() {
207
+ return { ack: undefined, load: undefined };
208
+ }
209
+ exports.ResponseData = {
210
+ encode(message, writer = new wire_1.BinaryWriter()) {
211
+ if (message.ack !== undefined) {
212
+ common_1.AckResponse.encode(message.ack, writer.uint32(10).fork()).join();
213
+ }
214
+ if (message.load !== undefined) {
215
+ exports.ManagerLoadResponseData.encode(message.load, writer.uint32(18).fork()).join();
216
+ }
217
+ return writer;
218
+ },
219
+ decode(input, length) {
220
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
221
+ const end = length === undefined ? reader.len : reader.pos + length;
222
+ const message = createBaseResponseData();
223
+ while (reader.pos < end) {
224
+ const tag = reader.uint32();
225
+ switch (tag >>> 3) {
226
+ case 1: {
227
+ if (tag !== 10) {
228
+ break;
229
+ }
230
+ message.ack = common_1.AckResponse.decode(reader, reader.uint32());
231
+ continue;
232
+ }
233
+ case 2: {
234
+ if (tag !== 18) {
235
+ break;
236
+ }
237
+ message.load = exports.ManagerLoadResponseData.decode(reader, reader.uint32());
238
+ continue;
239
+ }
240
+ }
241
+ if ((tag & 7) === 4 || tag === 0) {
242
+ break;
243
+ }
244
+ reader.skip(tag & 7);
245
+ }
246
+ return message;
247
+ },
248
+ fromJSON(object) {
249
+ return {
250
+ ack: isSet(object.ack) ? common_1.AckResponse.fromJSON(object.ack) : undefined,
251
+ load: isSet(object.load) ? exports.ManagerLoadResponseData.fromJSON(object.load) : undefined,
252
+ };
253
+ },
254
+ toJSON(message) {
255
+ const obj = {};
256
+ if (message.ack !== undefined) {
257
+ obj.ack = common_1.AckResponse.toJSON(message.ack);
258
+ }
259
+ if (message.load !== undefined) {
260
+ obj.load = exports.ManagerLoadResponseData.toJSON(message.load);
261
+ }
262
+ return obj;
263
+ },
264
+ create(base) {
265
+ return exports.ResponseData.fromPartial(base ?? {});
266
+ },
267
+ fromPartial(object) {
268
+ const message = createBaseResponseData();
269
+ message.ack = (object.ack !== undefined && object.ack !== null) ? common_1.AckResponse.fromPartial(object.ack) : undefined;
270
+ message.load = (object.load !== undefined && object.load !== null)
271
+ ? exports.ManagerLoadResponseData.fromPartial(object.load)
272
+ : undefined;
273
+ return message;
274
+ },
275
+ };
276
+ function createBaseManagerLoadCommand() {
277
+ return { mode: 0, env: 0, extensionPath: "", entrypoint: "", preferenceValues: {}, argumentValues: {} };
278
+ }
279
+ exports.ManagerLoadCommand = {
280
+ encode(message, writer = new wire_1.BinaryWriter()) {
281
+ if (message.mode !== 0) {
282
+ writer.uint32(8).int32(message.mode);
283
+ }
284
+ if (message.env !== 0) {
285
+ writer.uint32(16).int32(message.env);
286
+ }
287
+ if (message.extensionPath !== "") {
288
+ writer.uint32(26).string(message.extensionPath);
289
+ }
290
+ if (message.entrypoint !== "") {
291
+ writer.uint32(34).string(message.entrypoint);
292
+ }
293
+ Object.entries(message.preferenceValues).forEach(([key, value]) => {
294
+ if (value !== undefined) {
295
+ exports.ManagerLoadCommand_PreferenceValuesEntry.encode({ key: key, value }, writer.uint32(42).fork()).join();
296
+ }
297
+ });
298
+ Object.entries(message.argumentValues).forEach(([key, value]) => {
299
+ if (value !== undefined) {
300
+ exports.ManagerLoadCommand_ArgumentValuesEntry.encode({ key: key, value }, writer.uint32(50).fork()).join();
301
+ }
302
+ });
303
+ return writer;
304
+ },
305
+ decode(input, length) {
306
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
307
+ const end = length === undefined ? reader.len : reader.pos + length;
308
+ const message = createBaseManagerLoadCommand();
309
+ while (reader.pos < end) {
310
+ const tag = reader.uint32();
311
+ switch (tag >>> 3) {
312
+ case 1: {
313
+ if (tag !== 8) {
314
+ break;
315
+ }
316
+ message.mode = reader.int32();
317
+ continue;
318
+ }
319
+ case 2: {
320
+ if (tag !== 16) {
321
+ break;
322
+ }
323
+ message.env = reader.int32();
324
+ continue;
325
+ }
326
+ case 3: {
327
+ if (tag !== 26) {
328
+ break;
329
+ }
330
+ message.extensionPath = reader.string();
331
+ continue;
332
+ }
333
+ case 4: {
334
+ if (tag !== 34) {
335
+ break;
336
+ }
337
+ message.entrypoint = reader.string();
338
+ continue;
339
+ }
340
+ case 5: {
341
+ if (tag !== 42) {
342
+ break;
343
+ }
344
+ const entry5 = exports.ManagerLoadCommand_PreferenceValuesEntry.decode(reader, reader.uint32());
345
+ if (entry5.value !== undefined) {
346
+ message.preferenceValues[entry5.key] = entry5.value;
347
+ }
348
+ continue;
349
+ }
350
+ case 6: {
351
+ if (tag !== 50) {
352
+ break;
353
+ }
354
+ const entry6 = exports.ManagerLoadCommand_ArgumentValuesEntry.decode(reader, reader.uint32());
355
+ if (entry6.value !== undefined) {
356
+ message.argumentValues[entry6.key] = entry6.value;
357
+ }
358
+ continue;
359
+ }
360
+ }
361
+ if ((tag & 7) === 4 || tag === 0) {
362
+ break;
363
+ }
364
+ reader.skip(tag & 7);
365
+ }
366
+ return message;
367
+ },
368
+ fromJSON(object) {
369
+ return {
370
+ mode: isSet(object.mode) ? commandModeFromJSON(object.mode) : 0,
371
+ env: isSet(object.env) ? commandEnvFromJSON(object.env) : 0,
372
+ extensionPath: isSet(object.extensionPath) ? globalThis.String(object.extensionPath) : "",
373
+ entrypoint: isSet(object.entrypoint) ? globalThis.String(object.entrypoint) : "",
374
+ preferenceValues: isObject(object.preferenceValues)
375
+ ? Object.entries(object.preferenceValues).reduce((acc, [key, value]) => {
376
+ acc[key] = value;
377
+ return acc;
378
+ }, {})
379
+ : {},
380
+ argumentValues: isObject(object.argumentValues)
381
+ ? Object.entries(object.argumentValues).reduce((acc, [key, value]) => {
382
+ acc[key] = value;
383
+ return acc;
384
+ }, {})
385
+ : {},
386
+ };
387
+ },
388
+ toJSON(message) {
389
+ const obj = {};
390
+ if (message.mode !== 0) {
391
+ obj.mode = commandModeToJSON(message.mode);
392
+ }
393
+ if (message.env !== 0) {
394
+ obj.env = commandEnvToJSON(message.env);
395
+ }
396
+ if (message.extensionPath !== "") {
397
+ obj.extensionPath = message.extensionPath;
398
+ }
399
+ if (message.entrypoint !== "") {
400
+ obj.entrypoint = message.entrypoint;
401
+ }
402
+ if (message.preferenceValues) {
403
+ const entries = Object.entries(message.preferenceValues);
404
+ if (entries.length > 0) {
405
+ obj.preferenceValues = {};
406
+ entries.forEach(([k, v]) => {
407
+ obj.preferenceValues[k] = v;
408
+ });
409
+ }
410
+ }
411
+ if (message.argumentValues) {
412
+ const entries = Object.entries(message.argumentValues);
413
+ if (entries.length > 0) {
414
+ obj.argumentValues = {};
415
+ entries.forEach(([k, v]) => {
416
+ obj.argumentValues[k] = v;
417
+ });
418
+ }
419
+ }
420
+ return obj;
421
+ },
422
+ create(base) {
423
+ return exports.ManagerLoadCommand.fromPartial(base ?? {});
424
+ },
425
+ fromPartial(object) {
426
+ const message = createBaseManagerLoadCommand();
427
+ message.mode = object.mode ?? 0;
428
+ message.env = object.env ?? 0;
429
+ message.extensionPath = object.extensionPath ?? "";
430
+ message.entrypoint = object.entrypoint ?? "";
431
+ message.preferenceValues = Object.entries(object.preferenceValues ?? {}).reduce((acc, [key, value]) => {
432
+ if (value !== undefined) {
433
+ acc[key] = value;
434
+ }
435
+ return acc;
436
+ }, {});
437
+ message.argumentValues = Object.entries(object.argumentValues ?? {}).reduce((acc, [key, value]) => {
438
+ if (value !== undefined) {
439
+ acc[key] = value;
440
+ }
441
+ return acc;
442
+ }, {});
443
+ return message;
444
+ },
445
+ };
446
+ function createBaseManagerLoadCommand_PreferenceValuesEntry() {
447
+ return { key: "", value: undefined };
448
+ }
449
+ exports.ManagerLoadCommand_PreferenceValuesEntry = {
450
+ encode(message, writer = new wire_1.BinaryWriter()) {
451
+ if (message.key !== "") {
452
+ writer.uint32(10).string(message.key);
453
+ }
454
+ if (message.value !== undefined) {
455
+ struct_1.Value.encode(struct_1.Value.wrap(message.value), writer.uint32(18).fork()).join();
456
+ }
457
+ return writer;
458
+ },
459
+ decode(input, length) {
460
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
461
+ const end = length === undefined ? reader.len : reader.pos + length;
462
+ const message = createBaseManagerLoadCommand_PreferenceValuesEntry();
463
+ while (reader.pos < end) {
464
+ const tag = reader.uint32();
465
+ switch (tag >>> 3) {
466
+ case 1: {
467
+ if (tag !== 10) {
468
+ break;
469
+ }
470
+ message.key = reader.string();
471
+ continue;
472
+ }
473
+ case 2: {
474
+ if (tag !== 18) {
475
+ break;
476
+ }
477
+ message.value = struct_1.Value.unwrap(struct_1.Value.decode(reader, reader.uint32()));
478
+ continue;
479
+ }
480
+ }
481
+ if ((tag & 7) === 4 || tag === 0) {
482
+ break;
483
+ }
484
+ reader.skip(tag & 7);
485
+ }
486
+ return message;
487
+ },
488
+ fromJSON(object) {
489
+ return {
490
+ key: isSet(object.key) ? globalThis.String(object.key) : "",
491
+ value: isSet(object?.value) ? object.value : undefined,
492
+ };
493
+ },
494
+ toJSON(message) {
495
+ const obj = {};
496
+ if (message.key !== "") {
497
+ obj.key = message.key;
498
+ }
499
+ if (message.value !== undefined) {
500
+ obj.value = message.value;
501
+ }
502
+ return obj;
503
+ },
504
+ create(base) {
505
+ return exports.ManagerLoadCommand_PreferenceValuesEntry.fromPartial(base ?? {});
506
+ },
507
+ fromPartial(object) {
508
+ const message = createBaseManagerLoadCommand_PreferenceValuesEntry();
509
+ message.key = object.key ?? "";
510
+ message.value = object.value ?? undefined;
511
+ return message;
512
+ },
513
+ };
514
+ function createBaseManagerLoadCommand_ArgumentValuesEntry() {
515
+ return { key: "", value: undefined };
516
+ }
517
+ exports.ManagerLoadCommand_ArgumentValuesEntry = {
518
+ encode(message, writer = new wire_1.BinaryWriter()) {
519
+ if (message.key !== "") {
520
+ writer.uint32(10).string(message.key);
521
+ }
522
+ if (message.value !== undefined) {
523
+ struct_1.Value.encode(struct_1.Value.wrap(message.value), writer.uint32(18).fork()).join();
524
+ }
525
+ return writer;
526
+ },
527
+ decode(input, length) {
528
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
529
+ const end = length === undefined ? reader.len : reader.pos + length;
530
+ const message = createBaseManagerLoadCommand_ArgumentValuesEntry();
531
+ while (reader.pos < end) {
532
+ const tag = reader.uint32();
533
+ switch (tag >>> 3) {
534
+ case 1: {
535
+ if (tag !== 10) {
536
+ break;
537
+ }
538
+ message.key = reader.string();
539
+ continue;
540
+ }
541
+ case 2: {
542
+ if (tag !== 18) {
543
+ break;
544
+ }
545
+ message.value = struct_1.Value.unwrap(struct_1.Value.decode(reader, reader.uint32()));
546
+ continue;
547
+ }
548
+ }
549
+ if ((tag & 7) === 4 || tag === 0) {
550
+ break;
551
+ }
552
+ reader.skip(tag & 7);
553
+ }
554
+ return message;
555
+ },
556
+ fromJSON(object) {
557
+ return {
558
+ key: isSet(object.key) ? globalThis.String(object.key) : "",
559
+ value: isSet(object?.value) ? object.value : undefined,
560
+ };
561
+ },
562
+ toJSON(message) {
563
+ const obj = {};
564
+ if (message.key !== "") {
565
+ obj.key = message.key;
566
+ }
567
+ if (message.value !== undefined) {
568
+ obj.value = message.value;
569
+ }
570
+ return obj;
571
+ },
572
+ create(base) {
573
+ return exports.ManagerLoadCommand_ArgumentValuesEntry.fromPartial(base ?? {});
574
+ },
575
+ fromPartial(object) {
576
+ const message = createBaseManagerLoadCommand_ArgumentValuesEntry();
577
+ message.key = object.key ?? "";
578
+ message.value = object.value ?? undefined;
579
+ return message;
580
+ },
581
+ };
582
+ function createBaseManagerUnloadCommand() {
583
+ return { sessionId: "" };
584
+ }
585
+ exports.ManagerUnloadCommand = {
586
+ encode(message, writer = new wire_1.BinaryWriter()) {
587
+ if (message.sessionId !== "") {
588
+ writer.uint32(10).string(message.sessionId);
589
+ }
590
+ return writer;
591
+ },
592
+ decode(input, length) {
593
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
594
+ const end = length === undefined ? reader.len : reader.pos + length;
595
+ const message = createBaseManagerUnloadCommand();
596
+ while (reader.pos < end) {
597
+ const tag = reader.uint32();
598
+ switch (tag >>> 3) {
599
+ case 1: {
600
+ if (tag !== 10) {
601
+ break;
602
+ }
603
+ message.sessionId = reader.string();
604
+ continue;
605
+ }
606
+ }
607
+ if ((tag & 7) === 4 || tag === 0) {
608
+ break;
609
+ }
610
+ reader.skip(tag & 7);
611
+ }
612
+ return message;
613
+ },
614
+ fromJSON(object) {
615
+ return { sessionId: isSet(object.sessionId) ? globalThis.String(object.sessionId) : "" };
616
+ },
617
+ toJSON(message) {
618
+ const obj = {};
619
+ if (message.sessionId !== "") {
620
+ obj.sessionId = message.sessionId;
621
+ }
622
+ return obj;
623
+ },
624
+ create(base) {
625
+ return exports.ManagerUnloadCommand.fromPartial(base ?? {});
626
+ },
627
+ fromPartial(object) {
628
+ const message = createBaseManagerUnloadCommand();
629
+ message.sessionId = object.sessionId ?? "";
630
+ return message;
631
+ },
632
+ };
633
+ function createBaseManagerLoadResponseData() {
634
+ return { sessionId: "" };
635
+ }
636
+ exports.ManagerLoadResponseData = {
637
+ encode(message, writer = new wire_1.BinaryWriter()) {
638
+ if (message.sessionId !== "") {
639
+ writer.uint32(10).string(message.sessionId);
640
+ }
641
+ return writer;
642
+ },
643
+ decode(input, length) {
644
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
645
+ const end = length === undefined ? reader.len : reader.pos + length;
646
+ const message = createBaseManagerLoadResponseData();
647
+ while (reader.pos < end) {
648
+ const tag = reader.uint32();
649
+ switch (tag >>> 3) {
650
+ case 1: {
651
+ if (tag !== 10) {
652
+ break;
653
+ }
654
+ message.sessionId = reader.string();
655
+ continue;
656
+ }
657
+ }
658
+ if ((tag & 7) === 4 || tag === 0) {
659
+ break;
660
+ }
661
+ reader.skip(tag & 7);
662
+ }
663
+ return message;
664
+ },
665
+ fromJSON(object) {
666
+ return { sessionId: isSet(object.sessionId) ? globalThis.String(object.sessionId) : "" };
667
+ },
668
+ toJSON(message) {
669
+ const obj = {};
670
+ if (message.sessionId !== "") {
671
+ obj.sessionId = message.sessionId;
672
+ }
673
+ return obj;
674
+ },
675
+ create(base) {
676
+ return exports.ManagerLoadResponseData.fromPartial(base ?? {});
677
+ },
678
+ fromPartial(object) {
679
+ const message = createBaseManagerLoadResponseData();
680
+ message.sessionId = object.sessionId ?? "";
681
+ return message;
682
+ },
683
+ };
684
+ function isObject(value) {
685
+ return typeof value === "object" && value !== null;
686
+ }
687
+ function isSet(value) {
688
+ return value !== null && value !== undefined;
689
+ }