fix: small component fixes

This commit is contained in:
Taranto 2020-08-10 11:51:21 +01:00 committed by Josh Harvey
parent 0b28e7f98a
commit b153a23f25
7 changed files with 23 additions and 9 deletions

View file

@ -33,7 +33,7 @@ const useStyles = makeStyles({
marginRight: spacer / 4,
marginBottom: spacer / 2,
marginLeft: spacer / 4,
height: 18,
height: spacer * 3,
backgroundColor: ({ type }) => backgroundColors[type]
},
label: {

View file

@ -100,6 +100,7 @@ const ECol = ({
width,
textAlign,
suffix,
SuffixComponent = TL2,
view = it => it?.toString(),
inputProps = {}
} = config
@ -137,7 +138,9 @@ const ECol = ({
) : (
values && <>{view(values[name])}</>
)}
{suffix && <TL2 className={classes.suffix}>{suffix}</TL2>}
{suffix && (
<SuffixComponent className={classes.suffix}>{suffix}</SuffixComponent>
)}
</Td>
)
}

View file

@ -10,11 +10,11 @@ import {
white
} from 'src/styling/variables'
const { label2 } = typographyStyles
const { tl2 } = typographyStyles
const useStyles = makeStyles({
th: {
extend: label2,
extend: tl2,
backgroundColor: tableHeaderColor,
height: tableHeaderHeight,
textAlign: 'left',

View file

@ -20,6 +20,7 @@ import {
Label1,
Label3
} from 'src/components/typography'
import CopyToClipboard from 'src/pages/Transactions/CopyToClipboard'
import { primaryColor } from 'src/styling/variables'
import styles from './Funding.styles'
@ -199,7 +200,11 @@ const Funding = () => {
<H3 className={classes.topSpacer}>Address</H3>
<div className={classes.addressWrapper}>
<Mono className={classes.address}>
<strong>{formatAddress(selected.fundingAddress)}</strong>
<strong>
<CopyToClipboard buttonClassname={classes.copyToClipboard}>
{formatAddress(selected.fundingAddress)}
</CopyToClipboard>
</strong>
</Mono>
</div>
</div>

View file

@ -85,5 +85,11 @@ export default {
},
pending: {
backgroundColor: disabledColor2
},
copyToClipboard: {
marginLeft: 'auto',
paddingTop: 6,
paddingLeft: 15,
marginRight: -11
}
}

View file

@ -17,7 +17,7 @@ import {
TableBody,
TableCell
} from 'src/components/table'
import { Info3 } from 'src/components/typography'
import { Label1, Info3 } from 'src/components/typography'
import { ReactComponent as WhiteShareIcon } from 'src/styling/icons/circle buttons/share/white.svg'
import { ReactComponent as ShareIcon } from 'src/styling/icons/circle buttons/share/zodiac.svg'
@ -118,7 +118,7 @@ const Logs = () => {
Icon={ShareIcon}
InverseIcon={WhiteShareIcon}
onClick={sendSnapshot}>
Share with Lamassu
<Label1>Share with Lamassu</Label1>
</SimpleButton>
<Info3>{saveMessage}</Info3>
</div>

View file

@ -18,7 +18,7 @@ import {
TableBody,
TableCell
} from 'src/components/table'
import { Info3 } from 'src/components/typography'
import { Label1, Info3 } from 'src/components/typography'
import typographyStyles from 'src/components/typography/styles'
import { ReactComponent as WhiteShareIcon } from 'src/styling/icons/circle buttons/share/white.svg'
import { ReactComponent as ShareIcon } from 'src/styling/icons/circle buttons/share/zodiac.svg'
@ -128,7 +128,7 @@ const Logs = () => {
Icon={ShareIcon}
InverseIcon={WhiteShareIcon}
onClick={sendSnapshot}>
Share with Lamassu
<Label1>Share with Lamassu</Label1>
</SimpleButton>
<Info3>{saveMessage}</Info3>
</div>