Last active
October 19, 2023 12:59
-
-
Save marcosvpj/9c495b249b9b895c3a5f0952b1867ace to your computer and use it in GitHub Desktop.
Userscript to hide non-essential elements to focus on day events
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 Remove non-essential elements on https://outlook.office.com/calendar/view/workweek | |
// @namespace Violentmonkey Scripts | |
// @match https://outlook.office.com/calendar/view/* | |
// @grant GM_addStyle | |
// @version 1.1 | |
// @author marcosvpj | |
// @description 10/11/2023, 9:22:35 AM | |
// ==/UserScript== | |
(function() { | |
'use strict'; | |
var displayNone = | |
"/* Remove headers */"+ | |
"/******************************************************/ "+ | |
"#o365header { display:none; } "+ | |
"#mainApp > div:nth-of-type(2) > div:first-of-type { display:none; } "+ | |
""+ | |
""; | |
function main(){ | |
console.log("=============================================================="); | |
console.log("RUNNING cleaning script"); | |
console.log("=============================================================="); | |
GM_addStyle(displayNone); | |
// Scroll to current time | |
document.querySelectorAll('#id__72 .s63tW')[0].scrollIntoView({ | |
behavior: 'auto', | |
block: 'center', | |
inline: 'center' | |
}); | |
} | |
main(); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment