@onekeyfe/hd-web-sdk 0.1.28 → 0.1.29
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/build/iframe.html +1 -1
- package/build/js/iframe.08e8fa90652c00bb2376.js +3 -0
- package/build/js/{iframe.2b9c63ba236698f67ded.js.LICENSE.txt → iframe.08e8fa90652c00bb2376.js.LICENSE.txt} +0 -0
- package/build/js/iframe.08e8fa90652c00bb2376.js.map +1 -0
- package/build/onekey-js-sdk.js +4 -14
- package/build/onekey-js-sdk.js.map +1 -1
- package/build/onekey-js-sdk.min.js +1 -1
- package/build/onekey-js-sdk.min.js.map +1 -1
- package/package.json +5 -5
- package/build/js/iframe.2b9c63ba236698f67ded.js +0 -3
- package/build/js/iframe.2b9c63ba236698f67ded.js.map +0 -1
package/build/onekey-js-sdk.js
CHANGED
|
@@ -14865,7 +14865,7 @@ const UI_REQUEST = {
|
|
|
14865
14865
|
FIRMWARE_NOT_INSTALLED: 'ui-device_firmware_not_installed',
|
|
14866
14866
|
NOT_USE_ONEKEY_DEVICE: 'ui-device_please_use_onekey_device'
|
|
14867
14867
|
};
|
|
14868
|
-
const DEFAULT_DOMAIN = `https://jssdk.onekey.so/${"0.1.
|
|
14868
|
+
const DEFAULT_DOMAIN = `https://jssdk.onekey.so/${"0.1.29"}/`;
|
|
14869
14869
|
const DEFAULT_PRIORITY = 2;
|
|
14870
14870
|
const initialSettings = {
|
|
14871
14871
|
configSrc: './data/config.json',
|
|
@@ -19120,26 +19120,16 @@ class RequestWebUsbDevice extends BaseMethod {
|
|
|
19120
19120
|
return Promise.reject(hdShared.ERRORS.TypedError(hdShared.HardwareErrorCode.RuntimeError, 'Not webusb environment'));
|
|
19121
19121
|
}
|
|
19122
19122
|
|
|
19123
|
-
const transport = TransportManager.getTransport();
|
|
19124
|
-
|
|
19125
19123
|
try {
|
|
19126
|
-
const device = yield transport.requestDevice();
|
|
19127
|
-
|
|
19128
|
-
if (!device) {
|
|
19129
|
-
return yield Promise.reject(hdShared.ERRORS.TypedError(hdShared.HardwareErrorCode.RuntimeError, 'Please select the device to connect'));
|
|
19130
|
-
}
|
|
19131
|
-
|
|
19132
19124
|
const deviceDiff = yield (_a = this.connector) === null || _a === void 0 ? void 0 : _a.enumerate();
|
|
19133
19125
|
const devicesDescriptor = (_b = deviceDiff === null || deviceDiff === void 0 ? void 0 : deviceDiff.descriptors) !== null && _b !== void 0 ? _b : [];
|
|
19134
19126
|
const {
|
|
19135
19127
|
deviceList
|
|
19136
19128
|
} = yield DevicePool.getDevices(devicesDescriptor);
|
|
19137
19129
|
|
|
19138
|
-
|
|
19139
|
-
|
|
19140
|
-
if (_device) {
|
|
19130
|
+
if (deviceList.length > 0) {
|
|
19141
19131
|
return {
|
|
19142
|
-
device:
|
|
19132
|
+
device: deviceList[0].toMessageObject()
|
|
19143
19133
|
};
|
|
19144
19134
|
}
|
|
19145
19135
|
|
|
@@ -46501,7 +46491,7 @@ const src_init = async settings => {
|
|
|
46501
46491
|
|
|
46502
46492
|
try {
|
|
46503
46493
|
await init({ ..._settings,
|
|
46504
|
-
version: "0.1.
|
|
46494
|
+
version: "0.1.29"
|
|
46505
46495
|
});
|
|
46506
46496
|
return true;
|
|
46507
46497
|
} catch (e) {
|