| OLD | NEW |
| 1 /* | 1 /* |
| 2 Copyright (c) 2015 The Polymer Project Authors. All rights reserved. | 2 Copyright (c) 2015 The Polymer Project Authors. All rights reserved. |
| 3 This code may only be used under the BSD style license found at http://polymer.g
ithub.io/LICENSE.txt | 3 This code may only be used under the BSD style license found at http://polymer.g
ithub.io/LICENSE.txt |
| 4 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt | 4 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt |
| 5 The complete set of contributors may be found at http://polymer.github.io/CONTRI
BUTORS.txt | 5 The complete set of contributors may be found at http://polymer.github.io/CONTRI
BUTORS.txt |
| 6 Code distributed by Google as part of the polymer project is also | 6 Code distributed by Google as part of the polymer project is also |
| 7 subject to an additional IP rights grant found at http://polymer.github.io/PATEN
TS.txt | 7 subject to an additional IP rights grant found at http://polymer.github.io/PATEN
TS.txt |
| 8 */ | 8 */ |
| 9 | 9 |
| 10 :host { | 10 :host { |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 transform: translateZ(0); | 30 transform: translateZ(0); |
| 31 vertical-align: middle; | 31 vertical-align: middle; |
| 32 } | 32 } |
| 33 | 33 |
| 34 :host #ink { | 34 :host #ink { |
| 35 position: absolute; | 35 position: absolute; |
| 36 top: -15px; | 36 top: -15px; |
| 37 left: -15px; | 37 left: -15px; |
| 38 width: 48px; | 38 width: 48px; |
| 39 height: 48px; | 39 height: 48px; |
| 40 color: var(--paper-checkbox-unchecked-ink-color); | 40 color: var(--paper-checkbox-unchecked-ink-color, --primary-text-color); |
| 41 opacity: 0.6; | 41 opacity: 0.6; |
| 42 } | 42 } |
| 43 | 43 |
| 44 :host #ink[checked] { | 44 :host #ink[checked] { |
| 45 color: var(--paper-checkbox-checked-ink-color); | 45 color: var(--paper-checkbox-checked-ink-color, --default-primary-color); |
| 46 } | 46 } |
| 47 | 47 |
| 48 :host #checkbox { | 48 :host #checkbox { |
| 49 position: relative; | 49 position: relative; |
| 50 box-sizing: border-box; | 50 box-sizing: border-box; |
| 51 height: 100%; | 51 height: 100%; |
| 52 border: solid 2px; | 52 border: solid 2px; |
| 53 border-color: var(--paper-checkbox-unchecked-color); | 53 border-color: var(--paper-checkbox-unchecked-color, --primary-text-color); |
| 54 border-radius: 2px; | 54 border-radius: 2px; |
| 55 pointer-events: none; | 55 pointer-events: none; |
| 56 -webkit-transition: background-color 140ms, border-color 140ms; | 56 -webkit-transition: background-color 140ms, border-color 140ms; |
| 57 transition: background-color 140ms, border-color 140ms; | 57 transition: background-color 140ms, border-color 140ms; |
| 58 } | 58 } |
| 59 | 59 |
| 60 /* checkbox checked animations */ | 60 /* checkbox checked animations */ |
| 61 #checkbox.checked #checkmark { | 61 #checkbox.checked #checkmark { |
| 62 -webkit-animation: checkmark-expand 140ms ease-out forwards; | 62 -webkit-animation: checkmark-expand 140ms ease-out forwards; |
| 63 animation: checkmark-expand 140ms ease-out forwards; | 63 animation: checkmark-expand 140ms ease-out forwards; |
| (...skipping 23 matching lines...) Expand all Loading... |
| 87 } | 87 } |
| 88 100% { | 88 100% { |
| 89 top: -1px; | 89 top: -1px; |
| 90 left: 4px; | 90 left: 4px; |
| 91 width: 5px; | 91 width: 5px; |
| 92 height: 10px; | 92 height: 10px; |
| 93 } | 93 } |
| 94 } | 94 } |
| 95 | 95 |
| 96 :host #checkbox.checked { | 96 :host #checkbox.checked { |
| 97 background-color: var(--paper-checkbox-checked-color); | 97 background-color: var(--paper-checkbox-checked-color, --default-primary-color)
; |
| 98 border-color: var(--paper-checkbox-checked-color); | 98 border-color: var(--paper-checkbox-checked-color, --default-primary-color); |
| 99 } | 99 } |
| 100 | 100 |
| 101 :host #checkmark { | 101 :host #checkmark { |
| 102 -webkit-transform: rotate(45deg); | 102 -webkit-transform: rotate(45deg); |
| 103 transform: rotate(45deg); | 103 transform: rotate(45deg); |
| 104 position: absolute; | 104 position: absolute; |
| 105 top: -1px; | 105 top: -1px; |
| 106 left: 4px; | 106 left: 4px; |
| 107 width: 5px; | 107 width: 5px; |
| 108 height: 10px; | 108 height: 10px; |
| 109 border-style: solid; | 109 border-style: solid; |
| 110 border-top: none; | 110 border-top: none; |
| 111 border-left: none; | 111 border-left: none; |
| 112 border-right-width: 2px; | 112 border-right-width: 2px; |
| 113 border-bottom-width: 2px; | 113 border-bottom-width: 2px; |
| 114 border-color: white; | 114 border-color: white; |
| 115 } | 115 } |
| 116 | 116 |
| 117 /* label */ | 117 /* label */ |
| 118 #checkboxLabel { | 118 #checkboxLabel { |
| 119 position: relative; | 119 position: relative; |
| 120 display: inline-block; | 120 display: inline-block; |
| 121 vertical-align: middle; | 121 vertical-align: middle; |
| 122 padding-left: 8px; | 122 padding-left: 8px; |
| 123 white-space: normal; | 123 white-space: normal; |
| 124 pointer-events: none; | 124 pointer-events: none; |
| 125 color: var(--paper-checkbox-label-color); | 125 color: var(--paper-checkbox-label-color, --primary-text-color); |
| 126 } | 126 } |
| 127 | 127 |
| 128 #checkboxLabel[hidden] { | 128 #checkboxLabel[hidden] { |
| 129 display: none; | 129 display: none; |
| 130 } | 130 } |
| 131 | 131 |
| 132 /* disabled state */ | 132 /* disabled state */ |
| 133 :host([disabled]) { | 133 :host([disabled]) { |
| 134 pointer-events: none; | 134 pointer-events: none; |
| 135 } | 135 } |
| 136 | 136 |
| 137 :host([disabled]) #checkbox { | 137 :host([disabled]) #checkbox { |
| 138 opacity: 0.5; | 138 opacity: 0.5; |
| 139 border-color: var(--paper-checkbox-unchecked-color); | 139 border-color: var(--paper-checkbox-unchecked-color, --primary-text-color); |
| 140 } | 140 } |
| 141 | 141 |
| 142 :host([disabled][checked]) #checkbox { | 142 :host([disabled][checked]) #checkbox { |
| 143 background-color: var(--paper-checkbox-unchecked-color); | 143 background-color: var(--paper-checkbox-unchecked-color, --primary-text-color); |
| 144 opacity: 0.5; | 144 opacity: 0.5; |
| 145 } | 145 } |
| 146 | 146 |
| 147 :host([disabled]) #checkboxLabel { | 147 :host([disabled]) #checkboxLabel { |
| 148 opacity: 0.65; | 148 opacity: 0.65; |
| 149 } | 149 } |
| OLD | NEW |