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

Reapplying active font size/family with collapsed selection adds nested spans with same styling #1306

Closed
f1ames opened this issue Dec 1, 2017 · 1 comment · Fixed by #3375
Labels
plugin:font The plugin which probably causes the issue. regression This issue is a regression. status:confirmed An issue confirmed by the development team. type:bug A bug.

Comments

@f1ames
Copy link
Contributor

f1ames commented Dec 1, 2017

Are you reporting a feature request or a bug?

Bug

Provide detailed reproduction steps (if any)

  1. Go to e.g. /tests/plugins/font/manual/preservestyle (can be performed in any editor instance with font plugin).
  2. Add text foo bar.
  3. Select whole text.
  4. Apply some font size (e.g. 24).
  5. Put collapsed selection inside styled text.
  6. Apply same font size few times.

Expected result

Font keeps its size. Additional HTML elements are not added.

Actual result

Font keep its size. However, additional nested spans are added and if you start to type you end up with something like <p><span style="font-size:24px">Hel<span style="font-size:24px"><span style="font-size:24px"><span style="font-size:24px"><span style="font-size:24px">foo</span></span></span></span>lo</span> world</p>.

As we updated the logic of dropdown (Default value), previously reapplying the same style just removed it. So it is regression in a sense that it got broken not that it does not work like before.

Other details

  • Browser: All (checked on Chrome, FF)
  • OS: All
  • CKEditor version: 4.8.0
  • Installed CKEditor plugins: font
@f1ames f1ames added plugin:font The plugin which probably causes the issue. regression This issue is a regression. status:confirmed An issue confirmed by the development team. type:bug A bug. labels Dec 1, 2017
@f1ames
Copy link
Contributor Author

f1ames commented Dec 1, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
plugin:font The plugin which probably causes the issue. regression This issue is a regression. status:confirmed An issue confirmed by the development team. type:bug A bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants