From dfdc462fe9f6c7ef9a13c2e225b4a37eea3c39c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tu=C4=9F=C3=A7e=20K=C3=BC=C3=A7=C3=BCko=C4=9Flu?= Date: Fri, 18 Aug 2023 10:08:25 +0300 Subject: [PATCH] Fixed #4286 - SelectButton: passthrough option --- components/lib/selectbutton/SelectButton.d.ts | 4 ++++ components/lib/selectbutton/SelectButton.vue | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/components/lib/selectbutton/SelectButton.d.ts b/components/lib/selectbutton/SelectButton.d.ts index 3c5869495..721d1fadb 100755 --- a/components/lib/selectbutton/SelectButton.d.ts +++ b/components/lib/selectbutton/SelectButton.d.ts @@ -93,6 +93,10 @@ export interface SelectButtonContext { * @defaultValue false */ focused: boolean; + /** + * Available option. + */ + option: any; } /** diff --git a/components/lib/selectbutton/SelectButton.vue b/components/lib/selectbutton/SelectButton.vue index b28da9258..a291fb572 100755 --- a/components/lib/selectbutton/SelectButton.vue +++ b/components/lib/selectbutton/SelectButton.vue @@ -66,7 +66,8 @@ export default { return this.ptm(key, { context: { active: this.isSelected(option), - disabled: this.isOptionDisabled(option) + disabled: this.isOptionDisabled(option), + option } }); },