Fix clicking on the pop-up player placeholder expanding the clicked toot

lolsob-rspec
Claire 2021-07-12 14:44:35 +02:00
parent 9ed876972a
commit d5672b56e5
1 changed files with 2 additions and 2 deletions

View File

@ -224,8 +224,8 @@ export default class StatusContent extends React.PureComponent {
const [ deltaX, deltaY ] = [Math.abs(e.clientX - startX), Math.abs(e.clientY - startY)];
let element = e.target;
while (element) {
if (['button', 'video', 'a', 'label', 'canvas'].includes(element.localName)) {
while (element !== e.currentTarget) {
if (['button', 'video', 'a', 'label', 'canvas'].includes(element.localName) || element.getAttribute('role') === 'button') {
return;
}
element = element.parentNode;