Make the clickable area to dismiss notifications bigger
This commit is contained in:
parent
e77207dfee
commit
32a3ed6842
@ -32,8 +32,9 @@
|
|||||||
display: none;
|
display: none;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
span {
|
cursor: pointer;
|
||||||
cursor: pointer;
|
&:hover {
|
||||||
|
background-color: rgba(0,0,0,0.1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -5,7 +5,8 @@ define([
|
|||||||
'/common/common-ui-elements.js',
|
'/common/common-ui-elements.js',
|
||||||
'/common/notifications.js',
|
'/common/notifications.js',
|
||||||
'/common/hyperscript.js',
|
'/common/hyperscript.js',
|
||||||
], function ($, Util, UI, UIElements, Notifications, h) {
|
'/customize/messages.js',
|
||||||
|
], function ($, Util, UI, UIElements, Notifications, h, Messages) {
|
||||||
var Mailbox = {};
|
var Mailbox = {};
|
||||||
|
|
||||||
Mailbox.create = function (Common) {
|
Mailbox.create = function (Common) {
|
||||||
@ -48,7 +49,10 @@ define([
|
|||||||
};
|
};
|
||||||
var createElement = function (data) {
|
var createElement = function (data) {
|
||||||
var notif;
|
var notif;
|
||||||
var dismiss = h('span.fa.fa-times');
|
var dismissIcon = h('span.fa.fa-times');
|
||||||
|
var dismiss = h('div.cp-notification-dismiss', {
|
||||||
|
title: Messages.notifications_dismiss
|
||||||
|
}, dismissIcon)
|
||||||
dismiss.addEventListener('click', function (e) {
|
dismiss.addEventListener('click', function (e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
@ -65,7 +69,7 @@ define([
|
|||||||
'data-hash': data.content.hash
|
'data-hash': data.content.hash
|
||||||
}, [
|
}, [
|
||||||
h('div.cp-notification-content', h('p', formatData(data))),
|
h('div.cp-notification-content', h('p', formatData(data))),
|
||||||
h('div.cp-notification-dismiss', dismiss)
|
dismiss
|
||||||
]);
|
]);
|
||||||
return notif;
|
return notif;
|
||||||
};
|
};
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user