blob: 80021d52ff716c61b7660f145bf3b41552256626 [file] [log] [blame]
Simon Hunt58894c82016-05-24 15:09:02 -07001/*
2 * Copyright 2016-present Open Networking Laboratory
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17/*
18 ONOS GUI -- Topology View (theme) -- CSS file
19 */
20
21/* --- Base SVG Layer --- */
22
Simon Huntf44d7262016-06-14 14:46:56 -070023#ov-topo svg {
Simon Hunta9761342016-06-10 18:02:53 -070024 background-color: #f4f4f4;
Simon Hunt58894c82016-05-24 15:09:02 -070025}
26
27/* --- "No Devices" Layer --- */
28
Simon Huntf44d7262016-06-14 14:46:56 -070029#ov-topo svg .noDevsBird {
Simon Hunta9761342016-06-10 18:02:53 -070030 fill: #db7773;
Simon Hunt58894c82016-05-24 15:09:02 -070031}
32
Simon Huntf44d7262016-06-14 14:46:56 -070033#ov-topo svg #topo-noDevsLayer text {
Simon Hunta9761342016-06-10 18:02:53 -070034 fill: #7e9aa8;
Simon Hunt58894c82016-05-24 15:09:02 -070035}
36
37/* --- Topo Map --- */
38
Simon Huntf44d7262016-06-14 14:46:56 -070039#ov-topo svg #topo-map {
Simon Hunta9761342016-06-10 18:02:53 -070040 stroke-width: 2px;
41 stroke: #f4f4f4;
42 fill: #e5e5e6;
Simon Hunt58894c82016-05-24 15:09:02 -070043}
44
45/* --- general topo-panel styling --- */
46
Simon Hunt8f907cc2016-06-15 18:04:01 -070047.topo-p svg {
48 background: #c0242b;
49}
50
Simon Huntf44d7262016-06-14 14:46:56 -070051.topo-p svg .glyph {
Simon Hunt8f907cc2016-06-15 18:04:01 -070052 fill: #ffffff;
Simon Hunt58894c82016-05-24 15:09:02 -070053}
54
Simon Huntf44d7262016-06-14 14:46:56 -070055.topo-p hr {
Simon Hunt8f907cc2016-06-15 18:04:01 -070056 background-color: #cccccc;
Simon Hunt58894c82016-05-24 15:09:02 -070057}
Simon Hunt58894c82016-05-24 15:09:02 -070058
Simon Hunt8f907cc2016-06-15 18:04:01 -070059#topo-p-detail svg {
60 background: none;
61}
62
63#topo-p-detail .header svg .glyph {
64 fill: #c0242b;
65}
66
Simon Huntc217cb92016-08-30 16:17:51 -070067#toolbar-topo-tbar .tbar-row.right {
68 color: #aaa;
69}
Simon Hunt8f907cc2016-06-15 18:04:01 -070070
Simon Hunt58894c82016-05-24 15:09:02 -070071/* --- Topo Instance Panel --- */
72
73#topo-p-instance svg rect {
Simon Hunta9761342016-06-10 18:02:53 -070074 stroke-width: 0;
Simon Hunta9761342016-06-10 18:02:53 -070075 fill: #fbfbfb;
Simon Hunt58894c82016-05-24 15:09:02 -070076}
77
Simon Huntf44d7262016-06-14 14:46:56 -070078/* body of an instance */
79#topo-p-instance .online svg rect {
80 opacity: 1;
81 fill: #fbfbfb;
82}
Simon Hunt58894c82016-05-24 15:09:02 -070083
84#topo-p-instance svg .glyph {
Simon Hunta9761342016-06-10 18:02:53 -070085 fill: #fff;
Simon Hunt58894c82016-05-24 15:09:02 -070086}
87#topo-p-instance .online svg .glyph {
Simon Hunta9761342016-06-10 18:02:53 -070088 fill: #fff;
Simon Hunt58894c82016-05-24 15:09:02 -070089}
90
91
Simon Hunta9761342016-06-10 18:02:53 -070092/* offline */
Simon Hunt58894c82016-05-24 15:09:02 -070093#topo-p-instance svg .badgeIcon {
Simon Hunt58894c82016-05-24 15:09:02 -070094 opacity: 0.4;
Simon Hunta9761342016-06-10 18:02:53 -070095 fill: #939598;
Simon Hunt58894c82016-05-24 15:09:02 -070096}
97
Simon Hunta9761342016-06-10 18:02:53 -070098/* online */
Simon Hunt58894c82016-05-24 15:09:02 -070099#topo-p-instance .online svg .badgeIcon {
100 opacity: 1.0;
Simon Hunta9761342016-06-10 18:02:53 -0700101 fill: #939598;
Simon Hunt58894c82016-05-24 15:09:02 -0700102}
Simon Huntf44d7262016-06-14 14:46:56 -0700103#topo-p-instance .online svg .badgeIcon.bird {
Simon Hunta9761342016-06-10 18:02:53 -0700104 fill: #ffffff;
105}
106
107#topo-p-instance svg .readyBadge {
108 visibility: hidden;
109}
110#topo-p-instance .ready svg .readyBadge {
111 visibility: visible;
Simon Hunt58894c82016-05-24 15:09:02 -0700112}
113
114#topo-p-instance svg text {
Simon Hunta9761342016-06-10 18:02:53 -0700115 text-anchor: left;
116 opacity: 0.5;
Simon Hunta9761342016-06-10 18:02:53 -0700117 fill: #3c3a3a;
Simon Hunt58894c82016-05-24 15:09:02 -0700118}
Simon Huntf44d7262016-06-14 14:46:56 -0700119
120#topo-p-instance .online svg text {
121 opacity: 1.0;
Simon Hunta9761342016-06-10 18:02:53 -0700122 fill: #3c3a3a;
Simon Hunt58894c82016-05-24 15:09:02 -0700123}
124
125#topo-p-instance .onosInst.mastership {
126 opacity: 0.3;
127}
128#topo-p-instance .onosInst.mastership.affinity {
129 opacity: 1.0;
130}
Simon Huntf44d7262016-06-14 14:46:56 -0700131#topo-p-instance .onosInst.mastership.affinity svg rect {
Simon Hunt58894c82016-05-24 15:09:02 -0700132 filter: url(#blue-glow);
133}
Simon Hunta9761342016-06-10 18:02:53 -0700134
Simon Huntf44d7262016-06-14 14:46:56 -0700135.firefox #topo-p-instance .onosInst.mastership.affinity svg rect {
Simon Hunt58894c82016-05-24 15:09:02 -0700136 filter: url("data:image/svg+xml;utf8, <svg xmlns = \'http://www.w3.org/2000/svg\'><filter x=\"-50%\" y=\"-50%\" width=\"200%\" height=\"200%\" id=\"blue-glow\"><feColorMatrix type=\"matrix\" values=\"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.7 0 0 0 1 0 \"></feColorMatrix><feGaussianBlur stdDeviation=\"3\" result=\"coloredBlur\"></feGaussianBlur><feMerge><feMergeNode in=\"coloredBlur\"></feMergeNode><feMergeNode in=\"SourceGraphic\"></feMergeNode></feMerge></filter></svg>#blue-glow");
137}
Simon Hunt58894c82016-05-24 15:09:02 -0700138
139/* --- Topo Nodes --- */
140
141#ov-topo svg .suppressed {
142 opacity: 0.5 !important;
143}
144
145#ov-topo svg .suppressedmax {
146 opacity: 0.2 !important;
147}
148
Simon Hunt58894c82016-05-24 15:09:02 -0700149/* Device Nodes */
150
Simon Huntf44d7262016-06-14 14:46:56 -0700151/* note: device without the 'online' class is offline */
Simon Hunt58894c82016-05-24 15:09:02 -0700152#ov-topo svg .node.device rect {
Simon Huntf44d7262016-06-14 14:46:56 -0700153 /* TODO: theme */
154 fill: #f0f0f0;
Simon Hunt58894c82016-05-24 15:09:02 -0700155}
Simon Hunt58894c82016-05-24 15:09:02 -0700156#ov-topo svg .node.device text {
Simon Huntf44d7262016-06-14 14:46:56 -0700157 /*TODO: theme*/
Simon Hunt58894c82016-05-24 15:09:02 -0700158 fill: #bbb;
Simon Hunt58894c82016-05-24 15:09:02 -0700159}
Simon Huntf44d7262016-06-14 14:46:56 -0700160#ov-topo svg .node.device use {
161 /*TODO: theme*/
Simon Hunte9062fc2016-12-22 11:40:06 -0800162 fill: #eee;
Simon Hunt58894c82016-05-24 15:09:02 -0700163}
Simon Huntf44d7262016-06-14 14:46:56 -0700164
165
166#ov-topo svg .node.device.online rect {
167 fill: #ffffff;
Simon Hunt58894c82016-05-24 15:09:02 -0700168}
Simon Huntf44d7262016-06-14 14:46:56 -0700169#ov-topo svg .node.device.online text {
170 fill: #3c3a3a;
Simon Hunt58894c82016-05-24 15:09:02 -0700171}
Simon Huntf44d7262016-06-14 14:46:56 -0700172#ov-topo svg .node.device.online use {
Simon Hunte9062fc2016-12-22 11:40:06 -0800173 fill: #fff;
Simon Hunt58894c82016-05-24 15:09:02 -0700174}
Simon Huntf44d7262016-06-14 14:46:56 -0700175
176
177#ov-topo svg .node.device.selected rect {
Simon Hunt4766dfb2016-06-14 17:16:22 -0700178 stroke-width: 2.0;
179 stroke: #009fdb;
Simon Hunt58894c82016-05-24 15:09:02 -0700180}
181
182/* Badges */
Simon Huntf44d7262016-06-14 14:46:56 -0700183/* (... works for bothand dark themes...) */
Simon Hunt58894c82016-05-24 15:09:02 -0700184#ov-topo svg .node .badge circle {
185 stroke: #aaa;
186}
187
188#ov-topo svg .node .badge.badgeInfo circle {
189 fill: #99d;
190}
191
192#ov-topo svg .node .badge.badgeWarn circle {
193 fill: #da2;
194}
195
196#ov-topo svg .node .badge.badgeError circle {
197 fill: #e44;
198}
199
200#ov-topo svg .node .badge use {
201 fill: white !important;
202}
203
204#ov-topo svg .node .badge.badgeInfo use {
205 fill: #448;
206}
207
208#ov-topo svg .node .badge text {
209 fill: white !important;
210}
211
212#ov-topo svg .node .badge.badgeInfo text {
213 fill: #448;
214}
215
216/* Host Nodes */
217
218#ov-topo svg .node.host {
219}
220
221#ov-topo svg .node.host text {
222 stroke: none;
223 font: 9pt sans-serif;
Simon Hunt58894c82016-05-24 15:09:02 -0700224 fill: #846;
225}
Simon Hunt58894c82016-05-24 15:09:02 -0700226
Simon Hunt4766dfb2016-06-14 17:16:22 -0700227#ov-topo svg .node.host circle {
Simon Huntf44d7262016-06-14 14:46:56 -0700228 stroke: #a3a596;
229 fill: #e0dfd6;
Simon Hunt58894c82016-05-24 15:09:02 -0700230}
Simon Hunta5487ad2016-06-16 13:10:41 -0700231#ov-topo svg .node.host.selected .hostIcon > circle {
Simon Hunt4766dfb2016-06-14 17:16:22 -0700232 stroke-width: 2.0;
233 stroke: #009fdb;
234}
Simon Hunt58894c82016-05-24 15:09:02 -0700235
Simon Hunt4766dfb2016-06-14 17:16:22 -0700236#ov-topo svg .node.host use {
237 fill: #3c3a3a;
Simon Hunt58894c82016-05-24 15:09:02 -0700238}
Simon Hunt58894c82016-05-24 15:09:02 -0700239
240/* --- Topo Links --- */
241
242#ov-topo svg .link {
243 opacity: .9;
244}
245
246#ov-topo svg .link.selected,
247#ov-topo svg .link.enhanced {
Simon Hunt4766dfb2016-06-14 17:16:22 -0700248 stroke-width: 3.5;
249 stroke: #009fdb;
Simon Hunt58894c82016-05-24 15:09:02 -0700250}
Simon Hunt58894c82016-05-24 15:09:02 -0700251
252#ov-topo svg .link.inactive {
253 opacity: .5;
254 stroke-dasharray: 8 4;
255}
Simon Hunta9761342016-06-10 18:02:53 -0700256/* TODO: Review for not-permitted links */
Simon Hunt58894c82016-05-24 15:09:02 -0700257#ov-topo svg .link.not-permitted {
258 stroke: rgb(255,0,0);
259 stroke-width: 5.0;
260 stroke-dasharray: 8 4;
261}
262
263#ov-topo svg .link.secondary {
264 stroke-width: 3px;
Simon Hunt58894c82016-05-24 15:09:02 -0700265 stroke: rgba(0,153,51,0.5);
266}
Simon Hunt58894c82016-05-24 15:09:02 -0700267
268/* Port traffic color visualization for Kbps, Mbps, and Gbps */
269
Simon Huntf44d7262016-06-14 14:46:56 -0700270#ov-topo svg .link.secondary.port-traffic-Kbps {
Simon Hunt58894c82016-05-24 15:09:02 -0700271 stroke: rgb(0,153,51);
272 stroke-width: 5.0;
273}
Simon Hunt58894c82016-05-24 15:09:02 -0700274
Simon Huntf44d7262016-06-14 14:46:56 -0700275#ov-topo svg .link.secondary.port-traffic-Mbps {
Simon Hunt58894c82016-05-24 15:09:02 -0700276 stroke: rgb(128,145,27);
277 stroke-width: 6.5;
278}
Simon Hunt58894c82016-05-24 15:09:02 -0700279
Simon Huntf44d7262016-06-14 14:46:56 -0700280#ov-topo svg .link.secondary.port-traffic-Gbps {
Simon Hunt58894c82016-05-24 15:09:02 -0700281 stroke: rgb(255, 137, 3);
282 stroke-width: 8.0;
283}
Simon Hunt58894c82016-05-24 15:09:02 -0700284
Simon Huntf44d7262016-06-14 14:46:56 -0700285#ov-topo svg .link.secondary.port-traffic-Gbps-choked {
Simon Hunt58894c82016-05-24 15:09:02 -0700286 stroke: rgb(183, 30, 21);
287 stroke-width: 8.0;
288}
Simon Hunt58894c82016-05-24 15:09:02 -0700289
290
291
292#ov-topo svg .link.animated {
293 stroke-dasharray: 8 5;
294 animation: ants 5s infinite linear;
Simon Hunt4766dfb2016-06-14 17:16:22 -0700295 /* below line could be added via Javascript, based on path, if we cared
296 * enough about the direction of ant-flow
297 */
Simon Hunt58894c82016-05-24 15:09:02 -0700298 /*animation-direction: reverse;*/
299}
300@keyframes ants {
301 from {
302 stroke-dashoffset: 0;
303 }
304 to {
305 stroke-dashoffset: 400;
306 }
307}
308
309#ov-topo svg .link.primary {
310 stroke-width: 4px;
Simon Hunt58894c82016-05-24 15:09:02 -0700311 stroke: #ffA300;
312}
Simon Hunt58894c82016-05-24 15:09:02 -0700313
314#ov-topo svg .link.secondary.optical {
315 stroke-width: 4px;
Simon Hunt58894c82016-05-24 15:09:02 -0700316 stroke: rgba(128,64,255,0.5);
317}
Simon Hunt58894c82016-05-24 15:09:02 -0700318
319#ov-topo svg .link.primary.optical {
320 stroke-width: 6px;
Simon Hunt58894c82016-05-24 15:09:02 -0700321 stroke: #74f;
322}
Simon Hunt58894c82016-05-24 15:09:02 -0700323
324/* Link Labels */
325#ov-topo svg .linkLabel rect {
326 stroke: none;
Simon Hunt4766dfb2016-06-14 17:16:22 -0700327 fill: #ffffff;
Simon Hunt58894c82016-05-24 15:09:02 -0700328}
Simon Hunt58894c82016-05-24 15:09:02 -0700329
Simon Huntf44d7262016-06-14 14:46:56 -0700330#ov-topo svg .linkLabel text {
Simon Hunt58894c82016-05-24 15:09:02 -0700331 fill: #444;
332}
Simon Hunt58894c82016-05-24 15:09:02 -0700333
334/* Port Labels */
335
336#ov-topo svg .portLabel rect {
Simon Hunt4766dfb2016-06-14 17:16:22 -0700337 stroke: #a3a596;
338 fill: #ffffff;
Simon Hunt58894c82016-05-24 15:09:02 -0700339}
Simon Hunt58894c82016-05-24 15:09:02 -0700340
Simon Huntf44d7262016-06-14 14:46:56 -0700341#ov-topo svg .portLabel text {
Simon Hunt58894c82016-05-24 15:09:02 -0700342 fill: #444;
343}
Simon Hunt58894c82016-05-24 15:09:02 -0700344
345/* Number of Links Labels */
346
347
Simon Huntf44d7262016-06-14 14:46:56 -0700348#ov-topo text.numLinkText {
Simon Hunt58894c82016-05-24 15:09:02 -0700349 fill: #444;
350}
Simon Hunt58894c82016-05-24 15:09:02 -0700351
352/* ------------------------------------------------- */
353/* Sprite Layer */
354
Simon Huntf44d7262016-06-14 14:46:56 -0700355#ov-topo svg #topo-sprites .gold1 use {
Simon Hunt58894c82016-05-24 15:09:02 -0700356 stroke: #fda;
357 fill: none;
358}
Simon Huntf44d7262016-06-14 14:46:56 -0700359#ov-topo svg #topo-sprites .gold1 text {
Simon Hunt58894c82016-05-24 15:09:02 -0700360 fill: #eda;
361}
Simon Hunt58894c82016-05-24 15:09:02 -0700362
Simon Huntf44d7262016-06-14 14:46:56 -0700363#ov-topo svg #topo-sprites .blue1 use {
Simon Hunt58894c82016-05-24 15:09:02 -0700364 stroke: #bbd;
365 fill: none;
366}
Simon Huntf44d7262016-06-14 14:46:56 -0700367#ov-topo svg #topo-sprites .blue1 text {
Simon Hunt58894c82016-05-24 15:09:02 -0700368 fill: #cce;
369}
Simon Hunt58894c82016-05-24 15:09:02 -0700370
Simon Huntf44d7262016-06-14 14:46:56 -0700371#ov-topo svg #topo-sprites .gray1 use {
Simon Hunt58894c82016-05-24 15:09:02 -0700372 stroke: #ccc;
373 fill: none;
374}
Simon Huntf44d7262016-06-14 14:46:56 -0700375#ov-topo svg #topo-sprites .gray1 text {
Simon Hunt58894c82016-05-24 15:09:02 -0700376 fill: #ddd;
377}
Simon Hunt58894c82016-05-24 15:09:02 -0700378
379/* fills */
Simon Huntf44d7262016-06-14 14:46:56 -0700380#ov-topo svg #topo-sprites use.fill-gray2 {
Simon Hunt58894c82016-05-24 15:09:02 -0700381 fill: #eee;
382}
Simon Hunt58894c82016-05-24 15:09:02 -0700383
Simon Huntf44d7262016-06-14 14:46:56 -0700384#ov-topo svg #topo-sprites use.fill-blue2 {
Simon Hunt58894c82016-05-24 15:09:02 -0700385 fill: #bce;
386}