mol_crypto2_lib 0.0.30 → 0.0.32
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/node.d.ts +430 -0
- package/node.d.ts.map +1 -1
- package/package.json +1 -1
- package/web.d.ts +272 -0
- package/web.d.ts.map +1 -1
package/node.d.ts
CHANGED
|
@@ -18,10 +18,18 @@ declare namespace $ {
|
|
|
18
18
|
function $mol_base64_encode(src: Uint8Array<ArrayBuffer>): string;
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
+
declare namespace $ {
|
|
22
|
+
function $mol_base64_encode_node(str: Uint8Array<ArrayBuffer>): string;
|
|
23
|
+
}
|
|
24
|
+
|
|
21
25
|
declare namespace $ {
|
|
22
26
|
function $mol_base64_decode(base64: string): Uint8Array<ArrayBuffer>;
|
|
23
27
|
}
|
|
24
28
|
|
|
29
|
+
declare namespace $ {
|
|
30
|
+
function $mol_base64_decode_node(base64Str: string): Uint8Array<ArrayBuffer>;
|
|
31
|
+
}
|
|
32
|
+
|
|
25
33
|
declare namespace $ {
|
|
26
34
|
function $mol_base64_ae_encode(buffer: Uint8Array<ArrayBuffer>): string;
|
|
27
35
|
function $mol_base64_ae_decode(str: string): Uint8Array<ArrayBuffer>;
|
|
@@ -65,6 +73,11 @@ declare namespace $ {
|
|
|
65
73
|
function $mol_base64_url_decode(str: string): Uint8Array<ArrayBuffer>;
|
|
66
74
|
}
|
|
67
75
|
|
|
76
|
+
declare namespace $ {
|
|
77
|
+
function $mol_base64_url_encode_node(str: Uint8Array<ArrayBuffer>): string;
|
|
78
|
+
function $mol_base64_url_decode_node(str: string): Uint8Array<ArrayBuffer>;
|
|
79
|
+
}
|
|
80
|
+
|
|
68
81
|
declare namespace $ {
|
|
69
82
|
const $mol_ambient_ref: unique symbol;
|
|
70
83
|
type $mol_ambient_context = $;
|
|
@@ -150,6 +163,423 @@ declare namespace $ {
|
|
|
150
163
|
}
|
|
151
164
|
}
|
|
152
165
|
|
|
166
|
+
declare namespace $ {
|
|
167
|
+
function $node_internal_check(name: string): boolean;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
declare namespace $ {
|
|
171
|
+
function $mol_promise_like(val: any): val is Promise<any>;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
declare namespace $ {
|
|
175
|
+
function $mol_fail_catch(error: unknown): boolean;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
declare namespace $ {
|
|
179
|
+
function $mol_try<Result>(handler: () => Result): Result | Error;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
declare namespace $ {
|
|
183
|
+
function $mol_fail_log(error: unknown): boolean;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
declare namespace $ {
|
|
187
|
+
function $node_autoinstall(this: typeof $, name: string): void;
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
interface $node {
|
|
191
|
+
[key: string]: any;
|
|
192
|
+
}
|
|
193
|
+
declare var $node: $node;
|
|
194
|
+
|
|
195
|
+
declare namespace $ {
|
|
196
|
+
class $mol_error_mix<Cause extends {} = {}> extends AggregateError {
|
|
197
|
+
readonly cause: Cause;
|
|
198
|
+
name: string;
|
|
199
|
+
constructor(message: string, cause?: Cause, ...errors: readonly Error[]);
|
|
200
|
+
static [Symbol.toPrimitive](): string;
|
|
201
|
+
static toString(): string;
|
|
202
|
+
static make(...params: ConstructorParameters<typeof $mol_error_mix>): $mol_error_mix<{}>;
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
declare namespace $ {
|
|
207
|
+
namespace $$ { }
|
|
208
|
+
const $mol_object_field: unique symbol;
|
|
209
|
+
class $mol_object extends $mol_object2 {
|
|
210
|
+
static make<This extends typeof $mol_object>(this: This, config: Partial<InstanceType<This>>): InstanceType<This>;
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
declare namespace $ {
|
|
215
|
+
function $mol_env(): Record<string, string | undefined>;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
declare namespace $ {
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
declare namespace $ {
|
|
222
|
+
function $mol_guid(length?: number, exists?: (id: string) => boolean): string;
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
declare namespace $ {
|
|
226
|
+
enum $mol_wire_cursor {
|
|
227
|
+
stale = -1,
|
|
228
|
+
doubt = -2,
|
|
229
|
+
fresh = -3,
|
|
230
|
+
final = -4
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
declare namespace $ {
|
|
235
|
+
class $mol_wire_pub extends Object {
|
|
236
|
+
constructor(id?: string);
|
|
237
|
+
[Symbol.toStringTag]: string;
|
|
238
|
+
data: unknown[];
|
|
239
|
+
static get [Symbol.species](): ArrayConstructor;
|
|
240
|
+
protected sub_from: number;
|
|
241
|
+
get sub_list(): readonly $mol_wire_sub[];
|
|
242
|
+
get sub_empty(): boolean;
|
|
243
|
+
sub_on(sub: $mol_wire_pub, pub_pos: number): number;
|
|
244
|
+
sub_off(sub_pos: number): void;
|
|
245
|
+
reap(): void;
|
|
246
|
+
promote(): void;
|
|
247
|
+
fresh(): void;
|
|
248
|
+
complete(): void;
|
|
249
|
+
get incompleted(): boolean;
|
|
250
|
+
emit(quant?: $mol_wire_cursor): void;
|
|
251
|
+
peer_move(from_pos: number, to_pos: number): void;
|
|
252
|
+
peer_repos(peer_pos: number, self_pos: number): void;
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
declare namespace $ {
|
|
257
|
+
interface $mol_wire_sub extends $mol_wire_pub {
|
|
258
|
+
temp: boolean;
|
|
259
|
+
pub_list: $mol_wire_pub[];
|
|
260
|
+
track_on(): $mol_wire_sub | null;
|
|
261
|
+
track_next(pub?: $mol_wire_pub): $mol_wire_pub | null;
|
|
262
|
+
pub_off(pub_pos: number): void;
|
|
263
|
+
track_cut(sub: $mol_wire_pub | null): void;
|
|
264
|
+
track_off(sub: $mol_wire_pub | null): void;
|
|
265
|
+
absorb(quant: $mol_wire_cursor, pos: number): void;
|
|
266
|
+
destructor(): void;
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
declare namespace $ {
|
|
271
|
+
let $mol_wire_auto_sub: $mol_wire_sub | null;
|
|
272
|
+
function $mol_wire_auto(next?: $mol_wire_sub | null): $mol_wire_sub | null;
|
|
273
|
+
const $mol_wire_affected: ($mol_wire_sub | number)[];
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
declare namespace $ {
|
|
277
|
+
function $mol_dev_format_register(config: {
|
|
278
|
+
header: (val: any, config: any) => any;
|
|
279
|
+
hasBody: (val: any, config: any) => false;
|
|
280
|
+
} | {
|
|
281
|
+
header: (val: any, config: any) => any;
|
|
282
|
+
hasBody: (val: any, config: any) => boolean;
|
|
283
|
+
body: (val: any, config: any) => any;
|
|
284
|
+
}): void;
|
|
285
|
+
const $mol_dev_format_head: unique symbol;
|
|
286
|
+
const $mol_dev_format_body: unique symbol;
|
|
287
|
+
function $mol_dev_format_native(obj: any): any[];
|
|
288
|
+
function $mol_dev_format_auto(obj: any): any[];
|
|
289
|
+
function $mol_dev_format_element(element: string, style: object, ...content: any[]): any[];
|
|
290
|
+
let $mol_dev_format_span: (style: object, ...content: any[]) => any[];
|
|
291
|
+
let $mol_dev_format_div: (style: object, ...content: any[]) => any[];
|
|
292
|
+
let $mol_dev_format_ol: (style: object, ...content: any[]) => any[];
|
|
293
|
+
let $mol_dev_format_li: (style: object, ...content: any[]) => any[];
|
|
294
|
+
let $mol_dev_format_table: (style: object, ...content: any[]) => any[];
|
|
295
|
+
let $mol_dev_format_tr: (style: object, ...content: any[]) => any[];
|
|
296
|
+
let $mol_dev_format_td: (style: object, ...content: any[]) => any[];
|
|
297
|
+
let $mol_dev_format_accent: (...args: any[]) => any[];
|
|
298
|
+
let $mol_dev_format_strong: (...args: any[]) => any[];
|
|
299
|
+
let $mol_dev_format_string: (...args: any[]) => any[];
|
|
300
|
+
let $mol_dev_format_shade: (...args: any[]) => any[];
|
|
301
|
+
let $mol_dev_format_indent: (...args: any[]) => any[];
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
declare namespace $ {
|
|
305
|
+
class $mol_wire_pub_sub extends $mol_wire_pub implements $mol_wire_sub {
|
|
306
|
+
protected pub_from: number;
|
|
307
|
+
protected cursor: $mol_wire_cursor;
|
|
308
|
+
get temp(): boolean;
|
|
309
|
+
get pub_list(): $mol_wire_pub[];
|
|
310
|
+
track_on(): $mol_wire_sub | null;
|
|
311
|
+
promote(): void;
|
|
312
|
+
track_next(pub?: $mol_wire_pub): $mol_wire_pub | null;
|
|
313
|
+
track_off(sub: $mol_wire_sub | null): void;
|
|
314
|
+
pub_off(sub_pos: number): void;
|
|
315
|
+
destructor(): void;
|
|
316
|
+
track_cut(): void;
|
|
317
|
+
complete(): void;
|
|
318
|
+
complete_pubs(): void;
|
|
319
|
+
absorb(quant?: $mol_wire_cursor, pos?: number): void;
|
|
320
|
+
[$mol_dev_format_head](): any[];
|
|
321
|
+
get pub_empty(): boolean;
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
declare namespace $ {
|
|
326
|
+
class $mol_after_tick extends $mol_object2 {
|
|
327
|
+
task: () => void;
|
|
328
|
+
static promise: Promise<void> | null;
|
|
329
|
+
cancelled: boolean;
|
|
330
|
+
constructor(task: () => void);
|
|
331
|
+
destructor(): void;
|
|
332
|
+
}
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
declare namespace $ {
|
|
336
|
+
abstract class $mol_wire_fiber<Host, Args extends readonly unknown[], Result> extends $mol_wire_pub_sub {
|
|
337
|
+
readonly task: (this: Host, ...args: Args) => Result;
|
|
338
|
+
readonly host?: Host | undefined;
|
|
339
|
+
static warm: boolean;
|
|
340
|
+
static planning: Set<$mol_wire_fiber<any, any, any>>;
|
|
341
|
+
static reaping: Set<$mol_wire_fiber<any, any, any>>;
|
|
342
|
+
static plan_task: $mol_after_tick | null;
|
|
343
|
+
static plan(): void;
|
|
344
|
+
static sync(): void;
|
|
345
|
+
cache: Result | Error | Promise<Result | Error>;
|
|
346
|
+
get args(): Args;
|
|
347
|
+
result(): Result | undefined;
|
|
348
|
+
get incompleted(): boolean;
|
|
349
|
+
field(): string;
|
|
350
|
+
constructor(id: string, task: (this: Host, ...args: Args) => Result, host?: Host | undefined, args?: Args);
|
|
351
|
+
plan(): this;
|
|
352
|
+
reap(): void;
|
|
353
|
+
toString(): string;
|
|
354
|
+
toJSON(): string;
|
|
355
|
+
[$mol_dev_format_head](): any[];
|
|
356
|
+
[$mol_dev_format_body](): null;
|
|
357
|
+
get $(): any;
|
|
358
|
+
emit(quant?: $mol_wire_cursor): void;
|
|
359
|
+
fresh(): this | undefined;
|
|
360
|
+
refresh(): void;
|
|
361
|
+
abstract put(next: Result | Error | Promise<Result | Error>): Result | Error | Promise<Result | Error>;
|
|
362
|
+
sync(): Awaited<Result>;
|
|
363
|
+
async_raw(): Promise<Result>;
|
|
364
|
+
async(): Promise<Result> & {
|
|
365
|
+
destructor(): void;
|
|
366
|
+
};
|
|
367
|
+
step(): Promise<null>;
|
|
368
|
+
destructor(): void;
|
|
369
|
+
}
|
|
370
|
+
}
|
|
371
|
+
|
|
372
|
+
declare namespace $ {
|
|
373
|
+
let $mol_compare_deep_cache: WeakMap<any, WeakMap<any, boolean>>;
|
|
374
|
+
function $mol_compare_deep<Value>(left: Value, right: Value): boolean;
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
declare namespace $ {
|
|
378
|
+
type $mol_log3_event<Fields> = {
|
|
379
|
+
[key in string]: unknown;
|
|
380
|
+
} & {
|
|
381
|
+
time?: string;
|
|
382
|
+
place: unknown;
|
|
383
|
+
message: string;
|
|
384
|
+
} & Fields;
|
|
385
|
+
type $mol_log3_logger<Fields, Res = void> = (this: $, event: $mol_log3_event<Fields>) => Res;
|
|
386
|
+
let $mol_log3_come: $mol_log3_logger<{}>;
|
|
387
|
+
let $mol_log3_done: $mol_log3_logger<{}>;
|
|
388
|
+
let $mol_log3_fail: $mol_log3_logger<{}>;
|
|
389
|
+
let $mol_log3_warn: $mol_log3_logger<{
|
|
390
|
+
hint: string;
|
|
391
|
+
}>;
|
|
392
|
+
let $mol_log3_rise: $mol_log3_logger<{}>;
|
|
393
|
+
let $mol_log3_area: $mol_log3_logger<{}, () => void>;
|
|
394
|
+
function $mol_log3_area_lazy(this: $, event: $mol_log3_event<{}>): () => void;
|
|
395
|
+
let $mol_log3_stack: (() => void)[];
|
|
396
|
+
}
|
|
397
|
+
|
|
398
|
+
declare namespace $ {
|
|
399
|
+
class $mol_span extends $mol_object2 {
|
|
400
|
+
readonly uri: string;
|
|
401
|
+
readonly source: string;
|
|
402
|
+
readonly row: number;
|
|
403
|
+
readonly col: number;
|
|
404
|
+
readonly length: number;
|
|
405
|
+
constructor(uri: string, source: string, row: number, col: number, length: number);
|
|
406
|
+
static unknown: $mol_span;
|
|
407
|
+
static begin(uri: string, source?: string): $mol_span;
|
|
408
|
+
static end(uri: string, source: string): $mol_span;
|
|
409
|
+
static entire(uri: string, source: string): $mol_span;
|
|
410
|
+
toString(): string;
|
|
411
|
+
toJSON(): {
|
|
412
|
+
uri: string;
|
|
413
|
+
row: number;
|
|
414
|
+
col: number;
|
|
415
|
+
length: number;
|
|
416
|
+
};
|
|
417
|
+
error(message: string, Class?: ErrorConstructor): Error;
|
|
418
|
+
span(row: number, col: number, length: number): $mol_span;
|
|
419
|
+
after(length?: number): $mol_span;
|
|
420
|
+
slice(begin: number, end?: number): $mol_span;
|
|
421
|
+
}
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
declare namespace $ {
|
|
425
|
+
function $mol_tree2_to_string(this: $, tree: $mol_tree2): string;
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
declare namespace $ {
|
|
429
|
+
function $mol_maybe<Value>(value: Value | null | undefined): Value[];
|
|
430
|
+
}
|
|
431
|
+
|
|
432
|
+
declare namespace $ {
|
|
433
|
+
type $mol_tree2_path = Array<string | number | null>;
|
|
434
|
+
type $mol_tree2_hack<Context> = (input: $mol_tree2, belt: $mol_tree2_belt<Context>, context: Context) => readonly $mol_tree2[];
|
|
435
|
+
type $mol_tree2_belt<Context> = Record<string, $mol_tree2_hack<Context>>;
|
|
436
|
+
class $mol_tree2 extends Object {
|
|
437
|
+
readonly type: string;
|
|
438
|
+
readonly value: string;
|
|
439
|
+
readonly kids: readonly $mol_tree2[];
|
|
440
|
+
readonly span: $mol_span;
|
|
441
|
+
constructor(type: string, value: string, kids: readonly $mol_tree2[], span: $mol_span);
|
|
442
|
+
static list(kids: readonly $mol_tree2[], span?: $mol_span): $mol_tree2;
|
|
443
|
+
list(kids: readonly $mol_tree2[]): $mol_tree2;
|
|
444
|
+
static data(value: string, kids?: readonly $mol_tree2[], span?: $mol_span): $mol_tree2;
|
|
445
|
+
data(value: string, kids?: readonly $mol_tree2[]): $mol_tree2;
|
|
446
|
+
static struct(type: string, kids?: readonly $mol_tree2[], span?: $mol_span): $mol_tree2;
|
|
447
|
+
struct(type: string, kids?: readonly $mol_tree2[]): $mol_tree2;
|
|
448
|
+
clone(kids: readonly $mol_tree2[], span?: $mol_span): $mol_tree2;
|
|
449
|
+
text(): string;
|
|
450
|
+
static fromString(str: string, uri?: string): $mol_tree2;
|
|
451
|
+
toString(): string;
|
|
452
|
+
insert(value: $mol_tree2 | null, ...path: $mol_tree2_path): $mol_tree2;
|
|
453
|
+
update(value: readonly $mol_tree2[], ...path: $mol_tree2_path): readonly $mol_tree2[];
|
|
454
|
+
select(...path: $mol_tree2_path): $mol_tree2;
|
|
455
|
+
filter(path: string[], value?: string): $mol_tree2;
|
|
456
|
+
hack_self<Context extends {
|
|
457
|
+
span?: $mol_span;
|
|
458
|
+
[key: string]: unknown;
|
|
459
|
+
} = {}>(belt: $mol_tree2_belt<Context>, context?: Context): readonly $mol_tree2[];
|
|
460
|
+
hack<Context extends {
|
|
461
|
+
span?: $mol_span;
|
|
462
|
+
[key: string]: unknown;
|
|
463
|
+
} = {}>(belt: $mol_tree2_belt<Context>, context?: Context): $mol_tree2[];
|
|
464
|
+
error(message: string, Class?: ErrorConstructor): Error;
|
|
465
|
+
}
|
|
466
|
+
class $mol_tree2_empty extends $mol_tree2 {
|
|
467
|
+
constructor();
|
|
468
|
+
}
|
|
469
|
+
}
|
|
470
|
+
|
|
471
|
+
declare namespace $ {
|
|
472
|
+
class $mol_error_syntax extends SyntaxError {
|
|
473
|
+
reason: string;
|
|
474
|
+
line: string;
|
|
475
|
+
span: $mol_span;
|
|
476
|
+
constructor(reason: string, line: string, span: $mol_span);
|
|
477
|
+
}
|
|
478
|
+
}
|
|
479
|
+
|
|
480
|
+
declare namespace $ {
|
|
481
|
+
function $mol_tree2_from_string(this: $, str: string, uri?: string): $mol_tree2;
|
|
482
|
+
}
|
|
483
|
+
|
|
484
|
+
declare namespace $ {
|
|
485
|
+
function $mol_array_chunks<Item>(array: readonly Item[], rule: number | ((item: Item, index: number) => boolean)): Item[][];
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
declare namespace $ {
|
|
489
|
+
function $mol_tree2_from_json(json: any, span?: $mol_span): $mol_tree2;
|
|
490
|
+
}
|
|
491
|
+
|
|
492
|
+
declare namespace $ {
|
|
493
|
+
class $mol_term_color {
|
|
494
|
+
static reset: (str: string) => string;
|
|
495
|
+
static bold: (str: string) => string;
|
|
496
|
+
static italic: (str: string) => string;
|
|
497
|
+
static underline: (str: string) => string;
|
|
498
|
+
static inverse: (str: string) => string;
|
|
499
|
+
static hidden: (str: string) => string;
|
|
500
|
+
static strike: (str: string) => string;
|
|
501
|
+
static gray: (str: string) => string;
|
|
502
|
+
static red: (str: string) => string;
|
|
503
|
+
static green: (str: string) => string;
|
|
504
|
+
static yellow: (str: string) => string;
|
|
505
|
+
static blue: (str: string) => string;
|
|
506
|
+
static magenta: (str: string) => string;
|
|
507
|
+
static cyan: (str: string) => string;
|
|
508
|
+
static Gray: (str: string) => string;
|
|
509
|
+
static Red: (str: string) => string;
|
|
510
|
+
static Green: (str: string) => string;
|
|
511
|
+
static Yellow: (str: string) => string;
|
|
512
|
+
static Blue: (str: string) => string;
|
|
513
|
+
static Magenta: (str: string) => string;
|
|
514
|
+
static Cyan: (str: string) => string;
|
|
515
|
+
static ansi(open: number, close: number): (str: string) => string;
|
|
516
|
+
}
|
|
517
|
+
}
|
|
518
|
+
|
|
519
|
+
declare namespace $ {
|
|
520
|
+
function $mol_log3_node_make(level: keyof Console, output: 'stdout' | 'stderr', type: string, color: (str: string) => string): (this: $, event: $mol_log3_event<{}>) => () => void;
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
declare namespace $ {
|
|
524
|
+
class $mol_wire_task<Host, Args extends readonly unknown[], Result> extends $mol_wire_fiber<Host, Args, Result> {
|
|
525
|
+
static getter<Host, Args extends readonly unknown[], Result>(task: (this: Host, ...args: Args) => Result): (host: Host, args: Args) => $mol_wire_task<Host, Args, Result>;
|
|
526
|
+
get temp(): boolean;
|
|
527
|
+
complete(): void;
|
|
528
|
+
put(next: Result | Error | Promise<Result | Error>): Error | Result | Promise<Error | Result>;
|
|
529
|
+
destructor(): void;
|
|
530
|
+
}
|
|
531
|
+
}
|
|
532
|
+
|
|
533
|
+
declare namespace $ {
|
|
534
|
+
export function $mol_wire_sync<Host extends object>(obj: Host): ObjectOrFunctionResultAwaited<Host>;
|
|
535
|
+
type FunctionResultAwaited<Some> = Some extends (...args: infer Args) => infer Res ? (...args: Args) => Awaited<Res> : Some;
|
|
536
|
+
type ConstructorResultAwaited<Some> = Some extends new (...args: infer Args) => infer Res ? new (...args: Args) => Res : {};
|
|
537
|
+
type MethodsResultAwaited<Host extends Object> = {
|
|
538
|
+
[K in keyof Host]: FunctionResultAwaited<Host[K]>;
|
|
539
|
+
};
|
|
540
|
+
type ObjectOrFunctionResultAwaited<Some> = (Some extends (...args: any) => unknown ? FunctionResultAwaited<Some> : {}) & (Some extends Object ? MethodsResultAwaited<Some> & ConstructorResultAwaited<Some> : Some);
|
|
541
|
+
export {};
|
|
542
|
+
}
|
|
543
|
+
|
|
544
|
+
declare namespace $ {
|
|
545
|
+
type $mol_run_error_context = {
|
|
546
|
+
pid?: number;
|
|
547
|
+
stdout: Buffer | string;
|
|
548
|
+
stderr: Buffer | string;
|
|
549
|
+
};
|
|
550
|
+
class $mol_run_error extends $mol_error_mix<{
|
|
551
|
+
timeout_kill?: boolean;
|
|
552
|
+
pid?: number;
|
|
553
|
+
signal?: NodeJS.Signals | null;
|
|
554
|
+
status?: number | null;
|
|
555
|
+
command: string;
|
|
556
|
+
dir: string;
|
|
557
|
+
}> {
|
|
558
|
+
}
|
|
559
|
+
const $mol_run_spawn: (...args: Parameters<(typeof $node)["child_process"]["spawn"]>) => import("node:child_process").ChildProcess;
|
|
560
|
+
const $mol_run_spawn_sync: (...args: Parameters<(typeof $node)["child_process"]["spawnSync"]>) => import("node:child_process").SpawnSyncReturns<string | NonSharedBuffer>;
|
|
561
|
+
type $mol_run_options = {
|
|
562
|
+
command: readonly string[] | string;
|
|
563
|
+
dir: string;
|
|
564
|
+
timeout?: number;
|
|
565
|
+
env?: Record<string, string | undefined>;
|
|
566
|
+
};
|
|
567
|
+
class $mol_run extends $mol_object {
|
|
568
|
+
static async_enabled(): boolean;
|
|
569
|
+
static spawn(options: $mol_run_options): import("node:child_process").SpawnSyncReturns<string | NonSharedBuffer> | $mol_run_error_context;
|
|
570
|
+
static spawn_async({ dir, sync, timeout, command, env }: $mol_run_options & {
|
|
571
|
+
sync?: boolean;
|
|
572
|
+
}): import("node:child_process").SpawnSyncReturns<string | NonSharedBuffer> | (Promise<$mol_run_error_context> & {
|
|
573
|
+
destructor: () => void;
|
|
574
|
+
});
|
|
575
|
+
static error_message(res?: $mol_run_error_context): string;
|
|
576
|
+
}
|
|
577
|
+
}
|
|
578
|
+
|
|
579
|
+
declare namespace $ {
|
|
580
|
+
var $mol_crypto_native: Crypto;
|
|
581
|
+
}
|
|
582
|
+
|
|
153
583
|
declare namespace $ {
|
|
154
584
|
function $mol_crypto_restack(error: any): never;
|
|
155
585
|
}
|
package/node.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../mam.d.ts","../../../base64/encode/encode.d.ts","../../../base64/decode/decode.d.ts","../../../base64/ae/ae.d.ts","../../../func/name/name.d.ts","../../../fail/fail.d.ts","../../../buffer/buffer.d.ts","../../../base64/url/url.d.ts","../../../ambient/ambient.d.ts","../../../delegate/delegate.d.ts","../../../owning/owning.d.ts","../../../fail/hidden/hidden.d.ts","../../../type/writable/writable.d.ts","../../../key/key.d.ts","../../../object2/object2.d.ts","../../../wrapper/wrapper.d.ts","../../../memo/memo.d.ts","../../key/key.d.ts","../../../crypto/restack/restack.d.ts","../../auditor/auditor.d.ts","../../signer/signer.d.ts","../../socket/socket.d.ts","../../nonce/nonce.d.ts","../../../crypto/salt/salt.d.ts","../../../crypto/sacred/sacred.d.ts","../../cipher/cipher.d.ts","../../public/public.d.ts","../../private/private.d.ts"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACfA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACvBA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACbA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AClBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACVA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACTA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;ACNA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACXA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACtBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACXA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACTA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","sourcesContent":[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]}
|
|
1
|
+
{"version":3,"sources":["../../../../mam.d.ts","../../../base64/encode/encode.d.ts","../../../base64/encode/encode.node.d.ts","../../../base64/decode/decode.d.ts","../../../base64/decode/decode.node.d.ts","../../../base64/ae/ae.d.ts","../../../func/name/name.d.ts","../../../fail/fail.d.ts","../../../buffer/buffer.d.ts","../../../base64/url/url.d.ts","../../../base64/url/url.node.d.ts","../../../ambient/ambient.d.ts","../../../delegate/delegate.d.ts","../../../owning/owning.d.ts","../../../fail/hidden/hidden.d.ts","../../../type/writable/writable.d.ts","../../../key/key.d.ts","../../../object2/object2.d.ts","../../../wrapper/wrapper.d.ts","../../../memo/memo.d.ts","../../key/key.d.ts","../../../../node/internal/check/check.node.d.ts","../../../promise/like/like.d.ts","../../../fail/catch/catch.d.ts","../../../try/try.d.ts","../../../fail/log/log.d.ts","../../../../node/autoinstall/autoinstall.node.d.ts","../../../../node/node.node.d.ts","../../../error/mix/mix.d.ts","../../../object/object.d.ts","../../../env/env.d.ts","../../../env/env.node.d.ts","../../../guid/guid.d.ts","../../../wire/cursor/cursor.d.ts","../../../wire/pub/pub.d.ts","../../../wire/sub/sub.d.ts","../../../wire/wire.d.ts","../../../dev/format/format.d.ts","../../../wire/pub/sub/sub.d.ts","../../../after/tick/tick.d.ts","../../../wire/fiber/fiber.d.ts","../../../compare/deep/deep.d.ts","../../../log3/log3.d.ts","../../../span/span.d.ts","../../../tree2/to/string/string.d.ts","../../../maybe/maybe.d.ts","../../../tree2/tree2.d.ts","../../../error/syntax/syntax.d.ts","../../../tree2/from/string/string.d.ts","../../../array/chunks/chunks.d.ts","../../../tree2/from/json/json.d.ts","../../../term/color/color.d.ts","../../../log3/log3.node.d.ts","../../../wire/task/task.d.ts","../../../wire/sync/sync.d.ts","../../../run/run.node.d.ts","../../../crypto/native/native.node.d.ts","../../../crypto/restack/restack.d.ts","../../auditor/auditor.d.ts","../../signer/signer.d.ts","../../socket/socket.d.ts","../../nonce/nonce.d.ts","../../../crypto/salt/salt.d.ts","../../../crypto/sacred/sacred.d.ts","../../cipher/cipher.d.ts","../../public/public.d.ts","../../private/private.d.ts"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACfA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACvBA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACbA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AClBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACVA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACTA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACVA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACPA;AACA;AACA;AACA;ACHA;AACA;AACA;ACFA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACRA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACrBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACbA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AC3BA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACpBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACTA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACpCA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACpBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACzBA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACtCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACRA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AC1BA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACTA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACVA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AClCA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;ACNA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACXA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACtBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACXA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACTA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","sourcesContent":[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]}
|
package/package.json
CHANGED
package/web.d.ts
CHANGED
|
@@ -1,3 +1,275 @@
|
|
|
1
|
+
declare let _$_: {
|
|
2
|
+
new (): {};
|
|
3
|
+
} & typeof globalThis;
|
|
4
|
+
declare class $ extends _$_ {
|
|
5
|
+
}
|
|
6
|
+
declare namespace $ {
|
|
7
|
+
export type $ = typeof $$;
|
|
8
|
+
export class $$ extends $ {
|
|
9
|
+
static $: $;
|
|
10
|
+
}
|
|
11
|
+
namespace $$ {
|
|
12
|
+
type $$ = $;
|
|
13
|
+
}
|
|
14
|
+
export {};
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
declare namespace $ {
|
|
18
|
+
function $mol_base64_encode(src: Uint8Array<ArrayBuffer>): string;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
declare namespace $ {
|
|
22
|
+
var $mol_dom_context: typeof globalThis;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
declare namespace $ {
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
declare namespace $ {
|
|
29
|
+
var $mol_dom: typeof globalThis;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
declare namespace $ {
|
|
33
|
+
function $mol_base64_encode_web(str: Uint8Array<ArrayBuffer>): string;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
declare namespace $ {
|
|
37
|
+
function $mol_base64_decode(base64: string): Uint8Array<ArrayBuffer>;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
declare namespace $ {
|
|
41
|
+
function $mol_base64_decode_web(base64Str: string): Uint8Array<ArrayBuffer>;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
declare namespace $ {
|
|
45
|
+
function $mol_base64_ae_encode(buffer: Uint8Array<ArrayBuffer>): string;
|
|
46
|
+
function $mol_base64_ae_decode(str: string): Uint8Array<ArrayBuffer>;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
declare namespace $ {
|
|
50
|
+
function $mol_func_name(this: $, func: Function): string;
|
|
51
|
+
function $mol_func_name_from<Target extends Function>(target: Target, source: Function): Target;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
declare namespace $ {
|
|
55
|
+
function $mol_fail(error: any): never;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
declare namespace $ {
|
|
59
|
+
class $mol_buffer extends DataView<ArrayBuffer> {
|
|
60
|
+
[Symbol.toStringTag]: string;
|
|
61
|
+
static from<This extends typeof $mol_buffer>(this: This, array: number | string | ArrayBufferView<ArrayBuffer> | ArrayBuffer): InstanceType<This>;
|
|
62
|
+
static toString(): string;
|
|
63
|
+
getUint48(offset: number, LE?: boolean): number;
|
|
64
|
+
setUint48(offset: number, value: number, LE?: boolean): void;
|
|
65
|
+
int8(offset: number, next?: number): number;
|
|
66
|
+
uint8(offset: number, next?: number): number;
|
|
67
|
+
int16(offset: number, next?: number): number;
|
|
68
|
+
uint16(offset: number, next?: number): number;
|
|
69
|
+
int32(offset: number, next?: number): number;
|
|
70
|
+
uint32(offset: number, next?: number): number;
|
|
71
|
+
int64(offset: number, next?: bigint): bigint;
|
|
72
|
+
uint48(offset: number, next?: number): number;
|
|
73
|
+
uint64(offset: number, next?: bigint): bigint;
|
|
74
|
+
float16(offset: number, next?: number): number;
|
|
75
|
+
float32(offset: number, next?: number): number;
|
|
76
|
+
float64(offset: number, next?: number): number;
|
|
77
|
+
asArray(): Uint8Array<ArrayBuffer>;
|
|
78
|
+
toString(): string;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
declare namespace $ {
|
|
83
|
+
function $mol_base64_url_encode(buffer: Uint8Array<ArrayBuffer>): string;
|
|
84
|
+
function $mol_base64_url_decode(str: string): Uint8Array<ArrayBuffer>;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
declare namespace $ {
|
|
88
|
+
function $mol_base64_url_encode_web(buffer: Uint8Array<ArrayBuffer>): string;
|
|
89
|
+
function $mol_base64_url_decode_web(str: string): Uint8Array<ArrayBuffer>;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
declare namespace $ {
|
|
93
|
+
const $mol_ambient_ref: unique symbol;
|
|
94
|
+
type $mol_ambient_context = $;
|
|
95
|
+
function $mol_ambient(this: $ | void, overrides: Partial<$>): $;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
declare namespace $ {
|
|
99
|
+
function $mol_delegate<Value extends object>(proto: Value, target: () => Value): Value;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
declare namespace $ {
|
|
103
|
+
const $mol_owning_map: WeakMap<any, any>;
|
|
104
|
+
function $mol_owning_allow<Having>(having: Having): having is Having & {
|
|
105
|
+
destructor(): void;
|
|
106
|
+
};
|
|
107
|
+
function $mol_owning_get<Having, Owner extends object>(having: Having, Owner?: {
|
|
108
|
+
new (): Owner;
|
|
109
|
+
}): Owner | null;
|
|
110
|
+
function $mol_owning_check<Owner, Having>(owner: Owner, having: Having): having is Having & {
|
|
111
|
+
destructor(): void;
|
|
112
|
+
};
|
|
113
|
+
function $mol_owning_catch<Owner, Having>(owner: Owner, having: Having): boolean;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
declare namespace $ {
|
|
117
|
+
function $mol_fail_hidden(error: any): never;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
declare namespace $ {
|
|
121
|
+
type $mol_type_writable<T> = {
|
|
122
|
+
-readonly [P in keyof T]: T[P];
|
|
123
|
+
};
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
declare namespace $ {
|
|
127
|
+
const $mol_key_handle: unique symbol;
|
|
128
|
+
const $mol_key_store: WeakMap<object, string>;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
declare namespace $ {
|
|
132
|
+
class $mol_object2 {
|
|
133
|
+
static $: $;
|
|
134
|
+
[Symbol.toStringTag]: string;
|
|
135
|
+
[$mol_ambient_ref]: $;
|
|
136
|
+
get $(): $;
|
|
137
|
+
set $(next: $);
|
|
138
|
+
static create<Instance>(this: new (init?: (instance: any) => void) => Instance, init?: (instance: $mol_type_writable<Instance>) => void): Instance;
|
|
139
|
+
static [Symbol.toPrimitive](): any;
|
|
140
|
+
static toString(): any;
|
|
141
|
+
static toJSON(): any;
|
|
142
|
+
static [$mol_key_handle](): any;
|
|
143
|
+
destructor(): void;
|
|
144
|
+
static destructor(): void;
|
|
145
|
+
[Symbol.dispose](): void;
|
|
146
|
+
toString(): string;
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
declare namespace $ {
|
|
151
|
+
class $mol_wrapper extends $mol_object2 {
|
|
152
|
+
static wrap: (task: (...ags: any[]) => any) => (...ags: any[]) => any;
|
|
153
|
+
static run<Result>(task: () => Result): Result;
|
|
154
|
+
static func<Args extends any[], Result, Host = void>(func: (this: Host, ...args: Args) => Result): (this: Host, ...args: Args) => Result;
|
|
155
|
+
static get class(): <Class extends new (...args: any[]) => any>(Class: Class) => Class;
|
|
156
|
+
static get method(): (obj: object, name: PropertyKey, descr?: TypedPropertyDescriptor<any>) => TypedPropertyDescriptor<any>;
|
|
157
|
+
static get field(): <Host extends object, Field extends keyof Host, Args extends any[], Result>(obj: Host, name: Field, descr?: TypedPropertyDescriptor<Result>) => TypedPropertyDescriptor<Result>;
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
declare namespace $ {
|
|
162
|
+
class $mol_memo extends $mol_wrapper {
|
|
163
|
+
static wrap<This extends object, Value>(task: (this: This, next?: Value) => Value): (this: This, next?: Value) => Value | undefined;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
declare namespace $ {
|
|
168
|
+
class $mol_crypto2_key extends $mol_buffer {
|
|
169
|
+
static size_str: number;
|
|
170
|
+
static size_bin: number;
|
|
171
|
+
static from<This extends typeof $mol_buffer>(this: This, serial: number | string | ArrayBufferView<ArrayBuffer> | ArrayBuffer): InstanceType<This>;
|
|
172
|
+
asArray(): Uint8Array<ArrayBuffer>;
|
|
173
|
+
toString(): string;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
declare namespace $ {
|
|
178
|
+
var $mol_crypto_native: Crypto;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
declare namespace $ {
|
|
182
|
+
function $mol_crypto_restack(error: any): never;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
declare namespace $ {
|
|
186
|
+
class $mol_crypto2_auditor extends $mol_crypto2_key {
|
|
187
|
+
native(): Promise<CryptoKey>;
|
|
188
|
+
verify(data: BufferSource, sign: BufferSource): Promise<boolean>;
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
declare namespace $ {
|
|
193
|
+
class $mol_crypto2_signer extends $mol_crypto2_auditor {
|
|
194
|
+
static size_sign: number;
|
|
195
|
+
static generate(): Promise<$mol_crypto2_signer>;
|
|
196
|
+
nativePrivate(): Promise<CryptoKey>;
|
|
197
|
+
asArrayPrivate(): Uint8Array<ArrayBuffer>;
|
|
198
|
+
toStringPrivate(): string;
|
|
199
|
+
auditor(): $mol_crypto2_auditor;
|
|
200
|
+
sign(data: BufferSource): Promise<Uint8Array<ArrayBuffer>>;
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
declare namespace $ {
|
|
205
|
+
class $mol_crypto2_socket extends $mol_crypto2_key {
|
|
206
|
+
native(): Promise<CryptoKey>;
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
declare namespace $ {
|
|
211
|
+
function $mol_crypto2_nonce(): Uint8Array<ArrayBuffer>;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
declare namespace $ {
|
|
215
|
+
let $mol_crypto_salt: typeof $mol_crypto2_nonce;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
declare namespace $ {
|
|
219
|
+
type BufferSource = ArrayBufferView<ArrayBuffer> | ArrayBuffer;
|
|
220
|
+
export class $mol_crypto_sacred extends $mol_buffer {
|
|
221
|
+
static size: 16;
|
|
222
|
+
static make(): $mol_crypto_sacred;
|
|
223
|
+
static from<This extends typeof $mol_buffer>(this: This, serial: string | ArrayBufferView<ArrayBuffer>): InstanceType<This>;
|
|
224
|
+
static from_native(native: CryptoKey): Promise<$mol_crypto_sacred>;
|
|
225
|
+
constructor(buffer: ArrayBuffer, byteOffset?: number, byteLength?: number);
|
|
226
|
+
toString(): string;
|
|
227
|
+
_native: undefined | CryptoKey & {
|
|
228
|
+
type: 'secret';
|
|
229
|
+
};
|
|
230
|
+
native(): Promise<CryptoKey & {
|
|
231
|
+
type: "secret";
|
|
232
|
+
}>;
|
|
233
|
+
encrypt(open: BufferSource, salt: BufferSource): Promise<Uint8Array<ArrayBuffer>>;
|
|
234
|
+
decrypt(closed: BufferSource, salt: BufferSource): Promise<Uint8Array<ArrayBuffer>>;
|
|
235
|
+
close(opened: DataView<ArrayBuffer>, salt: BufferSource): Promise<Uint8Array<ArrayBuffer>>;
|
|
236
|
+
open(closed: Uint8Array<ArrayBuffer>, salt: BufferSource): Promise<Uint8Array<ArrayBuffer>>;
|
|
237
|
+
}
|
|
238
|
+
export {};
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
declare namespace $ {
|
|
242
|
+
class $mol_crypto2_cipher extends $mol_crypto2_socket {
|
|
243
|
+
static size_secret: number;
|
|
244
|
+
static generate(): Promise<$mol_crypto2_cipher>;
|
|
245
|
+
nativePrivate(): Promise<CryptoKey>;
|
|
246
|
+
asArrayPrivate(): Uint8Array<ArrayBuffer>;
|
|
247
|
+
toStringPrivate(): string;
|
|
248
|
+
socket(): $mol_crypto2_socket;
|
|
249
|
+
secret(pub: $mol_crypto2_socket): Promise<$mol_crypto_sacred>;
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
declare namespace $ {
|
|
254
|
+
class $mol_crypto2_public extends $mol_crypto2_key {
|
|
255
|
+
static size_str: number;
|
|
256
|
+
static size_bin: number;
|
|
257
|
+
auditor(): $mol_crypto2_auditor;
|
|
258
|
+
socket(): $mol_crypto2_socket;
|
|
259
|
+
toString(): string;
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
declare namespace $ {
|
|
264
|
+
class $mol_crypto2_private extends $mol_crypto2_public {
|
|
265
|
+
static generate(): Promise<$mol_crypto2_private>;
|
|
266
|
+
signer(): $mol_crypto2_signer;
|
|
267
|
+
cipher(): $mol_crypto2_cipher;
|
|
268
|
+
public(): $mol_crypto2_public;
|
|
269
|
+
asArrayPrivate(): Uint8Array<ArrayBuffer>;
|
|
270
|
+
toStringPrivate(): string;
|
|
271
|
+
}
|
|
272
|
+
}
|
|
1
273
|
|
|
2
274
|
export = $;
|
|
3
275
|
//# sourceMappingURL=web.d.ts.map
|
package/web.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","sourcesContent":[]}
|
|
1
|
+
{"version":3,"sources":["../../../../mam.d.ts","../../../base64/encode/encode.d.ts","../../../dom/context/context.d.ts","../../../dom/context/context.web.d.ts","../../../dom/dom.d.ts","../../../base64/encode/encode.web.d.ts","../../../base64/decode/decode.d.ts","../../../base64/decode/decode.web.d.ts","../../../base64/ae/ae.d.ts","../../../func/name/name.d.ts","../../../fail/fail.d.ts","../../../buffer/buffer.d.ts","../../../base64/url/url.d.ts","../../../base64/url/url.web.d.ts","../../../ambient/ambient.d.ts","../../../delegate/delegate.d.ts","../../../owning/owning.d.ts","../../../fail/hidden/hidden.d.ts","../../../type/writable/writable.d.ts","../../../key/key.d.ts","../../../object2/object2.d.ts","../../../wrapper/wrapper.d.ts","../../../memo/memo.d.ts","../../key/key.d.ts","../../../crypto/native/native.web.d.ts","../../../crypto/restack/restack.d.ts","../../auditor/auditor.d.ts","../../signer/signer.d.ts","../../socket/socket.d.ts","../../nonce/nonce.d.ts","../../../crypto/salt/salt.d.ts","../../../crypto/sacred/sacred.d.ts","../../cipher/cipher.d.ts","../../public/public.d.ts","../../private/private.d.ts"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACfA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;ACFA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACvBA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACbA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;AACA;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AClBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACVA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACTA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;ACNA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACXA;AACA;AACA;AACA;AACA;AACA;ACLA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;ACHA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACtBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACXA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACTA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","sourcesContent":[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]}
|