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

Side by Side Diff: third_party/polymer/components-chromium/core-dropdown-menu/core-dropdown-menu.html

Issue 1215543002: Remove Polymer 0.5. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix unit test 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) 2014 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
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
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
8 --><!--
9
10 `core-dropdown-menu` works together with `core-dropdown` and `core-selector` to
11 implement a drop-down menu. The currently selected item is displayed in the
12 control. If no item is selected, the `label` is displayed instead.
13
14 The child element with the class `dropdown` will be used as the drop-down
15 menu. It should be a `core-dropdown` or other overlay element. You should
16 also provide a `core-selector` or other selector element, such as `core-menu`,
17 in the drop-down.
18
19 Example:
20
21 <core-dropdown-menu label="Choose a pastry">
22 <core-dropdown class="dropdown">
23 <core-selector>
24 <core-item label="Croissant"></core-item>
25 <core-item label="Donut"></core-item>
26 <core-item label="Financier"></core-item>
27 <core-item label="Madeleine"></core-item>
28 </core-selector>
29 </core-dropdown>
30 </core-dropdown-menu>
31
32 @group Polymer Core Elements
33 @element core-dropdown-menu
34 @extends core-dropdown-base
35 @status unstable
36 @homepage github.io
37 --><html><head><link href="../polymer/polymer.html" rel="import">
38 <link href="../core-a11y-keys/core-a11y-keys.html" rel="import">
39 <link href="../core-dropdown/core-dropdown-base.html" rel="import">
40 <link href="../core-focusable/core-focusable.html" rel="import">
41 <link href="../core-icon/core-icon.html" rel="import">
42 <link href="../core-icons/core-icons.html" rel="import">
43
44 </head><body><polymer-element name="core-dropdown-menu" extends="core-dropdown-b ase" relative="" layout="" inline="" horizontal="" center="" tabindex="0" assetp ath="">
45 <template>
46
47 <style>
48 :host {
49 background-color: #fff;
50 }
51
52 :host([disabled]) {
53 color: #a8a8a8;
54 }
55
56 #label {
57 overflow: hidden;
58 white-space: nowrap;
59 text-overflow: ellipsis;
60 }
61 </style>
62
63 <core-a11y-keys target="{{}}" keys="enter space" on-keys-pressed="{{toggleOver lay}}"></core-a11y-keys>
64
65 <div flex="" auto="" id="label">{{selectedItemLabel || label}}</div>
66 <core-icon id="arrow" icon="{{opened ? openedIcon : closedIcon}}"></core-icon>
67
68 <content></content>
69
70 </template>
71
72 </polymer-element>
73 <script charset="utf-8" src="core-dropdown-menu-extracted.js"></script></body></ html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698