[Stacked plots] fixes scroll issue and removed redundant calls to backend (#3585)

* fixes scroll issue and removed redundant calls to backend

* change scroll to auto
This commit is contained in:
Deep Tailor 2020-12-08 10:10:50 -08:00 committed by GitHub
parent d80c0eef8e
commit ce8c31cfa4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 10 deletions

View File

@ -39,10 +39,11 @@ define([], function () {
const thisRequest = {
pending: 0
};
currentRequest = thisRequest;
$scope.currentRequest = thisRequest;
const telemetryObjects = $scope.telemetryObjects = [];
const thisTickWidthMap = {};
currentRequest = thisRequest;
$scope.currentRequest = thisRequest;
tickWidthMap = thisTickWidthMap;
if (unlisten) {
@ -52,14 +53,10 @@ define([], function () {
function addChild(child) {
const id = openmct.objects.makeKeyString(child.identifier);
const legacyObject = openmct.legacyObject(child);
thisTickWidthMap[id] = 0;
thisRequest.pending += 1;
objectService.getObjects([id])
.then(function (objects) {
thisRequest.pending -= 1;
const childObj = objects[id];
telemetryObjects.push(childObj);
});
telemetryObjects.push(legacyObject);
}
function removeChild(childIdentifier) {
@ -84,6 +81,7 @@ define([], function () {
}
thisRequest.pending += 1;
openmct.objects.get(domainObject.getId())
.then(function (obj) {
thisRequest.pending -= 1;

View File

@ -47,6 +47,7 @@ mct-plot {
.c-plot,
.gl-plot {
overflow: hidden;
min-height: 100px;
.s-status-taking-snapshot & {
.c-control-bar {
@ -79,7 +80,8 @@ mct-plot {
display: flex;
flex: 1 1 auto;
flex-direction: column;
overflow: hidden;
overflow-y: auto;
overflow-x: hidden;
}
&--stacked {