Files
blog/assets/scss/custom.scss
T
zhengchen.tao 9bbab6a135 init: Hugo + Stack 主题 + 首批 3 篇文章 + Gitea Actions 自动部署
- Stack 主题 + 自定义 padding 与标题样式 (assets/scss/custom.scss)
- 内容: HTTPS 旅程 / AI 工程师地图 / Xray Reality
- 页面: 首页 / 文章 / 归档 / 关于 / 搜索
- CI: Gitea Actions push → hugo --minify → rsync 到 NAS
  应用 Gitea Actions 模板 §4.4-4.5 经验: paths-ignore (注意不排除 **.md)
  + concurrency cancel-in-progress + summary
2026-05-03 15:56:04 +08:00

49 lines
1.2 KiB
SCSS

// 卡片 padding 比 Stack 默认 20/25/30 略宽一点,保证所有内容(含引用/code/图片)
// 都呆在 padding 内不顶到边
:root {
--card-padding: 24px;
}
@media (min-width: 768px) {
:root {
--card-padding: 28px;
}
}
@media (min-width: 1280px) {
:root {
--card-padding: 32px;
}
}
// 取消 Stack 默认的"标题 hanging 出 .article-content 左 padding"效果
// 让 H1-H6 的左竖线不再顶到卡片边框,留出呼吸空间
.article-content {
h1, h2, h3, h4, h5, h6 {
margin-inline-start: 0;
padding-inline-start: 0.6em;
// 锚点 # 浮在标题文字左外侧,避免和竖线重叠
a.header-anchor {
left: auto;
right: 100%;
width: 1.4em;
}
}
// 取消 Stack 默认让 blockquote / figure / code / table 等"独立块"用负 margin
// hanging 出卡片左右边缘的设计,让所有内容统一呆在 article-content 的 padding 内
blockquote,
figure,
.highlight,
pre,
.gallery,
.video-wrapper,
.table-wrapper,
.s_video_simple {
margin-left: 0;
margin-right: 0;
width: 100%;
}
}