diff --git a/components/License.js b/components/License.js index c7cfbd5..9611f86 100644 --- a/components/License.js +++ b/components/License.js @@ -23,14 +23,16 @@ export default function License({ setLicense }) { return ( - - {t("settings.license.text", { currentYear })} + + + {t('settings.license.text', { currentYear })} + @@ -39,11 +41,11 @@ export default function License({ setLicense }) { } License.propTypes = { - setLicense: PropTypes.func.isRequired + setLicense: PropTypes.func.isRequired, } const styles = StyleSheet.create({ container: { - ...Containers.rowContainer - } + ...Containers.rowContainer, + }, }) diff --git a/components/chart/chart-legend.js b/components/chart/chart-legend.js index 9d6e8cc..76d8014 100644 --- a/components/chart/chart-legend.js +++ b/components/chart/chart-legend.js @@ -18,21 +18,21 @@ const ChartLegend = ({ height }) => { } ChartLegend.propTypes = { - height: PropTypes.number.isRequired + height: PropTypes.number.isRequired, } const styles = StyleSheet.create({ container: { alignItems: 'center', justifyContent: 'flex-end', - width: CHART_YAXIS_WIDTH + width: CHART_YAXIS_WIDTH, }, text: { ...Typography.label, }, textBold: { - ...Typography.labelBold - } + ...Typography.labelBold, + }, }) export default ChartLegend diff --git a/components/chart/horizontal-grid.js b/components/chart/horizontal-grid.js index 9550248..e28af3b 100644 --- a/components/chart/horizontal-grid.js +++ b/components/chart/horizontal-grid.js @@ -5,18 +5,19 @@ import { StyleSheet, View } from 'react-native' import { getTickPositions } from '../helpers/chart' import { Colors } from '../../styles' -import { CHART_GRID_LINE_HORIZONTAL_WIDTH, CHART_YAXIS_WIDTH } from '../../config' +import { + CHART_GRID_LINE_HORIZONTAL_WIDTH, + CHART_YAXIS_WIDTH, +} from '../../config' const HorizontalGrid = ({ height }) => { - return getTickPositions(height).map(tick => { - return ( - - ) + return getTickPositions(height).map((tick) => { + return }) } HorizontalGrid.propTypes = { - height: PropTypes.number + height: PropTypes.number, } const styles = StyleSheet.create({ @@ -25,9 +26,9 @@ const styles = StyleSheet.create({ borderBottomColor: Colors.grey, borderBottomWidth: CHART_GRID_LINE_HORIZONTAL_WIDTH, left: CHART_YAXIS_WIDTH, - position:'absolute', - right: 0 - } + position: 'absolute', + right: 0, + }, }) export default HorizontalGrid diff --git a/components/chart/symptom-cell.js b/components/chart/symptom-cell.js index ef8caa1..0f828f1 100644 --- a/components/chart/symptom-cell.js +++ b/components/chart/symptom-cell.js @@ -6,7 +6,7 @@ import { Colors, Containers } from '../../styles' import { CHART_COLUMN_WIDTH, CHART_DOT_RADIUS, - CHART_GRID_LINE_HORIZONTAL_WIDTH + CHART_GRID_LINE_HORIZONTAL_WIDTH, } from '../../config' const SymptomCell = ({ @@ -14,22 +14,22 @@ const SymptomCell = ({ index, symptom, symptomValue, - isSymptomDataComplete + isSymptomDataComplete, }) => { - const shouldDrawDot = symptomValue !== false - const styleCell = index !== 0 - ? [styles.cell, { height, width: CHART_COLUMN_WIDTH }] - : [styles.cell, { height, width: CHART_COLUMN_WIDTH }, styles.topBorder] + const styleCell = + index !== 0 + ? [styles.cell, { height, width: CHART_COLUMN_WIDTH }] + : [styles.cell, { height, width: CHART_COLUMN_WIDTH }, styles.topBorder] let styleDot if (shouldDrawDot) { const styleSymptom = Colors.iconColors[symptom] const symptomColor = styleSymptom.shades[symptomValue] - const isMucusOrCervix = (symptom === 'mucus') || (symptom === 'cervix') - const backgroundColor = (isMucusOrCervix && !isSymptomDataComplete) ? - 'white' : symptomColor - const borderWidth = (isMucusOrCervix && !isSymptomDataComplete) ? 2 : 0 + const isMucusOrCervix = symptom === 'mucus' || symptom === 'cervix' + const backgroundColor = + isMucusOrCervix && !isSymptomDataComplete ? 'white' : symptomColor + const borderWidth = isMucusOrCervix && !isSymptomDataComplete ? 2 : 0 const borderColor = symptomColor styleDot = [styles.dot, { backgroundColor, borderColor, borderWidth }] } @@ -45,10 +45,7 @@ SymptomCell.propTypes = { height: PropTypes.number, index: PropTypes.number.isRequired, symptom: PropTypes.string, - symptomValue: PropTypes.oneOfType([ - PropTypes.bool, - PropTypes.number, - ]), + symptomValue: PropTypes.oneOfType([PropTypes.bool, PropTypes.number]), isSymptomDataComplete: PropTypes.bool, } @@ -59,7 +56,7 @@ const styles = StyleSheet.create({ borderBottomWidth: CHART_GRID_LINE_HORIZONTAL_WIDTH, borderLeftColor: Colors.grey, borderLeftWidth: CHART_GRID_LINE_HORIZONTAL_WIDTH, - ...Containers.centerItems + ...Containers.centerItems, }, topBorder: { borderTopColor: Colors.grey, @@ -68,7 +65,7 @@ const styles = StyleSheet.create({ dot: { width: CHART_DOT_RADIUS * 2, height: CHART_DOT_RADIUS * 2, - borderRadius: 50 - } + borderRadius: 50, + }, }) export default SymptomCell diff --git a/components/chart/symptom-icon.js b/components/chart/symptom-icon.js index 1bd5c6c..fa36def 100644 --- a/components/chart/symptom-icon.js +++ b/components/chart/symptom-icon.js @@ -1,6 +1,6 @@ import React from 'react' import PropTypes from 'prop-types' -import { StyleSheet , View } from 'react-native' +import { StyleSheet, View } from 'react-native' import DripIcon from '../../assets/drip-icons' @@ -26,8 +26,8 @@ SymptomIcon.propTypes = { const styles = StyleSheet.create({ container: { - ...Containers.centerItems - } + ...Containers.centerItems, + }, }) export default SymptomIcon diff --git a/components/chart/tick-list.js b/components/chart/tick-list.js index 63af7da..a828ecb 100644 --- a/components/chart/tick-list.js +++ b/components/chart/tick-list.js @@ -7,24 +7,22 @@ import Tick from './tick' import { getTickList } from '../helpers/chart' const TickList = ({ height }) => { - return ( - { - getTickList(height) - .map(({ isBold, label, position, shouldShowLabel, tickHeight}) => { - return ( - - ) - }) - } + {getTickList(height).map( + ({ isBold, label, position, shouldShowLabel, tickHeight }) => { + return ( + + ) + } + )} ) } @@ -35,8 +33,8 @@ TickList.propTypes = { const styles = StyleSheet.create({ container: { - flex: 1 - } + flex: 1, + }, }) export default TickList diff --git a/components/chart/tick.js b/components/chart/tick.js index 7c0862b..92ca2b7 100644 --- a/components/chart/tick.js +++ b/components/chart/tick.js @@ -9,10 +9,10 @@ import { CHART_TICK_WIDTH } from '../../config' const Tick = ({ yPosition, height, isBold, shouldShowLabel, label }) => { const top = yPosition - height / 2 - const containerStyle = [ styles.container, { flexBasis: height, height, top }] + const containerStyle = [styles.container, { flexBasis: height, height, top }] const textStyle = isBold ? styles.textBold : styles.textNormal - return( + return ( {shouldShowLabel && label} @@ -27,7 +27,6 @@ Tick.propTypes = { label: PropTypes.string, } - const text = { textAlign: 'right', } @@ -36,17 +35,17 @@ const styles = StyleSheet.create({ justifyContent: 'center', position: 'absolute', right: 0, - width: CHART_TICK_WIDTH + width: CHART_TICK_WIDTH, }, textBold: { fontSize: Sizes.base, fontWeight: 'bold', - ...text + ...text, }, textNormal: { fontSize: Sizes.small, - ...text - } + ...text, + }, }) export default Tick diff --git a/components/chart/tutorial.js b/components/chart/tutorial.js index fefe287..553a4ef 100644 --- a/components/chart/tutorial.js +++ b/components/chart/tutorial.js @@ -13,7 +13,7 @@ const image = require('../../assets/swipe.png') const Tutorial = ({ onClose }) => { return ( - + {chart.tutorial} @@ -23,20 +23,20 @@ const Tutorial = ({ onClose }) => { } Tutorial.propTypes = { - onClose: PropTypes.func.isRequired + onClose: PropTypes.func.isRequired, } const styles = StyleSheet.create({ container: { ...Containers.rowContainer, - padding: Spacing.large + padding: Spacing.large, }, image: { - height: 40 + height: 40, }, textContainer: { - width: '70%' - } + width: '70%', + }, }) -export default Tutorial \ No newline at end of file +export default Tutorial diff --git a/components/chart/y-axis.js b/components/chart/y-axis.js index c9e13f2..c71f236 100644 --- a/components/chart/y-axis.js +++ b/components/chart/y-axis.js @@ -13,7 +13,7 @@ const YAxis = ({ symptomsToDisplay, symptomsSectionHeight, shouldShowTemperatureColumn, - xAxisHeight + xAxisHeight, }) => { const symptomIconHeight = symptomsSectionHeight / symptomsToDisplay.length @@ -21,15 +21,14 @@ const YAxis = ({ {shouldShowTemperatureColumn && } - - {symptomsToDisplay.map(symptom => ( + + {symptomsToDisplay.map((symptom) => ( - ) - )} + ))} ) @@ -40,13 +39,13 @@ YAxis.propTypes = { symptomsToDisplay: PropTypes.array, symptomsSectionHeight: PropTypes.number, shouldShowTemperatureColumn: PropTypes.bool, - xAxisHeight: PropTypes.number.isRequired + xAxisHeight: PropTypes.number.isRequired, } const styles = StyleSheet.create({ yAxis: { - width: CHART_YAXIS_WIDTH - } + width: CHART_YAXIS_WIDTH, + }, }) export default YAxis diff --git a/components/common/app-icon.js b/components/common/app-icon.js index 717c1e0..9cd6edf 100644 --- a/components/common/app-icon.js +++ b/components/common/app-icon.js @@ -14,17 +14,17 @@ const AppIcon = ({ color, name, style, ...props }) => { AppIcon.propTypes = { color: PropTypes.string, name: PropTypes.string.isRequired, - style: PropTypes.object + style: PropTypes.object, } AppIcon.defaultProps = { - color: 'black' + color: 'black', } const styles = StyleSheet.create({ icon: { - fontSize: Sizes.subtitle - } + fontSize: Sizes.subtitle, + }, }) -export default AppIcon \ No newline at end of file +export default AppIcon diff --git a/components/common/app-loading.js b/components/common/app-loading.js index 115d2dc..4d9ada1 100644 --- a/components/common/app-loading.js +++ b/components/common/app-loading.js @@ -17,8 +17,8 @@ const AppLoadingView = () => { const styles = StyleSheet.create({ container: { - ...Containers.centerItems - } + ...Containers.centerItems, + }, }) export default AppLoadingView diff --git a/components/common/app-modal.js b/components/common/app-modal.js index 0f28882..6b33fd9 100644 --- a/components/common/app-modal.js +++ b/components/common/app-modal.js @@ -3,9 +3,9 @@ import { Modal, StyleSheet, TouchableOpacity } from 'react-native' import PropTypes from 'prop-types' const AppModal = ({ children, onClose }) => { - return( + return ( { AppModal.propTypes = { children: PropTypes.node, - onClose: PropTypes.func + onClose: PropTypes.func, } const styles = StyleSheet.create({ @@ -26,7 +26,7 @@ const styles = StyleSheet.create({ backgroundColor: 'black', flex: 1, opacity: 0.5, - } + }, }) export default AppModal diff --git a/components/common/app-page.js b/components/common/app-page.js index 0ffde8d..74ced3a 100644 --- a/components/common/app-page.js +++ b/components/common/app-page.js @@ -13,7 +13,7 @@ const AppPage = ({ title, ...props }) => { - return( + return ( { AppSwitch.propTypes = { onToggle: PropTypes.func.isRequired, text: PropTypes.string, - value: PropTypes.bool + value: PropTypes.bool, } const styles = StyleSheet.create({ container: { - ...Containers.rowContainer + ...Containers.rowContainer, }, switch: { flex: 1, }, textContainer: { flex: 4, - } + }, }) -export default AppSwitch \ No newline at end of file +export default AppSwitch diff --git a/components/common/app-text-input.js b/components/common/app-text-input.js index 03a3f70..fef29d5 100644 --- a/components/common/app-text-input.js +++ b/components/common/app-text-input.js @@ -5,7 +5,7 @@ import PropTypes from 'prop-types' import { Colors, Spacing, Typography } from '../../styles' const AppTextInput = ({ style, isKeyboardOffset, ...props }) => { - const behavior = isKeyboardOffset ? "padding" : "height" + const behavior = isKeyboardOffset ? 'padding' : 'height' const keyboardVerticalOffset = isKeyboardOffset ? 300 : 0 return ( @@ -39,8 +39,8 @@ const styles = StyleSheet.create({ minWidth: '80%', paddingHorizontal: Spacing.base, paddingVertical: Spacing.tiny, - ...Typography.mainText - } + ...Typography.mainText, + }, }) export default AppTextInput diff --git a/components/common/app-text.js b/components/common/app-text.js index 5d696f3..7501f1a 100644 --- a/components/common/app-text.js +++ b/components/common/app-text.js @@ -26,8 +26,8 @@ AppText.propTypes = { const styles = StyleSheet.create({ text: { color: Colors.greyDark, - ...Typography.mainText - } + ...Typography.mainText, + }, }) -export default AppText \ No newline at end of file +export default AppText diff --git a/components/common/close-icon.js b/components/common/close-icon.js index c5aff26..d92e6a1 100644 --- a/components/common/close-icon.js +++ b/components/common/close-icon.js @@ -4,7 +4,7 @@ import { StyleSheet, TouchableOpacity } from 'react-native' import AppIcon from './app-icon' -import { HIT_SLOP} from '../../config' +import { HIT_SLOP } from '../../config' import { Colors, Sizes } from '../../styles' const CloseIcon = ({ onClose, color, ...props }) => { @@ -15,21 +15,21 @@ const CloseIcon = ({ onClose, color, ...props }) => { style={styles.container} {...props} > - + ) } CloseIcon.propTypes = { onClose: PropTypes.func.isRequired, - color: PropTypes.string + color: PropTypes.string, } const styles = StyleSheet.create({ container: { alignSelf: 'flex-start', marginBottom: Sizes.base, - } + }, }) export default CloseIcon diff --git a/components/common/link.js b/components/common/link.js index aec7bfc..e624c27 100644 --- a/components/common/link.js +++ b/components/common/link.js @@ -21,7 +21,7 @@ const Link = ({ children, style }) => { Link.propTypes = { children: PropTypes.node, - style: PropTypes.object + style: PropTypes.object, } const styles = StyleSheet.create({ @@ -29,12 +29,12 @@ const styles = StyleSheet.create({ color: Colors.purple, textDecorationLine: 'underline', ...Typography.mainText, - } + }, }) function replaceUrlWithText(url) { - const link = Object.values(links).find(l => l.url === url) + const link = Object.values(links).find((l) => l.url === url) return (link && link.text) || url } -export default Link \ No newline at end of file +export default Link diff --git a/components/common/menu-icon.js b/components/common/menu-icon.js index 8ef9b9a..8954ce7 100644 --- a/components/common/menu-icon.js +++ b/components/common/menu-icon.js @@ -15,7 +15,7 @@ const MenuIcon = ({ isActive, name }) => { MenuIcon.propTypes = { isActive: PropTypes.bool, - name: PropTypes.string.isRequired + name: PropTypes.string.isRequired, } -export default MenuIcon \ No newline at end of file +export default MenuIcon diff --git a/components/common/segment.js b/components/common/segment.js index af96dcf..d17f1b7 100644 --- a/components/common/segment.js +++ b/components/common/segment.js @@ -43,7 +43,7 @@ const styles = StyleSheet.create({ }, title: { ...Typography.subtitle, - } + }, }) -export default Segment \ No newline at end of file +export default Segment diff --git a/components/common/table.js b/components/common/table.js index 65d3a10..5066c64 100644 --- a/components/common/table.js +++ b/components/common/table.js @@ -7,17 +7,17 @@ import AppText from './app-text' import { Sizes, Spacing, Typography } from '../../styles' const Table = ({ tableContent }) => { - return ( - tableContent.map((rowContent, i) => ) - ) + return tableContent.map((rowContent, i) => ( + + )) } Table.propTypes = { - tableContent: PropTypes.array.isRequired + tableContent: PropTypes.array.isRequired, } const Row = ({ rowContent }) => { - return( + return ( @@ -26,7 +26,7 @@ const Row = ({ rowContent }) => { } Row.propTypes = { - rowContent: PropTypes.array.isRequired + rowContent: PropTypes.array.isRequired, } const Cell = ({ content, isLeft }) => { @@ -35,7 +35,7 @@ const Cell = ({ content, isLeft }) => { const numberOfLines = isLeft ? 1 : 2 const ellipsizeMode = isLeft ? 'clip' : 'tail' - return( + return ( { return ( - {Object.keys(labels).map(key => { + {Object.keys(labels).map((key) => { const isActive = optionsState[key] const boxStyle = [styles.box, isActive && styles.boxActive] const textStyle = [styles.text, isActive && styles.textActive] @@ -31,25 +31,25 @@ const SelectBoxGroup = ({ labels, optionsState, onSelect }) => { SelectBoxGroup.propTypes = { labels: PropTypes.object.isRequired, onSelect: PropTypes.func.isRequired, - optionsState: PropTypes.object.isRequired + optionsState: PropTypes.object.isRequired, } const styles = StyleSheet.create({ box: { - ...Containers.box + ...Containers.box, }, boxActive: { - ...Containers.boxActive + ...Containers.boxActive, }, container: { - ...Containers.selectGroupContainer + ...Containers.selectGroupContainer, }, text: { - color: Colors.orange + color: Colors.orange, }, textActive: { - color: 'white' - } + color: 'white', + }, }) export default SelectBoxGroup diff --git a/components/cycle-day/select-tab-group.js b/components/cycle-day/select-tab-group.js index 29c2e2f..b298cbd 100644 --- a/components/cycle-day/select-tab-group.js +++ b/components/cycle-day/select-tab-group.js @@ -9,23 +9,21 @@ import { Colors, Containers } from '../../styles' export default function SelectTabGroup({ activeButton, buttons, onSelect }) { return ( - { - buttons.map(({ label, value }, i) => { - const isActive = value === activeButton - const boxStyle = [styles.box, isActive && styles.boxActive] - const textStyle = [styles.text, isActive && styles.textActive] + {buttons.map(({ label, value }, i) => { + const isActive = value === activeButton + const boxStyle = [styles.box, isActive && styles.boxActive] + const textStyle = [styles.text, isActive && styles.textActive] - return ( - onSelect(value)} - key={i} - style={boxStyle} - > - {label} - - ) - }) - } + return ( + onSelect(value)} + key={i} + style={boxStyle} + > + {label} + + ) + })} ) } @@ -33,23 +31,23 @@ export default function SelectTabGroup({ activeButton, buttons, onSelect }) { SelectTabGroup.propTypes = { activeButton: PropTypes.number, buttons: PropTypes.array.isRequired, - onSelect: PropTypes.func.isRequired + onSelect: PropTypes.func.isRequired, } const styles = StyleSheet.create({ box: { - ...Containers.box + ...Containers.box, }, boxActive: { - ...Containers.boxActive + ...Containers.boxActive, }, container: { - ...Containers.selectGroupContainer + ...Containers.selectGroupContainer, }, text: { - color: Colors.orange + color: Colors.orange, }, textActive: { - color: 'white' - } -}) \ No newline at end of file + color: 'white', + }, +}) diff --git a/components/header/index.js b/components/header/index.js index 1184506..a19f9cc 100644 --- a/components/header/index.js +++ b/components/header/index.js @@ -8,29 +8,28 @@ import HamburgerMenu from './hamburger-menu' import { Colors, Containers, Sizes } from '../../styles' const Header = ({ isSideMenuEnabled }) => { - return ( {isSideMenuEnabled && } - + ) } Header.propTypes = { - isSideMenuEnabled: PropTypes.bool + isSideMenuEnabled: PropTypes.bool, } Header.defaultProps = { - isSideMenuEnabled: true + isSideMenuEnabled: true, } const styles = StyleSheet.create({ header: { backgroundColor: Colors.purple, padding: Sizes.base, - ...Containers.rowContainer - } + ...Containers.rowContainer, + }, }) -export default Header \ No newline at end of file +export default Header diff --git a/components/helpers/general.js b/components/helpers/general.js index 9ce055a..90fc16b 100644 --- a/components/helpers/general.js +++ b/components/helpers/general.js @@ -1,5 +1,7 @@ import Toast from 'react-native-simple-toast' -export const showToast = (text) => Toast.show( - text, Toast.SHORT, ['RCTModalHostViewController', 'UIAlertController'] -) +export const showToast = (text) => + Toast.show(text, Toast.SHORT, [ + 'RCTModalHostViewController', + 'UIAlertController', + ]) diff --git a/components/helpers/labels.js b/components/helpers/labels.js index 192914a..7e4a0df 100644 --- a/components/helpers/labels.js +++ b/components/helpers/labels.js @@ -1,2 +1,2 @@ -export const getLabelsList = - (categories) => categories.map((label, i) => ({ label, value: i })) \ No newline at end of file +export const getLabelsList = (categories) => + categories.map((label, i) => ({ label, value: i })) diff --git a/components/helpers/pad-time-with-zeros.js b/components/helpers/pad-time-with-zeros.js index 8008de6..e2c5ef3 100644 --- a/components/helpers/pad-time-with-zeros.js +++ b/components/helpers/pad-time-with-zeros.js @@ -1,10 +1,11 @@ - export default function (jsDate) { const vals = [jsDate.getHours(), jsDate.getMinutes()] - return vals.map(val => { - if (parseInt(val) < 10) { - val = `0${val}` - } - return val - }).join(':') -} \ No newline at end of file + return vals + .map((val) => { + if (parseInt(val) < 10) { + val = `0${val}` + } + return val + }) + .join(':') +} diff --git a/components/menu/index.js b/components/menu/index.js index 2d329d0..00b607e 100644 --- a/components/menu/index.js +++ b/components/menu/index.js @@ -7,11 +7,11 @@ import { Containers } from '../../styles' import { pages } from '../pages' const Menu = () => { - const menuItems = pages.filter(page => page.isInMenu) + const menuItems = pages.filter((page) => page.isInMenu) return ( - { menuItems.map(({ icon, label, component }) => { + {menuItems.map(({ icon, label, component }) => { return ( { key={label} label={label} /> - )} - )} - + ) + })} + ) } const styles = StyleSheet.create({ container: { backgroundColor: 'white', - ...Containers.rowContainer - } + ...Containers.rowContainer, + }, }) -export default Menu \ No newline at end of file +export default Menu diff --git a/components/settings/common/alert-error.js b/components/settings/common/alert-error.js index 6d08d91..ce8e51e 100644 --- a/components/settings/common/alert-error.js +++ b/components/settings/common/alert-error.js @@ -3,4 +3,4 @@ import { shared as sharedLabels } from '../../../i18n/en/labels' export default function alertError(msg) { Alert.alert(sharedLabels.errorTitle, msg) -} \ No newline at end of file +} diff --git a/components/settings/common/password-field.js b/components/settings/common/password-field.js index d22fdd1..0429342 100644 --- a/components/settings/common/password-field.js +++ b/components/settings/common/password-field.js @@ -6,11 +6,7 @@ import styles from '../../../styles' export default function PasswordField(props) { return ( - + ) } @@ -18,5 +14,5 @@ PasswordField.propTypes = { placeholder: PropTypes.string, value: PropTypes.string, onChangeText: PropTypes.func, - autoFocus: PropTypes.bool + autoFocus: PropTypes.bool, } diff --git a/components/settings/common/settings-button.js b/components/settings/common/settings-button.js index 93af5f2..941c088 100644 --- a/components/settings/common/settings-button.js +++ b/components/settings/common/settings-button.js @@ -12,15 +12,17 @@ const SettingsButton = ({ children, style, secondary, ...props }) => { styles.settingsButton, secondary ? null : styles.settingsButtonAccent, props.disabled ? styles.settingsButtonDisabled : null, - style + style, ]} - { ...props } + {...props} > - + {children} @@ -32,7 +34,7 @@ SettingsButton.propTypes = { disabled: PropTypes.bool, onPress: PropTypes.func.isRequired, secondary: PropTypes.bool, - style: PropTypes.object + style: PropTypes.object, } -export default SettingsButton \ No newline at end of file +export default SettingsButton diff --git a/components/settings/data-management/constants.js b/components/settings/data-management/constants.js index 45956ed..0f86dbe 100644 --- a/components/settings/data-management/constants.js +++ b/components/settings/data-management/constants.js @@ -1 +1 @@ -export const EXPORT_FILE_NAME = 'drip-data.csv' \ No newline at end of file +export const EXPORT_FILE_NAME = 'drip-data.csv' diff --git a/components/settings/license.js b/components/settings/license.js index f3ead7f..c01b5f9 100644 --- a/components/settings/license.js +++ b/components/settings/license.js @@ -10,9 +10,9 @@ const License = () => { const currentYear = new Date().getFullYear() return ( - + - {t("settings.license.text", { currentYear })} + {t('settings.license.text', { currentYear })} ) diff --git a/components/settings/nfp-settings/slider-label.js b/components/settings/nfp-settings/slider-label.js index 4fbda08..7da99d0 100644 --- a/components/settings/nfp-settings/slider-label.js +++ b/components/settings/nfp-settings/slider-label.js @@ -17,14 +17,14 @@ const SliderLabel = ({ oneMarkerValue, twoMarkerValue, oneMarkerLeftPosition, - twoMarkerLeftPosition + twoMarkerLeftPosition, }) => { const minCoordinate = getMarkerCoordinate(oneMarkerLeftPosition) const maxCoordinate = getMarkerCoordinate(twoMarkerLeftPosition) - const isMinNumber = Number.isFinite(oneMarkerLeftPosition) && - Number.isFinite(oneMarkerValue) - const isMaxNumber = Number.isFinite(twoMarkerLeftPosition) && - Number.isFinite(twoMarkerValue) + const isMinNumber = + Number.isFinite(oneMarkerLeftPosition) && Number.isFinite(oneMarkerValue) + const isMaxNumber = + Number.isFinite(twoMarkerLeftPosition) && Number.isFinite(twoMarkerValue) const minStyle = [styles.label, { left: minCoordinate }] const maxStyle = [styles.label, { left: maxCoordinate }] @@ -40,15 +40,15 @@ SliderLabel.propTypes = { oneMarkerValue: PropTypes.oneOfType([PropTypes.string, PropTypes.number]), twoMarkerValue: PropTypes.oneOfType([PropTypes.string, PropTypes.number]), oneMarkerLeftPosition: PropTypes.number, - twoMarkerLeftPosition: PropTypes.number + twoMarkerLeftPosition: PropTypes.number, } const styles = StyleSheet.create({ label: { fontFamily: Fonts.bold, position: 'absolute', - marginTop: (-1) * Sizes.base - } + marginTop: -1 * Sizes.base, + }, }) -export default SliderLabel \ No newline at end of file +export default SliderLabel diff --git a/components/settings/settings-menu.js b/components/settings/settings-menu.js index 4436c15..7ff4155 100644 --- a/components/settings/settings-menu.js +++ b/components/settings/settings-menu.js @@ -7,23 +7,22 @@ import settingsLabels from '../../i18n/en/settings' const { menuItems } = settingsLabels const menu = [ - { ...menuItems.reminders, component: 'Reminders'}, - { ...menuItems.nfpSettings, component: 'NfpSettings'}, - { ...menuItems.dataManagement, component: 'DataManagement'}, - { ...menuItems.password, component: 'Password'} + { ...menuItems.reminders, component: 'Reminders' }, + { ...menuItems.nfpSettings, component: 'NfpSettings' }, + { ...menuItems.dataManagement, component: 'DataManagement' }, + { ...menuItems.password, component: 'Password' }, ] const SettingsMenu = () => { return ( {menu.map((menuItem, i) => { - const last = (menu.length === i + 1) + const last = menu.length === i + 1 - return - } - )} + return + })} ) } -export default SettingsMenu \ No newline at end of file +export default SettingsMenu