Commit Graph

1585 Commits

Author SHA1 Message Date
Tom Moor
45831e9469 Remove NotificationSettings table (#5036
* helper

* Add script to move notification settings

* wip, removal of NotificationSettings

* event name

* iteration

* test

* test

* Remove last of NotificationSettings model

* refactor

* More fixes

* snapshots

* Change emails to class instances for type safety

* test

* docs

* Update migration for self-hosted

* tsc
2023-03-18 06:32:41 -07:00
Tom Moor
41f97b0563 fix: Users should not be redirected to disabled authentication providers (#5055
* fix: Users should not be redirected to disabled authentication providers
Re-enabled tests in plugin directory

* Fix plugin http tests
2023-03-18 06:17:54 -07:00
Tom Moor
6dd4afccaf fix: Context binding,
closes #5056
2023-03-18 09:17:25 -04:00
Tom Moor
e69935be99 Remove username column (#5052) 2023-03-17 08:23:32 -07:00
Apoorv Mishra
21a44428f4 Filter groups given a member (#5034)
* feat: filter groups given a member

* Revert "feat: filter groups given a member"

This reverts commit 7dac8bb38de1fdaf661c636c5d1b13e4112fd8fd.

* fix: make it work via db query
2023-03-16 12:31:56 +05:30
Tom Moor
d663b92f2a tsc 2023-03-13 21:08:52 -04:00
Tom Moor
f6ac73a741 Add sanitization to log messages to reduce chance of tokens ending up in server logs 2023-03-13 20:42:22 -04:00
Tom Moor
e2dff9afca fix: Viewers cannot delete their own comments 2023-03-11 19:08:12 -05:00
Tom Moor
e9ece9125a fix: Comment deletion is not propagated correctly 2023-03-11 19:01:19 -05:00
Tom Moor
3eabb30949 fix: favicon, apple touch icon, etc not loaded from CDN 2023-03-11 14:10:13 -05:00
Mohamed ELIDRISSI
e2429f6d85 refactor: add server side validation schema for fileOperations (#4989)
* refactor: move files to subfolder

* refactor: schema for fileOperations.info

* refactor: schema for fileOperations.list

* refactor: schema for fileOperations.delete

* refactor: schema for fileOperations.redirect
2023-03-08 19:01:51 -08:00
Tom Moor
58f2b9aa2b fix: Invited users should not appear as option in @mention, closes #5006 2023-03-07 20:44:41 -05:00
Tom Moor
d3b099819d feat: Add @mention support to comments (#5001)
* Refactor, remove confusing 'packages' language

* Basic notifications when mentioned in comment

* fix: Incorrect trimming of comments

* test
2023-03-06 19:19:49 -08:00
Tom Moor
5c12f52c8d do not send mention and document published emails to one user 2023-03-06 19:37:42 -05:00
Tom Moor
4ba5d0d8e0 Tweaks, do not send mention and document updated emails to one user 2023-03-06 18:08:17 -05:00
Apoorv Mishra
de031b365c Capability to mention users in a document (#4838)
* feat: mention user

* fix: trigger api call on every letter typed

* fix: this allows command menu to re-render upon props change, shouldComponentUpdate prevented re-rendering when necessary

* fix: add node

* fix: mention node styling

* fix: Caret not visible after inserting mention

* fix: apply mentionRule

* fix: label is to be obtained from content, not attrs

* feat: add mentions table and model

* fix: typo

* fix: make all mention nodes visible in shared doc

* feat: parse mention ids from doc text

* feat: MentionsProcessor

* feat: documents.publish tests

* feat: tests for MentionsProcessor

* feat: schedule notifs for mentions

* fix: get rid of Mention model

* fix: put actor id and mention id in raw md

* Revert "fix: put actor id and mention id in raw md"

This reverts commit 3bb8a22e3c560971dccad6d2f82266256bcb2d96.

* Revert "Revert "fix: put actor id and mention id in raw md""

This reverts commit 3c5b36c40cebf147663908cf27d0dce6488adfad.

* fix: review

* fix: no need of set

* fix: show avatar

* fix: get rid of eventName

* fix: font-weight

* fix: prioritize mention notifs

* fix: store id in md

* fix: no need of prepending m

* fix: fetchPage

* fix: Avatars incorrect color

* fix: remove scanRE

* fix: test

* fix: include alphabet other than latin

* lockfile

* fix: regex should test for letters, marks and digits

---------

Co-authored-by: Tom Moor <tom.moor@gmail.com>
2023-03-06 14:54:57 -08:00
Tom Moor
591a87b728 Suppress comment notifications when viewing document (#4987)
* Updating views from collaboration server

* refactor

* Suppress comment notifications based on views

* test
2023-03-05 18:33:46 -08:00
Tom Moor
ac3284986c fix: Replies to comments in threads only trigger notifications to document subscribers, closes #4984 2023-03-05 16:19:56 -05:00
Tom Moor
760355302c Comment notification emails (#4978)
* Comment notification emails

* fix links
fix threading in email inboxes
from is now commenter name

* fix

* refactor

* fix async filter
2023-03-05 08:01:56 -08:00
Mohamed ELIDRISSI
bef9673530 refactor: add server side validation schema for views (#4953)
* refactor: move files to subfolder

* refactor: schema for views.list

* refactor: schema for views.create
2023-02-28 18:20:27 -08:00
Tom Moor
739a291a46 fix: Cannot read properties of undefined (reading 'message') 2023-02-28 18:55:25 -05:00
Apoorv Mishra
6b00ced48f fix: use LOG_LEVEL to set server log severity (#4937) 2023-02-27 21:36:01 +05:30
Mohamed ELIDRISSI
00baa2bd6d refactor: add server side validation schema for groups (#4881)
* refactor: move files to subfolder

* refactor: schema for groups.list

* refactor: schema for groups.info

* refactor: schema for groups.create

* refactor: schema for groups.update

* refactor: schema for groups.delete

* refactor: schema for groups.memberships

* refactor: schema for groups.add_user

* refactor: schema for groups.remove_user
2023-02-25 12:03:23 -08:00
Tom Moor
fc8c20149f feat: Comments (#4911)
* Comment model

* Framework, model, policy, presenter, api endpoint etc

* Iteration, first pass of UI

* fixes, refactors

* Comment commands

* comment socket support

* typing indicators

* comment component, styling

* wip

* right sidebar resize

* fix: CMD+Enter submit

* Add usePersistedState
fix: Main page scrolling on comment highlight

* drafts

* Typing indicator

* refactor

* policies

* Click thread to highlight
Improve comment timestamps

* padding

* Comment menu v1

* Change comments to use editor

* Basic comment editing

* fix: Hide commenting button when disabled at team level

* Enable opening sidebar without mark

* Move selected comment to location state

* Add comment delete confirmation

* Add comment count to document meta

* fix: Comment sidebar togglable
Add copy link to comment

* stash

* Restore History changes

* Refactor right sidebar to allow for comment animation

* Update to new router best practices

* stash

* Various improvements

* stash

* Handle click outside

* Fix incorrect placeholder in input
fix: Input box appearing on other sessions erroneously

* stash

* fix: Don't leave orphaned child comments

* styling

* stash

* Enable comment toggling again

* Edit styling, merge conflicts

* fix: Cannot navigate from insights to comments

* Remove draft comment mark on click outside

* Fix: Empty comment sidebar, tsc

* Remove public toggle

* fix: All comments are recessed
fix: Comments should not be printed

* fix: Associated mark should be removed on comment delete

* Revert unused changes

* Empty state, basic RTL support

* Create dont toggle comment mark

* Make it feel more snappy

* Highlight active comment in text

* fix animation

* RTL support

* Add reply CTA

* Translations
2023-02-25 12:03:05 -08:00
Apoorv Mishra
af3edd7cb2 fix: coalesce falsy body to {} (#4929) 2023-02-25 11:14:44 -08:00
dependabot[bot]
05c5d0637e chore(deps): bump koa-body from 4.2.0 to 6.0.1 (#4806)
* chore(deps): bump koa-body from 4.2.0 to 6.0.1

Bumps [koa-body](https://github.com/koajs/koa-body) from 4.2.0 to 6.0.1.
- [Release notes](https://github.com/koajs/koa-body/releases)
- [Changelog](https://github.com/koajs/koa-body/blob/master/CHANGELOG.md)
- [Commits](https://github.com/koajs/koa-body/compare/v4.2.0...v6.0.1)

---
updated-dependencies:
- dependency-name: koa-body
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update types

* test

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tom Moor <tom.moor@gmail.com>
2023-02-24 05:11:49 -08:00
dependabot[bot]
9d9df81dec chore(deps): bump sequelize from 6.20.1 to 6.29.0 (#4921)
* chore(deps): bump sequelize from 6.20.1 to 6.29.0

Bumps [sequelize](https://github.com/sequelize/sequelize) from 6.20.1 to 6.29.0.
- [Release notes](https://github.com/sequelize/sequelize/releases)
- [Commits](https://github.com/sequelize/sequelize/compare/v6.20.1...v6.29.0)

---
updated-dependencies:
- dependency-name: sequelize
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

* lint

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tom Moor <tom.moor@gmail.com>
2023-02-23 19:19:12 -08:00
Tom Moor
3acc352cf0 Fix PWA manifest (#4922) 2023-02-23 18:52:25 -08:00
Tom Moor
eb42f8006d chore: Remove 16+ unused dependencies (#4910)
* chore: Remove no-longer used webpack loaders

* chore: Remove migration of markdown from Slate documents (2y old)

* chore: Remove more unused deps

* chore: Remove explicit core-js dep

* Remove more unused dependencies

* test
2023-02-21 08:43:28 -08:00
Tom Moor
a9e373c72f fix: HMR in development 2023-02-20 11:23:25 -05:00
Tom Moor
21a1257d06 chore: Move remaining auth methods to plugins (#4900)
* Move Google, Email, and Azure to plugins

* Move OIDC provider, remove old loading code

* Move AuthLogo to plugin

* AuthLogo -> PluginIcon

* Lazy load plugin settings
2023-02-19 19:52:08 -08:00
Tom Moor
667ffdeaf1 fix: Import size should use larger of AWS_S3_UPLOAD_MAX_SIZE and MAX_IMPORT_SIZE
closes #4899
2023-02-19 19:18:31 -05:00
Tom Moor
70beb7524f feat: Custom accent color (#4897)
* types

* Working, but messy

* Add InputColor component

* types

* Show default theme values when not customized

* Support custom theme on team sign-in page

* Payload validation

* Custom theme on shared documents

* Improve theme validation

* Team -> Workspace in settings
2023-02-19 07:43:03 -08:00
Tom Moor
7c05b7326a test 2023-02-18 14:16:34 -05:00
Tom Moor
66b5dd0a2b fix: Do not show authentication provider plugins that aren't enabled 2023-02-18 13:56:03 -05:00
Hans Pagel
e754f89e5c Replace Webpack with Vite (#4765)
Co-authored-by: Tom Moor <tom@getoutline.com>
Co-authored-by: Vio <vio@beanon.com>
2023-02-15 19:39:46 -08:00
Mohamed ELIDRISSI
0976e85a1a refactor: add server side validation schema for authProviders (#4876)
* refactor: move files to subfolder

* refactor: schema for authenticationProviders.info

* refactor: schema for authenticationProviders.update

* refactor: use validated body
2023-02-14 14:49:24 -08:00
Tom Moor
60101c507a Move bulk of webhook logic to plugin (#4866)
* Move bulk of webhook logic to plugin

* Re-enable cleanup task

* cron tasks
2023-02-12 16:28:11 -08:00
Tom Moor
e028715afb Minor fixes from enterprise codebase 2023-02-12 16:31:15 -05:00
Tom Moor
33afa2f029 Plugin architecture (#4861)
* wip

* Refactor, tasks, processors, routes loading

* Move Slack settings config to plugin

* Fix translations in plugins

* Move Slack auth to plugin

* test

* Move other slack-related files into plugin

* Forgot to save

* refactor
2023-02-12 10:11:30 -08:00
Mohamed ELIDRISSI
492beedf00 refactor: add server side validation schema for apiKeys (#4859)
* refactor: add tests for apiKey api routes

* refactor: move files to subfolder

* refactor: schema for apiKeys.create and apiKeys.delete
2023-02-11 15:02:52 -08:00
Tom Moor
bb6f4b1c1e fix: Attachment converted to links when AWS ACL is public-read, closes #4853 2023-02-10 17:42:09 -05:00
Tom Moor
239e9e294d fix: Microsoft auth silently errors when logged into multiple Microsoft accounts, allow account selection in OAuth flow 2023-02-04 14:56:52 -05:00
Tom Moor
9b002abae3 fix: Ensure tsvector content is below 1Mb limitation
closes #4714
2023-02-04 14:26:54 -05:00
Tom Moor
534eeacc97 fix: Documents with images exported as HTML have broken images
closes #4822
2023-02-04 14:04:38 -05:00
Tom Moor
8b28d6f6e0 fix: Suppress Slack updated notifications when publishing
closes #4821
2023-02-04 14:00:30 -05:00
Tom Moor
a1cefa9771 fix: FORCE_HTTPS setting results in redirect loop when Outline terminates SSL 2023-02-02 21:45:33 -05:00
Apoorv Mishra
1caa51f58e Viewer should be allowed to subscribe to a document (#4814)
* fix: viewer should be allowed to subscribe to a document

* fix: allow subscribe only if the user has read permission for collection
2023-01-31 19:46:10 +05:30
dependabot[bot]
8f166ca775 chore(deps-dev): bump jest-cli from 28.1.3 to 29.4.1 (#4805)
* chore(deps-dev): bump jest-cli from 28.1.3 to 29.4.1

Bumps [jest-cli](https://github.com/facebook/jest/tree/HEAD/packages/jest-cli) from 28.1.3 to 29.4.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/commits/v29.4.1/packages/jest-cli)

---
updated-dependencies:
- dependency-name: jest-cli
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Snapshots

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tom Moor <tom.moor@gmail.com>
2023-01-30 20:17:09 -08:00
Tom Moor
f39487d25b fix: PaginatedList does not always load more (#4811) 2023-01-30 19:53:14 -08:00