import queryString from 'query-string'; import {useEffect, useState} from 'react'; import {FormattedMessage} from 'react-intl'; import {Link} from 'react-router'; import {Card, Grid, Image} from 'semantic-ui-react'; import {getChangelog, updateSeenVersion} from './changelog'; import logo from './topola.jpg'; import {Media} from './util/media'; import {isOnWikitreeDomain, WIKITREE_TOPOLA_URL} from './util/wikitree_util'; /** Link that loads a view. */ function ViewLink(props: {params: {[key: string]: string}; text: string}) { return ( {props.text} ); } function formatBuildDate(dateString: string | undefined) { return dateString?.slice(0, 16) || ''; } function Contents() { const [changelog, setChangelog] = useState(''); useEffect(() => { (async () => { setChangelog(await getChangelog(1)); updateSeenVersion(); })(); }, []); return ( <>
version: {formatBuildDate(import.meta.env.VITE_GIT_TIME)} ( {import.meta.env.VITE_GIT_SHA} )
> ); } /** The intro page. */ export function Intro() { return (