Commit graph

6248 commits

Author SHA1 Message Date
Tilman Vatteroth
36ac8f113c Remove browserstack integration
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-13 21:20:03 +02:00
renovate[bot]
d86e246974
Update linters (#1168)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-04-13 19:50:28 +02:00
renovate[bot]
90e1c8af11
Lock file maintenance (#1188)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-04-12 11:42:11 +02:00
Philip Molares
8186c96806
PrivateHistoryE2E: Extend POST /me/history
Test the correct behaviour in error cases

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-12 10:55:16 +02:00
Erik Michelson
7a21a26166
Disallow data and javascript URIs (#1186)
* Disallow data and javascript URIs

Signed-off-by: Erik Michelson <github@erik.michelson.eu>
2021-04-11 22:48:31 +02:00
Philip Molares
258a38f8c0
ControllerTests: Add connection to controller tests
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-11 22:06:41 +02:00
Philip Molares
0933b88ff5
ESLint: Add extra rules for tests
Add afterEach and beforeAll as additional additionalTestBlockFunctions for jest/no-standalone-expect. This is necessary, because we use expects in those functions for the history service unit tests.

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-18 14:02:55 +02:00
Philip Molares
ea7b0cb9c4
HistoryService: Add test for setHistory
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-11 22:06:36 +02:00
Philip Molares
524ad658d8
HistoryService: Add setHistory method
This is the transactional reimplementation of the business logic of the history controllers setHistory method (of the private api). This should prevent the problem that the history gets deleted, but a later error in the handling of the list of HistoryEntryImportDto let's the call fail.

See also: https://docs.nestjs.com/techniques/database#transactions

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-11 21:54:50 +02:00
Philip Molares
7c648e7056
HistoryService: Remove extra parameters from createOrUpdateHistoryEntry
As the function is now only called with a user and a note and the previous extra parameters are now added into the transactional setHistory method, this is no longer necessary.

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-11 21:28:53 +02:00
Philip Molares
6b6aef284c
NotesService: Extract checkNoteIdOrAlias into own method
To reuse this functionality in the history services setHistory method, it was extracted into its own exported function.

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-11 21:25:41 +02:00
Philip Molares
7e20bb0fef
[Project] Add seed script
This script invokes src/seed.ts to create a sqlite DB. The DB already contains some objects to manual test with. This ensures that devs easily can spin up a test instance of HedgeDoc and don't need to fumble around with the DB file.

See https://github.com/typeorm/typeorm#creating-a-connection-to-the-database

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-29 11:53:59 +02:00
Tilman Vatteroth
031e37325c Change plantuml server url to https
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-10 18:15:24 +02:00
renovate[bot]
ab9f89f39f
Update dependency vega to v5.20.2 (#1152)
* Update dependency vega to v5.20.2

Signed-off-by: Renovate Bot <bot@renovateapp.com>

* Add type to error object

Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>

Add renovate group for vega

Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>

Update vega code

Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>

* Regenerate yarn.lock

Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-10 15:27:42 +00:00
Tilman Vatteroth
ad10bfa39a Reformat package.json
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-10 16:57:42 +02:00
Tilman Vatteroth
bcb37269a4 Regenerate yarn.lock
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-10 16:57:42 +02:00
Renovate Bot
6b9c425a9e Update dependency @cypress/webpack-preprocessor to v5.7.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
a1292de26d Update dependency @testing-library/user-event to v13.1.2
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
b997fddaad Update dependency @types/luxon to v1.26.3
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
7996bc7adf Update dependency cypress-file-upload to v5.0.5
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
cd3a1fbd20 Update dependency eslint-plugin-flowtype to v5.6.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-10 16:57:42 +02:00
Renovate Bot
a5843c21c5 Update dependency highlight.js to v10.7.2
Signed-off-by: Renovate Bot <bot@renovateapp.com>
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-10 16:57:42 +02:00
Renovate Bot
ca493f1955 Update dependency i18next to v20.2.1
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
28764b3ff9 Update dependency katex to v0.13.2
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
2cdb43139e Update dependency react-use to v17.2.3
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
dc5beb9e03 Update dependency typescript to v4.2.4
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
74330086a4 Update typescript-eslint monorepo to v4.21.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
093b817361 Update dependency eslint-plugin-promise to v5
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Renovate Bot
d7915db5df Update dependency cypress to v6.9.1
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-10 16:57:42 +02:00
Tilman Vatteroth
31325a5f49 Improve renovate config by adding new groups
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-10 16:35:59 +02:00
Renovate Bot
8b0c60c4aa Update dependency d3-graphviz to v3.2.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-08 12:25:13 +02:00
Erik Michelson
c4264c4fa7
Revert "Update dependency d3-graphviz to v4" (#1160)
This reverts commit 65bdf54579.

Signed-off-by: Erik Michelson <github@erik.michelson.eu>
2021-04-07 23:38:33 +02:00
Tilman Vatteroth
3fb85fc64c Add renovate group for vega lite
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-07 23:07:48 +02:00
Tilman Vatteroth
af887877aa
Add context for iframe communicator in editor page (#1146)
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
2021-04-03 12:59:14 +02:00
Renovate Bot
6e43ec99a3 Update dependency abcjs to v6.0.0-beta.32
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-03 09:59:38 +02:00
Renovate Bot
65bdf54579 Update dependency d3-graphviz to v4
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-03 09:58:56 +02:00
Renovate Bot
668ea0ea49 Update JS test packages
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-03 09:47:39 +02:00
Renovate Bot
3f5a3870c9 Update dependency @types/mermaid to v8.2.4
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-03 09:47:17 +02:00
Renovate Bot
ef7f3c6888 Update dependency ts-loader to v8.1.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-03 09:38:30 +02:00
Renovate Bot
2e7a809332 Update typescript-eslint monorepo to v4.20.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-03 09:38:01 +02:00
Philip Molares
162f736647
PrivateApi: Add CORS-Header for rendererOrigin
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-02 17:36:51 +02:00
Philip Molares
bf13668548
PrivateApi: Serve under /api/private
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-02 17:33:42 +02:00
Philip Molares
1edc0d87c5
FrontendConfig: Fix unit test
Emulate the behaviour of the new app config: If renderOrigin is undefined instead use domain.

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-27 23:33:13 +02:00
Philip Molares
662d428e3c
AppConfig: Move default for rendererOrigin to config file
As we only use rendererOrigin in the frontend config service, where domain will be used if it is not defined, it makes more sense to move this default behavior to the app config directly. That makes it easier to understand what this variable contains and that it defaults to domain.

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-04-25 15:20:51 +02:00
Renovate Bot
116aa5e022
Pin dependency @tsconfig/node12 to 1.0.7
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-30 18:53:44 +00:00
Renovate Bot
34ae957dee
Update dependency rxjs to v7
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-30 18:53:59 +00:00
David Mehren
6ee2ddead5
Use node12 TypeScript base config
TypeScript recommends using a base config from https://github.com/tsconfig/bases.

Using this config reduces compile times by ~30%
and the size of the dist folder by ~45%.
It also enables the recommended `esModuleInterop` option,
which necessitated some changes to imports.
See also https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-7.html#support-for-import-d-from-cjs-from-commonjs-modules-with---esmoduleinterop

Signed-off-by: David Mehren <git@herrmehren.de>
2021-04-29 22:47:18 +02:00
Renovate Bot
c32c601d36
Lock file maintenance
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-29 14:49:27 +00:00
Renovate Bot
448225e124
Update dependency eslint-plugin-jest to v24.3.6
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-27 20:32:19 +00:00
Renovate Bot
77d03dd4aa
Update definitelyTyped
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-04-27 14:46:56 +00:00