Last active
March 16, 2020 23:48
-
-
Save zigiprimo/7bd91b1f46d8c95b694c52d03a63b90e to your computer and use it in GitHub Desktop.
hide qimagery header - grease/tamper monkey script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name qimagery-hide-banner | |
// @namespace http://www.zigiprimo.dev/ | |
// @version 0.1 | |
// @description Hiding the big banner for a more working space | |
// @author Sameer Cooshna | |
// @match https://qimagery.information.qld.gov.au/* | |
// @grant none | |
// ==/UserScript== | |
(function() { | |
'use strict'; | |
const topZero = {top: "0px"}; | |
const zIndexHigh = {zIndex: "100"}; | |
let elements = { | |
mapContainer: [document.getElementById("mapContainer"), topZero, zIndexHigh], | |
mainSidebar: [document.getElementById("main-sidebar"), topZero, zIndexHigh] | |
}; | |
Object.values(elements).forEach(value => { | |
let element = value.shift(); | |
let styles = value.reduce((styles, style) => { | |
return {...styles, ...style}; | |
}); | |
Object.assign(element.style, styles); | |
}); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment