Template:User settings page: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
 
(76 intermediate revisions by 6 users not shown)
Line 1: Line 1:
<onlyinclude><includeonly><div style="display: flex;align-items: center;justify-content: space-between;padding:8px;border:1px solid #525252;background-color:#3C3C3C;padding-left:20px;{{border-radius|4px}}"><div><span style="font-size:1.8em;color:white">'''Custom Settings'''</span>{{#if:{{:{{FULLPAGENAME}}}}|<h3 style=color:red>Warning: The #default value must be empty!</h3>}}
{{Doc}}
<includeonly><onlyinclude>{{ulf|en=1|hr=1|ru=1|zh=1}}<div style="display:flex; align-items:center; justify-content:space-between; padding:8px; border:1px solid #525252; background-color:#3C3C3C; padding-left:20px;{{border-radius|4px}}"><div><span style="font-size:1.8em; color:white">'''{{User settings page/strings|CustomSettings}}'''</span>{{#if:{{Settings|user={{ROOTPAGENAME}}}}|<h3 style="color:red"> Warning: The #default value must be empty! </h3>}}


'''Custom username (username):''' {{:{{FULLPAGENAME}}|username}}
'''{{User settings page/strings|txt-username}} (username):''' {{Settings|user={{ROOTPAGENAME}}|username|ifempty={{ROOTPAGENAME}}}}


'''Timestamp offset (timeoffsetdir) (timeoffseth) (timeoffsetm):''' {{#ifeq:{{:{{FULLPAGENAME}}|timeoffsetdir}}|-||+}}{{#if:{{:{{FULLPAGENAME}}|timeoffseth}}|{{:{{FULLPAGENAME}}|timeoffseth}}|0}}&#58;{{#if:{{:{{FULLPAGENAME}}|timeoffsetm}}|{{:{{FULLPAGENAME}}|timeoffsetm}}|00}}</div>
'''{{User settings page/strings|txt-timestamp-offset}} (timeoffsetdir) (timeoffseth) (timeoffsetm):''' {{#ifeq:{{Settings|user={{ROOTPAGENAME}}|timeoffsetdir}}|-|&minus;|+}}{{Settings|user={{ROOTPAGENAME}}|timeoffseth|ifempty=0}}&#58;{{Settings|user={{ROOTPAGENAME}}|timeoffsetm|ifempty=00}}<br><div style="display:flex; gap:10px; margin-top:20px"><div style="background:#4C4C4C; border:1px solid rgba(255,255,255,.1); border-radius:2px; padding:4px 8px">[[Template:User settings page|<span style="color:#E8E8E8"> {{User settings page/strings|Documentation}} </span>]]</div></div></div>
<div>{{CodeBlock|margin=0|<nowiki><onlyinclude>{{#switch:{{{1|}}}
<div>{{CodeBlock|margin=0|<nowiki>&lt;onlyinclude>{{#switch:{{{1|}}}
|username=</nowiki>{{:{{FULLPAGENAME}}|username}}<nowiki>
| username = </nowiki>{{Settings|user={{ROOTPAGENAME}}|username}}<nowiki>
|timeoffsetdir=</nowiki>{{:{{FULLPAGENAME}}|timeoffsetdir}}<nowiki>
| timeoffsetdir = </nowiki>{{Settings|user={{ROOTPAGENAME}}|timeoffsetdir}}<nowiki>
|timeoffseth=</nowiki>{{:{{FULLPAGENAME}}|timeoffseth}}<nowiki>
| timeoffseth = </nowiki>{{Settings|user={{ROOTPAGENAME}}|timeoffseth}}<nowiki>
|timeoffsetm=</nowiki>{{:{{FULLPAGENAME}}|timeoffsetm}}<nowiki>
| timeoffsetm = </nowiki>{{Settings|user={{ROOTPAGENAME}}|timeoffsetm}}<nowiki>
}}</onlyinclude></nowiki>}}</div>
| avatar format = </nowiki>{{Settings|user={{ROOTPAGENAME}}|avatar format}}<nowiki>
</div></includeonly></onlyinclude>
| avatar radius = </nowiki>{{Settings|user={{ROOTPAGENAME}}|avatar radius}}<nowiki>
| avatar rendering = </nowiki>{{Settings|user={{ROOTPAGENAME}}|avatar rendering}}<nowiki>
| avatar frame format = </nowiki>{{Settings|user={{ROOTPAGENAME}}|avatar frame format}}<nowiki>
| avatar frame size = </nowiki>{{Settings|user={{ROOTPAGENAME}}|avatar frame size}}<nowiki>
}}&lt;/onlyinclude></nowiki>}}</div>
</div>
 
<div style="display:flex; flex-direction:column; border: 1px solid #525252; background-color:#3C3C3C; padding:20px; margin-top:20px;{{border-radius|4px}}">
<h3 style="padding:0">{{User settings page/strings|Avatar}}</h3>
 
{{Note|{{User settings page/strings|Note}}}}
 
<div style="display: flex; align-items:center; background:#454545; border:1px solid rgba(255,255,255,.1); border-radius:6px; image-rendering:{{Settings|user={{ROOTPAGENAME}}|avatar rendering|ifempty=auto}}; padding:30px">
<!-- Avatar (128px) -->
<div style="display:flex; justify-content:center; align-items:center; min-width:128px; width:128px; height:128px; user-select:none"><!--
--><div style="display:flex; justify-content:center; align-items:center; width:100%; height:100%; background:#525252; border-radius:{{Settings|user={{ROOTPAGENAME}}|avatar radius|ifempty=50%}}; overflow:hidden"><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatar-{{ROOTPAGENAME}}.png}}
|[[File:UserAvatar-{{ROOTPAGENAME}}.png|link=|128px]]
|{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatar-{{ROOTPAGENAME}}.jpg}}
|[[File:UserAvatar-{{ROOTPAGENAME}}.jpg|link=|128px]]
|[[File:Icon-user.png|link=|48px]]}}}}
</div><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatarFrame-{{ROOTPAGENAME}}.png}}
|<div style="width:224px; height:224px; transform:scale(.7); display:flex; align-items:center; justify-content:center; overflow:hidden; user-select:none; position:absolute">[[{{Settings|user={{ROOTPAGENAME}}|before=File:UserAvatarFrame-{{ROOTPAGENAME}}.|avatar frame format|after={{!}}{{Settings|user={{ROOTPAGENAME}}|avatar frame size|ifempty=224px}}|ifempty=File:Empty.png}}]]</div>
|}}<!--
--></div>
<!-- Avatar (64px) -->
<div style="display:flex; justify-content:center; align-items:center; min-width:64px; width:64px; height:64px; user-select:none; margin-left:60px">
<div style="display:flex; justify-content:center; align-items:center; width:100%; height:100%; background:#525252; border-radius:{{Settings|user={{ROOTPAGENAME}}|avatar radius|ifempty=50%}}; overflow:hidden"><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatar-{{ROOTPAGENAME}}.png}}
|[[File:UserAvatar-{{ROOTPAGENAME}}.png|link=|64px]]
|{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatar-{{ROOTPAGENAME}}.jpg}}
|[[File:UserAvatar-{{ROOTPAGENAME}}.jpg|link=|64px]]
|[[File:Icon-user.png|link=|24px]]}}}}
</div><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatarFrame-{{ROOTPAGENAME}}.png}}
|<div style="width:224px; height:224px; transform:scale(.35); display:flex; align-items:center; justify-content:center; overflow:hidden; user-select:none; position:absolute">[[{{Settings|user={{ROOTPAGENAME}}|before=File:UserAvatarFrame-{{ROOTPAGENAME}}.|avatar frame format|after={{!}}{{Settings|user={{ROOTPAGENAME}}|avatar frame size|ifempty=224px}}|ifempty=File:Empty.png}}]]</div>
|}}
</div>
<!-- Avatar (40px) -->
<div style="display:flex; justify-content:center; align-items:center; min-width:40px; width:40px; height:40px; user-select:none; margin-left:40px">
<div style="display:flex; justify-content:center; align-items:center; width:100%; height:100%; background:#525252; border-radius:{{Settings|user={{ROOTPAGENAME}}|avatar radius|ifempty=50%}}; overflow:hidden"><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatar-{{ROOTPAGENAME}}.png}}
|[[File:UserAvatar-{{ROOTPAGENAME}}.png|link=|40px]]
|{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatar-{{ROOTPAGENAME}}.jpg}}
|[[File:UserAvatar-{{ROOTPAGENAME}}.jpg|link=|40px]]
|[[File:Icon-user.png|link=|16px]]}}}}
</div><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatarFrame-{{ROOTPAGENAME}}.png}}
|<div style="width:224px; height:224px; transform:scale(.22); display:flex; align-items:center; justify-content:center; overflow:hidden; user-select:none; position:absolute">[[{{Settings|user={{ROOTPAGENAME}}|before=File:UserAvatarFrame-{{ROOTPAGENAME}}.|avatar frame format|after={{!}}{{Settings|user={{ROOTPAGENAME}}|avatar frame size|ifempty=224px}}|ifempty=File:Empty.png}}]]</div>
|}}
</div>
</div>
 
