mirror of
https://github.com/pldubouilh/gossa.git
synced 2026-08-28 04:46:58 -04:00
add help hint on main page
Co-authored-by: Pietro Bonaldo Gregori <pietro.bogre@gmail.com>
This commit is contained in:
committed by
Pierre Dubouilh
co-authored by
Pietro Bonaldo Gregori
parent
33c93fc0b4
commit
99a6aec8db
Vendored
+10
@@ -11,6 +11,7 @@ const rmMsg = () => !confirm('Remove file?\n')
|
||||
const ensureMove = () => !confirm('move items?')
|
||||
const isRo = () => window.ro
|
||||
|
||||
// DOM elements
|
||||
const upBarName = document.getElementById('upBarName')
|
||||
const upBarPc = document.getElementById('upBarPc')
|
||||
const upGrid = document.getElementById('drop-grid')
|
||||
@@ -29,6 +30,8 @@ const editor = document.getElementById('text-editor')
|
||||
const crossIcon = document.getElementById('quitAll')
|
||||
const toast = document.getElementById('toast')
|
||||
const table = document.getElementById('linkTable')
|
||||
const helpMsg = document.getElementById('help_message')
|
||||
|
||||
const transparentPixel = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mNkYAAAAAYAAjCB0C8AAAAASUVORK5CYII='
|
||||
|
||||
// helpers
|
||||
@@ -847,5 +850,12 @@ function init () {
|
||||
const matchingA = allA.find(a => a.href === cleanURL)
|
||||
padOn(matchingA)
|
||||
}
|
||||
|
||||
// check if we're at root path
|
||||
if (location.pathname === window.extraPath + '/') {
|
||||
helpMsg.style.display = 'block'
|
||||
} else {
|
||||
helpMsg.style.display = 'none'
|
||||
}
|
||||
}
|
||||
init()
|
||||
|
||||
Reference in New Issue
Block a user