gpt4 book ai didi

css - 更改HUGO-Xmin主题中帖子标题的行高

转载 作者:行者123 更新时间:2023-11-28 09:43:30 25 4
gpt4 key购买 nike

有了R blogdown包,搭建个人网站变得轻而易举。我喜欢 yihui/hugo-xmin 的风格主题的简单性。我在 Windows 操作系统上的文件夹“c:/test”中使用 R blogdown 包构建了一个站点:

install.packages('blogdown')
setwd('c:/test')
blogdown::new_site(theme='yihui/hugo-xmin')

然后我将以下文本写入 c:/test/content/post/ 文件夹中的 .md 文件中:

---
title: "Summer Holiday in Southern France (VIII): Return to Nice (Videos) 带着俩娃游南法 (第十天): 重返尼斯 (视频)"
author: dapeng
date: "2017-08-17 15:22:06"
slug: summer-holiday-in-southern-france-viii-return-to-nice-videos
categories: [cn]
tags:
- cn
---

my text.

然后我预览了网站:

blogdown::serve_site()

但是,帖子标题看起来像这样:

enter image description here

我想知道如何更改标题中的行高,默认情况下它太小了。我在 /themes/hugo-xmin/static/css/style.css 中添加了一个 line-height 命令,如下所示:

.menu, .article-meta, footer { text-align: center; }
.title { font-size: 1.1em; }
footer a { text-decoration: none; }
hr {
border-style: dashed;
line-height: 5em;
color: #ddd;
}

但是没有用。

感谢您的帮助!

最佳答案

标题不在<hr>中标记但是<h1> .在你的 CSS 中添加这样的东西应该会增加行高:

h1 { line-height: 1.2em; }

我推荐你学习use the Developer Tools of your web browser .

关于css - 更改HUGO-Xmin主题中帖子标题的行高,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47138985/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com