# Templates for Wikis (especially an Infobox Object)

**URL:** <https://meta.discourse.org/t/templates-for-wikis-especially-an-infobox-object/322617>\
**Category:** Feature\
**Tags:** wiki-posts\
**Created:** [August 21, 2024, 2:58am UTC](https://meta.discourse.org/t/templates-for-wikis-especially-an-infobox-object/322617 "2024-08-21T02:58:05Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![Heliosurge](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/heliosurge/32/571810_2.png) [@Heliosurge](https://meta.discourse.org/u/Heliosurge)\
**Post date:** [August 26, 2024, 12:40am UTC](https://meta.discourse.org/t/templates-for-wikis-especially-an-infobox-object/322617/3 "2024-08-26T00:40:29Z")

</div>

## Revised Code adds background colors

- Note this code has all code from previous post.

> **Code For CSS Common**
>
> ```plaintext
> div[data-wrap="redbox"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> border: 2.5px solid #ff0000;
> border-radius: 0.40em;
> }
> div[data-wrap="greenbox"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> border: 2.5px solid #00ff00;
> border-radius: 0.40em;
> }
> div[data-wrap="bluebox"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> border: 2.5px solid #0000ff;
> border-radius: 0.40em;
> }
> div[data-wrap="yellowbox"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> border: 2.5px solid #ffff00;
> border-radius: 0.40em;
> }
> div[data-wrap="box"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> border: 2.5px solid #808080;
> border-radius: 0.40em;
> }
> div[data-wrap="redboxbg"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> background-color: #ff0000;
> border: 2.75px solid #808080;
> border-radius: 0.40em;
> }
> div[data-wrap="greenboxbg"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> background-color: #00ff00;
> border: 2.75px solid #808080;
> border-radius: 0.40em;
> }
> div[data-wrap="blueboxbg"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> background-color: #0000ff;
> border: 2.75px solid #808080;
> border-radius: 0.40em;
> }
> div[data-wrap="yellowboxbg"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> background-color: #ffff00;
> border: 2.75px solid #808080;
> border-radius: 0.40em;
> }
> div[data-wrap="greyboxbg"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> background-color: #808080;
> border: 2.75px solid #808080;
> border-radius: 0.40em;
> }
> div[data-wrap="grey1boxbg"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> background-color: #808080;
> border: 2.75px solid #ff0000;
> border-radius: 0.40em;
> }
> div[data-wrap="grey2boxbg"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> background-color: #808080;
> border: 2.75px solid #00ff00;
> border-radius: 0.40em;
> }
> div[data-wrap="grey3boxbg"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> background-color: #808080;
> border: 2.75px solid #0000ff;
> border-radius: 0.40em;
> }
> div[data-wrap="grey4boxbg"]{
> margin-top: 0.15em;
> margin-bottom: 0.15em;
> padding-left: 0.30em;
> padding-right: 0.30em;
> background-color: #808080;
> border: 2.75px solid #ffff00;
> border-radius: 0.40em;
> }
> 
> ```
> 
> * * *

Use this code in posts for bgcolor boxes:

```plaintext
[Wrap="redboxbg"]
> Infobox

Testing boxed
[/wrap]

```

New background color Options Substitute “ **red** ” with:

- “green”, “blue”, “yellow”  
_Color background. Grey border._

> **Screenshot Mobile**
>
> ![There is a colorful display with text boxes that likely represent different categories or purposes. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/6/8/6/6866e812c631a7c6a422215255aa28cbcf12f387.png)
> 
> * * *

- “grey”, “grey#” #=1-4.  
\*All grey backgrounds, grey border, 1 red border, 2 green border, 3 blue border, 4 yellow border

> **Screenshot Mobile**
>
> ![This is a screenshot of a user interface showing a testing box labeled "Picture" with a mechanical robot head as the image underneath. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/b/7/f/b7f0d035d83e6af5612e3edc7780aa3aa5b7cacc.png)
> 
> ![This image displays a dropdown menu with four different boxes, each representing a different type of test. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/0/5/b/05bdb4139fbb59ed3167b8b22b6e83bf9cba6450.png)
> 
> ![A stylized image of a robot with a human-like face and an intricate design, set against a backdrop of a futuristic cityscape. (Captioned by AI)](https://global.discourse-cdn.com/meta/original/4X/3/3/8/338db6fb1c9ea295818f572d358b720bd5763c9f.png)

---

_[View the full topic](https://meta.discourse.org/t/templates-for-wikis-especially-an-infobox-object/322617)._
