diff options
Diffstat (limited to 'js/panels/css-panel/style-shorthand.reel')
3 files changed, 275 insertions, 0 deletions
diff --git a/js/panels/css-panel/style-shorthand.reel/style-shorthand.css b/js/panels/css-panel/style-shorthand.reel/style-shorthand.css new file mode 100644 index 00000000..52f5a3c1 --- /dev/null +++ b/js/panels/css-panel/style-shorthand.reel/style-shorthand.css | |||
@@ -0,0 +1,43 @@ | |||
1 | /* <copyright> | ||
2 | This file contains proprietary software owned by Motorola Mobility, Inc.<br/> | ||
3 | No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder.<br/> | ||
4 | (c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved. | ||
5 | </copyright> */ | ||
6 | |||
7 | .css-tree-branch { | ||
8 | /*padding-left: 10px;*/ | ||
9 | } | ||
10 | .style-item { | ||
11 | padding-left: 20px; | ||
12 | } | ||
13 | .css-tree-branch .css-tree-branch { | ||
14 | padding-left: 20px; | ||
15 | margin-top: 0; | ||
16 | margin-bottom: 0; | ||
17 | overflow: hidden; | ||
18 | } | ||
19 | .style-shorthand-branch > div { | ||
20 | background-color: #fafafa; | ||
21 | border-bottom: 1px solid #ededed; | ||
22 | position: relative; | ||
23 | } | ||
24 | .style-shorthand-branch > div:hover { | ||
25 | background-color: #f1f1f1; | ||
26 | border-bottom: 1px solid #e1e1e1; | ||
27 | position: relative; | ||
28 | } | ||
29 | .style-shorthand-branch > div:hover:after { | ||
30 | opacity: 1; | ||
31 | } | ||
32 | .style-shorthand-branch > div:after { | ||
33 | background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAJCAYAAAD%2BWDajAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyRpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw%2FeHBhY2tldCBiZWdpbj0i77u%2FIiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8%2BIDx4OnhtcG1ldGEgeG1sbn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DVC6jxILADyL8Dl4SCKWg0A8P%2F%2F%2F%2FhGOitFch8JjSHxCFzAAIMACCjLJNKELwVAAAAAElFTkSuQmCC); | ||
34 | background-repeat: no-repeat; | ||
35 | content: "\00a0"; | ||
36 | height: 10px; | ||
37 | position: absolute; | ||
38 | right: 8px; | ||
39 | top: 4px; | ||
40 | width: 10px; | ||
41 | opacity: .3; | ||
42 | } | ||
43 | |||
diff --git a/js/panels/css-panel/style-shorthand.reel/style-shorthand.html b/js/panels/css-panel/style-shorthand.reel/style-shorthand.html new file mode 100644 index 00000000..243d9cc7 --- /dev/null +++ b/js/panels/css-panel/style-shorthand.reel/style-shorthand.html | |||
@@ -0,0 +1,174 @@ | |||
1 | <!DOCTYPE html> | ||
2 | <!-- <copyright> | ||
3 | This file contains proprietary software owned by Motorola Mobility, Inc.<br/> | ||
4 | No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder.<br/> | ||
5 | (c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved. | ||
6 | </copyright> --> | ||
7 | <html lang="en"> | ||
8 | <head> | ||
9 | <meta http-equiv="content-type" content="text/html; charset=utf-8" /> | ||
10 | <link href="style-shorthand.css" rel="stylesheet" type="text/css" /> | ||
11 | <script type="text/montage-serialization"> | ||
12 | { | ||
13 | "owner": { | ||
14 | "module" : "js/panels/css-panel/style-shorthand.reel", | ||
15 | "name" : "StyleShorthand", | ||
16 | "properties" : { | ||
17 | "element" : {"#" : "branch"}, | ||
18 | "label" : { "@" : "textComponent" }, | ||
19 | "branchList": {"#" : "branchList"}, | ||
20 | "arrayController": {"@": "arrayController" }, | ||
21 | "repetition": {"@": "repetition"}, | ||
22 | "leafComponent": {"@": "leaf"}, | ||
23 | "branchComponent": {"@": "branch"}, | ||
24 | "branchCollapser": {"#": "collapser" } | ||
25 | } | ||
26 | }, | ||
27 | |||
28 | "property": { | ||
29 | "module": "montage/ui/dynamic-text.reel", | ||
30 | "name": "DynamicText", | ||
31 | "properties": { | ||
32 | "element": {"#": "property"} | ||
33 | }, | ||
34 | "bindings": { | ||
35 | "value" : { | ||
36 | "boundObject": {"@": "owner"}, | ||
37 | "boundObjectPropertyPath": "propertyText", | ||
38 | "oneway": true | ||
39 | } | ||
40 | } | ||
41 | }, | ||
42 | "value": { | ||
43 | "module": "montage/ui/dynamic-text.reel", | ||
44 | "name": "DynamicText", | ||
45 | "properties": { | ||
46 | "element": {"#": "value"} | ||
47 | }, | ||
48 | "bindings": { | ||
49 | "value" : { | ||
50 | "boundObject": {"@": "owner"}, | ||
51 | "boundObjectPropertyPath": "valueText", | ||
52 | "oneway": true | ||
53 | } | ||
54 | } | ||
55 | }, | ||
56 | |||
57 | "arrayController": { | ||
58 | "module": "montage/ui/controller/array-controller", | ||
59 | "name": "ArrayController", | ||
60 | "bindings": { | ||
61 | "content": { | ||
62 | "boundObject": {"@": "owner"}, | ||
63 | "boundObjectPropertyPath": "childNodes" | ||
64 | } | ||
65 | } | ||
66 | }, | ||
67 | |||
68 | "style": { | ||
69 | "module": "js/panels/css-panel/style.reel", | ||
70 | "name": "Style", | ||
71 | "bindings": { | ||
72 | "sourceObject": { | ||
73 | "boundObject": {"@": "repetition" }, | ||
74 | "boundObjectPropertyPath": "objectAtCurrentIteration", | ||
75 | "oneway": true | ||
76 | }, | ||
77 | "labelKey" : { | ||
78 | "boundObject": {"@": "owner" }, | ||
79 | "boundObjectPropertyPath": "labelKey", | ||
80 | "oneway": true | ||
81 | }, | ||
82 | "branchKey" : { | ||
83 | "boundObject": {"@": "owner" }, | ||
84 | "boundObjectPropertyPath": "branchKey", | ||
85 | "oneway": true | ||
86 | }, | ||
87 | "treeView" : { | ||
88 | "boundObject": {"@": "owner" }, | ||
89 | "boundObjectPropertyPath": "treeView", | ||
90 | "oneway": true | ||
91 | } | ||
92 | } | ||
93 | }, | ||
94 | |||
95 | "shorthand": { | ||
96 | "module": "js/panels/css-panel/style-shorthand.reel", | ||
97 | "name": "StyleShorthand", | ||
98 | "bindings": { | ||
99 | "sourceObject": { | ||
100 | "boundObject": {"@": "repetition" }, | ||
101 | "boundObjectPropertyPath": "objectAtCurrentIteration", | ||
102 | "oneway": true | ||
103 | }, | ||
104 | "labelKey" : { | ||
105 | "boundObject": {"@": "owner" }, | ||
106 | "boundObjectPropertyPath": "labelKey", | ||
107 | "oneway": true | ||
108 | }, | ||
109 | "branchKey" : { | ||
110 | "boundObject": {"@": "owner" }, | ||
111 | "boundObjectPropertyPath": "branchKey", | ||
112 | "oneway": true | ||
113 | }, | ||
114 | "treeView" : { | ||
115 | "boundObject": {"@": "owner" }, | ||
116 | "boundObjectPropertyPath": "treeView", | ||
117 | "oneway": true | ||
118 | } | ||
119 | } | ||
120 | }, | ||
121 | |||
122 | "repetition": { | ||
123 | "module": "montage/ui/repetition.reel", | ||
124 | "name": "Repetition", | ||
125 | "properties": { | ||
126 | "element": { "#": "branchList" }, | ||
127 | "contentController": {"@": "arrayController" }, | ||
128 | "selectionEnabled": true | ||
129 | } | ||
130 | }, | ||
131 | |||
132 | "substitution": { | ||
133 | "module": "montage/ui/substitution.reel", | ||
134 | "name": "Substitution", | ||
135 | "properties": { | ||
136 | "element": {"#": "treeItem"}, | ||
137 | "switchComponents": { | ||
138 | "leaf": {"@": "style"}, | ||
139 | "branch": {"@": "shorthand"} | ||
140 | |||
141 | } | ||
142 | }, | ||
143 | "bindings": { | ||
144 | "switchValue": { | ||
145 | "boundObject": {"@": "repetition"}, | ||
146 | "boundObjectPropertyPath": "objectAtCurrentIteration.treeNodeType", | ||
147 | "oneway": true | ||
148 | } | ||
149 | } | ||
150 | }, | ||
151 | |||
152 | "collapser" : { | ||
153 | "module": "js/panels/collapse-composer", | ||
154 | "name": "CollapseComposer", | ||
155 | "properties" : { | ||
156 | "element": {"#":"collapser"}, | ||
157 | "component": {"@": "repetition"} | ||
158 | } | ||
159 | } | ||