File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed
sites/svelte.dev/src/routes/_components/Supporters Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change 2
2
import { Section } from ' @sveltejs/site-kit/components' ;
3
3
import contributors from ' ./contributors.js' ;
4
4
import donors from ' ./donors.js' ;
5
+
6
+ // @ts-ignore
7
+ import contributors_img from ' ./contributors.jpg?w=1200&format=webp;jpg&as=picture' ;
8
+ // @ts-check
9
+ import donors_img from ' ./donors.jpg?w=1200&format=webp;jpg&as=picture' ;
5
10
</script >
6
11
7
12
<Section --background =" var(--sk-back-2" >
20
25
<a
21
26
class =" supporter"
22
27
style ="background-position: {(100 * i ) / (contributors .length - 1 )}% 0"
28
+ style:background-image ="url( {contributors_img .sources .webp [0 ].src })"
23
29
href ="https://github.com/ {contributor }"
24
30
>
25
31
{contributor }
37
43
<a
38
44
class =" supporter"
39
45
style ="background-position: {(100 * i ) / (donors .length - 1 )}% 0"
46
+ style:background-image ="url( {donors_img .sources .webp [0 ].src })"
40
47
href ="https://opencollective.com/svelte" >{donor }</a
41
48
>
42
49
{/each }
86
93
}
87
94
88
95
.contributors .supporter {
89
- background-image : url (./contributors.jpg );
96
+ background-image : -webkit-image-set ( url (./contributors.jpg ) );
90
97
}
91
98
92
99
.donors .supporter {
93
- background-image : url (./donors.jpg );
100
+ background-image : -webkit-image-set ( url (./donors.jpg ) );
94
101
}
95
102
96
103
@media (min-width : 480px ) {
You can’t perform that action at this time.
0 commit comments