Opened 8 years ago

Last modified 8 years ago

#16658 confirmed Bug

Placeholder widget losses styling after switching to source mode.

Reported by: kkrzton Owned by:
Priority: Normal Milestone:
Component: General Version:
Keywords: Cc:

Description

Custom styles can be added to style placeholders, e.g:

{ name: 'Placeholder class', type: 'widget', widget: 'placeholder', attributes: { 'class': 'placeholder-class' } },

More on styles - http://docs.ckeditor.com/#!/guide/dev_styles.

While styles can be applied on a placeholder widget properly, switching to source mode removes classes/styling so it cannot be restored while switching back to WYSIWYG mode.

Expected result

The classes/styles are preserved while switching between Source/WYSIWYG mode.

Actual result

The classes/styles are removed while switching to Source mode.

Other details (browser, OS, CKEditor version, installed plugins)

The cause of the issue is the way placeholder widget is downcasted. It is downcasted to [[placeholder_name]] so there is no way to store additional attributes in the downcasted text/html.

Change History (1)

comment:1 Changed 8 years ago by kkrzton

Status: newconfirmed
Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy