Added missing tests and sidebar files
This commit is contained in:
parent
ab10cea8b6
commit
5930f3bfad
6 changed files with 125 additions and 2 deletions
0
static-data/www/shared/sidebar/sidebar.css
Normal file
0
static-data/www/shared/sidebar/sidebar.css
Normal file
17
static-data/www/shared/sidebar/sidebar.html
Normal file
17
static-data/www/shared/sidebar/sidebar.html
Normal file
|
@ -0,0 +1,17 @@
|
|||
<div id="quickviewDefault" class="quickview">
|
||||
<header class="quickview-header">
|
||||
<p class="title">Quickview title</p>
|
||||
<span class="delete" data-dismiss="quickview"></span>
|
||||
</header>
|
||||
|
||||
<div class="quickview-body">
|
||||
<div class="quickview-block">
|
||||
...
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<footer class="quickview-footer">
|
||||
|
||||
</footer>
|
||||
</div>
|
||||
<button class="button is-primary is-hidden sidebarBtn" data-show="quickview" data-target="quickviewDefault">Show quickview</button>
|
18
static-data/www/shared/sidebar/sidebar.js
Normal file
18
static-data/www/shared/sidebar/sidebar.js
Normal file
|
@ -0,0 +1,18 @@
|
|||
fetch('/shared/sidebar/sidebar.html', {
|
||||
"method": "get",
|
||||
headers: {
|
||||
"token": webpass
|
||||
}})
|
||||
.then((resp) => resp.text())
|
||||
.then(function(resp) {
|
||||
document.getElementById('sidebarContainer').innerHTML = resp
|
||||
})
|
||||
|
||||
|
||||
|
||||
window.addEventListener("keydown", function(event) {
|
||||
if (event.key === "s"){
|
||||
let quickviews = bulmaQuickview.attach()
|
||||
document.getElementsByClassName('sidebarBtn')[0].click()
|
||||
}
|
||||
}, true)
|
Loading…
Add table
Add a link
Reference in a new issue