zigap-utils 0.0.41 → 0.0.42

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.
@@ -1,9 +1,9 @@
1
- import { AccountType } from './types';
1
+ import { AccountProvideType } from './types';
2
2
 
3
3
  declare class AddressProvideService {
4
4
  private isAccountType;
5
- getAccount(): Promise<AccountType>;
6
- qrAddressProvide(roomId: string): Promise<AccountType>;
5
+ getAccount(): Promise<AccountProvideType>;
6
+ qrAddressProvide(roomId: string): Promise<AccountProvideType>;
7
7
  }
8
8
  declare const _default: AddressProvideService;
9
9
  export default _default;
@@ -1,2 +1 @@
1
- export { default as qrService } from './qrService';
2
- export { default as addressProvice } from './addressProvide';
1
+ export * from './qrService';
@@ -0,0 +1 @@
1
+ export { default as qrService } from './qrService';
@@ -1,4 +1,4 @@
1
- import { QrType } from './types';
1
+ import { QrType } from '../types';
2
2
 
3
3
  declare class QrService {
4
4
  generateQrCode(type: string, dapp: string, url: string, network: string[]): QrType;
@@ -10,15 +10,18 @@ export interface AccountCryptoType {
10
10
  publicKey: string;
11
11
  address: string;
12
12
  network: string;
13
+ nickName: string;
13
14
  etc: string;
14
15
  }
15
- export interface AccountType {
16
+ export interface AccountProvideType {
16
17
  address: string;
17
18
  network: string;
19
+ nickName: string;
18
20
  }
19
21
  export interface ResponseLoginType {
20
22
  address: string;
21
23
  network: string;
24
+ nickName: string;
22
25
  signature: string;
23
26
  publicKey: string;
24
27
  }
@@ -0,0 +1,10 @@
1
+ import { PayloadType } from 'src/components';
2
+
3
+ declare class Validation {
4
+ private base64url;
5
+ createToken(payload: PayloadType, signature: string): string;
6
+ verifyToken(token: string): any;
7
+ getAddress(publicKey: string): string;
8
+ }
9
+ declare const _default: Validation;
10
+ export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zigap-utils",
3
- "version": "0.0.41",
3
+ "version": "0.0.42",
4
4
  "description": "",
5
5
  "main": "dist/index.es.js",
6
6
  "types": "dist/index.d.ts",
@@ -13,20 +13,6 @@
13
13
  "files": [
14
14
  "dist"
15
15
  ],
16
- "export": {
17
- ".": {
18
- "import": "./dist/index.js",
19
- "require": "./dist/index.js"
20
- },
21
- "./components": {
22
- "import": "./dist/components/index.js",
23
- "require": "./dist/components/index.js"
24
- },
25
- "./util": {
26
- "import": "./dist/util/index.js",
27
- "require": "./dist/util/index.js"
28
- }
29
- },
30
16
  "scripts": {
31
17
  "preinstall": "npx only-allow pnpm",
32
18
  "dev": "vite",
@@ -1,11 +0,0 @@
1
- declare class SocketService {
2
- private socketInstance;
3
- constructor();
4
- joinRoom(roomId: string): void;
5
- leaveRoom(roomId: string): void;
6
- confirmMessage(roomId: string, message: string): import('socket.io-client').Socket<import('@socket.io/component-emitter').DefaultEventsMap, import('@socket.io/component-emitter').DefaultEventsMap>;
7
- onMessageReceived(type: string, callback: (message: any) => void): void;
8
- offMessageReceived(type: string): void;
9
- }
10
- declare const _default: SocketService;
11
- export default _default;
@@ -1,2 +0,0 @@
1
- export declare function hashString(input: string): string;
2
- export declare function verifyHash(input: string, hash: string): boolean;
@@ -1,5 +0,0 @@
1
- import { PayloadType } from 'src/components';
2
-
3
- export declare function createToken(payload: PayloadType, signature: string): string;
4
- export declare function verifyToken(token: string): any;
5
- export declare function getAddress(publicKey: string): string;