mirror of
https://github.com/trezor/trezor-wallet
synced 2025-01-26 07:51:36 +00:00
fix copy to clipboard button tooltip
This commit is contained in:
parent
56d2b8a0f7
commit
07db982493
@ -70,6 +70,11 @@ const ButtonCopy = styled(Button)`
|
||||
margin-top: 10px;
|
||||
`;
|
||||
|
||||
const TooltipContainer = styled.div`
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
`;
|
||||
|
||||
const Log = (props: Props) => {
|
||||
if (!props.log.opened) return null;
|
||||
|
||||
@ -93,15 +98,16 @@ const Log = (props: Props) => {
|
||||
<ReactJson src={props.log.entries} />
|
||||
</LogWrapper>
|
||||
{props.log.copied ? (
|
||||
<Tooltip
|
||||
defaultVisible
|
||||
maxWidth={285}
|
||||
placement="top"
|
||||
content={<FormattedMessage {...l10nMessages.TR_COPIED} />}
|
||||
afterVisibleChange={props.resetCopyState}
|
||||
>
|
||||
{copyBtn}
|
||||
</Tooltip>
|
||||
<TooltipContainer>
|
||||
<Tooltip
|
||||
maxWidth={285}
|
||||
placement="top"
|
||||
content={<FormattedMessage {...l10nMessages.TR_COPIED} />}
|
||||
onHidden={props.resetCopyState}
|
||||
>
|
||||
{copyBtn}
|
||||
</Tooltip>
|
||||
</TooltipContainer>
|
||||
) : (
|
||||
<CopyWrapper>{copyBtn}</CopyWrapper>
|
||||
)}
|
||||
|
Loading…
Reference in New Issue
Block a user