css_utils.ts: Add statuspanel rule

Related issue: https://github.com/tridactyl/tridactyl/issues/1284#issuecomment-459488419
This commit is contained in:
glacambre 2019-02-03 08:55:40 +01:00
parent bdaa65d216
commit 536dcb3abc
No known key found for this signature in database
GPG key ID: B9625DB1767553AC
2 changed files with 19 additions and 2 deletions

View file

@ -356,6 +356,13 @@ export async function guiset_quiet(rule: string, option: string) {
* - top-left
* - top-right
*
* - statuspanel (hoverlink + the indicator that appears when a website is loading)
* - none
* - left
* - right
* - top-left
* - top-right
*
* If you want to use guiset in your tridactylrc, you might want to use [[guiset_quiet]] instead.
*/
//#background
@ -2275,12 +2282,12 @@ export async function winopen(...args: string[]) {
browser.windows.create(createData)
}
/**
/**
* Close a tab.
*
* @param id - The window id. Defaults to the id of the current window.
*
* Example: `winclose
* Example: `winclose
*/
//#background
export async function winclose(...ids: string[]) {

View file

@ -36,6 +36,16 @@ export function findCssRules(
*
*/
export const potentialRules = {
statuspanel: {
name: `#statuspanel`,
options: {
none: `display: none !important;`,
right: `right: 0; display: inline;`,
left: ``,
"top-left": `top: 2em; z-index: 2; display: inline;`,
"top-right": `top: 2em; z-index: 2; right: 0; display: inline;`,
},
},
hoverlink: {
name: `statuspanel[type="overLink"], #statuspanel[type="overLink"]`,
options: {