Skip to content

Commit

Permalink
disabled Card action
Browse files Browse the repository at this point in the history
  • Loading branch information
mvorisek committed Nov 26, 2024
1 parent b9eb989 commit 11cdb6d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Card.php
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,10 @@ public function addClickAction(Model\UserAction $action, ?Button $button = null,
}
}

if ($action->enabled === false) {
$button->addClass('disabled');
}

$button->on('click', $cardDeck !== null ? $cardDeck->sharedExecutorsContainer->getExecutor($action) : $action, $defaults);

return $this;
Expand Down

0 comments on commit 11cdb6d

Please sign in to comment.