I am using ember-bootstrap and their modal component to create a modal on a template. Currently the modal component and the button to trigger it are on the same template, however I want to move the modal to a component so I can keep the template code clean.
This works
//application/template.hbs
{{#bs-button onClick=(action (mut modal1) true)}}Open Modal{{/bs-button}}
{{#bs-modal-simple open=modal1 title="Simple Dialog" size="sm" onHidden=(action (mut modal1) false)}}
Hi there
{{/bs-modal-simple}}
This doesn't work
//application/template.hbs
{{#bs-button onClick=(action (mut modal1) true)}}Open Modal{{/bs-button}}
{{my-modal}}
//components/my-modal/template.hbs
{{#bs-modal-simple open=modal1 title="Simple Dialog" size="sm" onHidden=(action (mut modal1) false)}}
Hi there
{{/bs-modal-simple}}
How could I get it so the modal is triggered from the applications template?