@hugo.ye/common 1.0.135 → 1.0.139

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/build/constants/global.d.ts +2 -0
  2. package/build/constants/global.d.ts.map +1 -0
  3. package/build/constants/global.js +2 -0
  4. package/build/constants/global.js.map +1 -0
  5. package/build/constants/index.d.ts +1 -0
  6. package/build/constants/index.d.ts.map +1 -1
  7. package/build/constants/index.js +1 -0
  8. package/build/constants/index.js.map +1 -1
  9. package/build/decorators/access.decorator.d.ts +1 -1
  10. package/build/decorators/access.decorator.d.ts.map +1 -1
  11. package/build/decorators/access.decorator.js +1 -1
  12. package/build/decorators/access.decorator.js.map +1 -1
  13. package/build/decorators/index.d.ts +1 -0
  14. package/build/decorators/index.d.ts.map +1 -1
  15. package/build/decorators/index.js +1 -0
  16. package/build/decorators/index.js.map +1 -1
  17. package/build/decorators/verify-access.decorator.d.ts +2 -0
  18. package/build/decorators/verify-access.decorator.d.ts.map +1 -0
  19. package/build/decorators/verify-access.decorator.js +4 -0
  20. package/build/decorators/verify-access.decorator.js.map +1 -0
  21. package/build/guards/index.d.ts +2 -0
  22. package/build/guards/index.d.ts.map +1 -0
  23. package/build/guards/index.js +2 -0
  24. package/build/guards/index.js.map +1 -0
  25. package/build/guards/verify-access.guard.d.ts +8 -0
  26. package/build/guards/verify-access.guard.d.ts.map +1 -0
  27. package/build/guards/verify-access.guard.js +52 -0
  28. package/build/guards/verify-access.guard.js.map +1 -0
  29. package/build/index.d.ts +1 -0
  30. package/build/index.d.ts.map +1 -1
  31. package/build/index.js +1 -0
  32. package/build/index.js.map +1 -1
  33. package/package.json +1 -1
@@ -0,0 +1,2 @@
1
+ export declare const VERIFY_ACCESS_KEY = "verifyAccess";
2
+ //# sourceMappingURL=global.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"global.d.ts","sourceRoot":"","sources":["../../src/constants/global.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,iBAAiB,iBAAiB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export const VERIFY_ACCESS_KEY = 'verifyAccess';
2
+ //# sourceMappingURL=global.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"global.js","sourceRoot":"","sources":["../../src/constants/global.ts"],"names":[],"mappings":"AACA,MAAM,CAAC,MAAM,iBAAiB,GAAG,cAAc,CAAC"}
@@ -1,4 +1,5 @@
1
1
  export * from './services.ts';
2
2
  export * from './patterns.ts';
3
3
  export * from './queue.ts';
4
+ export * from './global.ts';
4
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/constants/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/constants/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC"}
@@ -1,4 +1,5 @@
1
1
  export * from "./services.js";
2
2
  export * from "./patterns.js";
3
3
  export * from "./queue.js";
4
+ export * from "./global.js";
4
5
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/constants/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/constants/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC"}
@@ -1,2 +1,2 @@
1
- export declare const VerifyAccess: (...dataOrPipes: (string[] | import("@nestjs/common").PipeTransform<any, any> | import("@nestjs/common").Type<import("@nestjs/common").PipeTransform<any, any>>)[]) => ParameterDecorator;
1
+ export declare const _VerifyAccess: (...dataOrPipes: (string[] | import("@nestjs/common").PipeTransform<any, any> | import("@nestjs/common").Type<import("@nestjs/common").PipeTransform<any, any>>)[]) => ParameterDecorator;
2
2
  //# sourceMappingURL=access.decorator.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"access.decorator.d.ts","sourceRoot":"","sources":["../../src/decorators/access.decorator.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,YAAY,2LAqBxB,CAAC"}
