Difference between revisions of "Template:Cc"

From Data JW United
Jump to navigation Jump to search
m (Administrator moved page Template:Cs to Template:Cc without leaving a redirect)
 
(2 intermediate revisions by the same user not shown)
Line 5: Line 5:
 
! Code !! Example !! Result
 
! Code !! Example !! Result
 
|-
 
|-
| <code><nowiki>{{raw:data:cs|10|element}}</nowiki></code> || <code><nowiki>{{raw:data:cs|10|actual text}}</nowiki></code> || <div style="width:400px;">{{cs|65|actual text}} (container is 65px width)</div>
+
| <code><nowiki>{{raw:data:cc|10|element}}</nowiki></code> || <code><nowiki>{{raw:data:cc|10|actual text}}</nowiki></code> || <div style="width:400px;">{{cc|65|actual text}} (container is 65px width)</div>
 
|-
 
|-
| <code><nowiki>{{raw:data:cs|c|10|element}}</nowiki></code> || <code><nowiki>{{raw:data:cs|c|10|actual text}}</nowiki></code> || <div style="width:400px;">{{cs|c|65|actual text}}</div>
+
| <code><nowiki>{{raw:data:cc|c|10|element}}</nowiki></code> || <code><nowiki>{{raw:data:cc|c|10|actual text}}</nowiki></code> || <div style="width:400px;">{{cc|c|65|actual text}}</div>
 
|}
 
|}
 
</noinclude>
 
</noinclude>
 
<includeonly>
 
<includeonly>
{{#ifeq: {{{1}}} |c| <div style="margin:0 auto;width:{{{2}}}px;">{{{3}}}</div> | <div style="width:{{{1}}}px;">{{{2}}}</div>}}
+
{{#ifeq: {{{1}}} |c| <div style="margin:0 auto;max-width:{{{2}}}px;">{{{3}}}</div> | <div style="max-width:{{{1}}}px;">{{{2}}}</div>}}
 
</includeonly>
 
</includeonly>

Latest revision as of 16:10, 9 November 2020

This template is used to create a container of a certain width.

Code Example Result
{{raw:data:cc|10|element}} {{raw:data:cc|10|actual text}}
actual text
(container is 65px width)
{{raw:data:cc|c|10|element}} {{raw:data:cc|c|10|actual text}}
actual text