forked from DebaucheryLibrarian/traxxx
Improved tooltip behavior and styling.
This commit is contained in:
@@ -38,6 +38,24 @@ async function setConsent(consent) {
|
||||
}
|
||||
}
|
||||
|
||||
function blur(event) {
|
||||
this.events.emit('blur', event);
|
||||
}
|
||||
|
||||
function resize(event) {
|
||||
this.events.emit('resize', event);
|
||||
}
|
||||
|
||||
function mounted() {
|
||||
document.addEventListener('click', this.blur);
|
||||
window.addEventListener('resize', this.resize);
|
||||
}
|
||||
|
||||
function beforeUnmount() {
|
||||
document.removeEventListener('click', this.blur);
|
||||
window.removeEventListener('resize', this.resize);
|
||||
}
|
||||
|
||||
export default {
|
||||
components: {
|
||||
Header,
|
||||
@@ -50,9 +68,13 @@ export default {
|
||||
showWarning: localStorage.getItem('consent') !== window.env.sessionId,
|
||||
};
|
||||
},
|
||||
mounted,
|
||||
beforeUnmount,
|
||||
methods: {
|
||||
toggleSidebar,
|
||||
setConsent,
|
||||
blur,
|
||||
resize,
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user