valaxy 0.24.2 → 0.24.4
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.
|
@@ -8,15 +8,17 @@ import { useSiteConfig } from '../../config'
|
|
|
8
8
|
import { tObject } from '../../utils'
|
|
9
9
|
|
|
10
10
|
export function useValaxyHead() {
|
|
11
|
-
const { locale } = useI18n()
|
|
11
|
+
const { locale, t } = useI18n()
|
|
12
12
|
|
|
13
13
|
const fm = useFrontmatter()
|
|
14
14
|
const siteConfig = useSiteConfig()
|
|
15
15
|
const $title = computed(() => tObject(fm.value.title || '', locale.value))
|
|
16
|
+
|
|
16
17
|
useHead({
|
|
17
18
|
title: $title,
|
|
18
19
|
titleTemplate: (title) => {
|
|
19
|
-
|
|
20
|
+
const siteTitle = t(siteConfig.value.title)
|
|
21
|
+
return fm.value.titleTemplate || (title ? `${title} - ${siteTitle}` : siteTitle)
|
|
20
22
|
},
|
|
21
23
|
link: [
|
|
22
24
|
{
|
|
@@ -37,8 +37,9 @@ export function useCollapseCode() {
|
|
|
37
37
|
const el = e.target as HTMLElement
|
|
38
38
|
if (el.matches('[class*="language-"] > button.collapse')) {
|
|
39
39
|
const parent = el.parentElement
|
|
40
|
-
parent?.removeAttribute('style')
|
|
41
40
|
parent?.classList.remove('folded')
|
|
41
|
+
const codeHeightLimitClass = `max-h-${codeHeightLimit}px`
|
|
42
|
+
parent?.classList.remove(codeHeightLimitClass)
|
|
42
43
|
}
|
|
43
44
|
})
|
|
44
45
|
|
package/dist/node/cli/index.js
CHANGED
package/dist/node/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "valaxy",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.24.
|
|
4
|
+
"version": "0.24.4",
|
|
5
5
|
"description": "📄 Vite & Vue powered static blog generator.",
|
|
6
6
|
"author": {
|
|
7
7
|
"email": "me@yunyoujun.cn",
|
|
@@ -132,8 +132,8 @@
|
|
|
132
132
|
"vue-i18n": "^11.1.9",
|
|
133
133
|
"vue-router": "^4.5.1",
|
|
134
134
|
"yargs": "^18.0.0",
|
|
135
|
-
"@valaxyjs/devtools": "0.24.
|
|
136
|
-
"@valaxyjs/utils": "0.24.
|
|
135
|
+
"@valaxyjs/devtools": "0.24.4",
|
|
136
|
+
"@valaxyjs/utils": "0.24.4"
|
|
137
137
|
},
|
|
138
138
|
"devDependencies": {
|
|
139
139
|
"@mdit-vue/plugin-component": "^2.1.4",
|