Added styling to back and selection arrow (tree). Also increased the space allowed for selection arrow on tree item. Info Button created on grid items for mobile. Info bubble appears on tablet like desktop. Also on mobile, info bubble fits to width. New QueryService that returns if on iPhone. Also formatted dialog box so that their is no margin and takes up fullscreen on mobile.
179 lines
4.5 KiB
SCSS
179 lines
4.5 KiB
SCSS
/*****************************************************************************
|
|
* Open MCT Web, Copyright (c) 2014-2015, United States Government
|
|
* as represented by the Administrator of the National Aeronautics and Space
|
|
* Administration. All rights reserved.
|
|
*
|
|
* Open MCT Web is licensed under the Apache License, Version 2.0 (the
|
|
* "License"); you may not use this file except in compliance with the License.
|
|
* You may obtain a copy of the License at
|
|
* http://www.apache.org/licenses/LICENSE-2.0.
|
|
*
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
|
* License for the specific language governing permissions and limitations
|
|
* under the License.
|
|
*
|
|
* Open MCT Web includes source code licensed under additional open source
|
|
* licenses. See the Open Source Licenses file (LICENSES.md) included with
|
|
* this source code distribution or the Licensing information page available
|
|
* at runtime from the About dialog for additional information.
|
|
*****************************************************************************/
|
|
|
|
//************************************************* GENERAL
|
|
.bubble-container {
|
|
pointer-events: none;
|
|
}
|
|
|
|
|
|
//************************************************* LAYOUT
|
|
|
|
.l-infobubble-wrapper {
|
|
$arwSize: 5px;
|
|
@include box-shadow(rgba(black, 0.4) 0 1px 5px);
|
|
position: relative;
|
|
z-index: 50;
|
|
.l-infobubble {
|
|
display: inline-block;
|
|
min-width: $bubbleMinW;
|
|
max-width: $bubbleMaxW;
|
|
padding: 5px 10px;
|
|
&:before {
|
|
content:"";
|
|
position: absolute;
|
|
width: 0;
|
|
height: 0;
|
|
}
|
|
table {
|
|
width: 100%;
|
|
tr {
|
|
td {
|
|
//max-width: 150px;
|
|
padding: 2px 0;
|
|
vertical-align: top;
|
|
//white-space: nowrap;
|
|
//overflow: hidden;
|
|
//text-overflow: ellipsis;
|
|
&.label {
|
|
padding-right: $interiorMargin * 2;
|
|
white-space: nowrap;
|
|
}
|
|
&.value {
|
|
white-space: nowrap;
|
|
//width: 90%;
|
|
}
|
|
&.align-wrap {
|
|
white-space: normal;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
.title {
|
|
@include ellipsize();
|
|
margin-bottom: $interiorMargin;
|
|
//max-width: 200px;
|
|
}
|
|
}
|
|
|
|
&.arw-left {
|
|
margin-left: $bubbleArwSize*2;
|
|
.l-infobubble::before {
|
|
right: 100%;
|
|
// NOTE: [MOBILE] REMOVES TRIANGLE
|
|
// Removes the triangle located on the info
|
|
// bubble for phones only, for tablets and
|
|
// desktops, triangle remains.
|
|
@include desktopandtablet {
|
|
@include triangle('left', $bubbleArwSize, 1.5, $colorInfoBubbleBg);
|
|
}
|
|
}
|
|
}
|
|
|
|
&.arw-right {
|
|
// NOTE: [MOBILE] REMOVES RIGHT MARGIN
|
|
// Removes right margin made for the
|
|
// triangle on mobile
|
|
@include desktopandtablet {
|
|
margin-right: $bubbleArwSize*2;
|
|
}
|
|
.l-infobubble::before {
|
|
left: 100%;
|
|
// NOTE: [MOBILE] REMOVES TRIANGLE
|
|
// Removes the triangle located on the info
|
|
// bubble for phones only, for tablets and
|
|
// desktops, triangle remains.
|
|
@include desktopandtablet {
|
|
@include triangle('right', $bubbleArwSize, 1.5, $colorInfoBubbleBg);
|
|
}
|
|
}
|
|
}
|
|
|
|
&.arw-top {
|
|
.l-infobubble::before {
|
|
top: $bubbleArwSize * 2;
|
|
}
|
|
}
|
|
|
|
&.arw-btm {
|
|
.l-infobubble::before {
|
|
bottom: $bubbleArwSize * 2;
|
|
}
|
|
}
|
|
|
|
&.arw-down {
|
|
margin-bottom: $arwSize*2;
|
|
.l-infobubble::before {
|
|
left: 50%;
|
|
top: 100%;
|
|
margin-left: -1 * $arwSize;
|
|
border-left: $arwSize solid transparent;
|
|
border-right: $arwSize solid transparent;
|
|
border-top: ($arwSize * 1.5) solid $colorInfoBubbleBg;
|
|
}
|
|
}
|
|
.arw {
|
|
z-index: 2;
|
|
}
|
|
&.arw-up .arw.arw-down,
|
|
&.arw-down .arw.arw-up { display: none; }
|
|
}
|
|
|
|
//************************************************* LOOK AND FEEL
|
|
|
|
.l-thumbsbubble-wrapper {
|
|
.arw-up {
|
|
@include triangle('up', $bubbleArwSize, 1.5, $colorThumbsBubbleBg);
|
|
}
|
|
.arw-down {
|
|
@include triangle('down', $bubbleArwSize, 1.5, $colorThumbsBubbleBg);
|
|
}
|
|
}
|
|
.s-infobubble {
|
|
$emFg: darken($colorInfoBubbleFg, 20%);
|
|
@include border-radius($basicCr);
|
|
@include box-shadow(rgba(black, 0.4) 0 1px 5px);
|
|
background: $colorInfoBubbleBg;
|
|
color: $colorInfoBubbleFg;
|
|
font-size: 0.8rem;
|
|
.title {
|
|
color: $emFg;
|
|
font-weight: bold;
|
|
}
|
|
tr {
|
|
td {
|
|
border-top: 1px solid darken($colorInfoBubbleBg, 10%);
|
|
font-size: 0.9em;
|
|
}
|
|
&:first-child td {
|
|
border-top: none;
|
|
}
|
|
}
|
|
.value {
|
|
color: $emFg;
|
|
}
|
|
}
|
|
|
|
.s-thumbsbubble {
|
|
background: $colorThumbsBubbleBg;
|
|
color: $colorThumbsBubbleFg;
|
|
} |