mirror of
https://github.com/nasa/openmct.git
synced 2025-04-16 07:26:53 +00:00
[Frontend] Mods to layout element drag handles and editing behavior
WTD-951 layout.html: Added classes to and removed inline styles from drag handles, Removed edge handles, leaving corner handles in NW, SW and SE only; Added hover classes to display corner handles while editing; Modified z-indexing to allow view switcher to be accessed while editing;
This commit is contained in:
parent
a984e60ca5
commit
70e1a8ad9e
@ -2663,52 +2663,92 @@ label.checkbox.custom {
|
||||
* at runtime from the About dialog for additional information.
|
||||
*****************************************************************************/
|
||||
/* line 26, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-corner,
|
||||
.edit-main .edit-handle {
|
||||
position: absolute;
|
||||
top: 40px;
|
||||
right: 40px;
|
||||
bottom: 40px;
|
||||
left: 40px; }
|
||||
/* line 33, ../sass/edit/_editor.scss */
|
||||
z-index: 2; }
|
||||
/* line 32, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-corner {
|
||||
width: 15px;
|
||||
height: 15px; }
|
||||
/* line 35, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-corner.edit-resize-nw {
|
||||
-moz-border-radius-bottomright: 5px;
|
||||
-webkit-border-bottom-right-radius: 5px;
|
||||
border-bottom-right-radius: 5px;
|
||||
cursor: nw-resize;
|
||||
top: 0;
|
||||
left: 0; }
|
||||
/* line 40, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-corner.edit-resize-se {
|
||||
-moz-border-radius-topleft: 5px;
|
||||
-webkit-border-top-left-radius: 5px;
|
||||
border-top-left-radius: 5px;
|
||||
cursor: se-resize;
|
||||
bottom: 0;
|
||||
right: 0; }
|
||||
/* line 45, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-corner.edit-resize-sw {
|
||||
-moz-border-radius-topright: 5px;
|
||||
-webkit-border-top-right-radius: 5px;
|
||||
border-top-right-radius: 5px;
|
||||
cursor: sw-resize;
|
||||
bottom: 0;
|
||||
left: 0; }
|
||||
/* line 53, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-handle {
|
||||
top: 15px;
|
||||
right: 15px;
|
||||
bottom: 15px;
|
||||
left: 15px; }
|
||||
/* line 55, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-handle.edit-move {
|
||||
cursor: move;
|
||||
left: 30%;
|
||||
right: 30%;
|
||||
top: 30%;
|
||||
bottom: 30%; }
|
||||
/* line 42, ../sass/edit/_editor.scss */
|
||||
left: 0;
|
||||
right: 0;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
z-index: 1; }
|
||||
/* line 65, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-handle.edit-resize-n {
|
||||
top: 0px;
|
||||
bottom: auto;
|
||||
height: 15px;
|
||||
cursor: n-resize; }
|
||||
/* line 47, ../sass/edit/_editor.scss */
|
||||
/* line 70, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-handle.edit-resize-e {
|
||||
right: 0px;
|
||||
left: auto;
|
||||
width: 15px;
|
||||
cursor: e-resize; }
|
||||
/* line 52, ../sass/edit/_editor.scss */
|
||||
/* line 75, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-handle.edit-resize-s {
|
||||
bottom: 0px;
|
||||
top: auto;
|
||||
height: 15px;
|
||||
cursor: s-resize; }
|
||||
/* line 57, ../sass/edit/_editor.scss */
|
||||
/* line 80, ../sass/edit/_editor.scss */
|
||||
.edit-main .edit-handle.edit-resize-w {
|
||||
left: 0px;
|
||||
right: auto;
|
||||
width: 15px;
|
||||
cursor: w-resize; }
|
||||
/* line 66, ../sass/edit/_editor.scss */
|
||||
/* line 89, ../sass/edit/_editor.scss */
|
||||
.edit-main .frame.child-frame.panel:hover {
|
||||
border-color: #0099cc;
|
||||
-moz-box-shadow: rgba(0, 0, 0, 0.7) 0 3px 10px;
|
||||
-webkit-box-shadow: rgba(0, 0, 0, 0.7) 0 3px 10px;
|
||||
box-shadow: rgba(0, 0, 0, 0.7) 0 3px 10px; }
|
||||
/* line 69, ../sass/edit/_editor.scss */
|
||||
.edit-main .frame.child-frame.panel:hover .edit-handle {
|
||||
background-color: rgba(0, 153, 204, 0.3); }
|
||||
box-shadow: rgba(0, 0, 0, 0.7) 0 3px 10px;
|
||||
border-color: #0099cc;
|
||||
z-index: 2; }
|
||||
/* line 93, ../sass/edit/_editor.scss */
|
||||
.edit-main .frame.child-frame.panel:hover .view-switcher {
|
||||
opacity: 1; }
|
||||
/* line 96, ../sass/edit/_editor.scss */
|
||||
.edit-main .frame.child-frame.panel:hover .edit-corner {
|
||||
background-color: rgba(0, 153, 204, 0.8); }
|
||||
/* line 98, ../sass/edit/_editor.scss */
|
||||
.edit-main .frame.child-frame.panel:hover .edit-corner:hover {
|
||||
background-color: #0099cc; }
|
||||
|
||||
/* line 1, ../sass/features/_imagery.scss */
|
||||
.l-image-main-wrapper,
|
||||
@ -4061,11 +4101,12 @@ input[type="text"] {
|
||||
left: 5px; }
|
||||
/* line 54, ../sass/user-environ/_frame.scss */
|
||||
.frame.frame-template .view-switcher {
|
||||
opacity: 0; }
|
||||
/* line 58, ../sass/user-environ/_frame.scss */
|
||||
opacity: 0;
|
||||
z-index: 10; }
|
||||
/* line 59, ../sass/user-environ/_frame.scss */
|
||||
.frame.frame-template:hover .view-switcher {
|
||||
opacity: 1; }
|
||||
/* line 66, ../sass/user-environ/_frame.scss */
|
||||
/* line 67, ../sass/user-environ/_frame.scss */
|
||||
.frame .view-switcher .name {
|
||||
display: none; }
|
||||
|
||||
|
@ -21,42 +21,65 @@
|
||||
*****************************************************************************/
|
||||
|
||||
.edit-main {
|
||||
$handleD: 15px;
|
||||
$cr: 5px;
|
||||
.edit-corner,
|
||||
.edit-handle {
|
||||
position: absolute;
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
.edit-corner {
|
||||
width: $handleD;
|
||||
height: $handleD;
|
||||
&.edit-resize-nw {
|
||||
@include border-bottom-right-radius($cr);
|
||||
cursor: nw-resize;
|
||||
top: 0; left: 0;
|
||||
}
|
||||
&.edit-resize-se {
|
||||
@include border-top-left-radius($cr);
|
||||
cursor: se-resize;
|
||||
bottom: 0; right: 0;
|
||||
}
|
||||
&.edit-resize-sw {
|
||||
@include border-top-right-radius($cr);
|
||||
cursor: sw-resize;
|
||||
bottom: 0; left: 0;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.edit-handle {
|
||||
$edgeHandleD: 15px;
|
||||
$cornerM: 50px;
|
||||
//@include border-radius(0.5em);
|
||||
//display: none;
|
||||
position: absolute;
|
||||
top: $cornerM; right: $cornerM; bottom: $cornerM; left: $cornerM;
|
||||
top: $handleD; right: $handleD; bottom: $handleD; left: $handleD;
|
||||
&.edit-move {
|
||||
$m: 30%;
|
||||
$m: 0; //$handleD;
|
||||
cursor: move;
|
||||
left: $m;
|
||||
right: $m;
|
||||
top: $m;
|
||||
bottom: $m;
|
||||
z-index: 1;
|
||||
|
||||
}
|
||||
&.edit-resize-n {
|
||||
top: 0px; bottom: auto;
|
||||
height: $edgeHandleD;
|
||||
height: $handleD;
|
||||
cursor: n-resize;
|
||||
}
|
||||
&.edit-resize-e {
|
||||
right: 0px; left: auto;
|
||||
width: $edgeHandleD;
|
||||
width: $handleD;
|
||||
cursor: e-resize;
|
||||
}
|
||||
&.edit-resize-s {
|
||||
bottom: 0px; top: auto;
|
||||
height: $edgeHandleD;
|
||||
height: $handleD;
|
||||
cursor: s-resize;
|
||||
}
|
||||
&.edit-resize-w {
|
||||
left: 0px; right: auto;
|
||||
width: $edgeHandleD;
|
||||
width: $handleD;
|
||||
cursor: w-resize;
|
||||
}
|
||||
}
|
||||
@ -64,10 +87,17 @@
|
||||
|
||||
.frame.child-frame.panel {
|
||||
&:hover {
|
||||
border-color: $colorKey;
|
||||
@include boxShdwLarge();
|
||||
.edit-handle {
|
||||
background-color: rgba($colorKey, 0.3);
|
||||
border-color: $colorKey;
|
||||
z-index: 2;
|
||||
.view-switcher {
|
||||
opacity: 1;
|
||||
}
|
||||
.edit-corner {
|
||||
background-color: rgba($colorKey, 0.8);
|
||||
&:hover {
|
||||
background-color: rgba($colorKey, 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -54,6 +54,7 @@
|
||||
.view-switcher {
|
||||
//display: none;
|
||||
opacity: 0;
|
||||
z-index: 10;
|
||||
}
|
||||
&:hover .view-switcher {
|
||||
// Show the view switcher on frame hover
|
||||
|
@ -34,13 +34,14 @@
|
||||
|
||||
<!-- Drag handles -->
|
||||
<span ng-show="domainObject.hasCapability('editor')">
|
||||
|
||||
<span
|
||||
class="edit-handle edit-move"
|
||||
mct-drag-down="controller.startDrag(childObject.getId(), [1,1], [0,0])"
|
||||
mct-drag="controller.continueDrag(delta)"
|
||||
mct-drag-up="controller.endDrag()">
|
||||
</span>
|
||||
|
||||
<!--
|
||||
<span
|
||||
class="edit-handle edit-resize-w"
|
||||
mct-drag-down="controller.startDrag(childObject.getId(), [1,0], [-1,0])"
|
||||
@ -66,23 +67,29 @@
|
||||
mct-drag="controller.continueDrag(delta)"
|
||||
mct-drag-up="controller.endDrag()">
|
||||
</span>
|
||||
-->
|
||||
|
||||
<span style="position: absolute; left: 0px; width: 12px; top: 0px; height: 12px; cursor: nw-resize;"
|
||||
<span
|
||||
class="edit-corner edit-resize-nw"
|
||||
mct-drag-down="controller.startDrag(childObject.getId(), [1,1], [-1,-1])"
|
||||
mct-drag="controller.continueDrag(delta)"
|
||||
mct-drag-up="controller.endDrag()">
|
||||
</span>
|
||||
<span style="position: absolute; right: 0px; width: 12px; top: 0px; height: 12px; cursor: ne-resize;"
|
||||
<!--span
|
||||
class="edit-corner edit-resize-nw"
|
||||
style="position: absolute; right: 0px; width: 12px; top: 0px; height: 12px; cursor: ne-resize;"
|
||||
mct-drag-down="controller.startDrag(childObject.getId(), [0,1], [1,-1])"
|
||||
mct-drag="controller.continueDrag(delta)"
|
||||
mct-drag-up="controller.endDrag()">
|
||||
</span>
|
||||
<span style="position: absolute; left: 0px; width: 12px; bottom: 0px; height: 12px; cursor: sw-resize;"
|
||||
</span-->
|
||||
<span
|
||||
class="edit-corner edit-resize-sw"
|
||||
mct-drag-down="controller.startDrag(childObject.getId(), [1,0], [-1,1])"
|
||||
mct-drag="controller.continueDrag(delta)"
|
||||
mct-drag-up="controller.endDrag()">
|
||||
</span>
|
||||
<span style="position: absolute; right: 0px; width: 12px; bottom: 0px; height: 12px; cursor: se-resize;"
|
||||
<span
|
||||
class="edit-corner edit-resize-se"
|
||||
mct-drag-down="controller.startDrag(childObject.getId(), [0,0], [1,1])"
|
||||
mct-drag="controller.continueDrag(delta)"
|
||||
mct-drag-up="controller.endDrag()">
|
||||
|
Loading…
x
Reference in New Issue
Block a user