diff --git a/BlueComponents.js b/BlueComponents.js index 9f1ae59f..777d4743 100644 --- a/BlueComponents.js +++ b/BlueComponents.js @@ -45,11 +45,11 @@ if (aspectRatio > 1.6) { export class BlueButton extends Component { render() { - let backgroundColor = this.props.backgroundColor ? this.props.backgroundColor : '#ccddf9'; - let fontColor = '#0c2550'; + let backgroundColor = this.props.backgroundColor ? this.props.backgroundColor : BlueApp.settings.buttonBackgroundColor; + let fontColor = BlueApp.settings.buttonTextColor; if (this.props.hasOwnProperty('disabled') && this.props.disabled === true) { - backgroundColor = '#eef0f4'; - fontColor = '#9aa0aa'; + backgroundColor = BlueApp.settings.buttonDisabledBackgroundColor; + fontColor = BlueApp.settings.buttonDisabledTextColor; } let buttonWidth = width / 1.5; if (this.props.hasOwnProperty('noMinWidth')) { @@ -93,10 +93,10 @@ export class BitcoinButton extends Component { - - + + {loc.wallets.add.bitcoin} @@ -127,10 +127,10 @@ export class LightningButton extends Component { - - + + {loc.wallets.add.lightning} @@ -161,7 +161,7 @@ export class BlueButtonLink extends Component { }} {...this.props} > - {this.props.title} + {this.props.title} ); } @@ -169,15 +169,15 @@ export class BlueButtonLink extends Component { export const BlueNavigationStyle = (navigation, withNavigationCloseButton = false, customCloseButtonFunction = undefined) => ({ headerStyle: { - backgroundColor: '#FFFFFF', + backgroundColor: BlueApp.settings.brandingColor, borderBottomWidth: 0, elevation: 0, }, headerTitleStyle: { fontWeight: '600', - color: '#0c2550', + color: BlueApp.settings.foregroundColor, }, - headerTintColor: '#0c2550', + headerTintColor: BlueApp.settings.foregroundColor, headerRight: withNavigationCloseButton ? ( @@ -331,11 +331,11 @@ export class BlueFormInput extends Component { inputStyle={{ color: BlueApp.settings.foregroundColor, maxWidth: width - 105 }} containerStyle={{ marginTop: 5, - borderColor: '#d2d2d2', - borderBottomColor: '#d2d2d2', + borderColor: BlueApp.settings.inputBorderColor, + borderBottomColor: BlueApp.settings.inputBorderColor, borderWidth: 0.5, borderBottomWidth: 0.5, - backgroundColor: '#f5f5f5', + backgroundColor: BlueApp.settings.inputBackgroundColor, }} /> ); @@ -363,11 +363,11 @@ export class BlueFormMultiInput extends Component { style={{ marginTop: 5, marginHorizontal: 20, - borderColor: '#d2d2d2', - borderBottomColor: '#d2d2d2', + borderColor: BlueApp.settings.inputBorderColor, + borderBottomColor: BlueApp.settings.inputBorderColor, borderWidth: 0.5, borderBottomWidth: 0.5, - backgroundColor: '#f5f5f5', + backgroundColor: BlueApp.settings.inputBackgroundColor, height: 200, color: BlueApp.settings.foregroundColor, }} @@ -396,11 +396,11 @@ export class BlueFormInputAddress extends Component { }} containerStyle={{ marginTop: 5, - borderColor: '#d2d2d2', - borderBottomColor: '#d2d2d2', + borderColor: BlueApp.settings.inputBorderColor, + borderBottomColor: BlueApp.settings.inputBorderColor, borderWidth: 0.5, borderBottomWidth: 0.5, - backgroundColor: '#f5f5f5', + backgroundColor: BlueApp.settings.inputBackgroundColor, }} /> ); @@ -426,9 +426,9 @@ export class BlueHeader extends Component { export class BlueHeaderDefaultSub extends Component { render() { return ( - +
+
- + Total: {this.props.wallet.getBalance()} {BitcoinUnit.BTC} @@ -725,7 +725,7 @@ export class BlueTransactionIncomingIcon extends Component { - + @@ -760,7 +760,7 @@ export class BlueTransactionExpiredIcon extends Component { - + @@ -779,7 +779,7 @@ export class BlueTransactionOnchainIcon extends Component { name="link" size={16} type="font-awesome" - color="#37c0a1" + color={BlueApp.settings.incomingForegroundColor} iconStyle={{ left: 0, top: 7, transform: [{ rotate: '-45deg' }] }} /> @@ -795,7 +795,7 @@ export class BlueTransactionOffchainIcon extends Component { - + @@ -809,7 +809,7 @@ export class BlueTransactionOffchainIncomingIcon extends Component { - + @@ -823,7 +823,7 @@ export class BlueTransactionOutgoingIcon extends Component { - + @@ -841,7 +841,7 @@ export class BlueReceiveButtonIcon extends Component { style={{ flex: 1, minWidth: 130, - backgroundColor: '#ccddf9', + backgroundColor: BlueApp.settings.buttonBackgroundColor, }} > @@ -856,11 +856,11 @@ export class BlueReceiveButtonIcon extends Component { marginBottom: -11, }} > - + @@ -899,11 +899,11 @@ export class BlueSendButtonIcon extends Component { marginBottom: 11, }} > - + @@ -939,11 +939,11 @@ export class ManageFundsBigButton extends Component { transform: [{ rotate: '90deg' }], }} > - + {loc.wallets.list.create_a_wallet} @@ -1027,7 +1027,7 @@ export class NewWalletPanel extends Component { style={{ backgroundColor: 'transparent', fontSize: 13, - color: '#9aa0aa', + color: BlueApp.settings.alternativeTextColor, }} > {loc.wallets.list.create_a_wallet1} @@ -1036,7 +1036,7 @@ export class NewWalletPanel extends Component { style={{ backgroundColor: 'transparent', fontSize: 13, - color: '#9aa0aa', + color: BlueApp.settings.alternativeTextColor, }} > {loc.wallets.list.create_a_wallet2} @@ -1090,7 +1090,7 @@ export class BlueTransactionListItem extends Component { rowTitleStyle = () => { const item = this.props.item; - let color = '#37c0a1'; + let color = BlueApp.settings.successColor; if (item.type === 'user_invoice' || item.type === 'payment_request') { const currentDate = new Date(); @@ -1098,12 +1098,12 @@ export class BlueTransactionListItem extends Component { const invoiceExpiration = item.timestamp + item.expire_time; if (invoiceExpiration > now) { - color = '#37c0a1'; + color = BlueApp.settings.successColor; } else if (invoiceExpiration < now) { if (item.ispaid) { - color = '#37c0a1'; + color = BlueApp.settings.successColor; } else { - color = '#FF0000'; + color = BlueApp.settings.failedColor; } } } else if (item.value / 100000000 < 0) { @@ -1486,7 +1486,7 @@ export class WalletsCarousel extends Component { }} > {item.getLabel()} @@ -1524,7 +1524,7 @@ export class WalletsCarousel extends Component { backgroundColor: 'transparent', fontWeight: 'bold', fontSize: 36, - color: '#fff', + color: BlueApp.settings.inverseForegroundColor, }} > {loc.formatBalance(Number(item.getBalance()), item.getPreferredBalanceUnit(), true)} @@ -1535,7 +1535,7 @@ export class WalletsCarousel extends Component { style={{ backgroundColor: 'transparent', fontSize: 13, - color: '#fff', + color: BlueApp.settings.inverseForegroundColor, }} > {loc.wallets.list.latest_transaction} @@ -1546,7 +1546,7 @@ export class WalletsCarousel extends Component { backgroundColor: 'transparent', fontWeight: 'bold', fontSize: 16, - color: '#fff', + color: BlueApp.settings.inverseForegroundColor, }} > {loc.transactionTimeToReadable(item.getLatestTransactionTime())} @@ -1602,11 +1602,11 @@ export class BlueAddressInput extends Component { - - {loc.send.details.scan} + + {loc.send.details.scan} ); @@ -1712,16 +1712,16 @@ export class BlueBitcoinAmount extends Component { ref={textInput => (this.textInput = textInput)} editable={!this.props.isLoading && !this.props.disabled} value={amount} - placeholderTextColor={this.props.disabled ? '#99a0ab' : '#0f5cc0'} + placeholderTextColor={this.props.disabled ? BlueApp.settings.buttonDisabledTextColor : BlueApp.settings.alternativeTextColor2} style={{ - color: this.props.disabled ? '#99a0ab' : '#0f5cc0', + color: this.props.disabled ? BlueApp.settings.buttonDisabledTextColor : BlueApp.settings.alternativeTextColor2, fontSize: 36, fontWeight: '600', }} />