Closed Rohit-Metapercept closed 5 years ago
You should use dialog.close()
method.
I tried this but it's not getting close
`
<x-button toggled id="agree-button" ng-click="fronmatter_default();">
<x-label>Confirm</x-label>
</x-button>
</footer>`
Does this work for you?
let button = document.querySelector("x-button#disagree-button");
let dialog = document.querySelector("dialog");
button.addEventListener("click", (event) => {
dialog.close();
});
Yes this worked for me. Thanks, got the idea.
Hi , I am using dialog box and I am not getting any way to close the dialog box on button click . Is there any way to close it without on pointer event?