Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
frontend
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
vicotor
frontend
Commits
6a2203ce
Unverified
Commit
6a2203ce
authored
Oct 29, 2024
by
Igor Stuev
Committed by
GitHub
Oct 29, 2024
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2336 from blockscout/fe-2335
add skeleton to chart resolutions control
parents
5231d041
85f6dbff
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
+9
-3
Chart.tsx
ui/pages/Chart.tsx
+9
-3
No files found.
ui/pages/Chart.tsx
View file @
6a2203ce
import
{
Button
,
Flex
,
Link
,
Text
}
from
'
@chakra-ui/react
'
;
import
{
Button
,
Flex
,
Link
,
Skeleton
,
Text
}
from
'
@chakra-ui/react
'
;
import
type
{
NextRouter
}
from
'
next/router
'
;
import
type
{
NextRouter
}
from
'
next/router
'
;
import
{
useRouter
}
from
'
next/router
'
;
import
{
useRouter
}
from
'
next/router
'
;
import
React
from
'
react
'
;
import
React
from
'
react
'
;
...
@@ -179,13 +179,19 @@ const Chart = () => {
...
@@ -179,13 +179,19 @@ const Chart = () => {
{
!
isMobile
&&
<
Text
>
Period
</
Text
>
}
{
!
isMobile
&&
<
Text
>
Period
</
Text
>
}
<
ChartIntervalSelect
interval=
{
interval
}
onIntervalChange=
{
onIntervalChange
}
/>
<
ChartIntervalSelect
interval=
{
interval
}
onIntervalChange=
{
onIntervalChange
}
/>
</
Flex
>
</
Flex
>
{
lineQuery
.
data
?.
info
?.
resolutions
&&
lineQuery
.
data
?.
info
?.
resolutions
.
length
>
1
&&
(
{
(
(
info
?.
resolutions
&&
info
?.
resolutions
.
length
>
1
)
||
(
!
info
&&
lineQuery
.
data
?.
info
?.
resolutions
&&
lineQuery
.
data
?.
info
?.
resolutions
.
length
>
1
)
)
&&
(
<
Flex
alignItems=
"center"
gap=
{
3
}
>
<
Flex
alignItems=
"center"
gap=
{
3
}
>
<
Text
>
{
isMobile
?
'
Res.
'
:
'
Resolution
'
}
</
Text
>
<
Skeleton
isLoaded=
{
!
isInfoLoading
}
>
{
isMobile
?
'
Res.
'
:
'
Resolution
'
}
</
Skeleton
>
<
ChartResolutionSelect
<
ChartResolutionSelect
resolution=
{
resolution
}
resolution=
{
resolution
}
onResolutionChange=
{
onResolutionChange
}
onResolutionChange=
{
onResolutionChange
}
resolutions=
{
lineQuery
.
data
?.
info
?.
resolutions
||
[]
}
resolutions=
{
lineQuery
.
data
?.
info
?.
resolutions
||
[]
}
isLoading=
{
isInfoLoading
}
/>
/>
</
Flex
>
</
Flex
>
)
}
)
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment