Template:Cdx-message

Template documentation[view · edit · history · purge]
This documentation is transcluded from Template:Cdx-message/doc.
Category:Main message boxesCategory:Pages with content copied from English WikipediaCategory:Main message boxesCategory:Main message boxesCategory:Templates using TemplateStyles

Displays a smaller and more compact notice as compared to the {{Mbox}} series. Good for tips or notes in documentation and help pages. Not for article namespace. It looks similar to the Codex cdxMessage component, as it was originally styled to resemble it before that component became available in MediaWiki. Imported from mw:Template:Note.

Usage


Types

Standard

Standard type that appears identical to the Codex style guide cdxMessage component:

Additional

In order of visual severity, all set by default with widths like mbox templates, or an equivalent custom style of |style=margin-left: 10%; margin-right: 10%;:

Auto width

Inline use

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.

Float right

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.  Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.

Parameters

Adds message template. To inform the user of something noteworthy or give the user feedback.

Template parameters

This template prefers block formatting of parameters.

ParameterDescriptionTypeStatus
Content1 text content

Contents of notice.

Contentrequired
contentcontent

no description

Unknownoptional
texttext

no description

Unknownoptional
Type2 type

Type of notice or style to show; i.e. border/background coloring and icon. May be null to show the pin.

Suggested values
notice info success reminder flag warning warn caution error
Stringsuggested
typetype

no description

Unknownoptional
Inlineinline

If set to "true" or "1" or "yes" or "y", then will become inline instead of a block. Case-INSensitive.

Default
0
Example
1
Booleansuggested
Float rightright

If set to "true" or "1" or "yes" or "y", then will float right with restricted width of 238px. Case-INSensitive

Suggested values
1 0
Default
0
Example
1
Booleansuggested
Widthwidth

To set width to auto, then set auto.

Suggested values
auto
Default
100%
Example
auto
Stringsuggested
Classclass

Custom classes

Example
nomobile
Stringoptional
Stylestyle

Custom CSS styling

Example
padding: 0px 10%;
Contentoptional

See also

To-do
Could we change icon color with CSS filter function? Or should I reimplement entire thing following div and span tags used by new cdxMessage. And then copy their CSS for ease of use actually. Category:Message box templates
Category:Main message boxes Category:Message box templates Category:Pages with content copied from English Wikipedia Category:Templates for general use Category:Templates using TemplateStyles