साँचा:Element cell/doc

मुक्त ज्ञानकोश विकिपीडिया से
नेविगेशन पर जाएँ खोज पर जाएँ

{{

 साँचा:namespace detect

| type = notice | image = | imageright = | class = | style = margin-bottom:1.0em; | textstyle = | text = साँचा:strong for साँचा:terminate sentence
It contains usage information, categories and other content that is not part of the original साँचा page. | small = | smallimage = | smallimageright = | smalltext = | subst = | date = | name = }}

Usage

colspan=8 style="background:साँचा:element color" | साँचा:tnavbar-header
pattern:
{| |- | {{element cell-...}} |}
cell cell-named cell-large cell property cell AQ cell image cell-1
साँचा:element cell
साँचा:element cell-named
साँचा:element cell-large
साँचा:element cell property
साँचा:element cell AQ
साँचा:element cell image
साँचा:element cell-1
colspan=8 style="text-align:left; background:साँचा:element color;" | See also: Template:Element colorसाँचा:middotTemplate:Element frame

The template produces a content in formatted CSS style for a single element cell (to be used in a periodic table). It is part of a series. साँचा:clear

Parameters

All parameters are optional.

{{element cell
| 1= atomic number Z
| 2= element name
| link= wikipedia page (creates a wikilink like [[Mercury (element)|mercury]]. Formerly parameter 8=)
| 3= symbol
| 4= (not used)
| 5= state of matter (sets font color)
| 6= metal–nonmetal category name (sets background color)
| bg= background color (overrides 6; can look like bg=#aabbcc. Formerly parameter 9=
| 7= occurrence (sets cell border style)
| border= sets border style, (overrides 7. Like: border=3px solid red)
| style= adds or overrides style settings (do not add the "" quotes)

| title= (mousehover text, overrides title composed from 2: 6; 5; 7)
| legend= (overrides legend text that was composed from 6; 5; 7)
}}

Plain for c/e

{{element cell
| 1=
| 2=
| link=
| 3=
| 4=
| 5=
| 6=
| bg=
| 7=
| border=
| style=

| title=
| legend=
}}

Example Hg, in wikitable:

 {|
 |-
 | {{element cell|80|mercury|Hg||Liquid|Transition metals|Primordial|link=mercury (element)}}
 |}
साँचा:element cell
Top row

Parameter 1, usually the atomic number, is put in the top row unlinked. If this parameter is present, a <br/> is added. The font color is set by parameter 5, usually the state of matter key.

Asterisk (*)

To add a plain asterisk, as is done to mark lanthanides and actinides, add them in साँचा:code tags in parameter #1 like this:

 | {{element cell|<nowiki>*</nowiki>|Lanthanides}}
Page link

The cell links to parameter 2, usually the element name. If the page name is not the element name, as with साँचा:code, the correct pagename can be set through साँचा:code.

Label

The link is labeled with parameter 3 (usually the symbol): साँचा:code. If there is no link provided (no parameter 2, no link=), parameter 3 will show as unlinked text.

Background

The background color is set by parameter 6, usually the category name. It can be set by parameter bg: साँचा:code. Parameter bg is used for just a color, with no legend meaning (no text in the title).

Frame (cell border)

The frame style is set via parameter 7, usually the occurrence. It can be overridden by using साँचा:code. This sets the border (frame), but does not have a legend meaning (no text in the title).

Style

All style can be set (and overridden) by using the style parameter: साँचा:code. Do not add quotes ("").

Title

The title (mousehover text) is created from params 1: 6; 7; 5. (name: category; occurrence; state of matter).
The emercury example will give: साँचा:code
When parameters साँचा:code or साँचा:code are used, their setting is not added to the title (they are meaningless). The title can be set (overridden) to any text, including a blank, by using साँचा:code

Legend

The legend is composed from parameters 6, 5 and 7. It can be overridden by using साँचा:code. (This can be useful in combination with setting साँचा:code).

Example using parameters
 {|
 |-
 | {{element cell|one|two|three|bg=yellow|border=3px solid red|link=Main page|title=Some example}}
 |}
साँचा:element cell

Tracking

Pages that could have issues with this template are listed in Category:Element pages that need attention for the legend for maintenance. साँचा:as of.

See also

colspan=8 style="background:साँचा:element color" | साँचा:tnavbar-header
pattern:
{| |- | {{element cell-...}} |}
cell cell-named cell-large cell property cell AQ cell image cell-1
साँचा:element cell
साँचा:element cell-named
साँचा:element cell-large
साँचा:element cell property
साँचा:element cell AQ
साँचा:element cell image
साँचा:element cell-1
colspan=8 style="text-align:left; background:साँचा:element color;" | See also: Template:Element colorसाँचा:middotTemplate:Element frame

साँचा:periodic table templates