User:Myotis/Sandbox

From SpongePedia, the First SpongeBob Wiki.
Jump to: navigation, search

Contents

[edit] Collapsible Tables

[edit] Simple example

Tables are simpler to work with, as you merely need to add the collapsible class to the table itself. For the [hide]/[show] link to appear, the table's first row must be a header row, that is, one of the cells in the first row must be declared with an exclamation mark (in wikisyntax). The use of the class wikitable in the example below is merely for appearance; it is not needed for collapsible to function.

Code entered Output produced
{| class="wikitable collapsible"
! Simple collapsible table
|-
| Lorem ipsum dolor sit amet
|}
Simple collapsible table
Lorem ipsum dolor sit amet

Using the syntax above, collapsible tables are often used to always display an introduction to, or summary of, a lengthy discussion or section of content, while hiding the majority of that content from immediate view. The summary message is put in the header cell, and the content is placed into the body cell. The content is then easily accessible by clicking the 'show' button. The collapsible functionality is also available in larger and more complicated tables, as long as there is a header cell in the first row of the table.

Code entered Output produced
{| class="wikitable collapsible"
 |A normal cell in the header row
 ! colspan="2"| Header cell spans two cols
 |-
 | colspan="2" | Lorem ipsum dolor sit amet
 | Separate body cell
 |}
A normal cell in the header row Header cell spans two cols
Lorem ipsum dolor sit amet Separate body cell

[edit] Collapsing tables by default

Just using the collapsible class produces a table which is expanded by default, but can be collapsed by the reader. It is also possible to create tables which are collapsed by default, and can be optionally expanded. There are several methods for doing this, depending on the situations in which you want the table to collapse.

[edit] 'collapsed'

Adding the collapsed class will cause the table to always be initially collapsed, no matter what happens around it. It is the simplest method for doing so. Using the examples above:

Code entered Output produced
{| class="wikitable collapsible collapsed"
! Simple collapsible table
|-
| Lorem ipsum dolor sit amet
|}
{| class="wikitable collapsible collapsed"
 |A normal cell in the header row
 ! colspan="2"| Header cell spans two cols
 |-
 | colspan="2" | Lorem ipsum dolor sit amet
 | Separate body cell
 |}

[edit] 'autocollapse'

Adding the autocollapse class causes the table to collapse when there are 2 or more collapsible tables on the page (this threshold might be different on other projects). The example below, therefore, collapses because there are numerous collapsible tables on the page.

Code entered Output produced
{| class="wikitable collapsible autocollapse"
! Simple collapsible table
|-
| Lorem ipsum dolor sit amet
|}
Simple collapsible table
Lorem ipsum dolor sit amet

[edit] 'innercollapse' and 'outercollapse'

Using this pair of classes, it is possible to make a table collapsed by default only when it is contained within a particular object, such as another table. This is mainly useful for tables inside templates, which are often nested.

Code entered Output produced
{| class="wikitable outercollapse"
! This table does not collapse
|-
| But the table inside this cell

{| class="wikitable collapsible innercollapse"
! Does collapse
|-
| Hiding this part
|}

|}
This table does not collapse
But the table inside this cell
Does collapse
Hiding this part

[edit] Other notes

[edit] Sortable tables

Collapsible tables can be combined with the sortable tables functionality without difficulty. However, because the hide/show button is placed in the first header cell located, its positioning can look a bit peculiar if the table is not wide enough:

Code entered Output produced
{| class="wikitable collapsible sortable"
!Name!!Score
|-
|John||59
|-
|Jane||100
|-
|Bob||72
|}
Name Score
John 59
Jane 100
Bob 72

Possible alternative is sortable table inside one-cell collapsible table, see example on the right.

[edit] Customization

Registered users can edit their personal js file file to change some of the variables used.

<source lang=javascript> autoCollapse = 4 //how many collapsible tables on the page before autocollapse works (default=2) var collapseCaption = 'collapse' //text of the [hide] link (default='hide') var expandCaption = 'uncollapse' //text of the [show] link (default='show') </source>




