itizawa 4 лет назад
Родитель
Сommit
dc857a6307
1 измененных файлов с 8 добавлено и 1 удалено
  1. 8 1
      packages/slack/src/utils/block-kit-builder.ts

+ 8 - 1
packages/slack/src/utils/block-kit-builder.ts

@@ -63,13 +63,20 @@ export function inputBlock(
   };
 }
 
+type ButtonElement = {
+  text: string,
+  actionId: string,
+  style?: string,
+  value?:string
+}
+
 /**
  * Button element
  * https://api.slack.com/reference/block-kit/block-elements#button
  */
 export function buttonElement({
   text, actionId, style, value,
-}:{text: string, actionId: string, style?: string, value?:string}): Button {
+}:ButtonElement): Button {
   const button: Button = {
     type: 'button',
     text: {