From 9611939c579c3f981d39443b9d1f041e8b0f7f62 Mon Sep 17 00:00:00 2001 From: Deon George Date: Thu, 25 Aug 2022 13:44:03 +1000 Subject: [PATCH] Fixes for Button elements --- src/Blockkit/Blocks/Elements/Button.php | 7 ------- src/Interactive/BlockActions.php | 2 ++ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/src/Blockkit/Blocks/Elements/Button.php b/src/Blockkit/Blocks/Elements/Button.php index 8fa9265..aea58df 100644 --- a/src/Blockkit/Blocks/Elements/Button.php +++ b/src/Blockkit/Blocks/Elements/Button.php @@ -42,13 +42,6 @@ final class Button extends Element /* OPTIONAL ITEMS */ - public function callback_id(string $string): self - { - $this->callback_id = $string; - - return $this; - } - public function confirm(Confirm $confirm): self { $this->confirm = $confirm; diff --git a/src/Interactive/BlockActions.php b/src/Interactive/BlockActions.php index 09b1fc7..034bc0c 100644 --- a/src/Interactive/BlockActions.php +++ b/src/Interactive/BlockActions.php @@ -113,6 +113,8 @@ final class BlockActions extends Base case 'value': switch (object_get($this->action,'type')) { + case 'button': + return object_get($this->action,'text.text'); case 'external_select': case 'overflow': case 'static_select':