theragist-ts 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/auth/message.d.ts +242 -0
- package/dist/auth/message.js +2980 -0
- package/dist/auth/service.d.ts +239 -0
- package/dist/auth/service.js +963 -0
- package/dist/booking/message.d.ts +109 -0
- package/dist/booking/message.js +1263 -0
- package/dist/booking/service.d.ts +69 -0
- package/dist/booking/service.js +230 -0
- package/dist/common.d.ts +81 -0
- package/dist/common.js +641 -0
- package/dist/community/message.d.ts +67 -0
- package/dist/community/message.js +646 -0
- package/dist/community/service.d.ts +57 -0
- package/dist/community/service.js +213 -0
- package/dist/google/api/annotations.d.ts +1 -0
- package/dist/google/api/annotations.js +10 -0
- package/dist/google/api/http.d.ts +371 -0
- package/dist/google/api/http.js +360 -0
- package/dist/google/protobuf/descriptor.d.ts +884 -0
- package/dist/google/protobuf/descriptor.js +3595 -0
- package/dist/google/protobuf/struct.d.ts +107 -0
- package/dist/google/protobuf/struct.js +461 -0
- package/dist/index.d.ts +16 -0
- package/dist/index.js +192 -0
- package/dist/lookup/message.d.ts +128 -0
- package/dist/lookup/message.js +1498 -0
- package/dist/lookup/service.d.ts +93 -0
- package/dist/lookup/service.js +334 -0
- package/dist/therapist/message.d.ts +67 -0
- package/dist/therapist/message.js +679 -0
- package/dist/therapist/service.d.ts +47 -0
- package/dist/therapist/service.js +159 -0
- package/dist/user/message.d.ts +114 -0
- package/dist/user/message.js +1342 -0
- package/dist/user/service.d.ts +172 -0
- package/dist/user/service.js +1041 -0
- package/package.json +43 -0
|
@@ -0,0 +1,1041 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.10.1
|
|
5
|
+
// protoc v3.21.12
|
|
6
|
+
// source: user/service.proto
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.UserServiceDefinition = exports.RevokeSessionRequest = exports.ListSessionsResponse = exports.ChangePasswordRequest = exports.UpdateAvatarResponse = exports.UpdateAvatarRequest = exports.UpdateUserRequest = exports.protobufPackage = void 0;
|
|
9
|
+
/* eslint-disable */
|
|
10
|
+
const wire_1 = require("@bufbuild/protobuf/wire");
|
|
11
|
+
const common_1 = require("../common");
|
|
12
|
+
const message_1 = require("./message");
|
|
13
|
+
exports.protobufPackage = "pb";
|
|
14
|
+
function createBaseUpdateUserRequest() {
|
|
15
|
+
return {
|
|
16
|
+
fullName: undefined,
|
|
17
|
+
phoneNumber: undefined,
|
|
18
|
+
bio: undefined,
|
|
19
|
+
timeZone: undefined,
|
|
20
|
+
language: undefined,
|
|
21
|
+
preferences: undefined,
|
|
22
|
+
email: undefined,
|
|
23
|
+
username: undefined,
|
|
24
|
+
gender: undefined,
|
|
25
|
+
pronouns: undefined,
|
|
26
|
+
birthday: undefined,
|
|
27
|
+
specialties: [],
|
|
28
|
+
modalities: [],
|
|
29
|
+
experienceLevelId: undefined,
|
|
30
|
+
licenseNumber: undefined,
|
|
31
|
+
licenseState: undefined,
|
|
32
|
+
education: undefined,
|
|
33
|
+
languages: [],
|
|
34
|
+
sessionPrice: undefined,
|
|
35
|
+
location: undefined,
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
exports.UpdateUserRequest = {
|
|
39
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
40
|
+
if (message.fullName !== undefined) {
|
|
41
|
+
writer.uint32(10).string(message.fullName);
|
|
42
|
+
}
|
|
43
|
+
if (message.phoneNumber !== undefined) {
|
|
44
|
+
writer.uint32(18).string(message.phoneNumber);
|
|
45
|
+
}
|
|
46
|
+
if (message.bio !== undefined) {
|
|
47
|
+
writer.uint32(26).string(message.bio);
|
|
48
|
+
}
|
|
49
|
+
if (message.timeZone !== undefined) {
|
|
50
|
+
writer.uint32(34).string(message.timeZone);
|
|
51
|
+
}
|
|
52
|
+
if (message.language !== undefined) {
|
|
53
|
+
writer.uint32(42).string(message.language);
|
|
54
|
+
}
|
|
55
|
+
if (message.preferences !== undefined) {
|
|
56
|
+
message_1.UserPreferences.encode(message.preferences, writer.uint32(50).fork()).join();
|
|
57
|
+
}
|
|
58
|
+
if (message.email !== undefined) {
|
|
59
|
+
writer.uint32(58).string(message.email);
|
|
60
|
+
}
|
|
61
|
+
if (message.username !== undefined) {
|
|
62
|
+
writer.uint32(66).string(message.username);
|
|
63
|
+
}
|
|
64
|
+
if (message.gender !== undefined) {
|
|
65
|
+
writer.uint32(74).string(message.gender);
|
|
66
|
+
}
|
|
67
|
+
if (message.pronouns !== undefined) {
|
|
68
|
+
writer.uint32(82).string(message.pronouns);
|
|
69
|
+
}
|
|
70
|
+
if (message.birthday !== undefined) {
|
|
71
|
+
writer.uint32(90).string(message.birthday);
|
|
72
|
+
}
|
|
73
|
+
for (const v of message.specialties) {
|
|
74
|
+
writer.uint32(98).string(v);
|
|
75
|
+
}
|
|
76
|
+
for (const v of message.modalities) {
|
|
77
|
+
writer.uint32(106).string(v);
|
|
78
|
+
}
|
|
79
|
+
if (message.experienceLevelId !== undefined) {
|
|
80
|
+
writer.uint32(114).string(message.experienceLevelId);
|
|
81
|
+
}
|
|
82
|
+
if (message.licenseNumber !== undefined) {
|
|
83
|
+
writer.uint32(122).string(message.licenseNumber);
|
|
84
|
+
}
|
|
85
|
+
if (message.licenseState !== undefined) {
|
|
86
|
+
writer.uint32(130).string(message.licenseState);
|
|
87
|
+
}
|
|
88
|
+
if (message.education !== undefined) {
|
|
89
|
+
writer.uint32(138).string(message.education);
|
|
90
|
+
}
|
|
91
|
+
for (const v of message.languages) {
|
|
92
|
+
writer.uint32(146).string(v);
|
|
93
|
+
}
|
|
94
|
+
if (message.sessionPrice !== undefined) {
|
|
95
|
+
message_1.SessionPrice.encode(message.sessionPrice, writer.uint32(154).fork()).join();
|
|
96
|
+
}
|
|
97
|
+
if (message.location !== undefined) {
|
|
98
|
+
message_1.Location.encode(message.location, writer.uint32(162).fork()).join();
|
|
99
|
+
}
|
|
100
|
+
return writer;
|
|
101
|
+
},
|
|
102
|
+
decode(input, length) {
|
|
103
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
104
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
105
|
+
const message = createBaseUpdateUserRequest();
|
|
106
|
+
while (reader.pos < end) {
|
|
107
|
+
const tag = reader.uint32();
|
|
108
|
+
switch (tag >>> 3) {
|
|
109
|
+
case 1: {
|
|
110
|
+
if (tag !== 10) {
|
|
111
|
+
break;
|
|
112
|
+
}
|
|
113
|
+
message.fullName = reader.string();
|
|
114
|
+
continue;
|
|
115
|
+
}
|
|
116
|
+
case 2: {
|
|
117
|
+
if (tag !== 18) {
|
|
118
|
+
break;
|
|
119
|
+
}
|
|
120
|
+
message.phoneNumber = reader.string();
|
|
121
|
+
continue;
|
|
122
|
+
}
|
|
123
|
+
case 3: {
|
|
124
|
+
if (tag !== 26) {
|
|
125
|
+
break;
|
|
126
|
+
}
|
|
127
|
+
message.bio = reader.string();
|
|
128
|
+
continue;
|
|
129
|
+
}
|
|
130
|
+
case 4: {
|
|
131
|
+
if (tag !== 34) {
|
|
132
|
+
break;
|
|
133
|
+
}
|
|
134
|
+
message.timeZone = reader.string();
|
|
135
|
+
continue;
|
|
136
|
+
}
|
|
137
|
+
case 5: {
|
|
138
|
+
if (tag !== 42) {
|
|
139
|
+
break;
|
|
140
|
+
}
|
|
141
|
+
message.language = reader.string();
|
|
142
|
+
continue;
|
|
143
|
+
}
|
|
144
|
+
case 6: {
|
|
145
|
+
if (tag !== 50) {
|
|
146
|
+
break;
|
|
147
|
+
}
|
|
148
|
+
message.preferences = message_1.UserPreferences.decode(reader, reader.uint32());
|
|
149
|
+
continue;
|
|
150
|
+
}
|
|
151
|
+
case 7: {
|
|
152
|
+
if (tag !== 58) {
|
|
153
|
+
break;
|
|
154
|
+
}
|
|
155
|
+
message.email = reader.string();
|
|
156
|
+
continue;
|
|
157
|
+
}
|
|
158
|
+
case 8: {
|
|
159
|
+
if (tag !== 66) {
|
|
160
|
+
break;
|
|
161
|
+
}
|
|
162
|
+
message.username = reader.string();
|
|
163
|
+
continue;
|
|
164
|
+
}
|
|
165
|
+
case 9: {
|
|
166
|
+
if (tag !== 74) {
|
|
167
|
+
break;
|
|
168
|
+
}
|
|
169
|
+
message.gender = reader.string();
|
|
170
|
+
continue;
|
|
171
|
+
}
|
|
172
|
+
case 10: {
|
|
173
|
+
if (tag !== 82) {
|
|
174
|
+
break;
|
|
175
|
+
}
|
|
176
|
+
message.pronouns = reader.string();
|
|
177
|
+
continue;
|
|
178
|
+
}
|
|
179
|
+
case 11: {
|
|
180
|
+
if (tag !== 90) {
|
|
181
|
+
break;
|
|
182
|
+
}
|
|
183
|
+
message.birthday = reader.string();
|
|
184
|
+
continue;
|
|
185
|
+
}
|
|
186
|
+
case 12: {
|
|
187
|
+
if (tag !== 98) {
|
|
188
|
+
break;
|
|
189
|
+
}
|
|
190
|
+
message.specialties.push(reader.string());
|
|
191
|
+
continue;
|
|
192
|
+
}
|
|
193
|
+
case 13: {
|
|
194
|
+
if (tag !== 106) {
|
|
195
|
+
break;
|
|
196
|
+
}
|
|
197
|
+
message.modalities.push(reader.string());
|
|
198
|
+
continue;
|
|
199
|
+
}
|
|
200
|
+
case 14: {
|
|
201
|
+
if (tag !== 114) {
|
|
202
|
+
break;
|
|
203
|
+
}
|
|
204
|
+
message.experienceLevelId = reader.string();
|
|
205
|
+
continue;
|
|
206
|
+
}
|
|
207
|
+
case 15: {
|
|
208
|
+
if (tag !== 122) {
|
|
209
|
+
break;
|
|
210
|
+
}
|
|
211
|
+
message.licenseNumber = reader.string();
|
|
212
|
+
continue;
|
|
213
|
+
}
|
|
214
|
+
case 16: {
|
|
215
|
+
if (tag !== 130) {
|
|
216
|
+
break;
|
|
217
|
+
}
|
|
218
|
+
message.licenseState = reader.string();
|
|
219
|
+
continue;
|
|
220
|
+
}
|
|
221
|
+
case 17: {
|
|
222
|
+
if (tag !== 138) {
|
|
223
|
+
break;
|
|
224
|
+
}
|
|
225
|
+
message.education = reader.string();
|
|
226
|
+
continue;
|
|
227
|
+
}
|
|
228
|
+
case 18: {
|
|
229
|
+
if (tag !== 146) {
|
|
230
|
+
break;
|
|
231
|
+
}
|
|
232
|
+
message.languages.push(reader.string());
|
|
233
|
+
continue;
|
|
234
|
+
}
|
|
235
|
+
case 19: {
|
|
236
|
+
if (tag !== 154) {
|
|
237
|
+
break;
|
|
238
|
+
}
|
|
239
|
+
message.sessionPrice = message_1.SessionPrice.decode(reader, reader.uint32());
|
|
240
|
+
continue;
|
|
241
|
+
}
|
|
242
|
+
case 20: {
|
|
243
|
+
if (tag !== 162) {
|
|
244
|
+
break;
|
|
245
|
+
}
|
|
246
|
+
message.location = message_1.Location.decode(reader, reader.uint32());
|
|
247
|
+
continue;
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
251
|
+
break;
|
|
252
|
+
}
|
|
253
|
+
reader.skip(tag & 7);
|
|
254
|
+
}
|
|
255
|
+
return message;
|
|
256
|
+
},
|
|
257
|
+
fromJSON(object) {
|
|
258
|
+
return {
|
|
259
|
+
fullName: isSet(object.fullName) ? globalThis.String(object.fullName) : undefined,
|
|
260
|
+
phoneNumber: isSet(object.phoneNumber) ? globalThis.String(object.phoneNumber) : undefined,
|
|
261
|
+
bio: isSet(object.bio) ? globalThis.String(object.bio) : undefined,
|
|
262
|
+
timeZone: isSet(object.timeZone) ? globalThis.String(object.timeZone) : undefined,
|
|
263
|
+
language: isSet(object.language) ? globalThis.String(object.language) : undefined,
|
|
264
|
+
preferences: isSet(object.preferences) ? message_1.UserPreferences.fromJSON(object.preferences) : undefined,
|
|
265
|
+
email: isSet(object.email) ? globalThis.String(object.email) : undefined,
|
|
266
|
+
username: isSet(object.username) ? globalThis.String(object.username) : undefined,
|
|
267
|
+
gender: isSet(object.gender) ? globalThis.String(object.gender) : undefined,
|
|
268
|
+
pronouns: isSet(object.pronouns) ? globalThis.String(object.pronouns) : undefined,
|
|
269
|
+
birthday: isSet(object.birthday) ? globalThis.String(object.birthday) : undefined,
|
|
270
|
+
specialties: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.specialties)
|
|
271
|
+
? object.specialties.map((e) => globalThis.String(e))
|
|
272
|
+
: [],
|
|
273
|
+
modalities: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.modalities)
|
|
274
|
+
? object.modalities.map((e) => globalThis.String(e))
|
|
275
|
+
: [],
|
|
276
|
+
experienceLevelId: isSet(object.experienceLevelId) ? globalThis.String(object.experienceLevelId) : undefined,
|
|
277
|
+
licenseNumber: isSet(object.licenseNumber) ? globalThis.String(object.licenseNumber) : undefined,
|
|
278
|
+
licenseState: isSet(object.licenseState) ? globalThis.String(object.licenseState) : undefined,
|
|
279
|
+
education: isSet(object.education) ? globalThis.String(object.education) : undefined,
|
|
280
|
+
languages: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.languages)
|
|
281
|
+
? object.languages.map((e) => globalThis.String(e))
|
|
282
|
+
: [],
|
|
283
|
+
sessionPrice: isSet(object.sessionPrice) ? message_1.SessionPrice.fromJSON(object.sessionPrice) : undefined,
|
|
284
|
+
location: isSet(object.location) ? message_1.Location.fromJSON(object.location) : undefined,
|
|
285
|
+
};
|
|
286
|
+
},
|
|
287
|
+
toJSON(message) {
|
|
288
|
+
var _a, _b, _c;
|
|
289
|
+
const obj = {};
|
|
290
|
+
if (message.fullName !== undefined) {
|
|
291
|
+
obj.fullName = message.fullName;
|
|
292
|
+
}
|
|
293
|
+
if (message.phoneNumber !== undefined) {
|
|
294
|
+
obj.phoneNumber = message.phoneNumber;
|
|
295
|
+
}
|
|
296
|
+
if (message.bio !== undefined) {
|
|
297
|
+
obj.bio = message.bio;
|
|
298
|
+
}
|
|
299
|
+
if (message.timeZone !== undefined) {
|
|
300
|
+
obj.timeZone = message.timeZone;
|
|
301
|
+
}
|
|
302
|
+
if (message.language !== undefined) {
|
|
303
|
+
obj.language = message.language;
|
|
304
|
+
}
|
|
305
|
+
if (message.preferences !== undefined) {
|
|
306
|
+
obj.preferences = message_1.UserPreferences.toJSON(message.preferences);
|
|
307
|
+
}
|
|
308
|
+
if (message.email !== undefined) {
|
|
309
|
+
obj.email = message.email;
|
|
310
|
+
}
|
|
311
|
+
if (message.username !== undefined) {
|
|
312
|
+
obj.username = message.username;
|
|
313
|
+
}
|
|
314
|
+
if (message.gender !== undefined) {
|
|
315
|
+
obj.gender = message.gender;
|
|
316
|
+
}
|
|
317
|
+
if (message.pronouns !== undefined) {
|
|
318
|
+
obj.pronouns = message.pronouns;
|
|
319
|
+
}
|
|
320
|
+
if (message.birthday !== undefined) {
|
|
321
|
+
obj.birthday = message.birthday;
|
|
322
|
+
}
|
|
323
|
+
if ((_a = message.specialties) === null || _a === void 0 ? void 0 : _a.length) {
|
|
324
|
+
obj.specialties = message.specialties;
|
|
325
|
+
}
|
|
326
|
+
if ((_b = message.modalities) === null || _b === void 0 ? void 0 : _b.length) {
|
|
327
|
+
obj.modalities = message.modalities;
|
|
328
|
+
}
|
|
329
|
+
if (message.experienceLevelId !== undefined) {
|
|
330
|
+
obj.experienceLevelId = message.experienceLevelId;
|
|
331
|
+
}
|
|
332
|
+
if (message.licenseNumber !== undefined) {
|
|
333
|
+
obj.licenseNumber = message.licenseNumber;
|
|
334
|
+
}
|
|
335
|
+
if (message.licenseState !== undefined) {
|
|
336
|
+
obj.licenseState = message.licenseState;
|
|
337
|
+
}
|
|
338
|
+
if (message.education !== undefined) {
|
|
339
|
+
obj.education = message.education;
|
|
340
|
+
}
|
|
341
|
+
if ((_c = message.languages) === null || _c === void 0 ? void 0 : _c.length) {
|
|
342
|
+
obj.languages = message.languages;
|
|
343
|
+
}
|
|
344
|
+
if (message.sessionPrice !== undefined) {
|
|
345
|
+
obj.sessionPrice = message_1.SessionPrice.toJSON(message.sessionPrice);
|
|
346
|
+
}
|
|
347
|
+
if (message.location !== undefined) {
|
|
348
|
+
obj.location = message_1.Location.toJSON(message.location);
|
|
349
|
+
}
|
|
350
|
+
return obj;
|
|
351
|
+
},
|
|
352
|
+
create(base) {
|
|
353
|
+
return exports.UpdateUserRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
354
|
+
},
|
|
355
|
+
fromPartial(object) {
|
|
356
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
|
|
357
|
+
const message = createBaseUpdateUserRequest();
|
|
358
|
+
message.fullName = (_a = object.fullName) !== null && _a !== void 0 ? _a : undefined;
|
|
359
|
+
message.phoneNumber = (_b = object.phoneNumber) !== null && _b !== void 0 ? _b : undefined;
|
|
360
|
+
message.bio = (_c = object.bio) !== null && _c !== void 0 ? _c : undefined;
|
|
361
|
+
message.timeZone = (_d = object.timeZone) !== null && _d !== void 0 ? _d : undefined;
|
|
362
|
+
message.language = (_e = object.language) !== null && _e !== void 0 ? _e : undefined;
|
|
363
|
+
message.preferences = (object.preferences !== undefined && object.preferences !== null)
|
|
364
|
+
? message_1.UserPreferences.fromPartial(object.preferences)
|
|
365
|
+
: undefined;
|
|
366
|
+
message.email = (_f = object.email) !== null && _f !== void 0 ? _f : undefined;
|
|
367
|
+
message.username = (_g = object.username) !== null && _g !== void 0 ? _g : undefined;
|
|
368
|
+
message.gender = (_h = object.gender) !== null && _h !== void 0 ? _h : undefined;
|
|
369
|
+
message.pronouns = (_j = object.pronouns) !== null && _j !== void 0 ? _j : undefined;
|
|
370
|
+
message.birthday = (_k = object.birthday) !== null && _k !== void 0 ? _k : undefined;
|
|
371
|
+
message.specialties = ((_l = object.specialties) === null || _l === void 0 ? void 0 : _l.map((e) => e)) || [];
|
|
372
|
+
message.modalities = ((_m = object.modalities) === null || _m === void 0 ? void 0 : _m.map((e) => e)) || [];
|
|
373
|
+
message.experienceLevelId = (_o = object.experienceLevelId) !== null && _o !== void 0 ? _o : undefined;
|
|
374
|
+
message.licenseNumber = (_p = object.licenseNumber) !== null && _p !== void 0 ? _p : undefined;
|
|
375
|
+
message.licenseState = (_q = object.licenseState) !== null && _q !== void 0 ? _q : undefined;
|
|
376
|
+
message.education = (_r = object.education) !== null && _r !== void 0 ? _r : undefined;
|
|
377
|
+
message.languages = ((_s = object.languages) === null || _s === void 0 ? void 0 : _s.map((e) => e)) || [];
|
|
378
|
+
message.sessionPrice = (object.sessionPrice !== undefined && object.sessionPrice !== null)
|
|
379
|
+
? message_1.SessionPrice.fromPartial(object.sessionPrice)
|
|
380
|
+
: undefined;
|
|
381
|
+
message.location = (object.location !== undefined && object.location !== null)
|
|
382
|
+
? message_1.Location.fromPartial(object.location)
|
|
383
|
+
: undefined;
|
|
384
|
+
return message;
|
|
385
|
+
},
|
|
386
|
+
};
|
|
387
|
+
function createBaseUpdateAvatarRequest() {
|
|
388
|
+
return { avatarData: new Uint8Array(0), contentType: "" };
|
|
389
|
+
}
|
|
390
|
+
exports.UpdateAvatarRequest = {
|
|
391
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
392
|
+
if (message.avatarData.length !== 0) {
|
|
393
|
+
writer.uint32(10).bytes(message.avatarData);
|
|
394
|
+
}
|
|
395
|
+
if (message.contentType !== "") {
|
|
396
|
+
writer.uint32(18).string(message.contentType);
|
|
397
|
+
}
|
|
398
|
+
return writer;
|
|
399
|
+
},
|
|
400
|
+
decode(input, length) {
|
|
401
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
402
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
403
|
+
const message = createBaseUpdateAvatarRequest();
|
|
404
|
+
while (reader.pos < end) {
|
|
405
|
+
const tag = reader.uint32();
|
|
406
|
+
switch (tag >>> 3) {
|
|
407
|
+
case 1: {
|
|
408
|
+
if (tag !== 10) {
|
|
409
|
+
break;
|
|
410
|
+
}
|
|
411
|
+
message.avatarData = reader.bytes();
|
|
412
|
+
continue;
|
|
413
|
+
}
|
|
414
|
+
case 2: {
|
|
415
|
+
if (tag !== 18) {
|
|
416
|
+
break;
|
|
417
|
+
}
|
|
418
|
+
message.contentType = reader.string();
|
|
419
|
+
continue;
|
|
420
|
+
}
|
|
421
|
+
}
|
|
422
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
423
|
+
break;
|
|
424
|
+
}
|
|
425
|
+
reader.skip(tag & 7);
|
|
426
|
+
}
|
|
427
|
+
return message;
|
|
428
|
+
},
|
|
429
|
+
fromJSON(object) {
|
|
430
|
+
return {
|
|
431
|
+
avatarData: isSet(object.avatarData) ? bytesFromBase64(object.avatarData) : new Uint8Array(0),
|
|
432
|
+
contentType: isSet(object.contentType) ? globalThis.String(object.contentType) : "",
|
|
433
|
+
};
|
|
434
|
+
},
|
|
435
|
+
toJSON(message) {
|
|
436
|
+
const obj = {};
|
|
437
|
+
if (message.avatarData.length !== 0) {
|
|
438
|
+
obj.avatarData = base64FromBytes(message.avatarData);
|
|
439
|
+
}
|
|
440
|
+
if (message.contentType !== "") {
|
|
441
|
+
obj.contentType = message.contentType;
|
|
442
|
+
}
|
|
443
|
+
return obj;
|
|
444
|
+
},
|
|
445
|
+
create(base) {
|
|
446
|
+
return exports.UpdateAvatarRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
447
|
+
},
|
|
448
|
+
fromPartial(object) {
|
|
449
|
+
var _a, _b;
|
|
450
|
+
const message = createBaseUpdateAvatarRequest();
|
|
451
|
+
message.avatarData = (_a = object.avatarData) !== null && _a !== void 0 ? _a : new Uint8Array(0);
|
|
452
|
+
message.contentType = (_b = object.contentType) !== null && _b !== void 0 ? _b : "";
|
|
453
|
+
return message;
|
|
454
|
+
},
|
|
455
|
+
};
|
|
456
|
+
function createBaseUpdateAvatarResponse() {
|
|
457
|
+
return { userId: "", avatarUrl: "" };
|
|
458
|
+
}
|
|
459
|
+
exports.UpdateAvatarResponse = {
|
|
460
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
461
|
+
if (message.userId !== "") {
|
|
462
|
+
writer.uint32(10).string(message.userId);
|
|
463
|
+
}
|
|
464
|
+
if (message.avatarUrl !== "") {
|
|
465
|
+
writer.uint32(18).string(message.avatarUrl);
|
|
466
|
+
}
|
|
467
|
+
return writer;
|
|
468
|
+
},
|
|
469
|
+
decode(input, length) {
|
|
470
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
471
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
472
|
+
const message = createBaseUpdateAvatarResponse();
|
|
473
|
+
while (reader.pos < end) {
|
|
474
|
+
const tag = reader.uint32();
|
|
475
|
+
switch (tag >>> 3) {
|
|
476
|
+
case 1: {
|
|
477
|
+
if (tag !== 10) {
|
|
478
|
+
break;
|
|
479
|
+
}
|
|
480
|
+
message.userId = reader.string();
|
|
481
|
+
continue;
|
|
482
|
+
}
|
|
483
|
+
case 2: {
|
|
484
|
+
if (tag !== 18) {
|
|
485
|
+
break;
|
|
486
|
+
}
|
|
487
|
+
message.avatarUrl = reader.string();
|
|
488
|
+
continue;
|
|
489
|
+
}
|
|
490
|
+
}
|
|
491
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
492
|
+
break;
|
|
493
|
+
}
|
|
494
|
+
reader.skip(tag & 7);
|
|
495
|
+
}
|
|
496
|
+
return message;
|
|
497
|
+
},
|
|
498
|
+
fromJSON(object) {
|
|
499
|
+
return {
|
|
500
|
+
userId: isSet(object.userId) ? globalThis.String(object.userId) : "",
|
|
501
|
+
avatarUrl: isSet(object.avatarUrl) ? globalThis.String(object.avatarUrl) : "",
|
|
502
|
+
};
|
|
503
|
+
},
|
|
504
|
+
toJSON(message) {
|
|
505
|
+
const obj = {};
|
|
506
|
+
if (message.userId !== "") {
|
|
507
|
+
obj.userId = message.userId;
|
|
508
|
+
}
|
|
509
|
+
if (message.avatarUrl !== "") {
|
|
510
|
+
obj.avatarUrl = message.avatarUrl;
|
|
511
|
+
}
|
|
512
|
+
return obj;
|
|
513
|
+
},
|
|
514
|
+
create(base) {
|
|
515
|
+
return exports.UpdateAvatarResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
516
|
+
},
|
|
517
|
+
fromPartial(object) {
|
|
518
|
+
var _a, _b;
|
|
519
|
+
const message = createBaseUpdateAvatarResponse();
|
|
520
|
+
message.userId = (_a = object.userId) !== null && _a !== void 0 ? _a : "";
|
|
521
|
+
message.avatarUrl = (_b = object.avatarUrl) !== null && _b !== void 0 ? _b : "";
|
|
522
|
+
return message;
|
|
523
|
+
},
|
|
524
|
+
};
|
|
525
|
+
function createBaseChangePasswordRequest() {
|
|
526
|
+
return { currentPassword: "", newPassword: "" };
|
|
527
|
+
}
|
|
528
|
+
exports.ChangePasswordRequest = {
|
|
529
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
530
|
+
if (message.currentPassword !== "") {
|
|
531
|
+
writer.uint32(10).string(message.currentPassword);
|
|
532
|
+
}
|
|
533
|
+
if (message.newPassword !== "") {
|
|
534
|
+
writer.uint32(18).string(message.newPassword);
|
|
535
|
+
}
|
|
536
|
+
return writer;
|
|
537
|
+
},
|
|
538
|
+
decode(input, length) {
|
|
539
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
540
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
541
|
+
const message = createBaseChangePasswordRequest();
|
|
542
|
+
while (reader.pos < end) {
|
|
543
|
+
const tag = reader.uint32();
|
|
544
|
+
switch (tag >>> 3) {
|
|
545
|
+
case 1: {
|
|
546
|
+
if (tag !== 10) {
|
|
547
|
+
break;
|
|
548
|
+
}
|
|
549
|
+
message.currentPassword = reader.string();
|
|
550
|
+
continue;
|
|
551
|
+
}
|
|
552
|
+
case 2: {
|
|
553
|
+
if (tag !== 18) {
|
|
554
|
+
break;
|
|
555
|
+
}
|
|
556
|
+
message.newPassword = reader.string();
|
|
557
|
+
continue;
|
|
558
|
+
}
|
|
559
|
+
}
|
|
560
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
561
|
+
break;
|
|
562
|
+
}
|
|
563
|
+
reader.skip(tag & 7);
|
|
564
|
+
}
|
|
565
|
+
return message;
|
|
566
|
+
},
|
|
567
|
+
fromJSON(object) {
|
|
568
|
+
return {
|
|
569
|
+
currentPassword: isSet(object.currentPassword) ? globalThis.String(object.currentPassword) : "",
|
|
570
|
+
newPassword: isSet(object.newPassword) ? globalThis.String(object.newPassword) : "",
|
|
571
|
+
};
|
|
572
|
+
},
|
|
573
|
+
toJSON(message) {
|
|
574
|
+
const obj = {};
|
|
575
|
+
if (message.currentPassword !== "") {
|
|
576
|
+
obj.currentPassword = message.currentPassword;
|
|
577
|
+
}
|
|
578
|
+
if (message.newPassword !== "") {
|
|
579
|
+
obj.newPassword = message.newPassword;
|
|
580
|
+
}
|
|
581
|
+
return obj;
|
|
582
|
+
},
|
|
583
|
+
create(base) {
|
|
584
|
+
return exports.ChangePasswordRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
585
|
+
},
|
|
586
|
+
fromPartial(object) {
|
|
587
|
+
var _a, _b;
|
|
588
|
+
const message = createBaseChangePasswordRequest();
|
|
589
|
+
message.currentPassword = (_a = object.currentPassword) !== null && _a !== void 0 ? _a : "";
|
|
590
|
+
message.newPassword = (_b = object.newPassword) !== null && _b !== void 0 ? _b : "";
|
|
591
|
+
return message;
|
|
592
|
+
},
|
|
593
|
+
};
|
|
594
|
+
function createBaseListSessionsResponse() {
|
|
595
|
+
return { sessions: [] };
|
|
596
|
+
}
|
|
597
|
+
exports.ListSessionsResponse = {
|
|
598
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
599
|
+
for (const v of message.sessions) {
|
|
600
|
+
message_1.SessionInfo.encode(v, writer.uint32(10).fork()).join();
|
|
601
|
+
}
|
|
602
|
+
return writer;
|
|
603
|
+
},
|
|
604
|
+
decode(input, length) {
|
|
605
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
606
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
607
|
+
const message = createBaseListSessionsResponse();
|
|
608
|
+
while (reader.pos < end) {
|
|
609
|
+
const tag = reader.uint32();
|
|
610
|
+
switch (tag >>> 3) {
|
|
611
|
+
case 1: {
|
|
612
|
+
if (tag !== 10) {
|
|
613
|
+
break;
|
|
614
|
+
}
|
|
615
|
+
message.sessions.push(message_1.SessionInfo.decode(reader, reader.uint32()));
|
|
616
|
+
continue;
|
|
617
|
+
}
|
|
618
|
+
}
|
|
619
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
620
|
+
break;
|
|
621
|
+
}
|
|
622
|
+
reader.skip(tag & 7);
|
|
623
|
+
}
|
|
624
|
+
return message;
|
|
625
|
+
},
|
|
626
|
+
fromJSON(object) {
|
|
627
|
+
return {
|
|
628
|
+
sessions: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.sessions)
|
|
629
|
+
? object.sessions.map((e) => message_1.SessionInfo.fromJSON(e))
|
|
630
|
+
: [],
|
|
631
|
+
};
|
|
632
|
+
},
|
|
633
|
+
toJSON(message) {
|
|
634
|
+
var _a;
|
|
635
|
+
const obj = {};
|
|
636
|
+
if ((_a = message.sessions) === null || _a === void 0 ? void 0 : _a.length) {
|
|
637
|
+
obj.sessions = message.sessions.map((e) => message_1.SessionInfo.toJSON(e));
|
|
638
|
+
}
|
|
639
|
+
return obj;
|
|
640
|
+
},
|
|
641
|
+
create(base) {
|
|
642
|
+
return exports.ListSessionsResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
643
|
+
},
|
|
644
|
+
fromPartial(object) {
|
|
645
|
+
var _a;
|
|
646
|
+
const message = createBaseListSessionsResponse();
|
|
647
|
+
message.sessions = ((_a = object.sessions) === null || _a === void 0 ? void 0 : _a.map((e) => message_1.SessionInfo.fromPartial(e))) || [];
|
|
648
|
+
return message;
|
|
649
|
+
},
|
|
650
|
+
};
|
|
651
|
+
function createBaseRevokeSessionRequest() {
|
|
652
|
+
return { sessionId: "" };
|
|
653
|
+
}
|
|
654
|
+
exports.RevokeSessionRequest = {
|
|
655
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
656
|
+
if (message.sessionId !== "") {
|
|
657
|
+
writer.uint32(10).string(message.sessionId);
|
|
658
|
+
}
|
|
659
|
+
return writer;
|
|
660
|
+
},
|
|
661
|
+
decode(input, length) {
|
|
662
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
663
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
664
|
+
const message = createBaseRevokeSessionRequest();
|
|
665
|
+
while (reader.pos < end) {
|
|
666
|
+
const tag = reader.uint32();
|
|
667
|
+
switch (tag >>> 3) {
|
|
668
|
+
case 1: {
|
|
669
|
+
if (tag !== 10) {
|
|
670
|
+
break;
|
|
671
|
+
}
|
|
672
|
+
message.sessionId = reader.string();
|
|
673
|
+
continue;
|
|
674
|
+
}
|
|
675
|
+
}
|
|
676
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
677
|
+
break;
|
|
678
|
+
}
|
|
679
|
+
reader.skip(tag & 7);
|
|
680
|
+
}
|
|
681
|
+
return message;
|
|
682
|
+
},
|
|
683
|
+
fromJSON(object) {
|
|
684
|
+
return { sessionId: isSet(object.sessionId) ? globalThis.String(object.sessionId) : "" };
|
|
685
|
+
},
|
|
686
|
+
toJSON(message) {
|
|
687
|
+
const obj = {};
|
|
688
|
+
if (message.sessionId !== "") {
|
|
689
|
+
obj.sessionId = message.sessionId;
|
|
690
|
+
}
|
|
691
|
+
return obj;
|
|
692
|
+
},
|
|
693
|
+
create(base) {
|
|
694
|
+
return exports.RevokeSessionRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
695
|
+
},
|
|
696
|
+
fromPartial(object) {
|
|
697
|
+
var _a;
|
|
698
|
+
const message = createBaseRevokeSessionRequest();
|
|
699
|
+
message.sessionId = (_a = object.sessionId) !== null && _a !== void 0 ? _a : "";
|
|
700
|
+
return message;
|
|
701
|
+
},
|
|
702
|
+
};
|
|
703
|
+
exports.UserServiceDefinition = {
|
|
704
|
+
name: "UserService",
|
|
705
|
+
fullName: "pb.UserService",
|
|
706
|
+
methods: {
|
|
707
|
+
getMe: {
|
|
708
|
+
name: "GetMe",
|
|
709
|
+
requestType: common_1.Empty,
|
|
710
|
+
requestStream: false,
|
|
711
|
+
responseType: message_1.User,
|
|
712
|
+
responseStream: false,
|
|
713
|
+
options: {
|
|
714
|
+
_unknownFields: {
|
|
715
|
+
578365826: [
|
|
716
|
+
new Uint8Array([18, 18, 16, 47, 97, 112, 105, 47, 118, 49, 47, 117, 115, 101, 114, 115, 47, 109, 101]),
|
|
717
|
+
],
|
|
718
|
+
},
|
|
719
|
+
},
|
|
720
|
+
},
|
|
721
|
+
updateMe: {
|
|
722
|
+
name: "UpdateMe",
|
|
723
|
+
requestType: exports.UpdateUserRequest,
|
|
724
|
+
requestStream: false,
|
|
725
|
+
responseType: message_1.User,
|
|
726
|
+
responseStream: false,
|
|
727
|
+
options: {
|
|
728
|
+
_unknownFields: {
|
|
729
|
+
578365826: [
|
|
730
|
+
new Uint8Array([
|
|
731
|
+
21,
|
|
732
|
+
50,
|
|
733
|
+
16,
|
|
734
|
+
47,
|
|
735
|
+
97,
|
|
736
|
+
112,
|
|
737
|
+
105,
|
|
738
|
+
47,
|
|
739
|
+
118,
|
|
740
|
+
49,
|
|
741
|
+
47,
|
|
742
|
+
117,
|
|
743
|
+
115,
|
|
744
|
+
101,
|
|
745
|
+
114,
|
|
746
|
+
115,
|
|
747
|
+
47,
|
|
748
|
+
109,
|
|
749
|
+
101,
|
|
750
|
+
58,
|
|
751
|
+
1,
|
|
752
|
+
42,
|
|
753
|
+
]),
|
|
754
|
+
],
|
|
755
|
+
},
|
|
756
|
+
},
|
|
757
|
+
},
|
|
758
|
+
updateAvatar: {
|
|
759
|
+
name: "UpdateAvatar",
|
|
760
|
+
requestType: exports.UpdateAvatarRequest,
|
|
761
|
+
requestStream: false,
|
|
762
|
+
responseType: exports.UpdateAvatarResponse,
|
|
763
|
+
responseStream: false,
|
|
764
|
+
options: {
|
|
765
|
+
_unknownFields: {
|
|
766
|
+
578365826: [
|
|
767
|
+
new Uint8Array([
|
|
768
|
+
28,
|
|
769
|
+
34,
|
|
770
|
+
23,
|
|
771
|
+
47,
|
|
772
|
+
97,
|
|
773
|
+
112,
|
|
774
|
+
105,
|
|
775
|
+
47,
|
|
776
|
+
118,
|
|
777
|
+
49,
|
|
778
|
+
47,
|
|
779
|
+
117,
|
|
780
|
+
115,
|
|
781
|
+
101,
|
|
782
|
+
114,
|
|
783
|
+
115,
|
|
784
|
+
47,
|
|
785
|
+
109,
|
|
786
|
+
101,
|
|
787
|
+
47,
|
|
788
|
+
97,
|
|
789
|
+
118,
|
|
790
|
+
97,
|
|
791
|
+
116,
|
|
792
|
+
97,
|
|
793
|
+
114,
|
|
794
|
+
58,
|
|
795
|
+
1,
|
|
796
|
+
42,
|
|
797
|
+
]),
|
|
798
|
+
],
|
|
799
|
+
},
|
|
800
|
+
},
|
|
801
|
+
},
|
|
802
|
+
changePassword: {
|
|
803
|
+
name: "ChangePassword",
|
|
804
|
+
requestType: exports.ChangePasswordRequest,
|
|
805
|
+
requestStream: false,
|
|
806
|
+
responseType: common_1.SuccessResponse,
|
|
807
|
+
responseStream: false,
|
|
808
|
+
options: {
|
|
809
|
+
_unknownFields: {
|
|
810
|
+
578365826: [
|
|
811
|
+
new Uint8Array([
|
|
812
|
+
34,
|
|
813
|
+
50,
|
|
814
|
+
29,
|
|
815
|
+
47,
|
|
816
|
+
97,
|
|
817
|
+
112,
|
|
818
|
+
105,
|
|
819
|
+
47,
|
|
820
|
+
118,
|
|
821
|
+
49,
|
|
822
|
+
47,
|
|
823
|
+
117,
|
|
824
|
+
115,
|
|
825
|
+
101,
|
|
826
|
+
114,
|
|
827
|
+
115,
|
|
828
|
+
47,
|
|
829
|
+
99,
|
|
830
|
+
104,
|
|
831
|
+
97,
|
|
832
|
+
110,
|
|
833
|
+
103,
|
|
834
|
+
101,
|
|
835
|
+
45,
|
|
836
|
+
112,
|
|
837
|
+
97,
|
|
838
|
+
115,
|
|
839
|
+
115,
|
|
840
|
+
119,
|
|
841
|
+
111,
|
|
842
|
+
114,
|
|
843
|
+
100,
|
|
844
|
+
58,
|
|
845
|
+
1,
|
|
846
|
+
42,
|
|
847
|
+
]),
|
|
848
|
+
],
|
|
849
|
+
},
|
|
850
|
+
},
|
|
851
|
+
},
|
|
852
|
+
deactivateAccount: {
|
|
853
|
+
name: "DeactivateAccount",
|
|
854
|
+
requestType: common_1.Empty,
|
|
855
|
+
requestStream: false,
|
|
856
|
+
responseType: common_1.SuccessResponse,
|
|
857
|
+
responseStream: false,
|
|
858
|
+
options: {
|
|
859
|
+
_unknownFields: {
|
|
860
|
+
578365826: [
|
|
861
|
+
new Uint8Array([
|
|
862
|
+
32,
|
|
863
|
+
34,
|
|
864
|
+
27,
|
|
865
|
+
47,
|
|
866
|
+
97,
|
|
867
|
+
112,
|
|
868
|
+
105,
|
|
869
|
+
47,
|
|
870
|
+
118,
|
|
871
|
+
49,
|
|
872
|
+
47,
|
|
873
|
+
117,
|
|
874
|
+
115,
|
|
875
|
+
101,
|
|
876
|
+
114,
|
|
877
|
+
115,
|
|
878
|
+
47,
|
|
879
|
+
109,
|
|
880
|
+
101,
|
|
881
|
+
47,
|
|
882
|
+
100,
|
|
883
|
+
101,
|
|
884
|
+
97,
|
|
885
|
+
99,
|
|
886
|
+
116,
|
|
887
|
+
105,
|
|
888
|
+
118,
|
|
889
|
+
97,
|
|
890
|
+
116,
|
|
891
|
+
101,
|
|
892
|
+
58,
|
|
893
|
+
1,
|
|
894
|
+
42,
|
|
895
|
+
]),
|
|
896
|
+
],
|
|
897
|
+
},
|
|
898
|
+
},
|
|
899
|
+
},
|
|
900
|
+
deleteAccount: {
|
|
901
|
+
name: "DeleteAccount",
|
|
902
|
+
requestType: common_1.Empty,
|
|
903
|
+
requestStream: false,
|
|
904
|
+
responseType: common_1.SuccessResponse,
|
|
905
|
+
responseStream: false,
|
|
906
|
+
options: {
|
|
907
|
+
_unknownFields: {
|
|
908
|
+
578365826: [
|
|
909
|
+
new Uint8Array([18, 42, 16, 47, 97, 112, 105, 47, 118, 49, 47, 117, 115, 101, 114, 115, 47, 109, 101]),
|
|
910
|
+
],
|
|
911
|
+
},
|
|
912
|
+
},
|
|
913
|
+
},
|
|
914
|
+
listSessions: {
|
|
915
|
+
name: "ListSessions",
|
|
916
|
+
requestType: common_1.Empty,
|
|
917
|
+
requestStream: false,
|
|
918
|
+
responseType: exports.ListSessionsResponse,
|
|
919
|
+
responseStream: false,
|
|
920
|
+
options: {
|
|
921
|
+
_unknownFields: {
|
|
922
|
+
578365826: [
|
|
923
|
+
new Uint8Array([
|
|
924
|
+
27,
|
|
925
|
+
18,
|
|
926
|
+
25,
|
|
927
|
+
47,
|
|
928
|
+
97,
|
|
929
|
+
112,
|
|
930
|
+
105,
|
|
931
|
+
47,
|
|
932
|
+
118,
|
|
933
|
+
49,
|
|
934
|
+
47,
|
|
935
|
+
117,
|
|
936
|
+
115,
|
|
937
|
+
101,
|
|
938
|
+
114,
|
|
939
|
+
115,
|
|
940
|
+
47,
|
|
941
|
+
109,
|
|
942
|
+
101,
|
|
943
|
+
47,
|
|
944
|
+
115,
|
|
945
|
+
101,
|
|
946
|
+
115,
|
|
947
|
+
115,
|
|
948
|
+
105,
|
|
949
|
+
111,
|
|
950
|
+
110,
|
|
951
|
+
115,
|
|
952
|
+
]),
|
|
953
|
+
],
|
|
954
|
+
},
|
|
955
|
+
},
|
|
956
|
+
},
|
|
957
|
+
revokeSession: {
|
|
958
|
+
name: "RevokeSession",
|
|
959
|
+
requestType: exports.RevokeSessionRequest,
|
|
960
|
+
requestStream: false,
|
|
961
|
+
responseType: common_1.SuccessResponse,
|
|
962
|
+
responseStream: false,
|
|
963
|
+
options: {
|
|
964
|
+
_unknownFields: {
|
|
965
|
+
578365826: [
|
|
966
|
+
new Uint8Array([
|
|
967
|
+
39,
|
|
968
|
+
42,
|
|
969
|
+
37,
|
|
970
|
+
47,
|
|
971
|
+
97,
|
|
972
|
+
112,
|
|
973
|
+
105,
|
|
974
|
+
47,
|
|
975
|
+
118,
|
|
976
|
+
49,
|
|
977
|
+
47,
|
|
978
|
+
117,
|
|
979
|
+
115,
|
|
980
|
+
101,
|
|
981
|
+
114,
|
|
982
|
+
115,
|
|
983
|
+
47,
|
|
984
|
+
109,
|
|
985
|
+
101,
|
|
986
|
+
47,
|
|
987
|
+
115,
|
|
988
|
+
101,
|
|
989
|
+
115,
|
|
990
|
+
115,
|
|
991
|
+
105,
|
|
992
|
+
111,
|
|
993
|
+
110,
|
|
994
|
+
115,
|
|
995
|
+
47,
|
|
996
|
+
123,
|
|
997
|
+
115,
|
|
998
|
+
101,
|
|
999
|
+
115,
|
|
1000
|
+
115,
|
|
1001
|
+
105,
|
|
1002
|
+
111,
|
|
1003
|
+
110,
|
|
1004
|
+
73,
|
|
1005
|
+
100,
|
|
1006
|
+
125,
|
|
1007
|
+
]),
|
|
1008
|
+
],
|
|
1009
|
+
},
|
|
1010
|
+
},
|
|
1011
|
+
},
|
|
1012
|
+
},
|
|
1013
|
+
};
|
|
1014
|
+
function bytesFromBase64(b64) {
|
|
1015
|
+
if (globalThis.Buffer) {
|
|
1016
|
+
return Uint8Array.from(globalThis.Buffer.from(b64, "base64"));
|
|
1017
|
+
}
|
|
1018
|
+
else {
|
|
1019
|
+
const bin = globalThis.atob(b64);
|
|
1020
|
+
const arr = new Uint8Array(bin.length);
|
|
1021
|
+
for (let i = 0; i < bin.length; ++i) {
|
|
1022
|
+
arr[i] = bin.charCodeAt(i);
|
|
1023
|
+
}
|
|
1024
|
+
return arr;
|
|
1025
|
+
}
|
|
1026
|
+
}
|
|
1027
|
+
function base64FromBytes(arr) {
|
|
1028
|
+
if (globalThis.Buffer) {
|
|
1029
|
+
return globalThis.Buffer.from(arr).toString("base64");
|
|
1030
|
+
}
|
|
1031
|
+
else {
|
|
1032
|
+
const bin = [];
|
|
1033
|
+
arr.forEach((byte) => {
|
|
1034
|
+
bin.push(globalThis.String.fromCharCode(byte));
|
|
1035
|
+
});
|
|
1036
|
+
return globalThis.btoa(bin.join(""));
|
|
1037
|
+
}
|
|
1038
|
+
}
|
|
1039
|
+
function isSet(value) {
|
|
1040
|
+
return value !== null && value !== undefined;
|
|
1041
|
+
}
|