-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add notice to ledger chart description regarding date range inc…
…luded
- Loading branch information
Showing
10 changed files
with
59 additions
and
0 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
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
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
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
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 @@ | ||
export { default } from './ledger-description-notice' |
24 changes: 24 additions & 0 deletions
24
src/views/components/ledger-description-notice/ledger-description-notice.js
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,24 @@ | ||
import React from 'react' | ||
import dayjs from 'dayjs' | ||
import InfoIcon from '@mui/icons-material/Info' | ||
|
||
import './ledger-description-notice.styl' | ||
|
||
const timestamp = 1550832660 | ||
|
||
export default function LedgerDescriptionNotice() { | ||
const local_time = dayjs.unix(timestamp).format('YYYY-MM-DD HH:mm:ss') | ||
return ( | ||
<div className='ledger-chart-description-notice'> | ||
<InfoIcon /> | ||
<div className='ledger-chart-description-notice-text'> | ||
Data displayed includes only blocks with a timestamp. Local timestamps | ||
were first recorded:{' '} | ||
<span className='ledger-chart-description-notice-local-time'> | ||
{local_time} | ||
</span> | ||
. Data from blocks before this date are not included. | ||
</div> | ||
</div> | ||
) | ||
} |
20 changes: 20 additions & 0 deletions
20
src/views/components/ledger-description-notice/ledger-description-notice.styl
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,20 @@ | ||
.ledger-chart-description-notice | ||
border 1px solid lighten($nanoSoftBlue, 50%) | ||
border-radius 5px | ||
padding 10px | ||
margin-bottom 10px | ||
background-color lighten($nanoSoftBlue, 95%) | ||
display flex | ||
gap 10px | ||
|
||
svg | ||
width 20px | ||
height 20px | ||
color $nanoSoftBlue | ||
|
||
.ledger-chart-description-notice-local-time | ||
font-family 'IBM Plex Mono', monospace | ||
font-size 14px | ||
background-color white | ||
padding 2px 5px | ||
border-radius 5px |