@@ -2,7 +2,7 @@ import { DatasetteStatsCard } from '@/components/dashboard/datasette-stats-card'
2
2
import { StatisticsCard } from '@/components/dashboard/statistics-card'
3
3
import { Heading } from '@/components/mdx'
4
4
import { fetcher } from '@/lib/data-fetching'
5
- import { SimpleGrid , Spinner } from '@chakra-ui/react'
5
+ import { SimpleGrid , Spinner , Box , Container } from '@chakra-ui/react'
6
6
import { BsPeople , BsPerson } from 'react-icons/bs'
7
7
import { GoBook , GoPackage , GoStar , GoTag } from 'react-icons/go'
8
8
import useSWR from 'swr'
@@ -32,60 +32,62 @@ export const ProjectMetrics = () => {
32
32
const year = dateObj . getFullYear ( )
33
33
34
34
return (
35
- < >
36
- { ' ' }
37
- < Heading as = 'h1' size = '2xl' my = { 4 } textAlign = { 'center' } >
38
- Xarray Project Metrics
39
- </ Heading >
40
- < SimpleGrid columns = { { base : 1 , md : 3 } } spacing = { { base : 5 , lg : 8 } } >
41
- < StatisticsCard
42
- title = { 'Core Maintainers' }
43
- stat = { '15' }
44
- icon = { < BsPerson size = { '3em' } /> }
45
- link = { 'https://docs.xarray.dev/en/stable/team.html' }
46
- />
47
- < DatasetteStatsCard
48
- title = { 'Contributors' }
49
- query = {
50
- 'https://pydata-datasette.herokuapp.com/xarray/_analyze_tables_/contributors,user_id.json?_shape=array'
51
- }
52
- icon = { < BsPeople size = { '3em' } /> }
53
- link = { 'https://github.com/pydata/xarray/graphs/contributors' }
54
- />
35
+ < Box as = 'section' >
36
+ < Container maxW = 'container.lg' >
37
+ { ' ' }
38
+ < Heading as = 'h1' size = '2xl' textAlign = { 'center' } >
39
+ Xarray Project Metrics
40
+ </ Heading >
41
+ < SimpleGrid columns = { { base : 1 , md : 3 } } spacing = { { base : 5 , lg : 8 } } >
42
+ < StatisticsCard
43
+ title = { 'Core Maintainers' }
44
+ stat = { '15' }
45
+ icon = { < BsPerson size = { '3em' } /> }
46
+ link = { 'https://docs.xarray.dev/en/stable/team.html' }
47
+ />
48
+ < DatasetteStatsCard
49
+ title = { 'Contributors' }
50
+ query = {
51
+ 'https://pydata-datasette.herokuapp.com/xarray/_analyze_tables_/contributors,user_id.json?_shape=array'
52
+ }
53
+ icon = { < BsPeople size = { '3em' } /> }
54
+ link = { 'https://github.com/pydata/xarray/graphs/contributors' }
55
+ />
55
56
56
- < DatasetteStatsCard
57
- title = { 'Stargazers' }
58
- icon = { < GoStar size = { '3em' } /> }
59
- query = {
60
- 'https://pydata-datasette.herokuapp.com/xarray/_analyze_tables_/stars,user.json?_shape=array'
61
- }
62
- link = { 'https://github.com/pydata/xarray/stargazers' }
63
- />
57
+ < DatasetteStatsCard
58
+ title = { 'Stargazers' }
59
+ icon = { < GoStar size = { '3em' } /> }
60
+ query = {
61
+ 'https://pydata-datasette.herokuapp.com/xarray/_analyze_tables_/stars,user.json?_shape=array'
62
+ }
63
+ link = { 'https://github.com/pydata/xarray/stargazers' }
64
+ />
64
65
65
- < DatasetteStatsCard
66
- title = { 'Dependent Projects' }
67
- query = {
68
- 'https://pydata-datasette.herokuapp.com/xarray/_analyze_tables_/dependents,dependent.json?_shape=array'
69
- }
70
- icon = { < GoPackage size = { '3em' } /> }
71
- link = { 'https://github.com/pydata/xarray/network/dependents' }
72
- />
66
+ < DatasetteStatsCard
67
+ title = { 'Dependent Projects' }
68
+ query = {
69
+ 'https://pydata-datasette.herokuapp.com/xarray/_analyze_tables_/dependents,dependent.json?_shape=array'
70
+ }
71
+ icon = { < GoPackage size = { '3em' } /> }
72
+ link = { 'https://github.com/pydata/xarray/network/dependents' }
73
+ />
73
74
74
- < StatisticsCard
75
- title = { `${ month } /${ year } Docs Visitors` }
76
- stat = { monthlyViews . users }
77
- icon = { < GoBook size = { '3em' } /> }
78
- />
75
+ < StatisticsCard
76
+ title = { `${ month } /${ year } Docs Visitors` }
77
+ stat = { monthlyViews . users }
78
+ icon = { < GoBook size = { '3em' } /> }
79
+ />
79
80
80
- < DatasetteStatsCard
81
- title = { 'Releases' }
82
- query = {
83
- 'https://pydata-datasette.herokuapp.com/xarray/_analyze_tables_/releases,id.json?_shape=array'
84
- }
85
- icon = { < GoTag size = { '3em' } /> }
86
- link = { 'https://github.com/pydata/xarray/releases' }
87
- />
88
- </ SimpleGrid >
89
- </ >
81
+ < DatasetteStatsCard
82
+ title = { 'Releases' }
83
+ query = {
84
+ 'https://pydata-datasette.herokuapp.com/xarray/_analyze_tables_/releases,id.json?_shape=array'
85
+ }
86
+ icon = { < GoTag size = { '3em' } /> }
87
+ link = { 'https://github.com/pydata/xarray/releases' }
88
+ />
89
+ </ SimpleGrid >
90
+ </ Container >
91
+ </ Box >
90
92
)
91
93
}
0 commit comments