模板:Cquote:修订间差异

来自SS唯基
跳到导航 跳到搜索
(moegirl?)
(撤销NierPod042讨论)的版本7568)
第1行: 第1行:
<includeonly><div style="display:table;margin: auto; background-color:{{{bgcolor|transparent}}};width:{{{width|auto}}};{{#if: {{{bgcolor|}}}|border: 1px solid #AAAAAA;}}">
{| class="cquote pullquote" role="presentation" {{#if:{{{rtl|}}}|dir="rtl"}} style="{{#switch:{{{float|}}}
<div>
  | left = float:left
<div style="display: table-cell;vertical-align: top; color:#B2B7F2;font-size:{{#switch:{{{size|{{{4|{{{quotewidth|{{{width|20px}}}}}}}}}}}}
  | right = float:right
  | #default = margin:auto
  }}; border-collapse: collapse; border: none; background-color: {{{bgcolor|transparent}}}; width: {{#if: {{{wide|}}} | 100% | {{{width|auto}}}}}; {{#if: {{{bgcolor|}}} | border: 1px solid #AAAAAA;}}"
| style="width: 20px; vertical-align: top; border: none; color: {{{qcolor|#B2B7F2}}}; font-size: {{#switch:{{{size|{{{quotewidth|{{{width|{{{4|20px}}}}}}}}}}}}
|10px=20px
|10px=20px
|30px=60px
|30px=60px
第7行: 第10行:
|50px=100px
|50px=100px
|60px=120px
|60px=120px
|#default=36px}};font-family:'Times New Roman',serif;font-weight:bold;text-align:left;padding:10px 10px;line-height:100%">{{{open|-{“}-}}}</div>
|#default=40px}}; font-family: {{#if:{{{rtl|}}}|Roman|'Times New Roman', Times}}, serif; font-weight: bold; line-height: .6em; text-align: left; padding: {{#if:{{{small|}}}|10px 2px|10px 10px}};" | {{#if:{{{rtl|}}}|-{”}-|-{“}-}}
<div style="display: table-cell;text-align: left; padding: 1em; vertical-align: middle;">{{{1|}}}</div>
| style="vertical-align: top; border: none;{{#if:{{{rtl|}}}|direction:rtl;}} padding: {{#if:{{{small|}}}|4px 2px|4px 10px}};" | {{{text|{{{content|{{{quotetext|{{{quote|{{{1|<includeonly>{{error|Error: No text given for quotation (or equals sign used in the actual argument to an unnamed parameter)}}</includeonly><noinclude>{{lorem ipsum}}</noinclude>}}}}}}}}}}}}}}}
<div style="display: table-cell; vertical-align: bottom; color:#B2B7F2;font-size:{{#switch:{{{size|{{{4|{{{quotewidth|{{{width|20px}}}}}}}}}}}}
| style="width: 20px; vertical-align: bottom; border: none; color: {{{qcolor|#B2B7F2}}}; font-size: {{#switch:{{{size|{{{quotewidth|{{{width|{{{4|20px}}}}}}}}}}}}
|10px=20px
|10px=20px
|30px=60px
|30px=60px
第15行: 第18行:
|50px=100px
|50px=100px
|60px=120px
|60px=120px
|#default=36px}};font-family:'Times New Roman',serif;font-weight:bold;text-align:left;padding:10px 10px;line-height:100%">{{{close|-{”}-}}}</div>
|#default=40px}}; font-family: {{#if:{{{rtl|}}}|Roman|'Times New Roman', Times}}, serif; font-weight: bold; line-height: .6em; text-align: right; padding: {{#if:{{{small|}}}|10px 2px|10px 10px}};" | {{#if:{{{rtl|}}}|-{“}-|-{”}-}}
</div>{{#if:{{{2|}}}|
|-
<div style="font-size: smaller; text-align: right; padding-right: 4%;"><cite style="font-style:normal;">——{{{2}}}{{#if:{{{3|}}}|{{{3}}}|}}</cite>
{{#if:{{{author|{{{personquoted|{{{source|{{{publication|{{{title|{{{quotesource|{{{2|{{{3|}}}}}}}}}}}}}}}}}}}}}}}}|{{#if:{{NAMESPACE}}||[[Category:使用抬升式引用的條目]]}}
</div>}}
{{!}} colspan="3" class="cquotecite" style="border: none; padding-right: 4%; font-size: smaller; text-align: right;" {{!}} <cite>——&thinsp;{{#if:{{{author|{{{personquoted|{{{2|}}}}}}}}}|{{{author|{{{personquoted|{{{2}}}}}}}}}{{#if:{{{source|{{{publication|{{{title|{{{quotesource|{{{3|}}}}}}}}}}}}}}}|, {{{source|{{{publication|{{{title|{{{quotesource|{{{3}}}}}}}}}}}}}}}}}|{{#if:{{{source|{{{publication|{{{title|{{{quotesource|{{{3|}}}}}}}}}}}}}}}|{{{source|{{{publication|{{{title|{{{quotesource|{{{3}}}}}}}}}}}}}}}}}}}</cite>
</div></includeonly><noinclude>
}}
|}<!-- {{subst:FULLPAGENAME}} --><noinclude>
{{documentation}}
</noinclude>

2020年3月7日 (六) 15:56的版本

Documentation icon 模板文档[-查看-] [编辑] [历史] [刷新]

{{Cquote}}是一个适合于抬升式引用(pull quote)的模板,此类引用从一个页面的文字中独立展示出来。它一般不应当用于条目中,除非那样做有一个很好的理由。当抬升式引用被用在一个章节的开头或结尾做简短的引用,用以帮助强调该章节的内容,此时这种引用效果最好。

注意:本模板不应当用于条目文字中的块引用(Block quote)。对于文字中很长的引用,Quotations格式手册中建议使用HTML的<lockquote>元素,就像通过使用Quote模板那样。

用法

  • {{Cquote|text=引用文字|author=引用来源|source=引用出处}}

参数

参数1quote
引用的文字;用<p>...</p>包著第二個起每個段落。另見Poemquote。
注意:如果引用的文字含有一个或更多“=”(等号),那么此模板必须以{{cquote|1=引用文字}}的形式调用。

接下来的两个参数能够用来提供引文的出处。

参数author
人的名字,引文即是他/她所述或所著。可以包含链接。
参数source
该引文的来源(演讲、出版物标题,等等)。可以包含链接。

以下两个参数用于设置引号大小、背景色。

参数width
引号的字体大小,缺省为20px。可以设置为10px、20px、30px等等,不建议超过50。
参数bgcolor
主体的背景色,缺省为transparent。可以设置为十六进制编码,如“#FFC0CB”,或者已命名颜色的名称,如“pink”。

语法

{{Cquote|<引用内容>|<引用来源>|<引用出处>}}

举例

{{cquote|引用文字}}

就像吉米·威尔士所说的

{{cquote|引用文字|引用来源|引用出处}}
{{Cquote|键盘毁而吾不悔,<br />
爪机跪而我不归!<br />|[https://sstm.moe/profile/49975-1 伊弗列姆]|《[https://sstm.moe/topic/102946-1 回归倒计时之水怪榜不能不说的故事]》}}

页面展示效果为:

{{cquote|引用文字|quotewidth=40px}}

这样加大了引号:

带ref标签的例子:

{{cquote|◇我绝对不能再作那政府任命的校长。<br />
◇我绝对不能再做不自由的大学校长。<br />
◇思想自由,是世界大学的通例。|蔡元培|《不肯再任北大校长的宣言》<ref>(写于1919年6月15日)选自中华书局1984年版《蔡元培全集》第3卷</ref>|quotewidth=40px}}
  1. (写于1919年6月15日)选自中华书局1984年版《蔡元培全集》第3卷