Add/create/import/join. Main sass file
This commit is contained in:
parent
e00fb50674
commit
df0f77b383
7 changed files with 923 additions and 474 deletions
|
|
@ -1,228 +1,226 @@
|
|||
<div
|
||||
class="topbar-container"
|
||||
ng-include="'views/includes/topbar.html'"
|
||||
ng-init="titleSection='Import wallet'; goBackToState = 'add'; noColor = true">
|
||||
</div>
|
||||
<ion-view view-title="Import wallet" ng-controller="importController" ng-init="type='12'">
|
||||
<ion-nav-buttons side="primary">
|
||||
<a href ui-sref="add" class="button icon-left ion-chevron-left button-clear button-dark">Add</a>
|
||||
</ion-nav-buttons>
|
||||
<ion-nav-buttons side="secondary">
|
||||
<qr-scanner class="button button-clear button-positive" on-scan="processWalletInfo(data)"></qr-scanner>
|
||||
</ion-nav-buttons>
|
||||
|
||||
<ion-content>
|
||||
|
||||
<div class="content p20b" ng-controller="importController" ng-init="type='12'">
|
||||
<div class="create-tab pr small-only-text-center" ng-hide="create.hideTabs">
|
||||
<div class="row">
|
||||
<div class="tab-container small-4 medium-4 large-4" ng-class="{'selected': type =='12'}">
|
||||
<a href ng-click="setType('12')" translate>Recovery Phrase</a>
|
||||
<div class="col">
|
||||
<button
|
||||
ng-class="{'button-dark': type == '12', 'button-stable': type != '12'}"
|
||||
class="button button-full button-clear"
|
||||
ng-click="setType('12')" translate>
|
||||
Recovery Phrase
|
||||
</button>
|
||||
</div>
|
||||
<div class="tab-container small-4 medium-4 large-4" ng-class="{'selected': type=='file'}">
|
||||
<a href ng-click="setType('file')" translate>File/Text</a>
|
||||
<div class="col">
|
||||
<button
|
||||
ng-class="{'button-dark': type == 'file', 'button-stable': type != 'file'}"
|
||||
class="button button-full button-clear"
|
||||
ng-click="setType('file')" translate>
|
||||
File/Text
|
||||
</button>
|
||||
</div>
|
||||
<div class="tab-container small-4 medium-4 large-4" ng-class="{'selected': type=='hwWallet'}">
|
||||
<a href ng-click="setType('hwWallet')" translate>Hardware Wallet</a>
|
||||
<div class="col">
|
||||
<button
|
||||
ng-class="{'button-dark': type == 'hwWallet', 'button-stable': type != 'hwWallet'}"
|
||||
class="button button-full button-clear"
|
||||
ng-click="setType('hwWallet')" translate>
|
||||
Hardware Wallet
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div ng-show="type == '12' ">
|
||||
<div ng-show="type == '12'">
|
||||
|
||||
<div class="row" ng-click="importErr = error = null">
|
||||
<div class="large-12 columns">
|
||||
<div class="box-notification m20b" ng-show="importErr">
|
||||
<div class="text-warning">
|
||||
<div class="m10 text-bold" translate>Could not access the wallet at the server. Please check:</div>
|
||||
<ul class="size-12">
|
||||
<li translate>The password of the recovery phrase (if set)</li>
|
||||
<li translate>The derivation path</li>
|
||||
<li translate>The wallet service URL</li>
|
||||
</ul>
|
||||
<div class="m15l">
|
||||
<span translate>NOTE: To import a wallet from a 3rd party software, please go to Add Wallet > Create Wallet, and specify the Recovery Phrase there.</span><br>
|
||||
</div>
|
||||
<div ng-show="importErr || error" class="padding assertive" ng-click="importErr = error = null">
|
||||
<div ng-show="importErr">
|
||||
<div translate>Could not access the wallet at the server. Please check:</div>
|
||||
<ul>
|
||||
<li translate>The password of the recovery phrase (if set)</li>
|
||||
<li translate>The derivation path</li>
|
||||
<li translate>The wallet service URL</li>
|
||||
</ul>
|
||||
<div translate>
|
||||
NOTE: To import a wallet from a 3rd party software, please go to Add Wallet > Create Wallet, and specify the Recovery Phrase there.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="box-notification m20b" ng-show="error">
|
||||
<div class="text-warning">{{error|translate}}</div>
|
||||
<div ng-show="error">
|
||||
{{error|translate}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="large-12 columns">
|
||||
<form name="importForm12" ng-submit="importMnemonic(importForm12)" novalidate>
|
||||
<label for="words" class="m25r">
|
||||
<span translate>Type the Recovery Phrase (usually 12 words)</span>:
|
||||
<form name="importForm12" ng-submit="importMnemonic(importForm12)" novalidate>
|
||||
<div class="list">
|
||||
<label class="item item-input item-stacked-label">
|
||||
<span class="input-label" translate>Type the Recovery Phrase (usually 12 words)</span>
|
||||
<textarea name="words"
|
||||
ng-model="words"
|
||||
rows="3"
|
||||
autocapitalize="off"
|
||||
spellcheck="false"></textarea>
|
||||
</label>
|
||||
|
||||
<div class="qr-scanner-input-import">
|
||||
<qr-scanner on-scan="processWalletInfo(data)"></qr-scanner>
|
||||
<ion-toggle ng-model="showAdv" toggle-class="toggle-stable">
|
||||
<span translate ng-show="!showAdv">Show advanced options</span>
|
||||
<span translate ng-show="showAdv">Hide advanced options</span>
|
||||
</ion-toggle>
|
||||
|
||||
<div ng-show="showAdv">
|
||||
|
||||
<label class="item item-input item-stacked-label">
|
||||
<span class="input-label">Wallet Service URL</span>
|
||||
<input type="text" id="bwsurl" name="bwsurl" ng-model="bwsurl">
|
||||
</label>
|
||||
|
||||
<label class="item item-input item-stacked-label">
|
||||
<span class="input-label" translate>Password</span>
|
||||
<input type="text"
|
||||
placeholder="{{'The recovery phrase could require a password to be imported'|translate}}"
|
||||
autocapitalize="off"
|
||||
name="passphrase"
|
||||
ng-model="passphrase">
|
||||
</label>
|
||||
|
||||
<label class="item item-input item-stacked-label">
|
||||
<span class="input-label" translate>Derivation Path</span>
|
||||
<input type="text"
|
||||
placeholder="{{'BIP32 path for address derivation'|translate}}"
|
||||
name="derivationPath"
|
||||
ng-model="derivationPath">
|
||||
</label>
|
||||
|
||||
<ion-toggle ng-model="testnetEnabled" ng-change="setDerivationPath(testnetEnabled)" toggle-class="toggle-positive">
|
||||
Testnet
|
||||
</ion-toggle>
|
||||
</div>
|
||||
|
||||
<textarea class="form-control m10t" name="words" ng-model="words" rows="3" autocapitalize="off" spellcheck="false"></textarea>
|
||||
|
||||
<div class="m10t oh" ng-init="hideAdv=true">
|
||||
<a class="button outline light-gray expand tiny p10i" ng-click="hideAdv=!hideAdv">
|
||||
<i class="fi-widget m3r"></i>
|
||||
<span translate ng-hide="!hideAdv">Show advanced options</span>
|
||||
<span translate ng-hide="hideAdv">Hide advanced options</span>
|
||||
<i ng-if="hideAdv" class="icon-arrow-down4"></i>
|
||||
<i ng-if="!hideAdv" class="icon-arrow-up4"></i>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div ng-hide="hideAdv" class="row">
|
||||
<div class="large-12 columns">
|
||||
<label for="passphrase" class="oh"><span translate>Password</span> <small translate>The Wallet Recovery Phrase could require a password to be imported</small>
|
||||
<div class="input">
|
||||
<input type="password" class="form-control" placeholder="{{'Password'|translate}}"
|
||||
name="passphrase" ng-model="passphrase">
|
||||
</div>
|
||||
</label>
|
||||
|
||||
<div>
|
||||
<label class="oh"><span translate>Derivation Path</span> <small translate>BIP32 path for address derivation</small>
|
||||
<input type="text" class="form-control" name="derivationPath" ng-model="derivationPath">
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<label for="bws" class="oh">
|
||||
<span>Wallet Service URL</span>
|
||||
<input type="text" id="bwsurl" name="bwsurl" ng-model="bwsurl">
|
||||
</label>
|
||||
|
||||
<div class="oh">
|
||||
<ion-toggle ng-model="testnetEnabled" ng-change="setDerivationPath()" toggle-class="toggle-balanced" class="bct">
|
||||
<span class="toggle-label">Testnet</span>
|
||||
</ion-toggle>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<button translate type="submit" class="button round expand black m10t" ng-disabled="importForm12.$invalid">Import</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div ng-show="type == 'file' ">
|
||||
<div class="row">
|
||||
<div class="large-12 columns">
|
||||
<div class="box-notification m20b" ng-show="error">
|
||||
<span class="text-warning size-14">
|
||||
{{error|translate}}
|
||||
</span>
|
||||
</div>
|
||||
<form name="importForm" ng-submit="importBlob(importForm)" novalidate>
|
||||
|
||||
<div ng-show="!index.isSafari && !index.isCordova" class="line-b m10b">
|
||||
<label for="backupFile">
|
||||
<span translate>Choose a backup file from your computer</span> <i class="fi-laptop"></i>
|
||||
</label>
|
||||
<input type="file" class="form-control" placeholder="{{'Select a backup file'|translate}}"
|
||||
name="backupFile" ng-model="backupFile" ng-file-select>
|
||||
</div>
|
||||
<button type="submit"
|
||||
class="button button-block button-positive"
|
||||
ng-disabled="importForm12.$invalid" translate>Import</button>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div ng-show="index.isSafari || index.isCordova">
|
||||
<label for="backupText">
|
||||
<span translate>Paste the backup plain text code</span> <i class="fi-clipboard"></i>
|
||||
</label>
|
||||
<textarea class="form-control" name="backupText" ng-model="backupText" rows="5"></textarea>
|
||||
</div>
|
||||
<div ng-show="type == 'file'">
|
||||
|
||||
<label for="password"><span translate>Password</span>
|
||||
<div class="padding assertive" ng-show="error">
|
||||
{{error|translate}}
|
||||
</div>
|
||||
|
||||
<form name="importForm" ng-submit="importBlob(importForm)" novalidate>
|
||||
|
||||
<div class="list">
|
||||
<label class="item item-input item-stacked-label" ng-show="!index.isSafari && !index.isCordova">
|
||||
<span class="input-label" translate>Choose a backup file from your computer</span>
|
||||
<input type="file"
|
||||
placeholder="{{'Select a backup file'|translate}}"
|
||||
name="backupFile"
|
||||
ng-model="backupFile" ng-file-select>
|
||||
</label>
|
||||
<div class="input">
|
||||
<input type="password" class="form-control" placeholder="{{'Your password'|translate}}"
|
||||
name="password" ng-model="password">
|
||||
|
||||
<label class="item item-input item-stacked-label" ng-show="index.isSafari || index.isCordova">
|
||||
<span class="input-label" translate>Paste the backup plain text code</span>
|
||||
<textarea name="backupText" ng-model="backupText" rows="5"></textarea>
|
||||
</label>
|
||||
|
||||
<label class="item item-input item-stacked-label">
|
||||
<span class="input-label" translate>Password</span>
|
||||
<input type="password"
|
||||
placeholder="{{'Your password'|translate}}"
|
||||
name="password"
|
||||
ng-model="password">
|
||||
</label>
|
||||
|
||||
<ion-toggle ng-model="showAdv" toggle-class="toggle-stable">
|
||||
<span translate ng-show="!showAdv">Show advanced options</span>
|
||||
<span translate ng-show="showAdv">Hide advanced options</span>
|
||||
</ion-toggle>
|
||||
|
||||
<div ng-show="showAdv">
|
||||
|
||||
<label class="item item-input item-stacked-label">
|
||||
<span class="input-label">Wallet Service URL</span>
|
||||
<input type="text" id="bwsurl" name="bwsurl" ng-model="bwsurl">
|
||||
</label>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="m10t oh" ng-init="hideAdv=true">
|
||||
<a class="button outline light-gray expand tiny p10i" ng-click="hideAdv=!hideAdv">
|
||||
<i class="fi-widget m3r"></i>
|
||||
<span translate ng-hide="!hideAdv">Show advanced options</span>
|
||||
<span translate ng-hide="hideAdv">Hide advanced options</span>
|
||||
<i ng-if="hideAdv" class="icon-arrow-down4"></i>
|
||||
<i ng-if="!hideAdv" class="icon-arrow-up4"></i>
|
||||
</a>
|
||||
</div>
|
||||
<div ng-hide="hideAdv" class="row">
|
||||
<div class="large-12 columns">
|
||||
|
||||
<label for="bws" class="oh">
|
||||
<span>Wallet Service URL</span>
|
||||
<input type="text" id="bwsurl" name="bwsurl" ng-model="bwsurl">
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<button translate type="submit" class="button round expand black"
|
||||
ng-disabled="importForm.$invalid || !password ">
|
||||
Import backup
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div ng-show="type == 'hwWallet'">
|
||||
<div class="row">
|
||||
<div class="large-12 columns">
|
||||
<div class="box-notification m20b" ng-show="error">
|
||||
<span class="text-warning size-14">
|
||||
{{error|translate}}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
<form name="importForm3" ng-submit="importHW(importForm3)" novalidate>
|
||||
<div ng-show="!seedOptions[0]">
|
||||
<span translate>No hardware wallets supported on this device</span>
|
||||
<button type="submit"
|
||||
class="button round expand black"
|
||||
ng-disabled="importForm.$invalid || !password " translate>
|
||||
Import backup
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div ng-show="type == 'hwWallet'">
|
||||
<div class="padding assertive" ng-show="error">
|
||||
{{error|translate}}
|
||||
</div>
|
||||
|
||||
<form name="importForm3" ng-submit="importHW(importForm3)" novalidate>
|
||||
|
||||
<div class="card" ng-show="!seedOptions[0]">
|
||||
<div class="item item-text-wrap" translate>
|
||||
No hardware wallets supported on this device
|
||||
</div>
|
||||
<div ng-show="seedOptions[0]">
|
||||
<div>
|
||||
<label><span translate>Wallet Type</span>
|
||||
<select class="m10t" ng-model="seedSource"
|
||||
ng-options="seed as seed.label for seed in seedOptions"
|
||||
ng-change="setSeedSource()">
|
||||
</div>
|
||||
|
||||
<div ng-show="seedOptions[0]">
|
||||
<div class="list">
|
||||
|
||||
<label class="item item-input item-select">
|
||||
<div class="input-label" translate>
|
||||
Wallet Type
|
||||
</div>
|
||||
<select ng-model="seedSource"
|
||||
ng-options="seed as seed.label for seed in seedOptions"
|
||||
ng-change="setSeedSource()">
|
||||
</select>
|
||||
</label>
|
||||
|
||||
<label class="item item-input item-stacked-label"
|
||||
ng-show="seedSourceId == 'trezor' || seedSourceId == 'ledger'">
|
||||
<span class="input-label" translate>Account Number</span>
|
||||
<input type="number" id="account" ng-model="account" ignore-mouse-wheel>
|
||||
</label>
|
||||
|
||||
<ion-toggle ng-show="seedSourceId == 'trezor'"
|
||||
ng-model="isMultisig"
|
||||
toggle-class="toggle-positive">
|
||||
<span translate>Shared Wallet</span>
|
||||
</ion-toggle>
|
||||
|
||||
<ion-toggle ng-model="showAdv" toggle-class="toggle-stable">
|
||||
<span translate ng-show="!showAdv">Show advanced options</span>
|
||||
<span translate ng-show="showAdv">Hide advanced options</span>
|
||||
</ion-toggle>
|
||||
|
||||
<div ng-show="showAdv">
|
||||
|
||||
<label class="item item-input item-stacked-label">
|
||||
<span class="input-label">Wallet Service URL</span>
|
||||
<input type="text" id="bwsurl" name="bwsurl" ng-model="bwsurl">
|
||||
</label>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div ng-show="seedSourceId == 'trezor' || seedSourceId == 'ledger'">
|
||||
<button translate type="submit" class="button button-block button-positive">
|
||||
Import
|
||||
</button>
|
||||
</div> <!-- seedoptions show -->
|
||||
|
||||
<label class="oh"><span translate>Account Number</span>
|
||||
<input type="number" id="account" ng-model="account" ignore-mouse-wheel>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="oh" ng-show="seedSourceId == 'trezor'">
|
||||
<ion-toggle ng-model="isMultisig" toggle-class="toggle-balanced" class="bct">
|
||||
<span class="toggle-label" translate>Shared Wallet</span>
|
||||
</ion-toggle>
|
||||
</div>
|
||||
|
||||
<div class="m10t oh" ng-init="hideAdv=true">
|
||||
<a class="button outline light-gray expand tiny p10i" ng-click="hideAdv=!hideAdv">
|
||||
<i class="fi-widget m3r"></i>
|
||||
<span translate ng-hide="!hideAdv">Show advanced options</span>
|
||||
<span translate ng-hide="hideAdv">Hide advanced options</span>
|
||||
<i ng-if="hideAdv" class="icon-arrow-down4"></i>
|
||||
<i ng-if="!hideAdv" class="icon-arrow-up4"></i>
|
||||
</a>
|
||||
</div>
|
||||
<div ng-hide="hideAdv" class="row">
|
||||
<div class="large-12 columns">
|
||||
|
||||
<label for="bws" class="oh">
|
||||
<span>Wallet Service URL</span>
|
||||
<input type="text" id="bwsurl" name="bwsurl" ng-model="bwsurl">
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<button translate type="submit" class="button round expand black">
|
||||
Import
|
||||
</button>
|
||||
</div> <!-- seedoptions show -->
|
||||
</form>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="extra-margin-bottom"></div>
|
||||
</ion-content>
|
||||
</ion-view>
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue