@vicinae/api 0.20.9 → 0.20.10

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 (76) hide show
  1. package/dist/api/alert.d.ts +1 -1
  2. package/dist/api/alert.js +9 -14
  3. package/dist/api/client.d.ts +7 -0
  4. package/dist/api/client.js +11 -0
  5. package/dist/api/clipboard.d.ts +4 -8
  6. package/dist/api/clipboard.js +13 -18
  7. package/dist/api/color.d.ts +4 -10
  8. package/dist/api/color.js +8 -47
  9. package/dist/api/command.js +4 -6
  10. package/dist/api/controls.js +9 -56
  11. package/dist/api/environment.d.ts +0 -11
  12. package/dist/api/environment.js +2 -1
  13. package/dist/api/file-search.d.ts +3 -4
  14. package/dist/api/file-search.js +6 -4
  15. package/dist/api/globals.d.ts +9 -0
  16. package/dist/api/globals.js +5 -0
  17. package/dist/api/hooks/use-imperative-form-handle.d.ts +1 -1
  18. package/dist/api/hooks/use-imperative-form-handle.js +6 -3
  19. package/dist/api/hooks/use-navigation.d.ts +2 -2
  20. package/dist/api/hooks/use-navigation.js +2 -5
  21. package/dist/api/image.d.ts +4 -4
  22. package/dist/api/image.js +12 -51
  23. package/dist/api/index.d.ts +0 -2
  24. package/dist/api/index.js +0 -2
  25. package/dist/api/local-storage.js +7 -14
  26. package/dist/api/oauth.d.ts +1 -1
  27. package/dist/api/oauth.js +7 -15
  28. package/dist/api/preference.d.ts +2 -4
  29. package/dist/api/preference.js +10 -6
  30. package/dist/api/proto/api.d.ts +240 -0
  31. package/dist/api/proto/api.js +271 -0
  32. package/dist/api/toast.js +7 -77
  33. package/dist/api/utils.d.ts +6 -2
  34. package/dist/api/utils.js +9 -26
  35. package/dist/api/window-management.d.ts +3 -5
  36. package/dist/api/window-management.js +14 -27
  37. package/dist/schemas/manifest.d.ts +3 -3
  38. package/package.json +1 -4
  39. package/dist/api/bus.d.ts +0 -125
  40. package/dist/api/bus.js +0 -201
  41. package/dist/api/context/index.d.ts +0 -1
  42. package/dist/api/context/index.js +0 -17
  43. package/dist/api/context/navigation-context.d.ts +0 -7
  44. package/dist/api/context/navigation-context.js +0 -12
  45. package/dist/api/context/navigation-provider.d.ts +0 -7
  46. package/dist/api/context/navigation-provider.js +0 -58
  47. package/dist/api/hooks.d.ts +0 -1
  48. package/dist/api/hooks.js +0 -30
  49. package/dist/api/proto/application.d.ts +0 -79
  50. package/dist/api/proto/application.js +0 -826
  51. package/dist/api/proto/clipboard.d.ts +0 -88
  52. package/dist/api/proto/clipboard.js +0 -929
  53. package/dist/api/proto/command.d.ts +0 -35
  54. package/dist/api/proto/command.js +0 -182
  55. package/dist/api/proto/common.d.ts +0 -28
  56. package/dist/api/proto/common.js +0 -102
  57. package/dist/api/proto/extension.d.ts +0 -106
  58. package/dist/api/proto/extension.js +0 -1122
  59. package/dist/api/proto/file-search.d.ts +0 -42
  60. package/dist/api/proto/file-search.js +0 -290
  61. package/dist/api/proto/google/protobuf/struct.d.ts +0 -107
  62. package/dist/api/proto/google/protobuf/struct.js +0 -456
  63. package/dist/api/proto/ipc.d.ts +0 -64
  64. package/dist/api/proto/ipc.js +0 -604
  65. package/dist/api/proto/manager.d.ts +0 -87
  66. package/dist/api/proto/manager.js +0 -776
  67. package/dist/api/proto/oauth.d.ts +0 -97
  68. package/dist/api/proto/oauth.js +0 -994
  69. package/dist/api/proto/storage.d.ts +0 -80
  70. package/dist/api/proto/storage.js +0 -804
  71. package/dist/api/proto/ui.d.ts +0 -208
  72. package/dist/api/proto/ui.js +0 -2316
  73. package/dist/api/proto/wlr-clipboard.d.ts +0 -30
  74. package/dist/api/proto/wlr-clipboard.js +0 -158
  75. package/dist/api/proto/wm.d.ts +0 -142
  76. package/dist/api/proto/wm.js +0 -1714
