模板:Info:修订间差异

    来自中国珂学院
    info>Nostalgia
    (Created page with "{|class="common-box" style="margin: 0px 10%; width:{{{width|80%}}}; background: #fbfbfb; border-left: 10px solid {{{color|#1e90ff}}};" |- | style="padding: 2px 0 2px 0.5em" |...")
     
    info>Honoka55
    小无编辑摘要
    第1行: 第1行:
    {|class="common-box" style="margin: 0px 10%; width:{{{width|80%}}}; background: #fbfbfb; border-left: 10px solid {{{color|#1e90ff}}};"
    <includeonly><div class="infoBox {{{class|}}}" style="width:{{{width|80%}}};border-left: 10px solid {{{color|#1e90ff}}};{{#if:{{{backgroundColor|}}}|background-color:{{{backgroundColor}}};}}"><div class="infoBoxContent" {{#if:{{{backgroundColor|}}}|style="border-color:{{{backgroundColor}}};background-color:{{{backgroundColor}}};"}}>
    |-  
    {{#if:{{{title|}}}|<div class="infoBoxTitle" style="{{{title-style|}}}">{{{title}}}</div>}}<div class="infoBoxIcon" style="{{#if:{{{backgroundColor|}}}|background-color:{{{backgroundColor}}};}}{{{icon-style|}}}">{{{leftimage|[[image:Icon-info.png|50px|link=]]}}}</div><div class="infoBoxText" style="{{{text-style|}}}">{{{text|{{{1|'''nothing (⊙_⊙)'''}}}}}}</div>{{#if:{{{below|}}}|<div class="infoBoxBelow" style="{{{below-style|}}}">{{{below}}}</div>}}
    | style="padding: 2px 0 2px 0.5em" | {{{leftimage|[[image:Icon-info.png|50px|link=]]}}}
    </div></div>{{#ifeq:{{NAMESPACENUMBER}}|10|{{#switch:{{{type|}}}
    | style="padding: 0.25em 0.5em"| <div style="{{{text-style|}}}">{{{text|{{{1|'''nothing (⊙_⊙)'''}}}}}}</div>
    | top = [[Category:Top tip]]
    |}
    | middle = [[Category:Middle tip]]
    | none =
    #default = [[Category:Top tip]] }}|}}</includeonly><noinclude>{{Documentation}}[[Category:元模板]]</noinclude>

    2017年7月15日 (六) 12:21的版本

    文档图示 模板文档[查看] [编辑] [历史] [清除缓存]

    {
    "params": {
    "1": {
    "aliases": [
    "text"
    ],
    "label": "text",
    "description": "Text to be placed within the main body.",
    "example": "Hi, this is a info box!",
    "type": "string",
    "required": true
    },
    "width": {
    "description": "width of the template. Use CSS units; % often used.",
    "example": "100px, 50%;",
    "type": "string",
    "default": "80%"
    },
    "color": {
    "description": "Color of the left bar. Use CSS color.",
    "example": "red, #6527CB, rgb(245,135,38) (rgba not recommended)",
    "type": "string",
    "default": "#1e90ff"
    },
    "leftimage": {
    "description": "An image to be placed to the left of the info box. Internal file link recommended, although external URL could be accepted.",
    "example": "Disambig gray.svg",
    "type": "wiki-file-name",
    "default": "Icon-info.png",
    "suggested": true
    },
    "text-style": {
    "description": "Additional text styles, applicable to the text argument.",
    "type": "string"
    }
    },
    "description": "Meta template for creating a variety of informational templates. Can also be used on its own.",
    "paramOrder": [
    "1",
    "width",
    "color",
    "leftimage",
    "text-style"
    ],
    "format": "block"
    }