Tabelle der 216 websicheren Farben
#000 #003 #006 #009 #00C #00F
#030 #033 #036 #039 #03C #03F
#060 #063 #066 #069 #06C #06F
#090 #093 #096 #099 #09C #09F
#0C0 #0C3 #0C6 #0C9 #0CC #0CF
#0F0 #0F3 #0F6 #0F9 #0FC #0FF
#300 #303 #306 #309 #30C #30F
#330 #333 #336 #339 #33C #33F
#360 #363 #366 #369 #36C #36F
#390 #393 #396 #399 #39C #39F
#3C0 #3C3 #3C6 #3C9 #3CC #3CF
#3F0 #3F3 #3F6 #3F9 #3FC #3FF
#600 #603 #606 #609 #60C #60F
#630 #633 #636 #639 #63C #63F
#660 #663 #666 #669 #66C #66F
#690 #693 #696 #699 #69C #69F
#6C0 #6C3 #6C6 #6C9 #6CC #6CF
#6F0 #6F3 #6F6 #6F9 #6FC #6FF
#900 #903 #906 #909 #90C #90F
#930 #933 #936 #939 #93C #93F
#960 #963 #966 #969 #96C #96F
#990 #993 #996 #999 #99C #99F
#9C0 #9C3 #9C6 #9C9 #9CC #9CF
#9F0 #9F3 #9F6 #9F9 #9FC #9FF
#C00 #C03 #C06 #C09 #C0C #C0F
#C30 #C33 #C36 #C39 #C3C #C3F
#C60 #C63 #C66 #C69 #C6C #C6F
#C90 #C93 #C96 #C99 #C9C #C9F
#CC0 #CC3 #CC6 #CC9 #CCC #CCF
#CF0 #CF3 #CF6 #CF9 #CFC #CFF
#F00 #F03 #F06 #F09 #F0C #F0F
#F30 #F33 #F36 #F39 #F3C #F3F
#F60 #F63 #F66 #F69 #F6C #F6F
#F90 #F93 #F96 #F99 #F9C #F9F
#FC0 #FC3 #FC6 #FC9 #FCC #FCF
#FF0 #FF3 #FF6 #FF9 #FFC #FFF

[edit] Wirklich websichere Farben

Bei der Verwendung von 16 Bit Farbtiefe ergeben sich weitere Probleme: David Lehn und Hadley Stern haben festgestellt, dass nur 22 der 216 websicheren Farben bei 16 Bit Farbtiefe ohne Neuberechnung richtig dargestellt werden können. Sie bezeichneten diese Gruppe von 22 Farben als wirklich websichere Farbpalette. Sie besteht hauptsächlich aus grünen und gelben Farbtönen, ihre Werte sind in der folgenden Tabelle dargestellt:

#000 #F00 #003 #F03 #00F #F0F #0F0 #6F0 #FF0 #3F3 #6F3
#FF3 #0F6 #3F6 #CF6 #FF6 #0FC #3FC #0FF #3FF #6FF #FFF


Einbindung dieser Vorlage:

{{EpInfo|Title|Episode Card|Episode number|Season|Airdate|Previous Episode|Next Episode}}

Beispiel für die Episode Experten:

{{EpInfo|Experten|[[Bild:Experten.jpg]]|1c|1/1999|Tea at the Treedome|01.05.1999|23.08.2002|Meeresbodenpflege|Seifenblasen}}
{{EpInfo2|SpongeBob Schwammkopf|Santiago Ziesmer}}
{{EpInfo2|Sandy Cheeks|Cathleen Gawlich}}
{{EpInfo2|Patrick Star|Marco Kröger}}
|}

Für Charaktere Vorlage EpInfo2 je nach Anzahl wie im oben gezeigten Beispiel einfügen und mit |} abschließen.

Sollten für die deutsche Erstausstrahlung zwei Daten angegeben sein (Nick Premium, Nick), hat die entsprechende Spalte
wie im folgenden Beispiel auszusehen:

|24.04.2008 <small>([[Nick Premium]])</small><br>27.05.2008 <small>([[Nick]])</small>|


{{{1}}}
{{{2}}}
Episode No.: {{{3}}}
Season: {{{4}}}
Airdate: {{{5}}}
Previous Episode: [[{{{6}}} (Episode)|{{{6}}}]]
Next Episode: [[{{{7}}} (Episode)|{{{7}}}]]
Characters Voice actors
Personal tools
Namespaces

Variants
Actions
Navigation
Community
Content
Toolbox