diff --git a/app/extensions/brave/locales/en-US/preferences.properties b/app/extensions/brave/locales/en-US/preferences.properties index 4b9ba6e8743..5e504fdec30 100644 --- a/app/extensions/brave/locales/en-US/preferences.properties +++ b/app/extensions/brave/locales/en-US/preferences.properties @@ -90,7 +90,7 @@ contributionStatements=Contribution statements contributionTime=Contribution Time copied=Copied! copy=Copy -copyToClipboard=Copy to clipboard +copyToClipboard.title=Copy to clipboard createdWalletStatus=Your wallet is ready! createWallet=create wallet createWalletStatus=Click the Create Wallet button to get started. diff --git a/app/renderer/components/common/clipboardButton.js b/app/renderer/components/common/clipboardButton.js index 0729e9d1f17..baa2796d291 100644 --- a/app/renderer/components/common/clipboardButton.js +++ b/app/renderer/components/common/clipboardButton.js @@ -3,7 +3,10 @@ * You can obtain one at http://mozilla.org/MPL/2.0/. */ const React = require('react') -const {StyleSheet, css} = require('aphrodite') +const {StyleSheet, css} = require('aphrodite/no-important') +const globalStyles = require('../styles/global') + +const BrowserButton = require('./browserButton') /** * Represents a 'Copy to clipboard' button @@ -35,21 +38,24 @@ class ClipboardButton extends React.Component { render () { return - - { - this.props.textContext - ? this.props.textContext - : '' - } - + styles.clipboardButton__label, + this.state.visibleLabel && styles.clipboardButton__label_visible, + (this.props.bottomTooltip || this.props.topTooltip) && styles.clipboardButton__label_vertical, + (this.props.bottomTooltip && !this.props.topTooltip) && styles.clipboardButton__label_bottom, + + // Applied on add funds panel + (!this.props.bottomTooltip && this.props.topTooltip) && styles.clipboardButton__label_top + )} + onAnimationEnd={this.onAnimationEnd} + data-l10n-id='copied' + /> + } } @@ -73,32 +79,37 @@ const styles = StyleSheet.create({ position: 'relative', cursor: 'pointer' }, - doneLabel: { - marginRight: '15px', - opacity: 0, - display: 'none' - }, - doneLabelBottom: { - position: 'absolute', - top: '35px', - right: '30px', - width: '-webkit-fill-available', - opacity: 0, - display: 'none' + + clipboardButton__browserButton: { + fontSize: '1rem' }, - doneLabelTop: { - position: 'absolute', - bottom: '35px', - right: '30px', + + clipboardButton__label: { width: '-webkit-fill-available', - opacity: 0, - display: 'none' + marginRight: '1ch', + display: 'none', + willChange: 'opacity', + opacity: 0 }, - visible: { + + clipboardButton__label_visible: { display: 'inline', animationName: animation, animationDuration: '2s', animationTimingFunction: 'cubic-bezier(0.23, 1, 0.32, 1)' + }, + + clipboardButton__label_vertical: { + position: 'absolute', + right: '30px' + }, + + clipboardButton__label_bottom: { + top: '35px' + }, + + clipboardButton__label_top: { + bottom: '35px' } }) diff --git a/app/renderer/components/preferences/payment/addFundsDialog/steps/addFundsWizardAddress.js b/app/renderer/components/preferences/payment/addFundsDialog/steps/addFundsWizardAddress.js index 5a6b9065d0a..27c42e6ae39 100644 --- a/app/renderer/components/preferences/payment/addFundsDialog/steps/addFundsWizardAddress.js +++ b/app/renderer/components/preferences/payment/addFundsDialog/steps/addFundsWizardAddress.js @@ -13,7 +13,6 @@ const ClipboardButton = require('../../../../common/clipboardButton') const appActions = require('../../../../../../../js/actions/appActions') // Styles -const globalStyles = require('../../../../styles/global') const {addFundsDialogMinHeight} = require('../../../../styles/global').spacing const ethIcon = require('../../../../../../extensions/brave/img/ledger/cryptoIcons/ETH_icon.svg') const btcIcon = require('../../../../../../extensions/brave/img/ledger/cryptoIcons/BTC_icon.svg') @@ -48,7 +47,6 @@ class AddFundsWizardAddress extends React.Component { return ( ) diff --git a/js/about/brave.js b/js/about/brave.js index af09050f711..8de0a2a32fc 100644 --- a/js/about/brave.js +++ b/js/about/brave.js @@ -71,11 +71,7 @@ class AboutBrave extends React.Component {
- +