Difference between revisions of "Template:DNB/prescript"

From blackwiki
Jump to navigation Jump to search
imported>Trappist the monk
imported>Trappist the monk
 
Line 1: Line 1:
<includeonly>{{#if: {{{noicon}}}||
+
<includeonly>{{#if: {{{no-icon|{{{noicon|}}}<!-- -->}}}|<!--empty-->|
  <!--else-->{{#ifeq: {{{wstitle|}}}|<!--eq to empty-->|
+
  <!--else-->{{#ifeq: {{{wstitle|}}}|<!--eq to empty-->|
 
               <!--then-->[[File:PD-icon.svg|12px|alt=]]&nbsp;
 
               <!--then-->[[File:PD-icon.svg|12px|alt=]]&nbsp;
 
               |<!--else-->[[File:Wikisource-logo.svg|12px|alt=]]&nbsp;}}<!--endif
 
               |<!--else-->[[File:Wikisource-logo.svg|12px|alt=]]&nbsp;}}<!--endif
-->}}{{#ifeq:{{{prescript|}}}|<!--eq to empty-->|{{#ifeq: {{{inline|}}} |<!--eq to empty-->|<!--
+
-->}}{{#if:{{{prescript|}}}|{{{prescript}}}|{{#ifeq: {{{inline|}}} |<!--eq to empty-->|<!--
 
                       then display-->This article
 
                       then display-->This article
 
                       |<!--else display-->One or more of the preceding sentences
 
                       |<!--else display-->One or more of the preceding sentences
 
                     }}<!-- no white space
 
                     }}<!-- no white space
       --> incorporates text from a publication now in the [[public domain]]:&nbsp;|{{{prescript}}}}}<!-- no white space--></includeonly><noinclude>{{documentation}}</noinclude>
+
       --> incorporates text from a publication now in the [[public domain]]:&nbsp;}}<!-- no white space--></includeonly><noinclude>{{documentation}}</noinclude>

Latest revision as of 15:22, 9 June 2019

Template documentation[view] [edit] [history] [purge]

This is a support template for the Dictionary of National Biography attribution templates {{DNB}}, {{DNBSupp}}, {{DNB12}}, and {{DNBIE}}. Not to be used stand-alone.

Usage

{{DNB/prescript
|noicon = {{{no-icon|{{{noicon|}}}}}}
|wstitle = {{{wstitle|}}}
|prescript = {{{prescript|}}}
|inline = {{{inline|}}}
}}

TODO: at this writing, this template still in experimental stage; examples below use ~/sandbox templates

parameters
|noicon= – any assigned value hides the leading Wikisource or public domain icon
|wstitle= – when |noicon= does not have a value, the template renders with the leading Wikisource icon; default public domain icon else – not to be used on {{DNBIE}} which is not on Wikisource
|prescript= – overrides the template's default prescript text; the template's prescript text cannot be 'turned off'; to render the citation portion without prescript text, use the equivalent {{cite DNB}}, {{DNBSupp}}, {{DNB12}}, or {{DNBIE}} template
{{DNB |prescript=Alternate prescript text:&#32; |wstitle=Abbadie, Jacques}}
 Alternate prescript text: "Abbadie, Jacques". Dictionary of National Biography. London: Smith, Elder & Co. 1885–1900.
|prescript= – ignored; template uses the prescript text selected by |inline=
{{DNB |prescript= |wstitle=Abbadie, Jacques}}
 This article incorporates text from a publication now in the public domain"Abbadie, Jacques". Dictionary of National Biography. London: Smith, Elder & Co. 1885–1900.
|inline= – select one or the other of the two variants of the prescript text:
|inline=y:
{{DNB |inline=y |wstitle=Abbadie, Jacques}}
 One or more of the preceding sentences incorporates text from a publication now in the public domain"Abbadie, Jacques". Dictionary of National Biography. London: Smith, Elder & Co. 1885–1900.
|inline= or omitted:
{{DNB |inline= |wstitle=Abbadie, Jacques}}
 This article incorporates text from a publication now in the public domain"Abbadie, Jacques". Dictionary of National Biography. London: Smith, Elder & Co. 1885–1900.
{{DNB |wstitle=Abbadie, Jacques}}
 This article incorporates text from a publication now in the public domain"Abbadie, Jacques". Dictionary of National Biography. London: Smith, Elder & Co. 1885–1900.