Is there a simple way to adjust dialog widths on a per dialog basis? Right now, we're adjusting a custom dialog using the following method...
`changeWidth() {
setTimeout(() => {
let dialogEls = document.getElementsByClassName('mdl-dialog');
let elements = Array.prototype.filter.call(dialogEls, (dialogEl) => {
if (dialogEl.nodeName === 'MDL-DIALOG-HOST-COMPONENT') {
let hostComp = dialogEl.lastChild;
if ((hostComp || {}).nodeName === 'CUSTOM-DIALOG-CMP') {
return true;
}
}
})
elements.forEach(el => {
el.style.width = '500px';
});
});
}`
We're looking for a cleaner option. Any help would be greatly appreciated.
Is there a simple way to adjust dialog widths on a per dialog basis? Right now, we're adjusting a custom dialog using the following method...
`changeWidth() {
}`
We're looking for a cleaner option. Any help would be greatly appreciated.