~didrocks/+junk/face-detection-15.04

« back to all changes in this revision

Viewing changes to facedetection/www/bower_components/paper-spinner/paper-spinner.html

  • Committer: Didier Roche
  • Date: 2016-05-10 23:09:11 UTC
  • Revision ID: didier.roche@canonical.com-20160510230911-c7xr490zrj3yrzxd
New version

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<!--
 
2
@license
 
3
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
 
4
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
 
5
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
 
6
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
 
7
Code distributed by Google as part of the polymer project is also
 
8
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
 
9
-->
 
10
 
 
11
<link rel="import" href="../polymer/polymer.html">
 
12
<link rel="import" href="../iron-flex-layout/iron-flex-layout.html">
 
13
<link rel="import" href="../paper-styles/color.html">
 
14
<link rel="import" href="paper-spinner-behavior.html">
 
15
<link rel="import" href="paper-spinner-styles.html">
 
16
 
 
17
<!--
 
18
Material design: [Progress & activity](https://www.google.com/design/spec/components/progress-activity.html)
 
19
 
 
20
Element providing a multiple color material design circular spinner.
 
21
 
 
22
    <paper-spinner active></paper-spinner>
 
23
 
 
24
The default spinner cycles between four layers of colors; by default they are
 
25
blue, red, yellow and green. It can be customized to cycle between four different
 
26
colors. Use <paper-spinner-lite> for single color spinners.
 
27
 
 
28
### Accessibility
 
29
 
 
30
Alt attribute should be set to provide adequate context for accessibility. If not provided,
 
31
it defaults to 'loading'.
 
32
Empty alt can be provided to mark the element as decorative if alternative content is provided
 
33
in another form (e.g. a text block following the spinner).
 
34
 
 
35
    <paper-spinner alt="Loading contacts list" active></paper-spinner>
 
36
 
 
37
### Styling
 
38
 
 
39
The following custom properties and mixins are available for styling:
 
40
 
 
41
Custom property | Description | Default
 
42
----------------|-------------|----------
 
43
`--paper-spinner-layer-1-color` | Color of the first spinner rotation | `--google-blue-500`
 
44
`--paper-spinner-layer-2-color` | Color of the second spinner rotation | `--google-red-500`
 
45
`--paper-spinner-layer-3-color` | Color of the third spinner rotation | `--google-yellow-500`
 
46
`--paper-spinner-layer-4-color` | Color of the fourth spinner rotation | `--google-green-500`
 
47
`--paper-spinner-stroke-width` | The width of the spinner stroke | 3px
 
48
 
 
49
@group Paper Elements
 
50
@element paper-spinner
 
51
@hero hero.svg
 
52
@demo demo/index.html
 
53
-->
 
54
 
 
55
<dom-module id="paper-spinner">
 
56
  <template>
 
57
    <style include="paper-spinner-styles"></style>
 
58
 
 
59
    <div id="spinnerContainer" class-name="[[__computeContainerClasses(active, __coolingDown)]]">
 
60
      <div class="spinner-layer layer-1">
 
61
        <div class="circle-clipper left">
 
62
          <div class="circle"></div>
 
63
        </div><div class="gap-patch">
 
64
          <div class="circle"></div>
 
65
        </div><div class="circle-clipper right">
 
66
          <div class="circle"></div>
 
67
        </div>
 
68
      </div>
 
69
 
 
70
      <div class="spinner-layer layer-2">
 
71
        <div class="circle-clipper left">
 
72
          <div class="circle"></div>
 
73
        </div><div class="gap-patch">
 
74
          <div class="circle"></div>
 
75
        </div><div class="circle-clipper right">
 
76
          <div class="circle"></div>
 
77
        </div>
 
78
      </div>
 
79
 
 
80
      <div class="spinner-layer layer-3">
 
81
        <div class="circle-clipper left">
 
82
          <div class="circle"></div>
 
83
        </div><div class="gap-patch">
 
84
          <div class="circle"></div>
 
85
        </div><div class="circle-clipper right">
 
86
          <div class="circle"></div>
 
87
        </div>
 
88
      </div>
 
89
 
 
90
      <div class="spinner-layer layer-4">
 
91
        <div class="circle-clipper left">
 
92
          <div class="circle"></div>
 
93
        </div><div class="gap-patch">
 
94
          <div class="circle"></div>
 
95
        </div><div class="circle-clipper right">
 
96
          <div class="circle"></div>
 
97
        </div>
 
98
      </div>
 
99
    </div>
 
100
  </template>
 
101
 
 
102
  <script>
 
103
    Polymer({
 
104
      is: 'paper-spinner',
 
105
 
 
106
      behaviors: [
 
107
        Polymer.PaperSpinnerBehavior
 
108
      ]
 
109
    });
 
110
  </script>
 
111
</dom-module>