Skip to content

Commit

Permalink
Merge pull request #9694 from ckeditor/internal/718
Browse files Browse the repository at this point in the history
Feature (engine): Improved engine view matcher with new pattern syntax allowing to match attribute keys using regular expressions. Unified pattern syntax between attributes, styles, and classes. Closes #9872.

Feature (engine): Added special `expand` option to `StylesMap.getStyleNames()` and view `Element.getStyleNames()` methods allowing to expand shorthand style properties.
  • Loading branch information
jacekbogdanski authored Jun 14, 2021
2 parents 5fe253a + ea439f1 commit 22fad3d
Show file tree
Hide file tree
Showing 7 changed files with 920 additions and 119 deletions.
5 changes: 3 additions & 2 deletions packages/ckeditor5-engine/src/view/element.js
Original file line number Diff line number Diff line change
Expand Up @@ -468,10 +468,11 @@ export default class Element extends Node {
/**
* Returns iterator that contains all style names.
*
* @param {Boolean} [expand=false] Expand shorthand style properties and return all equivalent style representations.
* @returns {Iterable.<String>}
*/
getStyleNames() {
return this._styles.getStyleNames();
getStyleNames( expand = false ) {
return this._styles.getStyleNames( expand );
}

/**
Expand Down
Loading

0 comments on commit 22fad3d

Please sign in to comment.