@xylabs/eth-address 4.0.2 → 4.0.4

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.
@@ -0,0 +1,21 @@
1
+ export declare const isEthAddress: (obj: {
2
+ type: string;
3
+ }) => boolean;
4
+ export declare class EthAddress {
5
+ static readonly type = "EthAddress";
6
+ type: string;
7
+ private address;
8
+ private constructor();
9
+ static fromString(value?: string, base?: number): EthAddress | undefined;
10
+ static parse(value: unknown, base?: number): EthAddress | undefined;
11
+ static validate(address: string): boolean;
12
+ equals(address?: EthAddress | string | null): boolean;
13
+ toBigNumber(): bigint;
14
+ toHex(): string;
15
+ toJSON(): string;
16
+ toLowerCaseString(): string;
17
+ toShortString(length?: number): string;
18
+ toString(checksum?: boolean, chainId?: string): string;
19
+ validate(): boolean;
20
+ }
21
+ //# sourceMappingURL=EthAddress.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"EthAddress.d.ts","sourceRoot":"","sources":["../../src/EthAddress.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,YAAY,QAAS;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,YAAkC,CAAA;AAEpF,qBAAa,UAAU;IACrB,MAAM,CAAC,QAAQ,CAAC,IAAI,gBAAe;IAEnC,IAAI,SAAkB;IAEtB,OAAO,CAAC,OAAO,CAAQ;IAEvB,OAAO;IAIP,MAAM,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE,MAAM,EAAE,IAAI,SAAK;IAO3C,MAAM,CAAC,KAAK,CAAC,KAAK,EAAE,OAAO,EAAE,IAAI,CAAC,EAAE,MAAM;IAM1C,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE,MAAM;IAI/B,MAAM,CAAC,OAAO,CAAC,EAAE,UAAU,GAAG,MAAM,GAAG,IAAI,GAAG,OAAO;IAQrD,WAAW;IAIX,KAAK;IAIL,MAAM,IAAI,MAAM;IAIhB,iBAAiB;IAIjB,aAAa,CAAC,MAAM,SAAI;IAIxB,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,MAAM;IAQ7C,QAAQ;CAGT"}
@@ -0,0 +1,2 @@
1
+ export declare const ellipsize: (value: string, length?: number) => string;
2
+ //# sourceMappingURL=ellipsize.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ellipsize.d.ts","sourceRoot":"","sources":["../../src/ellipsize.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,UAAW,MAAM,4BAItC,CAAA"}
@@ -1,26 +1,4 @@
1
- declare const ellipsize: (value: string, length?: number) => string;
2
-
3
- declare const isEthAddress: (obj: {
4
- type: string;
5
- }) => boolean;
6
- declare class EthAddress {
7
- static readonly type = "EthAddress";
8
- type: string;
9
- private address;
10
- private constructor();
11
- static fromString(value?: string, base?: number): EthAddress | undefined;
12
- static parse(value: unknown, base?: number): EthAddress | undefined;
13
- static validate(address: string): boolean;
14
- equals(address?: EthAddress | string | null): boolean;
15
- toBigNumber(): bigint;
16
- toHex(): string;
17
- toJSON(): string;
18
- toLowerCaseString(): string;
19
- toShortString(length?: number): string;
20
- toString(checksum?: boolean, chainId?: string): string;
21
- validate(): boolean;
22
- }
23
-
24
- declare const padHex: (hex: string, byteCount?: number) => string;
25
-
26
- export { EthAddress, ellipsize, isEthAddress, padHex };
1
+ export * from './ellipsize.ts';
2
+ export * from './EthAddress.ts';
3
+ export * from './padHex.ts';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAA;AAC9B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,aAAa,CAAA"}
@@ -0,0 +1,3 @@
1
+ declare const padHex: (hex: string, byteCount?: number) => string;
2
+ export { padHex };
3
+ //# sourceMappingURL=padHex.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"padHex.d.ts","sourceRoot":"","sources":["../../src/padHex.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,MAAM,QAAS,MAAM,cAAc,MAAM,WAW9C,CAAA;AAED,OAAO,EAAE,MAAM,EAAE,CAAA"}
package/package.json CHANGED
@@ -1,19 +1,33 @@
1
1
  {
2
- "license": "LGPL-3.0-only",
3
2
  "name": "@xylabs/eth-address",
3
+ "version": "4.0.4",
4
+ "description": "Base functionality used throughout XY Labs TypeScript/JavaScript libraries",
5
+ "keywords": [
6
+ "eth",
7
+ "ethereum",
8
+ "address",
9
+ "xylabs",
10
+ "utility",
11
+ "typescript",
12
+ "esm"
13
+ ],
14
+ "homepage": "https://xylabs.com",
15
+ "bugs": {
16
+ "url": "git+https://github.com/xylabs/sdk-js/issues",
17
+ "email": "support@xylabs.com"
18
+ },
19
+ "repository": {
20
+ "type": "git",
21
+ "url": "git+https://github.com/xylabs/sdk-js.git"
22
+ },
23
+ "license": "LGPL-3.0-only",
4
24
  "author": {
5
- "email": "support@xylabs.com",
6
25
  "name": "XY Labs Development Team",
7
- "url": "https://xylabs.com"
8
- },
9
- "bugs": {
10
26
  "email": "support@xylabs.com",
11
- "url": "git+https://github.com/xylabs/sdk-js/issues"
27
+ "url": "https://xylabs.com"
12
28
  },
13
- "workspaces": [
14
- "packages/**/*"
15
- ],
16
- "description": "Base functionality used throughout XY Labs TypeScript/JavaScript libraries",
29
+ "sideEffects": false,
30
+ "type": "module",
17
31
  "exports": {
18
32
  ".": {
19
33
  "types": "./dist/neutral/index.d.ts",
@@ -21,26 +35,19 @@
21
35
  },
22
36
  "./package.json": "./package.json"
23
37
  },
24
- "types": "./dist/neutral/index.d.ts",
25
38
  "module": "./dist/neutral/index.mjs",
26
- "homepage": "https://xylabs.com",
27
- "keywords": [
28
- "eth",
29
- "ethereum",
30
- "address",
31
- "xylabs",
32
- "utility",
33
- "typescript",
34
- "esm"
39
+ "types": "./dist/neutral/index.d.ts",
40
+ "workspaces": [
41
+ "packages/**/*"
35
42
  ],
36
43
  "dependencies": {
37
- "@xylabs/assert": "^4.0.2",
44
+ "@xylabs/assert": "^4.0.4",
38
45
  "ethers": "^6.13.2"
39
46
  },
40
47
  "devDependencies": {
41
- "@xylabs/ts-scripts-yarn3": "^4.0.0-rc.15",
42
- "@xylabs/tsconfig": "^4.0.0-rc.15",
43
- "@xylabs/tsconfig-jest": "^4.0.0-rc.15",
48
+ "@xylabs/ts-scripts-yarn3": "^4.0.7",
49
+ "@xylabs/tsconfig": "^4.0.7",
50
+ "@xylabs/tsconfig-jest": "^4.0.7",
44
51
  "typescript": "^5.5.4"
45
52
  },
46
53
  "engines": {
@@ -48,12 +55,5 @@
48
55
  },
49
56
  "publishConfig": {
50
57
  "access": "public"
51
- },
52
- "repository": {
53
- "type": "git",
54
- "url": "git+https://github.com/xylabs/sdk-js.git"
55
- },
56
- "sideEffects": false,
57
- "version": "4.0.2",
58
- "type": "module"
58
+ }
59
59
  }
package/xy.config.ts CHANGED
@@ -2,9 +2,7 @@ import type { XyTsupConfig } from '@xylabs/ts-scripts-yarn3'
2
2
  const config: XyTsupConfig = {
3
3
  compile: {
4
4
  browser: {},
5
- neutral: {
6
- src: true,
7
- },
5
+ neutral: { src: true },
8
6
  node: {},
9
7
  },
10
8
  }