summaryrefslogtreecommitdiffhomepage
path: root/app
diff options
context:
space:
mode:
authoranderklander <anderklander@gmail.com>2018-02-14 20:47:18 +0100
committeranderklander <anderklander@gmail.com>2018-02-15 16:02:02 +0100
commit21c5d2fdfef9f49203f90b4f3b8451132e0773bc (patch)
treed329d841255ed7a2fca62dfe515e0b1f5b1cbebf /app
parentb5b64ecccd6e9ddb727f8ded678b355239dffce2 (diff)
downloadmullvadvpn-21c5d2fdfef9f49203f90b4f3b8451132e0773bc.tar.xz
mullvadvpn-21c5d2fdfef9f49203f90b4f3b8451132e0773bc.zip
Small naming/style/lint fix
Diffstat (limited to 'app')
-rw-r--r--app/components/Settings.js2
-rw-r--r--app/components/styled/AppButton.js18
2 files changed, 10 insertions, 10 deletions
diff --git a/app/components/Settings.js b/app/components/Settings.js
index 17853fe423..a55b3c085f 100644
--- a/app/components/Settings.js
+++ b/app/components/Settings.js
@@ -2,7 +2,7 @@
import moment from 'moment';
import React from 'react';
import { Component, Text, View } from 'reactxp';
-import { Button, CellButton, RedButton, Label, Icon } from './styled';
+import { Button, CellButton, RedButton, Label } from './styled';
import { Layout, Container } from './Layout';
import CustomScrollbars from './CustomScrollbars';
import styles from './SettingsStyles';
diff --git a/app/components/styled/AppButton.js b/app/components/styled/AppButton.js
index d094c6c28b..4d69075042 100644
--- a/app/components/styled/AppButton.js
+++ b/app/components/styled/AppButton.js
@@ -1,6 +1,6 @@
// @flow
import React from 'react';
-import { View, Text, Component } from 'reactxp';
+import { Text, Component } from 'reactxp';
import { Button } from './Button';
import Img from '../Img';
import { colors } from '../../config';
@@ -89,12 +89,12 @@ export class Icon extends Component {
const width = this.props.width || 7;
const height = this.props.height || 12;
const source = this.props.source || 'icon-chevron';
- const color = this.props.color || styles.white;
return (
- <Img style={[ styles.icon, {
- width,
- height,
- }, color]}
+ <Img style={[ styles.icon,
+ {width,
+ height},
+ styles.white,
+ this.props.style]}
source={source}
tintColor='currentColor'/>);
}
@@ -127,16 +127,16 @@ export default class BaseButton extends Component {
let updatedProps = {};
if(node.type.name === 'Label') {
- updatedProps = { color: this.textColor() };
+ updatedProps = { style: this.textColor() };
}
if(node.type.name === 'Icon') {
- updatedProps = { color: this.iconTintColor() };
+ updatedProps = { style: this.iconTintColor() };
}
return React.cloneElement(node, updatedProps);
} else {
- return <Label>{children}</Label>;
+ return <Label style={this.textColor()}>{children}</Label>;
}
})
}