mirror of
https://github.com/pezkuwichain/pezkuwi-ui.git
synced 2026-04-22 02:08:03 +00:00
Bump dev (w/ eslint adjustments) (#750)
This commit is contained in:
+2
-2
@@ -33,13 +33,13 @@
|
||||
"test:one": "polkadot-dev-run-test --env browser"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@polkadot/dev": "^0.72.36",
|
||||
"@polkadot/dev": "^0.72.39",
|
||||
"@polkadot/x-bundle": "^11.1.3",
|
||||
"@types/node": "^18.15.11",
|
||||
"react": "^18.2.0",
|
||||
"react-dom": "^18.2.0",
|
||||
"react-is": "^18.2.0",
|
||||
"react-native": "^0.71.5"
|
||||
"react-native": "^0.71.6"
|
||||
},
|
||||
"resolutions": {
|
||||
"typescript": "^5.0.4"
|
||||
|
||||
@@ -1,24 +1,12 @@
|
||||
// Copyright 2017-2023 @polkadot/react-qr authors & contributors
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
const ADDRESS_PREFIX = 'substrate';
|
||||
const SEED_PREFIX = 'secret';
|
||||
const FRAME_SIZE = 1024;
|
||||
const SUBSTRATE_ID = new Uint8Array([0x53]);
|
||||
const CRYPTO_SR25519 = new Uint8Array([0x01]);
|
||||
const CMD_SIGN_TX = new Uint8Array([0]);
|
||||
const CMD_SIGN_TX_HASH = new Uint8Array([1]);
|
||||
const CMD_SIGN_IMMORTAL_TX = new Uint8Array([2]);
|
||||
const CMD_SIGN_MSG = new Uint8Array([3]);
|
||||
|
||||
export {
|
||||
ADDRESS_PREFIX,
|
||||
CMD_SIGN_TX,
|
||||
CMD_SIGN_TX_HASH,
|
||||
CMD_SIGN_IMMORTAL_TX,
|
||||
CMD_SIGN_MSG,
|
||||
CRYPTO_SR25519,
|
||||
FRAME_SIZE,
|
||||
SEED_PREFIX,
|
||||
SUBSTRATE_ID
|
||||
};
|
||||
export const ADDRESS_PREFIX = 'substrate';
|
||||
export const SEED_PREFIX = 'secret';
|
||||
export const FRAME_SIZE = 1024;
|
||||
export const SUBSTRATE_ID = new Uint8Array([0x53]);
|
||||
export const CRYPTO_SR25519 = new Uint8Array([0x01]);
|
||||
export const CMD_SIGN_TX = new Uint8Array([0]);
|
||||
export const CMD_SIGN_TX_HASH = new Uint8Array([1]);
|
||||
export const CMD_SIGN_IMMORTAL_TX = new Uint8Array([2]);
|
||||
export const CMD_SIGN_MSG = new Uint8Array([3]);
|
||||
|
||||
@@ -5,6 +5,6 @@ import { Keyring } from './Keyring.js';
|
||||
|
||||
export { packageInfo } from './packageInfo.js';
|
||||
|
||||
const keyring = new Keyring();
|
||||
export const keyring = new Keyring();
|
||||
|
||||
export { Keyring, keyring };
|
||||
export { Keyring };
|
||||
|
||||
@@ -15,26 +15,20 @@ function toHex (address: string): string {
|
||||
);
|
||||
}
|
||||
|
||||
const accountKey = (address: string): string =>
|
||||
`${ACCOUNT_PREFIX}${toHex(address)}`;
|
||||
export function accountKey (address: string): string {
|
||||
return `${ACCOUNT_PREFIX}${toHex(address)}`;
|
||||
}
|
||||
|
||||
const addressKey = (address: string): string =>
|
||||
`${ADDRESS_PREFIX}${toHex(address)}`;
|
||||
export function addressKey (address: string): string {
|
||||
return `${ADDRESS_PREFIX}${toHex(address)}`;
|
||||
}
|
||||
|
||||
const contractKey = (address: string): string =>
|
||||
`${CONTRACT_PREFIX}${toHex(address)}`;
|
||||
export function contractKey (address: string): string {
|
||||
return `${CONTRACT_PREFIX}${toHex(address)}`;
|
||||
}
|
||||
|
||||
const accountRegex = new RegExp(`^${ACCOUNT_PREFIX}0x[0-9a-f]*`, '');
|
||||
export const accountRegex = new RegExp(`^${ACCOUNT_PREFIX}0x[0-9a-f]*`, '');
|
||||
|
||||
const addressRegex = new RegExp(`^${ADDRESS_PREFIX}0x[0-9a-f]*`, '');
|
||||
export const addressRegex = new RegExp(`^${ADDRESS_PREFIX}0x[0-9a-f]*`, '');
|
||||
|
||||
const contractRegex = new RegExp(`^${CONTRACT_PREFIX}0x[0-9a-f]*`, '');
|
||||
|
||||
export {
|
||||
accountKey,
|
||||
accountRegex,
|
||||
addressKey,
|
||||
addressRegex,
|
||||
contractKey,
|
||||
contractRegex
|
||||
};
|
||||
export const contractRegex = new RegExp(`^${CONTRACT_PREFIX}0x[0-9a-f]*`, '');
|
||||
|
||||
@@ -4,4 +4,4 @@
|
||||
import { accountKey } from '../defaults.js';
|
||||
import { genericSubject } from './genericSubject.js';
|
||||
|
||||
export const accounts = genericSubject(accountKey, true);
|
||||
export const accounts = /*#__PURE__*/ genericSubject(accountKey, true);
|
||||
|
||||
@@ -4,4 +4,4 @@
|
||||
import { addressKey } from '../defaults.js';
|
||||
import { genericSubject } from './genericSubject.js';
|
||||
|
||||
export const addresses = genericSubject(addressKey);
|
||||
export const addresses = /*#__PURE__*/ genericSubject(addressKey);
|
||||
|
||||
@@ -4,4 +4,4 @@
|
||||
import { contractKey } from '../defaults.js';
|
||||
import { genericSubject } from './genericSubject.js';
|
||||
|
||||
export const contracts = genericSubject(contractKey);
|
||||
export const contracts = /*#__PURE__*/ genericSubject(contractKey);
|
||||
|
||||
@@ -15,7 +15,7 @@ interface Result {
|
||||
contracts: SubjectInfo;
|
||||
}
|
||||
|
||||
export const obervableAll = combineLatest([
|
||||
export const obervableAll = /*#__PURE__*/ combineLatest([
|
||||
accounts.subject,
|
||||
addresses.subject,
|
||||
contracts.subject
|
||||
|
||||
@@ -6,8 +6,6 @@ import { objectSpread } from '@polkadot/util';
|
||||
|
||||
type ChainDef = string[];
|
||||
|
||||
const chains: Record <string, ChainDef> = selectableNetworks
|
||||
export const chains: Record <string, ChainDef> = /*#__PURE__*/ selectableNetworks
|
||||
.filter((n) => n.genesisHash.length)
|
||||
.reduce((chains, { genesisHash, network }) => objectSpread(chains, { [network]: genesisHash }), {});
|
||||
|
||||
export { chains };
|
||||
|
||||
@@ -3,10 +3,12 @@
|
||||
|
||||
import type { Option } from '../types.js';
|
||||
|
||||
export const ENDPOINTS: Option[] = [{
|
||||
info: 'local',
|
||||
text: 'Local Node (Own, 127.0.0.1:9944)',
|
||||
value: 'ws://127.0.0.1:9944/'
|
||||
}];
|
||||
export const ENDPOINTS: Option[] = [
|
||||
{
|
||||
info: 'local',
|
||||
text: 'Local Node (Own, 127.0.0.1:9944)',
|
||||
value: 'ws://127.0.0.1:9944/'
|
||||
}
|
||||
];
|
||||
|
||||
export const ENDPOINT_DEFAULT = ENDPOINTS[0];
|
||||
|
||||
@@ -3,15 +3,15 @@
|
||||
|
||||
import type { Option } from '../types.js';
|
||||
|
||||
import { CRYPTOS, CRYPTOS_ETH, CRYPTOS_LEDGER } from './crypto.js';
|
||||
import { ENDPOINT_DEFAULT, ENDPOINTS } from './endpoints.js';
|
||||
import { LEDGER_CONN, LEDGER_CONN_DEFAULT } from './ledger.js';
|
||||
import { PREFIX_DEFAULT, PREFIXES } from './ss58.js';
|
||||
import { ICON_DEFAULT, ICON_DEFAULT_HOST, ICONS, NOTIFICATION_DEFAULT, UIMODE_DEFAULT, UIMODES, UITHEME_DEFAULT, UITHEMES } from './ui.js';
|
||||
export { CRYPTOS, CRYPTOS_ETH, CRYPTOS_LEDGER } from './crypto.js';
|
||||
export { ENDPOINT_DEFAULT, ENDPOINTS } from './endpoints.js';
|
||||
export { LEDGER_CONN, LEDGER_CONN_DEFAULT } from './ledger.js';
|
||||
export { PREFIX_DEFAULT, PREFIXES } from './ss58.js';
|
||||
export { ICON_DEFAULT, ICON_DEFAULT_HOST, ICONS, NOTIFICATION_DEFAULT, UIMODE_DEFAULT, UIMODES, UITHEME_DEFAULT, UITHEMES } from './ui.js';
|
||||
|
||||
const CAMERA_DEFAULT = 'off';
|
||||
export const CAMERA_DEFAULT = 'off';
|
||||
|
||||
const CAMERA: Option[] = [
|
||||
export const CAMERA: Option[] = [
|
||||
{
|
||||
info: 'on',
|
||||
text: 'Allow camera access',
|
||||
@@ -24,11 +24,11 @@ const CAMERA: Option[] = [
|
||||
}
|
||||
];
|
||||
|
||||
const LANGUAGE_DEFAULT = 'default';
|
||||
export const LANGUAGE_DEFAULT = 'default';
|
||||
|
||||
const LOCKING_DEFAULT = 'session';
|
||||
export const LOCKING_DEFAULT = 'session';
|
||||
|
||||
const LOCKING: Option[] = [
|
||||
export const LOCKING: Option[] = [
|
||||
{
|
||||
info: 'session',
|
||||
text: 'Once per session',
|
||||
@@ -41,9 +41,9 @@ const LOCKING: Option[] = [
|
||||
}
|
||||
];
|
||||
|
||||
const METADATA_UP_DEFAULT = 'off';
|
||||
export const METADATA_UP_DEFAULT = 'off';
|
||||
|
||||
const METADATA_UP: Option[] = [
|
||||
export const METADATA_UP: Option[] = [
|
||||
{
|
||||
info: 'off',
|
||||
text: 'Do not auto-update extension metadata',
|
||||
@@ -56,9 +56,9 @@ const METADATA_UP: Option[] = [
|
||||
}
|
||||
];
|
||||
|
||||
const STORAGE_DEFAULT = 'off';
|
||||
export const STORAGE_DEFAULT = 'off';
|
||||
|
||||
const STORAGE: Option[] = [
|
||||
export const STORAGE: Option[] = [
|
||||
{
|
||||
info: 'on',
|
||||
text: 'Allow local in-browser account storage',
|
||||
@@ -70,32 +70,3 @@ const STORAGE: Option[] = [
|
||||
value: 'off'
|
||||
}
|
||||
];
|
||||
|
||||
export {
|
||||
CAMERA_DEFAULT,
|
||||
CAMERA,
|
||||
CRYPTOS,
|
||||
CRYPTOS_ETH,
|
||||
CRYPTOS_LEDGER,
|
||||
ENDPOINT_DEFAULT,
|
||||
ENDPOINTS,
|
||||
ICON_DEFAULT,
|
||||
ICON_DEFAULT_HOST,
|
||||
ICONS,
|
||||
LANGUAGE_DEFAULT,
|
||||
LEDGER_CONN_DEFAULT,
|
||||
LEDGER_CONN,
|
||||
LOCKING_DEFAULT,
|
||||
LOCKING,
|
||||
METADATA_UP,
|
||||
METADATA_UP_DEFAULT,
|
||||
NOTIFICATION_DEFAULT,
|
||||
PREFIX_DEFAULT,
|
||||
PREFIXES,
|
||||
STORAGE,
|
||||
STORAGE_DEFAULT,
|
||||
UIMODE_DEFAULT,
|
||||
UIMODES,
|
||||
UITHEME_DEFAULT,
|
||||
UITHEMES
|
||||
};
|
||||
|
||||
@@ -5,13 +5,13 @@ import type { Option } from '../types.js';
|
||||
|
||||
import { isPolkadot } from './type.js';
|
||||
|
||||
const LANGUAGE_DEFAULT = 'default';
|
||||
export const LANGUAGE_DEFAULT = 'default';
|
||||
|
||||
const UIMODE_DEFAULT = !isPolkadot && typeof window !== 'undefined' && window.location.host.includes('ui-light')
|
||||
export const UIMODE_DEFAULT = !isPolkadot && typeof window !== 'undefined' && window.location.host.includes('ui-light')
|
||||
? 'light'
|
||||
: 'full';
|
||||
|
||||
const UIMODES: Option[] = [
|
||||
export const UIMODES: Option[] = [
|
||||
{
|
||||
info: 'full',
|
||||
text: 'Fully featured',
|
||||
@@ -24,11 +24,11 @@ const UIMODES: Option[] = [
|
||||
}
|
||||
];
|
||||
|
||||
const UITHEME_DEFAULT = isPolkadot
|
||||
export const UITHEME_DEFAULT = isPolkadot
|
||||
? 'polkadot'
|
||||
: 'substrate';
|
||||
|
||||
const UITHEMES: Option[] = [
|
||||
export const UITHEMES: Option[] = [
|
||||
{
|
||||
info: 'polkadot',
|
||||
text: 'Polkadot',
|
||||
@@ -41,13 +41,13 @@ const UITHEMES: Option[] = [
|
||||
}
|
||||
];
|
||||
|
||||
const ICON_DEFAULT = 'default';
|
||||
export const ICON_DEFAULT = 'default';
|
||||
|
||||
const ICON_DEFAULT_HOST = isPolkadot
|
||||
export const ICON_DEFAULT_HOST = isPolkadot
|
||||
? 'polkadot'
|
||||
: 'substrate';
|
||||
|
||||
const ICONS: Option[] = [
|
||||
export const ICONS: Option[] = [
|
||||
{
|
||||
info: 'default',
|
||||
text: 'Default for the connected node',
|
||||
@@ -70,16 +70,4 @@ const ICONS: Option[] = [
|
||||
}
|
||||
];
|
||||
|
||||
const NOTIFICATION_DEFAULT = 'popup';
|
||||
|
||||
export {
|
||||
ICON_DEFAULT,
|
||||
ICON_DEFAULT_HOST,
|
||||
ICONS,
|
||||
LANGUAGE_DEFAULT,
|
||||
NOTIFICATION_DEFAULT,
|
||||
UIMODE_DEFAULT,
|
||||
UIMODES,
|
||||
UITHEME_DEFAULT,
|
||||
UITHEMES
|
||||
};
|
||||
export const NOTIFICATION_DEFAULT = 'popup';
|
||||
|
||||
@@ -1415,34 +1415,34 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/dev-test@npm:^0.72.36":
|
||||
version: 0.72.36
|
||||
resolution: "@polkadot/dev-test@npm:0.72.36"
|
||||
"@polkadot/dev-test@npm:^0.72.39":
|
||||
version: 0.72.39
|
||||
resolution: "@polkadot/dev-test@npm:0.72.39"
|
||||
dependencies:
|
||||
jsdom: ^21.1.1
|
||||
tslib: ^2.5.0
|
||||
checksum: 944572fdde67eff0b291e9d902c8bb5cb6753125a0722f30893b518e1c95e94118592a9a29771c9ace0c87adbad676d8f5cbba2416f04ac9101bfe09a2572685
|
||||
checksum: 2731ac8444aa2c5e78516798c18eee69bc850e66c1f61c35076c86938d906b143a2fe0c52a1fc73cf916f8665e0c79710f6e2f3cc4443f5f6eb3904734e35356
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/dev-ts@npm:^0.72.36":
|
||||
version: 0.72.36
|
||||
resolution: "@polkadot/dev-ts@npm:0.72.36"
|
||||
"@polkadot/dev-ts@npm:^0.72.39":
|
||||
version: 0.72.39
|
||||
resolution: "@polkadot/dev-ts@npm:0.72.39"
|
||||
dependencies:
|
||||
json5: ^2.2.3
|
||||
tslib: ^2.5.0
|
||||
typescript: ^5.0.4
|
||||
checksum: add592f7a1dd0e03e2ff09a7b7fd24401e5444a30a68f5e7eed20fbb2b8ccb9bc568806255fe1d097e1bfdfdf7b8b15aa89b6fb4cd5a352aefe02c6e5c1fc6ce
|
||||
checksum: 8782d9a9c567eed0a08ffd9a3a220622d19b68c86e0cedec0c97a652d4b900c59112a87c40c2a3065727fc4a55de5c49bea3538eff02188503ff1903e8741107
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@polkadot/dev@npm:^0.72.36":
|
||||
version: 0.72.36
|
||||
resolution: "@polkadot/dev@npm:0.72.36"
|
||||
"@polkadot/dev@npm:^0.72.39":
|
||||
version: 0.72.39
|
||||
resolution: "@polkadot/dev@npm:0.72.39"
|
||||
dependencies:
|
||||
"@eslint/js": ^8.38.0
|
||||
"@polkadot/dev-test": ^0.72.36
|
||||
"@polkadot/dev-ts": ^0.72.36
|
||||
"@polkadot/dev-test": ^0.72.39
|
||||
"@polkadot/dev-ts": ^0.72.39
|
||||
"@rollup/plugin-alias": ^5.0.0
|
||||
"@rollup/plugin-commonjs": ^24.0.1
|
||||
"@rollup/plugin-dynamic-import-vars": ^2.0.3
|
||||
@@ -1503,7 +1503,7 @@ __metadata:
|
||||
polkadot-exec-rollup: scripts/polkadot-exec-rollup.mjs
|
||||
polkadot-exec-tsc: scripts/polkadot-exec-tsc.mjs
|
||||
polkadot-exec-webpack: scripts/polkadot-exec-webpack.mjs
|
||||
checksum: 35bd8ca7c1cf30549af3383c75bbf573f2fe288c7be5260db19593c627412be73bd9a93cdbfb5902e7aa5681c125424ac383eeb031dffb3457186b0391941ae0
|
||||
checksum: 527602e64635b3ed43e8f7227c7bd5ae108c861bb89b6a1ad4f04ec933c0e9dc8ec8a9d260638eabc71ecf47f25b66672428becbdad4394a8f55e01ab19a040b
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@@ -10469,9 +10469,9 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"react-native@npm:^0.71.5":
|
||||
version: 0.71.5
|
||||
resolution: "react-native@npm:0.71.5"
|
||||
"react-native@npm:^0.71.6":
|
||||
version: 0.71.6
|
||||
resolution: "react-native@npm:0.71.6"
|
||||
dependencies:
|
||||
"@jest/create-cache-key-function": ^29.2.1
|
||||
"@react-native-community/cli": 10.2.2
|
||||
@@ -10511,7 +10511,7 @@ __metadata:
|
||||
react: 18.2.0
|
||||
bin:
|
||||
react-native: cli.js
|
||||
checksum: 56216de9cbbe5fa45fb566384e9e00202d806ea5058c1ce0b7f1649d1152406382a861b56a99fbb8652436d69808eb38cb048ee8ed36abacd12c25d21c503e6a
|
||||
checksum: aadbd9b57dd9b10a41b60337ea1a4103e2fb2320784bf148100e807bd0a77929bdb310ea68d054165cd3c00647a3d020eecb0efb864cc7a93733b2d580e1e675
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@@ -11042,13 +11042,13 @@ __metadata:
|
||||
version: 0.0.0-use.local
|
||||
resolution: "root-workspace-0b6124@workspace:."
|
||||
dependencies:
|
||||
"@polkadot/dev": ^0.72.36
|
||||
"@polkadot/dev": ^0.72.39
|
||||
"@polkadot/x-bundle": ^11.1.3
|
||||
"@types/node": ^18.15.11
|
||||
react: ^18.2.0
|
||||
react-dom: ^18.2.0
|
||||
react-is: ^18.2.0
|
||||
react-native: ^0.71.5
|
||||
react-native: ^0.71.6
|
||||
languageName: unknown
|
||||
linkType: soft
|
||||
|
||||
|
||||
Reference in New Issue
Block a user