Skip to content

Commit 0595275

Browse files
committed
fix sponsor style
1 parent b96d870 commit 0595275

File tree

1 file changed

+18
-3
lines changed

1 file changed

+18
-3
lines changed

docs/.vuepress/components/NormalPage.vue

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<NormalPage>
33
<template #contentBefore>
44
<div class="theme-hope-content ads-container">
5-
<div class="mingdao" v-if="!enableSidebar">
5+
<div class="mingdao" v-if="showMingdao">
66
<a href="https://www.mingdao.com?s=utm_51=utm_source=liteflow&utm_medium=banner&utm_campaign=%E5%93%81%E7%89%8C%E6%8E%A8%E5%B9%BF&utm_content=IT%E8%B5%8B%E8%83%BD%E4%B8%9A%E5%8A%A1"
77
target="_blank">
88
<img src="/img/ads/mingdao-h.png" alt="" />
@@ -13,6 +13,12 @@
1313
</div>
1414
</div>
1515
</template>
16+
<template #contentAfter>
17+
<div class="bottom-wwads">
18+
<div class="wwads wwads-cn wwads-horizontal" data-id="213" style="width:90% !important" v-if="showMingdao">
19+
</div>
20+
</div>
21+
</template>
1622
</NormalPage>
1723
</template>
1824
<script setup lang="ts">
@@ -25,8 +31,12 @@ const pageData = usePageData()
2531
2632
// get is enable sidebar from frontmatter
2733
const frontmatter = usePageFrontmatter();
28-
const enableSidebar = computed(() => {
29-
return frontmatter.value.sidebar === undefined ? true : frontmatter.value.sidebar;
34+
const showMingdao = computed(() => {
35+
if (pageData.value.path.startsWith("/tool/")) {
36+
return true;
37+
}
38+
const sidebar = frontmatter.value.sidebar;
39+
return sidebar === false;
3040
})
3141
3242
const spStr = computed(() => {
@@ -61,6 +71,11 @@ const spStr = computed(() => {
6171
}
6272
}
6373
74+
.bottom-wwads {
75+
display: flex;
76+
justify-content: center;
77+
margin-top: 20px;
78+
}
6479
.ads-container {
6580
padding-top: 0 !important;
6681
padding-bottom: 0 !important;

0 commit comments

Comments
 (0)