Add triggerClass support to the popover menu
This commit is contained in:
parent
ada745a59f
commit
d13af1bcb5
|
@ -15,6 +15,8 @@ const FOCUSABLE = [
|
|||
export default Component.extend({
|
||||
classnames: ['popover'],
|
||||
|
||||
triggerClass: '',
|
||||
|
||||
isOpen: false,
|
||||
dropdown: null,
|
||||
|
||||
|
|
|
@ -3,10 +3,10 @@
|
|||
@onOpen={{action (queue (action (mut isOpen) true) (action capture))}}
|
||||
@onClose={{action (mut isOpen) false}} as |dd|
|
||||
>
|
||||
<dd.Trigger data-test-popover-trigger class="popover-trigger button is-primary" {{on "keydown" (action "openOnArrowDown" dd)}}>
|
||||
<dd.Trigger data-test-popover-trigger class={{concat "popover-trigger button is-primary " triggerClass}} {{on "keydown" (action "openOnArrowDown" dd)}}>
|
||||
{{label}} {{x-icon "chevron-down" class="is-text"}}
|
||||
</dd.Trigger>
|
||||
<dd.Content class="popover-content">
|
||||
{{yield}}
|
||||
{{yield dd}}
|
||||
</dd.Content>
|
||||
</BasicDropdown>
|
||||
|
|
Loading…
Reference in a new issue