mirror of
https://github.com/SomboChea/ui
synced 2026-01-18 17:16:00 +07:00
fix: typography Component - Introduced ForwardRef (#179)
* refactor: introduced forwardref * refacttor: updated ref's * fix: fixed func's name * fix: fixed snapshots * fix: updated snap
This commit is contained in:
committed by
Juan Picado @jotadeveloper
parent
82d7107de7
commit
a8deeb9b9d
@@ -3,7 +3,7 @@ import React, { useContext } from 'react';
|
||||
import { DetailContext } from '../../pages/Version';
|
||||
import { DIST_TAGS } from '../../../lib/constants';
|
||||
|
||||
import { Heading } from './styles';
|
||||
import { StyledText } from './styles';
|
||||
import VersionsTagList from './VersionsTagList';
|
||||
import VersionsHistoryList from './VersionsHistoryList';
|
||||
|
||||
@@ -26,13 +26,13 @@ const Versions: React.FC = () => {
|
||||
<>
|
||||
{distTags && Object.keys(distTags).length > 0 && (
|
||||
<>
|
||||
<Heading variant="subtitle1">{LABEL_CURRENT_TAGS}</Heading>
|
||||
<StyledText variant="subtitle1">{LABEL_CURRENT_TAGS}</StyledText>
|
||||
<VersionsTagList tags={distTags} />
|
||||
</>
|
||||
)}
|
||||
{versions && Object.keys(versions).length > 0 && packageName && (
|
||||
<>
|
||||
<Heading variant="subtitle1">{LABEL_VERSION_HISTORY}</Heading>
|
||||
<StyledText variant="subtitle1">{LABEL_VERSION_HISTORY}</StyledText>
|
||||
<VersionsHistoryList packageName={packageName} time={time} versions={versions} />
|
||||
</>
|
||||
)}
|
||||
|
||||
@@ -1,13 +1,11 @@
|
||||
import styled from 'react-emotion';
|
||||
import Typography from '@material-ui/core/Typography';
|
||||
import { default as MuiListItemText } from '@material-ui/core/ListItemText';
|
||||
|
||||
import { fontWeight } from '../../utils/styles/sizes';
|
||||
import Text from '../../muiComponents/Text';
|
||||
|
||||
export const Heading = styled(Typography)({
|
||||
'&&': {
|
||||
fontWeight: fontWeight.bold,
|
||||
},
|
||||
export const StyledText = styled(Text)({
|
||||
fontWeight: fontWeight.bold,
|
||||
});
|
||||
|
||||
export const Spacer = styled('div')({
|
||||
|
||||
Reference in New Issue
Block a user