Template:Strings subpage: Difference between revisions

From Open Fortress Wiki
Jump to navigation Jump to search
(Created page with "{{Doc}} <includeonly> <onlyinclude>{{#ifeq: {{SUBPAGENAME}} | strings |<!-- -->__NOINDEX__<!-- - Language switcher - -->{{ulf | en = {{{en|}}} | ar = {{{ar|}}} | ca = {{{ca|}}} | cs = {{{cs|}}} | de = {{{de|}}} | el = {{{el|}}} | en-GB = {{{en-GB|}}} | eo = {{{eo|}}} | es = {{{es|}}} | et = {{{et|}}} | fi = {{{fi|}}} | fr = {{{fr|}}} | he = {{{he|}}} | hr = {{{hr|}}} | hu = {{{hu|}}} | it = {{{it|}}} | ja = {{{ja|}}} | ka = {{{ka|}}} | ko = {{{ko|...")
 
No edit summary
Line 47: Line 47:
--><div style="{{text-dir|rtl=direction:rtl;}} display:flex; flex-direction:column; justify-content:center; background-color:rgba(159,159,159,.05); border:1px solid rgba(159,159,159,.3); border-{{text-dir|ltr=left|rtl=right}}:4px solid #9F9F9F; border-radius:3px; overflow:hidden; position:relative; padding:10px; margin:6px 0">
--><div style="{{text-dir|rtl=direction:rtl;}} display:flex; flex-direction:column; justify-content:center; background-color:rgba(159,159,159,.05); border:1px solid rgba(159,159,159,.3); border-{{text-dir|ltr=left|rtl=right}}:4px solid #9F9F9F; border-radius:3px; overflow:hidden; position:relative; padding:10px; margin:6px 0">
<div style="opacity:.05; user-select:none; pointer-events:none; position:absolute; {{text-dir|ltr=right|rtl=left}}:-32px">[[File:icon-settings.png|64px|link=]]</div>
<div style="opacity:.05; user-select:none; pointer-events:none; position:absolute; {{text-dir|ltr=right|rtl=left}}:-32px">[[File:icon-settings.png|64px|link=]]</div>
<div style="font-size:16px; color:white">{{Strings subpage/strings|sos}}</div>
<div style="font-size:16px;">{{Strings subpage/strings|sos}}</div>
<div style="display: flex; flex-direction: row; align-items: center">{{#switch:{{Intlang}}
<div style="display: flex; flex-direction: row; align-items: center">{{#switch:{{Intlang}}
| #default = It contains various translatable and untranslatable strings that are used in the template or anywhere else.
| #default = It contains various translatable and untranslatable strings that are used in the template or anywhere else.

Revision as of 02:29, 4 January 2025

Template Documentation [subpage/Doc&action=edit edit]

A panel indicating that the page it is on contains strings that are used in lieu of complicated {{autolang}}s on the base page.

Looking for creating a Strings subpage?

If you are looking for creating a strings subpage, just create a "/strings" subpage, then paste the following code:

See the code
{{Strings subpage<!-- Don't forget to update once you add new translation to a strings. --> |number = 1 | en = 1 | de = 1 | eo = 1 | es = 1 | fi = 1 | fr = 1 | ru = 1 | vi = 1 | zh = 1 }} * {{{{PAGENAME}}|Example}} <includeonly><onlyinclude>{{#switch:{{{1}}}<!-- Remember to keep this clean by sorting A-Z, and copy paste the tab space instead of pressing "SPACE" repeatedly. --> | Example = {{#switch: {{language}} | #default = Example | de = Beispiel | eo = Ekzemplo | es = Ejemplo | fi = Esimerkki | fr = Exemple | ru = Пример | vi = Ví dụ | zh = 示例 }} }}</onlyinclude></includeonly>
Note:(Not required), but when you add a new language, it is recommended to sort the language codes from A to Z.

Parameters and Examples

Parameter Description Example
No Parameters Places the template.
{{Strings subpage}}
{{{number}}} Number of strings.
| number = 6
{{{<language code>}}} Number of translated strings into the specified language.
| en = 6
| eo = 3
| he = 2

When creating a new strings subpage, click on the three dots in the top right of the documentation box and click "Strings". This will create a new strings subpage with the proper formatting already applied. Of course, this is not required and you can just create a new one from scratch if you so wish.