ef4 / ember-elsewhere

Render elsewhere in the DOM, with nice composition, animation, etc. Based on 100% public API.
MIT License
184 stars 25 forks source link

{{to-elsewhere}} should be automatically focused #16

Closed hoIIer closed 7 years ago

hoIIer commented 7 years ago

hello, I'm using this library and noticed a small gotcha where rendering a form that has only a button inside a {{to-elsewhere}} will fail to capture any dom events. I figured out that what's happening is when the {{to-elsewhere}} is rendered, it is not in focus by default and thus my button will only trigger dom events such as keyDown if I first do a user action such as click anywhere in the component.

I could of course get around this in my local project now that I understand the issue but I feel like maybe the default behavior should be to focus the {{to-elsewhere}} component... thoughts?