1
+ {"version":3,"file":"access.decorator.d.ts","sourceRoot":"","sources":["../../src/decorators/access.decorator.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,aAAa,2LAqBzB,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import { SetMetadata, createParamDecorator, UnauthorizedException, } from '@nestjs/common';
2
2
  import { flattenNestedPermissions, RoleEntity } from '../index.js';
3
3
  // export const Visitor = (...permissions: string[]) => SetMetadata('permissions', permissions);
4
- export const VerifyAccess = createParamDecorator((accessPermissions, context) => {
4
+ export const _VerifyAccess = createParamDecorator((accessPermissions, context) => {
5
5
  const user = context.getType() === 'http'
6
6
  ? context.switchToHttp().getRequest().user
7
7
  : context.getArgs()[2].req.headers?.user
@@ -1 +1 @@
1
- {"version":3,"file":"access.decorator.js","sourceRoot":"","sources":["../../src/decorators/access.decorator.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EAEX,oBAAoB,EACpB,qBAAqB,GACtB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,wBAAwB,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEnE,gGAAgG;AAEhG,MAAM,CAAC,MAAM,YAAY,GAAG,oBAAoB,CAC9C,CAAC,iBAA2B,EAAE,OAAyB,EAAW,EAAE;IAClE,MAAM,IAAI,GACR,OAAO,CAAC,OAAO,EAAE,KAAK,MAAM;QAC1B,CAAC,CAAC,OAAO,CAAC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AoB,CAC/C,CAAC,iBAA2B,EAAE,OAAyB,EAAW,EAAE;IAClE,MAAM,IAAI,GACR,OAAO,CAAC,OAAO,EAAE,KAAK,MAAM;QAC1B,CAAC,CAAC,OAAO,CAAC,YAAY,EAAE,CAAC,UAAU,EAAE,CAAC,IAAI;QAC1C,CAAC,CAAC,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,EAAE,IAAI;YACtC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,EAAE,IAAI,CAAC;YACpD,CAAC,CAAC,IAAI,CAAC;IACb,IAAI,IAAI,EAAE,CAAC;QACT,MAAM,eAAe,GAAG,IAAI,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC,IAAgB,EAAE,EAAE,CAC3D,IAAI,CAAC,WAAW,EAAE,GAAG,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,CACvE,CAAC;QACF,MAAM,MAAM,GAAG,eAAe,CAAC,CAAC,CAAC,wBAAwB,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;QAChF,KAAK,MAAM,UAAU,IAAI,iBAAiB,EAAE,CAAC;YAC3C,IAAI,MAAM,CAAC,UAAU,CAAC;gBAAE,OAAO,IAAI,CAAC;QACtC,CAAC;QACD,MAAM,IAAI,qBAAqB,CAAC,MAAM,CAAC,CAAC;IAC1C,CAAC;SAAM,CAAC;QACN,MAAM,IAAI,qBAAqB,CAAC,MAAM,CAAC,CAAC;IAC1C,CAAC;AACH,CAAC,CACF,CAAC"}
@@ -4,4 +4,5 @@ export * from './gql-current-user.decorator.ts';
4
4
  export * from './current-member.decorato.ts';
5
5
  export * from './gql-current-member.decorator.ts';
6
6
  export * from './access.decorator.ts';
7
+ export * from './verify-access.decorator.ts';
7
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/decorators/index.ts"],"names":[],"mappings":"AAAA,cAAc,6BAA6B,CAAC;AAC5C,cAAc,qBAAqB,CAAC;AACpC,cAAc,iCAAiC,CAAC;AAChD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,mCAAmC,CAAC;AAClD,cAAc,uBAAuB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/decorators/index.ts"],"names":[],"mappings":"AAAA,cAAc,6BAA6B,CAAC;AAC5C,cAAc,qBAAqB,CAAC;AACpC,cAAc,iCAAiC,CAAC;AAChD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,mCAAmC,CAAC;AAClD,cAAc,uBAAuB,CAAC;AACtC,cAAc,8BAA8B,CAAC"}
@@ -4,4 +4,5 @@ export * from "./gql-current-user.decorator.js";
4
4
  export * from "./current-member.decorato.js";
5
5
  export * from "./gql-current-member.decorator.js";
6
6
  export * from "./access.decorator.js";
7
+ export * from "./verify-access.decorator.js";
7
8
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/decorators/index.ts"],"names":[],"mappings":"AAAA,cAAc,6BAA6B,CAAC;AAC5C,cAAc,qBAAqB,CAAC;AACpC,cAAc,iCAAiC,CAAC;AAChD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,mCAAmC,CAAC;AAClD,cAAc,uBAAuB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/decorators/index.ts"],"names":[],"mappings":"AAAA,cAAc,6BAA6B,CAAC;AAC5C,cAAc,qBAAqB,CAAC;AACpC,cAAc,iCAAiC,CAAC;AAChD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,mCAAmC,CAAC;AAClD,cAAc,uBAAuB,CAAC;AACtC,cAAc,8BAA8B,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const VerifyAccess: (...permissions: string[]) => import("@nestjs/common").CustomDecorator<string>;
2
+ //# sourceMappingURL=verify-access.decorator.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verify-access.decorator.d.ts","sourceRoot":"","sources":["../../src/decorators/verify-access.decorator.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,YAAY,GAAI,GAAG,aAAa,MAAM,EAAE,qDACR,CAAC"}
@@ -0,0 +1,4 @@
1
+ import { VERIFY_ACCESS_KEY } from '@app/constants';
2
+ import { SetMetadata } from '@nestjs/common';
3
+ export const VerifyAccess = (...permissions) => SetMetadata(VERIFY_ACCESS_KEY, permissions);
4
+ //# sourceMappingURL=verify-access.decorator.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verify-access.decorator.js","sourceRoot":"","sources":["../../src/decorators/verify-access.decorator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACnD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,GAAG,WAAqB,EAAE,EAAE,CACvD,WAAW,CAAC,iBAAiB,EAAE,WAAW,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from './verify-access.guard.ts';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/guards/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from "./verify-access.guard.js";
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/guards/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { type CanActivate, type ExecutionContext } from '@nestjs/common';
2
+ import { Reflector } from '@nestjs/core';
3
+ export declare class VerifyAccessGuard implements CanActivate {
4
+ private reflector;
5
+ constructor(reflector: Reflector);
6
+ canActivate(context: ExecutionContext): boolean;
7
+ }
8
+ //# sourceMappingURL=verify-access.guard.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verify-access.guard.d.ts","sourceRoot":"","sources":["../../src/guards/verify-access.guard.ts"],"names":[],"mappings":"AACA,OAAO,EAGL,KAAK,WAAW,EAChB,KAAK,gBAAgB,EACtB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAGzC,qBACa,iBAAkB,YAAW,WAAW;IACvC,OAAO,CAAC,SAAS;gBAAT,SAAS,EAAE,SAAS;IAExC,WAAW,CAAC,OAAO,EAAE,gBAAgB,GAAG,OAAO;CA2ChD"}
@@ -0,0 +1,52 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ // guards/verify-access.guard.ts
11
+ import { Injectable, UnauthorizedException, } from '@nestjs/common';
12
+ import { Reflector } from '@nestjs/core';
13
+ import { flattenNestedPermissions, RoleEntity, VERIFY_ACCESS_KEY } from '../index.js';
14
+ let VerifyAccessGuard = class VerifyAccessGuard {
15
+ reflector;
16
+ constructor(reflector) {
17
+ this.reflector = reflector;
18
+ }
19
+ canActivate(context) {
20
+ // 获取装饰器中定义的权限
21
+ const requiredPermissions = this.reflector.get(VERIFY_ACCESS_KEY, context.getHandler());
22
+ if (!requiredPermissions || requiredPermissions.length === 0) {
23
+ return true; // 没有权限要求,直接通过
24
+ }
25
+ // 获取用户
26
+ const user = context.getType() === 'http'
27
+ ? context.switchToHttp().getRequest().user
28
+ : context.getArgs()[2]?.req?.headers?.user
29
+ ? JSON.parse(context.getArgs()[2].req.headers.user)
30
+ : null;
31
+ if (!user) {
32
+ throw new UnauthorizedException('请先登陆');
33
+ }
34
+ // 获取用户权限
35
+ const userPermissions = user.roles?.map((role) => role.permissions?.map((permission) => ({ [permission.action]: true })));
36
+ const access = userPermissions
37
+ ? flattenNestedPermissions(userPermissions)
38
+ : {};
39
+ // 检查是否有所需权限
40
+ const hasPermission = requiredPermissions.some((permission) => access[permission]);
41
+ if (!hasPermission) {
42
+ throw new UnauthorizedException(`权限不足,需要以下权限之一: ${requiredPermissions.join(', ')}`);
43
+ }
44
+ return true;
45
+ }
46
+ };
47
+ VerifyAccessGuard = __decorate([
48
+ Injectable(),
49
+ __metadata("design:paramtypes", [Reflector])
50
+ ], VerifyAccessGuard);
51
+ export { VerifyAccessGuard };
52
+ //# sourceMappingURL=verify-access.guard.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verify-access.guard.js","sourceRoot":"","sources":["../../src/guards/verify-access.guard.ts"],"names":[],"mappings":";;;;;;;;;AAAA,gCAAgC;AAChC,OAAO,EACL,UAAU,EACV,qBAAqB,GAGtB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,wBAAwB,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAG/E,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB;IACR;IAApB,YAAoB,SAAoB;QAApB,cAAS,GAAT,SAAS,CAAW;IAAG,CAAC;IAE5C,WAAW,CAAC,OAAyB;QACnC,cAAc;QACd,MAAM,mBAAmB,GAAG,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CAAC;YACnB,MAAM,IAAI,qBAAqB,CAC7B,kBAAkB,mBAAmB,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CACnD,CAAC;QACJ,CAAC;QAED,OAAO,IAAI,CAAC;IACd,CAAC;CACF,CAAA;AA9CY,iBAAiB;IAD7B,UAAU,EAAE;qCAEoB,SAAS;GAD7B,iBAAiB,CA8C7B"}
package/build/index.d.ts CHANGED
@@ -11,4 +11,5 @@ export * from './paginate/dto/index.ts';
11
11
  export * from './repositories/index.ts';
12
12
  export * from './utils/index.ts';
13
13
  export * from './enums/index.ts';
14
+ export * from './guards/index.ts';
14
15
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,kBAAkB,CAAC;AACjC,cAAc,yBAAyB,CAAC;AACxC,cAAc,yBAAyB,CAAC;AACxC,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,kBAAkB,CAAC;AACjC,cAAc,yBAAyB,CAAC;AACxC,cAAc,yBAAyB,CAAC;AACxC,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC"}
package/build/index.js CHANGED
@@ -11,4 +11,5 @@ export * from "./paginate/dto/index.js";
11
11
  export * from "./repositories/index.js";
12
12
  export * from "./utils/index.js";
13
13
  export * from "./enums/index.js";
14
+ export * from "./guards/index.js";
14
15
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,kBAAkB,CAAC;AACjC,cAAc,yBAAyB,CAAC;AACxC,cAAc,yBAAyB,CAAC;AACxC,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,kBAAkB,CAAC;AACjC,cAAc,yBAAyB,CAAC;AACxC,cAAc,yBAAyB,CAAC;AACxC,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hugo.ye/common",
3
- "version": "1.0.135",
3
+ "version": "1.0.139",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",