Skip to content

Commit

Permalink
use dashed commands
Browse files Browse the repository at this point in the history
  • Loading branch information
keithamus committed Jul 27, 2024
1 parent a2beb10 commit 0cbe2f6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions invoker.js
Original file line number Diff line number Diff line change
Expand Up @@ -297,8 +297,8 @@
if (invokee.popover) {
const canShow = !invokee.matches(":popover-open");
const shouldShow =
canShow && (command === "togglepopover" || command === "showpopover");
const shouldHide = !canShow && command === "hidepopover";
canShow && (command === "toggle-popover" || command === "show-popover");
const shouldHide = !canShow && command === "hide-popover";

if (shouldShow) {
invokee.showPopover();
Expand All @@ -307,7 +307,7 @@
}
} else if (invokee.localName === "dialog") {
const canShow = !invokee.hasAttribute("open");
const shouldShow = canShow && command === "showmodal";
const shouldShow = canShow && command === "show-modal";
const shouldHide = !canShow && command === "close";

if (shouldShow) {
Expand Down

0 comments on commit 0cbe2f6

Please sign in to comment.