style: 💄 优化赞助位样式

This commit is contained in:
不如摸鱼去 2025-09-21 19:54:27 +08:00
parent 9d1b2b0680
commit 50a286fb5f
6 changed files with 19 additions and 21 deletions

View File

@ -1,7 +1,7 @@
<!-- <!--
* @Author: weisheng * @Author: weisheng
* @Date: 2025-09-21 17:13:45 * @Date: 2025-09-21 17:13:45
* @LastEditTime: 2025-09-21 19:33:17 * @LastEditTime: 2025-09-21 19:53:54
* @LastEditors: weisheng * @LastEditors: weisheng
* @Description: * @Description:
* @FilePath: /wot-design-uni/docs/.vitepress/theme/components/AsideSponsors.vue * @FilePath: /wot-design-uni/docs/.vitepress/theme/components/AsideSponsors.vue
@ -30,6 +30,7 @@ const isGoldSponsorsOdd = computed(() => {
<template> <template>
<div class="VPDocAsideSponsors"> <div class="VPDocAsideSponsors">
<a class="sponsors-aside-text" href="/reward/sponsor">赞助位</a>
<div class="VPSponsors vp-sponsor aside"> <div class="VPSponsors vp-sponsor aside">
<!-- 超级赞助一行一个 --> <!-- 超级赞助一行一个 -->
<section class="vp-sponsor-section" v-if="superSponsors?.items.length"> <section class="vp-sponsor-section" v-if="superSponsors?.items.length">
@ -86,10 +87,6 @@ const isGoldSponsorsOdd = computed(() => {
</template> </template>
<style> <style>
.VPDocAsideSponsors{
margin-top: 12px;
}
.vp-sponsor-grid-text { .vp-sponsor-grid-text {
color: var(--vp-c-text-2); color: var(--vp-c-text-2);
font-size: 12px; font-size: 12px;
@ -98,4 +95,14 @@ const isGoldSponsorsOdd = computed(() => {
.dark .vp-sponsor-grid-text { .dark .vp-sponsor-grid-text {
color: var(--vp-c-gray-1); color: var(--vp-c-gray-1);
} }
a.sponsors-aside-text {
color: var(--vp-c-text-3);
display: block;
margin: 2em 0 1em;
font-weight: 700;
font-size: 11px;
text-transform: uppercase;
letter-spacing: 0.4px;
}
</style> </style>

View File

@ -1,7 +1,7 @@
/* /*
* @Author: weisheng * @Author: weisheng
* @Date: 2025-09-21 19:12:03 * @Date: 2025-09-21 19:12:03
* @LastEditTime: 2025-09-21 19:37:14 * @LastEditTime: 2025-09-21 19:52:54
* @LastEditors: weisheng * @LastEditors: weisheng
* @Description: * @Description:
* @FilePath: /wot-design-uni/docs/.vitepress/theme/composables/adSponsor.ts * @FilePath: /wot-design-uni/docs/.vitepress/theme/composables/adSponsor.ts
@ -38,7 +38,7 @@ export function useAdSponsor() {
const fetchData = async () => { const fetchData = async () => {
for (const url of urls) { for (const url of urls) {
try { try {
const response = await axios.get(url, { const response = await axios.get(url + '?t=' + Date.now(), {
timeout: 5000 // 设置5秒超时 timeout: 5000 // 设置5秒超时
}) })
return response?.data?.data // 成功获取数据后直接返回 return response?.data?.data // 成功获取数据后直接返回

View File

@ -21,7 +21,7 @@ export function useAds() {
const fetchData = async () => { const fetchData = async () => {
for (const url of urls) { for (const url of urls) {
try { try {
const response = await axios.get(url, { const response = await axios.get(url + '?t=' + Date.now(), {
timeout: 5000 // 设置5秒超时 timeout: 5000 // 设置5秒超时
}) })
return response.data && response.data.ads ? response.data.ads : [] // 成功获取数据后直接返回 return response.data && response.data.ads ? response.data.ads : [] // 成功获取数据后直接返回

View File

@ -1,7 +1,7 @@
/* /*
* @Author: weisheng * @Author: weisheng
* @Date: 2025-08-30 13:06:10 * @Date: 2025-08-30 13:06:10
* @LastEditTime: 2025-09-21 15:07:39 * @LastEditTime: 2025-09-21 19:53:02
* @LastEditors: weisheng * @LastEditors: weisheng
* @Description: * @Description:
* @FilePath: /wot-design-uni/docs/.vitepress/theme/composables/cases.ts * @FilePath: /wot-design-uni/docs/.vitepress/theme/composables/cases.ts
@ -31,7 +31,7 @@ export function useCaseData() {
for (const url of urls) { for (const url of urls) {
try { try {
const path = '/cases.json' const path = '/cases.json'
const response = await axios.get(url + path, { const response = await axios.get(url + path + '?t=' + Date.now(), {
timeout: 5000 // 设置5秒超时 timeout: 5000 // 设置5秒超时
}) })
const data = response.data && response.data.data ? response.data.data : [] const data = response.data && response.data.data ? response.data.data : []

View File

@ -26,7 +26,7 @@ export function useFriendly() {
const fetchData = async () => { const fetchData = async () => {
for (const url of urls) { for (const url of urls) {
try { try {
const response = await axios.get(url, { const response = await axios.get(url + '?t=' + Date.now(), {
timeout: 5000 // 设置5秒超时 timeout: 5000 // 设置5秒超时
}) })
return response.data && response.data.links ? response.data.links : [] // 成功获取数据后直接返回 return response.data && response.data.links ? response.data.links : [] // 成功获取数据后直接返回

View File

@ -1,12 +1,3 @@
/*
* @Author: weisheng
* @Date: 2025-09-21 15:01:29
* @LastEditTime: 2025-09-21 18:00:09
* @LastEditors: weisheng
* @Description:
* @FilePath: /wot-design-uni/docs/.vitepress/theme/composables/sponsor.ts
*
*/
import { ref, onMounted } from 'vue' import { ref, onMounted } from 'vue'
import axios from 'axios' import axios from 'axios'
@ -29,7 +20,7 @@ export function useSponsor() {
const fetchData = async () => { const fetchData = async () => {
for (const url of urls) { for (const url of urls) {
try { try {
const response = await axios.get(url, { const response = await axios.get(url + '?t=' + Date.now(), {
timeout: 5000 // 设置5秒超时 timeout: 5000 // 设置5秒超时
}) })
return response.data // 成功获取数据后直接返回 return response.data // 成功获取数据后直接返回