Skip to content

Commit fc9703a

Browse files
authored
FIX: allows zooming of images in chat (#32891)
1 parent 199e120 commit fc9703a

File tree

1 file changed

+7
-0
lines changed
  • plugins/chat/assets/javascripts/discourse/lib

1 file changed

+7
-0
lines changed

plugins/chat/assets/javascripts/discourse/lib/lightbox.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,13 @@ export default function lightbox(images) {
2121
elementParse: (item) => {
2222
item.src = item.el[0].dataset.largeSrc || item.el[0].src;
2323
},
24+
open: function () {
25+
this.touchActionValue = document.body.style.touchAction;
26+
document.body.style.touchAction = "";
27+
},
28+
close: function () {
29+
document.body.style.touchAction = this.touchActionValue;
30+
},
2431
},
2532
});
2633
});

0 commit comments

Comments
 (0)