Mailspring/static/components/menu.less
Evan Morikawa 348d60ea0c feat(picker): new folder and label picker
Summary:
The new, styled folder and label picker!

Some highlights:
- Folder picker has custom icons and a divider
- Label picker has checkboxes with off, checked, and intermediate state
- Extracted LabelColorizer out of mail-label
- Search will bold the results it found
- Fixes to Tooltip to prevent it displaying at invalid moments
- Keyboard UX improvements to Menu

Test Plan: coming soon

Reviewers: bengotow

Reviewed By: bengotow

Differential Revision: https://phab.nylas.com/D1790
2015-07-23 11:47:46 -07:00

99 lines
2.3 KiB
Text

@import "ui-variables";
.menu {
flex: 1;
display: flex;
flex-direction: column;
.header-container {
flex-shrink: 0; // Don't squish the header! There may be a search box here
background-color: @background-color-secondary;
border-bottom: 1px solid @base-border-color;
padding: 3px;
position: relative;
input.search {
border: 1px solid darken(@background-color-secondary, 10%);
border-radius: 3px;
padding-left: 0;
background-color: white;
background-repeat: no-repeat;
background-image: url("../static/images/search/searchloupe@2x.png");
background-size: 15px 15px;
background-position: 7px 4px;
text-indent: 31px;
box-shadow: inset 0 1px 0 rgba(0,0,0,0.05), 0 1px 0 rgba(0,0,0,0.05)
}
}
.footer-container {
position: relative;
}
.content-container {
background: @background-color-secondary;
width: 100%;
margin-top: -1px;
overflow: auto;
}
.item {
display: block;
padding-left: @padding-base-horizontal;
padding-top: @padding-base-vertical;
padding-bottom: @padding-base-vertical;
cursor: default;
color: @text-color;
width: 100%;
overflow: hidden;
.primary {
max-width: 100%;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.secondary {
max-width: 100%;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
padding-left:5px;
color:@text-color-very-subtle;
}
}
.item.divider {
font-weight:@headings-font-weight;
color: @menu-divider-color;
font-size: @font-size-small;
text-transform: uppercase;
margin-top: 10px;
pointer-events: none;
}
.item.checked {
background-image:url(./images/menu/checked@2x.png);
background-size: 16px;
background-position: right;
background-repeat: no-repeat;
background-position-x: 97%;
margin-right: 20px;
padding-right: 10%;
}
.item.selected.checked, .item.checked:hover {
background-image:url(./images/menu/checked-selected@2x.png);
}
.item.selected, .item:hover, .item:active {
text-decoration: none;
background-color: @accent-primary;
color: @text-color-inverse;
.primary {
color: @text-color-inverse;
}
.secondary {
color: @text-color-inverse-very-subtle;
}
}
}