-
Notifications
You must be signed in to change notification settings - Fork 32
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
block node and createEditor
#173
base: main
Are you sure you want to change the base?
Conversation
- updated demo to have legacy editor creation and next - parameterize store for comments plugins in footnote
@@ -118,7 +125,23 @@ function CodeActions(props: ActionProps) { | |||
|
|||
if (!editorState || !node || pos == null) return null; | |||
|
|||
const onDelete = () => dispatch(deleteNode(stateId, viewId, { node, pos })); | |||
const onDelete = () => { | |||
const foundParentFigureResult = findParentNodeOfTypeClosestToPos( |
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.
Fixes an issue where delete code actions does not delete the figure wrapped around it
@@ -19,6 +20,23 @@ export const initialState: EditorsState = { | |||
// eslint-disable-next-line @typescript-eslint/default-param-last | |||
const editorReducer = (state = initialState, action: EditorActionTypes): EditorsState => { | |||
switch (action.type) { | |||
case REGISTER_EDITOR_STATE: { |
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.
Make it so that we can directly register editor state using the state object. The future goal is not having editor state in redux at all
article
schema preset that uses a block node as the top level node