Modèle:FiltreModule : Différence entre versions

[version non vérifiée][version vérifiée]
 
(34 révisions intermédiaires par 2 utilisateurs non affichées)
Ligne 1 : Ligne 1 :
{{#switch: {{{1|}}}
+
{{#switch:{{{Type|}}}
|Bouton=
+
|Text=
<div data-element="button" data-type="button" data-aria-controls="{{{id|{{{Nom|}}}}}}-range" data-aria-haspopup="true" data-aria-expanded="false" data-style="padding: 10px 20px; background-color: #fff; border: 1px solid #ccc; border-radius: 5px; font-size: 16px; cursor: pointer; user-select: none; display: inline-block;">Filtrer par {{{Nom|}}}</div>
+
{{FiltreÉlément
 +
|Élément=input
 +
|id={{{id}}}
 +
|type=text
 +
|placeholder={{{placeholder|}}}
 +
|Nom={{{Nom|}}}
 +
}}
 
|Range=
 
|Range=
<div id="{{{id|{{{Nom|}}}}}}-range" class="container tabber-noactive dropdown-menu" style="position: absolute; z-index: 10; top: 100%; left: 0; min-width: max-content; width: 170px; padding: 5px 0; margin: 0; list-style: none; background-color: #fff; border: 1px solid #ccc; border-radius: 5px; flex-direction: column; gap: 5px;">
+
{{FiltreÉlément
<div data-element="label-input" data-id="{{{id|{{{Nom|}}}}}}-min" data-type="number" data-min="0" data-max="135" data-value="0" data-style="display: inline-block; vertical-align: middle; margin-right: 10px; width: 40px; height: 20px; border: 1px solid #ccc; border-radius: 3px; appearance: none;">{{ucfirst:{{{Nom|}}}}} min.</div>
+
|Élément=button
<div data-element="label-input" data-id="{{{id|{{{Nom|}}}}}}-max" data-type="number" data-min="0" data-max="135" data-value="135" data-style="display: inline-block; vertical-align: middle; margin-right: 10px; width: 40px; height: 20px; border: 1px solid #ccc; border-radius: 3px; appearance: none;">{{ucfirst:{{{Nom|}}}}} max.</div>
+
|id={{{id}}}-range
 +
|Nom={{{Nom|}}}
 +
}}
 +
<div id="{{{id|{{{Nom|}}}}}}-range" class="container tabber-noactive dropdown-menu" style="position: absolute; z-index: 10; top: 100%; left: 0; min-width: max-content; width: 170px; padding: 5px 0; margin: 0; list-style: none; background-color: #fff; border: 1px solid #ccc; border-radius: 5px; flex-direction: column; gap: 5px; max-height: 180px; overflow-y: auto;" {{#if:{{{param|}}}|data-param="{{{param}}}"}}>
 +
{{FiltreÉlément
 +
|Élément=number
 +
|id={{{id}}}-min
 +
|Nom={{ucfirst:{{{Nom|}}}}} min.
 +
|min={{{min|}}}
 +
|max={{{max|}}}
 +
}}
 +
{{FiltreÉlément
 +
|Élément=number
 +
|id={{{id}}}-max
 +
|Nom={{ucfirst:{{{Nom|}}}}} max.
 +
|value={{{max|}}}
 +
|min={{{min|}}}
 +
|max={{{max|}}}
 +
}}
 
</div>
 
</div>
 +
<div class="tabber-noactive" style="position: absolute; top: -10px; right: 0; border: 2px green solid; border-radius: 100%; padding: 0 6px; justify-content: center; font-weight: bold; color: green; background: lightgreen;">0</div>
 
|Checkbox=
 
|Checkbox=
<div id="{{{id|}}}" class="container tabber-noactive dropdown-menu" style="position: absolute; z-index: 10; top: 100%; left: 0; min-width: max-content; width: 170px; padding: 5px 0; margin: 0; list-style: none; background-color: #fff; border: 1px solid #ccc; border-radius: 5px; flex-direction: column; gap: 5px;">
+
{{FiltreÉlément
 +
|Élément=button
 +
|id={{{id}}}
 +
|Nom={{{Nom|}}}
 +
}}
 +
<div id="{{{id}}}" class="container tabber-noactive dropdown-menu" style="position: absolute; z-index: 10; top: 100%; left: 0; min-width: max-content; width: 170px; padding: 5px 0; margin: 0; list-style: none; background-color: #fff; border: 1px solid #ccc; border-radius: 5px; flex-direction: column; gap: 5px; max-height: 180px; overflow-y: auto;" {{#if:{{{param|}}}|data-param="{{{param}}}"}}>
 
{{#if:{{{Checkbox1|}}}|
 
{{#if:{{{Checkbox1|}}}|
<div data-element="label-input" data-id="{{{id1|{{{Checkbox1}}}}}}" data-type="checkbox" data-style="display: inline-block; vertical-align: middle; margin-right: 10px; width: 20px; height: 20px; border: 1px solid #ccc; border-radius: 3px; margin-left: 0;">{{ucfirst:{{{Checkbox1}}}}}</div>
+
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id1|{{{Checkbox1}}}}}}}}
 +
|Nom={{{Checkbox1}}}
 
}}
 
}}
{{#if:{{{Checkbox2|}}}|
+
}} {{#if:{{{Checkbox2|}}}|
<div data-element="label-input" data-id="{{{id2|{{{Checkbox2}}}}}}" data-type="checkbox" data-style="display: inline-block; vertical-align: middle; margin-right: 10px; width: 20px; height: 20px; border: 1px solid #ccc; border-radius: 3px; margin-left: 0;">{{ucfirst:{{{Checkbox2}}}}}</div>
+
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id2|{{{Checkbox2}}}}}}}}
 +
