@blocklet/js-sdk 1.16.34-beta-20241207-134904-3c3d9a35 → 1.16.34-beta-20241212-152152-0b8d4bb3

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/index.d.mts CHANGED
@@ -2,6 +2,7 @@ import * as axios from 'axios';
2
2
  import { Axios, AxiosRequestConfig } from 'axios';
3
3
  import { TTheme, TNavigationItem } from '@blocklet/meta/lib/types';
4
4
  import { TComponentInternalInfo } from '@blocklet/meta/lib/blocklet';
5
+ import { BlockletStatus } from '@blocklet/meta/lib/constants';
5
6
 
6
7
  type UserPublicInfo = {
7
8
  avatar: string;
@@ -80,24 +81,6 @@ declare class TokenService {
80
81
  removeRefreshToken(): void;
81
82
  }
82
83
 
83
- declare const BlockletStatus: Readonly<{
84
- added: 0;
85
- downloading: 1;
86
- downloaded: 2;
87
- installing: 3;
88
- installed: 4;
89
- starting: 5;
90
- running: 6;
91
- stopping: 7;
92
- stopped: 8;
93
- error: 9;
94
- upgrading: 10;
95
- restarting: 11;
96
- corrupted: 12;
97
- waiting: 13;
98
- deleted: 14;
99
- }>;
100
-
101
84
  type RequestParams = {
102
85
  lazy?: boolean;
103
86
  lazyTime?: number;
@@ -236,7 +219,7 @@ declare class ComponentService {
236
219
  constructor({ blocklet }?: {
237
220
  blocklet?: Blocklet;
238
221
  });
239
- getComponent(name: string): BlockletComponent;
222
+ getComponent(name: string): never;
240
223
  getComponentMountPoint(name?: string): string;
241
224
  getUrl(name: string, ...parts: string[]): string;
242
225
  }
@@ -283,7 +266,7 @@ declare class FederatedService {
283
266
  getSourceAppPid(blocklet?: Blocklet): string;
284
267
  getFederatedApp(blocklet?: Blocklet): AppInfo | null;
285
268
  getCurrentApp(blocklet?: Blocklet): AppInfo | ServerInfo;
286
- getApps(blocklet?: Blocklet): (AppInfo | ServerInfo)[];
269
+ getApps(blocklet?: Blocklet): any[];
287
270
  getBlockletData(appUrl: string): Promise<any>;
288
271
  }
289
272
 
@@ -299,7 +282,9 @@ declare class BlockletSDK {
299
282
  constructor();
300
283
  }
301
284
  declare function createAxios(config?: AxiosRequestConfig, requestParams?: RequestParams): axios.AxiosInstance;
302
- declare function createFetch(options?: RequestInit, requestParams?: RequestParams): (input: string | Request | URL, options?: RequestInit) => Promise<Response>;
285
+ declare function createFetch(options?: RequestInit, requestParams?: RequestParams): (input: string | Request | URL, options?: RequestInit & {
286
+ secure?: boolean;
287
+ }) => Promise<Response>;
303
288
  declare const getBlockletSDK: () => BlockletSDK;
304
289
 
305
290
  export { AuthService, BlockletSDK, BlockletService, ComponentService, FederatedService, type NotificationConfig, type PrivacyConfig, type SpaceGateway, TokenService, type UserPublicInfo, type UserSession, UserSessionService, type UserSessionUser, type Webhook, createAxios, createFetch, getBlockletSDK, getCSRFToken };
package/dist/index.d.ts CHANGED
@@ -2,6 +2,7 @@ import * as axios from 'axios';
2
2
  import { Axios, AxiosRequestConfig } from 'axios';
3
3
  import { TTheme, TNavigationItem } from '@blocklet/meta/lib/types';
4
4
  import { TComponentInternalInfo } from '@blocklet/meta/lib/blocklet';
5
+ import { BlockletStatus } from '@blocklet/meta/lib/constants';
5
6
 
6
7
  type UserPublicInfo = {
7
8
  avatar: string;
@@ -80,24 +81,6 @@ declare class TokenService {
80
81
  removeRefreshToken(): void;
81
82
  }
82
83
 
83
- declare const BlockletStatus: Readonly<{
84
- added: 0;
85
- downloading: 1;
86
- downloaded: 2;
87
- installing: 3;
88
- installed: 4;
89
- starting: 5;
90
- running: 6;
91
- stopping: 7;
92
- stopped: 8;
93
- error: 9;
94
- upgrading: 10;
95
- restarting: 11;
96
- corrupted: 12;
97
- waiting: 13;
98
- deleted: 14;
99
- }>;
100
-
101
84
  type RequestParams = {
102
85
  lazy?: boolean;
103
86
  lazyTime?: number;
@@ -236,7 +219,7 @@ declare class ComponentService {
236
219
  constructor({ blocklet }?: {
237
220
  blocklet?: Blocklet;
238
221
  });
239
- getComponent(name: string): BlockletComponent;
222
+ getComponent(name: string): never;
240
223
  getComponentMountPoint(name?: string): string;
241
224
  getUrl(name: string, ...parts: string[]): string;
242
225
  }
@@ -283,7 +266,7 @@ declare class FederatedService {
283
266
  getSourceAppPid(blocklet?: Blocklet): string;
284
267
  getFederatedApp(blocklet?: Blocklet): AppInfo | null;
285
268
  getCurrentApp(blocklet?: Blocklet): AppInfo | ServerInfo;
286
- getApps(blocklet?: Blocklet): (AppInfo | ServerInfo)[];
269
+ getApps(blocklet?: Blocklet): any[];
287
270
  getBlockletData(appUrl: string): Promise<any>;
288
271
  }
289
272
 
@@ -299,7 +282,9 @@ declare class BlockletSDK {
299
282
  constructor();
300
283
  }
301
284
  declare function createAxios(config?: AxiosRequestConfig, requestParams?: RequestParams): axios.AxiosInstance;
302
- declare function createFetch(options?: RequestInit, requestParams?: RequestParams): (input: string | Request | URL, options?: RequestInit) => Promise<Response>;
285
+ declare function createFetch(options?: RequestInit, requestParams?: RequestParams): (input: string | Request | URL, options?: RequestInit & {
286
+ secure?: boolean;
287
+ }) => Promise<Response>;
303
288
  declare const getBlockletSDK: () => BlockletSDK;
304
289
 
305
290
  export { AuthService, BlockletSDK, BlockletService, ComponentService, FederatedService, type NotificationConfig, type PrivacyConfig, type SpaceGateway, TokenService, type UserPublicInfo, type UserSession, UserSessionService, type UserSessionUser, type Webhook, createAxios, createFetch, getBlockletSDK, getCSRFToken };
package/dist/index.mjs CHANGED
@@ -2,7 +2,13 @@ import { WELLKNOWN_SERVICE_PATH_PREFIX, SESSION_TOKEN_STORAGE_KEY, REFRESH_TOKEN
2
2
  import { withQuery, joinURL } from 'ufo';
3
3
  import Cookie from 'js-cookie';
4
4
  import QuickLRU from 'quick-lru';
5
+ import isEmpty from 'lodash/isEmpty';
5
6
  import axios from 'axios';
7
+ import omit from 'lodash/omit';
8
+ import isObject from 'lodash/isObject';
9
+ import stableStringify from 'json-stable-stringify';
10
+ import { fromPublicKey } from '@ocap/wallet';
11
+ import { toTypeInfo } from '@arcblock/did';
6
12
  import isUrl from 'is-url';
7
13
 
8
14
  var __defProp$4 = Object.defineProperty;
@@ -44,6 +50,7 @@ class AuthService {
44
50
  const { data } = await this.api.put("/api/user/notification/webhook", webhook);
45
51
  return data;
46
52
  }
53
+ // eslint-disable-next-line require-await
47
54
  async getProfileUrl({ did, locale }) {
48
55
  const url = `${WELLKNOWN_SERVICE_PATH_PREFIX}/user`;
49
56
  return withQuery(url, {
@@ -56,14 +63,14 @@ class AuthService {
56
63
  return data;
57
64
  }
58
65
  async refreshProfile() {
59
- await this.api.put(`/api/user/refreshProfile`);
66
+ await this.api.put("/api/user/refreshProfile");
60
67
  }
61
68
  async saveProfile({ locale, inviter }) {
62
69
  const { data } = await this.api.put("/api/user/profile", { locale, inviter });
63
70
  return data;
64
71
  }
65
72
  async updateDidSpace({ spaceGateway }) {
66
- await this.api.put(`/api/user/updateDidSpace`, { spaceGateway });
73
+ await this.api.put("/api/user/updateDidSpace", { spaceGateway });
67
74
  }
68
75
  /**
69
76
  *
@@ -114,14 +121,14 @@ class BlockletService {
114
121
  type: "json",
115
122
  t: Date.now()
116
123
  });
117
- return new Promise(async () => {
124
+ return new Promise(async (resolve) => {
118
125
  const res = await fetch(url);
119
126
  const data = await res.json();
120
127
  blockletCache.set(baseUrl, data);
121
- return data;
128
+ resolve(data);
122
129
  });
123
130
  }
124
- async loadBlocklet() {
131
+ loadBlocklet() {
125
132
  return new Promise((resolve, reject) => {
126
133
  if (typeof window === "undefined" || typeof document === "undefined") {
127
134
  reject();
@@ -240,994 +247,6 @@ class ComponentService {
240
247
  }
241
248
  }
242
249
 
243
- var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
244
-
245
- function getDefaultExportFromCjs (x) {
246
- return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
247
- }
248
-
249
- /** Used for built-in method references. */
250
-
251
- var objectProto$6 = Object.prototype;
252
-
253
- /**
254
- * Checks if `value` is likely a prototype object.
255
- *
256
- * @private
257
- * @param {*} value The value to check.
258
- * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.
259
- */
260
- function isPrototype$2(value) {
261
- var Ctor = value && value.constructor,
262
- proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto$6;
263
-
264
- return value === proto;
265
- }
266
-
267
- var _isPrototype = isPrototype$2;
268
-
269
- /**
270
- * Creates a unary function that invokes `func` with its argument transformed.
271
- *
272
- * @private
273
- * @param {Function} func The function to wrap.
274
- * @param {Function} transform The argument transform.
275
- * @returns {Function} Returns the new function.
276
- */
277
-
278
- function overArg$1(func, transform) {
279
- return function(arg) {
280
- return func(transform(arg));
281
- };
282
- }
283
-
284
- var _overArg = overArg$1;
285
-
286
- var overArg = _overArg;
287
-
288
- /* Built-in method references for those with the same name as other `lodash` methods. */
289
- var nativeKeys$1 = overArg(Object.keys, Object);
290
-
291
- var _nativeKeys = nativeKeys$1;
292
-
293
- var isPrototype$1 = _isPrototype,
294
- nativeKeys = _nativeKeys;
295
-
296
- /** Used for built-in method references. */
297
- var objectProto$5 = Object.prototype;
298
-
299
- /** Used to check objects for own properties. */
300
- var hasOwnProperty$4 = objectProto$5.hasOwnProperty;
301
-
302
- /**
303
- * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.
304
- *
305
- * @private
306
- * @param {Object} object The object to query.
307
- * @returns {Array} Returns the array of property names.
308
- */
309
- function baseKeys$1(object) {
310
- if (!isPrototype$1(object)) {
311
- return nativeKeys(object);
312
- }
313
- var result = [];
314
- for (var key in Object(object)) {
315
- if (hasOwnProperty$4.call(object, key) && key != 'constructor') {
316
- result.push(key);
317
- }
318
- }
319
- return result;
320
- }
321
-
322
- var _baseKeys = baseKeys$1;
323
-
324
- /** Detect free variable `global` from Node.js. */
325
-
326
- var freeGlobal$1 = typeof commonjsGlobal == 'object' && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
327
-
328
- var _freeGlobal = freeGlobal$1;
329
-
330
- var freeGlobal = _freeGlobal;
331
-
332
- /** Detect free variable `self`. */
333
- var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
334
-
335
- /** Used as a reference to the global object. */
336
- var root$7 = freeGlobal || freeSelf || Function('return this')();
337
-
338
- var _root = root$7;
339
-
340
- var root$6 = _root;
341
-
342
- /** Built-in value references. */
343
- var Symbol$2 = root$6.Symbol;
344
-
345
- var _Symbol = Symbol$2;
346
-
347
- var Symbol$1 = _Symbol;
348
-
349
- /** Used for built-in method references. */
350
- var objectProto$4 = Object.prototype;
351
-
352
- /** Used to check objects for own properties. */
353
- var hasOwnProperty$3 = objectProto$4.hasOwnProperty;
354
-
355
- /**
356
- * Used to resolve the
357
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
358
- * of values.
359
- */
360
- var nativeObjectToString$1 = objectProto$4.toString;
361
-
362
- /** Built-in value references. */
363
- var symToStringTag$1 = Symbol$1 ? Symbol$1.toStringTag : undefined;
364
-
365
- /**
366
- * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.
367
- *
368
- * @private
369
- * @param {*} value The value to query.
370
- * @returns {string} Returns the raw `toStringTag`.
371
- */
372
- function getRawTag$1(value) {
373
- var isOwn = hasOwnProperty$3.call(value, symToStringTag$1),
374
- tag = value[symToStringTag$1];
375
-
376
- try {
377
- value[symToStringTag$1] = undefined;
378
- var unmasked = true;
379
- } catch (e) {}
380
-
381
- var result = nativeObjectToString$1.call(value);
382
- if (unmasked) {
383
- if (isOwn) {
384
- value[symToStringTag$1] = tag;
385
- } else {
386
- delete value[symToStringTag$1];
387
- }
388
- }
389
- return result;
390
- }
391
-
392
- var _getRawTag = getRawTag$1;
393
-
394
- /** Used for built-in method references. */
395
-
396
- var objectProto$3 = Object.prototype;
397
-
398
- /**
399
- * Used to resolve the
400
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
401
- * of values.
402
- */
403
- var nativeObjectToString = objectProto$3.toString;
404
-
405
- /**
406
- * Converts `value` to a string using `Object.prototype.toString`.
407
- *
408
- * @private
409
- * @param {*} value The value to convert.
410
- * @returns {string} Returns the converted string.
411
- */
412
- function objectToString$1(value) {
413
- return nativeObjectToString.call(value);
414
- }
415
-
416
- var _objectToString = objectToString$1;
417
-
418
- var Symbol = _Symbol,
419
- getRawTag = _getRawTag,
420
- objectToString = _objectToString;
421
-
422
- /** `Object#toString` result references. */
423
- var nullTag = '[object Null]',
424
- undefinedTag = '[object Undefined]';
425
-
426
- /** Built-in value references. */
427
- var symToStringTag = Symbol ? Symbol.toStringTag : undefined;
428
-
429
- /**
430
- * The base implementation of `getTag` without fallbacks for buggy environments.
431
- *
432
- * @private
433
- * @param {*} value The value to query.
434
- * @returns {string} Returns the `toStringTag`.
435
- */
436
- function baseGetTag$4(value) {
437
- if (value == null) {
438
- return value === undefined ? undefinedTag : nullTag;
439
- }
440
- return (symToStringTag && symToStringTag in Object(value))
441
- ? getRawTag(value)
442
- : objectToString(value);
443
- }
444
-
445
- var _baseGetTag = baseGetTag$4;
446
-
447
- /**
448
- * Checks if `value` is the
449
- * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
450
- * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
451
- *
452
- * @static
453
- * @memberOf _
454
- * @since 0.1.0
455
- * @category Lang
456
- * @param {*} value The value to check.
457
- * @returns {boolean} Returns `true` if `value` is an object, else `false`.
458
- * @example
459
- *
460
- * _.isObject({});
461
- * // => true
462
- *
463
- * _.isObject([1, 2, 3]);
464
- * // => true
465
- *
466
- * _.isObject(_.noop);
467
- * // => true
468
- *
469
- * _.isObject(null);
470
- * // => false
471
- */
472
-
473
- function isObject$2(value) {
474
- var type = typeof value;
475
- return value != null && (type == 'object' || type == 'function');
476
- }
477
-
478
- var isObject_1 = isObject$2;
479
-
480
- var baseGetTag$3 = _baseGetTag,
481
- isObject$1 = isObject_1;
482
-
483
- /** `Object#toString` result references. */
484
- var asyncTag = '[object AsyncFunction]',
485
- funcTag$1 = '[object Function]',
486
- genTag = '[object GeneratorFunction]',
487
- proxyTag = '[object Proxy]';
488
-
489
- /**
490
- * Checks if `value` is classified as a `Function` object.
491
- *
492
- * @static
493
- * @memberOf _
494
- * @since 0.1.0
495
- * @category Lang
496
- * @param {*} value The value to check.
497
- * @returns {boolean} Returns `true` if `value` is a function, else `false`.
498
- * @example
499
- *
500
- * _.isFunction(_);
501
- * // => true
502
- *
503
- * _.isFunction(/abc/);
504
- * // => false
505
- */
506
- function isFunction$2(value) {
507
- if (!isObject$1(value)) {
508
- return false;
509
- }
510
- // The use of `Object#toString` avoids issues with the `typeof` operator
511
- // in Safari 9 which returns 'object' for typed arrays and other constructors.
512
- var tag = baseGetTag$3(value);
513
- return tag == funcTag$1 || tag == genTag || tag == asyncTag || tag == proxyTag;
514
- }
515
-
516
- var isFunction_1 = isFunction$2;
517
-
518
- var root$5 = _root;
519
-
520
- /** Used to detect overreaching core-js shims. */
521
- var coreJsData$1 = root$5['__core-js_shared__'];
522
-
523
- var _coreJsData = coreJsData$1;
524
-
525
- var coreJsData = _coreJsData;
526
-
527
- /** Used to detect methods masquerading as native. */
528
- var maskSrcKey = (function() {
529
- var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');
530
- return uid ? ('Symbol(src)_1.' + uid) : '';
531
- }());
532
-
533
- /**
534
- * Checks if `func` has its source masked.
535
- *
536
- * @private
537
- * @param {Function} func The function to check.
538
- * @returns {boolean} Returns `true` if `func` is masked, else `false`.
539
- */
540
- function isMasked$1(func) {
541
- return !!maskSrcKey && (maskSrcKey in func);
542
- }
543
-
544
- var _isMasked = isMasked$1;
545
-
546
- /** Used for built-in method references. */
547
-
548
- var funcProto$1 = Function.prototype;
549
-
550
- /** Used to resolve the decompiled source of functions. */
551
- var funcToString$1 = funcProto$1.toString;
552
-
553
- /**
554
- * Converts `func` to its source code.
555
- *
556
- * @private
557
- * @param {Function} func The function to convert.
558
- * @returns {string} Returns the source code.
559
- */
560
- function toSource$2(func) {
561
- if (func != null) {
562
- try {
563
- return funcToString$1.call(func);
564
- } catch (e) {}
565
- try {
566
- return (func + '');
567
- } catch (e) {}
568
- }
569
- return '';
570
- }
571
-
572
- var _toSource = toSource$2;
573
-
574
- var isFunction$1 = isFunction_1,
575
- isMasked = _isMasked,
576
- isObject = isObject_1,
577
- toSource$1 = _toSource;
578
-
579
- /**
580
- * Used to match `RegExp`
581
- * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
582
- */
583
- var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
584
-
585
- /** Used to detect host constructors (Safari). */
586
- var reIsHostCtor = /^\[object .+?Constructor\]$/;
587
-
588
- /** Used for built-in method references. */
589
- var funcProto = Function.prototype,
590
- objectProto$2 = Object.prototype;
591
-
592
- /** Used to resolve the decompiled source of functions. */
593
- var funcToString = funcProto.toString;
594
-
595
- /** Used to check objects for own properties. */
596
- var hasOwnProperty$2 = objectProto$2.hasOwnProperty;
597
-
598
- /** Used to detect if a method is native. */
599
- var reIsNative = RegExp('^' +
600
- funcToString.call(hasOwnProperty$2).replace(reRegExpChar, '\\$&')
601
- .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
602
- );
603
-
604
- /**
605
- * The base implementation of `_.isNative` without bad shim checks.
606
- *
607
- * @private
608
- * @param {*} value The value to check.
609
- * @returns {boolean} Returns `true` if `value` is a native function,
610
- * else `false`.
611
- */
612
- function baseIsNative$1(value) {
613
- if (!isObject(value) || isMasked(value)) {
614
- return false;
615
- }
616
- var pattern = isFunction$1(value) ? reIsNative : reIsHostCtor;
617
- return pattern.test(toSource$1(value));
618
- }
619
-
620
- var _baseIsNative = baseIsNative$1;
621
-
622
- /**
623
- * Gets the value at `key` of `object`.
624
- *
625
- * @private
626
- * @param {Object} [object] The object to query.
627
- * @param {string} key The key of the property to get.
628
- * @returns {*} Returns the property value.
629
- */
630
-
631
- function getValue$1(object, key) {
632
- return object == null ? undefined : object[key];
633
- }
634
-
635
- var _getValue = getValue$1;
636
-
637
- var baseIsNative = _baseIsNative,
638
- getValue = _getValue;
639
-
640
- /**
641
- * Gets the native function at `key` of `object`.
642
- *
643
- * @private
644
- * @param {Object} object The object to query.
645
- * @param {string} key The key of the method to get.
646
- * @returns {*} Returns the function if it's native, else `undefined`.
647
- */
648
- function getNative$5(object, key) {
649
- var value = getValue(object, key);
650
- return baseIsNative(value) ? value : undefined;
651
- }
652
-
653
- var _getNative = getNative$5;
654
-
655
- var getNative$4 = _getNative,
656
- root$4 = _root;
657
-
658
- /* Built-in method references that are verified to be native. */
659
- var DataView$1 = getNative$4(root$4, 'DataView');
660
-
661
- var _DataView = DataView$1;
662
-
663
- var getNative$3 = _getNative,
664
- root$3 = _root;
665
-
666
- /* Built-in method references that are verified to be native. */
667
- var Map$1 = getNative$3(root$3, 'Map');
668
-
669
- var _Map = Map$1;
670
-
671
- var getNative$2 = _getNative,
672
- root$2 = _root;
673
-
674
- /* Built-in method references that are verified to be native. */
675
- var Promise$2 = getNative$2(root$2, 'Promise');
676
-
677
- var _Promise = Promise$2;
678
-
679
- var getNative$1 = _getNative,
680
- root$1 = _root;
681
-
682
- /* Built-in method references that are verified to be native. */
683
- var Set$1 = getNative$1(root$1, 'Set');
684
-
685
- var _Set = Set$1;
686
-
687
- var getNative = _getNative,
688
- root = _root;
689
-
690
- /* Built-in method references that are verified to be native. */
691
- var WeakMap$1 = getNative(root, 'WeakMap');
692
-
693
- var _WeakMap = WeakMap$1;
694
-
695
- var DataView = _DataView,
696
- Map = _Map,
697
- Promise$1 = _Promise,
698
- Set = _Set,
699
- WeakMap = _WeakMap,
700
- baseGetTag$2 = _baseGetTag,
701
- toSource = _toSource;
702
-
703
- /** `Object#toString` result references. */
704
- var mapTag$2 = '[object Map]',
705
- objectTag$1 = '[object Object]',
706
- promiseTag = '[object Promise]',
707
- setTag$2 = '[object Set]',
708
- weakMapTag$1 = '[object WeakMap]';
709
-
710
- var dataViewTag$1 = '[object DataView]';
711
-
712
- /** Used to detect maps, sets, and weakmaps. */
713
- var dataViewCtorString = toSource(DataView),
714
- mapCtorString = toSource(Map),
715
- promiseCtorString = toSource(Promise$1),
716
- setCtorString = toSource(Set),
717
- weakMapCtorString = toSource(WeakMap);
718
-
719
- /**
720
- * Gets the `toStringTag` of `value`.
721
- *
722
- * @private
723
- * @param {*} value The value to query.
724
- * @returns {string} Returns the `toStringTag`.
725
- */
726
- var getTag$1 = baseGetTag$2;
727
-
728
- // Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.
729
- if ((DataView && getTag$1(new DataView(new ArrayBuffer(1))) != dataViewTag$1) ||
730
- (Map && getTag$1(new Map) != mapTag$2) ||
731
- (Promise$1 && getTag$1(Promise$1.resolve()) != promiseTag) ||
732
- (Set && getTag$1(new Set) != setTag$2) ||
733
- (WeakMap && getTag$1(new WeakMap) != weakMapTag$1)) {
734
- getTag$1 = function(value) {
735
- var result = baseGetTag$2(value),
736
- Ctor = result == objectTag$1 ? value.constructor : undefined,
737
- ctorString = Ctor ? toSource(Ctor) : '';
738
-
739
- if (ctorString) {
740
- switch (ctorString) {
741
- case dataViewCtorString: return dataViewTag$1;
742
- case mapCtorString: return mapTag$2;
743
- case promiseCtorString: return promiseTag;
744
- case setCtorString: return setTag$2;
745
- case weakMapCtorString: return weakMapTag$1;
746
- }
747
- }
748
- return result;
749
- };
750
- }
751
-
752
- var _getTag = getTag$1;
753
-
754
- /**
755
- * Checks if `value` is object-like. A value is object-like if it's not `null`
756
- * and has a `typeof` result of "object".
757
- *
758
- * @static
759
- * @memberOf _
760
- * @since 4.0.0
761
- * @category Lang
762
- * @param {*} value The value to check.
763
- * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
764
- * @example
765
- *
766
- * _.isObjectLike({});
767
- * // => true
768
- *
769
- * _.isObjectLike([1, 2, 3]);
770
- * // => true
771
- *
772
- * _.isObjectLike(_.noop);
773
- * // => false
774
- *
775
- * _.isObjectLike(null);
776
- * // => false
777
- */
778
-
779
- function isObjectLike$3(value) {
780
- return value != null && typeof value == 'object';
781
- }
782
-
783
- var isObjectLike_1 = isObjectLike$3;
784
-
785
- var baseGetTag$1 = _baseGetTag,
786
- isObjectLike$2 = isObjectLike_1;
787
-
788
- /** `Object#toString` result references. */
789
- var argsTag$1 = '[object Arguments]';
790
-
791
- /**
792
- * The base implementation of `_.isArguments`.
793
- *
794
- * @private
795
- * @param {*} value The value to check.
796
- * @returns {boolean} Returns `true` if `value` is an `arguments` object,
797
- */
798
- function baseIsArguments$1(value) {
799
- return isObjectLike$2(value) && baseGetTag$1(value) == argsTag$1;
800
- }
801
-
802
- var _baseIsArguments = baseIsArguments$1;
803
-
804
- var baseIsArguments = _baseIsArguments,
805
- isObjectLike$1 = isObjectLike_1;
806
-
807
- /** Used for built-in method references. */
808
- var objectProto$1 = Object.prototype;
809
-
810
- /** Used to check objects for own properties. */
811
- var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
812
-
813
- /** Built-in value references. */
814
- var propertyIsEnumerable = objectProto$1.propertyIsEnumerable;
815
-
816
- /**
817
- * Checks if `value` is likely an `arguments` object.
818
- *
819
- * @static
820
- * @memberOf _
821
- * @since 0.1.0
822
- * @category Lang
823
- * @param {*} value The value to check.
824
- * @returns {boolean} Returns `true` if `value` is an `arguments` object,
825
- * else `false`.
826
- * @example
827
- *
828
- * _.isArguments(function() { return arguments; }());
829
- * // => true
830
- *
831
- * _.isArguments([1, 2, 3]);
832
- * // => false
833
- */
834
- var isArguments$1 = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {
835
- return isObjectLike$1(value) && hasOwnProperty$1.call(value, 'callee') &&
836
- !propertyIsEnumerable.call(value, 'callee');
837
- };
838
-
839
- var isArguments_1 = isArguments$1;
840
-
841
- /**
842
- * Checks if `value` is classified as an `Array` object.
843
- *
844
- * @static
845
- * @memberOf _
846
- * @since 0.1.0
847
- * @category Lang
848
- * @param {*} value The value to check.
849
- * @returns {boolean} Returns `true` if `value` is an array, else `false`.
850
- * @example
851
- *
852
- * _.isArray([1, 2, 3]);
853
- * // => true
854
- *
855
- * _.isArray(document.body.children);
856
- * // => false
857
- *
858
- * _.isArray('abc');
859
- * // => false
860
- *
861
- * _.isArray(_.noop);
862
- * // => false
863
- */
864
-
865
- var isArray$1 = Array.isArray;
866
-
867
- var isArray_1 = isArray$1;
868
-
869
- /** Used as references for various `Number` constants. */
870
-
871
- var MAX_SAFE_INTEGER = 9007199254740991;
872
-
873
- /**
874
- * Checks if `value` is a valid array-like length.
875
- *
876
- * **Note:** This method is loosely based on
877
- * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).
878
- *
879
- * @static
880
- * @memberOf _
881
- * @since 4.0.0
882
- * @category Lang
883
- * @param {*} value The value to check.
884
- * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
885
- * @example
886
- *
887
- * _.isLength(3);
888
- * // => true
889
- *
890
- * _.isLength(Number.MIN_VALUE);
891
- * // => false
892
- *
893
- * _.isLength(Infinity);
894
- * // => false
895
- *
896
- * _.isLength('3');
897
- * // => false
898
- */
899
- function isLength$2(value) {
900
- return typeof value == 'number' &&
901
- value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
902
- }
903
-
904
- var isLength_1 = isLength$2;
905
-
906
- var isFunction = isFunction_1,
907
- isLength$1 = isLength_1;
908
-
909
- /**
910
- * Checks if `value` is array-like. A value is considered array-like if it's
911
- * not a function and has a `value.length` that's an integer greater than or
912
- * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.
913
- *
914
- * @static
915
- * @memberOf _
916
- * @since 4.0.0
917
- * @category Lang
918
- * @param {*} value The value to check.
919
- * @returns {boolean} Returns `true` if `value` is array-like, else `false`.
920
- * @example
921
- *
922
- * _.isArrayLike([1, 2, 3]);
923
- * // => true
924
- *
925
- * _.isArrayLike(document.body.children);
926
- * // => true
927
- *
928
- * _.isArrayLike('abc');
929
- * // => true
930
- *
931
- * _.isArrayLike(_.noop);
932
- * // => false
933
- */
934
- function isArrayLike$1(value) {
935
- return value != null && isLength$1(value.length) && !isFunction(value);
936
- }
937
-
938
- var isArrayLike_1 = isArrayLike$1;
939
-
940
- var isBuffer$1 = {exports: {}};
941
-
942
- /**
943
- * This method returns `false`.
944
- *
945
- * @static
946
- * @memberOf _
947
- * @since 4.13.0
948
- * @category Util
949
- * @returns {boolean} Returns `false`.
950
- * @example
951
- *
952
- * _.times(2, _.stubFalse);
953
- * // => [false, false]
954
- */
955
-
956
- function stubFalse() {
957
- return false;
958
- }
959
-
960
- var stubFalse_1 = stubFalse;
961
-
962
- isBuffer$1.exports;
963
-
964
- (function (module, exports) {
965
- var root = _root,
966
- stubFalse = stubFalse_1;
967
-
968
- /** Detect free variable `exports`. */
969
- var freeExports = exports && !exports.nodeType && exports;
970
-
971
- /** Detect free variable `module`. */
972
- var freeModule = freeExports && 'object' == 'object' && module && !module.nodeType && module;
973
-
974
- /** Detect the popular CommonJS extension `module.exports`. */
975
- var moduleExports = freeModule && freeModule.exports === freeExports;
976
-
977
- /** Built-in value references. */
978
- var Buffer = moduleExports ? root.Buffer : undefined;
979
-
980
- /* Built-in method references for those with the same name as other `lodash` methods. */
981
- var nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;
982
-
983
- /**
984
- * Checks if `value` is a buffer.
985
- *
986
- * @static
987
- * @memberOf _
988
- * @since 4.3.0
989
- * @category Lang
990
- * @param {*} value The value to check.
991
- * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.
992
- * @example
993
- *
994
- * _.isBuffer(new Buffer(2));
995
- * // => true
996
- *
997
- * _.isBuffer(new Uint8Array(2));
998
- * // => false
999
- */
1000
- var isBuffer = nativeIsBuffer || stubFalse;
1001
-
1002
- module.exports = isBuffer;
1003
- } (isBuffer$1, isBuffer$1.exports));
1004
-
1005
- var isBufferExports = isBuffer$1.exports;
1006
-
1007
- var baseGetTag = _baseGetTag,
1008
- isLength = isLength_1,
1009
- isObjectLike = isObjectLike_1;
1010
-
1011
- /** `Object#toString` result references. */
1012
- var argsTag = '[object Arguments]',
1013
- arrayTag = '[object Array]',
1014
- boolTag = '[object Boolean]',
1015
- dateTag = '[object Date]',
1016
- errorTag = '[object Error]',
1017
- funcTag = '[object Function]',
1018
- mapTag$1 = '[object Map]',
1019
- numberTag = '[object Number]',
1020
- objectTag = '[object Object]',
1021
- regexpTag = '[object RegExp]',
1022
- setTag$1 = '[object Set]',
1023
- stringTag = '[object String]',
1024
- weakMapTag = '[object WeakMap]';
1025
-
1026
- var arrayBufferTag = '[object ArrayBuffer]',
1027
- dataViewTag = '[object DataView]',
1028
- float32Tag = '[object Float32Array]',
1029
- float64Tag = '[object Float64Array]',
1030
- int8Tag = '[object Int8Array]',
1031
- int16Tag = '[object Int16Array]',
1032
- int32Tag = '[object Int32Array]',
1033
- uint8Tag = '[object Uint8Array]',
1034
- uint8ClampedTag = '[object Uint8ClampedArray]',
1035
- uint16Tag = '[object Uint16Array]',
1036
- uint32Tag = '[object Uint32Array]';
1037
-
1038
- /** Used to identify `toStringTag` values of typed arrays. */
1039
- var typedArrayTags = {};
1040
- typedArrayTags[float32Tag] = typedArrayTags[float64Tag] =
1041
- typedArrayTags[int8Tag] = typedArrayTags[int16Tag] =
1042
- typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =
1043
- typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =
1044
- typedArrayTags[uint32Tag] = true;
1045
- typedArrayTags[argsTag] = typedArrayTags[arrayTag] =
1046
- typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =
1047
- typedArrayTags[dataViewTag] = typedArrayTags[dateTag] =
1048
- typedArrayTags[errorTag] = typedArrayTags[funcTag] =
1049
- typedArrayTags[mapTag$1] = typedArrayTags[numberTag] =
1050
- typedArrayTags[objectTag] = typedArrayTags[regexpTag] =
1051
- typedArrayTags[setTag$1] = typedArrayTags[stringTag] =
1052
- typedArrayTags[weakMapTag] = false;
1053
-
1054
- /**
1055
- * The base implementation of `_.isTypedArray` without Node.js optimizations.
1056
- *
1057
- * @private
1058
- * @param {*} value The value to check.
1059
- * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.
1060
- */
1061
- function baseIsTypedArray$1(value) {
1062
- return isObjectLike(value) &&
1063
- isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
1064
- }
1065
-
1066
- var _baseIsTypedArray = baseIsTypedArray$1;
1067
-
1068
- /**
1069
- * The base implementation of `_.unary` without support for storing metadata.
1070
- *
1071
- * @private
1072
- * @param {Function} func The function to cap arguments for.
1073
- * @returns {Function} Returns the new capped function.
1074
- */
1075
-
1076
- function baseUnary$1(func) {
1077
- return function(value) {
1078
- return func(value);
1079
- };
1080
- }
1081
-
1082
- var _baseUnary = baseUnary$1;
1083
-
1084
- var _nodeUtil = {exports: {}};
1085
-
1086
- _nodeUtil.exports;
1087
-
1088
- (function (module, exports) {
1089
- var freeGlobal = _freeGlobal;
1090
-
1091
- /** Detect free variable `exports`. */
1092
- var freeExports = exports && !exports.nodeType && exports;
1093
-
1094
- /** Detect free variable `module`. */
1095
- var freeModule = freeExports && 'object' == 'object' && module && !module.nodeType && module;
1096
-
1097
- /** Detect the popular CommonJS extension `module.exports`. */
1098
- var moduleExports = freeModule && freeModule.exports === freeExports;
1099
-
1100
- /** Detect free variable `process` from Node.js. */
1101
- var freeProcess = moduleExports && freeGlobal.process;
1102
-
1103
- /** Used to access faster Node.js helpers. */
1104
- var nodeUtil = (function() {
1105
- try {
1106
- // Use `util.types` for Node.js 10+.
1107
- var types = freeModule && freeModule.require && freeModule.require('util').types;
1108
-
1109
- if (types) {
1110
- return types;
1111
- }
1112
-
1113
- // Legacy `process.binding('util')` for Node.js < 10.
1114
- return freeProcess && freeProcess.binding && freeProcess.binding('util');
1115
- } catch (e) {}
1116
- }());
1117
-
1118
- module.exports = nodeUtil;
1119
- } (_nodeUtil, _nodeUtil.exports));
1120
-
1121
- var _nodeUtilExports = _nodeUtil.exports;
1122
-
1123
- var baseIsTypedArray = _baseIsTypedArray,
1124
- baseUnary = _baseUnary,
1125
- nodeUtil = _nodeUtilExports;
1126
-
1127
- /* Node.js helper references. */
1128
- var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;
1129
-
1130
- /**
1131
- * Checks if `value` is classified as a typed array.
1132
- *
1133
- * @static
1134
- * @memberOf _
1135
- * @since 3.0.0
1136
- * @category Lang
1137
- * @param {*} value The value to check.
1138
- * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.
1139
- * @example
1140
- *
1141
- * _.isTypedArray(new Uint8Array);
1142
- * // => true
1143
- *
1144
- * _.isTypedArray([]);
1145
- * // => false
1146
- */
1147
- var isTypedArray$1 = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
1148
-
1149
- var isTypedArray_1 = isTypedArray$1;
1150
-
1151
- var baseKeys = _baseKeys,
1152
- getTag = _getTag,
1153
- isArguments = isArguments_1,
1154
- isArray = isArray_1,
1155
- isArrayLike = isArrayLike_1,
1156
- isBuffer = isBufferExports,
1157
- isPrototype = _isPrototype,
1158
- isTypedArray = isTypedArray_1;
1159
-
1160
- /** `Object#toString` result references. */
1161
- var mapTag = '[object Map]',
1162
- setTag = '[object Set]';
1163
-
1164
- /** Used for built-in method references. */
1165
- var objectProto = Object.prototype;
1166
-
1167
- /** Used to check objects for own properties. */
1168
- var hasOwnProperty = objectProto.hasOwnProperty;
1169
-
1170
- /**
1171
- * Checks if `value` is an empty object, collection, map, or set.
1172
- *
1173
- * Objects are considered empty if they have no own enumerable string keyed
1174
- * properties.
1175
- *
1176
- * Array-like values such as `arguments` objects, arrays, buffers, strings, or
1177
- * jQuery-like collections are considered empty if they have a `length` of `0`.
1178
- * Similarly, maps and sets are considered empty if they have a `size` of `0`.
1179
- *
1180
- * @static
1181
- * @memberOf _
1182
- * @since 0.1.0
1183
- * @category Lang
1184
- * @param {*} value The value to check.
1185
- * @returns {boolean} Returns `true` if `value` is empty, else `false`.
1186
- * @example
1187
- *
1188
- * _.isEmpty(null);
1189
- * // => true
1190
- *
1191
- * _.isEmpty(true);
1192
- * // => true
1193
- *
1194
- * _.isEmpty(1);
1195
- * // => true
1196
- *
1197
- * _.isEmpty([1, 2, 3]);
1198
- * // => false
1199
- *
1200
- * _.isEmpty({ 'a': 1 });
1201
- * // => false
1202
- */
1203
- function isEmpty(value) {
1204
- if (value == null) {
1205
- return true;
1206
- }
1207
- if (isArrayLike(value) &&
1208
- (isArray(value) || typeof value == 'string' || typeof value.splice == 'function' ||
1209
- isBuffer(value) || isTypedArray(value) || isArguments(value))) {
1210
- return !value.length;
1211
- }
1212
- var tag = getTag(value);
1213
- if (tag == mapTag || tag == setTag) {
1214
- return !value.size;
1215
- }
1216
- if (isPrototype(value)) {
1217
- return !baseKeys(value).length;
1218
- }
1219
- for (var key in value) {
1220
- if (hasOwnProperty.call(value, key)) {
1221
- return false;
1222
- }
1223
- }
1224
- return true;
1225
- }
1226
-
1227
- var isEmpty_1 = isEmpty;
1228
-
1229
- const isEmpty$1 = /*@__PURE__*/getDefaultExportFromCjs(isEmpty_1);
1230
-
1231
250
  var __defProp$1 = Object.defineProperty;
1232
251
  var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1233
252
  var __publicField$1 = (obj, key, value) => {
@@ -1263,8 +282,11 @@ class FederatedService {
1263
282
  }
1264
283
  getFederatedApp(blocklet = this.blocklet.getBlocklet()) {
1265
284
  const master = this.getMaster(blocklet);
1266
- const isFederatedMode = !isEmpty$1(master);
1267
- return isFederatedMode ? {
285
+ const isFederatedMode = !isEmpty(master);
286
+ if (!isFederatedMode) {
287
+ return null;
288
+ }
289
+ return {
1268
290
  appId: master.appId,
1269
291
  appName: master.appName,
1270
292
  appDescription: master.appDescription,
@@ -1274,7 +296,7 @@ class FederatedService {
1274
296
  version: master.version,
1275
297
  sourceAppPid: master.appPid,
1276
298
  provider: "wallet"
1277
- } : null;
299
+ };
1278
300
  }
1279
301
  getCurrentApp(blocklet = this.blocklet.getBlocklet()) {
1280
302
  if (blocklet) {
@@ -1349,6 +371,21 @@ const visitorIdKey = "__visitor_id";
1349
371
  const getVisitorId = () => {
1350
372
  return localStorage.getItem(visitorIdKey);
1351
373
  };
374
+ const verifyResponse = (response, onInvalid) => {
375
+ if (isObject(response.data) && response.status >= 200 && response.status < 300 && window.blocklet && window.blocklet.appId && window.blocklet.appPk) {
376
+ if (!response.data.$signature) {
377
+ onInvalid();
378
+ throw new Error("Invalid response");
379
+ }
380
+ const { appId, appPk } = window.blocklet;
381
+ const wallet = fromPublicKey(appPk, toTypeInfo(appId));
382
+ if (wallet.verify(stableStringify(omit(response.data, ["$signature"])), response.data.$signature) === false) {
383
+ onInvalid();
384
+ throw new Error("Invalid response");
385
+ }
386
+ }
387
+ return response;
388
+ };
1352
389
 
1353
390
  function getCSRFToken() {
1354
391
  return Cookie.get("x-csrf-token");
@@ -1418,6 +455,7 @@ async function renewRefreshToken$1(refreshToken) {
1418
455
  const refreshApi = createAxios$1({
1419
456
  baseURL: WELLKNOWN_SERVICE_PATH_PREFIX,
1420
457
  timeout: 10 * 1e3,
458
+ secure: true,
1421
459
  headers: {
1422
460
  authorization: getBearerToken(refreshToken)
1423
461
  }
@@ -1459,7 +497,15 @@ function createRequest$1({
1459
497
  (error) => Promise.reject(error)
1460
498
  );
1461
499
  service.interceptors.response.use(
1462
- (response) => response,
500
+ (response) => {
501
+ if (response.config?.secure) {
502
+ return verifyResponse(response, () => {
503
+ removeSessionToken();
504
+ removeRefreshToken();
505
+ });
506
+ }
507
+ return response;
508
+ },
1463
509
  async (error) => {
1464
510
  const originalRequest = error.config;
1465
511
  if (originalRequest) {
@@ -1613,6 +659,12 @@ function createRequest({
1613
659
  refreshingTokenRequest = null;
1614
660
  }
1615
661
  }
662
+ if (res.ok && options?.secure) {
663
+ verifyResponse({ status: res.status, data: await res.json() }, () => {
664
+ removeSessionToken();
665
+ removeRefreshToken();
666
+ });
667
+ }
1616
668
  return res;
1617
669
  };
1618
670
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blocklet/js-sdk",
3
- "version": "1.16.34-beta-20241207-134904-3c3d9a35",
3
+ "version": "1.16.34-beta-20241212-152152-0b8d4bb3",
4
4
  "main": "dist/index.mjs",
5
5
  "module": "dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",
@@ -28,22 +28,42 @@
28
28
  },
29
29
  "scripts": {
30
30
  "build:blocklet-js-sdk": "npm run build",
31
+ "lint": "eslint src",
32
+ "lint:fix": "npm run lint -- --fix",
33
+ "prebuild": "npm run clean",
34
+ "clean": "rm -fr dist",
35
+ "test": "vitest",
36
+ "coverage": "CI=1 vitest --coverage",
31
37
  "build": "unbuild",
32
38
  "watch": "nodemon -w src -e ts -x 'npm run build'"
33
39
  },
34
40
  "dependencies": {
35
- "@abtnode/constant": "1.16.34-beta-20241207-134904-3c3d9a35",
36
- "@blocklet/meta": "1.16.34-beta-20241207-134904-3c3d9a35",
41
+ "@abtnode/constant": "1.16.34-beta-20241212-152152-0b8d4bb3",
42
+ "@arcblock/did": "1.18.161",
43
+ "@blocklet/meta": "1.16.34-beta-20241212-152152-0b8d4bb3",
44
+ "@ocap/wallet": "1.18.161",
37
45
  "axios": "^1.7.5",
38
46
  "is-url": "^1.2.4",
39
47
  "js-cookie": "^3.0.5",
48
+ "json-stable-stringify": "^1.0.1",
49
+ "lodash": "^4.17.21",
40
50
  "quick-lru": "^7.0.0",
41
51
  "ufo": "^1.5.3"
42
52
  },
43
53
  "devDependencies": {
54
+ "@arcblock/eslint-config-ts": "^0.3.3",
44
55
  "@types/is-url": "^1.2.32",
56
+ "@types/json-stable-stringify": "^1.0.36",
57
+ "@types/lodash": "^4.17.10",
58
+ "@types/node": "^22.7.5",
59
+ "@typescript-eslint/eslint-plugin": "^5.42.0",
60
+ "@typescript-eslint/parser": "^5.42.0",
61
+ "eslint": "^8.57.0",
62
+ "json-stable-stringify": "^1.0.1",
63
+ "prettier": "^3.3.2",
64
+ "typescript": "^5.6.3",
45
65
  "unbuild": "^2.0.0",
46
66
  "vitest": "^2.0.5"
47
67
  },
48
- "gitHead": "75e87cd61f4978a8fc0e6f335492abc891aed082"
68
+ "gitHead": "999b6d7c9e4458844d001671bb9d538255307fc5"
49
69
  }