<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0"
  xmlns:atom="http://www.w3.org/2005/Atom"
  xmlns:content="http://purl.org/rss/1.0/modules/content/"
  xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Lightbox - Pocket Hugo</title>
    <link>https://theme.leftn.com/zh-cn/tags/lightbox/</link>
    <description>Lightbox</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>zh-cn</language>
    <lastBuildDate>Mon, 20 Apr 2026 02:51:39 &#43;0000</lastBuildDate>
    <atom:link href="https://theme.leftn.com/zh-cn/tags/lightbox/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>响应式图片管线演示</title>
      <link>https://theme.leftn.com/zh-cn/article/responsive-image-pipeline/</link>
      <pubDate>Sat, 21 Mar 2026 01:00:00 &#43;0000</pubDate>
      <guid>https://theme.leftn.com/zh-cn/article/responsive-image-pipeline/</guid>
      <description>一篇用于检查派生图片尺寸、正文内联显示和内置灯箱效果的示例文章。</description>
      <content:encoded><![CDATA[<p>这篇文章演示主题对正文 Markdown 图片的<strong>响应式图片管线</strong>支持。同一张源图会在正文中按布局规则显示，同时仍然可以在灯箱中查看更大的版本。</p>
<h2 id="正文图片测试">正文图片测试</h2>
<p><figure class="article-image">
    <a class="article-image__link" href="/article/responsive-image-pipeline/cover.webp" data-lightbox-image>
        <img
            src="/article/responsive-image-pipeline/cover_hu_891a2c2ed3e28888.webp"
            alt="岳麓书院"
            loading="lazy"
            decoding="async"
            srcset="/article/responsive-image-pipeline/cover_hu_cff19abd5b070e14.webp 640w, /article/responsive-image-pipeline/cover_hu_891a2c2ed3e28888.webp 960w"
            sizes="100vw"
            width="1080"
            height="464"
            
        >
    </a>
    
</figure>
</p>
<p><figure class="article-image">
    <a class="article-image__link" href="/article/responsive-image-pipeline/guangzhou.webp" data-lightbox-image>
        <img
            src="/article/responsive-image-pipeline/guangzhou_hu_e1e939e85e40728a.webp"
            alt="广州"
            loading="lazy"
            decoding="async"
            srcset="/article/responsive-image-pipeline/guangzhou_hu_982af0487a09f27b.webp 640w, /article/responsive-image-pipeline/guangzhou_hu_e1e939e85e40728a.webp 960w"
            sizes="100vw"
            width="1080"
            height="691"
            
        >
    </a>
    
</figure>
</p>
<p><figure class="article-image">
    <a class="article-image__link" href="/article/responsive-image-pipeline/writing.webp" data-lightbox-image>
        <img
            src="/article/responsive-image-pipeline/writing_hu_d0f50a54ee4873ff.webp"
            alt="写作"
            loading="lazy"
            decoding="async"
            srcset="/article/responsive-image-pipeline/writing_hu_7d0824451caa5ad9.webp 640w, /article/responsive-image-pipeline/writing_hu_d0f50a54ee4873ff.webp 960w"
            sizes="100vw"
            width="1080"
            height="595"
            
        >
    </a>
    
</figure>
</p>
<p>这代表了网页里图片的默认显示行为。如果你想调整图片显示高度，可以在 <code>hugo.toml</code> 中配置；如果不需要这一功能，也可以直接通过 <code>limitHeight = false</code> 关闭。</p>
<div class="highlight"><pre tabindex="0" class="chroma"><code class="language-toml" data-lang="toml"><span class="line"><span class="cl">  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">images</span><span class="p">.</span><span class="nx">content</span><span class="p">]</span>
</span></span><span class="line"><span class="cl">    <span class="nx">mobileMaxHeight</span> <span class="p">=</span> <span class="s2">&#34;160px&#34;</span>
</span></span><span class="line"><span class="cl">    <span class="nx">tabletMaxHeight</span> <span class="p">=</span> <span class="s2">&#34;250px&#34;</span>
</span></span><span class="line"><span class="cl">    <span class="nx">desktopMaxHeight</span> <span class="p">=</span> <span class="s2">&#34;350px&#34;</span></span></span></code></pre></div><p>这篇文章可以和 <a href="/article/image-config-reference/">图片配置参考</a>
 对照阅读；后者更专注于文章头图和卡片封面的设置。</p>]]></content:encoded>
    </item>
  </channel>
</rss>
