Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(245)

Side by Side Diff: ui/keyboard/resources/main.css

Issue 216183005: Refactor CSS rules for the shift-key. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased on master. Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ui/keyboard/resources/elements/kb-shift-key.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 Copyright (c) 2013 The Chromium Authors. All rights reserved. 2 Copyright (c) 2013 The Chromium Authors. All rights reserved.
3 Use of this source code is governed by a BSD-style license that can be 3 Use of this source code is governed by a BSD-style license that can be
4 found in the LICENSE file. 4 found in the LICENSE file.
5 */ 5 */
6 6
7 @font-face { 7 @font-face {
8 font-family: roboto-bold; 8 font-family: roboto-bold;
9 src: url(roboto_bold.ttf); 9 src: url(roboto_bold.ttf);
10 } 10 }
11 11
12 /** 12 /**
13 * TODO(rsadam@): Remove all these rules once we switch to native 13 * TODO(rsadam@): Remove all these rules once we switch to native
14 * shadow dom. 14 * shadow dom.
15 */ 15 */
16 kb-keyboard.ctrl-active kb-modifier-key[char=Ctrl], 16 kb-keyboard.ctrl-active kb-modifier-key[char=Ctrl],
17 kb-keyboard.alt-active kb-modifier-key[char=Alt] { 17 kb-keyboard.alt-active kb-modifier-key[char=Alt] {
18 color: lightblue; 18 color: lightblue;
19 } 19 }
20 20
21 kb-keyboard[keyset="upper"] kb-shift-key.dark /shadow-deep/ .key { 21 kb-keyboard[keyset="upper"] kb-shift-key.dark /deep/ .key {
22 background-image: url('images/shift-filled.svg'); 22 background-image: url('images/shift-filled.svg');
23 } 23 }
24 24
25 kb-keyboard[keyset="lower"] kb-shift-key /shadow-deep/ .key { 25 kb-keyboard[keyset="lower"] kb-shift-key /deep/ .key{
26 background-image: url('images/shift.svg'); 26 background-image: url('images/shift.svg');
27 } 27 }
28 28
29 /** 29 /**
30 * Controls whether the shift key should be highlighted or not. 30 * Controls whether the shift key should be highlighted or not.
31 */ 31 */
32 kb-keyboard.caps-locked kb-shift-key.dark /shadow-deep/ 32 kb-keyboard.caps-locked kb-shift-key.dark /deep/
33 .shift-light { 33 .shift-light {
34 -webkit-box-shadow: 0 1px 1px rgba(213, 213, 213, 0.5), 34 -webkit-box-shadow: 0 1px 1px rgba(213, 213, 213, 0.5),
35 0 -1px 1px rgba(213, 213, 213, 0.5); 35 0 -1px 1px rgba(213, 213, 213, 0.5);
36 background-image: -webkit-linear-gradient(#d5d5d5, #d5d5d5); 36 background-image: -webkit-linear-gradient(#d5d5d5, #d5d5d5);
37 border: none; 37 border: none;
38 height: 0.2em; 38 height: 0.2em;
39 } 39 }
40 kb-keyboard.caps-locked kb-shift-key.dark /shadow-deep/ 40 kb-keyboard.caps-locked kb-shift-key.dark /deep/
41 .shift-light-wrapper { 41 .shift-light-wrapper {
42 bottom: 2px; 42 bottom: 2px;
43 } 43 }
44 44
45 kb-keyboard.ctrl-active kb-modifier-key[char=Ctrl], 45 kb-keyboard.ctrl-active kb-modifier-key[char=Ctrl],
46 kb-keyboard.ctrl-active kb-modifier-key[char=Ctrl] { 46 kb-keyboard.ctrl-active kb-modifier-key[char=Ctrl] {
47 color: lightblue; 47 color: lightblue;
48 } 48 }
49 49
50 /** TODO(rsadam@): Move these rules to kb-row once we uprev to latest Polymer.*/ 50 /** TODO(rsadam@): Move these rules to kb-row once we uprev to latest Polymer.*/
(...skipping 14 matching lines...) Expand all
65 } 65 }
66 66
67 kb-row:nth-child(n+3) kb-key:not(.dark):not(.active){ 67 kb-row:nth-child(n+3) kb-key:not(.dark):not(.active){
68 -webkit-box-shadow: inset 0px 1px #565656, inset 0px -1px #434343; 68 -webkit-box-shadow: inset 0px 1px #565656, inset 0px -1px #434343;
69 background-image: -webkit-linear-gradient(#484848, #474747); 69 background-image: -webkit-linear-gradient(#484848, #474747);
70 background-size: cover; 70 background-size: cover;
71 border-bottom-color: #393939; 71 border-bottom-color: #393939;
72 border-top-color: #717171; 72 border-top-color: #717171;
73 } 73 }
74 74
75 kb-row:nth-child(2) kb-key:not([invert]) /shadow-deep/ .hint { 75 kb-row:nth-child(2) kb-key:not([invert]) /deep/ .hint {
76 color: #2C2C2C; 76 color: #2C2C2C;
77 } 77 }
78 78
79 kb-row:nth-child(3) kb-key:not([invert]) /shadow-deep/ .hint { 79 kb-row:nth-child(3) kb-key:not([invert]) /deep/ .hint {
80 color: #272727; 80 color: #272727;
81 } 81 }
82 82
83 kb-row:nth-child(n+3) kb-key:not([invert]) /shadow-deep/ .hint { 83 kb-row:nth-child(n+3) kb-key:not([invert]) /deep/ .hint {
84 color: #232323; 84 color: #232323;
85 } 85 }
86 86
87 .dark { 87 .dark {
88 font-size: 70%; 88 font-size: 70%;
89 } 89 }
90 90
91 .dark:not(.active) { 91 .dark:not(.active) {
92 -webkit-box-shadow: inset 0px 1px #313131, inset 0px -1px #202020; 92 -webkit-box-shadow: inset 0px 1px #313131, inset 0px -1px #202020;
93 background-color: #222222; 93 background-color: #222222;
94 border-bottom-color: #1c1c1c; 94 border-bottom-color: #1c1c1c;
95 border-top-color: #4f4f4f; 95 border-top-color: #4f4f4f;
96 } 96 }
97 97
98 :not(kb-altkey-set) > .active { 98 :not(kb-altkey-set) > .active {
99 -webkit-box-shadow: inset 0px 1px #969696, inset 0px -1px #6f6f6f; 99 -webkit-box-shadow: inset 0px 1px #969696, inset 0px -1px #6f6f6f;
100 background-image: -webkit-linear-gradient(#8b8b8b, #7d7d7d); 100 background-image: -webkit-linear-gradient(#8b8b8b, #7d7d7d);
101 background-size: cover; 101 background-size: cover;
102 border-bottom-color: #5b5b5b; 102 border-bottom-color: #5b5b5b;
103 border-top-color: #a4a4a4; 103 border-top-color: #a4a4a4;
104 } 104 }
OLDNEW
« no previous file with comments | « ui/keyboard/resources/elements/kb-shift-key.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698