<div style="display:flex; gap:10px; margin-top:20px">
<div style="background:#4c4c4c; border:1px solid rgba(255,255,255,.1); border-radius:2px; padding:4px 8px"><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatar-{{ROOTPAGENAME}}.png}}
|[[:File:UserAvatar-{{ROOTPAGENAME}}.png|<span style="color:#E8E8E8">{{User settings page/strings|ViewAvatar}}</span>]]
|{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatar-{{ROOTPAGENAME}}.jpg}}
|[[:File:UserAvatar-{{ROOTPAGENAME}}.jpg|<span style="color:#E8E8E8">{{User settings page/strings|ViewAvatar}}</span>]]
|{{User settings page/strings|UploadAvatar}}: {{Code|[[File:UserAvatar-{{ROOTPAGENAME}}.png|PNG]]}} {{Code|[[File:UserAvatar-{{ROOTPAGENAME}}.jpg|JPG]]}}}}}}
</div>
<div style="background:#4c4c4c; border:1px solid rgba(255,255,255,.1); border-radius:2px; padding:4px 8px"><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserAvatarFrame-{{ROOTPAGENAME}}.png}}
| [[:File:UserAvatarFrame-{{ROOTPAGENAME}}.png|<span style="color:#E8E8E8">{{User settings page/strings|ViewAvatarFrame}}</span>]]
| [[File:UserAvatarFrame-{{ROOTPAGENAME}}.png|{{User settings page/strings|UploadAvatarFrame}}]]}}
</div>
</div>
 
 
<h3>{{User settings page/strings|Cover}}</h3>
 
