Template:R/ref: Difference between revisions
Richardpruen (talk | contribs) m (1 revision imported) |
(ensure that ref name= and group= parameters are always passed down in quotes (more compatible in case of spaces)) |
||
Line 1: | Line 1: | ||
<includeonly>{{#tag:ref||name={{{1}}}|group={{{2}}}}}{{#if:{{{3}}}|<sup class="reference nowrap"><nowiki>:</nowiki><span {{#if:{{{4|}}}|style="border-bottom: 1px dashed;" title='"{{#tag:nowiki|{{#invoke:String|replace|{{trim quotes|s={{{4}}}}}|"|"}}}}"'}}>{{{3}}}</span></sup>}}</includeonly><noinclude> | <includeonly>{{#tag:ref||name="{{trim quotes|s={{{1}}}}}"|group="{{trim quotes|s={{{2}}}}}"}}{{#if:{{{3}}}|<sup class="reference nowrap"><nowiki>:</nowiki><span {{#if:{{{4|}}}|style="border-bottom: 1px dashed;" title='"{{#tag:nowiki|{{#invoke:String|replace|{{trim quotes|s={{{4}}}}}|"|"}}}}"'}}>{{{3}}}</span></sup>}}</includeonly><noinclude> | ||
{{documentation}} | {{documentation}} | ||
</noinclude> | </noinclude> |
Revision as of 21:24, 27 August 2021
This is a subtemplate, implementing a piece of Template:R for a single ref name.
Usage
For internal use only:
{{r/ref |[1=]name |[2=]group |direction=ltr/rtl |page=page / |pages=pages / |location=in-source-location |quote=quote |quote-page=page/p (for page) / quote-page / |quote-pages=pages/pp (for pages) / quote-pages |quote-location=page/p/pages/pp (for page/pages) / quote-location |language=language-code/language-name |translation=translation |quote-cite=quote-anchor (cite the quote belongs to) |reference=citation-text |annotation=p[age[s]] (for pages) / q[uote] (for quote including quote-page) / annotation-text |leadin=leadin-sequence |postscript=postscript-sequence |section=y[es] (to use internally generated section name) / context-section |needed-reason=y[es] (for "unspecified reason") / page-needed-reason |needed-date=page-needed-date |wrap=n[o] (default) / y[es] (to activate wrapping) / f[orced] (to enforce inline wrapping) |no-pp=y[es] (to optionally suppress p/pp) |style=AMA / else (to optionally select AMA style) |content-id=content-anchor (to mark annotation) |link-id=link-anchor (to mark superscript link) |debug=debug-value }}
See also
- Module:DecodeEncode.encode()
- Module:Plain text.main()
- Module:String.replace()
- Module:String2.hyphen2dash()
- Template:lang fn