diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2ec28061..dd8d27ea 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,4 +1,4 @@ -image: node:8 +image: node:9.3 cache: paths: diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 00000000..9f12ac88 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,14 @@ +# 1.0.1-beta +__added__ +- DigiByte in coin menu +- blocking device with seedless setup + +__fixed__ +- token input in "Account/Summary" (https://github.com/trezor/trezor-wallet/issues/235) +- "Go to your standard wallet" button in passphrase modal (https://github.com/trezor/trezor-wallet/issues/222) +- Double click on "show passphrase" (https://github.com/trezor/trezor-wallet/issues/221) +- images preloader for offline status (https://github.com/trezor/trezor-wallet/issues/218) + + +# 1.0.0-beta +- first release \ No newline at end of file diff --git a/Makefile b/Makefile index e40ce5de..c7a2cc4d 100644 --- a/Makefile +++ b/Makefile @@ -10,19 +10,34 @@ build-%: # usage: # make stage-beta # make stage-stable -stage-%: +sync-stage-%: ./scripts/s3sync.sh stage $* # s3sync with beta.mytrezor.com # Upload build/beta only # usage: # make beta -beta: +sync-beta: ./scripts/s3sync.sh beta beta # s3sync with wallet.mytrezor.com # Upload build/stable only # usage: # make stable -stable: - ./scripts/s3sync.sh stable stable \ No newline at end of file +sync-stable: + ./scripts/s3sync.sh stable stable + +.DEFAULT_GOAL:= default +default: + @echo "Build:" + @echo "git checkout to desired branch (beta|stable)" + @echo " make build-beta" + @echo " make build-stable" + @echo "Sync:" + @echo "s3 sync desired build to server (beta.mytrezor.com|wallet.mytrezor.com)" + @echo " make sync-beta" + @echo " make sync-stable" + @echo "Staging:" + @echo "s3 sync desired build to stage server (stage.mytrezor.com)" + @echo " make sync-stage-beta" + @echo " make sync-stage-stable" \ No newline at end of file diff --git a/package.json b/package.json index 80a26712..7dcd4df5 100644 --- a/package.json +++ b/package.json @@ -52,6 +52,7 @@ "react": "^16.4.2", "react-dom": "^16.2.0", "react-hot-loader": "^4.3.4", + "react-json-view": "^1.19.1", "react-qr-svg": "^2.1.0", "react-redux": "^5.0.7", "react-router-dom": "^4.2.2", diff --git a/src/actions/ModalActions.js b/src/actions/ModalActions.js index c0856481..cbb48e9d 100644 --- a/src/actions/ModalActions.js +++ b/src/actions/ModalActions.js @@ -25,7 +25,19 @@ export const onPinSubmit = (value: string): Action => { }; }; -export const onPassphraseSubmit = (passphrase: string): AsyncAction => async (dispatch: Dispatch): Promise => { +export const onPassphraseSubmit = (passphrase: string): AsyncAction => async (dispatch: Dispatch, getState: GetState): Promise => { + const { modal } = getState(); + if (modal.context !== MODAL.CONTEXT_DEVICE) return; + + if (passphrase === '') { + // set standard wallet type if passphrase is blank + dispatch({ + type: CONNECT.UPDATE_WALLET_TYPE, + device: modal.device, + hidden: false, + }); + } + await TrezorConnect.uiResponse({ type: UI.RECEIVE_PASSPHRASE, payload: { @@ -106,15 +118,16 @@ export const onDeviceConnect = (device: Device): ThunkAction => (dispatch: Dispa } }; -export const onWalletTypeRequest = (device: TrezorDevice, hidden: boolean, state: ?string): ThunkAction => (dispatch: Dispatch): void => { +export const onWalletTypeRequest = (hidden: boolean): ThunkAction => (dispatch: Dispatch, getState: GetState): void => { + const { modal } = getState(); + if (modal.context !== MODAL.CONTEXT_DEVICE) return; dispatch({ type: MODAL.CLOSE, }); dispatch({ type: CONNECT.RECEIVE_WALLET_TYPE, - device, + device: modal.device, hidden, - state, }); }; @@ -129,7 +142,6 @@ export const gotoExternalWallet = (id: string, url: string): ThunkAction => (dis export default { onPinSubmit, onPassphraseSubmit, - // askForRemember, onRememberDevice, onForgetDevice, onForgetSingleDevice, diff --git a/src/actions/RouterActions.js b/src/actions/RouterActions.js index 18eae118..3cb7dea1 100644 --- a/src/actions/RouterActions.js +++ b/src/actions/RouterActions.js @@ -64,8 +64,8 @@ export const paramsValidation = (params: RouterLocationState): PayloadAction => url = `/device/${device.path}/bootloader`; } else if (device.mode === 'initialize') { url = `/device/${device.features.device_id}/initialize`; + } else if (device.mode === 'seedless') { + url = `/device/${device.features.device_id}/seedless`; } else if (device.firmware === 'required') { url = `/device/${device.features.device_id}/firmware-update`; } else if (typeof device.instance === 'number') { diff --git a/src/actions/TrezorConnectActions.js b/src/actions/TrezorConnectActions.js index cc51ffab..d90530fb 100644 --- a/src/actions/TrezorConnectActions.js +++ b/src/actions/TrezorConnectActions.js @@ -78,10 +78,9 @@ export type TrezorConnectAction = { type: typeof CONNECT.REQUEST_WALLET_TYPE, device: TrezorDevice } | { - type: typeof CONNECT.RECEIVE_WALLET_TYPE, + type: typeof CONNECT.RECEIVE_WALLET_TYPE | typeof CONNECT.UPDATE_WALLET_TYPE, device: TrezorDevice, hidden: boolean, - state: ?string, }; declare var LOCAL: ?string; diff --git a/src/actions/constants/TrezorConnect.js b/src/actions/constants/TrezorConnect.js index a502472f..53b27c4f 100644 --- a/src/actions/constants/TrezorConnect.js +++ b/src/actions/constants/TrezorConnect.js @@ -29,4 +29,5 @@ export const START_ACQUIRING: 'connect__start_acquiring' = 'connect__start_acqui export const STOP_ACQUIRING: 'connect__stop_acquiring' = 'connect__stop_acquiring'; export const REQUEST_WALLET_TYPE: 'connect__request_wallet_type' = 'connect__request_wallet_type'; -export const RECEIVE_WALLET_TYPE: 'connect__receive_wallet_type' = 'connect__receive_wallet_type'; \ No newline at end of file +export const RECEIVE_WALLET_TYPE: 'connect__receive_wallet_type' = 'connect__receive_wallet_type'; +export const UPDATE_WALLET_TYPE: 'connect__update_wallet_type' = 'connect__update_wallet_type'; \ No newline at end of file diff --git a/src/components/Log/index.js b/src/components/Log/index.js index bfeaaa01..823a58b0 100644 --- a/src/components/Log/index.js +++ b/src/components/Log/index.js @@ -5,6 +5,7 @@ import { bindActionCreators } from 'redux'; import { connect } from 'react-redux'; import colors from 'config/colors'; import { H2 } from 'components/Heading'; +import ReactJson from 'react-json-view'; import Icon from 'components/Icon'; import P from 'components/Paragraph'; @@ -44,22 +45,17 @@ const Click = styled.div` } `; -const Textarea = styled.textarea` - width: 100%; - height: 200px; - min-height: 200px; - resize: vertical; - font-size: 10px; - - &:focus { - box-shadow: none; - } -`; - const StyledParagraph = styled(P)` margin: 10px 0; `; +const LogWrapper = styled.div` + background: white; + padding: 25px; + height: 300px; + overflow: scroll; +`; + const Log = (props: Props): ?React$Element => { if (!props.log.opened) return null; return ( @@ -69,7 +65,9 @@ const Log = (props: Props): ?React$Element => {

Log

Attention: The log contains your XPUBs. Anyone with your XPUBs can see your account history. -