Vorlage:Lead/Inner: Unterschied zwischen den Versionen

Aus Offene Naturführer
Wechseln zu: Navigation, Suche
(Entfernen der semantic properties (Vorversion) und Ersetzen von Vorlage Vorlage:Lead/MakeCommaBreakingList durch eine dummy-Version hilft NICHT. Daher hier wieder vollständige Version, mit kleinen Verbesserungen.)
(Minor simplification by combining the "L" plus keyID plus leadID already in calling Template:Lead)
Zeile 11: Zeile 11:
 
// German: Deutschsprachige Attribute
 
// German: Deutschsprachige Attribute
 
-->|de|de-formal=[[Category:Schlüssel mit Lead-Vorlage]]<!-- Hidden cat for SMW form!
 
-->|de|de-formal=[[Category:Schlüssel mit Lead-Vorlage]]<!-- Hidden cat for SMW form!
+
   -->{{
   -->{{#if: {{{commonnames}}}<!--
+
  #if: {{{commonnames}}}|{{#arraymap: {{{commonnames}}}<!-- values
  THEN-->|{{#arraymap: {{{commonnames}}}<!-- values
+
 
     -->|,<!-- split on ,
 
     -->|,<!-- split on ,
 
     -->|§<!-- assign temporary variable
 
     -->|§<!-- assign temporary variable
 
     -->|[[Deutscher Name::§| ]]<!-- output
 
     -->|[[Deutscher Name::§| ]]<!-- output
 
     -->|<!-- new output separator
 
     -->|<!-- new output separator
     -->}}<!--
+
     -->}} }}{{
  END -->}}{{
+
   #if: {{{synonyms}}}|[[Synonymliste::{{StripFormatting |{{{synonyms}}}}}| ]]}}{{
 
+
   #if: {{{scientificname}}}|[[Wissenschaftlicher Name::{{StripFormatting | {{{scientificname}}}}}| ]]}}<!--
   #if: {{{synonyms}}}<!--
+
  THEN-->| [[Synonymliste:: {{StripFormatting |{{{synonyms}}}}}| ]]<!--
+
  END -->}}{{
+
 
+
   #if: {{{scientificname}}}<!--
+
  THEN-->|[[Wissenschaftlicher Name::{{StripFormatting | {{{scientificname}}}}}| ]]<!--
+
  END -->}}<!--
+
  
 
// English properties
 
// English properties
Zeile 42: Zeile 34:
 
// THEN 2nd/3rd/etc lead in a couplet, normal start
 
// THEN 2nd/3rd/etc lead in a couplet, normal start
 
