2022-03-01 23:07:58 +08:00
|
|
|
<script setup lang="ts">
|
|
|
|
import { isDark } from '../composables/dark'
|
2022-04-02 12:54:03 +08:00
|
|
|
import { goldSponsors } from '../../config/sponsors'
|
2022-03-01 23:07:58 +08:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<template>
|
2022-04-03 17:28:59 +08:00
|
|
|
<div class="sponsor-container">
|
|
|
|
<a
|
2022-04-02 12:54:03 +08:00
|
|
|
v-for="item in goldSponsors"
|
2022-03-01 23:07:58 +08:00
|
|
|
:key="item.name"
|
2022-04-03 17:28:59 +08:00
|
|
|
:class="[
|
|
|
|
'sponsor-item inline-flex items-center',
|
|
|
|
item.isDark && isDark ? 'filter invert' : '',
|
|
|
|
]"
|
|
|
|
:href="item.url"
|
|
|
|
:title="`${item.name_cn || item.name} - ${item.slogan_cn || item.slogan}`"
|
|
|
|
target="_blank"
|
2022-03-01 23:07:58 +08:00
|
|
|
>
|
2022-04-03 17:28:59 +08:00
|
|
|
<img :src="item.img" :alt="item.name" />
|
|
|
|
</a>
|
2022-03-01 23:07:58 +08:00
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<style scoped lang="scss">
|
2022-04-03 18:05:21 +08:00
|
|
|
@use '../styles/mixins' as *;
|
2022-04-03 17:28:59 +08:00
|
|
|
.sponsor-container {
|
2022-03-01 23:07:58 +08:00
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
|
|
|
.sponsor-item {
|
|
|
|
margin-right: 4px;
|
2022-04-03 16:59:06 +08:00
|
|
|
height: 36px;
|
|
|
|
width: 36px;
|
2022-03-01 23:07:58 +08:00
|
|
|
|
2022-04-04 12:07:33 +08:00
|
|
|
@include respond-to('max') {
|
2022-04-03 18:05:21 +08:00
|
|
|
height: 44px;
|
|
|
|
width: 44px;
|
|
|
|
}
|
|
|
|
|
2022-04-05 10:21:14 +08:00
|
|
|
@media (max-width: 767px) {
|
|
|
|
width: 44px;
|
|
|
|
height: 44px;
|
|
|
|
}
|
|
|
|
|
2022-04-03 16:59:06 +08:00
|
|
|
img {
|
|
|
|
height: 100%;
|
|
|
|
width: 100%;
|
2022-03-01 23:07:58 +08:00
|
|
|
}
|
|
|
|
}
|
2022-04-04 01:30:47 +08:00
|
|
|
|
|
|
|
@include respond-to('xs') {
|
|
|
|
width: 196px;
|
|
|
|
}
|
2022-03-01 23:07:58 +08:00
|
|
|
}
|
|
|
|
</style>
|