Commit Graph

834 Commits

Author SHA1 Message Date
Jakob Ackermann
425e7b1e5b [web] enable mongo notablescan in CI (#29501)
* [monorepo] record ERROR/FATAL log messages in junit report

* [web] put SaaS specific code behind feature flag

* [web] use split test cache for getting user assignments

The unit tests needed updating as they did not replicate any of the
 mongo filtering. The acceptance tests cover this logic.

* [web] make better use of existing indexes

* [web] avoid col-scan in tests of notifications module

* [web] remove cleanup of empty feedbacks collection

* [web] add assertion for reason of rejected request in launchpad test

* [web] add missing indexes

* [web] enable mongo notablescan

* [web] make emailNotifications tests compatible with notablescan

GitOrigin-RevId: b888f2feeb3a0e915f068ae1c4ea23ec17821221
2026-01-13 09:06:38 +00:00
Domagoj Kriskovic
7b00e5d9f5 Add routes to save/get project notification preferences (#30114)
* Add routes to save/get project notification preferences

* update route url

* improve zod schema

* remove unused json response

* update schema and fix tests

* add jsdoc types to pass type-check

* remove using zod strict()

GitOrigin-RevId: f3ab5c88b58bd5af71e0504d0efbe03bdf9b243c
2025-12-16 09:07:07 +00:00
ilkin-overleaf
4801174f68 Merge pull request #30188 from overleaf/ii-domain-capture-group-sso-link
[web] Improved `group-sso-link` logs

GitOrigin-RevId: 426dfa46c5c3a236382744fe408f33df81c5a9a0
2025-12-16 09:06:53 +00:00
Andrew Rumble
f1e788d9b3 Merge pull request #29967 from overleaf/ar/web-remove-mocha-unit-tests
[web] remove mocha unit tests

GitOrigin-RevId: eda753af3470dbd1f385cb0bc3f06d78ade8a764
2025-12-03 09:05:37 +00:00
Andrew Rumble
07c827e9fd Merge pull request #29928 from overleaf/ar-last-infrastructure-conversions
[web] last infrastructure conversions

GitOrigin-RevId: ad1aff9b7df0610ed0303157d9e2c8032f32c02b
2025-11-28 09:05:56 +00:00
Andrew Rumble
18f44866e5 Merge pull request #29919 from overleaf/revert-29795-ar-last-infrastructure-conversions
Revert "[web] last infrastructure conversions"

GitOrigin-RevId: 48dc64553012afb5d2db4b2eb9c9898489b7e5ef
2025-11-27 09:05:54 +00:00
Andrew Rumble
d748d8d606 Merge pull request #29795 from overleaf/ar-last-infrastructure-conversions
[web] last infrastructure conversions

GitOrigin-RevId: 68aa11625a9bc6d0d5324ecd95bb5ac52af8ee96
2025-11-27 09:05:30 +00:00
Simon Gardner
7dce5f0e25 Adds audit log entry for user Logout event
GitOrigin-RevId: 5a305166ba0e017ae7cb3d426cdae541e8db62c3
2025-11-25 09:05:38 +00:00
Malik Glossop
016778295a Merge pull request #29733 from overleaf/mg-transfer-ownership
Fix transfer ownership permissions

GitOrigin-RevId: b6d09704361507085e3eae8dc9240a36ae47c70e
2025-11-24 09:06:50 +00:00
Andrew Rumble
beb6f6d484 Merge pull request #29597 from overleaf/ar-last-features-esm-conversion
[web] last features esm conversion

GitOrigin-RevId: a35ab995bf654f1cdfe0e0062d8806761ecccf2d
2025-11-21 09:05:36 +00:00
Andrew Rumble
5a4592b153 Merge pull request #29720 from overleaf/renovate-npm-glob-vulnerability
[Core] Update dependency glob to v11.1.0 [SECURITY] - abandoned

GitOrigin-RevId: 866612e84e2afd3edc97c244e22faeaff22484cf
2025-11-20 09:05:44 +00:00
Antoine Clausse
1447842fbd Remove scripts about unconfirmed emails removal (#29683)
* Remove unconfirmed email deletion scripts

* Remove tests

GitOrigin-RevId: a0ef84207fced135a13074265fe5d3b38400d76f
2025-11-18 09:05:29 +00:00
Andrew Rumble
394c60f2cf Merge pull request #29659 from overleaf/revert-29656-revert-29521-ar-models-es-conversion
Revert "Revert "[web] Convert models and self-referential test files to ESM ""

GitOrigin-RevId: f64000ae31d298b075a8722dfc51f294c71bc021
2025-11-18 09:04:56 +00:00
Andrew Rumble
ae6dec9dcb Merge pull request #29656 from overleaf/revert-29521-ar-models-es-conversion
Revert "[web] Convert models and self-referential test files to ESM "

GitOrigin-RevId: 5455cccbb513bd9ca36ce526ff1553065f83d233
2025-11-13 09:06:36 +00:00
Andrew Rumble
7c9fea64ac [web] Convert models and self-referential test files to ESM (#29521)
from overleaf/ar-models-es-conversion

GitOrigin-RevId: a92ab8342c0f3e23155eacc0570458fc910c3d71
2025-11-13 09:06:13 +00:00
Antoine Clausse
f028f21e3c [web] Remove the nocdn fallback (#29311)
* Remove the nocdn fallback

Co-authored-by: Tim Down <tim.down@overleaf.com>

* Remove comment about nocdn query string in ExpressLocals.mjs

Co-authored-by: Tim Down <tim.down@overleaf.com>

* Remove `Frontend` global

---------

Co-authored-by: Tim Down <tim.down@overleaf.com>
GitOrigin-RevId: 74160ed4cf8ba17f8bd9b6793c8baa80883d3361
2025-11-12 09:05:31 +00:00
Miguel Serrano
fe884195dc [web] Add Project logs to Group Audit Logs view (#29456)
* Add `project-created` audit log only for managed users

* Include project audit logs in group audit logs

* Added details column in Group Audit Logs UI

GitOrigin-RevId: 96c7a31b37270912df1629e27d905b692f28da46
2025-11-12 09:05:18 +00:00
Antoine Clausse
f2788868ac [web] Create script to re-add wrongly deleted emails (#29550)
* Allow passing auditLog extra info in addEmailAddress

* Create script re_add_deleted_emails.mjs

* Check email validity when parsing the CSV

* Allow no IP and initiator for the log events

* Add an acceptance test on re_add_deleted_emails

* Fix remove_unconfirmed_emails.mjs

We're not planning to run this again, but this could help if some code from here ever gets copy-pasted

* Fix remove_unconfirmed_emails.mjs

Rename `emailsToRemove` to `emailsToRemoveCandidates`

* Remove console.logs of event logs:

That's unnecessary complexity and we already have the data from the previous script

* Copy `addEmailAddress` into the script

* Handle primary emails correctly

* Ignore a TS error

* Fix async function in createUsers (tests)

* Add assertion for already in use emails in ReAddDeletedEmailsTests

* Add information in admin-panel for add-email audit logs

GitOrigin-RevId: f8480426d7b323f88a268874488d9ae641bc6045
2025-11-07 09:05:17 +00:00
Andrew Rumble
4f02a85aa4 Update paths
GitOrigin-RevId: 399c594dd1bbf739d91874df6be3b70e57fe01e3
2025-11-06 09:05:57 +00:00
Andrew Rumble
f02f6475ac Update paths
GitOrigin-RevId: a9474c8f36e8b287de4dd8fda29bc082001444ac
2025-10-23 08:06:10 +00:00
Domagoj Kriskovic
71457d74cb Add notifications web module (#28983)
* Add notifications web module

* implement getThreadMessage in chat

* Save comment mention notification

* check if recipient is a real user

* move commentMentionDelay

* use module-hooks types

* remove router

* updated collection name

GitOrigin-RevId: cf8240c88aac7d7e4de4bf51cfe2608b6b7e7918
2025-10-20 08:05:20 +00:00
Antoine Clausse
d7e1ad5588 Merge pull request #28981 from overleaf/ac-some-web-esm-migration-6
[web] Convert some Features/User files to ES modules

GitOrigin-RevId: c0d487082fa4822c68130e1e98c043297d4bedeb
2025-10-17 08:05:53 +00:00
Brian Gough
729e0f5ac9 move migrations to shared location (#28306)
* fix: correct typedef for Document in helpers.mjs

* add move-migrations codemod

* update migration paths to use shared migrations directory

* move migrations to shared location

* fix: update Dockerfile and docker-compose.ci.yml to include migrations directory

* feat: add migrations tool to workspaces in package.json

* [monorepo] Fix order of docker ignore rules

* [web] remove unused docker ignore file

* [monorepo] replace old references to migrations folder

* [server-ce] copy migrations from new place

* [migrations] Inline web scripts

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] move three web scripts over

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] add missing collection

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] remove lodash dependency

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] avoid mongodb-legacy dependency

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [monorepo] run migrations from tools/migrations

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] simplify migration for adding gitBridge feature to users

* [monorepo] run migrations from tests in all the services

* [migrations] add Jenkins pipeline for linting/formatting

* [monorepo] fixup running web migrations everywhere

* [monorepo] trigger Jenkins builds on changes to mongo migrations

* [migrations] add Jenkins pipeline for linting/formatting

* [monorepo] build scripts: update devDependencies before deps scanning

* [monorepo] build scripts: formerly depend on tools/migrations

* [monorepo] run eslint on .mjs files

* [migrations] enable more eslint rules and fix all the errors

* [rake] fix migrations:list task

---------

Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
GitOrigin-RevId: 14cf69cc1b9405bbc75adbb9a000e555500e0614
2025-10-16 08:07:37 +00:00
Andrew Rumble
7987c18350 Rename files
GitOrigin-RevId: 73ecf16aa08d0677661249f09d7be15214d15982
2025-10-16 08:06:51 +00:00
Andrew Rumble
3211c7c37a Make test admin users engineers
GitOrigin-RevId: 627b5b05eefdfa675937764b7c798e99ab6ef37e
2025-10-09 08:07:48 +00:00
Antoine Clausse
33e63d79fc Merge pull request #28584 from overleaf/ac-some-web-esm-migration-5
[web] Convert some Features files to ES modules (part 5)

GitOrigin-RevId: 0cad67f9afe0095e2b066bf2f4d3717c00540dab
2025-10-08 08:06:15 +00:00
Brian Gough
d7cd65d20c Merge pull request #28628 from overleaf/bg-cache-history-size-on-project
Implement project size checks on file uploads

GitOrigin-RevId: 4dffe237e6992b859f07964cffa82ff1c13e91c9
2025-09-24 08:07:37 +00:00
Antoine Clausse
46715191e3 Merge pull request #28544 from overleaf/ac-some-web-esm-migration-4
[web] Convert some Features files to ES modules (part 4)

GitOrigin-RevId: cf11a7584e39c4d4de08e2f924240e488a4066c4
2025-09-24 08:05:58 +00:00
Olzhas Askar
d11674a51f Merge pull request #28540 from overleaf/oa-punctuation
[web] Notification punctuation

GitOrigin-RevId: ba20f0049a5f72f3ba03917d9fe76b220adffcf0
2025-09-23 08:07:49 +00:00
Andrew Rumble
b1cf8d4e88 Return a formatted JSON error when validation fails
GitOrigin-RevId: 0f2d3d73a6e371aa332dee245be8802250adfb2b
2025-09-23 08:07:37 +00:00
Andrew Rumble
3cd9ded7c8 Make sharing test use correct user to setCollaboratorInfo
GitOrigin-RevId: 02b35facff478ccf269fb472eba271cbf8473d46
2025-09-23 08:07:32 +00:00
Eric Mc Sween
b31ee65a09 Migrate MockV1HistoryApi to zod
GitOrigin-RevId: d0fd392e76632e12832fb794d60b50a0835f3756
2025-09-23 08:07:13 +00:00
Brian Gough
fd82788e61 Merge pull request #28506 from overleaf/bg-size-limits
add size check when cloning project (logging only)

GitOrigin-RevId: 1f56ed80a2d05b28c44fab8532d751ad8e758943
2025-09-18 08:05:52 +00:00
Andrew Rumble
7f908915aa Merge pull request #28367 from overleaf/ar-migrate-routermjs-to-zod
[web] migrate router.mjs to zod

GitOrigin-RevId: d3fc21a11351f3e2deb5011cd1beeb86286a300b
2025-09-16 08:05:26 +00:00
Antoine Clausse
723954ccc2 [web] Convert some Features files to ES modules (part 2) (#28275)
* Rename files

* Rename test files

* Convert to ESM

GitOrigin-RevId: b0ee442ac8edd4ef3695f93a91ffd9521e6bf259
2025-09-16 08:04:59 +00:00
Eric Mc Sween
543f3fafcc Merge pull request #28431 from overleaf/em-docupdater-get-ranges
Look in docupdater when obtaining comments for DSMP

GitOrigin-RevId: acaead280f725da8e0c438d5b429fa983c3cad86
2025-09-15 08:05:29 +00:00
Jakob Ackermann
f8d69d05af [web] display project history blob size on admin pages (#28351)
* [history-v1] add endpoint for getting blob stats of projects

* [web] display project history blob size on admin pages

* [web] break down history storage size by text and binary blob

GitOrigin-RevId: bfa4d56cf2c503d03005c13a0f7ac38158156cd2
2025-09-10 08:06:19 +00:00
Domagoj Kriskovic
ff0e725935 [dsmp] Add endpoint to retrieve a single message from chat (#28242)
* [dsmp] Add endpoint to retrieve a single message from chat

* use user:null in case is deleted

GitOrigin-RevId: f42360c2e05cfe93fa11230ac3cc311bdb044c1d
2025-09-05 08:06:15 +00:00
Antoine Clausse
86e74b9228 [web] Update admin permissions to view/modify project contents (#28162)
* Split capability definitions `modify-project`/`view-project` into `modify-project-content`/`modify-project-setting`/`view-project-content`/`view-project-setting`

* Add admin capabilities check in AuthorizationManager

* Update checks in router

* Update frontend checks

* Remove UI elements for admins without `view-project-content`

* Update tests

* Remove `modify-project-content` from the roles' capabilities

* Update tests

* Add "with admin roles" tests in AuthorizationTests.mjs

GitOrigin-RevId: 3311bcb2da792968927b5b3703b24e069d0baf5b
2025-09-05 08:05:08 +00:00
Domagoj Kriskovic
f6820ed794 [dsmp] replace stubs with MockDocStoreApi and MockDocUpdaterApi (#28122)
* [dsmp] replace stubs with MockDocStoreApi and MockDocUpdaterApi

* fix reject changes test

GitOrigin-RevId: 692195545b16e9674327f7a9828b53f5271b6f20
2025-09-03 08:05:36 +00:00
Antoine Clausse
b8852282cd [web] Promisify AuthorizationTests (#28211)
* Promisify AuthorizationTests.mjs

* Replace reassigned response/body by separate consts

GitOrigin-RevId: db801a93919b7ecf2d8708dc38af231321a6b43b
2025-09-02 08:05:05 +00:00
Jakob Ackermann
bd4130c147 [filestore] remove user files endpoints (#28125)
* [filestore] remove user files endpoints

* [web] remove user files integration for filestore

GitOrigin-RevId: 565fa68a659c07420ee6141d0f276b4e4d2972e0
2025-09-02 08:04:52 +00:00
Andrew Rumble
42f3bd208b Log error on web service start when hashedEmailSalt not set
GitOrigin-RevId: 67473de85d869b56aa1321391b03ddcceb95346b
2025-08-29 08:05:25 +00:00
Eric Mc Sween
201e5c49aa Merge pull request #28019 from overleaf/em-dsmp-comment-event
DS mobile notification for comment added/replied to

GitOrigin-RevId: 602983c679ed415bf8dd8fbf83b328e5ee832e2b
2025-08-26 08:05:20 +00:00
Brian Gough
f5dbbadf79 add option to disable link sharing (#27626)
* add option to remove link-sharing from backend

* restrict make link-sharing in the frontend based on capability

* extend e2e project-sharing tests to cover OVERLEAF_DISABLE_LINK_SHARING=true

* throw an error when link sharing is disabled in TokenAccessHandler

* throw errors when attempting to add users to projects with link sharing disabled

* Update server-ce/test/project-sharing.spec.ts

Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>

* add tests for existing access when link sharing is disabled

* update tests to specify access restrictions for read-only and read-write link shared projects

* [web] block access to legacy public project with link-sharing disabled

---------

Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
GitOrigin-RevId: 5f194dbcb790e973e427c58a3a4a738a5dd74cb4
2025-08-20 08:05:33 +00:00
Jakob Ackermann
d697f00525 [web] reduce log noise in CI (#27961)
* [web] reduce noise from CollectPayPalPastDueInvoiceTest

* [web] reduce noise for frontend tests that use Range.getClientRects

* [web] avoid nesting <li> elements in ProjectToolsMoreDropdownButton

RenameProjectMenuItem/CopyProjectMenuItem will return <li> elements.

* [web] avoid clicking on links that navigate away in JSDom

* [web] add mock for location change in JSDom

* [web] add fallback stripe subscription data for test

3.8k lines of log noise!

GitOrigin-RevId: 7adab182487a6c07ac9809c60802e498a0edb0ec
2025-08-19 08:05:50 +00:00
Antoine Clausse
9774d9048c [web] Add admin permissions modify-group & modify-managed-group (#27456)
* Add capabilities `modify-group` and `modify-managed-group`

* Fix: Warning: validateDOMNesting(...): <span> cannot appear as a child of <option>

* Add `form-control` to select (fix styles)

* Check if admin can modify the group (frontend)

* Check if admin can modify the group (backend)

* Update tests

* Fix: Set `useSettingsUKAMF` state from `data?.useSettingsUKAMF`

* Add tests: Subscriptions update with adminRolesEnabled

* Use `getAdminCapabilities` helper

* Update `requireModifyGroupPermission` to array

Co-authored-by: Andrew Rumble <andrew.rumble@overleaf.com>

* Rename `canModify` to `canModifySubscription`

Co-authored-by: Andrew Rumble <andrew.rumble@overleaf.com>

* Refactor `requireModifyGroupPermission` stub

Co-authored-by: Andrew Rumble <andrew.rumble@overleaf.com>

* Test with `adminRolesEnabled` in SubscriptionDeletionTests.mjs

* Update test description with `adminRoles`

---------

Co-authored-by: Andrew Rumble <andrew.rumble@overleaf.com>
GitOrigin-RevId: 37b9a2e838fd566a33aa3a70631cebfd01b520ef
2025-08-14 08:05:00 +00:00
Jakob Ackermann
d055f01c00 [web] add config option for custom maintenance message (#27618)
GitOrigin-RevId: e01eebecce780af6e9e3f8b82321cb7776d414e2
2025-08-13 08:06:12 +00:00
roo hutton
eab0e40ba4 Merge pull request #27742 from overleaf/rh-odc-rm-skip
Remove skip button from ODC form

GitOrigin-RevId: b3974e041ab7fa5f28c2d5eb5176510616d50127
2025-08-12 08:06:12 +00:00
Jakob Ackermann
6a92acf542 Merge pull request #27476 from overleaf/jpa-transfer-all
[web] add script for transferring all of a users projects in Server Pro

GitOrigin-RevId: 3aad2b624e1da2af83fec0715c2e5e08eff43695
2025-07-30 08:06:51 +00:00