Antoine Clausse
b901bb6c75
[web] Update fetch-mock
to version 12 ( #24837 )
...
* Update fetch-mock to version 12
* Replace `fetchMock.done` by `fetchMock.callHistory.done`
* Replace `…Mock.called` by `…Mock.callHistory.called`
* Replace `fetchMock.reset` by `fetchMock.hardReset`
* Replace `fetchMock.restore` by `fetchMock.hardReset`
* Replace `fetchMock.resetHistory` by `fetchMock.clearHistory`
* Replace `fetchMock.calls` by `fetchMock.callHistory.calls`
* Replace `fetchMock.flush` by `fetchMock.callHistory.flush`
* Update tests for fetch-mock version 12
See https://www.wheresrhys.co.uk/fetch-mock/docs/Usage/upgrade-guide
* Update stories for fetch-mock version 12
* Remove `overwriteRoutes` option
* Add `fetchMock.spyGlobal()` to storybook
* Remove deprecated `sendAsJson` param
* Replace `fetchMock.hardReset()` by `fetchMock.removeRoutes().clearHistory()`
* Fixup fetch-mock in storybook:
Call `mockGlobal` inside the hook, call `removeRoutes` and `unmockGlobal` on cleanup
Behaviour can be tested by navigating between
https://storybook.dev-overleaf.com/main/?path=/story/editor-ai-error-assistant-compile-log-entries--first-log-entry
https://storybook.dev-overleaf.com/main/?path=/story/editor-ai-error-assistant-compile-log-entries--rate-limited
https://storybook.dev-overleaf.com/main/?path=/story/project-list-notifications--project-invite
https://storybook.dev-overleaf.com/main/?path=/story/project-list-notifications--project-invite-network-error
And clicking the buttons
GitOrigin-RevId: 35611b4430259e4c21c3d819ad18b2e6dab66242
2025-04-17 08:06:24 +00:00
Alf Eaton
2fbb4615f9
Convert utility functions to TypeScript ( #22658 )
...
* Convert event-tracking to TypeScript
* Convert local-storage to TypeScript
* Convert mapSeries to TypeScript
* Convert SessionStorage to TypeScript
* Convert account-upgrade to TypeScript
* Convert isValidTeXFile to TypeScript
* Convert date functions to TypeScript
* Convert EventEmitter to TypeScript
* Convert isNetworkError to TypeScript
* Convert webpack-public-path to TypeScript
* Convert displayNameForUser to TypeScript
GitOrigin-RevId: 79c5a2d1101fcd520f3116f0f4af29d974189d94
2025-01-16 09:05:36 +00:00
Alf Eaton
f375362894
Always use mockable location methods ( #11929 )
...
* Always use mockable location methods
* Add eslint rules for window.location calls/assignment
* Add useLocation hook
* Update tests
GitOrigin-RevId: eafb846db89f884a7a9a8570cce7745be605152c
2023-03-17 09:05:21 +00:00
Jessica Lawshe
bd3b9007c8
Merge pull request #11078 from overleaf/jel-features-page-analytics
...
[web] Add analytics to React dash features link
GitOrigin-RevId: 5f62af1af3854b1443734cda6b97334e6eb42711
2023-01-10 09:06:43 +00:00
ilkin-overleaf
e41315364d
Merge pull request #8226 from overleaf/ae-remaining-types
...
[web] Fix remaining strict type checks
GitOrigin-RevId: 69881c37938f88c7ea4a630f362712a804085bc8
2022-06-01 08:03:29 +00:00
Miguel Serrano
c8daef59dc
Merge pull request #8016 from overleaf/msm-leavers-survey-metrics
...
[Settings] Metrics for institutional leavers survey
GitOrigin-RevId: 776d556789e8c9d0ea4c524ce4daa6bf05435810
2022-05-25 08:09:25 +00:00
Timothée Alby
3580ec6db3
Merge pull request #8029 from overleaf/ta-settings-fix-7
...
[SettingsPage] Small Fixes 7
GitOrigin-RevId: 2716fe13af3f5f6b56d6bba47505fad75ba1adbf
2022-05-24 08:04:47 +00:00
Timothée Alby
7c243c6c50
Merge pull request #7975 from overleaf/ta-settings-fixes-6
...
[SettingsPage] Small Fixes 6
GitOrigin-RevId: 19ad9a195a401909ac3dcc2be79d380cb61078da
2022-05-19 08:03:54 +00:00
Timothée Alby
cb065e7f12
Merge pull request #7820 from overleaf/msm-settings-leavers-survey
...
[Settings] Institutional Leavers Survey
GitOrigin-RevId: 1774af7fc4bb90cb39c9fc188323c44a1256bb3d
2022-05-17 08:04:00 +00:00