Jump to content

Template:Li/II: Difference between revisions

From LithoGraphica
Reversedragon (talk | contribs)
m arguments
Reversedragon (talk | contribs)
m demo of template II - currently debugging code from icons to try to make it look better
 
Line 1: Line 1:
<includeonly><onlyinclude>{{#if:{{{start|}}}||</li>}}<li {{#if:{{{lang|}}}|lang{{=}}"{{{lang|}}}"}} {{#if:{{{II|}}}|{{Template:I{{{II|}}}/class}}}} {{#if:{{{class|}}}|class{{=}}"{{{class|}}}"}} {{#if:{{{Q2|}}}|data-qid{{=}}"{{{Q|}}}" value{{=}}"{{{Q2|}}}"|value{{=}}"{{{Q|}}}"}} data-icon="{{{II|}}}">{{#if:{{{II|}}}|{{Template:I{{{II|}}}}}|class={{Template:I{{{II|}}}/classname}}}}{{#if:{{{Q2|}}}{{{Q2|}}}|<span class="search-hint" aria-hidden="true">{{#if:{{{Q2|}}}|Q{{{Q2|}}}/Q{{{Q|}}}|Q{{{Q|}}}}}</span>}}{{#if:{{{h4|}}}|<h4>{{{h4}}}</h4>}}</includeonly></onlyinclude><!--
<includeonly><onlyinclude>{{#if:{{{start|}}}||</li>}}<li {{#if:{{{lang|}}}|lang{{=}}"{{{lang|}}}"}} {{#if:{{{II|}}}|{{Template:I{{{II|}}}/class|flag {{{class|}}}}}}} {{#if:{{{class|}}}|class{{=}}"{{{class|}}}"}} data-qid{{=}}"{{int:Hue-coordinate-friendly-Q{{{Q|}}}}}" value{{=}}"{{int:hue-coordinate-unfriendly-Q{{{Q|}}}}}" data-icon2="{{{II|}}}">{{#if:{{{II|}}}|{{Template:I{{{II|}}}|class={{Template:I{{{II|}}}/swatch|Q={{int:Hue-coordinate-friendly-Q{{{Q|}}}}}}}}}<span class="search-hint" aria-hidden="true">Q{{int:Hue-coordinate-friendly-Q{{{Q|}}}}}/Q{{int:Hue-coordinate-unfriendly-Q{{{Q|}}}}}}}</span>{{#if:{{{h4|}}}|<h4>{{{h4}}}</h4>}}{{#if:{{{PPPA|}}}|{{{PPPA|}}}|{{{1|}}}}}</includeonly></onlyinclude><!--


more readable version:
more readable version:
{{#if:{{{start|}}}||</li>}}
{{#if:{{{start|}}}||</li>}}
<li {{#if:{{{lang|}}}|lang{{=}}"{{{lang|}}}"}}
<li {{#if:{{{lang|}}}|lang{{=}}"{{{lang|}}}"}}
  {{#if:{{{II|}}}|{{Template:I{{{II|}}}/class}}}} {{#if:{{{class|}}}|class{{=}}"{{{class|}}}"}}
  {{#if:{{{II|}}}|{{Template:I{{{II|}}}/class|flag {{{class|}}}}}}} {{#if:{{{class|}}}|class{{=}}"{{{class|}}}"}}
  {{#if:{{{Q2|}}}|data-qid{{=}}"{{{Q|}}}" value{{=}}"{{{Q2|}}}"|value{{=}}"{{{Q|}}}"}} data-icon="{{{II|}}}">
  data-qid{{=}}"{{int:hue-coordinate-friendly-Q{{{Q|}}}}}" value{{=}}"{{int:hue-coordinate-unfriendly-Q{{{Q|}}}}}" data-icon2="{{{II|}}}">
   {{#if:{{{II|}}}|{{Template:I{{{II|}}}}}|class={{Template:I{{{II|}}}/classname}}}}
   {{#if:{{{II|}}}|{{Template:I{{{II|}}}|class={{Template:I{{{II|}}}/swatch|Q={{int:Hue-coordinate-friendly-Q{{{Q|}}}}}}}}}
{{#if:{{{Q2|}}}{{{Q2|}}}
<span class="search-hint" aria-hidden="true">Q{{int:hue-coordinate-friendly-Q{{{Q|}}}}}/Q{{int:hue-coordinate-unfriendly-Q{{{Q|}}}}}}}</span>
  |<span class="search-hint" aria-hidden="true">
    {{#if:{{{Q2|}}} | Q{{{Q2|}}}/Q{{{Q|}}} | Q{{{Q|}}} }}
    </span>}}
{{#if:{{{Q2|}}}{{{Q2|}}}
  |<span class="search-hint" aria-hidden="true">
    {{#if:{{{Q2|}}} | Q{{{Q2|}}}/Q{{{Q|}}} | Q{{{Q|}}} }}
    </span>}}
{{#if:{{{h4|}}}|<h4>{{{h4}}}</h4>}}
{{#if:{{{h4|}}}|<h4>{{{h4}}}</h4>}}
-- {{#if:{{{PPPA|}}}|{{{PPPA|}}}|{{{1|}}}}} --
{{#if:{{{PPPA|}}}|{{{PPPA|}}}|{{{1|}}}}}


-->== Description ==
-->
== Demo ==
=== II (v2) ===
<ol class="hue clean">
{{li|start=y|II=S1/Fy|Q=38,45}}{{TTS|Fy|Fiction}} / [[E:Q38,45|superstructural fantasy worlds]]
</li></ol>
<!-- currently generates this code:
 
<ol class="hue clean"><li class="field_fantasy manual flag" data-dimension="S" data-qid="38,45" value="3845" data-icon2="S1/Fy"><span class="mix-match field_fantasy"><abbr class="figure item-dimension" data-icon="" title="S1 Signifier Item / fantasy, fiction, or arts / Item ID Q / main sense"><ins class="tts flag" data-title="" data-arg1="" data-tts=". (S)"><ruby><span class="visual" aria-hidden="true">S–</span><rp class="bracket" aria-hidden="true"> (</rp><rp class="help">pronounced </rp><rt data-lang="" class="aural">. (S)</rt><rp class="bracket" aria-hidden="true">)</rp></ruby></ins><ins class="tts swatch" data-title="" data-arg1="(Fantasy) (S):" data-tts=""><ruby><span class="visual" aria-hidden="true">[Fy] [S]</span><rp class="bracket" aria-hidden="true"> (</rp><rp class="help">pronounced </rp><rt data-lang="" class="aural">(Fantasy) (S):</rt><rp class="bracket" aria-hidden="true">)</rp></ruby></ins> </abbr><span class="spacer"> </span></span><ins class="field-tag"><span class="plainlinks"><a rel="nofollow" class="external text" href="https://research.moraleconomy.au/index.php?title=Ontology:"><abbr class="tts" title="fantasy, fiction, or arts" data-arg1="" data-tts="">Fy</abbr></a></span> / </ins><span class="search-hint" aria-hidden="true">Q38,45/Q3845</span><span class="tts" title="Fiction" data-arg1="Fiction" data-tts=""><ruby><span class="visual" aria-hidden="true">Fy</span><rp class="bracket" aria-hidden="true"> (</rp><rp class="help">pronounced </rp><rt data-lang="" class="aural">Fiction</rt><rp class="bracket" aria-hidden="true">)</rp></ruby></span> / <a href="/index.php?title=Ontology:Q38,45" title="Ontology:Q38,45">superstructural fantasy worlds</a></li></ol>
 
-->
=== I (v1) ===
<ol class="hue clean">
{{li|start=y|I=S1/Fy|Q=38,45|Q2=3845}}{{TTS|Fy|Fiction}} / [[E:Q38,45|superstructural fantasy worlds]]
</li></ol>
 
== Description ==


This is a template meant to mirror the HTML <code>li</code> tag. The purpose of it is to make prototype pages more readable and intuitive and less easy to make typos. As such, most of the parameters for the tag have to do with Hue Items.
This is a template meant to mirror the HTML <code>li</code> tag. The purpose of it is to make prototype pages more readable and intuitive and less easy to make typos. As such, most of the parameters for the tag have to do with Hue Items.

Latest revision as of 03:20, 24 June 2026

Demo

II (v2)

  1. pronounced . (S)pronounced (Fantasy) (S): Fy  / pronounced Fiction / superstructural fantasy worlds

I (v1)

  1. pronounced Fiction / superstructural fantasy worlds

Description

This is a template meant to mirror the HTML li tag. The purpose of it is to make prototype pages more readable and intuitive and less easy to make typos. As such, most of the parameters for the tag have to do with Hue Items.

Parameters

  • start - Must be used on the first Item in the list for correct rendering. (Though if it is omitted, browsers may ignore the bug anyway.)
  • II - Icon Template, such as S2/Fy. It is assumed that you will supply the dimension and main classname in this argument. (This parameter was originally I but is now II on this template to reflect that it is the second version.)
  • class - For adding to the CSS classname applied to the tag. Optional.
  • Q - Item number with commas, for use in ordered lists.
  • Q2 - Item number without commas, for use in ordered lists.
  • h4 - Proposition title, to be bolded and shown on table of contents. Optional.
  • lang - Language of text inside list item. If not specified, this list item will probably be assumed to have the same language as the page or section that contains it.