template:vector
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
template:vector [2021-01-08 19:58] – [Custom tab examples] coldscientist | template:vector [2024-02-19 13:00] (current) – menix | ||
---|---|---|---|
Line 2: | Line 2: | ||
---- template ---- | ---- template ---- | ||
- | description | + | description |
author | author | ||
email : dokuwiki@dev.arsava.com | email : dokuwiki@dev.arsava.com | ||
lastupdate | lastupdate | ||
- | compatible | + | compatible |
depends | depends | ||
conflicts | conflicts | ||
similar | similar | ||
- | screenshot_img: | ||
tags : monobook, mediawiki, wikipedia, dokubook, vector, sidebar, talk, translation | tags : monobook, mediawiki, wikipedia, dokubook, vector, sidebar, talk, translation | ||
Line 17: | Line 16: | ||
sourcerepo | sourcerepo | ||
donationurl | donationurl | ||
+ | |||
+ | screenshot_img: | ||
---- | ---- | ||
- | :!: Problems with this template in **Ponder Stibbons**? Due to a [[https:// | + | :!: Problems with this template in **Ponder Stibbons**? Due to a [[issue>683|bug]] in DokuWiki, you need to **[[config: |
===== About ===== | ===== About ===== | ||
- | " | + | " |
* Maintainer: [[https:// | * Maintainer: [[https:// | ||
* Contact: See " | * Contact: See " | ||
Line 32: | Line 33: | ||
* **Cite this Article**\\ Allows students, journalists, | * **Cite this Article**\\ Allows students, journalists, | ||
* **Permanent Link**\\ __Guarantees__ that articles you link to are the same as you saw them that second you link them. | * **Permanent Link**\\ __Guarantees__ that articles you link to are the same as you saw them that second you link them. | ||
- | * **Automatic plugin integration**\\ vector automatically detects and uses some popular, optionally installed plugins. Therefore you don't have to insert any code snippets or stuff when using: [[plugin: | + | * **Automatic plugin integration**\\ vector automatically detects and uses some popular, optionally installed plugins. Therefore you don't have to insert any code snippets or stuff when using: [[plugin: |
* All non-page portions (e.g. navigation) of the template can be edited just as if they were pages. How cool is that? 8-) | * All non-page portions (e.g. navigation) of the template can be edited just as if they were pages. How cool is that? 8-) | ||
Line 295: | Line 296: | ||
=== Add custom plugin tab === | === Add custom plugin tab === | ||
- | The vector template doesn' | + | The vector template doesn' |
<code php> | <code php> | ||
//custom plugin tab | //custom plugin tab | ||
- | $items = (new \dokuwiki\Menu\PageMenu())-> | + | $skip_types |
- | foreach($items | + | foreach((new \dokuwiki\Menu\PageMenu())-> |
- | | + | |
- | parse_str($query, $params); | + | |
- | + | ||
- | if(!preg_match("/ | + | |
- | | + | |
- | $_vector_tabs_right[" | + | |
- | $_vector_tabs_right[" | + | |
} | } | ||
+ | | ||
+ | $attr = $item-> | ||
+ | $_vector_tabs_right[" | ||
+ | $_vector_tabs_right[" | ||
+ | $_vector_tabs_right[" | ||
+ | if ($item-> | ||
+ | $_vector_tabs_right[" | ||
+ | } | ||
+ | | ||
} | } | ||
</ | </ | ||
Line 360: | Line 365: | ||
Grtz, Theo | Grtz, Theo | ||
+ | === Add custom plugin toolbox === | ||
+ | The vector template doesn' | ||
==== Hacks for / | ==== Hacks for / | ||
Line 549: | Line 556: | ||
</ | </ | ||
- | ==== Hacks for / | + | === Automatically numbering Headings and Table of Contents (TOC) via CSS === |
- | ...to insert into ''/ | + | <code css> |
+ | /* Automatically numbering Headings via CSS | ||
+ | https://philarcher.org/diary/2013/ | ||
+ | body {counter-reset: | ||
+ | h2 {counter-reset: | ||
+ | h3 {counter-reset: | ||
+ | h4 {counter-reset: | ||
+ | h5 {counter-reset: | ||
- | :!: **ATTENTION**: You have to activate the template option | + | h2:before {counter-increment: h2; content: counter(h2) |
+ | h3:before {counter-increment: | ||
+ | h4:before {counter-increment: h4; content: counter(h2) | ||
+ | h5:before {counter-increment: | ||
+ | h6:before {counter-increment: | ||
+ | |||
+ | h2.nocount: | ||
+ | |||
+ | /* Automatically numbering Table of Contents (TOC) via CSS | ||
+ | https://www.freecodecamp.org/ | ||
+ | #dw__toc ul ul { | ||
+ | list-style-type: | ||
+ | counter-reset: | ||
+ | } | ||
+ | |||
+ | #dw__toc ul ul li div.li: | ||
+ | counter-increment: | ||
+ | content: counters(css-counters, | ||
+ | } | ||
+ | </ | ||
=== Images exceed page body width === | === Images exceed page body width === | ||
- | By default, images are not scaled to the width of the page body and exceed the visible region of the page, so I added this to ''/ | + | By default, images are not scaled to the width of the page body and exceed the visible region of the page, so I added this to ''/ |
- | < | + | < |
- | let vectorstyle = document.createElement(' | + | div# |
- | vectorstyle.id = " | + | div# |
- | document.head.appendChild(vectorstyle); | + | |
- | vectorstyle.innerHTML = " | + | |
</ | </ | ||
Line 592: | Line 623: | ||
===== Sites using this Template ===== | ===== Sites using this Template ===== | ||
- | |||
Feel free to add yours here: | Feel free to add yours here: | ||
=== English === | === English === | ||
+ | * [[https:// | ||
* [[http:// | * [[http:// | ||
* [[http:// | * [[http:// | ||
* [[http:// | * [[http:// | ||
* [[http:// | * [[http:// | ||
+ | * [[http:// | ||
+ | * [[https:// | ||
=== German === | === German === | ||
Line 612: | Line 645: | ||
=== French === | === French === | ||
* [[http:// | * [[http:// | ||
+ | * [[http:// | ||
=== Russian === | === Russian === | ||
Line 625: | Line 659: | ||
* [[http:// | * [[http:// | ||
- | === Multiple | + | === Multiple |
* [[http:// | * [[http:// | ||
template/vector.1610132304.txt.gz · Last modified: 2021-01-08 19:58 by coldscientist