| OLD | NEW |
| (Empty) | |
| 1 <!doctype html> |
| 2 <!-- |
| 3 @license |
| 4 Copyright (c) 2015 The Polymer Project Authors. All rights reserved. |
| 5 This code may only be used under the BSD style license found at http://polymer.g
ithub.io/LICENSE.txt |
| 6 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt |
| 7 The complete set of contributors may be found at http://polymer.github.io/CONTRI
BUTORS.txt |
| 8 Code distributed by Google as part of the polymer project is also |
| 9 subject to an additional IP rights grant found at http://polymer.github.io/PATEN
TS.txt |
| 10 --> |
| 11 |
| 12 <html> |
| 13 <head> |
| 14 |
| 15 <meta charset="utf-8"> |
| 16 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> |
| 17 <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-
scale=1, user-scalable=yes"> |
| 18 |
| 19 <title>paper-button demo</title> |
| 20 |
| 21 <script src="../../webcomponentsjs/webcomponents-lite.js"></script> |
| 22 <link rel="import" href="../../paper-styles/paper-styles.html"> |
| 23 <link rel="import" href="../../paper-styles/demo-pages.html"> |
| 24 <link rel="import" href="../../iron-icons/iron-icons.html"> |
| 25 <link rel="import" href="../paper-button.html"> |
| 26 |
| 27 <style is="custom-style"> |
| 28 .horizontal-section { |
| 29 min-width: 130px; |
| 30 } |
| 31 |
| 32 paper-button { |
| 33 display: block; |
| 34 margin-bottom: 24px; |
| 35 } |
| 36 |
| 37 paper-button.colorful { |
| 38 color: #4285f4; |
| 39 } |
| 40 |
| 41 paper-button[raised].colorful { |
| 42 background: #4285f4; |
| 43 color: #fff; |
| 44 } |
| 45 |
| 46 paper-button[toggles] { |
| 47 transition: background-color 0.3s; |
| 48 } |
| 49 |
| 50 paper-button[toggles][active] { |
| 51 background-color: rgba(0, 0, 0, 0.25); |
| 52 } |
| 53 |
| 54 paper-button[toggles][active].colorful { |
| 55 background-color: rgba(66, 133, 244, 0.25); |
| 56 } |
| 57 |
| 58 paper-button[toggles][active][raised].colorful { |
| 59 background-color: rgba(66, 133, 244, 0.75); |
| 60 } |
| 61 |
| 62 paper-button.blue { |
| 63 color: var(--paper-light-blue-500); |
| 64 --paper-button-flat-focus-color: var(--paper-light-blue-50); |
| 65 } |
| 66 paper-button.blue:hover { |
| 67 background: var(--paper-light-blue-50); |
| 68 } |
| 69 paper-button.red { |
| 70 color: var(--paper-red-500); |
| 71 --paper-button-flat-focus-color: var(--paper-red-50); |
| 72 } |
| 73 paper-button.red:hover { |
| 74 background: var(--paper-red-50); |
| 75 } |
| 76 paper-button.green { |
| 77 color: var(--paper-green-500); |
| 78 --paper-button-flat-focus-color: var(--paper-green-50); |
| 79 } |
| 80 paper-button.green:hover { |
| 81 background: var(--paper-green-50); |
| 82 } |
| 83 paper-button.orange { |
| 84 color: var(--paper-orange-500); |
| 85 --paper-button-flat-focus-color: var(--paper-orange-50); |
| 86 } |
| 87 paper-button.orange:hover { |
| 88 background: var(--paper-orange-50); |
| 89 } |
| 90 |
| 91 paper-button.hover:hover { |
| 92 background: #eee; |
| 93 } |
| 94 |
| 95 paper-button.ripple::shadow paper-ripple { |
| 96 color: var(--paper-pink-a200); |
| 97 } |
| 98 |
| 99 paper-button.ripple paper-ripple { |
| 100 color: var(--paper-pink-a200); |
| 101 } |
| 102 |
| 103 </style> |
| 104 |
| 105 </head> |
| 106 <body> |
| 107 <div class="horizontal center-justified layout"> |
| 108 <div> |
| 109 <h4>Flat</h4> |
| 110 <div class="horizontal-section"> |
| 111 <paper-button tabindex="0">button</paper-button> |
| 112 <paper-button tabindex="0" class="colorful">colorful</paper-button> |
| 113 <paper-button tabindex="0" disabled>disabled</paper-button> |
| 114 <paper-button tabindex="0" noink>noink</paper-button> |
| 115 <paper-button tabindex="0" class="colorful custom"><iron-icon icon="chec
k"></iron-icon>ok</paper-button> |
| 116 <paper-button tabindex="0" class="custom"><iron-icon icon="clear"></iron
-icon>cancel</paper-button> |
| 117 |
| 118 </div> |
| 119 </div> |
| 120 |
| 121 <div> |
| 122 <h4>Raised</h4> |
| 123 <div class="horizontal-section"> |
| 124 <paper-button tabindex="0" raised>button</paper-button> |
| 125 <paper-button tabindex="0" raised class="colorful">colorful</paper-butto
n> |
| 126 <paper-button tabindex="0" raised disabled>disabled</paper-button> |
| 127 <paper-button tabindex="0" raised noink>noink</paper-button> |
| 128 <paper-button tabindex="0" raised class="colorful custom"><iron-icon ico
n="check"></iron-icon>ok</paper-button> |
| 129 <paper-button tabindex="0" raised class="custom"><iron-icon icon="clear"
></iron-icon>cancel</paper-button> |
| 130 </div> |
| 131 </div> |
| 132 |
| 133 <div> |
| 134 <h4>Toggleable</h4> |
| 135 <div class="horizontal-section"> |
| 136 <paper-button tabindex="0" toggles>button</paper-button> |
| 137 <paper-button tabindex="0" toggles raised noink>noink</paper-button> |
| 138 <paper-button tabindex="0" toggles active class="colorful">colorful</pap
er-button> |
| 139 <paper-button tabindex="0" toggles raised active class="colorful">colorf
ul</paper-button> |
| 140 <paper-button tabindex="0" toggles class="colorful custom"><iron-icon ic
on="check"></iron-icon>ok</paper-button> |
| 141 <paper-button tabindex="0" toggles class="custom"><iron-icon icon="clear
"></iron-icon>cancel</paper-button> |
| 142 </div> |
| 143 </div> |
| 144 |
| 145 <div> |
| 146 <h4>Color</h4> |
| 147 <div class="horizontal-section"> |
| 148 <paper-button tabindex="0" class="blue ripple">button</paper-button> |
| 149 <paper-button tabindex="0" class="red ripple">noink</paper-button> |
| 150 <paper-button tabindex="0" class="orange ripple">colorful</paper-button> |
| 151 <paper-button tabindex="0" class="green ripple">colorful</paper-button> |
| 152 <paper-button tabindex="0" class="red ripple"><iron-icon icon="check"></
iron-icon>ok</paper-button> |
| 153 <paper-button tabindex="0" class="blue ripple"><iron-icon icon="clear"><
/iron-icon>cancel</paper-button> |
| 154 </div> |
| 155 </div> |
| 156 </div> |
| 157 </body> |
| 158 </html> |
| OLD | NEW |