mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-07 23:16:52 +08:00
110 lines
1.7 KiB
SCSS
110 lines
1.7 KiB
SCSS
|
|
// Use Flexbox for our header and footer bars
|
|
.bar {
|
|
@include disable-user-select();
|
|
|
|
display: -webkit-box;
|
|
display: box;
|
|
|
|
position: fixed;
|
|
left: 0;
|
|
right: 0;
|
|
z-index: 10;
|
|
width: 100%;
|
|
height: $barHeight;
|
|
padding: $barPaddingPortrait;
|
|
box-sizing: border-box;
|
|
|
|
|
|
|
|
// Title inside of a bar is centered
|
|
.title {
|
|
position: absolute;
|
|
z-index: 0;
|
|
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
|
|
line-height: $barHeight;
|
|
|
|
margin: 0;
|
|
//padding: $barPaddingVertical 0px;
|
|
|
|
min-width: 30px;
|
|
|
|
// Go into ellipsis if too small
|
|
text-overflow: ellipsis;
|
|
|
|
text-align: center;
|
|
white-space: nowrap;
|
|
font-size: $barTitleFontSize;
|
|
|
|
}
|
|
|
|
|
|
.title a {
|
|
color: inherit;
|
|
}
|
|
|
|
.button {
|
|
@include box-flex(0);
|
|
background-color: transparent;
|
|
line-height: $barButtonLineHeight;
|
|
font-size: 12px;
|
|
padding: 4px 12px;
|
|
}
|
|
|
|
.button-bar {
|
|
line-height: $barButtonBarLineHeight;
|
|
}
|
|
|
|
.button-bar + .button, .button + .button-bar {
|
|
margin-left: 5px;
|
|
}
|
|
|
|
// Place the last button in a bar on the right of the bar
|
|
.title + .button:last-child,
|
|
> .button + .button:last-child,
|
|
> .button.pull-right,
|
|
.title + .buttons {
|
|
position: absolute;
|
|
top: 5px;
|
|
right: 5px;
|
|
}
|
|
}
|
|
|
|
|
|
// Header at top
|
|
.bar-header {
|
|
top: 0;
|
|
}
|
|
|
|
// Footer at bottom
|
|
.bar-footer {
|
|
bottom: 0;
|
|
}
|
|
|
|
// Don't render padding if the bar is just for tabs
|
|
.bar-tabs {
|
|
padding: 0;
|
|
}
|
|
|
|
.bar-header-secondary {
|
|
top: $barHeight;
|
|
}
|
|
.bar-footer-secondary {
|
|
bottom: $barHeight;
|
|
}
|
|
|
|
/* Pad top/bottom of content so it doesn't hide behind .bar-title and .bar-tab.
|
|
Note: For these to work, content must come after both bars in the markup */
|
|
.has-header {
|
|
top: $barHeight;
|
|
}
|
|
|
|
.has-footer {
|
|
bottom: $barHeight;
|
|
}
|
|
|