Added toggle to enable and disable the count of blocked stickies

This commit is contained in:
Rohit Patnaik 2020-04-27 08:00:29 -05:00
parent d13c90c691
commit a6b997b780
2 changed files with 18 additions and 1 deletions

View File

@ -16,6 +16,11 @@
<input type='checkbox' id='whitelist-mode'></input>
<span class='whitelist-mode-label'>Whitelist mode</span>
</span>
<span class='display-stickies-killed-container'>
<span class='enable-stickes-killed-count'>Show killed stickies count</span>
<input type='checkbox' id='display-kill-count'>
<span class='disable-stickies-killed-count'>Hide killed stickies count</span>
</span>
<span class='buttons'>
<button disabled type='button' class='reset-button'>Reset</button>
<button disabled type='button' class='save-button'>Save</button>
@ -91,4 +96,4 @@
</body>
<script src="functions.js"></script>
<script src="options.js"></script>
</html>
</html>

View File

@ -12,6 +12,13 @@ function modeSelectorInputReceived() {
setButtonsActive(true);
}
/*
* Triggered when a click is received by the kill count display switch
*/
function showKillCountInputReceived() {
setButtonsActive(true);
}
/***********/
/* HELPERS */
/***********/
@ -176,6 +183,11 @@ function initialize() {
});
});
//Listener for killcount display switch
document.querySelector("input#display-kill-count").addEventListener("change", (event) => {
showKillCountInputReceived();
});
// Listener for open help button.
document.querySelector(".open-help-button").addActivateEvent((event) => {
setHelpOverlayVisible(true);