// @flow import * as React from 'react'; import {Image} from 'react-native'; import {Container, Content, H1, H3, View} from 'native-base'; import CustomHeader from "../components/CustomHeader"; import ThemeManager from "../utils/ThemeManager"; import HTML from "react-native-render-html"; import {Linking} from "expo"; import PlanningEventManager from '../utils/PlanningEventManager'; type Props = { navigation: Object, }; function openWebLink(event, link) { Linking.openURL(link).catch((err) => console.error('Error opening link', err)); } /** * 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 { render() { // console.log("rendering planningDisplayScreen"); const nav = this.props.navigation; const displayData = nav.getParam('data', []); return (

{displayData.title}

{PlanningEventManager.getFormattedTime(displayData)}

{displayData.logo !== null ? : } {displayData.description !== null ? // Surround description with div to allow text styling if the description is not html " + displayData.description + ""} tagsStyles={{ p: { color: ThemeManager.getCurrentThemeVariables().textColor, fontSize: ThemeManager.getCurrentThemeVariables().fontSizeBase }, div: {color: ThemeManager.getCurrentThemeVariables().textColor} }} onLinkPress={openWebLink}/> : }
); } }