@initia/initia.js 0.2.22 → 0.2.24

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.es.js CHANGED
@@ -138,8 +138,8 @@ class qf {
138
138
  throw new Error("Query param should be passed via the params argument");
139
139
  }
140
140
  computeEndpoint(t) {
141
- const e = new URL(this.baseURL);
142
- return e.pathname === "/" ? e.pathname = t : e.pathname += t, e.toString();
141
+ const e = t.replace(/^\/+/, ""), r = new URL(this.baseURL);
142
+ return r.pathname.endsWith("/") || (r.pathname += "/"), r.pathname += e, r.toString();
143
143
  }
144
144
  async getRaw(t, e = {}) {
145
145
  this.validateEndpoint(t);
@@ -4228,7 +4228,7 @@ class rr extends m {
4228
4228
  token: o == null ? void 0 : o.toAmino(),
4229
4229
  sender: n,
4230
4230
  receiver: s,
4231
- timeout_height: (i == null ? void 0 : i.toAmino()) ?? {},
4231
+ timeout_height: i == null ? void 0 : i.toAmino(),
4232
4232
  timeout_timestamp: c,
4233
4233
  memo: d
4234
4234
  }
@@ -12865,7 +12865,7 @@ class no extends m {
12865
12865
  token_ids: n,
12866
12866
  sender: s,
12867
12867
  receiver: i,
12868
- timeout_height: (c == null ? void 0 : c.toAmino()) ?? {},
12868
+ timeout_height: c == null ? void 0 : c.toAmino(),
12869
12869
  timeout_timestamp: d,
12870
12870
  memo: g
12871
12871
  }
@@ -29317,6 +29317,7 @@ export {
29317
29317
  Pt as WeightedVoteOption,
29318
29318
  Gv as bcs,
29319
29319
  Ds as checkDecimal,
29320
+ ul as fromLittleEndian,
29320
29321
  od as hashToHex,
29321
29322
  Jv as isTxError,
29322
29323
  Wf as keccak256,
@@ -29326,5 +29327,6 @@ export {
29326
29327
  jf as ripemd160,
29327
29328
  dd as sha256,
29328
29329
  nw as stateFromJSON,
29329
- sw as stateToJSON
29330
+ sw as stateToJSON,
29331
+ ml as toLittleEndian
29330
29332
  };
@@ -35,3 +35,5 @@ export declare const bcs: {
35
35
  map<K, V, InputK = K, InputV = V>(keyType: import('@mysten/bcs').BcsType<K, InputK>, valueType: import('@mysten/bcs').BcsType<V, InputV>): import('@mysten/bcs').BcsType<Map<K, V>, Map<InputK, InputV>>;
36
36
  lazy<T extends import('@mysten/bcs').BcsType<any>>(cb: () => T): T;
37
37
  };
38
+ export declare function toLittleEndian(bigint: bigint): Uint8Array;
39
+ export declare function fromLittleEndian(bytes: number[]): bigint;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@initia/initia.js",
3
- "version": "0.2.22",
3
+ "version": "0.2.24",
4
4
  "description": "The JavaScript SDK for Initia",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Initia Foundation",