File tree 1 file changed +10
-48
lines changed
frontend/routes/package/(_islands)
1 file changed +10
-48
lines changed Original file line number Diff line number Diff line change @@ -86,59 +86,21 @@ export function DownloadChart(props: Props) {
86
86
borderColor : isDarkMode ? "#47515c" : "#e5e8eb" , // jsr-gray-700 for dark mode, jsr-gray-100 for light
87
87
strokeDashArray : 3 ,
88
88
} ,
89
+ responsive : [
90
+ {
91
+ breakpoint : 768 ,
92
+ options : {
93
+ legend : {
94
+ horizontalAlign : "left" ,
95
+ } ,
96
+ } ,
97
+ } ,
98
+ ] ,
89
99
} ) ;
90
100
91
101
useEffect ( ( ) => {
92
102
( async ( ) => {
93
103
const { default : ApexCharts } = await import ( "apexcharts" ) ;
94
- chartRef . current = new ApexCharts ( chartDivRef . current ! , {
95
- chart : {
96
- type : "area" ,
97
- stacked : true ,
98
- animations : {
99
- enabled : false ,
100
- } ,
101
- height : "100%" ,
102
- width : "100%" ,
103
- zoom : {
104
- allowMouseWheelZoom : false ,
105
- } ,
106
- } ,
107
- legend : {
108
- horizontalAlign : "center" ,
109
- position : "top" ,
110
- showForSingleSeries : true ,
111
- } ,
112
- tooltip : {
113
- items : {
114
- padding : 0 ,
115
- } ,
116
- } ,
117
- dataLabels : {
118
- enabled : false ,
119
- } ,
120
- stroke : {
121
- curve : "straight" ,
122
- width : 1.7 ,
123
- } ,
124
- series : getSeries ( props . downloads , "weekly" ) ,
125
- xaxis : {
126
- type : "datetime" ,
127
- tooltip : {
128
- enabled : false ,
129
- } ,
130
- } ,
131
- responsive : [
132
- {
133
- breakpoint : 768 ,
134
- options : {
135
- legend : {
136
- horizontalAlign : "left" ,
137
- } ,
138
- } ,
139
- } ,
140
- ] ,
141
- } ) ;
142
104
const isDarkMode = document . documentElement . classList . contains ( "dark" ) ;
143
105
144
106
chartRef . current = new ApexCharts (
You can’t perform that action at this time.
0 commit comments