From bbd7e2ac7a5672e1c6e766b366b6b54d4ff12e82 Mon Sep 17 00:00:00 2001 From: Saurav Suman Date: Thu, 28 Apr 2022 09:35:46 +0530 Subject: [PATCH] fix: fixing overflow accessory to take urls (#5) --- lib/Accessory/index.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/Accessory/index.js b/lib/Accessory/index.js index aaa4193..d36c1ab 100644 --- a/lib/Accessory/index.js +++ b/lib/Accessory/index.js @@ -76,7 +76,7 @@ class Accessory { /** * Overflow accessory - * @param {Array<{text:String, value:String}>} options list of items to show in the overflow menu + * @param {Array<{text:String, value:String, url:String}>} options list of items to show in the overflow menu * @param {String} [actionId] optional action id * @param {Object} [dialog] optional confirm object * @param {String} dialog.title title of the confirm dialog @@ -92,6 +92,7 @@ class Accessory { options: options.map((o) => ({ text: { type: "plain_text", text: o.text }, value: o.value, + ...(o.url && { url: o.url }) })), }, };