mirror of
https://github.com/the-djmaze/snappymail.git
synced 2024-12-30 19:41:46 +08:00
fix: allow clicking action on entire "ListItem" area, instead of just the "text elements"
This commit is contained in:
parent
49010a70a0
commit
15e59ef65f
2 changed files with 11 additions and 3 deletions
|
@ -200,8 +200,16 @@ export class Selector {
|
|||
|
||||
addEventsListeners(contentScrollable, {
|
||||
click: event => {
|
||||
let el = event.target.closestWithin(this.sItemSelector, contentScrollable);
|
||||
el && this.actionClick(ko.dataFor(el), event);
|
||||
|
||||
const lowerClassName = event.target.className.toLowerCase();
|
||||
if (this.sItemSelector !== '.messageListItem'
|
||||
|| (lowerClassName.indexOf('flagparent') === -1
|
||||
&& lowerClassName.indexOf('checkbox') === -1)) {
|
||||
|
||||
let el = event.target.closestWithin(this.sItemSelector, contentScrollable);
|
||||
el && this.actionClick(ko.dataFor(el), event);
|
||||
|
||||
}
|
||||
|
||||
const item = getItem(this.sItemCheckedSelector);
|
||||
if (item) {
|
||||
|
|
|
@ -219,7 +219,7 @@ export class MailMessageList extends AbstractViewRight {
|
|||
MessagelistUserStore,
|
||||
MessagelistUserStore.selectedMessage,
|
||||
MessagelistUserStore.focusedMessage,
|
||||
'.messageListItem .actionHandle',
|
||||
'.messageListItem',
|
||||
'.messageListItem .messageCheckbox',
|
||||
'.messageListItem.focused'
|
||||
);
|
||||
|
|
Loading…
Reference in a new issue