Opened 7 years ago

#9486 new Bug

Using CKEDITOR.templates for stylesheets

Reported by: Piotrek Koszuliński Owned by:
Priority: Normal Milestone:
Component: General Version: 4.0
Keywords: Cc:

Description

In Moono skin we used CKEDITOR.templates to create content of CSS stylesheet. CSS uses '{' and it's also part of our wildcard, so we had to use trick to make it work.

There are couple of solutions:

  1. Escaping '{' by e.g. doubling. Note that escaping with '\' is not possible because it's also escape character in JS string.
  2. Specifying more precise regexp for template's wildcards, so e.g. only [a-zA-Z0-9]+ will be accepted.
  3. Changing wildcard format.

Solution first is ok, because it's backward compatible, but we will have to add more characters in our templates making them longer and less readable.

Third solution completely breaks backward compatibility so it's bad.

Second solution isn't fully backward compatible, but should work in 99% of cases (if we'll make good pattern) and it doesn't enlarge template and doesn't make it less readable.

Change History (0)

Note: See TracTickets for help on using tickets.
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy