Builder: Modal - code simplification
This commit is contained in:
parent
d5fb7e50c8
commit
01180d7718
|
@ -8,12 +8,12 @@ export let id = "";
|
|||
let ukModal;
|
||||
let listenerAdded = false;
|
||||
|
||||
$: if(ukModal && !listenerAdded) {
|
||||
listenerAdded = true;
|
||||
ukModal.addEventListener("hide", onClosed);
|
||||
}
|
||||
|
||||
$: {
|
||||
if(ukModal && !listenerAdded) {
|
||||
listenerAdded = true;
|
||||
ukModal.addEventListener("hide", onClosed);
|
||||
}
|
||||
|
||||
if(ukModal) {
|
||||
if(isOpen) {
|
||||
UIkit.modal(ukModal).show();
|
||||
|
|
Loading…
Reference in New Issue