Actions

Modèle

« Div col » : différence entre les versions

Aucun résumé des modifications
Aucun résumé des modifications
 
(3 versions intermédiaires par le même utilisateur non affichées)
Ligne 1 : Ligne 1 :
<templatedata>
<includeonly><div class="div-col columns column-width" style="{{column-width|{{{colwidth|30em}}}}} <!--
{
-->{{#if: {{{gap|}}}
    "description": "Breaks a list into columns. It automatically breaks each column to an equal space, so you do not manually have to find the half way point on two columns. The list is closed with {{div col end}}.",
    | {{column-gap|{{{gap}}}}} }}<!--
    "params": {
-->{{#switch: {{{rules|}}}
        "cols": {
    | = <!--empty-->
            "label": "cols",
    | yes = {{column-rule}}
            "description": "Specifies the number of columns.",
    | {{Column-rule|{{{rules}}}}} }} <!--
            "type": "string",
-->{{#ifeq: {{{small|}}}|yes
            "default": "2",
    | font-size:90%; }} <!--
            "aliases": ["1"],
-->{{#if: {{{style|}}}
            "required": false
    | {{{style}}} }}"><!--
        },
-->{{#if: {{{content|}}}
        "colwidth": {
     |{{{content}}}
            "label": "colwidth",
</div>}}<!-- Inventory how many pages use small=yes
            "description": "Specifies the width of columns, and determines dynamically the number of columns based on screen width; more columns will be shown on wider displays. This overrides the 'cols' setting.",
-->{{#ifeq: {{{small|}}}|yes
            "type": "string",
    |[[Category:Pages using div col with small parameter]]}}</includeonly>
            "aliases": ["2"],
{{#invoke:Check for unknown parameters|check|unknown={{main other|[[Category:Pages using div col with unknown parameters|_VALUE_{{PAGENAME}}]]}}|preview=Page using [[Template:Div col]] with unknown parameter "_VALUE_"; use colwidth= to specify column size |ignoreblank=y | colwidth | content | gap | rules | small | style }}
            "required": false
        },
        "colgap": {
            "label": "colgap",
            "description": "Specifies the width of gaps between columns, must be non-zero if rules are used (the default is 1em if rules is set, otherwise don't set any gap).",
            "type": "string",
            "aliases": ["3"],
            "required": false
        },
        "rules": {
            "label": "rules",
            "description": "Produces vertical rules between the columns if set to yes.",
            "type": "string",
            "required": false
        },
        "small": {
            "label": "small",
            "description": "Specifies small font size (90%) if set to yes.",
            "type": "string",
            "required": false
        },
        "style": {
            "label": "style",
            "description": "Specify any custom styling.",
            "type": "string",
            "required": false
        }
     }
}</templatedata>
 
<noinclude>
[[Category:Modèle]]
</noinclude>

Dernière version du 21 juillet 2020 à 16:45