Remove debug line, add Form components
This commit is contained in:
parent
097a523b39
commit
a727e89e10
4 changed files with 84 additions and 79 deletions
|
@ -38,7 +38,6 @@ export class SplashScreen extends React.PureComponent<Props, State> {
|
||||||
updateStatus() {
|
updateStatus() {
|
||||||
Lbry.status().then(status => {
|
Lbry.status().then(status => {
|
||||||
this._updateStatusCallback(status);
|
this._updateStatusCallback(status);
|
||||||
window.status = status;
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
// @flow
|
// @flow
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { FormRow, FormField } from 'component/common/form';
|
import { Form, FormRow, FormField } from 'component/common/form';
|
||||||
import { Modal } from 'modal/modal';
|
import { Modal } from 'modal/modal';
|
||||||
import Button from 'component/button';
|
import Button from 'component/button';
|
||||||
|
|
||||||
|
@ -43,16 +43,18 @@ class ModalWalletDecrypt extends React.PureComponent<Props> {
|
||||||
onConfirmed={() => this.submitDecryptForm()}
|
onConfirmed={() => this.submitDecryptForm()}
|
||||||
onAborted={closeModal}
|
onAborted={closeModal}
|
||||||
>
|
>
|
||||||
|
<Form onSubmit={() => this.submitDecryptForm()}>
|
||||||
{__(
|
{__(
|
||||||
'Your wallet has been encrypted with a local password, performing this action will remove this password.'
|
'Your wallet has been encrypted with a local password, performing this action will remove this password.'
|
||||||
)}
|
)}
|
||||||
<FormRow padded>
|
<div className="card__actions">
|
||||||
<Button
|
<Button
|
||||||
button="link"
|
button="link"
|
||||||
label={__('Learn more')}
|
label={__('Learn more')}
|
||||||
href="https://lbry.io/faq/wallet-encryption"
|
href="https://lbry.io/faq/wallet-encryption"
|
||||||
/>
|
/>
|
||||||
</FormRow>
|
</div>
|
||||||
|
</Form>
|
||||||
</Modal>
|
</Modal>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
// @flow
|
// @flow
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { FormRow, FormField } from 'component/common/form';
|
import { Form, FormRow, FormField } from 'component/common/form';
|
||||||
import { Modal } from 'modal/modal';
|
import { Modal } from 'modal/modal';
|
||||||
import Button from 'component/button';
|
import Button from 'component/button';
|
||||||
|
|
||||||
|
@ -89,6 +89,7 @@ class ModalWalletEncrypt extends React.PureComponent<Props> {
|
||||||
onConfirmed={() => this.submitEncryptForm()}
|
onConfirmed={() => this.submitEncryptForm()}
|
||||||
onAborted={closeModal}
|
onAborted={closeModal}
|
||||||
>
|
>
|
||||||
|
<Form onSubmit={() => this.submitEncryptForm()}>
|
||||||
{__(
|
{__(
|
||||||
'Encrypting your wallet will require a password to access your local wallet data when LBRY starts. Please enter a new password for your wallet.'
|
'Encrypting your wallet will require a password to access your local wallet data when LBRY starts. Please enter a new password for your wallet.'
|
||||||
)}
|
)}
|
||||||
|
@ -126,14 +127,15 @@ class ModalWalletEncrypt extends React.PureComponent<Props> {
|
||||||
onChange={event => this.onChangeUnderstandConfirm(event)}
|
onChange={event => this.onChangeUnderstandConfirm(event)}
|
||||||
/>
|
/>
|
||||||
</FormRow>
|
</FormRow>
|
||||||
<FormRow padded>
|
<div className="card__actions">
|
||||||
<Button
|
<Button
|
||||||
button="link"
|
button="link"
|
||||||
label={__('Learn more')}
|
label={__('Learn more')}
|
||||||
href="https://lbry.io/faq/wallet-encryption"
|
href="https://lbry.io/faq/wallet-encryption"
|
||||||
/>
|
/>
|
||||||
</FormRow>
|
</div>
|
||||||
{failMessage && <div className="error-text">{__(failMessage)}</div>}
|
{failMessage && <div className="error-text">{__(failMessage)}</div>}
|
||||||
|
</Form>
|
||||||
</Modal>
|
</Modal>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
// @flow
|
// @flow
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { FormRow, FormField } from 'component/common/form';
|
import { Form, FormRow, FormField } from 'component/common/form';
|
||||||
import { Modal } from 'modal/modal';
|
import { Modal } from 'modal/modal';
|
||||||
import Button from 'component/button';
|
import Button from 'component/button';
|
||||||
|
|
||||||
|
@ -43,6 +43,7 @@ class ModalWalletUnlock extends React.PureComponent<Props> {
|
||||||
onConfirmed={() => unlockWallet(password)}
|
onConfirmed={() => unlockWallet(password)}
|
||||||
onAborted={quit}
|
onAborted={quit}
|
||||||
>
|
>
|
||||||
|
<Form onSubmit={() => unlockWallet(password)}>
|
||||||
{__(
|
{__(
|
||||||
'Your wallet has been encrypted with a local password. Please enter your wallet password to proceed.'
|
'Your wallet has been encrypted with a local password. Please enter your wallet password to proceed.'
|
||||||
)}
|
)}
|
||||||
|
@ -56,13 +57,14 @@ class ModalWalletUnlock extends React.PureComponent<Props> {
|
||||||
onChange={event => this.onChangePassword(event)}
|
onChange={event => this.onChangePassword(event)}
|
||||||
/>
|
/>
|
||||||
</FormRow>
|
</FormRow>
|
||||||
<FormRow padded>
|
<div className="card__actions">
|
||||||
<Button
|
<Button
|
||||||
button="link"
|
button="link"
|
||||||
label={__('Learn more')}
|
label={__('Learn more')}
|
||||||
href="https://lbry.io/faq/wallet-encryption"
|
href="https://lbry.io/faq/wallet-encryption"
|
||||||
/>
|
/>
|
||||||
</FormRow>
|
</div>
|
||||||
|
</Form>
|
||||||
</Modal>
|
</Modal>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue