Skip to content

Commit

Permalink
Feat: 调整内容适配器副标题显示的内容
Browse files Browse the repository at this point in the history
  • Loading branch information
Lruihao committed Oct 3, 2024
1 parent 2fa4250 commit 5b1a6aa
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
7 changes: 6 additions & 1 deletion _content.gotmpl
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,11 @@
-}}
{{- $categories := $group.categories | default $projectsAdapters.categories -}}
{{- $collections := $group.collections | default $projectsAdapters.collections -}}
{{- $subtitle := T "projects.source" (dict
"Name" $repoInfo.full_name
"Link" $repoInfo.html_url
"Website" $repoInfo.homepage
) -}}
{{- $params := dict
"fromAdapters" "projects"
"author" $author
Expand All @@ -68,7 +73,7 @@
"lightgallery" true
"capitalizeTitles" false
"toc" (dict "ordered" false)
"subtitle" ($repoInfo.homepage | default $repoInfo.html_url)
"subtitle" $subtitle
"sourceURL" (add $readme.html_url "?plain=1")
"editURL" (replace $readme.html_url "/blob/" "/edit/" )
"LinkToReport" false
Expand Down
1 change: 1 addition & 0 deletions i18n/en.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
[projects]
relatedArticles = "Related Articles"
errorGetGhRepo = "failed to fetch repo info from GitHub API, Please check the network!"
source = "Source: [{{ .Name }}]({{ .Link }}){{ with .Website }}<br>Website: <{{ . }}>{{ end }}"
poweredBy = "This page is powered by <a href=\"https://github.com/hugo-fixit/component-projects\">Component Projects</a>."

[projects.totalStarCount]
Expand Down
1 change: 1 addition & 0 deletions i18n/zh-CN.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
[projects]
relatedArticles = "相关文章"
errorGetGhRepo = "从 GitHub API 获取仓库信息失败,请检查网络!"
source = "来源:[{{ .Name }}]({{ .Link }}){{ with .Website }}<br>网站:<{{ . }}>{{ end }}"
poweredBy = "本页面由 <a href=\"https://github.com/hugo-fixit/component-projects\">Component Projects</a> 强力驱动。"

[projects.totalStarCount]
Expand Down

0 comments on commit 5b1a6aa

Please sign in to comment.