경고: 로그인하지 않았습니다. 편집을 하면 IP 주소가 공개되게 됩니다. 로그인하거나 계정을 생성하면 편집자가 사용자 이름으로 기록되고, 다른 장점도 있습니다. 스팸 방지 검사입니다. 이것을 입력하지 마세요!{{Documentation subpage}} <!-- Add categories where indicated at the bottom of this page and interwikis at Wikidata --> {{Uses TemplateStyles|Template:Nowrap/styles.css}} {{tlx|Nowrap}} or {{tlx|nowrap}} stops wrapping of specific text. It prevents word wraps (line breaks) within text or inside a link which contains spaces, hyphens ("-"), or, in some browsers, parentheses. The size of the nowrapped text becomes the minimum width of that paragraph and that can negatively influence the ability of the page to adapt to smaller screens, or alternate representations of the content. == Usage == :: <code><nowiki>{{Nowrap|these words stay together}}</nowiki></code> :: <code><nowiki>{{Nowrap|a, b, c, or d.}}</nowiki></code> :: <code><nowiki>{{Nowrap| merry-go-round }}</nowiki></code> :: <code><nowiki>{{Nowrap| [[4-part harmony]] }}</nowiki></code> :: <code><nowiki>{{Nowrap| [[Cascading Style Sheets|CSS]] }}</nowiki></code> :: <code><nowiki>{{Nowrap| [[#Examples|Examples section]] }}</nowiki></code> === Examples === {| class=wikitable |"<code>They held <nowiki>{{Nowrap|10 kg (22 lb)}}</nowiki> in total.</code>" <br/> May render like this: :They held {{Nowrap|10 kg (22 lb)}} <br/>in total. <br/> Or like this: :They held <br/>10 kg (22 lb) in total. <br/> But ''not'' render like this: :They held 10 kg (22 <br/>lb) in total. | "<code>He encountered <nowiki>{{Nowrap|a tiger}}</nowiki> in the woods.</code>" <br/> May render like this: :He encountered a tiger <br/>in the woods. <br/> Or like this: :He encountered <br/>a tiger in the woods. <br/> But ''not'' like this: :He encountered a <br/>tiger in the woods. |} === Handling equal-sign or bar === [[Help:Templates|Templates]] have problems with parameter data that contains equal-signs "<code>=</code>" or vertical bars "<code>|</code>" (pipes). Note that this does not apply if the equal-sign "<code>=</code>" or vertical bar "<code>|</code>" is inside a wikilink or another template. However, there are workarounds: For text that includes an equal-sign "=", precede the text with <code>1=</code>, use a triple-brace unnamed parameter <code><nowiki>{{{|=}}}</nowiki></code>, or the <code><nowiki>{{=}}</nowiki></code> template. For example: :<code><nowiki>{{Nowrap|</nowiki>1=2 + 2 = 4}}</code>, <br /><code><nowiki>{{Nowrap|2 + 2 {{{|=}}} 4}}</nowiki></code>, or <br /><code><nowiki>{{Nowrap|2 + 2 {{=}} 4}}</nowiki></code> which all render as this: :{{Nowrap|1=2 + 2 = 4}}. For text that includes a vertical bar "|", escape the bar(s) with "<code><nowiki>&#124;</nowiki></code>" or "<code><nowiki>{{!}}</nowiki></code>". For instance, put two bars "|6|" like this: :<code><nowiki>{{Nowrap|</nowiki>&#124;6&#124; < 7}}</code> or <code><nowiki>{{Nowrap|{{!}}6{{!}} < 7}}</nowiki></code> Which renders this: :{{Nowrap||6| < 7}} == Technical details == The actual code that does the job is this HTML {{tag|span|open|link=yes}} tag that applies a class to the text inside the template: <syntaxhighlight lang="html"> <span class="nowrap">This text will not wrap</span> </syntaxhighlight> The class <code>nowrap</code> receives the CSS property <syntaxhighlight lang="css" inline>white-space: nowrap;</syntaxhighlight> in {{Blue|MediaWiki:Common.css}}. == TemplateData == {{TemplateData header}} <templatedata> { "description": { "en": "Prevents word wraps (line breaks) within text or inside a link which contains spaces or hyphens (-).", "cs": "Zabraňuje zalamování slov (zalomení řádků) v textu nebo uvnitř odkazu, který obsahuje mezery nebo spojovníky (-)." }, "format": "inline", "params": { "1": { "label": { "en": "Text", "cs": "Text" }, "description": { "en": "Text or link to be protected.", "cs": "Text nebo odkaz, který má být chráněn." }, "type": "string", "required": true } } } </templatedata> <includeonly>{{Sandbox other|| <!-- Categories below this line; interwikis at Wikidata --> [[Category:Formatting templates]] }}</includeonly> 요약: 풉키위키 [스타시티즌 위키]에서의 모든 기여는 크리에이티브 커먼즈 저작자표시 라이선스로 배포된다는 점을 유의해 주세요 (자세한 내용에 대해서는 Sc wiki:저작권 문서를 읽어주세요). 만약 여기에 동의하지 않는다면 문서를 저장하지 말아 주세요. 또한, 직접 작성했거나 퍼블릭 도메인과 같은 자유 문서에서 가져왔다는 것을 보증해야 합니다. 저작권이 있는 내용을 허가 없이 저장하지 마세요! 취소 편집 도움말 (새 창에서 열림) 이 문서에서 사용한 틀: 틀:Blue (편집) 틀:Documentation subpage (편집) 틀:Nowrap (편집) 틀:Sandbox other (편집) 틀:Tag (편집) 틀:TemplateData header (편집) 틀:Tlx (편집) 틀:Uses TemplateStyles (편집)