Updates for JSON v3 (#393)
* Updates for JSON v3 * Bump ui * isBusy markers * isBusy button * Spinner button * Update tests * Update packages/extension-ui/src/Popup/Export.tsx * Adjust busy indicator * Spinner colors
This commit is contained in:
parent
c8d02b2404
commit
837e1ecedd
12
package.json
12
package.json
@ -8,11 +8,11 @@
|
|||||||
"packages/*"
|
"packages/*"
|
||||||
],
|
],
|
||||||
"resolutions": {
|
"resolutions": {
|
||||||
"@polkadot/api": "^1.25.1",
|
"@polkadot/api": "^1.26.0-beta.1",
|
||||||
"@polkadot/keyring": "^2.18.1",
|
"@polkadot/keyring": "^3.0.0-beta.2",
|
||||||
"@polkadot/types": "^1.25.1",
|
"@polkadot/types": "^1.26.0-beta.1",
|
||||||
"@polkadot/util": "^2.18.1",
|
"@polkadot/util": "^3.0.0-beta.2",
|
||||||
"@polkadot/util-crypto": "^2.18.1",
|
"@polkadot/util-crypto": "^3.0.0-beta.2",
|
||||||
"babel-core": "^7.0.0-bridge.0"
|
"babel-core": "^7.0.0-bridge.0"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
@ -33,7 +33,7 @@
|
|||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@babel/core": "^7.10.5",
|
"@babel/core": "^7.10.5",
|
||||||
"@polkadot/dev": "^0.55.27",
|
"@polkadot/dev": "^0.55.27",
|
||||||
"@polkadot/typegen": "^1.25.1",
|
"@polkadot/typegen": "^1.26.0-beta.1",
|
||||||
"@types/jest": "^26.0.4",
|
"@types/jest": "^26.0.4",
|
||||||
"copy-webpack-plugin": "^6.0.3",
|
"copy-webpack-plugin": "^6.0.3",
|
||||||
"sinon-chrome": "^3.0.1",
|
"sinon-chrome": "^3.0.1",
|
||||||
|
|||||||
@ -6,9 +6,9 @@
|
|||||||
"license": "Apache-2",
|
"license": "Apache-2",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.10.5",
|
"@babel/runtime": "^7.10.5",
|
||||||
"@polkadot/api": "^1.25.1",
|
"@polkadot/api": "^1.26.0-beta.1",
|
||||||
"@polkadot/extension-inject": "0.32.0-beta.8",
|
"@polkadot/extension-inject": "0.32.0-beta.8",
|
||||||
"@polkadot/keyring": "^2.18.1",
|
"@polkadot/keyring": "^3.0.0-beta.2",
|
||||||
"@polkadot/ui-keyring": "^0.56.0-beta.3"
|
"@polkadot/ui-keyring": "^0.57.0-beta.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -218,7 +218,7 @@ export default class Extension {
|
|||||||
private jsonVerifyFile ({ json }: RequestJsonRestore): boolean {
|
private jsonVerifyFile ({ json }: RequestJsonRestore): boolean {
|
||||||
try {
|
try {
|
||||||
const publicKey = keyring.decodeAddress(json.address, true);
|
const publicKey = keyring.decodeAddress(json.address, true);
|
||||||
const isFileValid = publicKey.length === 32 && isHex(json.encoded) && isObject(json.meta) && (
|
const isFileValid = publicKey.length === 32 && !!json.encoded && isObject(json.meta) && (
|
||||||
Array.isArray(json.encoding.content)
|
Array.isArray(json.encoding.content)
|
||||||
? json.encoding.content[0] === 'pkcs8'
|
? json.encoding.content[0] === 'pkcs8'
|
||||||
: json.encoding.content === 'pkcs8'
|
: json.encoding.content === 'pkcs8'
|
||||||
|
|||||||
@ -7,8 +7,8 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "^7.10.5",
|
"@babel/runtime": "^7.10.5",
|
||||||
"@polkadot/extension-inject": "0.32.0-beta.8",
|
"@polkadot/extension-inject": "0.32.0-beta.8",
|
||||||
"@polkadot/util": "^2.18.1",
|
"@polkadot/util": "^3.0.0-beta.2",
|
||||||
"@polkadot/util-crypto": "^2.18.1"
|
"@polkadot/util-crypto": "^3.0.0-beta.2"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@polkadot/api": "*"
|
"@polkadot/api": "*"
|
||||||
|
|||||||
@ -8,11 +8,11 @@
|
|||||||
"@babel/runtime": "^7.10.5",
|
"@babel/runtime": "^7.10.5",
|
||||||
"@polkadot/extension-base": "0.32.0-beta.8",
|
"@polkadot/extension-base": "0.32.0-beta.8",
|
||||||
"@polkadot/extension-inject": "0.32.0-beta.8",
|
"@polkadot/extension-inject": "0.32.0-beta.8",
|
||||||
"@polkadot/keyring": "^2.18.1",
|
"@polkadot/keyring": "^3.0.0-beta.2",
|
||||||
"@polkadot/react-identicon": "^0.56.0-beta.3",
|
"@polkadot/react-identicon": "^0.57.0-beta.1",
|
||||||
"@polkadot/react-qr": "^0.56.0-beta.3",
|
"@polkadot/react-qr": "^0.57.0-beta.1",
|
||||||
"@polkadot/util": "^2.18.1",
|
"@polkadot/util": "^3.0.0-beta.2",
|
||||||
"@polkadot/util-crypto": "^2.18.1",
|
"@polkadot/util-crypto": "^3.0.0-beta.2",
|
||||||
"react": "^16.13.1",
|
"react": "^16.13.1",
|
||||||
"react-dom": "^16.13.1",
|
"react-dom": "^16.13.1",
|
||||||
"react-dropzone": "^11.0.2",
|
"react-dropzone": "^11.0.2",
|
||||||
|
|||||||
@ -9,15 +9,19 @@ import { Name, Password } from '../../partials';
|
|||||||
|
|
||||||
interface Props {
|
interface Props {
|
||||||
address: string;
|
address: string;
|
||||||
|
isBusy: boolean;
|
||||||
onBackClick: () => void;
|
onBackClick: () => void;
|
||||||
onCreate: (name: string, password: string) => void | Promise<void | boolean>;
|
onCreate: (name: string, password: string) => void | Promise<void | boolean>;
|
||||||
}
|
}
|
||||||
|
|
||||||
function AccountName ({ address, onBackClick, onCreate }: Props): React.ReactElement<Props> {
|
function AccountName ({ address, isBusy, onBackClick, onCreate }: Props): React.ReactElement<Props> {
|
||||||
const [name, setName] = useState<string | null>(null);
|
const [name, setName] = useState<string | null>(null);
|
||||||
const [password, setPassword] = useState<string | null>(null);
|
const [password, setPassword] = useState<string | null>(null);
|
||||||
|
|
||||||
const _onCreate = useCallback(() => name && password && onCreate(name, password), [name, password, onCreate]);
|
const _onCreate = useCallback(
|
||||||
|
() => name && password && onCreate(name, password),
|
||||||
|
[name, password, onCreate]
|
||||||
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
@ -37,6 +41,7 @@ function AccountName ({ address, onBackClick, onCreate }: Props): React.ReactEle
|
|||||||
<BackButton onClick={onBackClick} />
|
<BackButton onClick={onBackClick} />
|
||||||
<NextStepButton
|
<NextStepButton
|
||||||
data-button-action='add new root'
|
data-button-action='add new root'
|
||||||
|
isBusy={isBusy}
|
||||||
isDisabled={!password || !name}
|
isDisabled={!password || !name}
|
||||||
onClick={_onCreate}
|
onClick={_onCreate}
|
||||||
>
|
>
|
||||||
|
|||||||
@ -11,6 +11,7 @@ import Mnemonic from './Mnemonic';
|
|||||||
|
|
||||||
export default function CreateAccount (): React.ReactElement {
|
export default function CreateAccount (): React.ReactElement {
|
||||||
const onAction = useContext(ActionContext);
|
const onAction = useContext(ActionContext);
|
||||||
|
const [isBusy, setIsBusy] = useState(false);
|
||||||
const [step, setStep] = useState(1);
|
const [step, setStep] = useState(1);
|
||||||
const [account, setAccount] = useState<null | { address: string; seed: string }>(null);
|
const [account, setAccount] = useState<null | { address: string; seed: string }>(null);
|
||||||
|
|
||||||
@ -24,9 +25,14 @@ export default function CreateAccount (): React.ReactElement {
|
|||||||
const _onCreate = (name: string, password: string): void => {
|
const _onCreate = (name: string, password: string): void => {
|
||||||
// this should always be the case
|
// this should always be the case
|
||||||
if (name && password && account) {
|
if (name && password && account) {
|
||||||
|
setIsBusy(true);
|
||||||
|
|
||||||
createAccountSuri(name, password, account.seed)
|
createAccountSuri(name, password, account.seed)
|
||||||
.then((): void => onAction('/'))
|
.then((): void => onAction('/'))
|
||||||
.catch((error: Error) => console.error(error));
|
.catch((error: Error): void => {
|
||||||
|
setIsBusy(false);
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -49,6 +55,7 @@ export default function CreateAccount (): React.ReactElement {
|
|||||||
: (
|
: (
|
||||||
<AccountName
|
<AccountName
|
||||||
address={account.address}
|
address={account.address}
|
||||||
|
isBusy={isBusy}
|
||||||
onBackClick={_onPreviousStep}
|
onBackClick={_onPreviousStep}
|
||||||
onCreate={_onCreate}
|
onCreate={_onCreate}
|
||||||
/>
|
/>
|
||||||
|
|||||||
@ -117,7 +117,7 @@ describe('Derive', () => {
|
|||||||
|
|
||||||
const button = wrapper.find('[data-button-action="create derived account"] button');
|
const button = wrapper.find('[data-button-action="create derived account"] button');
|
||||||
|
|
||||||
expect(button.prop('disabled')).toBe(false);
|
expect(button.prop('disabled')).not.toBe(true);
|
||||||
});
|
});
|
||||||
|
|
||||||
it('derivation path input is not present until password is correct', async () => {
|
it('derivation path input is not present until password is correct', async () => {
|
||||||
@ -138,7 +138,7 @@ describe('Derive', () => {
|
|||||||
|
|
||||||
const button = wrapper.find('[data-button-action="create derived account"] button');
|
const button = wrapper.find('[data-button-action="create derived account"] button');
|
||||||
|
|
||||||
expect(button.prop('disabled')).toBe(false);
|
expect(button.prop('disabled')).not.toBe(true);
|
||||||
});
|
});
|
||||||
|
|
||||||
it('takes selected address from URL as parent account', async () => {
|
it('takes selected address from URL as parent account', async () => {
|
||||||
|
|||||||
@ -30,6 +30,7 @@ interface ConfirmState {
|
|||||||
function Derive ({ isLocked }: Props): React.ReactElement<Props> {
|
function Derive ({ isLocked }: Props): React.ReactElement<Props> {
|
||||||
const onAction = useContext(ActionContext);
|
const onAction = useContext(ActionContext);
|
||||||
const { address: parentAddress } = useParams<AddressState>();
|
const { address: parentAddress } = useParams<AddressState>();
|
||||||
|
const [isBusy, setIsBusy] = useState(false);
|
||||||
const [account, setAccount] = useState<null | PathState>(null);
|
const [account, setAccount] = useState<null | PathState>(null);
|
||||||
const [name, setName] = useState<string | null>(null);
|
const [name, setName] = useState<string | null>(null);
|
||||||
const [password, setPassword] = useState<string | null>(null);
|
const [password, setPassword] = useState<string | null>(null);
|
||||||
@ -40,9 +41,14 @@ function Derive ({ isLocked }: Props): React.ReactElement<Props> {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
setIsBusy(true);
|
||||||
|
|
||||||
deriveAccount(parentAddress, account.suri, parentPassword, name, password)
|
deriveAccount(parentAddress, account.suri, parentPassword, name, password)
|
||||||
.then(() => onAction('/'))
|
.then(() => onAction('/'))
|
||||||
.catch(console.error);
|
.catch((error): void => {
|
||||||
|
setIsBusy(false);
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
}, [account, name, password, onAction, parentAddress, parentPassword]);
|
}, [account, name, password, onAction, parentAddress, parentPassword]);
|
||||||
|
|
||||||
const _onDerivationConfirmed = useCallback(({ account, parentPassword }: ConfirmState) => {
|
const _onDerivationConfirmed = useCallback(({ account, parentPassword }: ConfirmState) => {
|
||||||
@ -86,6 +92,7 @@ function Derive ({ isLocked }: Props): React.ReactElement<Props> {
|
|||||||
<ButtonArea>
|
<ButtonArea>
|
||||||
<BackButton onClick={_onBackClick}/>
|
<BackButton onClick={_onBackClick}/>
|
||||||
<NextStepButton
|
<NextStepButton
|
||||||
|
isBusy={isBusy}
|
||||||
isDisabled={!password}
|
isDisabled={!password}
|
||||||
onClick={_onCreate}
|
onClick={_onCreate}
|
||||||
>
|
>
|
||||||
|
|||||||
@ -5,7 +5,7 @@
|
|||||||
import React, { useCallback, useContext, useState } from 'react';
|
import React, { useCallback, useContext, useState } from 'react';
|
||||||
import { RouteComponentProps, withRouter } from 'react-router';
|
import { RouteComponentProps, withRouter } from 'react-router';
|
||||||
|
|
||||||
import { ActionContext, Address, Button, InputWithLabel, Warning, ActionText, ActionBar } from '../components';
|
import { ActionBar, ActionContext, ActionText, Address, Button, InputWithLabel, Warning } from '../components';
|
||||||
import { exportAccount } from '../messaging';
|
import { exportAccount } from '../messaging';
|
||||||
import { Header } from '../partials';
|
import { Header } from '../partials';
|
||||||
import styled from 'styled-components';
|
import styled from 'styled-components';
|
||||||
@ -16,6 +16,7 @@ type Props = RouteComponentProps<{ address: string }>;
|
|||||||
|
|
||||||
function Export ({ match: { params: { address } } }: Props): React.ReactElement<Props> {
|
function Export ({ match: { params: { address } } }: Props): React.ReactElement<Props> {
|
||||||
const onAction = useContext(ActionContext);
|
const onAction = useContext(ActionContext);
|
||||||
|
const [isBusy, setIsBusy] = useState(false);
|
||||||
const [pass, setPass] = useState('');
|
const [pass, setPass] = useState('');
|
||||||
const [wrongPasswordHighlight, setWrongPasswordHighlight] = useState(false);
|
const [wrongPasswordHighlight, setWrongPasswordHighlight] = useState(false);
|
||||||
|
|
||||||
@ -25,7 +26,9 @@ function Export ({ match: { params: { address } } }: Props): React.ReactElement<
|
|||||||
);
|
);
|
||||||
|
|
||||||
const _onExportButtonClick = useCallback(
|
const _onExportButtonClick = useCallback(
|
||||||
(): Promise<void> =>
|
(): void => {
|
||||||
|
setIsBusy(true);
|
||||||
|
|
||||||
exportAccount(address, pass)
|
exportAccount(address, pass)
|
||||||
.then(({ exportedJson }) => {
|
.then(({ exportedJson }) => {
|
||||||
const element = document.createElement('a');
|
const element = document.createElement('a');
|
||||||
@ -40,9 +43,11 @@ function Export ({ match: { params: { address } } }: Props): React.ReactElement<
|
|||||||
.catch((error: Error) => {
|
.catch((error: Error) => {
|
||||||
console.error(error);
|
console.error(error);
|
||||||
|
|
||||||
|
setIsBusy(false);
|
||||||
setWrongPasswordHighlight(true);
|
setWrongPasswordHighlight(true);
|
||||||
setTimeout(() => setWrongPasswordHighlight(false), 100);
|
setTimeout(() => setWrongPasswordHighlight(false), 100);
|
||||||
}),
|
});
|
||||||
|
},
|
||||||
[address, onAction, pass]
|
[address, onAction, pass]
|
||||||
);
|
);
|
||||||
|
|
||||||
@ -58,6 +63,7 @@ function Export ({ match: { params: { address } } }: Props): React.ReactElement<
|
|||||||
<ActionArea>
|
<ActionArea>
|
||||||
<InputWithLabel
|
<InputWithLabel
|
||||||
data-export-password
|
data-export-password
|
||||||
|
disabled={isBusy}
|
||||||
isError={pass.length < MIN_LENGTH || wrongPasswordHighlight}
|
isError={pass.length < MIN_LENGTH || wrongPasswordHighlight}
|
||||||
label='password for this account'
|
label='password for this account'
|
||||||
onChange={setPass}
|
onChange={setPass}
|
||||||
@ -66,6 +72,7 @@ function Export ({ match: { params: { address } } }: Props): React.ReactElement<
|
|||||||
<Button
|
<Button
|
||||||
className='export-button'
|
className='export-button'
|
||||||
data-export-button
|
data-export-button
|
||||||
|
isBusy={isBusy}
|
||||||
isDanger
|
isDanger
|
||||||
isDisabled={pass.length === 0}
|
isDisabled={pass.length === 0}
|
||||||
onClick={_onExportButtonClick}
|
onClick={_onExportButtonClick}
|
||||||
|
|||||||
@ -28,6 +28,7 @@ const isSeedValid = allOf(
|
|||||||
export default function Import (): React.ReactElement {
|
export default function Import (): React.ReactElement {
|
||||||
const { accounts } = useContext(AccountContext);
|
const { accounts } = useContext(AccountContext);
|
||||||
const onAction = useContext(ActionContext);
|
const onAction = useContext(ActionContext);
|
||||||
|
const [isBusy, setIsBusy] = useState(false);
|
||||||
const [account, setAccount] = useState<null | { address: string; suri: string }>(null);
|
const [account, setAccount] = useState<null | { address: string; suri: string }>(null);
|
||||||
const [name, setName] = useState<string | null>(null);
|
const [name, setName] = useState<string | null>(null);
|
||||||
const [password, setPassword] = useState<string | null>(null);
|
const [password, setPassword] = useState<string | null>(null);
|
||||||
@ -51,9 +52,14 @@ export default function Import (): React.ReactElement {
|
|||||||
const _onCreate = useCallback((): void => {
|
const _onCreate = useCallback((): void => {
|
||||||
// this should always be the case
|
// this should always be the case
|
||||||
if (name && password && account) {
|
if (name && password && account) {
|
||||||
|
setIsBusy(true);
|
||||||
|
|
||||||
createAccountSuri(name, password, account.suri)
|
createAccountSuri(name, password, account.suri)
|
||||||
.then(() => onAction('/'))
|
.then(() => onAction('/'))
|
||||||
.catch(console.error);
|
.catch((error): void => {
|
||||||
|
setIsBusy(false);
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}, [account, name, onAction, password]);
|
}, [account, name, onAction, password]);
|
||||||
|
|
||||||
@ -83,6 +89,7 @@ export default function Import (): React.ReactElement {
|
|||||||
<VerticalSpace />
|
<VerticalSpace />
|
||||||
<ButtonArea>
|
<ButtonArea>
|
||||||
<NextStepButton
|
<NextStepButton
|
||||||
|
isBusy={isBusy}
|
||||||
onClick={_onCreate}
|
onClick={_onCreate}
|
||||||
>
|
>
|
||||||
Add the account with the supplied seed
|
Add the account with the supplied seed
|
||||||
|
|||||||
@ -43,6 +43,7 @@ async function parseFile (file: Uint8Array): Promise<FileState> {
|
|||||||
export default function Upload (): React.ReactElement {
|
export default function Upload (): React.ReactElement {
|
||||||
const { accounts } = useContext(AccountContext);
|
const { accounts } = useContext(AccountContext);
|
||||||
const onAction = useContext(ActionContext);
|
const onAction = useContext(ActionContext);
|
||||||
|
const [isBusy, setIsBusy] = useState(false);
|
||||||
const [{ address, isFileValid, json }, setJson] = useState<FileState>({ address: null, isFileValid: false, json: null });
|
const [{ address, isFileValid, json }, setJson] = useState<FileState>({ address: null, isFileValid: false, json: null });
|
||||||
const [{ isPassValid, password }, setPass] = useState<PassState>({ isPassValid: false, password: '' });
|
const [{ isPassValid, password }, setPass] = useState<PassState>({ isPassValid: false, password: '' });
|
||||||
|
|
||||||
@ -72,9 +73,12 @@ export default function Upload (): React.ReactElement {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
setIsBusy(true);
|
||||||
|
|
||||||
jsonRestore(json, password)
|
jsonRestore(json, password)
|
||||||
.then(({ error }): void => {
|
.then(({ error }): void => {
|
||||||
if (error) {
|
if (error) {
|
||||||
|
setIsBusy(false);
|
||||||
setPass(({ password }) => ({ decodeError: error, isPassValid: false, password }));
|
setPass(({ password }) => ({ decodeError: error, isPassValid: false, password }));
|
||||||
} else {
|
} else {
|
||||||
onAction('/');
|
onAction('/');
|
||||||
@ -110,10 +114,11 @@ export default function Upload (): React.ReactElement {
|
|||||||
type='password'
|
type='password'
|
||||||
/>
|
/>
|
||||||
<Button
|
<Button
|
||||||
|
isBusy={isBusy}
|
||||||
isDisabled={!isFileValid || !isPassValid}
|
isDisabled={!isFileValid || !isPassValid}
|
||||||
onClick={_onRestore}
|
onClick={_onRestore}
|
||||||
>
|
>
|
||||||
Restore
|
Restore
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
</>
|
</>
|
||||||
|
|||||||
@ -13,7 +13,8 @@ interface Props {
|
|||||||
buttonText?: string;
|
buttonText?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function Unlock ({ buttonText = 'Sign the transaction', className, error, onSign }: Props): React.ReactElement<Props> {
|
function Unlock ({ buttonText = 'Sign the transaction', className, error, onSign }: Props): React.ReactElement<Props> {
|
||||||
|
const [isBusy, setIsBusy] = useState(false);
|
||||||
const [ownError, setError] = useState<string | null>();
|
const [ownError, setError] = useState<string | null>();
|
||||||
const [password, setPassword] = useState('');
|
const [password, setPassword] = useState('');
|
||||||
|
|
||||||
@ -29,21 +30,37 @@ export default function Unlock ({ buttonText = 'Sign the transaction', className
|
|||||||
[]
|
[]
|
||||||
);
|
);
|
||||||
const _onClick = useCallback(
|
const _onClick = useCallback(
|
||||||
(): Promise<void> =>
|
(): void => {
|
||||||
onSign(password).catch((error: Error) => setError(error.message)),
|
setIsBusy(true);
|
||||||
|
onSign(password)
|
||||||
|
.then(() => setIsBusy(false))
|
||||||
|
.catch((error: Error): void => {
|
||||||
|
setIsBusy(false);
|
||||||
|
setError(error.message);
|
||||||
|
});
|
||||||
|
},
|
||||||
[onSign, password]
|
[onSign, password]
|
||||||
);
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={className}>
|
<div className={className}>
|
||||||
<InputWithLabel
|
<InputWithLabel
|
||||||
|
disabled={isBusy}
|
||||||
isError={!password || !!ownError}
|
isError={!password || !!ownError}
|
||||||
isFocused
|
isFocused
|
||||||
label='Password for this account'
|
label='Password for this account'
|
||||||
onChange={_onChangePassword}
|
onChange={_onChangePassword}
|
||||||
|
onEnter={_onClick}
|
||||||
type='password'
|
type='password'
|
||||||
/>
|
/>
|
||||||
<Button onClick={_onClick}>{buttonText}</Button>
|
<Button
|
||||||
|
isBusy={isBusy}
|
||||||
|
onClick={_onClick}
|
||||||
|
>
|
||||||
|
{buttonText}
|
||||||
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export default React.memo(Unlock);
|
||||||
|
|||||||
BIN
packages/extension-ui/src/assets/spinner-white.png
Normal file
BIN
packages/extension-ui/src/assets/spinner-white.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 143 KiB |
BIN
packages/extension-ui/src/assets/spinner.png
Normal file
BIN
packages/extension-ui/src/assets/spinner.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 144 KiB |
@ -310,7 +310,7 @@ export default styled(Address)(({ theme }: ThemeProps) => `
|
|||||||
}
|
}
|
||||||
|
|
||||||
.identityIcon {
|
.identityIcon {
|
||||||
margin-left: 25px;
|
margin-left: 15px;
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
|
|
||||||
& svg {
|
& svg {
|
||||||
|
|||||||
@ -7,18 +7,26 @@ import { ThemeProps } from '../types';
|
|||||||
import React from 'react';
|
import React from 'react';
|
||||||
import styled from 'styled-components';
|
import styled from 'styled-components';
|
||||||
|
|
||||||
|
import Spinner from './Spinner';
|
||||||
|
|
||||||
interface Props extends ThemeProps {
|
interface Props extends ThemeProps {
|
||||||
className?: string;
|
className?: string;
|
||||||
children?: React.ReactNode;
|
children?: React.ReactNode;
|
||||||
|
isBusy?: boolean;
|
||||||
isDanger?: boolean;
|
isDanger?: boolean;
|
||||||
isDisabled?: boolean;
|
isDisabled?: boolean;
|
||||||
onClick?: () => void | Promise<void | boolean>;
|
onClick?: () => void | Promise<void | boolean>;
|
||||||
to?: string;
|
to?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
function Button ({ children, className, isDisabled, onClick, to }: Props): React.ReactElement<Props> {
|
const STYLE: { position: 'relative'; width: string } = {
|
||||||
|
position: 'relative',
|
||||||
|
width: '100%'
|
||||||
|
};
|
||||||
|
|
||||||
|
function Button ({ children, className, isBusy, isDisabled, onClick, to }: Props): React.ReactElement<Props> {
|
||||||
const _onClick = (): void => {
|
const _onClick = (): void => {
|
||||||
if (isDisabled) {
|
if (isBusy || isDisabled) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -30,13 +38,16 @@ function Button ({ children, className, isDisabled, onClick, to }: Props): React
|
|||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<button
|
<div style={STYLE}>
|
||||||
className={className}
|
<button
|
||||||
disabled={isDisabled}
|
className={className}
|
||||||
onClick={_onClick}
|
disabled={isDisabled || isBusy}
|
||||||
>
|
onClick={_onClick}
|
||||||
{children}
|
>
|
||||||
</button>
|
{children}
|
||||||
|
</button>
|
||||||
|
{isBusy && <Spinner />}
|
||||||
|
</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -18,12 +18,20 @@ interface Props {
|
|||||||
label: string;
|
label: string;
|
||||||
onBlur?: () => void;
|
onBlur?: () => void;
|
||||||
onChange?: (value: string) => void;
|
onChange?: (value: string) => void;
|
||||||
|
onEnter?: () => void;
|
||||||
type?: 'text' | 'password';
|
type?: 'text' | 'password';
|
||||||
value?: string;
|
value?: string;
|
||||||
placeholder?: string;
|
placeholder?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
function InputWithLabel ({ className, defaultValue, disabled, isError, isFocused, isReadOnly, label, onBlur, onChange, placeholder, type = 'text', value }: Props): React.ReactElement<Props> {
|
function InputWithLabel ({ className, defaultValue, disabled, isError, isFocused, isReadOnly, label, onBlur, onChange, onEnter, placeholder, type = 'text', value }: Props): React.ReactElement<Props> {
|
||||||
|
const _checkEnter = useCallback(
|
||||||
|
(event: React.KeyboardEvent<HTMLInputElement>): void => {
|
||||||
|
onEnter && event.key === 'Enter' && onEnter();
|
||||||
|
},
|
||||||
|
[onEnter]
|
||||||
|
);
|
||||||
|
|
||||||
const _onChange = useCallback(
|
const _onChange = useCallback(
|
||||||
({ target: { value } }: React.ChangeEvent<HTMLInputElement>): void => {
|
({ target: { value } }: React.ChangeEvent<HTMLInputElement>): void => {
|
||||||
onChange && onChange(value);
|
onChange && onChange(value);
|
||||||
@ -44,6 +52,7 @@ function InputWithLabel ({ className, defaultValue, disabled, isError, isFocused
|
|||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
onBlur={onBlur}
|
onBlur={onBlur}
|
||||||
onChange={_onChange}
|
onChange={_onChange}
|
||||||
|
onKeyPress={_checkEnter}
|
||||||
placeholder={placeholder}
|
placeholder={placeholder}
|
||||||
readOnly={isReadOnly}
|
readOnly={isReadOnly}
|
||||||
spellCheck={false}
|
spellCheck={false}
|
||||||
|
|||||||
33
packages/extension-ui/src/components/Spinner.tsx
Normal file
33
packages/extension-ui/src/components/Spinner.tsx
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
// Copyright 2019-2020 @polkadot/extension-ui authors & contributors
|
||||||
|
// This software may be modified and distributed under the terms
|
||||||
|
// of the Apache-2.0 license. See the LICENSE file for details.
|
||||||
|
|
||||||
|
import { ThemeProps } from '../types';
|
||||||
|
|
||||||
|
import React from 'react';
|
||||||
|
import styled from 'styled-components';
|
||||||
|
|
||||||
|
import spinnerSrc from '../assets/spinner.png';
|
||||||
|
|
||||||
|
interface Props extends ThemeProps {
|
||||||
|
className?: string;
|
||||||
|
size?: 'normal';
|
||||||
|
}
|
||||||
|
|
||||||
|
function Spinner ({ className = '', size = 'normal' }: Props): React.ReactElement<Props> {
|
||||||
|
return (
|
||||||
|
<img
|
||||||
|
className={`${className} ${size}Size`}
|
||||||
|
src={spinnerSrc}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
export default React.memo(styled(Spinner)`
|
||||||
|
bottom: 0rem;
|
||||||
|
height: 3rem;
|
||||||
|
position: absolute;
|
||||||
|
right: 0.75rem;
|
||||||
|
width: 3rem;
|
||||||
|
z-index:
|
||||||
|
`);
|
||||||
@ -26,6 +26,7 @@ export { default as MenuDivider } from './MenuDivider';
|
|||||||
export { default as MenuItem } from './MenuItem';
|
export { default as MenuItem } from './MenuItem';
|
||||||
export { default as MnemonicSeed } from './MnemonicSeed';
|
export { default as MnemonicSeed } from './MnemonicSeed';
|
||||||
export { default as NextStepButton } from './NextStepButton';
|
export { default as NextStepButton } from './NextStepButton';
|
||||||
|
export { default as Spinner } from './Spinner';
|
||||||
export { default as Svg } from './Svg';
|
export { default as Svg } from './Svg';
|
||||||
export { default as Switch } from './Switch';
|
export { default as Switch } from './Switch';
|
||||||
export { default as Table } from './Table';
|
export { default as Table } from './Table';
|
||||||
|
|||||||
222
yarn.lock
222
yarn.lock
@ -1328,7 +1328,7 @@ __metadata:
|
|||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@babel/runtime@npm:^7.1.2, @babel/runtime@npm:^7.10.3, @babel/runtime@npm:^7.10.4, @babel/runtime@npm:^7.10.5, @babel/runtime@npm:^7.5.5, @babel/runtime@npm:^7.8.4, @babel/runtime@npm:^7.9.6":
|
"@babel/runtime@npm:^7.1.2, @babel/runtime@npm:^7.10.3, @babel/runtime@npm:^7.10.5, @babel/runtime@npm:^7.5.5, @babel/runtime@npm:^7.8.4, @babel/runtime@npm:^7.9.6":
|
||||||
version: 7.10.5
|
version: 7.10.5
|
||||||
resolution: "@babel/runtime@npm:7.10.5"
|
resolution: "@babel/runtime@npm:7.10.5"
|
||||||
dependencies:
|
dependencies:
|
||||||
@ -2795,42 +2795,42 @@ __metadata:
|
|||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/api-derive@npm:1.25.1":
|
"@polkadot/api-derive@npm:1.26.0-beta.1":
|
||||||
version: 1.25.1
|
version: 1.26.0-beta.1
|
||||||
resolution: "@polkadot/api-derive@npm:1.25.1"
|
resolution: "@polkadot/api-derive@npm:1.26.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/api": 1.25.1
|
"@polkadot/api": 1.26.0-beta.1
|
||||||
"@polkadot/rpc-core": 1.25.1
|
"@polkadot/rpc-core": 1.26.0-beta.1
|
||||||
"@polkadot/rpc-provider": 1.25.1
|
"@polkadot/rpc-provider": 1.26.0-beta.1
|
||||||
"@polkadot/types": 1.25.1
|
"@polkadot/types": 1.26.0-beta.1
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^2.18.1
|
||||||
"@polkadot/util-crypto": ^2.18.1
|
"@polkadot/util-crypto": ^2.18.1
|
||||||
bn.js: ^5.1.2
|
bn.js: ^5.1.2
|
||||||
memoizee: ^0.4.14
|
memoizee: ^0.4.14
|
||||||
rxjs: ^6.6.0
|
rxjs: ^6.6.0
|
||||||
checksum: 3/f033e49ee83542892dd07b2b0d24d817bb9f5f9265f67624521bc8cfe485854f84d1533f0bc2d9603c51da5cd125f92fd602e010f9c06e76c222e2b0f6097968
|
checksum: 3/0948b9ce0476b677f27cb81271d7d28e02a0d694ec9c05b49640184108c74c3ff77404f4d745f2f151723c31260bbf2de3fec8e05a982609f09f9161583405fc
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/api@npm:^1.25.1":
|
"@polkadot/api@npm:^1.26.0-beta.1":
|
||||||
version: 1.25.1
|
version: 1.26.0-beta.1
|
||||||
resolution: "@polkadot/api@npm:1.25.1"
|
resolution: "@polkadot/api@npm:1.26.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/api-derive": 1.25.1
|
"@polkadot/api-derive": 1.26.0-beta.1
|
||||||
"@polkadot/keyring": ^2.18.1
|
"@polkadot/keyring": ^2.18.1
|
||||||
"@polkadot/metadata": 1.25.1
|
"@polkadot/metadata": 1.26.0-beta.1
|
||||||
"@polkadot/rpc-core": 1.25.1
|
"@polkadot/rpc-core": 1.26.0-beta.1
|
||||||
"@polkadot/rpc-provider": 1.25.1
|
"@polkadot/rpc-provider": 1.26.0-beta.1
|
||||||
"@polkadot/types": 1.25.1
|
"@polkadot/types": 1.26.0-beta.1
|
||||||
"@polkadot/types-known": 1.25.1
|
"@polkadot/types-known": 1.26.0-beta.1
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^2.18.1
|
||||||
"@polkadot/util-crypto": ^2.18.1
|
"@polkadot/util-crypto": ^2.18.1
|
||||||
bn.js: ^5.1.2
|
bn.js: ^5.1.2
|
||||||
eventemitter3: ^4.0.4
|
eventemitter3: ^4.0.4
|
||||||
rxjs: ^6.6.0
|
rxjs: ^6.6.0
|
||||||
checksum: 3/1bf493f3ad6b05eba239dcc38febd723bc238e6286376704bc3cb487e5e2dc52a2cd0ec58a9b27a85756355c1786ab0ee2c03f03d5a42cfebdebf8b8eb15edaa
|
checksum: 3/8c9aeaf0430d370c9f303f775692ba2bf478f68c03971e01f86a28d0cdf23164e5ca92d447146c8677cf4c201cf81b09caa0ea0c5e25790f32e2b36a79e38fb1
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
@ -2928,10 +2928,10 @@ __metadata:
|
|||||||
resolution: "@polkadot/extension-base@workspace:packages/extension-base"
|
resolution: "@polkadot/extension-base@workspace:packages/extension-base"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/api": ^1.25.1
|
"@polkadot/api": ^1.26.0-beta.1
|
||||||
"@polkadot/extension-inject": 0.32.0-beta.8
|
"@polkadot/extension-inject": 0.32.0-beta.8
|
||||||
"@polkadot/keyring": ^2.18.1
|
"@polkadot/keyring": ^3.0.0-beta.2
|
||||||
"@polkadot/ui-keyring": ^0.56.0-beta.3
|
"@polkadot/ui-keyring": ^0.57.0-beta.1
|
||||||
languageName: unknown
|
languageName: unknown
|
||||||
linkType: soft
|
linkType: soft
|
||||||
|
|
||||||
@ -2951,8 +2951,8 @@ __metadata:
|
|||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/extension-inject": 0.32.0-beta.8
|
"@polkadot/extension-inject": 0.32.0-beta.8
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^3.0.0-beta.2
|
||||||
"@polkadot/util-crypto": ^2.18.1
|
"@polkadot/util-crypto": ^3.0.0-beta.2
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
"@polkadot/api": "*"
|
"@polkadot/api": "*"
|
||||||
languageName: unknown
|
languageName: unknown
|
||||||
@ -2977,11 +2977,11 @@ __metadata:
|
|||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/extension-base": 0.32.0-beta.8
|
"@polkadot/extension-base": 0.32.0-beta.8
|
||||||
"@polkadot/extension-inject": 0.32.0-beta.8
|
"@polkadot/extension-inject": 0.32.0-beta.8
|
||||||
"@polkadot/keyring": ^2.18.1
|
"@polkadot/keyring": ^3.0.0-beta.2
|
||||||
"@polkadot/react-identicon": ^0.56.0-beta.3
|
"@polkadot/react-identicon": ^0.57.0-beta.1
|
||||||
"@polkadot/react-qr": ^0.56.0-beta.3
|
"@polkadot/react-qr": ^0.57.0-beta.1
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^3.0.0-beta.2
|
||||||
"@polkadot/util-crypto": ^2.18.1
|
"@polkadot/util-crypto": ^3.0.0-beta.2
|
||||||
"@types/bn.js": ^4.11.6
|
"@types/bn.js": ^4.11.6
|
||||||
"@types/enzyme": ^3.10.5
|
"@types/enzyme": ^3.10.5
|
||||||
"@types/enzyme-adapter-react-16": ^1.0.6
|
"@types/enzyme-adapter-react-16": ^1.0.6
|
||||||
@ -3025,38 +3025,38 @@ __metadata:
|
|||||||
languageName: unknown
|
languageName: unknown
|
||||||
linkType: soft
|
linkType: soft
|
||||||
|
|
||||||
"@polkadot/keyring@npm:^2.18.1":
|
"@polkadot/keyring@npm:^3.0.0-beta.2":
|
||||||
version: 2.18.1
|
version: 3.0.0-beta.2
|
||||||
resolution: "@polkadot/keyring@npm:2.18.1"
|
resolution: "@polkadot/keyring@npm:3.0.0-beta.2"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.4
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/util": 2.18.1
|
"@polkadot/util": 3.0.0-beta.2
|
||||||
"@polkadot/util-crypto": 2.18.1
|
"@polkadot/util-crypto": 3.0.0-beta.2
|
||||||
checksum: 3/293c9a25c33234a85710b10a6a253b76930ba0be7b42825af6bfc19d47579c185133d7b793c3e34ac0de9189563f65949cf08bf8dabf04c02661c675ee87e41d
|
checksum: 3/49dca58190d2de0f3f850d6fd462e705808e0c477b33de648352c66a8f38f8d21b3bffceac9d59aad0a8db93378a2673651f7df0e2d4dacae32be6d0bdcfe0fa
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/metadata@npm:1.25.1":
|
"@polkadot/metadata@npm:1.26.0-beta.1":
|
||||||
version: 1.25.1
|
version: 1.26.0-beta.1
|
||||||
resolution: "@polkadot/metadata@npm:1.25.1"
|
resolution: "@polkadot/metadata@npm:1.26.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/types": 1.25.1
|
"@polkadot/types": 1.26.0-beta.1
|
||||||
"@polkadot/types-known": 1.25.1
|
"@polkadot/types-known": 1.26.0-beta.1
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^2.18.1
|
||||||
"@polkadot/util-crypto": ^2.18.1
|
"@polkadot/util-crypto": ^2.18.1
|
||||||
bn.js: ^5.1.2
|
bn.js: ^5.1.2
|
||||||
checksum: 3/3b1c80d1c231a5b71aef26c657d92aa9647560328e11153ea09dcca4eea2579472a949bc6274d2358bbcf38a01c8cc0955eac16ff794c4f7819f9d479bef5093
|
checksum: 3/cbb23e1f6f64d528d368b73df5b084da96d66d0678d5f256bfb63321ab8bfcb899b45e88f8dde9dc56f26dd34cbdc113ed1cbfb50cc8e6889e8c277355673a00
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/react-identicon@npm:^0.56.0-beta.3":
|
"@polkadot/react-identicon@npm:^0.57.0-beta.1":
|
||||||
version: 0.56.0-beta.3
|
version: 0.57.0-beta.1
|
||||||
resolution: "@polkadot/react-identicon@npm:0.56.0-beta.3"
|
resolution: "@polkadot/react-identicon@npm:0.57.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/ui-settings": 0.56.0-beta.3
|
"@polkadot/ui-settings": 0.57.0-beta.1
|
||||||
"@polkadot/ui-shared": 0.56.0-beta.3
|
"@polkadot/ui-shared": 0.57.0-beta.1
|
||||||
color: ^3.1.2
|
color: ^3.1.2
|
||||||
jdenticon: 2.2.0
|
jdenticon: 2.2.0
|
||||||
react-copy-to-clipboard: ^5.0.2
|
react-copy-to-clipboard: ^5.0.2
|
||||||
@ -3068,13 +3068,13 @@ __metadata:
|
|||||||
react-dom: "*"
|
react-dom: "*"
|
||||||
react-is: "*"
|
react-is: "*"
|
||||||
styled-components: "*"
|
styled-components: "*"
|
||||||
checksum: 3/19447f8103d31dbf8cc54e0aa6cda17ddc7d9bec8b971ce4bc995aa2a68d2f938e4715c37eeea36df9709879a68344c241801a0ed7eed61d3ea10b99c030b266
|
checksum: 3/03ee88220f6f40433d80cda02af636c411cb67faac6256d55ba4144b1b2b473527276d245dfab6307b5b9aa2a2e15359a6c9ca3477534264df67f774f99ebd9b
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/react-qr@npm:^0.56.0-beta.3":
|
"@polkadot/react-qr@npm:^0.57.0-beta.1":
|
||||||
version: 0.56.0-beta.3
|
version: 0.57.0-beta.1
|
||||||
resolution: "@polkadot/react-qr@npm:0.56.0-beta.3"
|
resolution: "@polkadot/react-qr@npm:0.57.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
qrcode-generator: ^1.4.4
|
qrcode-generator: ^1.4.4
|
||||||
@ -3085,53 +3085,53 @@ __metadata:
|
|||||||
react: "*"
|
react: "*"
|
||||||
react-dom: "*"
|
react-dom: "*"
|
||||||
styled-components: "*"
|
styled-components: "*"
|
||||||
checksum: 3/c60a4f842d9cbbf049f41c9834290bc09465c0715829e21343fa2a1df533cbc964de292b18b906866b014d4efd1fbe967689f5da301a3891bd967bd022d143e4
|
checksum: 3/3dff1f6993acb7d1ba82c086f39858b3fa4337c1c6dc1470b2f1b5537c5a01fa0d269d852e0862c870c521665a09ea38819886e1d31d2fc0d6c864a73304a9d6
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/rpc-core@npm:1.25.1":
|
"@polkadot/rpc-core@npm:1.26.0-beta.1":
|
||||||
version: 1.25.1
|
version: 1.26.0-beta.1
|
||||||
resolution: "@polkadot/rpc-core@npm:1.25.1"
|
resolution: "@polkadot/rpc-core@npm:1.26.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/metadata": 1.25.1
|
"@polkadot/metadata": 1.26.0-beta.1
|
||||||
"@polkadot/rpc-provider": 1.25.1
|
"@polkadot/rpc-provider": 1.26.0-beta.1
|
||||||
"@polkadot/types": 1.25.1
|
"@polkadot/types": 1.26.0-beta.1
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^2.18.1
|
||||||
memoizee: ^0.4.14
|
memoizee: ^0.4.14
|
||||||
rxjs: ^6.6.0
|
rxjs: ^6.6.0
|
||||||
checksum: 3/7d205bbf0c93a91fa6cfb994a9dbecb92e7b98ff022611b5c79022437806a2d2f9a3c20ef7274e00dc2aa1cf5395af507d3bb1af1d5171c23ca7cf45fdfaf037
|
checksum: 3/24df7e2247081ee8fb9489a46715b74ca86e6379076df7f906cddea9536e1f94e25d5341fead2157d899475b1def0930d7d5c111c213955b8b323403da7a9065
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/rpc-provider@npm:1.25.1":
|
"@polkadot/rpc-provider@npm:1.26.0-beta.1":
|
||||||
version: 1.25.1
|
version: 1.26.0-beta.1
|
||||||
resolution: "@polkadot/rpc-provider@npm:1.25.1"
|
resolution: "@polkadot/rpc-provider@npm:1.26.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/metadata": 1.25.1
|
"@polkadot/metadata": 1.26.0-beta.1
|
||||||
"@polkadot/types": 1.25.1
|
"@polkadot/types": 1.26.0-beta.1
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^2.18.1
|
||||||
"@polkadot/util-crypto": ^2.18.1
|
"@polkadot/util-crypto": ^2.18.1
|
||||||
bn.js: ^5.1.2
|
bn.js: ^5.1.2
|
||||||
eventemitter3: ^4.0.4
|
eventemitter3: ^4.0.4
|
||||||
isomorphic-fetch: ^2.2.1
|
isomorphic-fetch: ^2.2.1
|
||||||
websocket: ^1.0.31
|
websocket: ^1.0.31
|
||||||
checksum: 3/3873039e08e7d8b8162762998bc35d3990991dec896f87a2ce8491186f6b75f3b1cd2d897be6b911e150d4bb5d1e84d699b2894680e9852ef9303900ba6f639d
|
checksum: 3/62919b991e86342b50b1082de4a53cbb2fb3d0051458f08db4837b32c1ae992b2d35c46e7ecefd6ba9a23a442a772ef4b0d13dcb96dceca9af59089b7d847665
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/typegen@npm:^1.25.1":
|
"@polkadot/typegen@npm:^1.26.0-beta.1":
|
||||||
version: 1.25.1
|
version: 1.26.0-beta.1
|
||||||
resolution: "@polkadot/typegen@npm:1.25.1"
|
resolution: "@polkadot/typegen@npm:1.26.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/core": ^7.10.5
|
"@babel/core": ^7.10.5
|
||||||
"@babel/register": ^7.10.5
|
"@babel/register": ^7.10.5
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/api": 1.25.1
|
"@polkadot/api": 1.26.0-beta.1
|
||||||
"@polkadot/metadata": 1.25.1
|
"@polkadot/metadata": 1.26.0-beta.1
|
||||||
"@polkadot/rpc-provider": 1.25.1
|
"@polkadot/rpc-provider": 1.26.0-beta.1
|
||||||
"@polkadot/types": 1.25.1
|
"@polkadot/types": 1.26.0-beta.1
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^2.18.1
|
||||||
handlebars: ^4.7.6
|
handlebars: ^4.7.6
|
||||||
websocket: ^1.0.31
|
websocket: ^1.0.31
|
||||||
@ -3142,41 +3142,41 @@ __metadata:
|
|||||||
polkadot-types-from-defs: scripts/polkadot-types-from-defs.js
|
polkadot-types-from-defs: scripts/polkadot-types-from-defs.js
|
||||||
polkadot-types-internal-interfaces: scripts/polkadot-types-internal-interfaces.js
|
polkadot-types-internal-interfaces: scripts/polkadot-types-internal-interfaces.js
|
||||||
polkadot-types-internal-metadata: scripts/polkadot-types-internal-metadata.js
|
polkadot-types-internal-metadata: scripts/polkadot-types-internal-metadata.js
|
||||||
checksum: 3/4af4c2969c8967a95e8d792a191958668a75c98febaa90b3ecd0d1afbc0b5582575a84ce2f374958371ba08cec89d4b5b8d57e7a71093d0166efbe6137c86518
|
checksum: 3/d1945effd41fb2ec4318fbc579fae32bc03f364340a006293f47cb775daa16f80c4e896fec5a9b1235480a919d6e63f5a99be25dab130a615cf2b854d80bb009
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/types-known@npm:1.25.1":
|
"@polkadot/types-known@npm:1.26.0-beta.1":
|
||||||
version: 1.25.1
|
version: 1.26.0-beta.1
|
||||||
resolution: "@polkadot/types-known@npm:1.25.1"
|
resolution: "@polkadot/types-known@npm:1.26.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/types": 1.25.1
|
"@polkadot/types": 1.26.0-beta.1
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^2.18.1
|
||||||
bn.js: ^5.1.2
|
bn.js: ^5.1.2
|
||||||
checksum: 3/3ca0c1e642a03596f8790b5f8ab69b05cda2c48cc1f6fe1a9a16be8fdea6064998cb83a17f7ac781ae699deeb32292e40deccb44aea713fabcaf718d43ebffaa
|
checksum: 3/b3552571bb0e5e77439253f8e18a3fe81fd8b84c597410bdf76eee0d2a6502fb17c79775b2f6785f9d8db6b4c511953936bf379645224c40a88d76cba7eb740b
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/types@npm:^1.25.1":
|
"@polkadot/types@npm:^1.26.0-beta.1":
|
||||||
version: 1.25.1
|
version: 1.26.0-beta.1
|
||||||
resolution: "@polkadot/types@npm:1.25.1"
|
resolution: "@polkadot/types@npm:1.26.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/metadata": 1.25.1
|
"@polkadot/metadata": 1.26.0-beta.1
|
||||||
"@polkadot/util": ^2.18.1
|
"@polkadot/util": ^2.18.1
|
||||||
"@polkadot/util-crypto": ^2.18.1
|
"@polkadot/util-crypto": ^2.18.1
|
||||||
"@types/bn.js": ^4.11.6
|
"@types/bn.js": ^4.11.6
|
||||||
bn.js: ^5.1.2
|
bn.js: ^5.1.2
|
||||||
memoizee: ^0.4.14
|
memoizee: ^0.4.14
|
||||||
rxjs: ^6.6.0
|
rxjs: ^6.6.0
|
||||||
checksum: 3/6a5723f4236f31c4895ade2e232b21a83be908c8ab9fb9a92711a4515be5bc0c6f6cb575088a3d73536bff26f06c6590d99d2cada4ca6a7336cf77f71e2da4f6
|
checksum: 3/f2013b4e79563cb7fc1e53da174d203112be7c7a4e9c4d99b5caa6db5c5d30efe6e08e55a89daa5918820c1737100c35a3b7a69d97ae829c42073fe44bcbca0c
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/ui-keyring@npm:^0.56.0-beta.3":
|
"@polkadot/ui-keyring@npm:^0.57.0-beta.1":
|
||||||
version: 0.56.0-beta.3
|
version: 0.57.0-beta.1
|
||||||
resolution: "@polkadot/ui-keyring@npm:0.56.0-beta.3"
|
resolution: "@polkadot/ui-keyring@npm:0.57.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
"@ledgerhq/hw-transport-node-hid": ^5.19.1
|
"@ledgerhq/hw-transport-node-hid": ^5.19.1
|
||||||
@ -3192,42 +3192,42 @@ __metadata:
|
|||||||
dependenciesMeta:
|
dependenciesMeta:
|
||||||
"@ledgerhq/hw-transport-node-hid":
|
"@ledgerhq/hw-transport-node-hid":
|
||||||
optional: true
|
optional: true
|
||||||
checksum: 3/40c8478de7b14d62f8734e47880a450ee8555c6302f0b1610d91c870340487b8dc19ec7a69f8bea9f2fd44a77c26cdc0bf914e8024ea98aa79d2243f8e9a17b2
|
checksum: 3/55962fac3fbc07d85dcede5fb478d942a31f6dab231c4181f75b5b5f01047fff54d9c6dfa5aee01481d83a74bebb65da0285bfb88e063c542a38a75c29ce17b6
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/ui-settings@npm:0.56.0-beta.3":
|
"@polkadot/ui-settings@npm:0.57.0-beta.1":
|
||||||
version: 0.56.0-beta.3
|
version: 0.57.0-beta.1
|
||||||
resolution: "@polkadot/ui-settings@npm:0.56.0-beta.3"
|
resolution: "@polkadot/ui-settings@npm:0.57.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
eventemitter3: ^4.0.4
|
eventemitter3: ^4.0.4
|
||||||
store: ^2.0.12
|
store: ^2.0.12
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
"@polkadot/util": "*"
|
"@polkadot/util": "*"
|
||||||
checksum: 3/6707d58f70e3defb45b5ae8e9e5e0660e254332b1636c46953dd8e207c1408d0485f43855ff947711a22328797374092951119e5b55b92c2d4b272d1b7ad04df
|
checksum: 3/710aedfda14af1dbc7602fdc68e0c121cf6646a27e788d690acec29bd899263acc76dff4fbd1909abe85aabcaf2997e42095445e3ac56f300eda23734a3df1a2
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/ui-shared@npm:0.56.0-beta.3":
|
"@polkadot/ui-shared@npm:0.57.0-beta.1":
|
||||||
version: 0.56.0-beta.3
|
version: 0.57.0-beta.1
|
||||||
resolution: "@polkadot/ui-shared@npm:0.56.0-beta.3"
|
resolution: "@polkadot/ui-shared@npm:0.57.0-beta.1"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.5
|
"@babel/runtime": ^7.10.5
|
||||||
color: ^3.1.2
|
color: ^3.1.2
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
"@polkadot/util": "*"
|
"@polkadot/util": "*"
|
||||||
"@polkadot/util-crypto": "*"
|
"@polkadot/util-crypto": "*"
|
||||||
checksum: 3/38477d1646a8a5a1079edd819a9caa916df35811c52865dd516955871729a640054efe0d46d304cd6d1b5eb1a21c8e7e2402fb2b0469319c9394e8c913441a0f
|
checksum: 3/5c3abd8a6bf6cb8c6fc07f9478e15334c9a243ab63e8ceb527558fdca5fa7749ec764f4721b992de9d3eb4b09d3d6f6535d924c742d9989c84108a8a25871da7
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/util-crypto@npm:^2.18.1":
|
"@polkadot/util-crypto@npm:^3.0.0-beta.2":
|
||||||
version: 2.18.1
|
version: 3.0.0-beta.2
|
||||||
resolution: "@polkadot/util-crypto@npm:2.18.1"
|
resolution: "@polkadot/util-crypto@npm:3.0.0-beta.2"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.4
|
"@babel/runtime": ^7.10.5
|
||||||
"@polkadot/util": 2.18.1
|
"@polkadot/util": 3.0.0-beta.2
|
||||||
"@polkadot/wasm-crypto": ^1.2.1
|
"@polkadot/wasm-crypto": ^1.2.1
|
||||||
base-x: ^3.0.8
|
base-x: ^3.0.8
|
||||||
bip39: ^3.0.2
|
bip39: ^3.0.2
|
||||||
@ -3236,23 +3236,24 @@ __metadata:
|
|||||||
elliptic: ^6.5.3
|
elliptic: ^6.5.3
|
||||||
js-sha3: ^0.8.0
|
js-sha3: ^0.8.0
|
||||||
pbkdf2: ^3.1.1
|
pbkdf2: ^3.1.1
|
||||||
|
scryptsy: ^2.1.0
|
||||||
tweetnacl: ^1.0.3
|
tweetnacl: ^1.0.3
|
||||||
xxhashjs: ^0.2.2
|
xxhashjs: ^0.2.2
|
||||||
checksum: 3/412d3f1c0d0c318130808cdb6d0097fc0be915412e505d86e38ea7f2e131f0a7277b371bd4a9f41608d5220fc04f71de29409781f75f2a40399490827603f6fd
|
checksum: 3/f257c010802ffdf236bb0a0e1c8ffbce19440a3a8603a78a7ae108805da6454ad87e43db580b167d540f79439ef50044b115cdc6eb9f657b10261fd2112b9a30
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"@polkadot/util@npm:^2.18.1":
|
"@polkadot/util@npm:^3.0.0-beta.2":
|
||||||
version: 2.18.1
|
version: 3.0.0-beta.2
|
||||||
resolution: "@polkadot/util@npm:2.18.1"
|
resolution: "@polkadot/util@npm:3.0.0-beta.2"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime": ^7.10.4
|
"@babel/runtime": ^7.10.5
|
||||||
"@types/bn.js": ^4.11.6
|
"@types/bn.js": ^4.11.6
|
||||||
bn.js: ^5.1.2
|
bn.js: ^5.1.2
|
||||||
camelcase: ^5.3.1
|
camelcase: ^5.3.1
|
||||||
chalk: ^4.1.0
|
chalk: ^4.1.0
|
||||||
ip-regex: ^4.1.0
|
ip-regex: ^4.1.0
|
||||||
checksum: 3/df6cb63e7d5cff1f0075e7807b76c6ea26c1a52f887dc20558d8717cde81713fa391cfd17dd82792f4c6271be30f143d3a11c816b7c00eaeea1d411fe5208e71
|
checksum: 3/8fd56e268363acb838095906f33c1369a9b57160fd3499357f8aa50430d35c0a0b4b66359c5fe7dd1e95e81f682cfa5cf851b54c0589f66bcd331825dcb20a6d
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
@ -18691,7 +18692,7 @@ __metadata:
|
|||||||
dependencies:
|
dependencies:
|
||||||
"@babel/core": ^7.10.5
|
"@babel/core": ^7.10.5
|
||||||
"@polkadot/dev": ^0.55.27
|
"@polkadot/dev": ^0.55.27
|
||||||
"@polkadot/typegen": ^1.25.1
|
"@polkadot/typegen": ^1.26.0-beta.1
|
||||||
"@types/jest": ^26.0.4
|
"@types/jest": ^26.0.4
|
||||||
copy-webpack-plugin: ^6.0.3
|
copy-webpack-plugin: ^6.0.3
|
||||||
sinon-chrome: ^3.0.1
|
sinon-chrome: ^3.0.1
|
||||||
@ -18867,6 +18868,13 @@ __metadata:
|
|||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
|
"scryptsy@npm:^2.1.0":
|
||||||
|
version: 2.1.0
|
||||||
|
resolution: "scryptsy@npm:2.1.0"
|
||||||
|
checksum: 3/9fd847955caa9d13a6d58a0360ba8fb31f8e7e7da9250b4c09c67db784a0f6dda757bc837313b0860c0e35f84a56ba068394c682dd4fba81c5899d82832aa7d6
|
||||||
|
languageName: node
|
||||||
|
linkType: hard
|
||||||
|
|
||||||
"sdp@npm:^2.12.0, sdp@npm:^2.6.0":
|
"sdp@npm:^2.12.0, sdp@npm:^2.6.0":
|
||||||
version: 2.12.0
|
version: 2.12.0
|
||||||
resolution: "sdp@npm:2.12.0"
|
resolution: "sdp@npm:2.12.0"
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user