1
0
mirror of https://github.com/flarum/core.git synced 2025-07-28 20:20:34 +02:00

Don't show quote button until after selection has been made

This commit is contained in:
Toby Zerner
2016-10-18 22:26:04 +10:30
parent 18a4b6d4b1
commit de7d450093
2 changed files with 8 additions and 4 deletions

View File

@@ -311,8 +311,6 @@ System.register('flarum/mentions/addComposerAutocomplete', ['flarum/extend', 'fl
return {
setters: [function (_flarumExtend) {
/*global getCaretCoordinates*/
extend = _flarumExtend.extend;
}, function (_flarumComponentsComposerBody) {
ComposerBody = _flarumComponentsComposerBody.default;
@@ -681,7 +679,10 @@ System.register('flarum/mentions/addPostQuoteButton', ['flarum/extend', 'flarum/
};
this.$().after($container).on('mouseup', handler);
if ('ontouchstart' in window) {
document.addEventListener('selectionchange', handler, false);
}
});
}

View File

@@ -37,6 +37,9 @@ export default function addPostQuoteButton() {
};
this.$().after($container).on('mouseup', handler);
if ('ontouchstart' in window) {
document.addEventListener('selectionchange', handler, false);
}
});
}