|Nom={{{Checkbox2}}}
 
}}
 
}}
{{#if:{{{Checkbox3|}}}|
+
}} {{#if:{{{Checkbox3|}}}|
<div data-element="label-input" data-id="{{{id3|{{{Checkbox3}}}}}}" data-type="checkbox" data-style="display: inline-block; vertical-align: middle; margin-right: 10px; width: 20px; height: 20px; border: 1px solid #ccc; border-radius: 3px; margin-left: 0;">{{ucfirst:{{{Checkbox3}}}}}</div>
+
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id3|{{{Checkbox3}}}}}}}}
 +
|Nom={{{Checkbox3}}}
 
}}
 
}}
{{#if:{{{Checkbox4|}}}|
+
}} {{#if:{{{Checkbox4|}}}|
<div data-element="label-input" data-id="{{{id4|{{{Checkbox4}}}}}}" data-type="checkbox" data-style="display: inline-block; vertical-align: middle; margin-right: 10px; width: 20px; height: 20px; border: 1px solid #ccc; border-radius: 3px; margin-left: 0;">{{ucfirst:{{{Checkbox4}}}}}</div>
+
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id4|{{{Checkbox4}}}}}}}}
 +
|Nom={{{Checkbox4}}}
 
}}
 
}}
{{#if:{{{Checkbox5|}}}|
+
}} {{#if:{{{Checkbox5|}}}|
<div data-element="label-input" data-id="{{{id5|{{{Checkbox5}}}}}}" data-type="checkbox" data-style="display: inline-block; vertical-align: middle; margin-right: 10px; width: 20px; height: 20px; border: 1px solid #ccc; border-radius: 3px; margin-left: 0;">{{ucfirst:{{{Checkbox5}}}}}</div>
+
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id5|{{{Checkbox5}}}}}}}}
 +
|Nom={{{Checkbox5}}}
 
}}
 
}}
{{#if:{{{Checkbox6|}}}|
+
}} {{#if:{{{Checkbox6|}}}|
<div data-element="label-input" data-id="{{{id6|{{{Checkbox6}}}}}}" data-type="checkbox" data-style="display: inline-block; vertical-align: middle; margin-right: 10px; width: 20px; height: 20px; border: 1px solid #ccc; border-radius: 3px; margin-left: 0;">{{ucfirst:{{{Checkbox6}}}}}</div>
+
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id6|{{{Checkbox6}}}}}}}}
 +
|Nom={{{Checkbox6}}}
 
}}
 
}}
 +
}} {{#if:{{{Checkbox7|}}}|
 +
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id7|{{{Checkbox7}}}}}}}}
 +
|Nom={{{Checkbox7}}}
 +
}}
 +
}} {{#if:{{{Checkbox8|}}}|
 +
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id8|{{{Checkbox8}}}}}}}}
 +
|Nom={{{Checkbox8}}}
 +
}}
 +
}} {{#if:{{{Checkbox9|}}}|
 +
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id9|{{{Checkbox9}}}}}}}}
 +
|Nom={{{Checkbox9}}}
 +
}}
 +
}} {{#if:{{{Checkbox10|}}}|
 +
{{FiltreÉlément
 +
|Élément=checkbox
 +
|id={{{id}}}-{{lcfirst:{{{id10|{{{Checkbox10}}}}}}}}
 +
|Nom={{{Checkbox10}}}
 +
}}
 +
}}
 +
</div>
 +
<div class="tabber-noactive" style="position: absolute; top: -10px; right: 0; border: 2px green solid; border-radius: 100%; padding: 0 6px; justify-content: center; font-weight: bold; color: green; background: lightgreen;">0</div>
 
}}
 
}}
 +
<noinclude>[[Catégorie:Nouveaux modèles]]</noinclude>

Version actuelle datée du 27 octobre 2023 à 23:15