improve sidebar and usertool for bookcreator plugin
This commit is contained in:
parent
40ecfe32e5
commit
63f543f62d
|
@ -16,15 +16,12 @@
|
|||
box-shadow: 0 1px 1px 3px rgba(0,0,0,0.1);
|
||||
border-radius: var(--standard-border-radius);
|
||||
text-align:left;
|
||||
margin: .5rem;
|
||||
padding: 1em;
|
||||
margin: .5rem;
|
||||
opacity: 0;
|
||||
visibility: hidden;
|
||||
transition: 0.5s;
|
||||
}
|
||||
#dokuwiki__sidebar_header * {
|
||||
display: inline-block;
|
||||
}
|
||||
#dokuwiki__sidebar_close_btn {
|
||||
float: right;
|
||||
}
|
||||
|
@ -35,6 +32,11 @@
|
|||
margin: .5rem;
|
||||
cursor: pointer;
|
||||
}
|
||||
#dokuwiki__sidebar_content {
|
||||
padding: .5em;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--standard-border-radius);
|
||||
}
|
||||
#dokuwiki__sidebar:target {
|
||||
opacity: 1;
|
||||
visibility: visible;
|
||||
|
@ -55,20 +57,18 @@
|
|||
}
|
||||
[dir=rtl] .dokuwiki .toggle strong { float: left; }
|
||||
#dw__toc {
|
||||
border-top: 1px solid var(--border);
|
||||
padding: .25em;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--standard-border-radius);
|
||||
padding: .5em;
|
||||
}
|
||||
#dw__toc > h3 {
|
||||
font-size: 1rem;
|
||||
margin-top: auto;
|
||||
}
|
||||
#dw__toc ul {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
#dw__toc ul li {
|
||||
list-style-type: none;
|
||||
border-left: 1px solid var(--border);
|
||||
padding-left: .25em;
|
||||
}
|
||||
#dw__toc ul ul { padding-left: 1em; }
|
||||
|
@ -105,12 +105,18 @@
|
|||
list-style-image: url(../../images/closed-rtl.png);
|
||||
}
|
||||
|
||||
/* page tools */
|
||||
#dokuwiki__pagetools {
|
||||
margin-top: 1em;
|
||||
}
|
||||
|
||||
/* edit */
|
||||
button.toolbutton {
|
||||
background-color:var(--bg);
|
||||
}
|
||||
|
||||
.dokuwiki textarea.edit {
|
||||
font-family: var(--mono-font);
|
||||
font-family: var(--mono-font);
|
||||
font-size:1rem;
|
||||
}
|
||||
|
||||
|
|
33
main.php
33
main.php
|
@ -44,8 +44,8 @@ $showSidebar = page_findnearest($conf['sidebar']) && ($ACT=='show');
|
|||
// get logo either out of the template images folder or data/media folder
|
||||
$logoSize = array();
|
||||
$logo = tpl_getMediaFile(array(':wiki:logo.svg', ':logo.svg', 'images/logo.svg', ':wiki:logo.png', ':logo.png', 'images/logo.png'), false, $logoSize);
|
||||
$logoSize[3] = $logoSize[3] ?? ''; // empty if no size given
|
||||
|
||||
$logoSize[3] = $logoSize[3] ?? ''; // empty if no size given
|
||||
// display logo and wiki title in a link to the home page
|
||||
tpl_link(
|
||||
wl(),
|
||||
|
@ -65,14 +65,6 @@ $showSidebar = page_findnearest($conf['sidebar']) && ($ACT=='show');
|
|||
<a id="dokuwiki__sidebar_show_btn" class="button" href="#dokuwiki__sidebar" class="button" >☰</a>
|
||||
<div id="dokuwiki__sidebar" aria-labelledby="dokuwiki__sitetools_heading">
|
||||
<div id="dokuwiki__sidebar_header">
|
||||
<!-- SITE TOOLS -->
|
||||
<?php
|
||||
if (file_exists(DOKU_INC . 'inc/Menu/MobileMenu.php')) {
|
||||
echo (new \dokuwiki\Menu\MobileMenu())->getDropdown($lang['tools']);
|
||||
} else {
|
||||
tpl_actiondropdown($lang['tools']);
|
||||
}
|
||||
?>
|
||||
<a href="#dokuwiki__sidebar_close" id="dokuwiki__sidebar_close_btn" class="button" aria-label="Close">×</a>
|
||||
</div>
|
||||
<div id="dokuwiki__sidebar_content">
|
||||
|
@ -81,10 +73,24 @@ $showSidebar = page_findnearest($conf['sidebar']) && ($ACT=='show');
|
|||
<?php tpl_include_page($conf['sidebar'], 1, 1) /* includes the nearest sidebar page */ ?>
|
||||
<?php tpl_includeFile('sidebarfooter.html') ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php tpl_toc()?>
|
||||
</div>
|
||||
</div>
|
||||
<details id="dokuwiki__pagetools" aria-labelledby="dokuwiki__pagetools_heading">
|
||||
<summary id="dokuwiki__pagetools_heading"><?php echo $lang['page_tools'] ?></summary>
|
||||
<ul>
|
||||
<?php if (file_exists(DOKU_INC . 'inc/Menu/SiteMenu.php')) {
|
||||
echo (new \dokuwiki\Menu\SiteMenu())->getListItems('action ', false);
|
||||
} else {
|
||||
_tpl_sitetools();
|
||||
} ?>
|
||||
<?php if (file_exists(DOKU_INC . 'inc/Menu/PageMenu.php')) {
|
||||
echo (new \dokuwiki\Menu\PageMenu())->getListItems('action ', false);
|
||||
} else {
|
||||
_tpl_pagetools();
|
||||
} ?>
|
||||
</ul>
|
||||
</details>
|
||||
<?php tpl_toc()?>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<main id="dokuwiki__content">
|
||||
|
@ -98,7 +104,6 @@ $showSidebar = page_findnearest($conf['sidebar']) && ($ACT=='show');
|
|||
<?php } ?>
|
||||
</nav>
|
||||
|
||||
|
||||
<?php tpl_flush() /* flush the output buffer */ ?>
|
||||
<?php tpl_includeFile('pageheader.html') ?>
|
||||
|
||||
|
@ -108,12 +113,14 @@ $showSidebar = page_findnearest($conf['sidebar']) && ($ACT=='show');
|
|||
<?php tpl_includeFile('pagefooter.html') ?>
|
||||
</main>
|
||||
|
||||
|
||||
<!-- ********** FOOTER ********** -->
|
||||
<footer>
|
||||
<div class="doc"><?php tpl_pageinfo() /* 'Last modified' etc */ ?></div>
|
||||
<?php tpl_license('button') /* content license, parameters: img=*badge|button|0, imgonly=*0|1, return=*0|1 */ ?>
|
||||
<?php tpl_includeFile('footer.html') ?>
|
||||
|
||||
|
||||
</footer>
|
||||
<div class="no"><?php tpl_indexerWebBug() /* provide DokuWiki housekeeping, required in all templates */ ?></div>
|
||||
</body>
|
||||
|
|
Loading…
Reference in New Issue