1
0
Fork 0

refine code

This commit is contained in:
nanxiaobei 2021-08-24 10:14:27 +08:00
parent e5050d8bc4
commit e8237eaf14
2 changed files with 3 additions and 3 deletions

View file

@ -221,7 +221,7 @@ img {
.social a {
width: 3rem;
margin-left: 3rem;
background: var(--img) center center no-repeat;
background: var(--url) center center no-repeat;
}
.dark .social a {

View file

@ -31,7 +31,7 @@
buttonDark.addEventListener('click', () => {
bodyClass.contains('dark') ? setLight() : setDark();
});
schemeDark.addEventListener('change', event => {
schemeDark.addEventListener('change', (event) => {
event.matches ? setDark() : setLight();
});
</script>
@ -50,7 +50,7 @@
{{ range $key, $val := . }}
<a
class="{{ $key }}"
style="--img: url(./{{ printf `%s.svg` $key }})"
style="--url: url(./{{ printf `%s.svg` $key }})"
href="https://{{ $key }}.com/{{ $val }}"
target="_blank"
></a>