@@ -3,43 +3,9 @@ import '@splidejs/vue-splide/css/skyblue';
33import { defineClientComponent , useData } from ' vitepress' ;
44import { computed } from ' vue' ;
55
6- const photos: { url: string ; alt: Record <string , string > }[] = [
7- {
8- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/100.jpg' ,
9- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
10- }, {
11- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/96.jpg' ,
12- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
13- }, {
14- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/95.jpg' ,
15- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
16- }, {
17- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/94.jpg' ,
18- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
19- }, {
20- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/47.jpg' ,
21- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
22- }, {
23- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/44.jpg' ,
24- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
25- },
26- {
27- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/4.jpg' ,
28- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
29- },
30- {
31- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/1.jpg' ,
32- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
33- },
34- {
35- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/2.jpg' ,
36- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
37- },
38- {
39- url: ' https://eu2.contabostorage.com/176b8434127b4d90bfb1360e128e586c:oneamongus/about-us/3.jpg' ,
40- alt: { en: ' Events Photo -- All rights reserved' , ' zh-Hans' : ' 活动照片,保留所有权利' },
41- },
42- ];
6+ import photosData from ' ./photos.json' ;
7+
8+ const photos: { url: string ; alt: Record <string , string > }[] = photosData ;
439
4410export default defineClientComponent (async () => {
4511 const data = useData ();
@@ -76,6 +42,10 @@ export default defineClientComponent(async () => {
7642.splideimg {
7743 border : 1px solid var (--vp-c-bg-soft );
7844 border-radius : 12px ;
45+ max-height : 70vh ;
46+ max-width : 100% ;
47+ width : auto ;
48+ object-fit : contain ;
7949 transition :
8050 border-color 0.25s ,
8151 background-color 0.25s ;
@@ -84,4 +54,9 @@ export default defineClientComponent(async () => {
8454.splideimg :hover {
8555 border-color : var (--vp-c-brand-1 );
8656}
57+
58+ /* Override VitePress default list styling that misaligns the pagination buttons */
59+ .splide__pagination li {
60+ margin-top : 0 !important ;
61+ }
8762 </style >
0 commit comments