-
-
Notifications
You must be signed in to change notification settings - Fork 437
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: option to disable trailing block #679
feat: option to disable trailing block #679
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@Kashifwahaj is attempting to deploy a commit to the TypeCell Team on Vercel. A member of the Team first needs to authorize it. |
💵 To receive payouts, sign up on Algora, link your Github account and connect with Stripe/Alipay. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, thanks!
- can you make the default
true
? (inline with current behaviour) - can you also update the documentation where the other editor options are explained?
@@ -180,6 +182,8 @@ export class BlockNoteEditor< | |||
|
|||
public readonly uploadFile: ((file: File) => Promise<string>) | undefined; | |||
|
|||
public trailingBlock?: boolean = false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we remove this member, and just pass the option to getBlockNoteExtensions
on line 249, similar to the other options?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it's better and resulted in less code. Thanks! 👍
@@ -66,6 +66,8 @@ export class BlockNoteSchema< | |||
* A list of custom Styles that should be available in the editor. | |||
*/ | |||
styleSpecs?: SSpecs; | |||
|
|||
trailingNode?: boolean; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why is this added here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was necessary for the 'typescript' warning, but with getBlockNoteExtensions
, it's no longer needed, so I removed it in the new commits.
Got it, I will make the default value |
…should-be-configurable
…-traling-node-should-be-configurable
…' of https://github.com/Kashifwahaj/BlockNote into feat-TypeCellOS#631-traling-node-should-be-configurable
Please let me know if any change is needed. Thanks |
@YousefED Hi, Please Let me know if any improvement or changes required for this PR. |
Looks good, awesome! |
Thank you for this in the latest release :D |
So user need to pass
trailingBlock
boolean option to enable trailing Node./claim #631