@injectivelabs/wallet-ledger 1.20.5 → 1.20.7

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 { i as TransportError, n as DisconnectedDeviceDuringOperation, o as TransportOpenUserCancelled, t as DisconnectedDevice } from "./lib-es-DrwRIZm6.js";
2
- import { r as log } from "./semver-SXdKWIAb.js";
3
- import { i as Transport, n as ledgerUSBVendorId, r as hid_framing_default, t as identifyUSBProductId } from "./lib-es-B3JjM59t.js";
1
+ import { i as TransportError, n as DisconnectedDeviceDuringOperation, o as TransportOpenUserCancelled, t as DisconnectedDevice } from "./lib-es-B0_OnYuj.js";
2
+ import { r as log } from "./semver-DAjTm0lz.js";
3
+ import { i as Transport, n as ledgerUSBVendorId, r as hid_framing_default, t as identifyUSBProductId } from "./lib-es-DrrkPby3.js";
4
4
  import { Buffer } from "buffer";
5
5
 
6
- //#region ../../../node_modules/.pnpm/@ledgerhq+hw-transport-webhid@6.31.0/node_modules/@ledgerhq/hw-transport-webhid/lib-es/TransportWebHID.js
6
+ //#region ../../../node_modules/.pnpm/@ledgerhq+hw-transport-webhid@6.35.4/node_modules/@ledgerhq/hw-transport-webhid/lib-es/TransportWebHID.js
7
7
  const ledgerDevices = [{ vendorId: ledgerUSBVendorId }];
8
8
  const isSupported = () => Promise.resolve(!!(window.navigator && window.navigator.hid));
9
9
  const getHID = () => {
@@ -45,7 +45,11 @@ var TransportWebHID = class TransportWebHID extends Transport {
45
45
  inputs = [];
46
46
  inputCallback;
47
47
  read = () => {
48
- if (this.inputs.length) return Promise.resolve(this.inputs.shift());
48
+ if (this.inputs.length) {
49
+ const value = this.inputs.shift();
50
+ if (value !== void 0) return Promise.resolve(value);
51
+ throw new Error("Unreachable: non-empty inputs");
52
+ }
49
53
  return new Promise((success) => {
50
54
  this.inputCallback = success;
51
55
  });
@@ -1,9 +1,9 @@
1
- import { a as TransportInterfaceNotAvailable, l as TransportWebUSBGestureRequired, n as DisconnectedDeviceDuringOperation, o as TransportOpenUserCancelled, t as DisconnectedDevice } from "./lib-es-DrwRIZm6.js";
2
- import { r as log } from "./semver-SXdKWIAb.js";
3
- import { i as Transport, n as ledgerUSBVendorId, r as hid_framing_default, t as identifyUSBProductId } from "./lib-es-B3JjM59t.js";
1
+ import { a as TransportInterfaceNotAvailable, l as TransportWebUSBGestureRequired, n as DisconnectedDeviceDuringOperation, o as TransportOpenUserCancelled, t as DisconnectedDevice } from "./lib-es-B0_OnYuj.js";
2
+ import { r as log } from "./semver-DAjTm0lz.js";
3
+ import { i as Transport, n as ledgerUSBVendorId, r as hid_framing_default, t as identifyUSBProductId } from "./lib-es-DrrkPby3.js";
4
4
  import { Buffer } from "buffer";
5
5
 
6
- //#region ../../../node_modules/.pnpm/@ledgerhq+hw-transport-webusb@6.30.0/node_modules/@ledgerhq/hw-transport-webusb/lib-es/webusb.js
6
+ //#region ../../../node_modules/.pnpm/@ledgerhq+hw-transport-webusb@6.34.4/node_modules/@ledgerhq/hw-transport-webusb/lib-es/webusb.js
7
7
  const ledgerDevices = [{ vendorId: ledgerUSBVendorId }];
8
8
  async function requestLedgerDevice() {
9
9
  return await navigator.usb.requestDevice({ filters: ledgerDevices });
@@ -19,7 +19,7 @@ async function getFirstLedgerDevice() {
19
19
  const isSupported = () => Promise.resolve(!!navigator && !!navigator.usb && typeof navigator.usb.getDevices === "function");
20
20
 
21
21
  //#endregion
22
- //#region ../../../node_modules/.pnpm/@ledgerhq+hw-transport-webusb@6.30.0/node_modules/@ledgerhq/hw-transport-webusb/lib-es/TransportWebUSB.js
22
+ //#region ../../../node_modules/.pnpm/@ledgerhq+hw-transport-webusb@6.34.4/node_modules/@ledgerhq/hw-transport-webusb/lib-es/TransportWebUSB.js
23
23
  const configurationValue = 1;
24
24
  const endpointNumber = 3;
25
25
  /**