We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ee49936 commit 4854248Copy full SHA for 4854248
filebrowser.js
@@ -3104,19 +3104,9 @@ function setupEditor() {
3104
3105
// update on screen resize
3106
3107
- let lastWidth;
3108
-
3109
- window.addEventListener('resize', () => {
3110
3111
- if (lastWidth === window.innerWidth) {
3112
- return;
3113
- }
3114
3115
- lastWidth = window.innerWidth;
3116
3117
- updateLineNumbersHTML();
3118
3119
- });
+ const portrait = window.matchMedia('(orientation: portrait)');
+
+ portrait.addEventListener('change', updateLineNumbersHTML);
3120
3121
3122
let beautifierOptions = {
0 commit comments