From cc5cd1e20f7cfeb7e0641c378d79f08d7c48572a Mon Sep 17 00:00:00 2001 From: 777777777 Date: Wed, 28 Feb 2024 14:06:30 +0800 Subject: [PATCH] feat(20231212): add help image size parameter (#46) --- webex_bot/commands/help.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/webex_bot/commands/help.py b/webex_bot/commands/help.py index 742c424..1028ed6 100644 --- a/webex_bot/commands/help.py +++ b/webex_bot/commands/help.py @@ -14,7 +14,7 @@ class HelpCommand(Command): - def __init__(self, bot_name, bot_help_subtitle, bot_help_image): + def __init__(self, bot_name, bot_help_subtitle, bot_help_image, bot_help_image_size = ImageSize.SMALL): self.commands = None super().__init__( command_keyword=HELP_COMMAND_KEYWORD, @@ -25,6 +25,7 @@ def __init__(self, bot_name, bot_help_subtitle, bot_help_image): self.bot_name = bot_name self.bot_help_subtitle = bot_help_subtitle self.bot_help_image = bot_help_image + self.bot_help_image_size = bot_help_image_size def execute(self, message, attachment_actions, activity): pass @@ -42,7 +43,7 @@ def build_card(self, message, attachment_actions, activity): image = Image( url=self.bot_help_image, - size=ImageSize.SMALL) + size=self.bot_help_image_size) header_column = Column(items=[heading, subtitle], width=2) header_image_column = Column(