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 on triple nested list <ol> or <ul> objects: Cannot read properties of null (reading 'querySelector') #4818

Open
wvddrss opened this issue Sep 12, 2024 · 3 comments

Comments

@wvddrss
Copy link

wvddrss commented Sep 12, 2024

Expected behavior.

It should not throw an error which causes the froala editor to freeze and no options are available.

Actual behavior.

It throws an error and causes the froala editor to freeze and no options are available.

Error:

Uncaught TypeError: Cannot read properties of null (reading 'querySelector')
    at s (froala_editor.pkgd.min.js:7:25822)
    at r (froala_editor.pkgd.min.js:7:26299)
    at Object.g [as lists] (froala_editor.pkgd.min.js:7:26303)
    at h (froala_editor.pkgd.min.js:7:130299)
    at Object.L [as set] (froala_editor.pkgd.min.js:7:135815)
    at n (froala_editor.pkgd.min.js:7:523930)
    at Object.E [as toggle] (froala_editor.pkgd.min.js:7:524314)
    at w.Bootstrap.callback (froala_editor.pkgd.min.js:7:525236)
    at Object.n [as exec] (froala_editor.pkgd.min.js:7:44720)
    at c (froala_editor.pkgd.min.js:7:221305)
s @ froala_editor.pkgd.min.js:7
r @ froala_editor.pkgd.min.js:7
g @ froala_editor.pkgd.min.js:7
h @ froala_editor.pkgd.min.js:7
L @ froala_editor.pkgd.min.js:7
n @ froala_editor.pkgd.min.js:7
E @ froala_editor.pkgd.min.js:7
callback @ froala_editor.pkgd.min.js:7
n @ froala_editor.pkgd.min.js:7
c @ froala_editor.pkgd.min.js:7
a @ froala_editor.pkgd.min.js:7
t @ froala_editor.pkgd.min.js:7
d @ froala_editor.pkgd.min.js:7
a @ froala_editor.pkgd.min.js:7
(anonymous) @ froala_editor.pkgd.min.js:7
(anonymous) @ froala_editor.pkgd.min.js:7
Steps to reproduce the problem.

paste following html in editor:

<ol>
	<ol>
		<ol>
			<li><span>item 1</span></li>
			<li><span>item 2</span></li>
		</ol>
           </ol>
</ol>
Editor version.

4.2.1 + 4.2.2

OS.

macOS 14.5 (23F79)

Browser.

Chrome Version 128.0.6613.120

Recording.
Screen.Recording.2024-09-12.at.16.44.23.mov
@brambilliet
Copy link

How do I give this bug a thumbs up? Asking for a frustrated friend...

@ItaloLeandro02
Copy link

Froala 4.2.1 does not have this issue.

@coreequip
Copy link

This bug still present in v4.3.0.

Steps to reproduce:

  • Just start a (un)ordered list
  • press TAB two times

It will end up in a 3rd level list item and the editor is throwing the mentioned exception.

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

4 participants