Template:Rp: Difference between revisions

added language support
m (1 revision imported)
(added language support)
Line 1: Line 1:
{{#if: {{{needed|}}}
{{#if:{{{needed|}}}|{{page needed|date={{{date|}}}|reason={{{reason|}}}}}|{{r/superscript
|{{page needed|date={{{date|}}} }}
|prefix={{#switch:{{{style|}}}|AMA|Ama|ama=(|:}}
|<sup class="reference" style="white-space:nowrap;">{{#if: {{{page|}}}
|suffix={{#switch:{{{style|}}}|AMA|Ama|ama=)}}
|(<span {{#if:{{{q|{{{quote|}}}}}}|style="border-bottom: 1px dashed;" title='"{{#tag:nowiki|{{#invoke:String|replace|{{trim quotes|s={{{q|{{{quote}}}}}}}}|"|&quot;}}}}"'}}>{{#if: {{{nopp|}}}||p}}{{{page}}}</span>)
|pp={{#switch:{{{style|}}}|AMA|Ama|ama={{#if:{{{no-pp|{{{nopp|}}}}}}||{{#if:{{{quote-page|{{{qp|{{{page|{{{p|}}}}}}}}}}}}|p|{{#if:{{{quote-pages|{{{qpp|{{{pages|{{{pp|}}}}}}}}}}}}|pp}}}}}}}}
|{{#if: {{{pages|}}}
<!-- previous behaviour:
  |(<span {{#if:{{{q|{{{quote|}}}}}}|style="border-bottom: 1px dashed;" title='"{{#tag:nowiki|{{#invoke:String|replace|{{trim quotes|s={{{q|{{{quote}}}}}}}}|"|&quot;}}}}"'}}>{{#if: {{{nopp|}}}||pp}}{{{pages}}}</span>)
|prefix={{#if:{{{quote-page|{{{qp|{{{page|{{{p|{{{quote-pages|{{{qpp|{{{pages|{{{pp|{{{at|{{{loc|}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}|(|:}}
  |{{#if: {{{at|}}}
|suffix={{#if:{{{quote-page|{{{qp|{{{page|{{{p|{{{quote-pages|{{{qpp|{{{pages|{{{pp|{{{at|{{{loc|}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}|)}}
      |(<span {{#if:{{{q|{{{quote|}}}}}}|style="border-bottom: 1px dashed;" title='"{{#tag:nowiki|{{#invoke:String|replace|{{trim quotes|s={{{q|{{{quote}}}}}}}}|"|&quot;}}}}"'}}>{{{at}}}</span>)
|pp={{#if:{{{no-pp|{{{nopp|}}}}}}||{{#if:{{{quote-page|{{{qp|{{{page|{{{p|}}}}}}}}}}}}|p|{{#if:{{{quote-pages|{{{qpp|{{{pages|{{{pp|}}}}}}}}}}}}|pp}}}}}}
      |<nowiki>:</nowiki><span {{#if:{{{q|{{{quote|}}}}}}|style="border-bottom: 1px dashed;" title='"{{#tag:nowiki|{{#invoke:String|replace|{{trim quotes|s={{{q|{{{quote}}}}}}}}|"|&quot;}}}}"'}}>{{trim|
        {{#invoke:String|replace|
          {{#invoke:String|replace|
            {{#invoke:String|replace|{{{1|}}}|(%d+)%-(%d+)|%1&ndash;%2|plain=false}} <!-- Match all ranges of numbers e.g. 1-2 -->
          |(%d+)%-%s*$|%1&ndash;|plain=false}} <!-- Match all like "1-" which only have whitespace after and then end of parameter -->
        |(%d+)%-,([%s][^%s]+)|%1&ndash;%2|plain=false}} <!-- Match all like "2-, 10" but never "1-," -->
      }}</span>
    }}
  }}
}}</sup>
}}<noinclude><!--
  Note: Please do not change the parameter names "at", "page", "pages"
        and "nopp" as they are also used by [[Template:Citation]].
-->
-->
{{Documentation}}
|leadin={{#if:{{{quote-page|{{{qp|{{{page|{{{p|}}}}}}}}}}}}|Page|{{#if:{{{quote-pages|{{{qpp|{{{pages|{{{pp|}}}}}}}}}}}}|Pages|{{#if:{{{at|{{{loc|}}}}}}|Location|Page&nbsp;/ location}}}}}}
|where={{#if:{{{quote-page|{{{qp|{{{page|{{{p|{{{at|{{{loc|}}}}}}}}}}}}}}}}}}|{{{quote-page|{{{qp|{{{page|{{{p|{{{at|{{{loc|}}}}}}}}}}}}}}}}}}|{{#invoke:String2|hyphen2dash|{{{quote-pages|{{{qpp|{{{pages|{{{pp|{{{1|}}}}}}}}}}}}}}}}}}}
|quote={{{quotation|{{{quote|{{{q|}}}}}}}}}
|language={{{language|{{{lang|{{{l|}}}}}}}}}
|translation={{{trans-quote|{{{tq|{{{translation|{{{t|}}}}}}}}}}}}
|wrap={{{wrap|}}}
}}{{#switch:{{{wrap|}}}|n|no=|&#8203;}}}}<noinclude><!--
Note: Please do not change the parameter names "at", "page", "p", "pages", "pp", "quote-page", "quote-pages", "trans-quote" , "no-pp" and "nopp" as they are also used by CS1/CS2 citation templates, "loc" is also used by SFN templates. -->
{{documentation}}
</noinclude>
</noinclude>