diff options
| author | Erik Larkö <erik@mullvad.net> | 2017-11-27 11:14:01 +0100 |
|---|---|---|
| committer | Erik Larkö <erik@mullvad.net> | 2017-12-14 09:16:50 +0100 |
| commit | 7dd023cb17746b217c8e5f1b78525bd5ec322be9 (patch) | |
| tree | 85ca726d8be704c86f56f4e22fd9e4d972e9a2db /app | |
| parent | cc05ad18e7362cf5f8976a26ebf03105d1de0df4 (diff) | |
| download | mullvadvpn-7dd023cb17746b217c8e5f1b78525bd5ec322be9.tar.xz mullvadvpn-7dd023cb17746b217c8e5f1b78525bd5ec322be9.zip | |
Rebase fixes
Diffstat (limited to 'app')
| -rw-r--r-- | app/app.js | 20 | ||||
| -rw-r--r-- | app/components/HeaderBar.js | 5 | ||||
| -rw-r--r-- | app/components/HeaderBarStyles.js | 6 | ||||
| -rw-r--r-- | app/components/Img.js | 2 | ||||
| -rw-r--r-- | app/lib/backend.js | 1 | ||||
| -rw-r--r-- | app/lib/platform.android.js | 4 | ||||
| -rw-r--r-- | app/lib/platform.js | 5 |
7 files changed, 11 insertions, 32 deletions
diff --git a/app/app.js b/app/app.js index a5392a49c3..e84a577223 100644 --- a/app/app.js +++ b/app/app.js @@ -1,7 +1,6 @@ // @flow import React from 'react'; -import ReactDOM from 'react-dom'; import { Component} from 'reactxp'; import { Provider } from 'react-redux'; import { ConnectedRouter } from 'react-router-redux'; @@ -85,25 +84,6 @@ webFrame.setZoomLevelLimits(1, 1); ipcRenderer.send('on-browser-window-ready'); -function getRootElement() { - const currentScript = document.currentScript; - if (!currentScript) { - throw new Error('Missing document.currentScript'); - } - - const containerId = currentScript.getAttribute('data-container'); - if(!containerId) { - throw new Error('Missing data-container attribute.'); - } - - const rootElement = document.querySelector(containerId); - if(!rootElement) { - throw new Error('Missing root element.'); - } - - return rootElement; -} - export default class App extends Component{ render() { diff --git a/app/components/HeaderBar.js b/app/components/HeaderBar.js index 254c4e56c0..d22771420b 100644 --- a/app/components/HeaderBar.js +++ b/app/components/HeaderBar.js @@ -4,7 +4,6 @@ import { Component, Text, Button, - Image, View } from 'reactxp'; @@ -47,7 +46,7 @@ export default class HeaderBar extends Component { <Img style={ styles.headerbar__logo } source='logo-icon'/> <Text style={styles.headerbar__title}>MULLVAD VPN</Text> </View> - : null} + : null} {this.props.showSettings ? <View style={styles.headerbar__settings}> @@ -55,7 +54,7 @@ export default class HeaderBar extends Component { <Img style={ styles.headerbar__settings } source='icon-settings'/> </Button> </View> - : null} + : null} </View> ); } diff --git a/app/components/HeaderBarStyles.js b/app/components/HeaderBarStyles.js index 1e93f5d68e..2a2a0812bd 100644 --- a/app/components/HeaderBarStyles.js +++ b/app/components/HeaderBarStyles.js @@ -55,9 +55,9 @@ const styles = { width: 24, height: 24, backgroundColor: 'transparent', - marginLeft: -6, //Because of button.css, when removed remove this - marginTop: -1, //Because of button.css, when removed remove this -}) + marginLeft: -6, //Because of button.css, when removed remove this + marginTop: -1, //Because of button.css, when removed remove this + }) }; module.exports = styles;
\ No newline at end of file diff --git a/app/components/Img.js b/app/components/Img.js index 280d072a29..637f66f08b 100644 --- a/app/components/Img.js +++ b/app/components/Img.js @@ -5,7 +5,7 @@ import { View, Component } from 'reactxp'; export default class Img extends Component { render(){ - const url = "./assets/images/" + this.props.source + ".svg"; + const url = './assets/images/' + this.props.source + '.svg'; const style = this.props.style; diff --git a/app/lib/backend.js b/app/lib/backend.js index a68c2309e7..b76b3b3749 100644 --- a/app/lib/backend.js +++ b/app/lib/backend.js @@ -8,7 +8,6 @@ import accountActions from '../redux/account/actions'; import connectionActions from '../redux/connection/actions'; import settingsActions from '../redux/settings/actions'; import { push } from 'react-router-redux'; -import { defaultServer } from '../config'; import type { ReduxStore } from '../redux/store'; import type { AccountToken, BackendState, RelayLocation, RelaySettingsUpdate } from './ipc-facade'; diff --git a/app/lib/platform.android.js b/app/lib/platform.android.js index f1f286826b..d7bd39b867 100644 --- a/app/lib/platform.android.js +++ b/app/lib/platform.android.js @@ -6,8 +6,8 @@ const exit = () => { BackHandler.exitApp(); }; -const open = (link) => { +const open = (link: string) => { Linking.openURL(link); }; -export {exit, open};
\ No newline at end of file +export {exit, open}; diff --git a/app/lib/platform.js b/app/lib/platform.js index 868a24e588..74ae69e145 100644 --- a/app/lib/platform.js +++ b/app/lib/platform.js @@ -6,8 +6,9 @@ const exit = () => { remote.app.quit(); }; -const open = (link) => { +const open = (link: string) => { + // $FlowFixMe shell.openExternal(link); }; -export {exit, open};
\ No newline at end of file +export {exit, open}; |
