Skip to content

Commit

Permalink
Bug fixes
Browse files Browse the repository at this point in the history
Thanks @ChrisPiel70!
  • Loading branch information
KTibow authored Nov 10, 2020
1 parent 7c4147a commit 2063b63
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions fullscreen-card.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,11 @@ class FullscreenCard extends HTMLElement {
if (this.fullscreen) {
document.exitFullscreen();
this.atag.innerHTML =
config["go_fullscreen"] ||
(config["go_fullscreen"] = "Go fullscreen");
this.config["go_fullscreen"] || "Go fullscreen";
} else {
document.documentElement.requestFullscreen();
this.atag.innerHTML =
config["exit_fullscreen"] ||
(config["exit_fullscreen"] = "Exit fullscreen");
this.config["exit_fullscreen"] || "Exit fullscreen";
}
this.fullscreen = !this.fullscreen;
}.bind(this);
Expand All @@ -44,6 +42,7 @@ class FullscreenCard extends HTMLElement {
}

customElements.define("fullscreen-card", FullscreenCard);
window.customCards = window.customCards || [];
window.customCards.push({
type: "fullscreen-card",
name: "Fullscreen card",
Expand Down

0 comments on commit 2063b63

Please sign in to comment.