-
Notifications
You must be signed in to change notification settings - Fork 887
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: prevent bad text alignment in portfolio TXs
- Loading branch information
1 parent
0e07c4d
commit af14e70
Showing
3 changed files
with
201 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
55 changes: 55 additions & 0 deletions
55
...t_ui/components/desktop/portfolio-transaction-item/portfolio-transaction-item.stories.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
// Copyright (c) 2022 The Brave Authors. All rights reserved. | ||
// This Source Code Form is subject to the terms of the Mozilla Public | ||
// License, v. 2.0. If a copy of the MPL was not distributed with this file, | ||
// you can obtain one at http://mozilla.org/MPL/2.0/. | ||
|
||
import * as React from 'react' | ||
import styled from 'styled-components' | ||
import { mockAccount } from '../../../common/constants/mocks' | ||
import { mockTransactionInfo } from '../../../stories/mock-data/mock-transaction-info' | ||
|
||
import { WalletPageStory } from '../../../stories/wrappers/wallet-page-story-wrapper' | ||
import WalletPageLayout from '../wallet-page-layout' | ||
import WalletSubViewLayout from '../wallet-sub-view-layout' | ||
import { PortfolioTransactionItem } from './index' | ||
|
||
export const CryptoViewWrapper = styled.div` | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
justify-content: flex-start; | ||
width: 100%; | ||
position: relative; | ||
` | ||
|
||
const PortfolioWrapper = styled.div` | ||
display: flex; | ||
flex-direction: column; | ||
align-items: flex-start; | ||
justify-content: flex-start; | ||
width: 100%; | ||
margin-bottom: 20px; | ||
` | ||
|
||
export const _PortfolioTransactionItem: React.FC = () => { | ||
return ( | ||
<WalletPageStory> | ||
<WalletPageLayout> | ||
<WalletSubViewLayout> | ||
<CryptoViewWrapper> | ||
<PortfolioWrapper> | ||
<PortfolioTransactionItem | ||
account={mockAccount} | ||
accounts={[mockAccount]} | ||
displayAccountName={true} | ||
transaction={mockTransactionInfo} | ||
/> | ||
</PortfolioWrapper> | ||
</CryptoViewWrapper> | ||
</WalletSubViewLayout> | ||
</WalletPageLayout> | ||
</WalletPageStory> | ||
) | ||
} | ||
|
||
export default _PortfolioTransactionItem |
Oops, something went wrong.