import React, { Component, ReactElement, Fragment } from 'react'; import { DetailContextConsumer, VersionPageConsumerProps } from '../../pages/Version'; import Readme from '../Readme'; import Versions from '../Versions'; import { preventXSS } from '../../utils/sec-utils'; import Tabs from '@material-ui/core/Tabs'; import Tab from '@material-ui/core/Tab'; import { Content } from './styles'; import Dependencies from '../Dependencies'; import UpLinks from '../UpLinks'; interface DetailContainerState { tabPosition: number; } export const README_LABEL = 'Readme'; export const DEPS_LABEL = 'Dependencies'; export const VERSION_LABEL = 'Versions'; export const UPLINKS_LABEL = 'Uplinks'; class DetailContainer
extends Component
{
public state = {
tabPosition: 0,
};
public render(): ReactElement
{tabPosition === 0 && this.renderReadme(readMe)}
{tabPosition === 1 &&