summaryrefslogtreecommitdiffstats
path: root/third_party/polymer/components/paper-icon-button/demo.html
blob: bd42d52f7da731d1a68896aba15e21033be65366 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
<!doctype html>
<!--
Copyright 2013 The Polymer Authors. All rights reserved.
Use of this source code is governed by a BSD-style
license that can be found in the LICENSE file.
-->
<html>
  <head>
    <title>paper-icon-button</title>
    <meta name="viewport" content="width=device-width; initial-scale=1.0; max-scale=1.0; user-scalable=yes">
    <script src="../platform/platform.js"></script>
    
    <link rel="import" href="../core-icons/core-icons.html">
    <link rel="import" href="../core-icons/maps-icons.html">
    <link rel="import" href="../core-icons/social-icons.html">
    <link rel="import" href="../core-selector/core-selector.html">
    <link rel="import" href="paper-icon-button.html">

    <style shim-shadowdom>
      body {
        font-family: sans-serif;
      }

      column {
        display: inline-block;
        max-width: 720px;
      }
      
      section {
        margin: 1em;
      }

      span {
        display: inline-block;
        text-align: right;
        width: 6em;
        margin-right: 1em;
      }

      paper-icon-button {
        vertical-align: middle;
      }

      paper-icon-button.red::shadow core-icon {
        fill: #fe774d;
      }

      core-selector paper-icon-button:not([active])::shadow core-icon {
        fill: #c9c9c9;
      }
    </style>
    
  </head>
  
  <body unresolved layout horizontal center-justified>

    <column>
     
      <section>
        <span>icon buttons</span>
        <paper-icon-button icon="menu"></paper-icon-button>
        <paper-icon-button icon="arrow-back"></paper-icon-button>
        <paper-icon-button icon="arrow-forward"></paper-icon-button>
        <paper-icon-button icon="check"></paper-icon-button>
        <paper-icon-button icon="close"></paper-icon-button>
        <paper-icon-button icon="fullscreen"></paper-icon-button>
        <paper-icon-button icon="fullscreen-exit"></paper-icon-button>
        <paper-icon-button icon="more-vert"></paper-icon-button>
        <paper-icon-button icon="refresh"></paper-icon-button>
      </section>
  
      <section>
        <span>styled</span>
        <paper-icon-button icon="favorite"></paper-icon-button>
        <paper-icon-button class="red" icon="favorite"></paper-icon-button>
        <paper-icon-button disabled onclick="alert('should not be clickable');" icon="favorite"></paper-icon-button>
      </section>
  
<!--       <section>
        <span>focused</span>
        <paper-icon-button focused icon="social:cake"></paper-icon-button>
        <paper-icon-button focused icon="social:plus-one"></paper-icon-button>
      </section>
 -->  
      <section>
        <span>segmented</span>
        <core-selector selected="1">
          <paper-icon-button fill isToggle icon="maps:directionswalk"></paper-icon-button>
          <paper-icon-button fill isToggle icon="maps:directions-bike"></paper-icon-button>
          <paper-icon-button fill isToggle icon="maps:directions-transit"></paper-icon-button>
          <paper-icon-button fill isToggle icon="maps:directions-car"></paper-icon-button>
        </core-selector>
      </section>

      <section>
        <span>custom img</span>
        <paper-icon-button iconSrc="https://assets-cdn.github.com/images/modules/logos_page/Octocat.png"></paper-icon-button>
      </section>
    </column>
    
  </body>
</html>