« Modèle:Note » : différence entre les versions

De wiki-spl
Aller à la navigation Aller à la recherche
test0>Kghbln
(this is unbelievable)
m (113 versions importées)
 
(10 versions intermédiaires par 3 utilisateurs non affichées)
Ligne 1 : Ligne 1 :
<languages/>
<languages/>
<onlyinclude>{{#switch:<translate></translate>
<onlyinclude>{{#if: {{#if:{{{1|{{{text|}}}}}}|{{{1|{{{text|}}}}}}|{{#if:<noinclude>demo</noinclude>|demo|{{{demo|}}}}} }} | <templatestyles src="Note/styles.css" /><div role="note" class="note note-{{#switch: {{{2|{{{type|}}}}}}
| =
{{#if: {{#if:{{{1|}}}|{{{1}}}|{{#if:<noinclude>demo</noinclude>|demo|{{{demo|}}}}} }} | <templatestyles src="Note/styles.css" /><div role="note" class="note note-{{#switch:{{{2|}}}
     |gotcha=error
     |gotcha=error
     |=info
     |=info
     |#default={{{2|}}}
     |#default={{{2|{{{type|}}}}}}
     }} {{#if:{{{inline|}}}|note-inline}}">{{{1}}}</div>
     }} {{#ifeq:{{{inline|}}}|1|note-inline}}">{{{1|{{{text}}}}}}</div>
   | [[File:20px-OOjs_UI_icon_lightbulb-20_fc3.svg.png|18px|<translate><!--T:1--> Note</translate>|link=]]&nbsp;'''<translate><!--T:2--> Note:</translate>''' }}
   | [[File:OOjs UI icon lightbulb-20 fc3.svg|18px|<translate><!--T:1--> Note</translate>|link=]]&nbsp;'''<translate><!--T:2--> Note:</translate>''' }}<!--
| #default=
--></onlyinclude>
  {{#invoke:Template translation|renderTranslatedTemplate|template=Template:Note|noshift=1}}
}}</onlyinclude>
{{documentation|content=
{{documentation|content=
<translate>
<translate>
Ligne 16 : Ligne 12 :
</translate>
</translate>
<pre>
<pre>
{{note|Foo}}
{{Note|Foo}}
{{note|Foo|reminder}}
{{Note|Foo|info}}
{{note|Foo|error}}
{{Note|Foo|reminder}}
{{note|Foo|gotcha}}
{{Note|Foo|warn}}
{{tip|Foo}}
{{Note|Foo|error}}
{{note}} <translate><!--T:6--> Loose test</translate>
{{Note}} <translate nowrap><!--T:6--> Loose test</translate>
{{tip}} <translate><!--T:7--> Loose test</translate>


* Text {{note|Foo|inline=1}}
* Text {{Note|Foo|inline=1}}
</pre>
</pre>
{{note|Foo}}
{{Note|Foo}}
{{note|Foo|reminder}}
{{Note|Foo|info}}
{{note|Foo|error}}
{{Note|Foo|reminder}}
{{note|Foo|gotcha}}
{{Note|Foo|warn}}
{{tip|Foo}}
{{Note|Foo|error}}
{{note}} <translate><!--T:4--> Loose test</translate>
{{Note}} <translate><!--T:4--> Loose test</translate>


{{tip}} <translate><!--T:5--> Loose test</translate>
* Text {{Note|Foo|inline=1}}


* Text {{note|Foo|inline=1}}
== Parameters ==


<templatedata>
{{Note/doc}}
{
"params": {
"1": {
"type": "content",
"label": "Text",
"required": true
},
"2": {
"label": "Type",
"description": "'reminder', 'error', 'gotcha' or nothing. Will affect formatting.",
"type": "line"
},
"inline": {
"label": "Inline formatting",
"description": "Show the template without line breaks before and after it",
"type": "line"
}
},
"format": "inline",
"description": "Show a note in a box (e.g. a top-of-the-page warning)."
}
</templatedata>


}}
}}
[[Category:Templates{{#translation:}}|{{PAGENAME}}]]
[[Category:Templates{{#translation:}}|{{PAGENAME}}]]

Dernière version du 14 novembre 2021 à 14:21

<languages/>

{{#if: {{#if:||{{#if:demo|demo|}} }} | <templatestyles src="Note/styles.css" />

{{{text}}}
 | <translate> Note</translate> <translate> Note:</translate> }}

{{#invoke:documentation|main|_content={{ {{#invoke:documentation|contentTitle}}}}}}{{#if:<translate>

Usage

</translate>

{{Note|Foo}}
{{Note|Foo|info}}
{{Note|Foo|reminder}}
{{Note|Foo|warn}}
{{Note|Foo|error}}
{{Note}} <translate nowrap><!--T:6--> Loose test</translate>

* Text {{Note|Foo|inline=1}}

{{#if: {{#if:Foo|Foo|{{#if:|demo|}} }} | <templatestyles src="Note/styles.css" />

Foo
 | <translate> Note</translate> <translate> Note:</translate> }}

{{#if: {{#if:Foo|Foo|{{#if:|demo|}} }} | <templatestyles src="Note/styles.css" />

Foo
 | <translate> Note</translate> <translate> Note:</translate> }}

{{#if: {{#if:Foo|Foo|{{#if:|demo|}} }} | <templatestyles src="Note/styles.css" />

Foo
 | <translate> Note</translate> <translate> Note:</translate> }}

{{#if: {{#if:Foo|Foo|{{#if:|demo|}} }} | <templatestyles src="Note/styles.css" />

Foo
 | <translate> Note</translate> <translate> Note:</translate> }}

{{#if: {{#if:Foo|Foo|{{#if:|demo|}} }} | <templatestyles src="Note/styles.css" />

Foo
 | <translate> Note</translate> <translate> Note:</translate> }}

{{#if: {{#if:||{{#if:|demo|}} }} | <templatestyles src="Note/styles.css" />

{{{text}}}
 | <translate> Note</translate> <translate> Note:</translate> }} <translate> Loose test</translate>
  • Text {{#if: {{#if:Foo|Foo|{{#if:|demo|}} }} | <templatestyles src="Note/styles.css" />
    Foo
 | <translate> Note</translate> <translate> Note:</translate> }}

Parameters

{{#switch:<translate></translate> | = {{#if:{{#ifexpr: ( {{#ifeq:note|doc|1|0}} or ( {{#ifeq:{{#titleparts:modèle:note|-1|-2}}|doc|1|0}} and {{#if:{{#invoke:Template translation|getLanguageSubpage}}|1|0}} ) )|1|}}

    | 

{{#ifeq:show |show

         | Modèle:Mbox
        }}{{#if: |
         |   {{#ifexist:Modèle:Note
                  | [[Category:{{#switch:Modèle
                          | Template | Project = Template
                          | Module   = Module
                          | User     = User
                          | #default = MediaWiki
                      }} documentation pages{{#translation:}}]]
                  | [[Category:Documentation subpages without corresponding pages{{#translation:}}]]
                 }}
        }}
    | 
   }}

| #default=

 {{#invoke:Template translation|renderTranslatedTemplate|template=Template:Documentation subpage|noshift=1|uselang=⧼lang⧽}}

}} Modèle:TemplateData header <templatedata> { "format": "inline", "description": { "en": "Show a note in a box (e.g. a top-of-the-page warning).", "tr": "Bir kutuda bir not gösterin (ör. sayfanın üstü uyarısı)." }, "params": { "inline": { "label": { "en": "Inline formatting", "tr": "Satır içi biçimlendirme" }, "description": { "en": "Show the template without line breaks before and after it.", "tr": "Şablonu, öncesinde ve sonrasında satır kesmeleri olmadan gösterin." }, "default": "0", "autovalue": "1", "type": "boolean" }, "type": { "aliases": [ "2" ], "label": { "en": "Type", "tr": "Tür" }, "description": { "en": "One of “info”, “reminder”, “warn”, or “error”. This setting affects the color and icon.", "tr": "“info”, “reminder”, “warn” veya “error” değerlerden biri. Bu ayar, rengi ve simgeyi etkiler." }, "suggestedvalues": [ "info", "reminder", "warn", "error" ], "default": "info", "type": "string" }, "1": { "aliases": [ "text" ], "label": { "en": "Text", "tr": "Metin" }, "description": { "en": "Informative note.", "tr": "Bilgilendirecek not." }, "required": true, "type": "content" } }, "paramOrder": [ "inline", "type", "1" ] } </templatedata> Modèle:Sandbox other| [[Category:Template documentation pages{{#translation:}}]] }} [[Category:Templates{{#translation:}}|Note]]