11<template >
22 <div class =" page-container" >
33 <Hero title =" Organizations" />
4- <LastUpdated />
5- <div class =" area-chart-section" >
6- <div class =" chart-header" >
7- <div class =" divider-black" ></div >
8- <div class =" flex-container" >
9- <h2 class =" pb-3 lg:pb-0" >Total Organizations in Jordan</h2 >
10- <ChartsPeriodDropdown
11- class =" justify-self-end"
12- @on-chart-period-changed =" onChartPeriodChanged"
13- />
4+ <div class =" px-8 md:px-14 lg:px-24" >
5+ <LastUpdated />
6+ <div class =" area-chart-section" >
7+ <div class =" chart-header" >
8+ <div class =" divider" ></div >
9+ <div class =" flex-container" >
10+ <h2 class =" pb-3 lg:pb-0" >Total Organizations in Jordan</h2 >
11+ <label class =" hidden" for =" orgCharts" >Period</label >
12+ <ChartsPeriodDropdown
13+ class =" justify-self-end"
14+ name =" orgCharts"
15+ @on-chart-period-changed =" onChartPeriodChanged"
16+ />
17+ </div >
1418 </div >
19+ <AreaChart class =" area-chart" :chart-options =" areaChartData" />
20+ </div >
21+ <div >
22+ <TopOrganizations class =" top-developers" />
1523 </div >
16- <AreaChart class =" area-chart" :chart-options =" areaChartData" />
17- </div >
18- <div >
19- <TopOrganizations class =" top-developers" />
2024 </div >
2125 </div >
2226</template >
@@ -43,7 +47,7 @@ export default {
4347 async mounted () {
4448 const lastYear = new Date ().getFullYear () - 1
4549 const response = await this .$axios .get (
46- ` /v1/organizations/stats?period=${ lastYear} -01-01_${ lastYear} -12-31&aggregation=month`
50+ ` /v1/organizations/stats?period=${ lastYear} -01-01_${ lastYear} -12-31&aggregation=month` ,
4751 )
4852 const areaChartStats = response .data .organizationsStats [lastYear]
4953
@@ -54,7 +58,7 @@ export default {
5458 const months = [... Array (12 ).keys ()].map ((key ) =>
5559 new Date (0 , key).toLocaleString (' default' , {
5660 month: ' short' ,
57- })
61+ }),
5862 )
5963 const lastYear = new Date ().getFullYear () - 1
6064
@@ -244,7 +248,7 @@ export default {
244248 const thisYear = new Date ().getFullYear ()
245249
246250 const response = await this .$axios .get (
247- ` /v1/organizations/stats?period=${ thisYear} -01-01_${ thisYear} -12-31&aggregation=month`
251+ ` /v1/organizations/stats?period=${ thisYear} -01-01_${ thisYear} -12-31&aggregation=month` ,
248252 )
249253 const areaChartStats = response .data .organizationsStats [thisYear]
250254 const months = [... Array (areaChartStats .length ).keys ()].map ((key ) => {
@@ -258,7 +262,7 @@ export default {
258262 const lastYear = new Date ().getFullYear () - 1
259263
260264 const response = await this .$axios .get (
261- ` /v1/organizations/stats?period=${ lastYear} -01-01_${ lastYear} -12-31&aggregation=month`
265+ ` /v1/organizations/stats?period=${ lastYear} -01-01_${ lastYear} -12-31&aggregation=month` ,
262266 )
263267 const areaChartStats = response .data .organizationsStats [lastYear]
264268 const months = [... Array (areaChartStats .length ).keys ()].map ((key ) => {
@@ -274,7 +278,7 @@ export default {
274278 const year = lastMonthDate .getFullYear ()
275279
276280 const response = await this .$axios .get (
277- ` /v1/organizations/stats?period=${ year} -01-01_${ year} -12-31&aggregation=day`
281+ ` /v1/organizations/stats?period=${ year} -01-01_${ year} -12-31&aggregation=day` ,
278282 )
279283
280284 const areaChartStats =
@@ -286,7 +290,7 @@ export default {
286290 {
287291 day: ' numeric' ,
288292 month: ' numeric' ,
289- }
293+ },
290294 )
291295 })
292296 const tickAmount = 5
@@ -305,26 +309,18 @@ export default {
305309 @apply h-56 md :h-96 lg:h-720;
306310}
307311
308- .area-chart-section {
309- @apply lg :mx-10 2 xl:mx-9 mx-3;
310- }
311-
312- .top-developers {
313- @apply 2 xl :mx-3;
314- }
315-
316312.chart-header {
317313 font-family : 'IBM Mono' ;
318314 font-size : 1.7 rem ;
319315 line-height : 1 em ;
320- @apply font-normal mx-4 pb-4 pt-16 md :pt-24 md:pb-8 md:mx-14 lg:text-4xl lg:font-light lg:px-2 2 xl:px-4 ;
316+ @apply font-normal pb-4 pt-16 md :pt-24 md:pb-8 lg:text-4xl lg:font-light;
321317}
322318
323319.flex-container {
324320 @apply items-center md :flex md:justify-between;
325321}
326322
327- .divider-black {
323+ .divider {
328324 @apply w-10 lg :w-10 border-t-2 border-black;
329325}
330326 </style >
0 commit comments