Modèle:FiltreModule : Différence entre versions

[version non vérifiée][version non vérifiée]
Ligne 1 : Ligne 1 :
 
{{#switch: {{{1|}}}
 
{{#switch: {{{1|}}}
 
|Bouton=
 
|Bouton=
<div data-element="button" data-type="button" data-aria-controls="{{{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>
+
<div data-element="button" data-type="button" data-aria-controls="{{{id|}}}-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>
 
|Range=
 
|Range=
<div 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;">
+
<div id="{{{id|}}}-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;">
<div data-element="label-input" data-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>
+
<div data-element="label-input" data-id="{{{id|}}}-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>
<div data-element="label-input" data-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>
+
<div data-element="label-input" data-id="{{{id|}}}-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>
 
</div>
 
</div>
 
|Checkbox=
 
|Checkbox=
<div id="{{{Nom|}}}" 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;">
+
<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;">
 
{{#if:{{{Checkbox1|}}}|
 
{{#if:{{{Checkbox1|}}}|
<div data-element="label-input" data-id="{{{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>
+
<div data-element="label-input" data-id="{{{id1|}}}" 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;">{{{Checkbox1}}}</div>
 
}}
 
}}
 
{{#if:{{{Checkbox2|}}}|
 
{{#if:{{{Checkbox2|}}}|
<div data-element="label-input" data-id="{{{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>
+
<div data-element="label-input" data-id="{{{id2|}}}" 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;">{{{Checkbox2}}}</div>
 
}}
 
}}
 
}}
 
}}

Version du 8 mars 2023 à 20:07