Age | Commit message (Collapse) | Author |
|
also remove dependency vulnerability
Signed-off-by: Vinicius Reis <vinicius.reis@nextcloud.com>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Do not show the spinning wheel unless the file actually changed.
* Resolves #2215.
* Targets: master.
Opening Readme.md in the sidebar triggers a PROPFIND.
We parse its response just like the initial file list load.
Readme.md is part of the response and our handler attempts to open it.
Only set the vm.ready if the file actually changed.
Only a changed file will make the editor load again.
Only then will it set ready to true and stop the spinning wheel.
Signed-off-by: Max <max@nextcloud.com>
|
|
Using `mdiOrderBoolAscendingVariant` as suggested in #2018.
Fixes #2018 together with the previous commit.
Signed-off-by: Max <max@nextcloud.com>
|
|
See #2018.
Use tiptap TaskList and TaskItem.
Markdown-it happily mixes tasks and bullet points in the same list.
Tiptap lists are strictly separated.
Split bullet and tasks into BulletList and TaskList in markdown-io.
Just like this will turn into three different lists:
* one
- two
+ three
This will now also turn into three different lists
with the middle one being a task list:
* first list
* [ ] todo
* [x] done
* third list
Signed-off-by: Max <max@nextcloud.com>
|
|
Signed-off-by: Max <max@nextcloud.com>
|
|
This allows specifying what steps to perform in a test inside the test data.
Signed-off-by: Max <max@nextcloud.com>
|
|
Signed-off-by: Max <max@nextcloud.com>
|
|
Signed-off-by: Max <max@nextcloud.com>
|
|
Signed-off-by: Max <max@nextcloud.com>
|
|
Signed-off-by: Max <max@nextcloud.com>
|
|
This is a regression tests for #2104.
Signed-off-by: Max <max@nextcloud.com>
|
|
Cypress tests were failing because they triggered editor.focus on a read only doc.
Focus seems to cause sendable steps - maybe because the current cursor changes.
Prevent this on various levels:
* Do not autofocus read only docs.
* Do not send steps to read only docs.
* Handle server response with 403 without content gracefully when sending steps.
The last originated here:
https://github.com/nextcloud/text/blob/master/lib/Service/ApiService.php#L158
So wither the session was not valid or the document read only.
Not entirely sure what best to do in this situation.
Logging to console.error for now.
Signed-off-by: Max <max@nextcloud.com>
|
|
Also remove all the timeouts and error workarounds from share tests.
We increase the timeout in CI for all commands
and that works quite well so far.
Signed-off-by: Max <max@nextcloud.com>
|
|
Currently only few tests are language dependent.
Run tests without a preset language on the server
and fix the language in the tests in question.
Signed-off-by: Max <max@nextcloud.com>
|
|
Signed-off-by: Max <max@nextcloud.com>
|
|
See #2171.
Even though this is meant to improve load times
I did not observe any improvements locally.
I suspect that is because the workspace was loaded in parallel with the PROPFIND anyway.
Experience may differ in production environments obviously.
It is still one request less and the code also seems more clean.
Signed-off-by: Max <max@nextcloud.com>
|
|
Migrate the entire editor to tiptap v2.
Some changes were introduces that go beyond just using the new tiptap API:
*Collaboration*
Port tiptap1 collaboration.
We still want to use our session and sync mechanism.
*Serialization*
Add Markdown extension to handle serialization.
Tiptap config extensions are not automatically added
to the prosemirror schema anymore.
The extension adds the `toMarkdown` config value to the prosemirror schema.
With the new naming scheme tiptap nodes for a number of elements
do not match the prosemirror names.
Camelcase the marks and nodes from `defaultMarkdownSerializer`
so they match the tiptap names.
*Menubar*
* Specify args for isActive function directly rather than setting a function.
* Make use of the editor instance inside the MenuBar component.
* Use the editor rather than slots for command, focused etc.
* disable icons based on editor.can
* Show menubar as long as submenus are open.
When opening a submenu of the menubar
keep track of the open menu even for the image and the remaining action menu.
Also refocus the editor whenever a submenu is closed.
*MenuBubble*
Let tippy handle the positioning
Tippy is really good at positioning the menu bubble.
Remove all our workarounds and let it do its thing.
In order for this to work the content of the MenuBubble
actually needs to live inside the tippy-content.
Tippy bases its calculations on the width of tippy-content.
So if we have the content hanging in a separate div
with absolute positioning
tippy-content will be 0x0 px and not represent the actual width
of the menu bubble.
*Upgrade image node and ImageView.*
Quite a bit of the syntax changed.
We now need a wrapping `<node-view-wrapper>` element.
Pretty good docs at https://tiptap.dev/guide/node-views/vue#render-a-vue-component
We also need to handle the async action.
It will run the action on it's own.
So in `clickIcon()` we need to test if the action returned anything.
Tiptap v1 had inline images.
v2 keeps them outside of paragraphs by default.
Configure Image node to use inline images as markdownit creates inline images right now.
*Trailing Node*
Tiptap v2 does not ship the trailing node extension anymore.
Included the one from the demos and turned it from typescript into javascript.
*Tests*
In order to isolate some problems tests were added.
The tests in Undeline.spec.js were green right from the beginning.
They are not related to the fix and only helped isolate the problem.
Also introduced a cypress test for Lists
that tests the editor
without rendering the page and logging in.
It is very fast and fairly easy to write.
*Refactorings*
* Split marks into separate files.
Signed-off-by: Max <max@nextcloud.com>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Signed-off-by: Max <max@nextcloud.com>
|
|
* roll back parts of #1903 that broke it again.
* Calculate top of menububble based on scrollHeight of content-wrapper.
* Always display menububble below selected line.
This will make it less likely to conflict with the menubar
or mobile copy and paste toolbars.
* Add cypress tests for the workspace.
Signed-off-by: Azul <azul@riseup.net>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
|
|
Open the test.md file once and then check all the things.
Signed-off-by: Azul <azul@riseup.net>
|
|
Use the new session feature to create and reuse sessions:
https://docs.cypress.io/api/commands/session
The first time `login` with a given name is called
the steps described in the login function are performed
and cookies and localstorage are cached.
The next time `login` is called with the same name
cookies and localStorage are restored and used again.
This allows us to keep fast test runs
while still separating the tests more cleanly.
The old logout command was broken because of the way
we used `Cypress.Cookies.defaults({ preserve })` before:
Cypress runs all the `cy.*` commands during initialization
and builds a list of commands that are then executed during the tests.
However `Cypress.Cookies.defaults` is evaluated when preparing the list
not while performing the actual steps.
Signed-off-by: Azul <azul@riseup.net>
|
|
* Use `BASH_SOURCE` rather than `PWD` to retrieve `CYPRESS_DIR`
independently of where the script was called from.
* Ensure docker-compose is called inside the `CYPRESS_DIR`.
* Respect `CYPRESS_baseUrl` when set in environment.
* Check if server is already running at `CYPRESS_baseUrl`
before starting one with `docker-compose`
* Exit if the server does not start,
even if `docker-compose logs` also fails.
Signed-off-by: Azul <azul@riseup.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
The markup of the close icon has changed.
See https://github.com/nextcloud/viewer/commit/f7bcfd0464987d889c706f3e3514d3db3ab73907
for a similar fix to the viewer itself.
Signed-off-by: Azul <azul@riseup.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
cypress: use master branch of nextcloud server
|
|
The `bugfix/noid/initial-stte-cspv3` branch has been merged into master in
https://github.com/nextcloud/server/pull/22636 .
It does not exist anymore which will cause issues when trying to run the cypress tests.
Remove the `$BRANCH` environment variable from the docker-compose.yml.
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|
|
Signed-off-by: Julius Härtl <jus@bitgrid.net>
|