1/* 2 * Copyright (C) 2019 The Android Open Source Project 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/* Dark theme, the default if none specified */ 18body, body.dark-theme { 19 --main-bg: black; 20 --main-fg: white; 21 --error-bg: #900000; /* dark red */ 22 --alert-bg: #927836; /* dark yellow */ 23 --info-bg: #007000; /* dark green */ 24 --modal-bg: #5f6368ea; /* Semi-transparent Google grey 500 */ 25 --modal-button-bg: #e8eaed; /* Google grey 200 */ 26 --modal-button-shadow: #444444; 27 --modal-button-fg: black; 28 --modal-button-border: black; 29 --modal-button-invalid-border: red; 30 --modal-button-highlight-bg: #f4cccc; /* light red */ 31 --bt-label-fg: green; 32 --bt-label-invalid-fg: red; 33 --bt-action-bg: transparent; 34 --custom-button-bg: #1c4587ff; /* blue */ 35 --button-fg: #e8eaed; /* Google grey 200 */ 36 --button-bg: transparent; 37 --button-disabled-fg: #9aa0a6; /* Google grey 500 */ 38 --button-pressed-border: #505050; 39 --button-pressed-bg: #303030; 40} 41/* End of dark theme */ 42 43/* Light theme */ 44body.light-theme { 45 --main-bg: #fafafa; 46 --main-fg: black; 47 --error-bg: #ea9da0; /* light red */ 48 --alert-bg: #f3ef9e; /* light yellow */ 49 --info-bg: #a5d5a5; /* light green */ 50 --modal-bg: #d9d9d9ea; /* Semi-transparent Google grey 200 */ 51 --modal-button-bg: #7b7b7b; /* Google grey 500 */ 52 --modal-button-shadow: #666666; 53 --modal-button-fg: #fafafa; 54 --modal-button-border: #c4c4c4; /* Google grey 300 */ 55 --modal-button-invalid-border: #c3413d; /*light red */ 56 --modal-button-highlight-bg: #a05555; /* dark red-ish */ 57 --bt-label-fg: green; 58 --bt-label-invalid-fg: #c3413d; /* light red */ 59 --bt-action-bg: transparent; 60 --custom-button-bg: #8fc3ea; /* light blue */ 61 --button-fg: #555555; /* Google grey 600 */ 62 --button-bg: transparent; 63 --button-disabled-fg: #c4c4c4; /* Google grey 300 */ 64 --button-pressed-border: #c4c4c4; /* Google grey 300 */ 65 --button-pressed-bg: #d9d9d9; /* Google grey 200 */ 66} 67/* End of light theme */ 68 69body { 70 background-color: var(--main-bg); 71 margin: 0; 72 touch-action: none; 73 overscroll-behavior: none; 74} 75 76#device-connection { 77 display: none; 78 max-height: 100vh; 79} 80 81@keyframes spin { 82 0% { transform: rotate(0deg); } 83 100% { transform: rotate(360deg); } 84} 85 86#loader { 87 border-left: 12px solid #4285F4; 88 border-top: 12px solid #34A853; 89 border-right: 12px solid #FBBC05; 90 border-bottom: 12px solid #EA4335; 91 border-radius: 50%; 92 width: 70px; 93 height: 70px; 94 animation: spin 1.2s linear infinite; 95 margin: 100px; 96} 97 98/* Top header row. */ 99 100#header { 101 height: 64px; 102 /* Items inside this use a row Flexbox.*/ 103 display: flex; 104 align-items: center; 105} 106 107#camera_off_btn { 108 display: none !important; 109} 110#record_video_btn { 111 display: none !important; 112} 113 114#error-message-div { 115 position: absolute; 116 top: 0; 117 left: 0; 118 width: 100%; 119 z-index: 999; 120 opacity: 0.97; 121} 122#error-message { 123 color: var(--main-fg); 124 font-family: 'Open Sans', sans-serif; 125 padding: 10px; 126 margin: 10px; 127 border-radius: 10px; 128} 129#error-message .close-btn { 130 float: right; 131 cursor: pointer; 132} 133#error-message.hidden { 134 display: none; 135} 136#error-message.info { 137 background-color: var(--info-bg); 138} 139#error-message.warning { 140 background-color: var(--alert-bg); 141} 142#error-message.error { 143 background-color: var(--error-bg); 144} 145/* Control panel buttons and device screen(s). */ 146 147#controls-and-displays { 148 height: 100%; 149 150 /* Items inside this use a row Flexbox.*/ 151 display: flex; 152} 153 154#controls-and-displays > div { 155 margin-left: 5px; 156 margin-right: 5px; 157} 158 159.modal { 160 /* Start out hidden, and use absolute positioning. */ 161 display: none; 162 position: absolute; 163 164 border-radius: 10px; 165 padding: 20px; 166 padding-top: 1px; 167 168 background-color: var(--modal-bg); 169 color: var(--main-fg); 170 font-family: 'Open Sans', sans-serif; 171} 172.modal-header { 173 cursor: move; 174 /* Items inside this use a row Flexbox.*/ 175 display: flex; 176 justify-content: space-between; 177} 178.modal-close { 179 color: var(--main-fg); 180 border: none; 181 outline: none; 182 background-color: transparent; 183} 184.modal-button, .modal-button-highlight { 185 background: var(--modal-button-bg) 186 border-radius: 10px; 187 box-shadow: 1px 1px var(--modal-button-shadow); 188 padding: 10px 20px; 189 color: var(--modal-button-fg); 190 display: inline-block; 191 font: normal bold 14px/1 "Open Sans", sans-serif; 192 text-align: center; 193} 194#bluetooth-wizard-mac:valid { 195 border: 2px solid var(--modal-button-border); 196} 197#bluetooth-wizard-mac:invalid { 198 border: 2px solid var(--modal-button-invalid-border); 199} 200#bluetooth-wizard-mac:invalid + span::before { 201 font-weight: bold; 202 content: 'X'; 203 color: var(--bt-label-invalid-fg); 204} 205#bluetooth-wizard-mac:valid + span::before { 206 font-weight: bold; 207 content: 'OK'; 208 color: var(--bt-label-fg); 209} 210.modal-button { 211 background: var(--modal-button-bg); 212} 213.modal-button-highlight { 214 background: var(--modal-button-highlight-bg); 215} 216#device-details-modal span { 217 white-space: pre; 218} 219#bluetooth-console-input { 220 width: 100%; 221} 222#bluetooth-console-cmd-label { 223 color: var(--main-fg); 224} 225.bluetooth-text, .bluetooth-text-bold, .bluetooth-text-field input { 226 font: normal 18px/1 "Open Sans", sans-serif; 227} 228.bluetooth-text, .bluetooth-text-bold { 229 color: var(--main-fg); 230} 231.bluetooth-text-bold { 232 font: bold; 233} 234.bluetooth-button { 235 text-align: center; 236} 237.bluetooth-drop-down select { 238 font: normal 18px/1 "Open Sans", sans-serif; 239 color: var(--modal-button-fg); 240 width: 500px; 241 margin: 5px; 242 rows: 10; 243 columns: 60; 244} 245.bluetooth-text-field input { 246 color: var(--modal-button-fg); 247 width: 500px; 248 margin: 5px; 249 rows: 10; 250 columns: 60; 251} 252.bluetooth-list-trash { 253 background: var(--bt-action-bg); 254 border: 0px; 255 color: var(--main-fg); 256} 257 258.location-text, .location-text-bold, .location-text-field input { 259 font: normal 18px/1 "Open Sans", sans-serif; 260} 261.location-text, .location-text-bold { 262 color: var(--main-fg); 263} 264.location-text-bold { 265 font: bold; 266} 267.location-button { 268 text-align: center; 269} 270 271.control-panel-column { 272 width: 50px; 273 /* Items inside this use a column Flexbox.*/ 274 display: flex; 275 flex-direction: column; 276 padding: 1px; 277} 278#control-panel-custom-buttons { 279 display: none; 280 /* Give the custom buttons column a blue background. */ 281 background-color: var(--custom-button-bg); 282 height: fit-content; 283 border-radius: 10px; 284} 285 286.control-panel-column button { 287 margin: 0px 1px 5px 1px; 288 height: 50px; 289 font-size: 32px; 290 291 color: var(--button-fg); 292 border: none; 293 border-radius: 10px; 294 outline: none; 295 background-color: var(--button-bg); 296} 297 298.control-panel-column button.modal-button-opened { 299 background-color: var(--modal-bg); 300} 301 302.control-panel-column button:disabled { 303 color: var(--button-disabled-fg); 304 cursor: not-allowed; 305} 306 307.control-panel-column button:enabled { 308 cursor: pointer; 309} 310 311.control-panel-column button:active { 312 margin: 0px 0px 5px 0px; 313 border: solid 1px var(--button-pressed-border); 314 background-color: var(--button-pressed-bg); 315} 316 317#device-displays { 318 /* Take up the remaining width of the window.*/ 319 flex-grow: 1; 320 /* Don't grow taller than the window.*/ 321 max-height: 100vh; 322 /* Allows child elements to be positioned relative to this element. */ 323 position: relative; 324 display: flex; 325 flex-direction: row; 326 /* Don't show an outline when using the keyboard */ 327 outline: 0px solid transparent; 328} 329 330/* 331 * Container <div> used to wrap each display's <video> element which is used for 332 * maintaining each display's width and height while the display is potentially 333 * rotating. 334 */ 335.device-display { 336 position: relative; 337 display: flex; 338 flex-direction: column; 339 flex-grow: 1; 340 margin: 10px; 341 visibility: hidden; 342} 343 344.device-video-container { 345 flex-grow: 1; 346 overflow: hidden; 347} 348 349/* Container <div> to show info about the individual display. */ 350.device-display-info { 351 color: var(--main-fg); 352 /* dark green */ 353 background-color: var(--info-bg); 354 font-family: 'Open Sans', sans-serif; 355 text-indent: 0px; 356 border-radius: 10px; 357 padding: 10px; 358 margin-bottom: 10px; 359 flex-grow: 0; 360 flex-shrink: 0; 361} 362 363/* The actual <video> element for each display. */ 364.device-display-video { 365 position: relative; 366 max-width: 100%; 367 max-height: 100%; 368 touch-action: none; 369} 370