diff --git a/components/PreviewEventDashboardItem.js b/components/PreviewEventDashboardItem.js index e8322bb..d3781ed 100644 --- a/components/PreviewEventDashboardItem.js +++ b/components/PreviewEventDashboardItem.js @@ -1,11 +1,10 @@ // @flow import * as React from 'react'; -import {MaterialCommunityIcons} from "@expo/vector-icons"; import {View} from "react-native"; import HTML from "react-native-render-html"; import i18n from "i18n-js"; -import {Avatar, Card, Text, withTheme, Button} from 'react-native-paper'; +import {Avatar, Button, Card, withTheme} from 'react-native-paper'; import PlanningEventManager from "../utils/PlanningEventManager"; @@ -34,28 +33,28 @@ function PreviewEventDashboardItem(props) { title={props.event['title']} subtitle={PlanningEventManager.getFormattedEventTime(props.event)} />} - 70 ? 100 : 50, - overflow: 'hidden', - }}> - " + props.event['description'] + ""} - tagsStyles={{ - p: {color: colors.text,}, - div: {color: colors.text}, - }}/> + 70 ? 100 : 50, + overflow: 'hidden', + }}> + " + props.event['description'] + ""} + tagsStyles={{ + p: {color: colors.text,}, + div: {color: colors.text}, + }}/> - - - - + > + {i18n.t("homeScreen.dashboard.seeMore")} + + ); } else diff --git a/components/ProxiwashListItem.js b/components/ProxiwashListItem.js index 2accefa..1e6f2c2 100644 --- a/components/ProxiwashListItem.js +++ b/components/ProxiwashListItem.js @@ -1,5 +1,5 @@ import * as React from 'react'; -import {Card, Avatar, List, Text, withTheme} from 'react-native-paper'; +import {Avatar, Card, Text, withTheme} from 'react-native-paper'; import {View} from "react-native"; import ProxiwashConstants from "../constants/ProxiwashConstants"; diff --git a/components/Sidebar.js b/components/Sidebar.js index d6805c8..4f8fb9f 100644 --- a/components/Sidebar.js +++ b/components/Sidebar.js @@ -21,7 +21,7 @@ type State = { /** * Class used to define a navigation drawer */ -export default class SideBar extends React.Component { +export default class SideBar extends React.PureComponent { dataSet: Array; @@ -122,11 +122,6 @@ export default class SideBar extends React.Component { this.getRenderItem = this.getRenderItem.bind(this); } - shouldComponentUpdate(nextProps: Props, nextState: State): boolean { - return nextState.active !== this.state.active; - } - - onListItemPress(item: Object) { if (item.link === undefined) this.props.navigation.navigate(item.route); diff --git a/components/WebSectionList.js b/components/WebSectionList.js index 13bc60e..481a9e1 100644 --- a/components/WebSectionList.js +++ b/components/WebSectionList.js @@ -36,7 +36,7 @@ const MIN_REFRESH_TIME = 5 * 1000; * @prop fontSize {number} The icon size. Use 26 if unspecified * @prop width {number} The icon width. Use 30 if unspecified */ -export default class WebSectionList extends React.Component { +export default class WebSectionList extends React.PureComponent { static defaultProps = { renderSectionHeader: null, diff --git a/components/WebViewScreen.js b/components/WebViewScreen.js index 24fd705..bdeb5b5 100644 --- a/components/WebViewScreen.js +++ b/components/WebViewScreen.js @@ -3,8 +3,7 @@ import * as React from 'react'; import {View} from 'react-native'; import WebView from "react-native-webview"; -import ThemeManager from "../utils/ThemeManager"; -import {ActivityIndicator} from 'react-native-paper'; +import {ActivityIndicator, withTheme} from 'react-native-paper'; import HeaderButton from "./HeaderButton"; type Props = { @@ -24,28 +23,31 @@ type Props = { /** * Class defining a webview screen. */ -export default class WebViewScreen extends React.Component { +class WebViewScreen extends React.PureComponent { static defaultProps = { hasBackButton: false, hasSideMenu: true, hasFooter: true, }; - webviewArray: Array = []; + webviewRef: Object; onRefreshClicked: Function; onWebviewRef: Function; onGoBackWebview: Function; onGoForwardWebview: Function; - onOpenWebLink: Function; + getRenderLoading: Function; - constructor() { - super(); + colors: Object; + + constructor(props) { + super(props); this.onRefreshClicked = this.onRefreshClicked.bind(this); this.onWebviewRef = this.onWebviewRef.bind(this); this.onGoBackWebview = this.onGoBackWebview.bind(this); this.onGoForwardWebview = this.onGoForwardWebview.bind(this); - this.onOpenWebLink = this.onOpenWebLink.bind(this); + this.getRenderLoading = this.getRenderLoading.bind(this); + this.colors = props.theme.colors; } componentDidMount() { @@ -73,38 +75,28 @@ export default class WebViewScreen extends React.Component { }; onRefreshClicked() { - for (let view of this.webviewArray) { - if (view !== null) - view.reload(); - } + if (this.webviewRef !== null) + this.webviewRef.reload(); } onGoBackWebview() { - for (let view of this.webviewArray) { - if (view !== null) - view.goBack(); - } + if (this.webviewRef !== null) + this.webviewRef.goBack(); } onGoForwardWebview() { - for (let view of this.webviewArray) { - if (view !== null) - view.goForward(); - } + if (this.webviewRef !== null) + this.webviewRef.goForward(); } - onOpenWebLink() { - this.openWebLink(this.props.data[0]['url']) - } - - onWebviewRef(ref: WebView) { - this.webviewArray.push(ref) + onWebviewRef(ref: Object) { + this.webviewRef = ref } getRenderLoading() { return ( { + color={this.colors.primary}/> ); } - getWebview(obj: Object) { - return ( - - ); - } - render() { // console.log("rendering WebViewScreen"); - this.webviewArray = []; return ( - this.getWebview(this.props.data[0]) + ); } } +export default withTheme(WebViewScreen); diff --git a/screens/About/AboutScreen.js b/screens/About/AboutScreen.js index 3c00b05..d93fb0c 100644 --- a/screens/About/AboutScreen.js +++ b/screens/About/AboutScreen.js @@ -6,8 +6,7 @@ import i18n from "i18n-js"; import appJson from '../../app'; import AsyncStorageManager from "../../utils/AsyncStorageManager"; import CustomModal from "../../components/CustomModal"; -import ThemeManager from "../../utils/ThemeManager"; -import {Avatar, Button, Card, List, Text, Title} from 'react-native-paper'; +import {Avatar, Button, Card, List, Text, Title, withTheme} from 'react-native-paper'; const links = { appstore: 'https://apps.apple.com/us/app/campus-amicale-insat/id1477722148', @@ -59,7 +58,7 @@ function openWebLink(link) { /** * Class defining an about screen. This screen shows the user information about the app and it's author. */ -export default class AboutScreen extends React.Component { +class AboutScreen extends React.Component { debugTapCounter = 0; modalRef: Object; @@ -188,11 +187,14 @@ export default class AboutScreen extends React.Component { getMainCard: Function; onModalRef: Function; - constructor(props: any) { + colors: object; + + constructor(props) { super(props); this.getCardItem = this.getCardItem.bind(this); this.getMainCard = this.getMainCard.bind(this); this.onModalRef = this.onModalRef.bind(this); + this.colors = props.theme.colors; } getAppCard() { @@ -326,7 +328,7 @@ export default class AboutScreen extends React.Component { icon="email" mode="contained" dark={true} - color={ThemeManager.getCurrentThemeVariables().primary} + color={this.colors.primary} style={{ marginTop: 20, marginLeft: 'auto', @@ -339,7 +341,7 @@ export default class AboutScreen extends React.Component { icon="git" mode="contained" dark={true} - color={ThemeManager.getCurrentThemeVariables().primary} + color={this.colors.primary} style={{ marginTop: 20, marginLeft: 'auto', @@ -391,3 +393,5 @@ export default class AboutScreen extends React.Component { ); } } + +export default withTheme(AboutScreen); diff --git a/screens/About/DebugScreen.js b/screens/About/DebugScreen.js index 98e1565..09df31e 100644 --- a/screens/About/DebugScreen.js +++ b/screens/About/DebugScreen.js @@ -1,12 +1,11 @@ // @flow import * as React from 'react'; -import ThemeManager from '../../utils/ThemeManager'; import {Alert, Clipboard, ScrollView, View} from "react-native"; import AsyncStorageManager from "../../utils/AsyncStorageManager"; import NotificationsManager from "../../utils/NotificationsManager"; import CustomModal from "../../components/CustomModal"; -import {Button, Card, List, Subheading, TextInput, Title} from 'react-native-paper'; +import {Button, Card, List, Subheading, TextInput, Title, withTheme} from 'react-native-paper'; type Props = { navigation: Object, @@ -20,7 +19,7 @@ type State = { /** * Class defining the Debug screen. This screen allows the user to get detailed information on the app/device. */ -export default class DebugScreen extends React.Component { +class DebugScreen extends React.Component { modalRef: Object; modalInputValue = ''; @@ -31,9 +30,12 @@ export default class DebugScreen extends React.Component { onModalRef: Function; - constructor(props: any) { + colors: Object; + + constructor(props) { super(props); this.onModalRef = this.onModalRef.bind(this); + this.colors = props.theme.colors; } static getGeneralItem(onPressCallback: Function, icon: ?string, title: string, subtitle: string) { @@ -103,14 +105,14 @@ export default class DebugScreen extends React.Component { @@ -166,3 +168,5 @@ export default class DebugScreen extends React.Component { ); } } + +export default withTheme(DebugScreen); diff --git a/screens/HomeScreen.js b/screens/HomeScreen.js index be79447..464f196 100644 --- a/screens/HomeScreen.js +++ b/screens/HomeScreen.js @@ -3,11 +3,10 @@ import * as React from 'react'; import {View} from 'react-native'; import i18n from "i18n-js"; -import ThemeManager from "../utils/ThemeManager"; import DashboardItem from "../components/EventDashboardItem"; import * as WebBrowser from 'expo-web-browser'; import WebSectionList from "../components/WebSectionList"; -import {Text} from 'react-native-paper'; +import {Text, withTheme} from 'react-native-paper'; import FeedItem from "../components/FeedItem"; import SquareDashboardItem from "../components/SquareDashboardItem"; import PreviewEventDashboardItem from "../components/PreviewEventDashboardItem"; @@ -26,12 +25,13 @@ const REFRESH_TIME = 1000 * 20; // Refresh every 20 seconds type Props = { navigation: Object, + theme: Object, } /** * Class defining the app's home screen */ -export default class HomeScreen extends React.Component { +class HomeScreen extends React.Component { onProxiwashClick: Function; onTutorInsaClick: Function; @@ -40,14 +40,17 @@ export default class HomeScreen extends React.Component { getRenderItem: Function; createDataset: Function; - constructor() { - super(); + colors : Object; + + constructor(props) { + super(props); this.onProxiwashClick = this.onProxiwashClick.bind(this); this.onTutorInsaClick = this.onTutorInsaClick.bind(this); this.onMenuClick = this.onMenuClick.bind(this); this.onProximoClick = this.onProximoClick.bind(this); this.getRenderItem = this.getRenderItem.bind(this); this.createDataset = this.createDataset.bind(this); + this.colors = props.theme.colors; } /** @@ -338,35 +341,35 @@ export default class HomeScreen extends React.Component { margin: 10, }}> 0} badgeNumber={proxiwashData['washers']} /> 0} badgeNumber={proxiwashData['dryers']} /> 0} badgeNumber={tutorinsaData} /> 0} badgeNumber={parseInt(proximoData)} /> 0} @@ -413,3 +416,5 @@ export default class HomeScreen extends React.Component { ); } } + +export default withTheme(HomeScreen); diff --git a/screens/Planning/PlanningDisplayScreen.js b/screens/Planning/PlanningDisplayScreen.js index 9caf9a8..bbb4a2b 100644 --- a/screens/Planning/PlanningDisplayScreen.js +++ b/screens/Planning/PlanningDisplayScreen.js @@ -6,7 +6,7 @@ import ThemeManager from "../../utils/ThemeManager"; import HTML from "react-native-render-html"; import {Linking} from "expo"; import PlanningEventManager from '../../utils/PlanningEventManager'; -import {Card} from 'react-native-paper'; +import {Card, withTheme} from 'react-native-paper'; type Props = { navigation: Object, @@ -20,10 +20,17 @@ function openWebLink(event, link) { /** * Class defining an about screen. This screen shows the user information about the app and it's author. */ -export default class PlanningDisplayScreen extends React.Component { +class PlanningDisplayScreen extends React.Component { displayData = this.props.route.params['data']; + colors: Object; + + constructor(props) { + super(props); + this.colors = props.theme.colors; + } + render() { // console.log("rendering planningDisplayScreen"); return ( @@ -44,8 +51,8 @@ export default class PlanningDisplayScreen extends React.Component { " + this.displayData.description + ""} tagsStyles={{ - p: {color: ThemeManager.getCurrentThemeVariables().text,}, - div: {color: ThemeManager.getCurrentThemeVariables().text} + p: {color: this.colors.text,}, + div: {color: this.colors.text} }} onLinkPress={openWebLink}/> @@ -54,3 +61,5 @@ export default class PlanningDisplayScreen extends React.Component { ); } } + +export default withTheme(PlanningDisplayScreen); diff --git a/screens/Proximo/ProximoAboutScreen.js b/screens/Proximo/ProximoAboutScreen.js index 25581c0..b7e0118 100644 --- a/screens/Proximo/ProximoAboutScreen.js +++ b/screens/Proximo/ProximoAboutScreen.js @@ -3,7 +3,7 @@ import * as React from 'react'; import {Image, ScrollView, View} from 'react-native'; import i18n from "i18n-js"; -import {Text, Card, List, Paragraph} from 'react-native-paper'; +import {Card, List, Paragraph, Text} from 'react-native-paper'; type Props = { navigation: Object, diff --git a/screens/Proximo/ProximoListScreen.js b/screens/Proximo/ProximoListScreen.js index 3fbed58..3d7bd77 100644 --- a/screens/Proximo/ProximoListScreen.js +++ b/screens/Proximo/ProximoListScreen.js @@ -3,9 +3,8 @@ import * as React from 'react'; import {FlatList, Image, ScrollView, View} from "react-native"; import i18n from "i18n-js"; -import ThemeManager from "../../utils/ThemeManager"; import CustomModal from "../../components/CustomModal"; -import {Avatar, IconButton, List, RadioButton, Searchbar, Subheading, Text, Title} from "react-native-paper"; +import {Avatar, IconButton, List, RadioButton, Searchbar, Subheading, Text, Title, withTheme} from "react-native-paper"; function sortPrice(a, b) { return a.price - b.price; @@ -45,7 +44,7 @@ type State = { /** * Class defining proximo's article list of a certain category. */ -export default class ProximoListScreen extends React.Component { +class ProximoListScreen extends React.Component { modalRef: Object; originalData: Array; @@ -56,7 +55,9 @@ export default class ProximoListScreen extends React.Component { renderItem: Function; onModalRef: Function; - constructor(props: any) { + colors: Object; + + constructor(props) { super(props); this.originalData = this.props.route.params['data']['data']; this.shouldFocusSearchBar = this.props.route.params['shouldFocusSearchBar']; @@ -70,6 +71,7 @@ export default class ProximoListScreen extends React.Component { this.onSortMenuPress = this.onSortMenuPress.bind(this); this.renderItem = this.renderItem.bind(this); this.onModalRef = this.onModalRef.bind(this); + this.colors = props.theme.colors; } @@ -133,11 +135,11 @@ export default class ProximoListScreen extends React.Component { getStockColor(availableStock: number) { let color: string; if (availableStock > 3) - color = ThemeManager.getCurrentThemeVariables().success; + color = this.colors.success; else if (availableStock > 0) - color = ThemeManager.getCurrentThemeVariables().warning; + color = this.colors.warning; else - color = ThemeManager.getCurrentThemeVariables().danger; + color = this.colors.danger; return color; } @@ -270,7 +272,7 @@ export default class ProximoListScreen extends React.Component { return ( @@ -286,7 +288,7 @@ export default class ProximoListScreen extends React.Component { descriptionStyle={{color: this.getStockColor(parseInt(item.quantity))}} onPress={onPress} left={() => } + source={{uri: item.image}}/>} right={() => {item.price}€ @@ -322,3 +324,5 @@ export default class ProximoListScreen extends React.Component { ); } } + +export default withTheme(ProximoListScreen); diff --git a/screens/Proximo/ProximoMainScreen.js b/screens/Proximo/ProximoMainScreen.js index a4dd547..c278608 100644 --- a/screens/Proximo/ProximoMainScreen.js +++ b/screens/Proximo/ProximoMainScreen.js @@ -3,9 +3,8 @@ import * as React from 'react'; import {View} from 'react-native' import i18n from "i18n-js"; -import ThemeManager from "../../utils/ThemeManager"; import WebSectionList from "../../components/WebSectionList"; -import {IconButton, List} from 'react-native-paper'; +import {List, withTheme} from 'react-native-paper'; import HeaderButton from "../../components/HeaderButton"; const DATA_URL = "https://etud.insa-toulouse.fr/~proximo/data/stock-v2.json"; @@ -22,7 +21,7 @@ type State = { * Class defining the main proximo screen. This screen shows the different categories of articles * offered by proximo. */ -export default class ProximoMainScreen extends React.Component { +class ProximoMainScreen extends React.Component { articles: Object; @@ -31,12 +30,15 @@ export default class ProximoMainScreen extends React.Component { getRenderItem: Function; createDataset: Function; - constructor() { - super(); + colors: Object; + + constructor(props) { + super(props); this.onPressSearchBtn = this.onPressSearchBtn.bind(this); this.onPressAboutBtn = this.onPressAboutBtn.bind(this); this.getRenderItem = this.getRenderItem.bind(this); this.createDataset = this.createDataset.bind(this); + this.colors = props.theme.colors; } static sortFinalData(a: Object, b: Object) { @@ -180,7 +182,7 @@ export default class ProximoMainScreen extends React.Component { left={props => } + color={this.colors.primary}/>} right={props => } /> ); @@ -202,3 +204,4 @@ export default class ProximoMainScreen extends React.Component { } } +export default withTheme(ProximoMainScreen); diff --git a/screens/Proxiwash/ProxiwashAboutScreen.js b/screens/Proxiwash/ProxiwashAboutScreen.js index 0176460..dd4cd21 100644 --- a/screens/Proxiwash/ProxiwashAboutScreen.js +++ b/screens/Proxiwash/ProxiwashAboutScreen.js @@ -1,7 +1,7 @@ // @flow import * as React from 'react'; -import {Image, View, ScrollView} from 'react-native'; +import {Image, ScrollView, View} from 'react-native'; import i18n from "i18n-js"; import {Card, List, Paragraph, Text, Title} from 'react-native-paper'; diff --git a/screens/Proxiwash/ProxiwashScreen.js b/screens/Proxiwash/ProxiwashScreen.js index 515df53..0232658 100644 --- a/screens/Proxiwash/ProxiwashScreen.js +++ b/screens/Proxiwash/ProxiwashScreen.js @@ -7,12 +7,11 @@ import WebSectionList from "../../components/WebSectionList"; import NotificationsManager from "../../utils/NotificationsManager"; import AsyncStorageManager from "../../utils/AsyncStorageManager"; import * as Expo from "expo"; -import {Avatar, Banner, Button, Card, Text} from 'react-native-paper'; +import {Avatar, Banner, Button, Card, Text, withTheme} from 'react-native-paper'; import HeaderButton from "../../components/HeaderButton"; import ProxiwashListItem from "../../components/ProxiwashListItem"; import ProxiwashConstants from "../../constants/ProxiwashConstants"; import CustomModal from "../../components/CustomModal"; -import ThemeManager from "../../utils/ThemeManager"; const DATA_URL = "https://etud.insa-toulouse.fr/~amicale_app/washinsa/washinsa.json"; @@ -24,6 +23,7 @@ const REFRESH_TIME = 1000 * 10; // Refresh every 10 seconds type Props = { navigation: Object, + theme: Object, } type State = { @@ -39,7 +39,7 @@ type State = { * Class defining the app's proxiwash screen. This screen shows information about washing machines and * dryers, taken from a scrapper reading proxiwash website */ -export default class ProxiwashScreen extends React.Component { +class ProxiwashScreen extends React.Component { modalRef: Object; @@ -51,6 +51,7 @@ export default class ProxiwashScreen extends React.Component { onModalRef: Function; fetchedData: Object; + colors: Object; state = { refreshing: false, @@ -65,8 +66,8 @@ export default class ProxiwashScreen extends React.Component { /** * Creates machine state parameters using current theme and translations */ - constructor() { - super(); + constructor(props) { + super(props); stateStrings[ProxiwashConstants.machineStates.TERMINE] = i18n.t('proxiwashScreen.states.finished'); stateStrings[ProxiwashConstants.machineStates.DISPONIBLE] = i18n.t('proxiwashScreen.states.ready'); stateStrings[ProxiwashConstants.machineStates["EN COURS"]] = i18n.t('proxiwashScreen.states.running'); @@ -92,6 +93,7 @@ export default class ProxiwashScreen extends React.Component { this.createDataset = this.createDataset.bind(this); this.onHideBanner = this.onHideBanner.bind(this); this.onModalRef = this.onModalRef.bind(this); + this.colors = props.theme.colors; } onHideBanner() { @@ -301,7 +303,7 @@ export default class ProxiwashScreen extends React.Component { title={title} left={() => } /> @@ -338,41 +340,6 @@ export default class ProxiwashScreen extends React.Component { this.modalRef = ref; } - render() { - const nav = this.props.navigation; - return ( - - } - > - {i18n.t('proxiwashScreen.enableNotificationsTip')} - - - {this.state.modalCurrentDisplayItem} - - - - - ); - } - getMachineAvailableNumber(isDryer: boolean) { let data; if (isDryer) @@ -403,7 +370,7 @@ export default class ProxiwashScreen extends React.Component { subtitle={subtitle} left={() => } /> @@ -440,4 +407,41 @@ export default class ProxiwashScreen extends React.Component { /> ); } + + render() { + const nav = this.props.navigation; + return ( + + } + > + {i18n.t('proxiwashScreen.enableNotificationsTip')} + + + {this.state.modalCurrentDisplayItem} + + + + + ); + } } + +export default withTheme(ProxiwashScreen); diff --git a/screens/SelfMenuScreen.js b/screens/SelfMenuScreen.js index 716f9cc..45369cf 100644 --- a/screens/SelfMenuScreen.js +++ b/screens/SelfMenuScreen.js @@ -2,10 +2,9 @@ import * as React from 'react'; import {View} from 'react-native'; -import ThemeManager from "../utils/ThemeManager"; import i18n from "i18n-js"; import WebSectionList from "../components/WebSectionList"; -import {Card, Text} from 'react-native-paper'; +import {Card, Text, withTheme} from 'react-native-paper'; import AprilFoolsManager from "../utils/AprilFoolsManager"; const DATA_URL = "https://etud.insa-toulouse.fr/~amicale_app/menu/menu_data.json"; @@ -18,7 +17,7 @@ type Props = { * Class defining the app's menu screen. * This screen fetches data from etud to render the RU menu */ -export default class SelfMenuScreen extends React.Component { +class SelfMenuScreen extends React.Component { // Hard code strings as toLocaleDateString does not work on current android JS engine daysOfWeek = []; @@ -27,9 +26,10 @@ export default class SelfMenuScreen extends React.Component { getRenderItem: Function; getRenderSectionHeader: Function; createDataset: Function; + colors: Object; - constructor() { - super(); + constructor(props) { + super(props); this.daysOfWeek.push(i18n.t("date.daysOfWeek.monday")); this.daysOfWeek.push(i18n.t("date.daysOfWeek.tuesday")); this.daysOfWeek.push(i18n.t("date.daysOfWeek.wednesday")); @@ -54,6 +54,7 @@ export default class SelfMenuScreen extends React.Component { this.getRenderItem = this.getRenderItem.bind(this); this.getRenderSectionHeader = this.getRenderSectionHeader.bind(this); this.createDataset = this.createDataset.bind(this); + this.colors = props.theme.colors; } getKeyExtractor(item: Object) { @@ -138,7 +139,7 @@ export default class SelfMenuScreen extends React.Component { marginLeft: 'auto', marginRight: 'auto', borderBottomWidth: 1, - borderBottomColor: ThemeManager.getCurrentThemeVariables().primary, + borderBottomColor: this.colors.primary, marginTop: 5, marginBottom: 5, }}/> @@ -178,3 +179,4 @@ export default class SelfMenuScreen extends React.Component { } } +export default withTheme(SelfMenuScreen); diff --git a/utils/ThemeManager.js b/utils/ThemeManager.js index 91fd936..760f68f 100644 --- a/utils/ThemeManager.js +++ b/utils/ThemeManager.js @@ -132,14 +132,6 @@ export default class ThemeManager { return ThemeManager.getWhiteTheme(); } - /** - * Get the variables contained in the current theme - * @returns {Object} - */ - static getCurrentThemeVariables(): Object { - return ThemeManager.getCurrentTheme().colors; - } - /** * Set the function to be called when the theme is changed (allows for general reload of the app) * @param callback Function to call after theme change