1import React from 'react';
2import { Input } from 'indigo-react';
3import * as bip39 from 'bip39';
5import { DEFAULT_HD_PATH } from 'lib/wallet';
10} from 'lib/validators';
11import { prependSig } from 'lib/transformers';
13const kExampleMnemonic = bip39.generateMnemonic();
15// const RequiredInput = advancedInput({
16// WrappedComponent: Input,
17// validators: [validateNotEmpty],
20// const NetworkKeyInput = advancedInput({
21// WrappedComponent: Input,
22// validators: [validateNotEmpty, validateNetworkKey],
25// const NetworkSeedInput = advancedInput({
26// WrappedComponent: Input,
27// validators: [validateNotEmpty, validateNetworkSeed],
30// const AddressInput = advancedInput({
31// WrappedComponent: Input,
32// validators: [validateEthereumAddress, validateNotEmpty],
35export function PassphraseInput(props) {
40 placeholder="Passphrase"
46export function MnemonicInput(props) {
51 placeholder={`e.g. ${kExampleMnemonic}`}
52 validators={[validateMnemonic, validateNotEmpty]}
58export function HdPathInput(props) {
63 placeholder={`${DEFAULT_HD_PATH}`}
64 validators={[validateNotEmpty]}
70// const GalaxyInput = advancedInput({
71// WrappedComponent: Input,
72// validators: [validateGalaxy, validateNotEmpty],
73// transformers: [prependSig],
76export function PointInput(props) {
80 placeholder="e.g. ~zod"
81 initialValue={props.initialValue || '~'}
82 validators={[validatePoint, validateNotEmpty]}
83 transformers={[prependSig]}
90// const TicketInput = advancedInput({
91// WrappedComponent: Input,
92// validators: [validateTicket, validateNotEmpty],
93// transformers: [prependSig],
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list