I wanted to see how much I could simplify the new Adora Belle default template "dokuwiki" [
https://www.dokuwiki.org/template:dokuwiki] by minimal hacks. Mostly I wanted to reduce the whitespace of the header and to simplify the overall look and feel.
Screenshots:
*
http://imageshack.com/a/img27/5292/6lvj.jpg
*
http://imageshack.com/a/img132/7374/yv3r.jpg
I started off by hiding the pageId and removing some whitespace:
div.dokuwiki div.pageId { display: none; }
#dokuwiki__header { padding-bottom: 0.1em; }
#dokuwiki__header .headings, #dokuwiki__header .tools { margin-bottom: 0.6em; }
But then I decided to move the user and site tools completely to the super nice page tools hover panel. For this I had to delete the respective lines in
tpl_header.php[/m] (the whole [m]<div id="dokuwiki__usertools">...</div>[/m] and the [m]tpl_action(...) lines for recent, media, and index.
The remove
tpl_action(...)[/m] lines, I added to [m]main.php:
'recent' => tpl_action('recent', 1, 'li', 1, '<span>', '</span>'),
'media' => tpl_action('media', 1, 'li', 1, '<span>', '</span>'),
'index' => tpl_action('index', 1, 'li', 1, '<span>', '</span>'),
'profile' => tpl_action('profile', 1, 'li', 1, '<span>', '</span>',
'<bdi>'.hsc($INFO['userinfo']['name']).'</bdi> (<bdi>'.hsc($_SERVER['REMOTE_USER']).'</bdi>)'),
'admin' => tpl_action('admin', 1, 'li', 1, '<span>', '</span>'),
'login' => tpl_action('login', 1, 'li', 1, '<span>', '</span>'),
Fortunately, this works without the need to add CSS and icons. A default icon is shown. However, I also tried modifying
pagetools-sprite.png[/m]. Since I am allergic to blue I had to change it anyway. There's [m]images/pagetools-build.php which is meant to create the sprite (thanks for including this). Unfortunately, on my servers it bails out with
PHP Fatal error: Call to undefined function imagelayereffect()
So, I hacked
pagetools-sprite.png manually:
http://imageshack.com/a/img854/2715/nky7.png ... not a great job, but might be of use for people who prefer
orange :-D
The rest is CSS included in
userstyle.css:
/* preserve some whitespace on top of the page */
div.dokuwiki div.pageId { display: none; }
#dokuwiki__header { padding-bottom: 0.1em; }
#dokuwiki__header .headings, #dokuwiki__header .tools { margin-bottom: 0.6em; }
#dokuwiki__header { padding-top: 1.1em; }
#dokuwiki__header h1 { padding-bottom: .5em; }
/* icons for the tool bar (pagetools) */
#dokuwiki__pagetools ul li a.media { background-position: right -990px; }
#dokuwiki__pagetools ul li a.media:before { margin-top: -990px; }
#dokuwiki__pagetools ul li a.media:hover,
#dokuwiki__pagetools ul li a.media:active,
#dokuwiki__pagetools ul li a.media:focus { background-position: right -1035px; }
/* ... */