Path: blob/trunk/third_party/closure/goog/css/menuitem.css
2868 views
/*1* Copyright 2009 The Closure Library Authors. All Rights Reserved.2*3* Use of this source code is governed by the Apache License, Version 2.0.4* See the COPYING file for details.5*/67/*8* Standard styling for menus created by goog.ui.MenuItemRenderer.9*10* @author [email protected] (Attila Bodis)11*/121314/**15* State: resting.16*17* NOTE(mleibman,chrishenry):18* The RTL support in Closure is provided via two mechanisms -- "rtl" CSS19* classes and BiDi flipping done by the CSS compiler. Closure supports RTL20* with or without the use of the CSS compiler. In order for them not21* to conflict with each other, the "rtl" CSS classes need to have the @noflip22* annotation. The non-rtl counterparts should ideally have them as well, but,23* since .goog-menuitem existed without .goog-menuitem-rtl for so long before24* being added, there is a risk of people having templates where they are not25* rendering the .goog-menuitem-rtl class when in RTL and instead rely solely26* on the BiDi flipping by the CSS compiler. That's why we're not adding the27* @noflip to .goog-menuitem.28*/29.goog-menuitem {30color: #000;31font: normal 13px Arial, sans-serif;32list-style: none;33margin: 0;34/* 28px on the left for icon or checkbox; 7em on the right for shortcut. */35padding: 4px 7em 4px 28px;36white-space: nowrap;37}3839/* BiDi override for the resting state. */40/* @noflip */41.goog-menuitem.goog-menuitem-rtl {42/* Flip left/right padding for BiDi. */43padding-left: 7em;44padding-right: 28px;45}4647/* If a menu doesn't have checkable items or items with icons, remove padding. */48.goog-menu-nocheckbox .goog-menuitem,49.goog-menu-noicon .goog-menuitem {50padding-left: 12px;51}5253/*54* If a menu doesn't have items with shortcuts, leave just enough room for55* submenu arrows, if they are rendered.56*/57.goog-menu-noaccel .goog-menuitem {58padding-right: 20px;59}6061.goog-menuitem-content {62color: #000;63font: normal 13px Arial, sans-serif;64}6566/* State: disabled. */67.goog-menuitem-disabled .goog-menuitem-accel,68.goog-menuitem-disabled .goog-menuitem-content {69color: #ccc !important;70}71.goog-menuitem-disabled .goog-menuitem-icon {72opacity: 0.3;73-moz-opacity: 0.3;74filter: alpha(opacity=30);75}7677/* State: hover. */78.goog-menuitem-highlight,79.goog-menuitem-hover {80background-color: #d6e9f8;81/* Use an explicit top and bottom border so that the selection is visible82* in high contrast mode. */83border-color: #d6e9f8;84border-style: dotted;85border-width: 1px 0;86padding-bottom: 3px;87padding-top: 3px;88}8990/* State: selected/checked. */91.goog-menuitem-checkbox,92.goog-menuitem-icon {93background-repeat: no-repeat;94height: 16px;95left: 6px;96position: absolute;97right: auto;98vertical-align: middle;99width: 16px;100}101102/* BiDi override for the selected/checked state. */103/* @noflip */104.goog-menuitem-rtl .goog-menuitem-checkbox,105.goog-menuitem-rtl .goog-menuitem-icon {106/* Flip left/right positioning. */107left: auto;108right: 6px;109}110111.goog-option-selected .goog-menuitem-checkbox,112.goog-option-selected .goog-menuitem-icon {113/* Client apps may override the URL at which they serve the sprite. */114background: url(//ssl.gstatic.com/editor/editortoolbar.png) no-repeat -512px 0;115}116117/* Keyboard shortcut ("accelerator") style. */118.goog-menuitem-accel {119color: #999;120/* Keyboard shortcuts are untranslated; always left-to-right. */121/* @noflip */ direction: ltr;122left: auto;123padding: 0 6px;124position: absolute;125right: 0;126text-align: right;127}128129/* BiDi override for shortcut style. */130/* @noflip */131.goog-menuitem-rtl .goog-menuitem-accel {132/* Flip left/right positioning and text alignment. */133left: 0;134right: auto;135text-align: left;136}137138/* Mnemonic styles. */139.goog-menuitem-mnemonic-hint {140text-decoration: underline;141}142143.goog-menuitem-mnemonic-separator {144color: #999;145font-size: 12px;146padding-left: 4px;147}148149150