@@ -1,776 +0,0 @@
1
- "use strict";
2
- // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
3
- // versions:
4
- // protoc-gen-ts_proto v2.7.7
5
- // protoc v6.33.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 {
278
- mode: 0,
279
- env: 0,
280
- vicinaePath: "",
281
- entrypoint: "",
282
- preferenceValues: {},
283
- argumentValues: {},
284
- isRaycast: false,
285
- commandName: "",
286
- extensionId: "",
287
- extensionName: "",
288
- ownerOrAuthorName: "",
289
- };
290
- }
291
- exports.ManagerLoadCommand = {
292
- encode(message, writer = new wire_1.BinaryWriter()) {
293
- if (message.mode !== 0) {
294
- writer.uint32(8).int32(message.mode);
295
- }
296
- if (message.env !== 0) {
297
- writer.uint32(16).int32(message.env);
298
- }
299
- if (message.vicinaePath !== "") {
300
- writer.uint32(26).string(message.vicinaePath);
301
- }
302
- if (message.entrypoint !== "") {
303
- writer.uint32(34).string(message.entrypoint);
304
- }
305
- Object.entries(message.preferenceValues).forEach(([key, value]) => {
306
- if (value !== undefined) {
307
- exports.ManagerLoadCommand_PreferenceValuesEntry.encode({ key: key, value }, writer.uint32(42).fork()).join();
308
- }
309
- });
310
- Object.entries(message.argumentValues).forEach(([key, value]) => {
311
- if (value !== undefined) {
312
- exports.ManagerLoadCommand_ArgumentValuesEntry.encode({ key: key, value }, writer.uint32(50).fork()).join();
313
- }
314
- });
315
- if (message.isRaycast !== false) {
316
- writer.uint32(56).bool(message.isRaycast);
317
- }
318
- if (message.commandName !== "") {
319
- writer.uint32(66).string(message.commandName);
320
- }
321
- if (message.extensionId !== "") {
322
- writer.uint32(74).string(message.extensionId);
323
- }
324
- if (message.extensionName !== "") {
325
- writer.uint32(82).string(message.extensionName);
326
- }
327
- if (message.ownerOrAuthorName !== "") {
328
- writer.uint32(90).string(message.ownerOrAuthorName);
329
- }
330
- return writer;
331
- },
332
- decode(input, length) {
333
- const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
334
- const end = length === undefined ? reader.len : reader.pos + length;
335
- const message = createBaseManagerLoadCommand();
336
- while (reader.pos < end) {
337
- const tag = reader.uint32();
338
- switch (tag >>> 3) {
339
- case 1: {
340
- if (tag !== 8) {
341
- break;
342
- }
343
- message.mode = reader.int32();
344
- continue;
345
- }
346
- case 2: {
347
- if (tag !== 16) {
348
- break;
349
- }
350
- message.env = reader.int32();
351
- continue;
352
- }
353
- case 3: {
354
- if (tag !== 26) {
355
- break;
356
- }
357
- message.vicinaePath = reader.string();
358
- continue;
359
- }
360
- case 4: {
361
- if (tag !== 34) {
362
- break;
363
- }
364
- message.entrypoint = reader.string();
365
- continue;
366
- }
367
- case 5: {
368
- if (tag !== 42) {
369
- break;
370
- }
371
- const entry5 = exports.ManagerLoadCommand_PreferenceValuesEntry.decode(reader, reader.uint32());
372
- if (entry5.value !== undefined) {
373
- message.preferenceValues[entry5.key] = entry5.value;
374
- }
375
- continue;
376
- }
377
- case 6: {
378
- if (tag !== 50) {
379
- break;
380
- }
381
- const entry6 = exports.ManagerLoadCommand_ArgumentValuesEntry.decode(reader, reader.uint32());
382
- if (entry6.value !== undefined) {
383
- message.argumentValues[entry6.key] = entry6.value;
384
- }
385
- continue;
386
- }
387
- case 7: {
388
- if (tag !== 56) {
389
- break;
390
- }
391
- message.isRaycast = reader.bool();
392
- continue;
393
- }
394
- case 8: {
395
- if (tag !== 66) {
396
- break;
397
- }
398
- message.commandName = reader.string();
399
- continue;
400
- }
401
- case 9: {
402
- if (tag !== 74) {
403
- break;
404
- }
405
- message.extensionId = reader.string();
406
- continue;
407
- }
408
- case 10: {
409
- if (tag !== 82) {
410
- break;
411
- }
412
- message.extensionName = reader.string();
413
- continue;
414
- }
415
- case 11: {
416
- if (tag !== 90) {
417
- break;
418
- }
419
- message.ownerOrAuthorName = reader.string();
420
- continue;
421
- }
422
- }
423
- if ((tag & 7) === 4 || tag === 0) {
424
- break;
425
- }
426
- reader.skip(tag & 7);
427
- }
428
- return message;
429
- },
430
- fromJSON(object) {
431
- return {
432
- mode: isSet(object.mode) ? commandModeFromJSON(object.mode) : 0,
433
- env: isSet(object.env) ? commandEnvFromJSON(object.env) : 0,
434
- vicinaePath: isSet(object.vicinaePath) ? globalThis.String(object.vicinaePath) : "",
435
- entrypoint: isSet(object.entrypoint) ? globalThis.String(object.entrypoint) : "",
436
- preferenceValues: isObject(object.preferenceValues)
437
- ? Object.entries(object.preferenceValues).reduce((acc, [key, value]) => {
438
- acc[key] = value;
439
- return acc;
440
- }, {})
441
- : {},
442
- argumentValues: isObject(object.argumentValues)
443
- ? Object.entries(object.argumentValues).reduce((acc, [key, value]) => {
444
- acc[key] = value;
445
- return acc;
446
- }, {})
447
- : {},
448
- isRaycast: isSet(object.isRaycast) ? globalThis.Boolean(object.isRaycast) : false,
449
- commandName: isSet(object.commandName) ? globalThis.String(object.commandName) : "",
450
- extensionId: isSet(object.extensionId) ? globalThis.String(object.extensionId) : "",
451
- extensionName: isSet(object.extensionName) ? globalThis.String(object.extensionName) : "",
452
- ownerOrAuthorName: isSet(object.ownerOrAuthorName) ? globalThis.String(object.ownerOrAuthorName) : "",
453
- };
454
- },
455
- toJSON(message) {
456
- const obj = {};
457
- if (message.mode !== 0) {
458
- obj.mode = commandModeToJSON(message.mode);
459
- }
460
- if (message.env !== 0) {
461
- obj.env = commandEnvToJSON(message.env);
462
- }
463
- if (message.vicinaePath !== "") {
464
- obj.vicinaePath = message.vicinaePath;
465
- }
466
- if (message.entrypoint !== "") {
467
- obj.entrypoint = message.entrypoint;
468
- }
469
- if (message.preferenceValues) {
470
- const entries = Object.entries(message.preferenceValues);
471
- if (entries.length > 0) {
472
- obj.preferenceValues = {};
473
- entries.forEach(([k, v]) => {
474
- obj.preferenceValues[k] = v;
475
- });
476
- }
477
- }
478
- if (message.argumentValues) {
479
- const entries = Object.entries(message.argumentValues);
480
- if (entries.length > 0) {
481
- obj.argumentValues = {};
482
- entries.forEach(([k, v]) => {
483
- obj.argumentValues[k] = v;
484
- });
485
- }
486
- }
487
- if (message.isRaycast !== false) {
488
- obj.isRaycast = message.isRaycast;
489
- }
490
- if (message.commandName !== "") {
491
- obj.commandName = message.commandName;
492
- }
493
- if (message.extensionId !== "") {
494
- obj.extensionId = message.extensionId;
495
- }
496
- if (message.extensionName !== "") {
497
- obj.extensionName = message.extensionName;
498
- }
499
- if (message.ownerOrAuthorName !== "") {
500
- obj.ownerOrAuthorName = message.ownerOrAuthorName;
501
- }
502
- return obj;
503
- },
504
- create(base) {
505
- return exports.ManagerLoadCommand.fromPartial(base ?? {});
506
- },
507
- fromPartial(object) {
508
- const message = createBaseManagerLoadCommand();
509
- message.mode = object.mode ?? 0;
510
- message.env = object.env ?? 0;
511
- message.vicinaePath = object.vicinaePath ?? "";
512
- message.entrypoint = object.entrypoint ?? "";
513
- message.preferenceValues = Object.entries(object.preferenceValues ?? {}).reduce((acc, [key, value]) => {
514
- if (value !== undefined) {
515
- acc[key] = value;
516
- }
517
- return acc;
518
- }, {});
519
- message.argumentValues = Object.entries(object.argumentValues ?? {}).reduce((acc, [key, value]) => {
520
- if (value !== undefined) {
521
- acc[key] = value;
522
- }
523
- return acc;
524
- }, {});
525
- message.isRaycast = object.isRaycast ?? false;
526
- message.commandName = object.commandName ?? "";
527
- message.extensionId = object.extensionId ?? "";
528
- message.extensionName = object.extensionName ?? "";
529
- message.ownerOrAuthorName = object.ownerOrAuthorName ?? "";
530
- return message;
531
- },
532
- };
533
- function createBaseManagerLoadCommand_PreferenceValuesEntry() {
534
- return { key: "", value: undefined };
535
- }
536
- exports.ManagerLoadCommand_PreferenceValuesEntry = {
537
- encode(message, writer = new wire_1.BinaryWriter()) {
538
- if (message.key !== "") {
539
- writer.uint32(10).string(message.key);
540
- }
541
- if (message.value !== undefined) {
542
- struct_1.Value.encode(struct_1.Value.wrap(message.value), writer.uint32(18).fork()).join();
543
- }
544
- return writer;
545
- },
546
- decode(input, length) {
547
- const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
548
- const end = length === undefined ? reader.len : reader.pos + length;
549
- const message = createBaseManagerLoadCommand_PreferenceValuesEntry();
550
- while (reader.pos < end) {
551
- const tag = reader.uint32();
552
- switch (tag >>> 3) {
553
- case 1: {
554
- if (tag !== 10) {
555
- break;
556
- }
557
- message.key = reader.string();
558
- continue;
559
- }
560
- case 2: {
561
- if (tag !== 18) {
562
- break;
563
- }
564
- message.value = struct_1.Value.unwrap(struct_1.Value.decode(reader, reader.uint32()));
565
- continue;
566
- }
567
- }
568
- if ((tag & 7) === 4 || tag === 0) {
569
- break;
570
- }
571
- reader.skip(tag & 7);
572
- }
573
- return message;
574
- },
575
- fromJSON(object) {
576
- return {
577
- key: isSet(object.key) ? globalThis.String(object.key) : "",
578
- value: isSet(object?.value) ? object.value : undefined,
579
- };
580
- },
581
- toJSON(message) {
582
- const obj = {};
583
- if (message.key !== "") {
584
- obj.key = message.key;
585
- }
586
- if (message.value !== undefined) {
587
- obj.value = message.value;
588
- }
589
- return obj;
590
- },
591
- create(base) {
592
- return exports.ManagerLoadCommand_PreferenceValuesEntry.fromPartial(base ?? {});
593
- },
594
- fromPartial(object) {
595
- const message = createBaseManagerLoadCommand_PreferenceValuesEntry();
596
- message.key = object.key ?? "";
597
- message.value = object.value ?? undefined;
598
- return message;
599
- },
600
- };
601
- function createBaseManagerLoadCommand_ArgumentValuesEntry() {
602
- return { key: "", value: undefined };
603
- }
604
- exports.ManagerLoadCommand_ArgumentValuesEntry = {
605
- encode(message, writer = new wire_1.BinaryWriter()) {
606
- if (message.key !== "") {
607
- writer.uint32(10).string(message.key);
608
- }
609
- if (message.value !== undefined) {
610
- struct_1.Value.encode(struct_1.Value.wrap(message.value), writer.uint32(18).fork()).join();
611
- }
612
- return writer;
613
- },
614
- decode(input, length) {
615
- const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
616
- const end = length === undefined ? reader.len : reader.pos + length;
617
- const message = createBaseManagerLoadCommand_ArgumentValuesEntry();
618
- while (reader.pos < end) {
619
- const tag = reader.uint32();
620
- switch (tag >>> 3) {
621
- case 1: {
622
- if (tag !== 10) {
623
- break;
624
- }
625
- message.key = reader.string();
626
- continue;
627
- }
628
- case 2: {
629
- if (tag !== 18) {
630
- break;
631
- }
632
- message.value = struct_1.Value.unwrap(struct_1.Value.decode(reader, reader.uint32()));
633
- continue;
634
- }
635
- }
636
- if ((tag & 7) === 4 || tag === 0) {
637
- break;
638
- }
639
- reader.skip(tag & 7);
640
- }
641
- return message;
642
- },
643
- fromJSON(object) {
644
- return {
645
- key: isSet(object.key) ? globalThis.String(object.key) : "",
646
- value: isSet(object?.value) ? object.value : undefined,
647
- };
648
- },
649
- toJSON(message) {
650
- const obj = {};
651
- if (message.key !== "") {
652
- obj.key = message.key;
653
- }
654
- if (message.value !== undefined) {
655
- obj.value = message.value;
656
- }
657
- return obj;
658
- },
659
- create(base) {
660
- return exports.ManagerLoadCommand_ArgumentValuesEntry.fromPartial(base ?? {});
661
- },
662
- fromPartial(object) {
663
- const message = createBaseManagerLoadCommand_ArgumentValuesEntry();
664
- message.key = object.key ?? "";
665
- message.value = object.value ?? undefined;
666
- return message;
667
- },
668
- };
669
- function createBaseManagerUnloadCommand() {
670
- return { sessionId: "" };
671
- }
672
- exports.ManagerUnloadCommand = {
673
- encode(message, writer = new wire_1.BinaryWriter()) {
674
- if (message.sessionId !== "") {
675
- writer.uint32(10).string(message.sessionId);
676
- }
677
- return writer;
678
- },
679
- decode(input, length) {
680
- const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
681
- const end = length === undefined ? reader.len : reader.pos + length;
682
- const message = createBaseManagerUnloadCommand();
683
- while (reader.pos < end) {
684
- const tag = reader.uint32();
685
- switch (tag >>> 3) {
686
- case 1: {
687
- if (tag !== 10) {
688
- break;
689
- }
690
- message.sessionId = reader.string();
691
- continue;
692
- }
693
- }
694
- if ((tag & 7) === 4 || tag === 0) {
695
- break;
696
- }
697
- reader.skip(tag & 7);
698
- }
699
- return message;
700
- },
701
- fromJSON(object) {
702
- return { sessionId: isSet(object.sessionId) ? globalThis.String(object.sessionId) : "" };
703
- },
704
- toJSON(message) {
705
- const obj = {};
706
- if (message.sessionId !== "") {
707
- obj.sessionId = message.sessionId;
708
- }
709
- return obj;
710
- },
711
- create(base) {
712
- return exports.ManagerUnloadCommand.fromPartial(base ?? {});
713
- },
714
- fromPartial(object) {
715
- const message = createBaseManagerUnloadCommand();
716
- message.sessionId = object.sessionId ?? "";
717
- return message;
718
- },
719
- };
720
- function createBaseManagerLoadResponseData() {
721
- return { sessionId: "" };
722
- }
723
- exports.ManagerLoadResponseData = {
724
- encode(message, writer = new wire_1.BinaryWriter()) {
725
- if (message.sessionId !== "") {
726
- writer.uint32(10).string(message.sessionId);
727
- }
728
- return writer;
729
- },
730
- decode(input, length) {
731
- const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
732
- const end = length === undefined ? reader.len : reader.pos + length;
733
- const message = createBaseManagerLoadResponseData();
734
- while (reader.pos < end) {
735
- const tag = reader.uint32();
736
- switch (tag >>> 3) {
737
- case 1: {
738
- if (tag !== 10) {
739
- break;
740
- }
741
- message.sessionId = reader.string();
742
- continue;
743
- }
744
- }
745
- if ((tag & 7) === 4 || tag === 0) {
746
- break;
747
- }
748
- reader.skip(tag & 7);
749
- }
750
- return message;
751
- },
752
- fromJSON(object) {
753
- return { sessionId: isSet(object.sessionId) ? globalThis.String(object.sessionId) : "" };
754
- },
755
- toJSON(message) {
756
- const obj = {};
757
- if (message.sessionId !== "") {
758
- obj.sessionId = message.sessionId;
759
- }
760
- return obj;
761
- },
762
- create(base) {
763
- return exports.ManagerLoadResponseData.fromPartial(base ?? {});
764
- },
765
- fromPartial(object) {
766
- const message = createBaseManagerLoadResponseData();
767
- message.sessionId = object.sessionId ?? "";
768
- return message;
769
- },
770
- };
771
- function isObject(value) {
772
- return typeof value === "object" && value !== null;
773
- }
774
- function isSet(value) {
775
- return value !== null && value !== undefined;
776
- }