fix(LinkBubble): Don't open bubble at initialization and on remote changes#5924
Merged
juliusknorr merged 7 commits intomainfrom Jun 25, 2024
Merged
fix(LinkBubble): Don't open bubble at initialization and on remote changes#5924juliusknorr merged 7 commits intomainfrom
juliusknorr merged 7 commits intomainfrom
Conversation
Member
Author
|
/backport to stable29 |
8212160 to
8b413f9
Compare
Fixes: #5855 Fixes: nextcloud/collectives#1296 Signed-off-by: Jonas <jonas@freesources.org>
a837f07 to
337b9dc
Compare
Signed-off-by: Jonas <jonas@freesources.org>
Undo button should be disabled after initial content got loaded and only get enabled after typing something. Signed-off-by: Jonas <jonas@freesources.org>
Hide was called with a timeout of 100ms, while update was not. This could lead to a race condition and flaky link bubble behaviour. Signed-off-by: Jonas <jonas@freesources.org>
337b9dc to
a6e80a4
Compare
`active` object from prosemirror state and oldState are never similar anyway. Signed-off-by: Jonas <jonas@freesources.org>
Signed-off-by: Jonas <jonas@freesources.org>
a6e80a4 to
a2f9f65
Compare
3 tasks
Should make the workspace link bubble test less flaky. Signed-off-by: Jonas <jonas@freesources.org>
max-nextcloud
approved these changes
Jun 25, 2024
Collaborator
max-nextcloud
left a comment
There was a problem hiding this comment.
Looks good to me.
|
|
||
| appendTransaction: (transactions, oldState, state) => { | ||
| // Don't open bubble at editor initialisation | ||
| if (oldState?.doc.content.size === 2) { |
Collaborator
There was a problem hiding this comment.
This will also be in effect if you paste into an empty document. I can't think of any case where that's a problem. Just wanted to mention.
Collaborator
There was a problem hiding this comment.
Uuhh... what if you insert a link via the link picker on an empty document. Actually would be nice if that behaved exactly as in a doc that already contains some characters. Not so important - but still a bit inconsistent.
Oh... doesn't the initial load happen through the ydoc? That would be caught by the other conditions later on - wouldn't it?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes: #5855
Fixes: nextcloud/collectives#1296
🏁 Checklist
npm run lint/npm run stylelint/composer run cs:check)