Replace hammer.js with local code
Hammer.js is used to facilitate resizing the sidebar by dragging the sidebar button. For this use case, we can avoid a dependency which is not actively maintained, get more visibility into what the code is doing and make testing easier by using a small amount of our own code. In the process the tests for drag resizing in the sidebar were refactored to avoid referencing private fields of `Sidebar` and mocking `getComputedStyle`. The user-facing behavior should be unchanged.
Showing
... | ... | @@ -31,7 +31,6 @@ |
"@types/chai": "^5.0.0", | ||
"@types/dompurify": "^3.0.0", | ||
"@types/escape-html": "^1.0.1", | ||
"@types/hammerjs": "^2.0.41", | ||
"@types/katex": "^0.16.0", | ||
"@types/retry": "^0.12.1", | ||
"@types/scroll-into-view": "^1.16.0", | ||
... | ... | @@ -69,7 +68,6 @@ |
"globals": "^15.11.0", | ||
"gulp": "^5.0.0", | ||
"gulp-changed": "^5.0.1", | ||
"hammerjs": "^2.0.4", | ||
"karma": "^6.0.1", | ||
"karma-chrome-launcher": "^3.1.0", | ||
"karma-coverage-istanbul-reporter": "^3.0.2", | ||
... | ... |
Please register or sign in to comment