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

When autoClearEmptyLines: true, deleting the last line will crash & burn #458

Closed
izaak opened this issue Mar 21, 2012 · 0 comments
Closed

Comments

@izaak
Copy link

izaak commented Mar 21, 2012

Hey first of all great work, this editor is kind of amazing. I plan to get a proper implementation layer into Drupal's wysiwyg module. While playing around I've encountered the following bug-

When autoClearEmptyLines: true, putting the cursor anywhere on the last line of text and backspacing to the previous line will crash & burn. I've confirmed this with 2.22 and the latest git snapshot. .

Steps to reproduce:

  1. I presume mode doesn't matter, but I confirmed on the javascript and markdown demo pages. Set autoClearEmptyLines: true.
  2. Load an editor with at least a couple lines of text.
  3. Put the cursor anywhere on the last line (whether the last line is empty has no ramification).
  4. Backspace until the cursor has jumped up one line
  5. Crashy!
  6. Now try to move your cursor around with the mouse. I get the errors below:

Safari 5.1.3 (7534.53.10)
TypeError: 'undefined' is not an object (evaluating 'child.chunkSize')
codemirror.js:2597

Chrome 17.0.963.79
Uncaught TypeError: Cannot call method 'chunkSize' of undefined

Firefox 10.0.2
[23:44:32.569] child is undefined @ file:///Users/izaak/Downloads/marijnh-CodeMirror2-3d90a1b/lib/codemirror.js:2597

melloware added a commit to melloware/CodeMirror that referenced this issue May 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants