Skip to content
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

Error: Cannot resolve a DOM node from Slate node: {"text":""} #7220

Closed
peterstory opened this issue May 30, 2024 · 5 comments
Closed

Error: Cannot resolve a DOM node from Slate node: {"text":""} #7220

peterstory opened this issue May 30, 2024 · 5 comments

Comments

@peterstory
Copy link

Describe the bug
I was creating a post in the markdown editor. I typed shift-return to create a line break instead of a paragraph.

To Reproduce
Type shift-return to create a line break instead of a paragraph. Then delete the line break, and create a paragraph break instead. Decap will crash.

Expected behavior

Screenshots

Applicable Versions:

  • Decap CMS version: decap-cms@3.1.2
  • Git provider: gitlab
  • Browser version: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.5 Safari/605.1.15

CMS configuration

backend:
  name: gitlab
  repo: trinityworc/trinityworc.gitlab.io
  branch: main
  auth_type: pkce
  app_id: 4cc4af5fcdddf53c7d6f6ff0d170153a999635dda84e2dbec80658b69a4e3618
media_folder: images/uploads
public_folder: /images/uploads
collections:
  - name: news
    label: News
    folder: _posts
    create: true
    slug: "{{year}}-{{month}}-{{day}}-{{slug}}"
    fields:
      - label: Layout
        name: layout
        widget: hidden
        default: post
      - label: Title
        name: title
        widget: string
      - label: Body
        name: body
        widget: markdown
      - label: Date
        name: date
        widget: datetime
    publish: true
    type: folder_based_collection
    sortable_fields:
      - commit_date
      - title
      - date
      - commit_author
    view_filters: []
    view_groups: []
  - name: about
    label: About
    folder: _about
    fields:
      - label: Title
        name: title
        widget: string
      - label: Anchor
        name: anchor
        widget: hidden
      - label: Image
        name: image
        widget: image
      - label: Image Alt Text
        name: image_alt
        widget: string
      - label: Body
        name: body
        widget: markdown
    publish: true
    type: folder_based_collection
    sortable_fields:
      - commit_date
      - title
      - commit_author
    view_filters: []
    view_groups: []
  - name: staff
    label: Staff
    folder: _staff
    fields:
      - label: Name
        name: name
        widget: string
      - label: Title
        name: title
        widget: string
      - label: Email
        name: email
        widget: string
      - label: Phone
        name: phone
        widget: string
      - label: Image
        name: image
        widget: image
      - label: Website
        name: website
        widget: string
    publish: true
    type: folder_based_collection
    sortable_fields:
      - commit_date
      - name
      - name
    view_filters: []
    view_groups: []
publish_mode: simple
slug:
  encoding: unicode
  clean_accents: false
  sanitize_replacement: "-"
isFetching: false
error: null

Additional context

@mohab-sameh
Copy link

Similar to what happened with me in #7218. Consistently reproducible and a complete blocker issue.

@LHSnow
Copy link

LHSnow commented Jun 3, 2024

Also similar to #7123

@martinjagodic
Copy link
Member

Closing as duplicate of #7152

@martinjagodic martinjagodic closed this as not planned Won't fix, can't repro, duplicate, stale Aug 5, 2024
@demshy
Copy link
Member

demshy commented Aug 7, 2024

@peterstory do you mind checking if the crash still happens in 3.2.1?

@peterstory
Copy link
Author

@demshy With 3.2.1, I don't have any issues. Thank you for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants