-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
move statement info panel to new UI kit #159
- Loading branch information
Showing
32 changed files
with
211 additions
and
215 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
This file was deleted.
Oops, something went wrong.
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
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
16 changes: 0 additions & 16 deletions
16
src/components/market/StatementDetailedInfo/StatementDetailedInfo.module.scss
This file was deleted.
Oops, something went wrong.
67 changes: 0 additions & 67 deletions
67
src/components/market/StatementDetailedInfo/StatementDetailedInfo.tsx
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
37 changes: 0 additions & 37 deletions
37
src/components/market/StatementInfoPanel/StatementInfoPanel.module.scss
This file was deleted.
Oops, something went wrong.
57 changes: 0 additions & 57 deletions
57
src/components/market/StatementInfoPanel/StatementInfoPanel.tsx
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
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
Empty file.
47 changes: 47 additions & 0 deletions
47
src/features/dashboard/components/StatementInfoPanel/StatementDetailedInfo.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,47 @@ | ||
/** | ||
* @file React component. | ||
* @copyright Yury Korotovskikh <u.korotovskiy@nil.foundation> | ||
*/ | ||
|
||
import { globalStyles } from '@/styles/globalStyles'; | ||
import type { ReactElement } from 'react'; | ||
import { useStyletron } from 'styletron-react'; | ||
|
||
type StatementDetailedInfoProps = { | ||
description?: string; | ||
url?: string; | ||
}; | ||
|
||
/** | ||
* Statement detailed info component. | ||
* | ||
* @param {StatementDetailedInfoProps} props Props. | ||
* @returns React component. | ||
*/ | ||
export const StatementDetailedInfo = ({ | ||
description, | ||
url, | ||
}: StatementDetailedInfoProps): ReactElement => { | ||
const [css] = useStyletron(); | ||
|
||
return ( | ||
<div> | ||
<div> | ||
<span className={css(globalStyles.textMuted)}>Description:</span> | ||
{description ? ` ${description}` : 'No description'} | ||
</div> | ||
{url && ( | ||
<div> | ||
<span className={css(globalStyles.textMuted)}>Url:</span>{' '} | ||
<a | ||
href={url} | ||
rel="noreferrer" | ||
target="_blank" | ||
> | ||
{url} | ||
</a> | ||
</div> | ||
)} | ||
</div> | ||
); | ||
}; |
Oops, something went wrong.