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

De wiki-spl
Aller à la navigation Aller à la recherche
test0>Shirayuki
m (Reverted edits by 2404:130:0:1000:F8A4:6A46:9982:A0DB (talk) to last revision by Shirayuki)
m (25 versions importées)
 
(16 versions intermédiaires par 10 utilisateurs non affichées)
Ligne 1 : Ligne 1 :
{{Documentation subpage}}
{{Documentation subpage}}
== Usage ==
<!-- Add categories where indicated at the bottom of this page and interwikis at Wikidata -->
<pre>
{{TemplateData header|editlinks=1|docpage=Note/doc}}
{{note|Foo}}
<templatedata>
{{note|Foo|reminder}}
{
{{note|Foo|error}}
"format": "inline",
{{note|Foo|gotcha}}
"description": {
{{tip|Foo}}
"en": "Show a note in a box (e.g. a top-of-the-page warning).",
{{note}} Loose test
"tr": "Bir kutuda bir not gösterin (ör. sayfanın üstü uyarısı)."
{{tip}} Loose test
},
</pre>
"params": {
{{note|Foo}}
"inline": {
{{note|Foo|reminder}}
"label": {
{{note|Foo|error}}
"en": "Inline formatting",
{{note|Foo|gotcha}}
"tr": "Satır içi biçimlendirme"
{{tip|Foo}}
},
{{note}} Loose test
"description": {
 
"en": "Show the template without line breaks before and after it.",
{{tip}} Loose test
"tr": "Şablonu, öncesinde ve sonrasında satır kesmeleri olmadan gösterin."
<includeonly>
},
<!-- Categories go here, and interwikis go here -->
"default": "0",
{{languages}}
"autovalue": "1",
</includeonly>
"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>
<includeonly>{{Sandbox other||
<!-- Categories below this line; interwikis at Wikidata -->
[[Category:Templates{{#translation:}}]]
}}</includeonly>

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

{{#switch:<translate></translate> | = {{#if:{{#ifexpr: ( {{#ifeq:doc|doc|1|0}} or ( {{#ifeq:{{#titleparts:modèle:note/doc|-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>