From 45ee0a9627edfc2cef0de66dbdee9df1c91e2361 Mon Sep 17 00:00:00 2001 From: mhartington Date: Thu, 30 Nov 2017 12:05:13 -0500 Subject: [PATCH] feat(actionSheet): union types for actionsheet button --- packages/core/src/components/action-sheet/action-sheet.tsx | 2 +- packages/core/src/components/action-sheet/test/basic/index.html | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/core/src/components/action-sheet/action-sheet.tsx b/packages/core/src/components/action-sheet/action-sheet.tsx index 0f3eaccc68..481632ebf9 100644 --- a/packages/core/src/components/action-sheet/action-sheet.tsx +++ b/packages/core/src/components/action-sheet/action-sheet.tsx @@ -265,7 +265,7 @@ export interface ActionSheetOptions { export interface ActionSheetButton { text?: string; - role?: string; + role?: 'cancel' | 'destructive' | 'selected'; icon?: string; cssClass?: string; handler?: () => boolean | void; diff --git a/packages/core/src/components/action-sheet/test/basic/index.html b/packages/core/src/components/action-sheet/test/basic/index.html index 3052c99b58..826d1e33f1 100644 --- a/packages/core/src/components/action-sheet/test/basic/index.html +++ b/packages/core/src/components/action-sheet/test/basic/index.html @@ -300,6 +300,7 @@ buttons: [ { text: 'Test', + role: 'test', cssClass: 'my-cancel-button, my-custom-button customClass', handler: () => { console.log('Cancel clicked');