Update Compass QoL Enhancer to 1.8.0

- Fix a weird overline on hover for calendar events
- Make strikethroughs in calendar events and their tooltips more noticeable
This commit is contained in:
blankie 2023-08-10 17:57:04 +10:00
parent 868c06677d
commit 16eadc5aa3
Signed by: blankie
GPG Key ID: CC15FC822C7F61F5
2 changed files with 13 additions and 1 deletions

View File

@ -2,7 +2,7 @@
// @name Compass QoL Enhancer // @name Compass QoL Enhancer
// @namespace blankie-scripts // @namespace blankie-scripts
// @match http*://*.compass.education/* // @match http*://*.compass.education/*
// @version 1.7.0 // @version 1.8.0
// @author blankie // @author blankie
// @description A userscript that adds small but useful features for Compass, such as the ability to close windows by clicking on the background // @description A userscript that adds small but useful features for Compass, such as the ability to close windows by clicking on the background
// @inject-into page // @inject-into page
@ -57,6 +57,8 @@ function handleNewCalendarEvent(element) {
} }
// fix learning tasks shrinking for some reason // fix learning tasks shrinking for some reason
a.style.display = "block"; a.style.display = "block";
// fix weird aboveline (underline but above the text) on hover
a.style.textDecoration = "none";
a.replaceChildren(...element.childNodes); a.replaceChildren(...element.childNodes);
let preventCompassHandler = false; let preventCompassHandler = false;
@ -233,6 +235,15 @@ document.body.addEventListener("click", function(event) {
} }
}, {passive: true}); }, {passive: true});
let style = document.createElement("style");
style.textContent = `
/* Make strikethroughs more noticeable on calendar events and their tooltips */
.ext-cal-evt s, .calendar-tip .title s {
text-decoration-thickness: .25em;
}
`;
document.head.append(style);
// Suppress that annoying barebones context menu that only has Copy // Suppress that annoying barebones context menu that only has Copy
// why is it not obvious that you can just hold ctrl or shift to suppress it??? // why is it not obvious that you can just hold ctrl or shift to suppress it???
// i know it's compass' fault but i'm still frustrated // i know it's compass' fault but i'm still frustrated

View File

@ -23,6 +23,7 @@ A userscript that adds small but useful features for Compass. Features include:
- Calendar events now being links (they work with [Link Hints] now! you can - Calendar events now being links (they work with [Link Hints] now! you can
also ctrl+click on "standard classes", events, and learning tasks) also ctrl+click on "standard classes", events, and learning tasks)
- Calendar events now show their end time without having to being hovered - Calendar events now show their end time without having to being hovered
- Strikethroughs in calendar events are now a lot more noticeable
- Tabs are now links (you can refresh pages and the tab will automatically - Tabs are now links (you can refresh pages and the tab will automatically
open. you can also ctrl+click on them) open. you can also ctrl+click on them)
- Files and folders in Resources is now marked clickable ([Link Hints] can now - Files and folders in Resources is now marked clickable ([Link Hints] can now