<div style="display: flex; justify-content:center; align-items:center; width:100%; height:256px; background:#353535; border-radius:6px; overflow: hidden; user-select:none; position:relative; z-index:1"><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserCover-{{ROOTPAGENAME}}.png}}
| [[File:UserCover-{{ROOTPAGENAME}}.png|link=]]
| {{#if:{{PROTECTIONEXPIRY:edit|File:UserCover-{{ROOTPAGENAME}}.gif}}
| [[File:UserCover-{{ROOTPAGENAME}}.gif|link=]]
| {{#if:{{PROTECTIONEXPIRY:edit|File:UserCover-{{ROOTPAGENAME}}.jpg}}
| [[File:UserCover-{{ROOTPAGENAME}}.jpg|link=]]
| [[File:Icon-panorama-filled.png|link=|80px]]}}}}}}
</div>
<div style="display:flex; gap:10px; margin-top:20px">
<div style="background:#4c4c4c; border:1px solid rgba(255,255,255,.1); border-radius:2px; padding:4px 8px"><!--
-->{{#if:{{PROTECTIONEXPIRY:edit|File:UserCover-{{ROOTPAGENAME}}.png}}
| [[:File:UserCover-{{ROOTPAGENAME}}.png|<span style="color:#E8E8E8">{{User settings page/strings|ViewCover}}</span>]]
| {{#if:{{PROTECTIONEXPIRY:edit|File:UserCover-{{ROOTPAGENAME}}.jpg}}
| [[:File:UserCover-{{ROOTPAGENAME}}.jpg|<span style="color:#E8E8E8">{{User settings page/strings|ViewCover}}</span>]]
| {{User settings page/strings|UploadCover}}: {{Code|[[File:UserCover-{{ROOTPAGENAME}}.png|PNG]]}} {{Code|[[File:UserCover-{{ROOTPAGENAME}}.jpg|JPG]]}}}}}}
</div>
</div>
</div></onlyinclude></includeonly>

Latest revision as of 09:44, 14 June 2024

English (en)Deutsch (de)Esperanto (eo)Español (es)Français (fr)Suomi (fi)Hrvatski (hr)Magyar (hu)Italiano (it)日本語 (ja)한국어 (ko)Nederlands (nl)Polski (pl)Português (pt)Português do Brasil (pt-br)Русский (ru)Slovenčina (sk)Svenska (sv)Türkçe (tr)Українська (uk)Tiếng Việt (vi)中文 (zh)中文(臺灣) (zh-tw)
Curly brackets white.pngTemplate Documentation [view] [edit]
Icon-translate.png Available doc translations
View
Page history
Icon-translate.png
This template uses a strings subpage
Please follow the format on this subpage(s) to add translations.

This template is used for checking the functionality of a user settings subpage Special:MyPage/Settings.

Usage

{{User settings page}}

Create your settings page

To create your settings page, click here.

Copy and Paste

{{User settings page}} <onlyinclude>{{#switch:{{{1|}}} | username = | timeoffsetdir = | timeoffseth = | timeoffsetm = | avatar format = | avatar radius = | avatar frame format = | avatar frame size = }}</onlyinclude>

Translations

The used strings are on strings subpage. Please follow the format to add translations for them.

Parameters and Examples

These are parameters that used by various templates such as {{Message}}.

Parameter Description Example
{{{username}}} Your nickname that the template should show instead of your username.
Tip.pngTip:You can use {{Autolang}} for supporting multi-language nickname.
| username = Gabe Newell
| username = {{#switch: {{language}}|#default = Gabe Newell|zh=加布·纽维尔}}
Location
{{{timeoffsetdir}}} Time direction (plus or minus) relative to UTC. The default value is +, so this parameter should only be used if you want to specify a minus
| timeoffsetdir = -
{{{timeoffseth}}} Time difference from UTC (hours)
| timeoffseth = 8
{{{timeoffsetm}}} Time difference from UTC (minutes)
| timeoffsetm = 30
Avatar
{{{avatar format}}} The file format of your avatar. Without this parameter, the image for avatar will not be used.
| avatar format = png
{{{avatar radius}}} Avatar Radius.
| avatar radius = 6px
{{{avatar rendering}}} Specifies the value for image-rendering (CSS property) in the avatar. The default value is auto.
| avatar rendering = pixelated
Avatar Frame
{{{avatar frame format}}} The file format of the frame of your avatar. Without this parameter, the frame image for avatar will not be used.
| avatar frame format = gif
{{{avatar frame size}}} It is necessary to specify the recommended resolution of the avatar frame instead of the native one. The parameter was added due to differences between static and animated avatar frames on Steam. Static avatar frames have a resolution of 244 x 244 pixels, while animated frames use the recommended 224 x 224 pixels.

Due to the way MediaWiki works, we cannot specify a fixed size for all avatar frames, because after that animated frames simply won't work.

| avatar frame size = 224px