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

Side by Side Diff: polymer_1.0.4/bower_components/iron-a11y-announcer/demo/x-announces.html

Issue 1205703007: Add polymer 1.0 to npm_modules (Closed) Base URL: https://chromium.googlesource.com/infra/third_party/npm_modules.git@master
Patch Set: Renamed folder to 1.0.4 Created 5 years, 5 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
OLDNEW
(Empty)
1 <!--
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
4 The complete set of authors may be found at http://polymer.github.io/AUTHORS
5 The complete set of contributors may be found at http://polymer.github.io/CONTRI BUTORS
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
8 -->
9
10 <link rel="import" href="../../polymer/polymer.html">
11 <link rel="import" href="../../paper-button/paper-button.html">
12 <link rel="import" href="../iron-a11y-announcer.html">
13
14 <dom-module id="x-announces">
15 <style>
16 :host {
17 display: block;
18 position: relative;
19 padding: 1em 0;
20 }
21
22 paper-button {
23 background: #4285f4;
24 color: #fff;
25 }
26 </style>
27 <template>
28 <paper-button on-tap="_onTapAnnounce" raised>Announce</paper-button>
29 <span id="content" aria-hidden="true">
30 <content></content>
31 </span>
32 </template>
33 <script>
34 Polymer({
35 is: 'x-announces',
36
37 attached: function() {
38 Polymer.IronA11yAnnouncer.requestAvailability();
39 },
40
41 _onTapAnnounce: function() {
42 this.fire('iron-announce', {
43 text: this.$.content.textContent.trim()
44 }, {
45 bubbles: true
46 });
47 }
48 });
49 </script>
50 </dom-module>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698