-->|{{#vardefine: decisiontreeAlternative|{{#expr: {{#var: decisiontreeAlternative}}+1}}}}<!--
 
-->|{{#vardefine: decisiontreeAlternative|{{#expr: {{#var: decisiontreeAlternative}}+1}}}}<!--
   --><tr id="L{{{keyID}}}_{{{leadID}}}_{{#var:decisiontreeAlternative}}_row" class="dt-row">{{
+
   --><tr id="{{{leadID}}}_{{#var:decisiontreeAlternative}}_row" class="dt-row">{{
 
       #if:{{{parentlead}}}<!-- THEN: indent 2 columns -->|<td></td><td></td>}}
 
       #if:{{{parentlead}}}<!-- THEN: indent 2 columns -->|<td></td><td></td>}}
 
       <td class="dt-nodeid">{{{displayID}}}</td><!--
 
       <td class="dt-nodeid">{{{displayID}}}</td><!--
Zeile 70: Zeile 62:
 
   -->}}<!--
 
   -->}}<!--
 
   // Next column is lead id for first alternative.
 
   // Next column is lead id for first alternative.
   --><tr id="L{{{keyID}}}_{{{leadID}}}_row" class="dt-row">{{
+
   --><tr id="{{{leadID}}}_row" class="dt-row">{{
 
     #if:{{{parentlead}}}<!-- THEN: indent 2 columns -->|<td></td><td></td>}}
 
     #if:{{{parentlead}}}<!-- THEN: indent 2 columns -->|<td></td><td></td>}}
     <td id="L{{{keyID}}}_{{{leadID}}}" class="dt-nodeid">{{{displayID}}}</td><!--
+
     <td id="{{{leadID}}}" class="dt-nodeid">{{{displayID}}}</td><!--
 
// END PART 1, Manage spacer rows and subheadings above a lead row
 
// END PART 1, Manage spacer rows and subheadings above a lead row
 
-->}}<!--
 
-->}}<!--
Zeile 87: Zeile 79:
 
     --><span class="leadspan">{{Trim|1={{{statement}}}}}&nbsp;</span><!--
 
     --><span class="leadspan">{{Trim|1={{{statement}}}}}&nbsp;</span><!--
 
     // Add mw-collapsible span (the "more…")
 
     // Add mw-collapsible span (the "more…")
     -->{{#if: {{{detailspresent}}}|<span class="leadspan noprint mw-customtoggle-L{{{keyID}}}{{{leadID}}}{{#var:decisiontreeAlternative}}row"></span>}}<!--
+
     -->{{#if: {{{detailspresent}}}|<span class="leadspan noprint mw-customtoggle-{{{leadID}}}_{{#var:decisiontreeAlternative}}row"></span>}}<!--
 
     --></td><!--
 
     --></td><!--
 
     // Second column in nested table = number of further leads. NEW: both with and without result in same row (it used to be below result)!
 
     // Second column in nested table = number of further leads. NEW: both with and without result in same row (it used to be below result)!
Zeile 108: Zeile 100:
 
     // TODO: introduce resultformat parameter later (= list of format options, allowing common name or scientific name to be first)
 
     // TODO: introduce resultformat parameter later (= list of format options, allowing common name or scientific name to be first)
 
     -->{{#if: {{{resulttextoverride}}}<!--  
 
     -->{{#if: {{{resulttextoverride}}}<!--  
    // THEN: Explicit result text override -> ignore commonnames+scientificname, i.e.
 
 
       -->|{{#if: {{{scientificname}}}|<!--
 
       -->|{{#if: {{{scientificname}}}|<!--
       // THEN: NEW LAYOUT RULES -> no common names output for resulttextoverride
+
       // THEN: NEW LAYOUT RULES -> ignore commonnames+scientificname if resulttextoverride
       // ELSE:-> output common names if present:
+
       // ELSE:-> output common names even for resulttextoverride
 
       -->|{{#if: {{{commonnames}}}<!--
 
       -->|{{#if: {{{commonnames}}}<!--
 
         -->|<span class="commonnames">&nbsp;{{Lead/MakeCommaBreakingList | listtext={{{commonnames}}} }}<!--
 
         -->|<span class="commonnames">&nbsp;{{Lead/MakeCommaBreakingList | listtext={{{commonnames}}} }}<!--
Zeile 158: Zeile 149:
 
     -->{{#if:{{{nested}}}<!--
 
     -->{{#if:{{{nested}}}<!--
 
       -->|<br /><!-- within-page-link:
 
       -->|<br /><!-- within-page-link:
       --><span class="leadon">&nbsp;[[#L{{{keyID}}}_{{{leadID}}}<!--
+
       --><span class="leadon">&nbsp;[[#{{{leadID}}}<!--
 
       -->{{#ifeq:{{#sub:{{{leadpart2}}}|0|1}}|[<!--
 
       -->{{#ifeq:{{#sub:{{{leadpart2}}}|0|1}}|[<!--
 
       -->|<!--THEN nothing
 
       -->|<!--THEN nothing
Zeile 182: Zeile 173:
 
// THEN  
 
// THEN  
 
-->|<tr><td class="leadextras" colspan="2"><!--
 
-->|<tr><td class="leadextras" colspan="2"><!--
--><div class="mw-collapsible mw-collapsed mw-collapsible-content leadextras" id="mw-customcollapsible-L{{{keyID}}}{{{leadID}}}{{#var:decisiontreeAlternative}}row"><!--
+
--><div class="mw-collapsible mw-collapsed mw-collapsible-content leadextras" id="mw-customcollapsible-{{{leadID}}}_{{#var:decisiontreeAlternative}}row"><!--
 
-->{{{detailtext}}}<!--
 
-->{{{detailtext}}}<!--
 
-->{{#if: {{{image m}}}<!--
 
-->{{#if: {{{image m}}}<!--

Version vom 5. September 2012, 19:05 Uhr

See Key Start-Doc for the main documentation, Lead-Doc for recent technical changes of the Lead-templates.

Quelle: Offene Naturführer, Das Wiki zu Bestimmungsfragen: Vorlage:Lead/Inner. Abgerufen am 2. Juni 2025, 01:39 von https://offene-naturfuehrer.de/web/Vorlage:Lead/Inner