1/* Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 * Use of this source code is governed by a BSD-style license that can be
3 * found in the LICENSE file. */
4
5menu {
6  -webkit-box-shadow: 0 2px 4px rgba(0, 0, 0, .50);
7  background: white;
8  border-radius: 2px;
9  color: black;
10  cursor: default;
11  left: 0;
12  margin: 0;
13  outline: 1px solid rgba(0, 0, 0, 0.2);
14  padding: 8px 0;
15  position: fixed;
16  white-space: nowrap;
17  z-index: 3;
18}
19
20menu:not(.decorated) {
21  display: none;
22}
23
24menu > * {
25  box-sizing: border-box;
26  display: block;
27  margin: 0;
28  text-align: start;
29  width: 100%;
30}
31
32menu > :not(hr) {
33  -webkit-appearance: none;
34  background: transparent;
35  border: 0;
36  color: black;
37  font: inherit;
38  line-height: 18px;
39  outline: none;
40  overflow: hidden;
41  padding: 0 19px;
42  text-overflow: ellipsis;
43}
44
45menu > hr {
46  background: -webkit-linear-gradient(left,
47                                      rgba(0, 0, 0, .10),
48                                      rgba(0, 0, 0, .02) 96%);
49  border: 0;
50  height: 1px;
51  margin: 8px 0;
52}
53
54menu > [disabled] {
55  color: rgba(0, 0, 0, .3);
56}
57
58menu > [hidden] {
59  display: none;
60}
61
62menu > :not(hr)[selected] {
63  background-color: rgba(0, 0, 0, .06);
64}
65
66menu > :not(hr)[selected]:active {
67  background-color: rgba(0, 0, 0, .06);
68}
69
70menu > [checked]::before {
71  content: url('../images/checkbox_black.png');
72  display: inline-block;
73  height: 9px;
74  margin: 0 5px;
75  width: 9px;
76}
77
78menu > [checked] {
79  -webkit-padding-start: 0;
80}
81
82menu > [selected][checked]:active::before {
83  content: url('../images/checkbox_white.png');
84}
85
86/* TODO(zvorygin) menu > [shortcutText]::after - this selector is much better,
87 * but it's buggy in current webkit revision, so I have to use [showShortcuts].
88 */
89menu[showShortcuts] > ::after {
90  -webkit-padding-start: 30px;
91  color: #999;
92  content: attr(shortcutText);
93  float: right;
94}
95