mirror of
https://github.com/garraflavatra/rolens.git
synced 2025-07-14 04:34:04 +00:00
Add modal transitions
This commit is contained in:
@ -6,11 +6,17 @@ function newDialog(dialogComponent, data = {}) {
|
||||
outlet.className = 'dialogoutlet';
|
||||
document.getElementById('dialogoutlets').appendChild(outlet);
|
||||
|
||||
const instance = new dialogComponent({ target: outlet, props: data });
|
||||
const instance = new dialogComponent({
|
||||
target: outlet,
|
||||
intro: true,
|
||||
props: data,
|
||||
});
|
||||
|
||||
instance.$close = function() {
|
||||
instance.$destroy();
|
||||
outlet.remove();
|
||||
setTimeout(() => {
|
||||
instance.$destroy();
|
||||
outlet.remove();
|
||||
}, 200);
|
||||
};
|
||||
|
||||
instance.$on('close', instance.$close);
|
||||
|
Reference in New Issue
Block a user