diff options
author | Eric Guzman | 2012-05-14 23:44:47 -0700 |
---|---|---|
committer | Eric Guzman | 2012-05-14 23:44:47 -0700 |
commit | d4ce8c2fe42fcbfc36cf4b20ef8de67c6471c241 (patch) | |
tree | 9698ed4cc633fc6ac84250ee2f342b5d3a6f8d97 /js/panels/css-panel/rule-list-container.reel/rule-list-container.js | |
parent | b3624fbd6ed9c03e1b5c889bf4757af2ff6ce96d (diff) | |
download | ninja-d4ce8c2fe42fcbfc36cf4b20ef8de67c6471c241.tar.gz |
CSSPanel - Add mutli-selection and adding classes to groups of elements
Diffstat (limited to 'js/panels/css-panel/rule-list-container.reel/rule-list-container.js')
-rw-r--r-- | js/panels/css-panel/rule-list-container.reel/rule-list-container.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/js/panels/css-panel/rule-list-container.reel/rule-list-container.js b/js/panels/css-panel/rule-list-container.reel/rule-list-container.js index 511ff24c..50d69093 100644 --- a/js/panels/css-panel/rule-list-container.reel/rule-list-container.js +++ b/js/panels/css-panel/rule-list-container.reel/rule-list-container.js | |||
@@ -98,7 +98,9 @@ exports.RuleListContainer = Montage.create(Component, { | |||
98 | value: function(selection) { | 98 | value: function(selection) { |
99 | var rules; | 99 | var rules; |
100 | 100 | ||
101 | if(selection.length === 1) { | 101 | if(selection.length > 1) { |
102 | rules = this.stylesController.getCommonRules(selection); | ||
103 | } else if(selection.length === 1) { | ||
102 | rules = this.stylesController.getMatchingRules(selection[0]); | 104 | rules = this.stylesController.getMatchingRules(selection[0]); |
103 | 105 | ||
104 | ///// Add inline style to rule list | 106 | ///// Add inline style to rule list |
@@ -109,7 +111,7 @@ exports.RuleListContainer = Montage.create(Component, { | |||
109 | style : selection[0].style | 111 | style : selection[0].style |
110 | }); | 112 | }); |
111 | 113 | ||
112 | } //// TODO: support more selection types | 114 | } |
113 | 115 | ||
114 | return rules; | 116 | return rules; |
115 | } | 117 | } |