<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="zh-Hans-CN">
	<id>https://zh.postal.wiki/index.php?action=history&amp;feed=atom&amp;title=%E7%94%A8%E6%88%B7%3AHehua%2Ffilepreview.js</id>
	<title>用户:Hehua/filepreview.js - 版本历史</title>
	<link rel="self" type="application/atom+xml" href="https://zh.postal.wiki/index.php?action=history&amp;feed=atom&amp;title=%E7%94%A8%E6%88%B7%3AHehua%2Ffilepreview.js"/>
	<link rel="alternate" type="text/html" href="https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;action=history"/>
	<updated>2026-09-21T00:45:18Z</updated>
	<subtitle>本wiki上该页面的版本历史</subtitle>
	<generator>MediaWiki 1.43.9</generator>
	<entry>
		<id>https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5196&amp;oldid=prev</id>
		<title>Hehua：​[IPE-NEXT] Quick edit</title>
		<link rel="alternate" type="text/html" href="https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5196&amp;oldid=prev"/>
		<updated>2026-07-23T07:07:26Z</updated>

		<summary type="html">&lt;p&gt;[IPE-NEXT] Quick edit&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;zh-Hans-CN&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;←上一版本&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;2026年7月23日 (四) 07:07的版本&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l19&quot;&gt;第19行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第19行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         var CONFIG = {&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         var CONFIG = {&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             delay: 400,&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             delay: 400,&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            thumbWidth: 220,&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             maxPopupWidth: 480,&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             maxPopupWidth: 480,&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             maxPopupHeight: 540&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             maxPopupHeight: 540&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l108&quot;&gt;第108行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第107行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 tllimit: 50,&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 tllimit: 50,&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 iiprop: &amp;#039;url|size|user|comment|timestamp|extmetadata&amp;#039;,&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 iiprop: &amp;#039;url|size|user|comment|timestamp|extmetadata&amp;#039;,&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                iiurlwidth: CONFIG.thumbWidth,&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 format: &amp;#039;json&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 format: &amp;#039;json&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             });&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             });&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l124&quot;&gt;第124行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第122行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var ii = page.imageinfo &amp;amp;&amp;amp; page.imageinfo[0];&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var ii = page.imageinfo &amp;amp;&amp;amp; page.imageinfo[0];&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             if (ii) {&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             if (ii) {&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                if (ii.thumburl) {&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                    parts.push(&#039;&amp;lt;div style=&quot;text-align:center;margin-bottom:8px;&quot;&amp;gt;&amp;lt;a href=&quot;&#039; + esc(ii.url) + &#039;&quot; target=&quot;_blank&quot;&amp;gt;&#039; +&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                        &#039;&amp;lt;img src=&quot;&#039; + esc(ii.thumburl) + &#039;&quot; alt=&quot;&quot; style=&quot;max-width:100%;border:1px solid #eaecf0;border-radius:3px;&quot;&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/div&amp;gt;&#039;);&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                }&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 var meta = [];&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 var meta = [];&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 if (ii.width &amp;amp;&amp;amp; ii.height) meta.push(ii.width + &amp;#039;\u00d7&amp;#039; + ii.height + &amp;#039; (&amp;#039; + fmtBytes(ii.size) + &amp;#039;)&amp;#039;);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 if (ii.width &amp;amp;&amp;amp; ii.height) meta.push(ii.width + &amp;#039;\u00d7&amp;#039; + ii.height + &amp;#039; (&amp;#039; + fmtBytes(ii.size) + &amp;#039;)&amp;#039;);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key wiki:diff:1.41:old-5195:rev-5196:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>Hehua</name></author>
	</entry>
	<entry>
		<id>https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5195&amp;oldid=prev</id>
		<title>Hehua：​[IPE-NEXT] Quick edit</title>
		<link rel="alternate" type="text/html" href="https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5195&amp;oldid=prev"/>
		<updated>2026-07-23T07:04:54Z</updated>

		<summary type="html">&lt;p&gt;[IPE-NEXT] Quick edit&lt;/p&gt;
&lt;a href=&quot;https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;amp;diff=5195&amp;amp;oldid=5194&quot;&gt;显示更改&lt;/a&gt;</summary>
		<author><name>Hehua</name></author>
	</entry>
	<entry>
		<id>https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5194&amp;oldid=prev</id>
		<title>Hehua：​[IPE-NEXT] Quick edit</title>
		<link rel="alternate" type="text/html" href="https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5194&amp;oldid=prev"/>
		<updated>2026-07-23T07:01:10Z</updated>

		<summary type="html">&lt;p&gt;[IPE-NEXT] Quick edit&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;zh-Hans-CN&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;←上一版本&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;2026年7月23日 (四) 07:01的版本&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l84&quot;&gt;第84行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第84行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         }&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         var fileNSNames = getFileNSNames();&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         var fileNSNames = getFileNSNames();&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         var fileNSRe = new RegExp(&#039;^(&#039; + fileNSNames.map(function(n) { return n.replace(/[.*+?^${}()|[\]\\]/g, &#039;\\$&amp;amp;&#039;); }).join(&#039;|&#039;) + &#039;):&#039;, &#039;i&#039;);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         var fileNSRe = new RegExp(&#039;^(&#039; + fileNSNames.map(function(n) { return n.replace(/[.*+?^${}()|[\]\\]/g, &#039;\\$&amp;amp;&#039;); }).join(&#039;|&#039;) + &#039;):&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;(.+)$&lt;/ins&gt;&#039;, &#039;i&#039;);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         /* ---------- api + render ---------- */&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         /* ---------- api + render ---------- */&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key wiki:diff:1.41:old-5193:rev-5194:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>Hehua</name></author>
	</entry>
	<entry>
		<id>https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5193&amp;oldid=prev</id>
		<title>Hehua：​[IPE-NEXT] Quick edit</title>
		<link rel="alternate" type="text/html" href="https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5193&amp;oldid=prev"/>
		<updated>2026-07-23T06:59:07Z</updated>

		<summary type="html">&lt;p&gt;[IPE-NEXT] Quick edit&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;zh-Hans-CN&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;←上一版本&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;2026年7月23日 (四) 06:59的版本&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l186&quot;&gt;第186行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第186行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 clearTimeout(state.hideTimer);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 clearTimeout(state.hideTimer);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 var title = getFileTitle(link);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 var title = getFileTitle(link);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 if (!title) return;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 if (!title) &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                    console.log(&#039;[FilePreview] 无法提取标题, title属性:&#039;, link.getAttribute(&#039;title&#039;));&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                    &lt;/ins&gt;return&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                }&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                console.log(&#039;[FilePreview] 请求:&#039;, title)&lt;/ins&gt;;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 var x = e.clientX, y = e.clientY;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 var x = e.clientX, y = e.clientY;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 state.fetchTimer = setTimeout(function () {&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 state.fetchTimer = setTimeout(function () {&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                     showPopup(link, x, y, &amp;#039;&amp;lt;div style=&amp;quot;color:#888;&amp;quot;&amp;gt;\u52a0\u8f7d\u4e2d\u2026 &amp;#039; + esc(title) + &amp;#039;&amp;lt;/div&amp;gt;&amp;#039;);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                     showPopup(link, x, y, &amp;#039;&amp;lt;div style=&amp;quot;color:#888;&amp;quot;&amp;gt;\u52a0\u8f7d\u4e2d\u2026 &amp;#039; + esc(title) + &amp;#039;&amp;lt;/div&amp;gt;&amp;#039;);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                     fetchData(title).then(function (d) { render(d, link, x, y); })&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                     fetchData(title).then(function (d) {&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                        &lt;/del&gt;.catch(function (err) { showPopup(link, x, y, &#039;&amp;lt;div style=&quot;color:#c00;&quot;&amp;gt;\u5931\&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;u8d25&lt;/del&gt;: &#039; + esc(String(err)) + &#039;&amp;lt;/div&amp;gt;&#039;); });&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                        console.log(&#039;[FilePreview] API返回:&#039;, JSON.stringify(d).slice(0, 300));&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                        &lt;/ins&gt;render(d, link, x, y);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                    &lt;/ins&gt;}).catch(function (err) {&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                        console.log(&#039;[FilePreview] API错误:&#039;, err);&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                        &lt;/ins&gt;showPopup(link, x, y, &#039;&amp;lt;div style=&quot;color:#c00;&quot;&amp;gt;\u5931\&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;u8d95&lt;/ins&gt;: &#039; + esc(String(err)) + &#039;&amp;lt;/div&amp;gt;&#039;);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;                    &lt;/ins&gt;});&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 }, CONFIG.delay);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;                 }, CONFIG.delay);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             });&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             });&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key wiki:diff:1.41:old-5192:rev-5193:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>Hehua</name></author>
	</entry>
	<entry>
		<id>https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5192&amp;oldid=prev</id>
		<title>2026年7月23日 (四) 06:54 Hehua</title>
		<link rel="alternate" type="text/html" href="https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5192&amp;oldid=prev"/>
		<updated>2026-07-23T06:54:42Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;zh-Hans-CN&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;←上一版本&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;2026年7月23日 (四) 06:54的版本&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l73&quot;&gt;第73行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第73行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             if (state.popup) state.popup.style.display = &amp;#039;none&amp;#039;;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             if (state.popup) state.popup.style.display = &amp;#039;none&amp;#039;;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         }&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        /* ---------- localized namespace ---------- */&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        function getFileNSNames() {&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            var names = [&#039;File&#039;, &#039;Image&#039;];&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            var fmt = mw.config.get(&#039;wgFormattedNamespaces&#039;) || {};&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            if (fmt[6] &amp;amp;&amp;amp; names.indexOf(fmt[6]) === -1) names.push(fmt[6]);&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            var aliases = mw.config.get(&#039;wgNamespaceAliases&#039;) || {};&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            for (var a in aliases) { if (aliases[a] === 6 &amp;amp;&amp;amp; names.indexOf(a) === -1) names.push(a); }&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            return names;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        }&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        var fileNSNames = getFileNSNames();&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        var fileNSRe = new RegExp(&#039;^(&#039; + fileNSNames.map(function(n) { return n.replace(/[.*+?^${}()|[\]\\]/g, &#039;\\$&amp;amp;&#039;); }).join(&#039;|&#039;) + &#039;):&#039;, &#039;i&#039;);&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         /* ---------- api + render ---------- */&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         /* ---------- api + render ---------- */&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l84&quot;&gt;第84行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第96行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         function getFileTitle(link) {&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         function getFileTitle(link) {&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var t = link.getAttribute(&amp;#039;title&amp;#039;) || &amp;#039;&amp;#039;;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var t = link.getAttribute(&amp;#039;title&amp;#039;) || &amp;#039;&amp;#039;;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var m = t.match(&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;/^(File|Image):(.+)$/i&lt;/del&gt;);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var m = t.match(&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;fileNSRe&lt;/ins&gt;);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             if (m) return &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;m[1] + &lt;/del&gt;&#039;:&#039; + m[2];&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             if (m) return &#039;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;File&lt;/ins&gt;:&#039; + m[2];&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var h = link.getAttribute(&amp;#039;href&amp;#039;) || &amp;#039;&amp;#039;;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var h = link.getAttribute(&amp;#039;href&amp;#039;) || &amp;#039;&amp;#039;;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             m = h.match(/[?&amp;amp;]title=(File|Image):([^&amp;amp;]+)/);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             m = h.match(/[?&amp;amp;]title=(File|Image):([^&amp;amp;]+)/);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             if (m) return &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;m[1] + &lt;/del&gt;&#039;:&#039; + decodeURIComponent(m[2].replace(/\+/g, &#039; &#039;));&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             if (m) return &#039;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;File&lt;/ins&gt;:&#039; + decodeURIComponent(m[2].replace(/\+/g, &#039; &#039;));&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             return null;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             return null;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        }&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        function isFileLink(link) {&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            if (!link) return false;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            var title = link.getAttribute(&#039;title&#039;) || &#039;&#039;;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            if (fileNSRe.test(title)) return true;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            var href = link.href || &#039;&#039;;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            if (/\/wiki\/(File|Image):/i.test(href) || /[?&amp;amp;]title=(File|Image):/i.test(href)) return true;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            return false;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         }&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l182&quot;&gt;第182行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第202行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         function scanLinks() {&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         function scanLinks() {&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;links &lt;/del&gt;= &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;document&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;querySelectorAll&lt;/del&gt;(&#039;a[title^=&quot;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;File&lt;/del&gt;:&quot;], &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;a[title^&lt;/del&gt;=&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&quot;Image:&quot;]&#039;&lt;/del&gt;);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             var &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;sel &lt;/ins&gt;= &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;fileNSNames&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;map(function &lt;/ins&gt;(&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;n) { return &lt;/ins&gt;&#039;a[title^=&quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&#039; + n + &#039;&lt;/ins&gt;:&quot;]&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&#039;; }).join(&#039;&lt;/ins&gt;,&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&#039;);&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             console.log(&#039;[FilePreview] 找到 &#039; &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;+ &lt;/del&gt;links.length &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;+ &#039; 个文件链接&#039;&lt;/del&gt;);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            var links &lt;/ins&gt;= &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;document.querySelectorAll(sel&lt;/ins&gt;);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             console.log(&#039;[FilePreview] &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;命名空间名:&#039;, JSON.stringify(fileNSNames), &#039;选择器:&#039;, sel, &#039;&lt;/ins&gt;找到&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;:&lt;/ins&gt;&#039;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;, &lt;/ins&gt;links.length);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             links.forEach(bindLink);&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;             links.forEach(bindLink);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         }&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key wiki:diff:1.41:old-5191:rev-5192:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>Hehua</name></author>
	</entry>
	<entry>
		<id>https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5191&amp;oldid=prev</id>
		<title>2026年7月23日 (四) 06:43 Hehua</title>
		<link rel="alternate" type="text/html" href="https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5191&amp;oldid=prev"/>
		<updated>2026-07-23T06:43:52Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;a href=&quot;https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;amp;diff=5191&amp;amp;oldid=5189&quot;&gt;显示更改&lt;/a&gt;</summary>
		<author><name>Hehua</name></author>
	</entry>
	<entry>
		<id>https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5189&amp;oldid=prev</id>
		<title>2026年7月23日 (四) 06:37 Hehua</title>
		<link rel="alternate" type="text/html" href="https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5189&amp;oldid=prev"/>
		<updated>2026-07-23T06:37:48Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;a href=&quot;https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;amp;diff=5189&amp;amp;oldid=5187&quot;&gt;显示更改&lt;/a&gt;</summary>
		<author><name>Hehua</name></author>
	</entry>
	<entry>
		<id>https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5187&amp;oldid=prev</id>
		<title>Hehua：​创建页面，内容为“/**  * FilePreview — 文件链接悬停预览脚本  * 鼠标悬停在 File: 蓝色链接上时，弹出浮窗显示：  *   - 缩略图预览  *   - 文件信息（尺寸、大小、上传者）  *   - 分类 (categories)  *   - 版权/许可模板 (templates)  *  * 安装方式：将本脚本的内容复制到你的  *   User:&lt;你的名字&gt;/common.js 或 MediaWiki:Common.js  * 或通过 importScript 引入。  */ mw.loader.using([&#039;mediawiki.api&#039;, &#039;mediawiki…”</title>
		<link rel="alternate" type="text/html" href="https://zh.postal.wiki/index.php?title=%E7%94%A8%E6%88%B7:Hehua/filepreview.js&amp;diff=5187&amp;oldid=prev"/>
		<updated>2026-07-23T06:29:08Z</updated>

		<summary type="html">&lt;p&gt;创建页面，内容为“&lt;span class=&quot;autocomment&quot;&gt;*  * FilePreview — 文件链接悬停预览脚本  * 鼠标悬停在 File: 蓝色链接上时，弹出浮窗显示：  *   - 缩略图预览  *   - 文件信息（尺寸、大小、上传者）  *   - 分类 (categories)  *   - 版权/许可模板 (templates)  *  * 安装方式：将本脚本的内容复制到你的  *   User:&amp;lt;你的名字&amp;gt;/common.js 或 MediaWiki:Common.js  * 或通过 importScript 引入。：​&lt;/span&gt; mw.loader.using([&amp;#039;mediawiki.api&amp;#039;, &amp;#039;mediawiki…”&lt;/p&gt;
&lt;p&gt;&lt;b&gt;新页面&lt;/b&gt;&lt;/p&gt;&lt;div&gt;/**&lt;br /&gt;
 * FilePreview — 文件链接悬停预览脚本&lt;br /&gt;
 * 鼠标悬停在 File: 蓝色链接上时，弹出浮窗显示：&lt;br /&gt;
 *   - 缩略图预览&lt;br /&gt;
 *   - 文件信息（尺寸、大小、上传者）&lt;br /&gt;
 *   - 分类 (categories)&lt;br /&gt;
 *   - 版权/许可模板 (templates)&lt;br /&gt;
 *&lt;br /&gt;
 * 安装方式：将本脚本的内容复制到你的&lt;br /&gt;
 *   User:&amp;lt;你的名字&amp;gt;/common.js 或 MediaWiki:Common.js&lt;br /&gt;
 * 或通过 importScript 引入。&lt;br /&gt;
 */&lt;br /&gt;
mw.loader.using([&amp;#039;mediawiki.api&amp;#039;, &amp;#039;mediawiki.util&amp;#039;]).then(function () {&lt;br /&gt;
    &amp;#039;use strict&amp;#039;;&lt;br /&gt;
&lt;br /&gt;
    var CONFIG = {&lt;br /&gt;
        delay: 400,         // 悬停延迟 (ms)&lt;br /&gt;
        thumbWidth: 220,    // 缩略图宽度&lt;br /&gt;
        maxPopupWidth: 460,&lt;br /&gt;
        maxPopupHeight: 520&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    /* ---------- state ---------- */&lt;br /&gt;
    var state = {&lt;br /&gt;
        link: null,&lt;br /&gt;
        fetchTimer: null,&lt;br /&gt;
        hideTimer: null,&lt;br /&gt;
        popup: null&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    /* ---------- popup DOM ---------- */&lt;br /&gt;
    function getPopup() {&lt;br /&gt;
        if (!state.popup) {&lt;br /&gt;
            var el = document.createElement(&amp;#039;div&amp;#039;);&lt;br /&gt;
            el.id = &amp;#039;filepreview-popup&amp;#039;;&lt;br /&gt;
            el.style.cssText = [&lt;br /&gt;
                &amp;#039;display:none&amp;#039;,&lt;br /&gt;
                &amp;#039;position:fixed&amp;#039;,&lt;br /&gt;
                &amp;#039;z-index:9999&amp;#039;,&lt;br /&gt;
                &amp;#039;background:#fff&amp;#039;,&lt;br /&gt;
                &amp;#039;border:1px solid #c8ccd1&amp;#039;,&lt;br /&gt;
                &amp;#039;border-radius:6px&amp;#039;,&lt;br /&gt;
                &amp;#039;box-shadow:0 4px 16px rgba(0,0,0,0.2)&amp;#039;,&lt;br /&gt;
                &amp;#039;padding:14px&amp;#039;,&lt;br /&gt;
                &amp;#039;max-width:&amp;#039; + CONFIG.maxPopupWidth + &amp;#039;px&amp;#039;,&lt;br /&gt;
                &amp;#039;max-height:&amp;#039; + CONFIG.maxPopupHeight + &amp;#039;px&amp;#039;,&lt;br /&gt;
                &amp;#039;overflow-y:auto&amp;#039;,&lt;br /&gt;
                &amp;#039;font:13px/1.5 sans-serif&amp;#039;,&lt;br /&gt;
                &amp;#039;color:#222&amp;#039;,&lt;br /&gt;
                &amp;#039;pointer-events:auto&amp;#039;&lt;br /&gt;
            ].join(&amp;#039;;&amp;#039;);&lt;br /&gt;
            document.body.appendChild(el);&lt;br /&gt;
            state.popup = el;&lt;br /&gt;
&lt;br /&gt;
            // 鼠标移到浮窗上时不隐藏&lt;br /&gt;
            el.addEventListener(&amp;#039;mouseenter&amp;#039;, function () {&lt;br /&gt;
                clearTimeout(state.hideTimer);&lt;br /&gt;
                clearTimeout(state.fetchTimer);&lt;br /&gt;
            });&lt;br /&gt;
            el.addEventListener(&amp;#039;mouseleave&amp;#039;, function (e) {&lt;br /&gt;
                if (e.relatedTarget &amp;amp;&amp;amp; e.relatedTarget.closest &amp;amp;&amp;amp; e.relatedTarget.closest(&amp;#039;a&amp;#039;) === state.link) {&lt;br /&gt;
                    return;&lt;br /&gt;
                }&lt;br /&gt;
                hidePopup();&lt;br /&gt;
            });&lt;br /&gt;
        }&lt;br /&gt;
        return state.popup;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function showPopup(x, y, html) {&lt;br /&gt;
        var popup = getPopup();&lt;br /&gt;
        popup.innerHTML = html;&lt;br /&gt;
        popup.style.display = &amp;#039;block&amp;#039;;&lt;br /&gt;
&lt;br /&gt;
        var rect = popup.getBoundingClientRect();&lt;br /&gt;
        var left = Math.max(6, Math.min(x + 12, window.innerWidth - rect.width - 6));&lt;br /&gt;
        var top = Math.max(6, Math.min(y + 12, window.innerHeight - rect.height - 6));&lt;br /&gt;
        popup.style.left = left + &amp;#039;px&amp;#039;;&lt;br /&gt;
        popup.style.top = top + &amp;#039;px&amp;#039;;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function hidePopup() {&lt;br /&gt;
        clearTimeout(state.hideTimer);&lt;br /&gt;
        clearTimeout(state.fetchTimer);&lt;br /&gt;
        if (state.popup) state.popup.style.display = &amp;#039;none&amp;#039;;&lt;br /&gt;
        state.link = null;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    /* ---------- helpers ---------- */&lt;br /&gt;
    function getFileTitle(link) {&lt;br /&gt;
        var title = link.getAttribute(&amp;#039;title&amp;#039;) || link.getAttribute(&amp;#039;data-title&amp;#039;) || &amp;#039;&amp;#039;;&lt;br /&gt;
        var m = title.match(/^(File|Image):(.+)$/i);&lt;br /&gt;
        if (m) return m[1] + &amp;#039;:&amp;#039; + m[2];&lt;br /&gt;
        // 后备：从 href 解析&lt;br /&gt;
        var href = link.getAttribute(&amp;#039;href&amp;#039;) || &amp;#039;&amp;#039;;&lt;br /&gt;
        m = href.match(/[?&amp;amp;]title=(File|Image):([^&amp;amp;]+)/);&lt;br /&gt;
        if (m) return m[1] + &amp;#039;:&amp;#039; + decodeURIComponent(m[2].replace(/\+/g, &amp;#039; &amp;#039;));&lt;br /&gt;
        return null;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function isFileLink(link) {&lt;br /&gt;
        if (!link || !link.href) return false;&lt;br /&gt;
        var title = link.getAttribute(&amp;#039;title&amp;#039;) || &amp;#039;&amp;#039;;&lt;br /&gt;
        if (/^(File|Image):/i.test(title)) return true;&lt;br /&gt;
        return /[?&amp;amp;]title=(File|Image):/i.test(link.search || link.href);&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function fmtBytes(b) {&lt;br /&gt;
        if (!b) return &amp;#039;?&amp;#039;;&lt;br /&gt;
        if (b &amp;lt; 1024) return b + &amp;#039; B&amp;#039;;&lt;br /&gt;
        if (b &amp;lt; 1048576) return (b / 1024).toFixed(1) + &amp;#039; KB&amp;#039;;&lt;br /&gt;
        return (b / 1048576).toFixed(1) + &amp;#039; MB&amp;#039;;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function esc(s) {&lt;br /&gt;
        return mw.html.escape(String(s));&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    /* ---------- API ---------- */&lt;br /&gt;
    function fetchFileData(fileTitle) {&lt;br /&gt;
        var api = new mw.Api();&lt;br /&gt;
        return api.get({&lt;br /&gt;
            action: &amp;#039;query&amp;#039;,&lt;br /&gt;
            titles: fileTitle,&lt;br /&gt;
            prop: &amp;#039;categories|templates|imageinfo|info&amp;#039;,&lt;br /&gt;
            cllimit: 50,&lt;br /&gt;
            tllimit: 50,&lt;br /&gt;
            clprop: &amp;#039;sortkey&amp;#039;,&lt;br /&gt;
            iiprop: &amp;#039;url|size|user|comment|timestamp|extmetadata&amp;#039;,&lt;br /&gt;
            iiurlwidth: CONFIG.thumbWidth,&lt;br /&gt;
            format: &amp;#039;json&amp;#039;&lt;br /&gt;
        });&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    /* ---------- render ---------- */&lt;br /&gt;
    function renderPopup(data, x, y) {&lt;br /&gt;
        var pages = data.query &amp;amp;&amp;amp; data.query.pages;&lt;br /&gt;
        if (!pages) { showPopup(x, y, &amp;#039;&amp;lt;div style=&amp;quot;color:#c00;&amp;quot;&amp;gt;无法获取数据&amp;lt;/div&amp;gt;&amp;#039;); return; }&lt;br /&gt;
&lt;br /&gt;
        var id = Object.keys(pages)[0];&lt;br /&gt;
        var page = pages[id];&lt;br /&gt;
        if (id === &amp;#039;-1&amp;#039; || !page) {&lt;br /&gt;
            showPopup(x, y, &amp;#039;&amp;lt;div style=&amp;quot;color:#888;&amp;quot;&amp;gt;文件页面不存在&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
            return;&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        var parts = [];&lt;br /&gt;
        parts.push(&amp;#039;&amp;lt;div style=&amp;quot;font-weight:bold;font-size:14px;margin-bottom:6px;word-break:break-all;&amp;quot;&amp;gt;&amp;#039; + esc(page.title) + &amp;#039;&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
&lt;br /&gt;
        // 缩略图&lt;br /&gt;
        var ii = page.imageinfo &amp;amp;&amp;amp; page.imageinfo[0];&lt;br /&gt;
        if (ii) {&lt;br /&gt;
            if (ii.thumburl) {&lt;br /&gt;
                parts.push(&amp;#039;&amp;lt;div style=&amp;quot;text-align:center;margin-bottom:8px;&amp;quot;&amp;gt;&amp;lt;a href=&amp;quot;&amp;#039; + esc(ii.url) + &amp;#039;&amp;quot; target=&amp;quot;_blank&amp;quot;&amp;gt;&amp;#039; +&lt;br /&gt;
                    &amp;#039;&amp;lt;img src=&amp;quot;&amp;#039; + esc(ii.thumburl) + &amp;#039;&amp;quot; alt=&amp;quot;&amp;quot; style=&amp;quot;max-width:100%;border:1px solid #eaecf0;border-radius:3px;&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
            }&lt;br /&gt;
            var meta = [];&lt;br /&gt;
            if (ii.width &amp;amp;&amp;amp; ii.height) meta.push(ii.width + &amp;#039;×&amp;#039; + ii.height + &amp;#039; (&amp;#039; + fmtBytes(ii.size) + &amp;#039;)&amp;#039;);&lt;br /&gt;
            if (ii.user) meta.push(&amp;#039;上传者: &amp;#039; + esc(ii.user));&lt;br /&gt;
            if (meta.length) parts.push(&amp;#039;&amp;lt;div style=&amp;quot;color:#555;margin-bottom:4px;font-size:12px;&amp;quot;&amp;gt;&amp;#039; + meta.join(&amp;#039; | &amp;#039;) + &amp;#039;&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
&lt;br /&gt;
            // 许可信息 (extmetadata)&lt;br /&gt;
            if (ii.extmetadata) {&lt;br /&gt;
                var licField = ii.extmetadata.LicenseShortName || ii.extmetadata.License || ii.extmetadata.Copyright;&lt;br /&gt;
                if (licField) {&lt;br /&gt;
                    var licVal = licField.value || licField;&lt;br /&gt;
                    parts.push(&amp;#039;&amp;lt;div style=&amp;quot;color:#555;margin-bottom:4px;font-size:12px;&amp;quot;&amp;gt;许可: &amp;#039; + esc(String(licVal)) + &amp;#039;&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
                }&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        // 分类&lt;br /&gt;
        if (page.categories &amp;amp;&amp;amp; page.categories.length) {&lt;br /&gt;
            parts.push(&amp;#039;&amp;lt;div style=&amp;quot;margin-top:8px;font-weight:bold;font-size:13px;&amp;quot;&amp;gt;分类&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
            parts.push(&amp;#039;&amp;lt;ul style=&amp;quot;margin:2px 0 0 14px;padding:0;list-style:none;&amp;quot;&amp;gt;&amp;#039;);&lt;br /&gt;
            var cats = page.categories.slice(0, 25);&lt;br /&gt;
            cats.forEach(function (c) {&lt;br /&gt;
                parts.push(&amp;#039;&amp;lt;li style=&amp;quot;padding:1px 0;font-size:12px;&amp;quot;&amp;gt;• &amp;#039; + esc(c.title.replace(/^Category:/, &amp;#039;&amp;#039;)) + &amp;#039;&amp;lt;/li&amp;gt;&amp;#039;);&lt;br /&gt;
            });&lt;br /&gt;
            if (page.categories.length &amp;gt; 25) {&lt;br /&gt;
                parts.push(&amp;#039;&amp;lt;li style=&amp;quot;color:#888;font-size:12px;&amp;quot;&amp;gt;… 还有 &amp;#039; + (page.categories.length - 25) + &amp;#039; 个&amp;lt;/li&amp;gt;&amp;#039;);&lt;br /&gt;
            }&lt;br /&gt;
            parts.push(&amp;#039;&amp;lt;/ul&amp;gt;&amp;#039;);&lt;br /&gt;
        } else {&lt;br /&gt;
            parts.push(&amp;#039;&amp;lt;div style=&amp;quot;margin-top:6px;color:#888;font-size:12px;&amp;quot;&amp;gt;无分类&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        // 模板（含版权模板）&lt;br /&gt;
        if (page.templates &amp;amp;&amp;amp; page.templates.length) {&lt;br /&gt;
            parts.push(&amp;#039;&amp;lt;div style=&amp;quot;margin-top:8px;font-weight:bold;font-size:13px;&amp;quot;&amp;gt;模板 (含版权/许可)&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
            parts.push(&amp;#039;&amp;lt;div style=&amp;quot;margin:2px 0 0;max-height:130px;overflow-y:auto;&amp;quot;&amp;gt;&amp;#039;);&lt;br /&gt;
            var tpls = page.templates.slice(0, 40);&lt;br /&gt;
            tpls.forEach(function (t) {&lt;br /&gt;
                var name = t.title.replace(/^Template:/, &amp;#039;&amp;#039;);&lt;br /&gt;
                parts.push(&amp;#039;&amp;lt;span style=&amp;quot;display:inline-block;background:#f0f2f5;border:1px solid #d4d8dd;border-radius:3px;padding:1px 5px;margin:1px 2px;font:12px monospace;color:#333;&amp;quot;&amp;gt;{{&amp;#039; + esc(name) + &amp;#039;}}&amp;lt;/span&amp;gt;&amp;#039;);&lt;br /&gt;
            });&lt;br /&gt;
            if (page.templates.length &amp;gt; 40) {&lt;br /&gt;
                parts.push(&amp;#039;&amp;lt;span style=&amp;quot;color:#888;font-size:11px;&amp;quot;&amp;gt; …+&amp;#039; + (page.templates.length - 40) + &amp;#039;&amp;lt;/span&amp;gt;&amp;#039;);&lt;br /&gt;
            }&lt;br /&gt;
            parts.push(&amp;#039;&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        // 底部链接&lt;br /&gt;
        var url = mw.config.get(&amp;#039;wgScript&amp;#039;) || &amp;#039;/wiki/&amp;#039;;&lt;br /&gt;
        var target = page.title.replace(/ /g, &amp;#039;_&amp;#039;);&lt;br /&gt;
        parts.push(&amp;#039;&amp;lt;div style=&amp;quot;margin-top:10px;border-top:1px solid #eaecf0;padding-top:6px;text-align:right;font-size:12px;&amp;quot;&amp;gt;&amp;#039; +&lt;br /&gt;
            &amp;#039;&amp;lt;a href=&amp;quot;&amp;#039; + url + esc(target) + &amp;#039;&amp;quot; target=&amp;quot;_blank&amp;quot;&amp;gt;打开文件页 →&amp;lt;/a&amp;gt;&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
&lt;br /&gt;
        showPopup(x, y, parts.join(&amp;#039;&amp;#039;));&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    /* ---------- hover handlers ---------- */&lt;br /&gt;
    function onLinkOver(e) {&lt;br /&gt;
        var link = e.target.closest ? e.target.closest(&amp;#039;a[href]&amp;#039;) : null;&lt;br /&gt;
        if (!link || !isFileLink(link)) return;&lt;br /&gt;
        if (link === state.link) return;&lt;br /&gt;
&lt;br /&gt;
        clearTimeout(state.fetchTimer);&lt;br /&gt;
        clearTimeout(state.hideTimer);&lt;br /&gt;
        state.link = link;&lt;br /&gt;
&lt;br /&gt;
        var title = getFileTitle(link);&lt;br /&gt;
        if (!title) return;&lt;br /&gt;
&lt;br /&gt;
        state.fetchTimer = setTimeout(function () {&lt;br /&gt;
            showPopup(e.clientX, e.clientY, &amp;#039;&amp;lt;div style=&amp;quot;color:#888;font-size:13px;&amp;quot;&amp;gt;加载中… &amp;#039; + esc(title) + &amp;#039;&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
            fetchFileData(title).then(function (data) {&lt;br /&gt;
                if (state.link === link) renderPopup(data, e.clientX, e.clientY);&lt;br /&gt;
            }).catch(function (err) {&lt;br /&gt;
                if (state.link === link) showPopup(e.clientX, e.clientY, &amp;#039;&amp;lt;div style=&amp;quot;color:#c00;&amp;quot;&amp;gt;请求失败: &amp;#039; + esc(String(err)) + &amp;#039;&amp;lt;/div&amp;gt;&amp;#039;);&lt;br /&gt;
            });&lt;br /&gt;
        }, CONFIG.delay);&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function onLinkOut(e) {&lt;br /&gt;
        var link = e.target.closest ? e.target.closest(&amp;#039;a[href]&amp;#039;) : null;&lt;br /&gt;
        if (!link || !isFileLink(link)) return;&lt;br /&gt;
        if (link !== state.link) return;&lt;br /&gt;
&lt;br /&gt;
        // 如果鼠标进入浮窗则不隐藏&lt;br /&gt;
        clearTimeout(state.fetchTimer);&lt;br /&gt;
        state.hideTimer = setTimeout(function () {&lt;br /&gt;
            hidePopup();&lt;br /&gt;
        }, 200);&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    /* ---------- install ---------- */&lt;br /&gt;
    document.addEventListener(&amp;#039;mouseover&amp;#039;, onLinkOver, true);&lt;br /&gt;
    document.addEventListener(&amp;#039;mouseout&amp;#039;, onLinkOut, true);&lt;br /&gt;
&lt;br /&gt;
    // 滚动时隐藏&lt;br /&gt;
    window.addEventListener(&amp;#039;scroll&amp;#039;, function () { hidePopup(); }, true);&lt;br /&gt;
});&lt;/div&gt;</summary>
		<author><name>Hehua</name></author>
	</entry>
</feed>