valaxy-theme-yun 0.14.25 → 0.14.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,38 +1,47 @@
1
1
  <script lang="ts" setup>
2
2
  import { useSiteConfig } from 'valaxy'
3
- import { ref } from 'vue'
3
+ import { computed, ref } from 'vue'
4
4
  import { useI18n } from 'vue-i18n'
5
5
 
6
6
  const { t } = useI18n()
7
7
 
8
8
  const siteConfig = useSiteConfig()
9
9
  const showQr = ref(false)
10
+ const sponsorBtnTitle = computed(() => {
11
+ return siteConfig.value.sponsor?.title ?? t('reward.donate')
12
+ })
10
13
  </script>
11
14
 
12
15
  <template>
13
16
  <div class="yun-sponsor-container flex-center flex-col">
14
17
  <button
15
18
  class="sponsor-button yun-icon-btn shadow hover:shadow-md"
16
- :title="t('reward.donate')" text="red-400" @click="showQr = !showQr"
19
+ :title="sponsorBtnTitle" text="red-400" @click="showQr = !showQr"
17
20
  >
18
21
  <div i-ri-heart-line />
19
22
  </button>
20
23
 
21
- <div class="qrcode-container qrcode flex justify-around" m="y-4" :class="showQr && 'show'">
22
- <a
23
- v-for="method, i in siteConfig.sponsor.methods" :key="i"
24
- class="flex-center flex-col animate-iteration-1 animate-fade-in"
25
- :href="method.url" target="_blank"
26
- :style="`color:${method.color}`"
27
- >
28
- <img class="sponsor-method-img" border="~ rounded" p="1" loading="lazy" :src="method.url" :title="method.name">
29
- <div text="xl" m="2" :class="method.icon" />
30
- </a>
24
+ <div class="qrcode-container qrcode flex-center flex-col" m="y-4" :class="showQr && 'show'">
25
+ <div v-if="siteConfig.sponsor.description" class="sponsor-description" mb="4" text="sm">
26
+ {{ siteConfig.sponsor.description }}
27
+ </div>
28
+ <div class="flex justify-around">
29
+ <a
30
+ v-for="method, i in siteConfig.sponsor.methods" :key="i"
31
+ class="flex-center flex-col animate-iteration-1 animate-fade-in"
32
+ :href="method.url" target="_blank"
33
+ :style="`color:${method.color}`"
34
+ >
35
+ <img class="sponsor-method-img" border="~ rounded" p="1" loading="lazy" :src="method.url" :title="method.name">
36
+ <div text="xl" m="2" :class="method.icon" />
37
+ </a>
38
+ </div>
31
39
  </div>
32
40
  </div>
33
41
  </template>
34
42
 
35
43
  <style lang="scss">
44
+ @use "valaxy/client/styles/mixins" as *;
36
45
  .sponsor-button {
37
46
  background-color: rgba(255, 255, 255, 0.1);
38
47
 
@@ -62,10 +71,14 @@ const showQr = ref(false)
62
71
  transition: height var(--va-transition-duration) ease-in-out;
63
72
 
64
73
  &.show {
65
- height: 220px;
74
+ height: 260px;
66
75
  }
67
76
  }
68
77
 
78
+ .sponsor-description {
79
+ color: get-css-var('c-gray');
80
+ }
81
+
69
82
  .sponsor-method-img {
70
83
  width: 12rem;
71
84
  max-width: 90%;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "valaxy-theme-yun",
3
- "version": "0.14.25",
3
+ "version": "0.14.26",
4
4
  "author": {
5
5
  "email": "me@yunyoujun.cn",
6
6
  "name": "YunYouJun",
@@ -18,12 +18,12 @@
18
18
  "types": "types/index.d.ts",
19
19
  "dependencies": {
20
20
  "@iconify-json/ant-design": "^1.1.5",
21
- "@iconify-json/simple-icons": "^1.1.48",
21
+ "@iconify-json/simple-icons": "^1.1.49",
22
22
  "animejs": "^3.2.1",
23
23
  "valaxy-addon-waline": "0.1.0"
24
24
  },
25
25
  "devDependencies": {
26
26
  "@types/animejs": "^3.1.7",
27
- "valaxy": "0.14.25"
27
+ "valaxy": "0.14.26"
28
28
  }
29
29
  }