Skip to content

Conversation

@AntoLC
Copy link
Collaborator

@AntoLC AntoLC commented Nov 27, 2024

Purpose

At the base, this code was made to solve this issue: #384

The link in the read mode was not clickable anymore, it was due to a attempt to not display the cursor of anonymous users.
We changes the way to do it by rendering our own cursor, when a user is anonymous we don't render the cursor.
By rendering our own cursor we fixed another problem, the cursor was flickering when the user was typing at the end of the line on the firefox browser.

About the Firefox flickering issue

https://github.com/TypeCellOS/BlockNote/blob/3ef72187c6c10fbc37891d922b4ed6421474482b/packages/core/src/editor/BlockNoteExtensions.ts#L261-L262

Initially:
https://github.com/yjs/y-prosemirror/blob/df4257b499bf25b2b8e69d56cc2d8bb790f8e7ba/src/plugins/cursor-plugin.js#L39

We are investigating the purpose of it, stayed tune !

Proposal

  • ♻️(frontend) add hooks useUploadFile
  • 🐛(frontend) use hook useTranslation
  • 🐛(frontend) link not clickable and flickering firefox

@AntoLC AntoLC added bug Something isn't working frontend Firefox labels Nov 27, 2024
@AntoLC AntoLC self-assigned this Nov 27, 2024
@AntoLC AntoLC force-pushed the issue/link-unclickable-read-mode branch 2 times, most recently from 60c222d to e97a476 Compare November 27, 2024 11:20
@AntoLC AntoLC linked an issue Nov 27, 2024 that may be closed by this pull request
Move upload file logic to hooks useUploadFile.
It will be more readable and easy to reuse.
Sentry highlitghted a few errors about the
function "t" not being defined. Better to get
it from the hook useTranslation.
@AntoLC AntoLC force-pushed the issue/link-unclickable-read-mode branch from e97a476 to 425ab97 Compare November 27, 2024 11:27
@AntoLC AntoLC force-pushed the issue/link-unclickable-read-mode branch from 425ab97 to edabb24 Compare November 27, 2024 11:48
@AntoLC AntoLC linked an issue Nov 27, 2024 that may be closed by this pull request
The link in the read mode was not clickable anymore,
it was due to a attempt to not display the cursor
of anonymous users.
We changes the way to do it by rendering our own cursor,
when a user is anonymous we don't render the cursor.
By rendering our own cursor we fixed another problem,
the cursor was flickering when the user was typing
at the end of the line on the firefox browser.
@AntoLC AntoLC force-pushed the issue/link-unclickable-read-mode branch from edabb24 to b214168 Compare November 27, 2024 14:44
A recent update to the workbox-webpack-plugin
package seems to introduce strange behavior.
Better to downgrade in waiting that it is more stable.
@AntoLC AntoLC mentioned this pull request Nov 27, 2024
@AntoLC AntoLC merged commit c94f26c into main Nov 27, 2024
15 of 16 checks passed
@AntoLC AntoLC deleted the issue/link-unclickable-read-mode branch November 27, 2024 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working Firefox frontend

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Page break created when on the same line and place cursor at the end 🐛 Unregistered users appear as agent on a public doc

2 participants