I am using Paper-dialog and paper-dialog-scrollable webcomponents in Polymer projects. I have some set of input fields (Forms) on paper-dialog (pop-up). By default when opening popup(Dialog) I am focusing input field.
But issue is when i click, scroll anywhere inside the dialog, Input lose it focus. How should i keep focus inside paper-dialog even if i click/scroll
i tried below code but no luck. form code wrote inside another element called my-form-element
<paper-dialog-scrollable id="myDialog">
<my-form-element></my-form-element>
</paper-dialog-scrollable>
Polymer.RenderStatus.afterNextRender( this, function() {
const dialogContent = this.$.myDialog.$.scrollable;
dialogContent.addEventListener('click', (e) => {
e.preventDefault();
});
});