Merge branch 'master' into warp135b

This commit is contained in:
Victor Woeltjen
2016-03-07 15:21:28 -08:00
219 changed files with 6946 additions and 19041 deletions

View File

@@ -29,6 +29,8 @@ define([
"./src/controllers/RefreshingController",
"./src/actions/StartTimerAction",
"./src/actions/RestartTimerAction",
"text!./res/templates/clock.html",
"text!./res/templates/timer.html",
'legacyRegistry'
], function (
ClockIndicator,
@@ -38,6 +40,8 @@ define([
RefreshingController,
StartTimerAction,
RestartTimerAction,
clockTemplate,
timerTemplate,
legacyRegistry
) {
"use strict";
@@ -116,13 +120,13 @@ define([
"key": "clock",
"type": "clock",
"editable": false,
"templateUrl": "templates/clock.html"
"template": clockTemplate
},
{
"key": "timer",
"type": "timer",
"editable": false,
"templateUrl": "templates/timer.html"
"template": timerTemplate
}
],
"actions": [

View File

@@ -25,11 +25,13 @@ define([
"./src/ConductorRepresenter",
"./src/ConductorTelemetryDecorator",
"./src/ConductorService",
"text!./res/templates/time-conductor.html",
'legacyRegistry'
], function (
ConductorRepresenter,
ConductorTelemetryDecorator,
ConductorService,
timeConductorTemplate,
legacyRegistry
) {
"use strict";
@@ -70,7 +72,7 @@ define([
"templates": [
{
"key": "time-conductor",
"templateUrl": "templates/time-conductor.html"
"template": timeConductorTemplate
}
],
"constants": [

View File

@@ -25,11 +25,13 @@ define([
"./src/EventListController",
"./src/directives/MCTDataTable",
"./src/policies/MessagesViewPolicy",
"text!./res/templates/messages.html",
'legacyRegistry'
], function (
EventListController,
MCTDataTable,
MessagesViewPolicy,
messagesTemplate,
legacyRegistry
) {
"use strict";
@@ -44,7 +46,7 @@ define([
"name": "Messages",
"glyph": "5",
"description": "Scrolling list of messages.",
"templateUrl": "templates/messages.html",
"template": messagesTemplate,
"needs": [
"telemetry"
],

View File

@@ -25,14 +25,14 @@
* Module defining MCTDataTable. Created by shale on 06/22/2015.
*/
define(
[],
function () {
['text!../../res/templates/mct-data-table.html'],
function (dataTableTemplate) {
"use strict";
function MCTDataTable($window) {
return {
restrict: "E",
templateUrl: "platform/features/events/res/templates/mct-data-table.html",
template: dataTableTemplate,
scope: {
headers: "=",
rows: "=",

View File

@@ -25,11 +25,13 @@ define([
"./src/policies/ImageryViewPolicy",
"./src/controllers/ImageryController",
"./src/directives/MCTBackgroundImage",
"text!./res/templates/imagery.html",
'legacyRegistry'
], function (
ImageryViewPolicy,
ImageryController,
MCTBackgroundImage,
imageryTemplate,
legacyRegistry
) {
"use strict";
@@ -42,7 +44,7 @@ define([
"name": "Imagery",
"key": "imagery",
"glyph": "ã",
"templateUrl": "templates/imagery.html",
"template": imageryTemplate,
"priority": "preferred",
"needs": [
"telemetry"

View File

@@ -25,11 +25,27 @@ define([
"./src/LayoutController",
"./src/FixedController",
"./src/LayoutCompositionPolicy",
"text!./res/templates/layout.html",
"text!./res/templates/fixed.html",
"text!./res/templates/frame.html",
"text!./res/templates/elements/telemetry.html",
"text!./res/templates/elements/box.html",
"text!./res/templates/elements/line.html",
"text!./res/templates/elements/text.html",
"text!./res/templates/elements/image.html",
'legacyRegistry'
], function (
LayoutController,
FixedController,
LayoutCompositionPolicy,
layoutTemplate,
fixedTemplate,
frameTemplate,
telemetryTemplate,
boxTemplate,
lineTemplate,
textTemplate,
imageTemplate,
legacyRegistry
) {
"use strict";
@@ -44,7 +60,7 @@ define([
"name": "Display Layout",
"glyph": "L",
"type": "layout",
"templateUrl": "templates/layout.html",
"template": layoutTemplate,
"editable": true,
"uses": []
},
@@ -53,7 +69,7 @@ define([
"name": "Fixed Position",
"glyph": "3",
"type": "telemetry.panel",
"templateUrl": "templates/fixed.html",
"template": fixedTemplate,
"uses": [
"composition"
],
@@ -191,7 +207,7 @@ define([
"representations": [
{
"key": "frame",
"templateUrl": "templates/frame.html"
"template": frameTemplate
}
],
"controllers": [
@@ -218,23 +234,23 @@ define([
"templates": [
{
"key": "fixed.telemetry",
"templateUrl": "templates/elements/telemetry.html"
"template": telemetryTemplate
},
{
"key": "fixed.box",
"templateUrl": "templates/elements/box.html"
"template": boxTemplate
},
{
"key": "fixed.line",
"templateUrl": "templates/elements/line.html"
"template": lineTemplate
},
{
"key": "fixed.text",
"templateUrl": "templates/elements/text.html"
"template": textTemplate
},
{
"key": "fixed.image",
"templateUrl": "templates/elements/image.html"
"template": imageTemplate
}
],
"policies": [

View File

@@ -303,12 +303,16 @@ define(
this.generateDragHandles = generateDragHandles;
// Track current selection state
this.selection = $scope.selection;
$scope.$watch("selection", function (selection) {
this.selection = selection;
// Expose the view's selection proxy
if (this.selection) {
this.selection.proxy(new FixedProxy(addElement, $q, dialogService));
}
// Expose the view's selection proxy
if (this.selection) {
this.selection.proxy(
new FixedProxy(addElement, $q, dialogService)
);
}
}.bind(this));
// Refresh list of elements whenever model changes
$scope.$watch("model.modified", refreshElements);

View File

@@ -148,6 +148,8 @@ define(
mockHandler,
mockFormatter
);
findWatch("selection")(mockScope.selection);
});
it("subscribes when a domain object is available", function () {

View File

@@ -23,9 +23,11 @@
define([
"./src/EmbeddedPageController",
"text!./res/iframe.html",
'legacyRegistry'
], function (
EmbeddedPageController,
iframeTemplate,
legacyRegistry
) {
"use strict";
@@ -54,7 +56,7 @@ define([
],
"views": [
{
"templateUrl": "iframe.html",
"template": iframeTemplate,
"name": "Page",
"type": "example.page",
"key": "example.page",

View File

@@ -25,11 +25,17 @@ define([
"./src/MCTChart",
"./src/PlotController",
"./src/policies/PlotViewPolicy",
"./src/PlotOptionsController",
"text!./res/templates/plot.html",
"text!./res/templates/plot-options-browse.html",
'legacyRegistry'
], function (
MCTChart,
PlotController,
PlotViewPolicy,
PlotOptionsController,
plotTemplate,
plotOptionsBrowseTemplate,
legacyRegistry
) {
"use strict";
@@ -42,7 +48,7 @@ define([
"name": "Plot",
"key": "plot",
"glyph": "6",
"templateUrl": "templates/plot.html",
"template": plotTemplate,
"needs": [
"telemetry"
],
@@ -71,6 +77,13 @@ define([
"throttle",
"PLOT_FIXED_DURATION"
]
},
{
"key": "PlotOptionsController",
"implementation": PlotOptionsController,
"depends": [
"$scope"
]
}
],
"constants": [
@@ -86,6 +99,12 @@ define([
"category": "view",
"implementation": PlotViewPolicy
}
],
"representations": [
{
"key": "plot-options-browse",
"template": plotOptionsBrowseTemplate
}
]
}
});

View File

@@ -0,0 +1,76 @@
<!--
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.
-->
<style>
.l-inspect .l-inspector-part .no-margin .form {
margin-left: 0;
}
.reduced-min-width .form .form-row > .label {
min-width: 80px;
}
</style>
<div ng-controller="PlotOptionsController" class="flex-elem grows l-inspector-part">
<em class="t-inspector-part-header" title="Display properties for this object">Display</em>
<mct-form
ng-model="configuration.plot.xAxis"
structure="xAxisForm"
name="xAxisFormState"
class="flex-elem l-flex-row no-validate no-margin reduced-min-width">
</mct-form>
<mct-form
ng-model="configuration.plot.yAxis"
structure="yAxisForm"
name="yAxisFormState"
class="flex-elem l-flex-row no-validate no-margin reduced-min-width">
</mct-form>
<div class="section-header ng-binding ng-scope">
Plot Series
</div>
<ul class="first flex-elem grows vscroll">
<ul class="tree">
<li ng-repeat="child in children">
<span ng-controller="ToggleController as toggle">
<span ng-controller="TreeNodeController as treeNode">
<span class="tree-item menus-to-left">
<span
class='ui-symbol view-control flex-elem has-children'
ng-class="{ expanded: toggle.isActive() }"
ng-click="toggle.toggle(); treeNode.trackExpansion()">
</span>
<mct-representation
class="rep-object-label"
key="'label'"
mct-object="child">
</mct-representation>
</span>
</span>
<mct-form
ng-class="{hidden: !toggle.isActive()}"
ng-model="configuration.plot.series[$index]"
structure="plotSeriesForm"
name="plotOptionsState"
class="flex-elem l-flex-row l-controls-first no-validate">
</mct-form>
</span>
</li>
</ul>
</ul>
</div>

View File

@@ -0,0 +1,197 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define*/
define(
['./PlotOptionsForm'],
function (PlotOptionsForm) {
"use strict";
/**
* Notes on implementation of plot options
*
* Multiple y-axes will have to be handled with multiple forms as
* they will need to be stored on distinct model object
*
* Likewise plot series options per-child will need to be separate
* forms.
*/
/**
* The LayoutController is responsible for supporting the
* Layout view. It arranges frames according to saved configuration
* and provides methods for updating these based on mouse
* movement.
* @memberof platform/features/plot
* @constructor
* @param {Scope} $scope the controller's Angular scope
*/
function PlotOptionsController($scope) {
var self = this;
this.$scope = $scope;
this.domainObject = $scope.domainObject;
this.configuration = this.domainObject.getModel().configuration || {};
this.plotOptionsForm = new PlotOptionsForm();
this.composition = [];
this.watches = [];
/*
Listen for changes to the domain object and update the object's
children.
*/
this.mutationListener = this.domainObject.getCapability('mutation').listen(function(model) {
if (self.hasCompositionChanged(self.composition, model.composition)) {
self.updateChildren();
}
});
/*
Set form structures on scope
*/
$scope.plotSeriesForm = this.plotOptionsForm.plotSeriesForm;
$scope.xAxisForm = this.plotOptionsForm.xAxisForm;
$scope.yAxisForm = this.plotOptionsForm.yAxisForm;
$scope.$on("$destroy", function() {
//Clean up any listeners on destruction of controller
self.mutationListener();
});
this.defaultConfiguration();
this.updateChildren();
/*
* Setup a number of watches for changes to form values. On
* change, update the model configuration via mutation
*/
$scope.$watchCollection('configuration.plot.yAxis', function(newValue, oldValue){
self.updateConfiguration(newValue, oldValue);
});
$scope.$watchCollection('configuration.plot.xAxis', function(newValue, oldValue){
self.updateConfiguration(newValue, oldValue);
});
this.watchSeries();
}
/**
* Unregister all watches for series data (ie. the configuration for
* child objects)
* @private
*/
PlotOptionsController.prototype.clearSeriesWatches = function() {
this.watches.forEach(function(watch) {
watch();
});
this.watches = [];
};
/**
* Attach watches for each object in the plot's composition
* @private
*/
PlotOptionsController.prototype.watchSeries = function() {
var self = this;
this.clearSeriesWatches();
(self.$scope.children || []).forEach(function(child, index){
self.watches.push(
self.$scope.$watchCollection(
'configuration.plot.series[' + index + ']',
function(newValue, oldValue){
self.updateConfiguration(newValue, oldValue);
}
)
);
});
};
/**
* Determine whether the changes to the model that triggered a
* mutation event were purely compositional.
*
* @private
*/
PlotOptionsController.prototype.hasCompositionChanged = function(oldComposition, newComposition){
// Framed slightly strangely, but the boolean logic is
// easier to follow for the unchanged case.
var isUnchanged = oldComposition === newComposition ||
(
oldComposition.length === newComposition.length &&
oldComposition.every( function (currentValue, index) {
return newComposition[index] && currentValue === newComposition[index];
})
);
return !isUnchanged;
};
/**
* Default the plot options model
*
* @private
*/
PlotOptionsController.prototype.defaultConfiguration = function () {
this.configuration.plot = this.configuration.plot || {};
this.configuration.plot.xAxis = this.configuration.plot.xAxis || {};
this.configuration.plot.yAxis = this.configuration.plot.yAxis || {}; // y-axes will be associative array keyed on axis key
this.configuration.plot.series = this.configuration.plot.series || []; // series will be associative array keyed on sub-object id
this.$scope.configuration = this.configuration;
};
/**
* When a child is added to, or removed from a plot, update the
* plot options model
* @private
*/
PlotOptionsController.prototype.updateChildren = function() {
var self = this;
this.domainObject.useCapability('composition').then(function(children){
self.$scope.children = children;
self.composition = self.domainObject.getModel().composition;
children.forEach(function(child, index){
self.configuration.plot.series[index] =
self.configuration.plot.series[index] || {'id': child.getId()};
});
self.watchSeries();
});
};
/**
* On changes to the form, update the configuration on the domain
* object
* @private
*/
PlotOptionsController.prototype.updateConfiguration = function() {
var self = this;
this.domainObject.useCapability('mutation', function(model){
model.configuration = model.configuration || {};
model.configuration.plot = self.configuration.plot;
});
};
return PlotOptionsController;
}
);

View File

@@ -0,0 +1,146 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define*/
define(
[],
function () {
"use strict";
/**
* A class for encapsulating structure and behaviour of the plot
* options form
* @memberOf platform/features/plot
* @param topic
* @constructor
*/
function PlotOptionsForm() {
/*
Defined below are the form structures for the plot options.
*/
this.xAxisForm = {
'name':'x-axis',
'sections': [{
'name': 'x-axis',
'rows': [
{
'name': 'Domain',
'control': 'select',
'key': 'key',
'options': [
{'name':'scet', 'value': 'scet'},
{'name':'sclk', 'value': 'sclk'},
{'name':'lst', 'value': 'lst'}
]
}
]
}]};
this.yAxisForm = {
'name':'y-axis',
'sections': [{
// Will need to be repeated for each y-axis, with a
// distinct name for each. Ideally the name of the axis
// itself.
'name': 'y-axis',
'rows': [
{
'name': 'Autoscale',
'control': 'checkbox',
'key': 'autoscale'
},
{
'name': 'Min',
'control': 'textfield',
'key': 'min',
'pattern': '[0-9]'
},
{
'name': 'Max',
'control': 'textfield',
'key': 'max',
'pattern': '[0-9]'
},
{
'name': 'Range',
'control': 'select',
'key': 'key',
'options': [
{'name':'eu', 'value': 'eu'},
{'name':'dn', 'value': 'dn'},
{'name':'status', 'value': 'status'}
]
}
]
}]
};
this.plotSeriesForm = {
'name':'Series Options',
'sections': [
{
rows: [
{
'name': 'Color',
'control': 'color',
'key': 'color'
}]
},
{
'rows':[
{
'name': 'Markers',
'control': 'checkbox',
'key': 'markers'
}
]
},
{
'rows':[
{
'name': 'No Line',
'control': 'radio',
'key': 'lineType',
'value': 'noLine'
},
{
'name': 'Step Line',
'control': 'radio',
'key': 'lineType',
'value': 'stepLine'
},
{
'name': 'Linear Line',
'control': 'radio',
'key': 'lineType',
'value': 'linearLine'
}
]
}
]
};
}
return PlotOptionsForm;
}
);

View File

@@ -0,0 +1,150 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,describe,it,expect,beforeEach,jasmine,xit*/
define(
['../src/PlotOptionsController'],
function (PlotOptionsController) {
"use strict";
describe("The Plot Options controller", function () {
var plotOptionsController,
mockDomainObject,
mockMutationCapability,
mockUseCapabilities,
mockCompositionCapability,
mockComposition,
mockUnlisten,
mockFormUnlisten,
mockChildOne,
mockChildTwo,
model,
mockScope;
beforeEach(function () {
model = {
composition: ['childOne']
};
mockChildOne = jasmine.createSpyObj('domainObject', [
'getId'
]);
mockChildOne.getId.andReturn('childOne');
mockChildTwo = jasmine.createSpyObj('childTwo', [
'getId'
]);
mockChildOne.getId.andReturn('childTwo');
mockCompositionCapability = jasmine.createSpyObj('compositionCapability', [
'then'
]);
mockComposition = [
mockChildOne
];
mockCompositionCapability.then.andCallFake(function (callback){
callback(mockComposition);
});
mockUseCapabilities = jasmine.createSpyObj('useCapabilities', [
'composition',
'mutation'
]);
mockUseCapabilities.composition.andReturn(mockCompositionCapability);
mockMutationCapability = jasmine.createSpyObj('mutationCapability', [
'listen'
]);
mockUnlisten = jasmine.createSpy('unlisten');
mockMutationCapability.listen.andReturn(mockUnlisten);
mockDomainObject = jasmine.createSpyObj('domainObject', [
'getModel',
'useCapability',
'getCapability'
]);
mockDomainObject.useCapability.andCallFake(function(capability){
return mockUseCapabilities[capability]();
});
mockDomainObject.getCapability.andReturn(mockMutationCapability);
mockDomainObject.getModel.andReturn(model);
mockScope = jasmine.createSpyObj('scope', [
'$on',
'$watchCollection'
]);
mockScope.domainObject = mockDomainObject;
function noop() {}
mockScope.$watchCollection.andReturn(noop);
plotOptionsController = new PlotOptionsController(mockScope);
});
it("sets form definitions on scope", function () {
expect(mockScope.xAxisForm).toBeDefined();
expect(mockScope.yAxisForm).toBeDefined();
expect(mockScope.plotSeriesForm).toBeDefined();
});
it("sets object children on scope", function () {
expect(mockScope.children).toBe(mockComposition);
});
it("on changes in object composition, updates the form", function () {
expect(mockMutationCapability.listen).toHaveBeenCalled();
expect(mockScope.children).toBe(mockComposition);
expect(mockScope.children.length).toBe(1);
mockComposition.push(mockChildTwo);
model.composition.push('childTwo');
mockMutationCapability.listen.mostRecentCall.args[0](model);
expect(mockScope.children).toBe(mockComposition);
expect(mockScope.children.length).toBe(2);
});
it("on changes in form values, updates the object model", function () {
var scopeConfiguration = mockScope.configuration,
model = mockDomainObject.getModel();
scopeConfiguration.plot.yAxis.autoScale = true;
scopeConfiguration.plot.yAxis.key = 'eu';
scopeConfiguration.plot.xAxis.key = 'lst';
expect(mockScope.$watchCollection).toHaveBeenCalled();
mockScope.$watchCollection.calls[0].args[1]();
expect(mockDomainObject.useCapability).toHaveBeenCalledWith('mutation', jasmine.any(Function));
mockDomainObject.useCapability.mostRecentCall.args[1](model);
expect(model.configuration.plot.yAxis.autoScale).toBe(true);
expect(model.configuration.plot.yAxis.key).toBe('eu');
expect(model.configuration.plot.xAxis.key).toBe('lst');
});
it("cleans up listeners on destruction of the controller", function () {
mockScope.$on.mostRecentCall.args[1]();
expect(mockUnlisten).toHaveBeenCalled();
});
});
}
);

View File

@@ -0,0 +1,50 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,describe,it,expect,beforeEach,jasmine,xit*/
define(
['../src/PlotOptionsForm'],
function (PlotOptionsForm) {
"use strict";
describe("The Plot Options form", function () {
var plotOptionsForm,
listener;
beforeEach(function () {
plotOptionsForm = new PlotOptionsForm();
});
it("defines form specs for x-axis, y-axis, and series data", function () {
expect(plotOptionsForm.xAxisForm).toBeDefined();
expect(plotOptionsForm.xAxisForm.sections).toBeDefined();
expect(plotOptionsForm.xAxisForm.sections[0].rows).toBeDefined();
expect(plotOptionsForm.xAxisForm.sections[0].rows.length).toBeGreaterThan(0);
expect(plotOptionsForm.yAxisForm).toBeDefined();
expect(plotOptionsForm.plotSeriesForm).toBeDefined();
});
});
}
);

View File

@@ -25,11 +25,13 @@ define([
"./src/RTEventListController",
"./src/directives/MCTRTDataTable",
"./src/policies/RTMessagesViewPolicy",
"text!./res/templates/rtmessages.html",
'legacyRegistry'
], function (
RTEventListController,
MCTRTDataTable,
RTMessagesViewPolicy,
rtmessagesTemplate,
legacyRegistry
) {
"use strict";
@@ -44,7 +46,7 @@ define([
"name": "RT Messages",
"glyph": "5",
"description": "Scrolling list of real time messages.",
"templateUrl": "templates/rtmessages.html",
"template": rtmessagesTemplate,
"needs": [
"telemetry"
],

View File

@@ -25,14 +25,14 @@
* Module defining MCTRTDataTable. Created by shale on 06/25/2015.
*/
define(
[],
function () {
['text!../../res/templates/mct-rt-data-table.html'],
function (dataTableTemplate) {
"use strict";
function MCTRTDataTable($window) {
return {
restrict: "E",
templateUrl: "platform/features/rtevents/res/templates/mct-rt-data-table.html",
template: dataTableTemplate,
scope: {
headers: "=",
rows: "=",

View File

@@ -23,9 +23,11 @@
define([
"./src/RTScrollingListController",
"text!./res/templates/rtscrolling.html",
'legacyRegistry'
], function (
RTScrollingListController,
rtscrollingTemplate,
legacyRegistry
) {
"use strict";
@@ -40,7 +42,7 @@ define([
"name": "Scrolling",
"glyph": "5",
"description": "Scrolling list of data values.",
"templateUrl": "templates/rtscrolling.html",
"template": rtscrollingTemplate,
"needs": [
"telemetry"
],

View File

@@ -23,9 +23,11 @@
define([
"./src/ScrollingListController",
"text!./res/templates/scrolling.html",
'legacyRegistry'
], function (
ScrollingListController,
scrollingTemplate,
legacyRegistry
) {
"use strict";
@@ -40,7 +42,7 @@ define([
"name": "Scrolling",
"glyph": "5",
"description": "Scrolling list of data values.",
"templateUrl": "templates/scrolling.html",
"template": scrollingTemplate,
"needs": [
"telemetry"
],

View File

@@ -23,9 +23,11 @@
define([
"text!./res/markup.html",
'legacyRegistry'
], function (
markupTemplate,
legacyRegistry
) {
"use strict";
@@ -45,7 +47,7 @@ define([
],
"views": [
{
"templateUrl": "markup.html",
"template": markupTemplate,
"name": "Static Markup",
"type": "static.markup",
"key": "static.markup"

View File

@@ -0,0 +1,125 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define*/
define([
"./src/directives/MCTTable",
"./src/controllers/TelemetryTableController",
"./src/controllers/TableOptionsController",
'../../commonUI/regions/src/Region',
'../../commonUI/browse/src/InspectorRegion',
"legacyRegistry"
], function (
MCTTable,
TelemetryTableController,
TableOptionsController,
Region,
InspectorRegion,
legacyRegistry
) {
"use strict";
/**
* Two region parts are defined here. One that appears only in browse
* mode, and one that appears only in edit mode. For not they both point
* to the same representation, but a different key could be used here to
* include a customized representation for edit mode.
*/
var tableInspector = new InspectorRegion(),
tableOptionsEditRegion = new Region({
name: "table-options",
title: "Table Options",
modes: ['edit'],
content: {
key: "table-options-edit"
}
});
tableInspector.addRegion(tableOptionsEditRegion);
legacyRegistry.register("platform/features/table", {
"extensions": {
"types": [
{
"key": "table",
"name": "Table",
"glyph": "\ue605",
"description": "A table for displaying telemetry data",
"features": "creation",
"delegates": [
"telemetry"
],
"inspector": tableInspector,
"contains": [
{
"has": "telemetry"
}
],
"model": {
"composition": []
},
"views": [
"table"
]
}
],
"controllers": [
{
"key": "TelemetryTableController",
"implementation": TelemetryTableController,
"depends": ["$scope", "telemetryHandler", "telemetryFormatter"]
},
{
"key": "TableOptionsController",
"implementation": TableOptionsController,
"depends": ["$scope"]
}
],
"views": [
{
"name": "Table",
"key": "table",
"glyph": "\ue605",
"templateUrl": "templates/table.html",
"needs": [
"telemetry"
],
"delegation": true,
"editable": true
}
],
"directives": [
{
"key": "mctTable",
"implementation": MCTTable,
"depends": ["$timeout"]
}
],
"representations": [
{
"key": "table-options-edit",
"templateUrl": "templates/table-options-edit.html"
}
]
}
});
});

View File

@@ -0,0 +1,64 @@
<div class="l-view-section scrolling"
style="overflow: auto;"
>
<table class="filterable"
ng-style="overrideRowPositioning && {
height: totalHeight + 'px',
'table-layout': overrideRowPositioning ? 'fixed' : 'auto'
}">
<thead>
<tr>
<th ng-repeat="header in displayHeaders"
ng-style="overrideRowPositioning && {
width: columnWidths[$index] + 'px',
'max-width': columnWidths[$index] + 'px',
overflow: 'none',
'box-sizing': 'border-box'
}"
ng-class="[
enableSort ? 'sortable' : '',
sortColumn === header ? 'sort' : '',
sortDirection || ''
].join(' ')"
ng-click="toggleSort(header)">
{{ header }}
</th>
</tr>
<tr ng-if="enableFilter" class="s-filters">
<th ng-repeat="header in displayHeaders"
ng-style="overrideRowPositioning && {
width: columnWidths[$index] + 'px',
'max-width': columnWidths[$index] + 'px',
overflow: 'none',
'box-sizing': 'border-box'
}">
<input type="text"
ng-model="filters[header]"/>
</th>
</tr>
</thead>
<tbody ng-style="overrideRowPositioning ? '' : {
'opacity': '0.0'
}">
<tr ng-repeat="visibleRow in visibleRows track by visibleRow.rowIndex"
ng-style="overrideRowPositioning && {
position: 'absolute',
top: visibleRow.offsetY + 'px',
}">
<td ng-repeat="header in displayHeaders"
ng-style="overrideRowPositioning && {
width: columnWidths[$index] + 'px',
'white-space': 'nowrap',
'max-width': columnWidths[$index] + 'px',
overflow: 'hidden',
'box-sizing': 'border-box'
}"
class="{{visibleRow.contents[header].cssClass}}">
{{ visibleRow.contents[header].text }}
</td>
</tr>
</tbody>
</table>
</div>

View File

@@ -0,0 +1,30 @@
<!--
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.
-->
<div ng-controller="TableOptionsController" class="flex-elem grows l-inspector-part">
<em class="t-inspector-part-header" title="Display properties for this object">Display</em>
<mct-form
ng-model="configuration.table.columns"
structure="columnsForm"
name="columnsFormState"
class="flex-elem l-flex-row no-validate no-margin reduced-min-width">
</mct-form>
</div>

View File

@@ -0,0 +1,8 @@
<div ng-controller="TelemetryTableController">
<mct-table
headers="headers"
rows="rows"
enableFilter="true"
enableSort="true">
</mct-table>
</div>

View File

@@ -0,0 +1,64 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,moment*/
/**
* Module defining DomainColumn.
*/
define(
[],
function () {
"use strict";
/**
* A column which will report telemetry domain values
* (typically, timestamps.) Used by the ScrollingListController.
*
* @memberof platform/features/table
* @constructor
* @param domainMetadata an object with the machine- and human-
* readable names for this domain (in `key` and `name`
* fields, respectively.)
* @param {TelemetryFormatter} telemetryFormatter the telemetry
* formatting service, for making values human-readable.
*/
function DomainColumn(domainMetadata, telemetryFormatter) {
this.domainMetadata = domainMetadata;
this.telemetryFormatter = telemetryFormatter;
}
DomainColumn.prototype.getTitle = function () {
return this.domainMetadata.name;
};
DomainColumn.prototype.getValue = function (domainObject, datum) {
return {
text: this.telemetryFormatter.formatDomainValue(
datum[this.domainMetadata.key],
this.domainMetadata.format
)
};
};
return DomainColumn;
}
);

View File

@@ -0,0 +1,54 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,Promise*/
/**
* Module defining NameColumn. Created by vwoeltje on 11/18/14.
*/
define(
[],
function () {
"use strict";
/**
* A column which will report the name of the domain object
* which exposed specific telemetry values.
*
* @memberof platform/features/table
* @constructor
*/
function NameColumn() {
}
NameColumn.prototype.getTitle = function () {
return "Name";
};
NameColumn.prototype.getValue = function (domainObject) {
return {
text: domainObject.getModel().name
};
};
return NameColumn;
}
);

View File

@@ -0,0 +1,67 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,Promise*/
/**
* Module defining DomainColumn. Created by vwoeltje on 11/18/14.
*/
define(
[],
function () {
"use strict";
/**
* A column which will report telemetry range values
* (typically, measurements.) Used by the ScrollingListController.
*
* @memberof platform/features/table
* @constructor
* @param rangeMetadata an object with the machine- and human-
* readable names for this range (in `key` and `name`
* fields, respectively.)
* @param {TelemetryFormatter} telemetryFormatter the telemetry
* formatting service, for making values human-readable.
*/
function RangeColumn(rangeMetadata, telemetryFormatter) {
this.rangeMetadata = rangeMetadata;
this.telemetryFormatter = telemetryFormatter;
}
RangeColumn.prototype.getTitle = function () {
return this.rangeMetadata.name;
};
RangeColumn.prototype.getValue = function (domainObject, datum) {
var range = this.rangeMetadata.key,
limit = domainObject.getCapability('limit'),
value = isNaN(datum[range]) ? datum[range] : parseFloat(datum[range]),
alarm = limit && limit.evaluate(datum, range);
return {
cssClass: alarm && alarm.cssClass,
text: typeof(value) === 'undefined' ? undefined : this.telemetryFormatter.formatRangeValue(value)
};
};
return RangeColumn;
}
);

View File

@@ -0,0 +1,180 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,moment*/
define(
[
'./DomainColumn',
'./RangeColumn',
'./NameColumn'
],
function (DomainColumn, RangeColumn, NameColumn) {
"use strict";
/**
* Class that manages table metadata, state, and contents.
* @memberof platform/features/table
* @param domainObject
* @constructor
*/
function TableConfiguration(domainObject, telemetryFormatter) {
this.domainObject = domainObject;
this.columns = [];
this.telemetryFormatter = telemetryFormatter;
}
/**
* Build column definitions based on supplied telemetry metadata
* @param metadata Metadata describing the domains and ranges available
* @returns {TableConfiguration} This object
*/
TableConfiguration.prototype.buildColumns = function(metadata) {
var self = this;
this.columns = [];
if (metadata) {
if (metadata.length > 1){
self.addColumn(new NameColumn(), 0);
}
metadata.forEach(function (metadatum) {
//Push domains first
(metadatum.domains || []).forEach(function (domainMetadata) {
self.addColumn(new DomainColumn(domainMetadata, self.telemetryFormatter));
});
(metadatum.ranges || []).forEach(function (rangeMetadata) {
self.addColumn(new RangeColumn(rangeMetadata, self.telemetryFormatter));
});
});
}
return this;
};
/**
* Add a column definition to this Table
* @param {RangeColumn | DomainColumn | NameColumn} column
* @param {Number} [index] Where the column should appear (will be
* affected by column filtering)
*/
TableConfiguration.prototype.addColumn = function (column, index) {
if (typeof index === 'undefined') {
this.columns.push(column);
} else {
this.columns.splice(index, 0, column);
}
};
/**
* @private
* @param column
* @returns {*|string}
*/
TableConfiguration.prototype.getColumnTitle = function (column) {
return column.getTitle();
};
/**
* Get a simple list of column titles
* @returns {Array} The titles of the columns
*/
TableConfiguration.prototype.getHeaders = function() {
var self = this;
return this.columns.map(function (column, i){
return self.getColumnTitle(column) || 'Column ' + (i + 1);
});
};
/**
* Retrieve and format values for a given telemetry datum.
* @param telemetryObject The object that the telemetry data is
* associated with
* @param datum The telemetry datum to retrieve values from
* @returns {Object} Key value pairs where the key is the column
* title, and the value is the formatted value from the provided datum.
*/
TableConfiguration.prototype.getRowValues = function(telemetryObject, datum) {
var self = this;
return this.columns.reduce(function(rowObject, column, i){
var columnTitle = self.getColumnTitle(column) || 'Column ' + (i + 1),
columnValue = column.getValue(telemetryObject, datum);
if (columnValue !== undefined && columnValue.text === undefined){
columnValue.text = '';
}
// Don't replace something with nothing.
// This occurs when there are multiple columns with the
// column title
if (rowObject[columnTitle] === undefined || rowObject[columnTitle].text === undefined || rowObject[columnTitle].text.length === 0) {
rowObject[columnTitle] = columnValue;
}
return rowObject;
}, {});
};
/**
* @private
*/
TableConfiguration.prototype.defaultColumnConfiguration = function () {
return ((this.domainObject.getModel().configuration || {}).table || {}).columns || {};
};
/**
* Set the established configuration on the domain object
* @private
*/
TableConfiguration.prototype.saveColumnConfiguration = function (columnConfig) {
this.domainObject.useCapability('mutation', function (model) {
model.configuration = model.configuration || {};
model.configuration.table = model.configuration.table || {};
model.configuration.table.columns = columnConfig;
});
};
/**
* As part of the process of building the table definition, extract
* configuration from column definitions.
* @returns {Object} A configuration object consisting of key-value
* pairs where the key is the column title, and the value is a
* boolean indicating whether the column should be shown.
*/
TableConfiguration.prototype.getColumnConfiguration = function() {
var configuration = {},
//Use existing persisted config, or default it
defaultConfig = this.defaultColumnConfiguration();
/**
* For each column header, define a configuration value
* specifying whether the column is visible or not. Default to
* existing (persisted) configuration if available
*/
this.getHeaders().forEach(function(columnTitle) {
configuration[columnTitle] = typeof defaultConfig[columnTitle] === 'undefined' ? true : defaultConfig[columnTitle];
});
return configuration;
};
return TableConfiguration;
}
);

View File

@@ -0,0 +1,354 @@
/*global define*/
define(
[],
function () {
"use strict";
function MCTTableController($scope, $timeout, element) {
var self = this;
this.$scope = $scope;
this.element = element;
this.$timeout = $timeout;
this.maxDisplayRows = 50;
$scope.visibleRows = [];
$scope.overrideRowPositioning = false;
/**
* Set default values for optional parameters on a given scope
*/
function setDefaults($scope) {
if (typeof $scope.enableFilter === 'undefined') {
$scope.enableFilter = true;
$scope.filters = {};
}
if (typeof $scope.enableSort === 'undefined') {
$scope.enableSort = true;
$scope.sortColumn = undefined;
$scope.sortDirection = undefined;
}
}
setDefaults($scope);
element.find('div').on('scroll', this.onScroll.bind(this));
$scope.toggleSort = function (key) {
if (!$scope.enableSort) {
return;
}
if ($scope.sortColumn !== key) {
$scope.sortColumn = key;
$scope.sortDirection = 'asc';
} else if ($scope.sortDirection === 'asc') {
$scope.sortDirection = 'desc';
} else if ($scope.sortDirection === 'desc') {
$scope.sortColumn = undefined;
$scope.sortDirection = undefined;
}
self.updateRows($scope.rows);
};
$scope.$watchCollection('filters', function () {
self.updateRows(self.$scope.rows);
});
$scope.$watchCollection('headers', this.updateHeaders.bind(this));
$scope.$watchCollection('rows', this.updateRows.bind(this));
}
/**
* On scroll, calculate which rows indexes are visible and
* ensure that an equal number of rows are preloaded for
* scrolling in either direction.
*/
MCTTableController.prototype.onScroll = function (event) {
var self = this,
topScroll = event.target.scrollTop,
bottomScroll = topScroll + event.target.offsetHeight,
firstVisible,
lastVisible,
totalVisible,
numberOffscreen,
start,
end;
if (this.$scope.displayRows.length < this.maxDisplayRows) {
return;
}
if (topScroll < this.$scope.headerHeight) {
firstVisible = 0;
} else {
firstVisible = Math.floor(
(topScroll - this.$scope.headerHeight) / this.$scope.rowHeight
);
}
lastVisible = Math.ceil(
(bottomScroll - this.$scope.headerHeight) / this.$scope.rowHeight
);
totalVisible = lastVisible - firstVisible;
numberOffscreen = this.maxDisplayRows - totalVisible;
start = firstVisible - Math.floor(numberOffscreen / 2);
end = lastVisible + Math.ceil(numberOffscreen / 2);
if (start < 0) {
start = 0;
end = this.$scope.visibleRows.length - 1;
} else if (end >= this.$scope.displayRows.length) {
end = this.$scope.displayRows.length - 1;
start = end - this.maxDisplayRows + 1;
}
if (this.$scope.visibleRows[0].rowIndex === start &&
this.$scope.visibleRows[this.$scope.visibleRows.length-1]
.rowIndex === end) {
return; // don't update if no changes are required.
}
this.$scope.visibleRows = this.$scope.displayRows.slice(start, end)
.map(function(row, i) {
return {
rowIndex: start + i,
offsetY: ((start + i) * self.$scope.rowHeight) +
self.$scope.headerHeight,
contents: row
};
});
this.$scope.$digest();
};
/**
* Update table headers with new headers. If filtering is
* enabled, reset filters. If sorting is enabled, reset
* sorting.
*/
MCTTableController.prototype.updateHeaders = function (newHeaders) {
if (!newHeaders){
return;
}
this.$scope.displayHeaders = newHeaders;
if (this.$scope.enableFilter) {
this.$scope.filters = {};
}
// Reset column sort information unless the new headers
// contain the column current sorted on.
if (this.$scope.enableSort && newHeaders.indexOf(this.$scope.sortColumn) === -1) {
this.$scope.sortColumn = undefined;
this.$scope.sortDirection = undefined;
}
this.updateRows(this.$scope.rows);
};
/**
* Read styles from the DOM and use them to calculate offsets
* for individual rows.
*/
MCTTableController.prototype.setElementSizes = function () {
var self = this,
thead = this.element.find('thead'),
tbody = this.element.find('tbody'),
firstRow = tbody.find('tr'),
column = firstRow.find('td'),
headerHeight = thead.prop('offsetHeight'),
//row height is hard-coded for now.
rowHeight = 20,
overallHeight = headerHeight + (rowHeight * (this.$scope.displayRows ? this.$scope.displayRows.length - 1 : 0));
this.$scope.columnWidths = [];
while (column.length) {
this.$scope.columnWidths.push(column.prop('offsetWidth'));
column = column.next();
}
this.$scope.headerHeight = headerHeight;
this.$scope.rowHeight = rowHeight;
this.$scope.totalHeight = overallHeight;
this.$scope.visibleRows = this.$scope.displayRows.slice(0, this.maxDisplayRows).map(function(row, i) {
return {
rowIndex: i,
offsetY: (i * self.$scope.rowHeight) + self.$scope.headerHeight,
contents: row
};
});
this.$scope.overrideRowPositioning = true;
};
/**
* Returns a new array which is a result of applying the sort
* criteria defined in $scope.
*
* Does not modify the array that was passed in.
*/
MCTTableController.prototype.sortRows = function(rowsToSort) {
/**
* Compare two variables, returning a number that represents
* which is larger. Similar to the default array sort
* comparator, but does not coerce all values to string before
* conversion. Strings are lowercased before comparison.
*/
function genericComparator(a, b) {
if (typeof a === "string" && typeof b === "string") {
a = a.toLowerCase();
b = b.toLowerCase();
}
if (a < b) {
return -1;
}
if (a > b) {
return 1;
}
return 0;
}
if (!this.$scope.sortColumn || !this.$scope.sortDirection) {
return rowsToSort;
}
var sortKey = this.$scope.sortColumn,
sortDirectionMultiplier;
if (this.$scope.sortDirection === 'asc') {
sortDirectionMultiplier = 1;
} else if (this.$scope.sortDirection === 'desc') {
sortDirectionMultiplier = -1;
}
return rowsToSort.slice(0).sort(function(a, b) {
//If the values to compare can be compared as
// numbers, do so. String comparison of number
// values can cause inconsistencies
var valA = isNaN(a[sortKey].text) ? a[sortKey].text : parseFloat(a[sortKey].text),
valB = isNaN(b[sortKey].text) ? b[sortKey].text : parseFloat(b[sortKey].text);
return genericComparator(valA, valB) *
sortDirectionMultiplier;
});
};
/**
* Returns an object which contains the largest values
* for each key in the given set of rows. This is used to
* pre-calculate optimal column sizes without having to render
* every row.
*/
MCTTableController.prototype.findLargestRow = function(rows) {
var largestRow = rows.reduce(function (largestRow, row) {
Object.keys(row).forEach(function (key) {
var currentColumn = row[key].text,
currentColumnLength =
(currentColumn && currentColumn.length) ?
currentColumn.length :
currentColumn,
largestColumn = largestRow[key].text,
largestColumnLength =
(largestColumn && largestColumn.length) ?
largestColumn.length :
largestColumn;
if (currentColumnLength > largestColumnLength) {
largestRow[key] = JSON.parse(JSON.stringify(row[key]));
}
});
return largestRow;
}, JSON.parse(JSON.stringify(rows[0] || {})));
// Pad with characters to accomodate variable-width fonts,
// and remove characters that would allow word-wrapping.
largestRow = JSON.parse(JSON.stringify(largestRow));
Object.keys(largestRow).forEach(function(key) {
var padCharacters,
i;
largestRow[key].text = String(largestRow[key].text);
padCharacters = largestRow[key].text.length / 10;
for (i = 0; i < padCharacters; i++) {
largestRow[key].text = largestRow[key].text + 'W';
}
largestRow[key].text = largestRow[key].text
.replace(/[ \-_]/g, 'W');
});
return largestRow;
};
MCTTableController.prototype.resize = function (){
var largestRow = this.findLargestRow(this.$scope.displayRows);
this.$scope.visibleRows = [
{
rowIndex: 0,
offsetY: undefined,
contents: largestRow
}
];
this.$timeout(this.setElementSizes.bind(this));
};
/**
* Update rows with new data. If filtering is enabled, rows
* will be sorted before display.
*/
MCTTableController.prototype.updateRows = function (newRows) {
var displayRows = newRows;
this.$scope.visibleRows = [];
this.$scope.overrideRowPositioning = false;
if (!this.$scope.displayHeaders) {
return;
}
if (this.$scope.enableFilter) {
displayRows = this.filterRows(displayRows);
}
if (this.$scope.enableSort) {
displayRows = this.sortRows(displayRows);
}
this.$scope.displayRows = displayRows;
this.resize();
};
/**
* Filter rows.
*/
MCTTableController.prototype.filterRows = function(rowsToFilter) {
var filters = {},
self = this;
/**
* Returns true if row matches all filters.
*/
function matchRow(filters, row) {
return Object.keys(filters).every(function(key) {
if (!row[key]) {
return false;
}
var testVal = String(row[key].text).toLowerCase();
return testVal.indexOf(filters[key]) !== -1;
});
}
if (!Object.keys(this.$scope.filters).length) {
return rowsToFilter;
}
Object.keys(this.$scope.filters).forEach(function(key) {
if (!self.$scope.filters[key]) {
return;
}
filters[key] = self.$scope.filters[key].toLowerCase();
});
return rowsToFilter.filter(matchRow.bind(null, filters));
};
return MCTTableController;
}
);

View File

@@ -0,0 +1,94 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define*/
define(
[],
function () {
"use strict";
/**
* Notes on implementation of plot options
*
* Multiple y-axes will have to be handled with multiple forms as
* they will need to be stored on distinct model object
*
* Likewise plot series options per-child will need to be separate
* forms.
*/
/**
* The LayoutController is responsible for supporting the
* Layout view. It arranges frames according to saved configuration
* and provides methods for updating these based on mouse
* movement.
* @memberof platform/features/plot
* @constructor
* @param {Scope} $scope the controller's Angular scope
*/
function TableOptionsController($scope) {
var self = this;
this.$scope = $scope;
this.domainObject = $scope.domainObject;
$scope.columnsForm = {};
this.domainObject.getCapability('mutation').listen(function (model) {
self.populateForm(model);
});
$scope.$watchCollection('configuration.table.columns', function(columns){
if (columns){
self.domainObject.useCapability('mutation', function(model) {
model.configuration.table.columns = columns;
});
self.domainObject.getCapability('persistence').persist();
}
});
}
TableOptionsController.prototype.populateForm = function (model) {
var columnsDefinition = (((model.configuration || {}).table || {}).columns || {}),
rows = [];
this.$scope.columnsForm = {
'name':'Columns',
'sections': [{
'name': 'Columns',
'rows': rows
}]};
Object.keys(columnsDefinition).forEach(function (key){
rows.push({
'name': key,
'control': 'checkbox',
'key': key
});
});
this.$scope.configuration = JSON.parse(JSON.stringify(model.configuration));
};
return TableOptionsController;
}
);

View File

@@ -0,0 +1,189 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define*/
/**
* This bundle adds a table view for displaying telemetry data.
* @namespace platform/features/table
*/
define(
[
'../TableConfiguration'
],
function (TableConfiguration) {
"use strict";
/**
* The TableController is responsible for getting data onto the page
* in the table widget. This includes handling composition,
* configuration, and telemetry subscriptions.
* @memberof platform/features/table
* @param $scope
* @param telemetryHandler
* @param telemetryFormatter
* @constructor
*/
function TelemetryTableController(
$scope,
telemetryHandler,
telemetryFormatter
) {
var self = this;
this.$scope = $scope;
this.columns = {}; //Range and Domain columns
this.handle = undefined;
//this.pending = false;
this.telemetryHandler = telemetryHandler;
this.table = new TableConfiguration($scope.domainObject, telemetryFormatter);
this.changeListeners = [];
$scope.rows = [];
// Subscribe to telemetry when a domain object becomes available
this.$scope.$watch('domainObject', function(domainObject){
if (!domainObject)
return;
self.subscribe();
self.registerChangeListeners();
});
// Unsubscribe when the plot is destroyed
this.$scope.$on("$destroy", this.destroy.bind(this));
}
TelemetryTableController.prototype.registerChangeListeners = function() {
//Defer registration of change listeners until domain object is
// available in order to avoid race conditions
this.changeListeners.forEach(function (listener) {
return listener && listener();
});
this.changeListeners = [];
// When composition changes, re-subscribe to the various
// telemetry subscriptions
this.changeListeners.push(this.$scope.$watchCollection('domainObject.getModel().composition', this.subscribe.bind(this)));
//Change of bounds in time conductor
this.changeListeners.push(this.$scope.$on('telemetry:display:bounds', this.subscribe.bind(this)));
};
/**
* Release the current subscription (called when scope is destroyed)
*/
TelemetryTableController.prototype.destroy = function () {
if (this.handle) {
this.handle.unsubscribe();
this.handle = undefined;
}
};
/**
Create a new subscription. This is called when
*/
TelemetryTableController.prototype.subscribe = function() {
if (this.handle) {
this.handle.unsubscribe();
}
this.$scope.rows = [];
//Noop because not supporting realtime data right now
function noop(){
}
this.handle = this.$scope.domainObject && this.telemetryHandler.handle(
this.$scope.domainObject,
noop,
true // Lossless
);
this.handle.request({}, this.addHistoricalData.bind(this));
this.setup();
};
/**
* Add any historical data available
*/
TelemetryTableController.prototype.addHistoricalData = function(domainObject, series) {
var i;
for (i=0; i < series.getPointCount(); i++) {
this.updateRows(domainObject, this.handle.makeDatum(domainObject, series, i));
}
};
/**
* Setup table columns based on domain object metadata
*/
TelemetryTableController.prototype.setup = function() {
var handle = this.handle,
table = this.table,
self = this;
if (handle) {
handle.promiseTelemetryObjects().then(function (objects) {
table.buildColumns(handle.getMetadata());
self.filterColumns();
// When table column configuration changes, (due to being
// selected or deselected), filter columns appropriately.
self.changeListeners.push(self.$scope.$watchCollection(
'domainObject.getModel().configuration.table.columns',
self.filterColumns.bind(self)
));
});
}
};
/**
* Add data to rows
* @param object The object for which data is available (table may
* be composed of multiple objects)
* @param datum The data received from the telemetry source
*/
TelemetryTableController.prototype.updateRows = function (object, datum) {
this.$scope.rows.push(this.table.getRowValues(object, datum));
};
/**
* When column configuration changes, update the visible headers
* accordingly.
*/
TelemetryTableController.prototype.filterColumns = function (columnConfig) {
if (!columnConfig){
columnConfig = this.table.getColumnConfiguration();
this.table.saveColumnConfiguration(columnConfig);
}
//Populate headers with visible columns (determined by configuration)
this.$scope.headers = Object.keys(columnConfig).filter(function(column) {
return columnConfig[column];
});
};
return TelemetryTableController;
}
);

View File

@@ -0,0 +1,24 @@
/*global define*/
define(
["../controllers/MCTTableController"],
function (MCTTableController) {
"use strict";
function MCTTable($timeout) {
return {
restrict: "E",
templateUrl: "platform/features/table/res/templates/mct-data-table.html",
controller: ['$scope', '$timeout', '$element', MCTTableController],
scope: {
headers: "=",
rows: "=",
enableFilter: "=?",
enableSort: "=?"
},
};
}
return MCTTable;
}
);

View File

@@ -0,0 +1,84 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,describe,it,expect,beforeEach,waitsFor,jasmine,xit*/
/**
* MergeModelsSpec. Created by vwoeltje on 11/6/14.
*/
define(
["../src/DomainColumn"],
function (DomainColumn) {
"use strict";
var TEST_DOMAIN_VALUE = "some formatted domain value";
describe("A domain column", function () {
var mockDataSet,
testMetadata,
mockFormatter,
column;
beforeEach(function () {
mockDataSet = jasmine.createSpyObj(
"data",
[ "getDomainValue" ]
);
mockFormatter = jasmine.createSpyObj(
"formatter",
[ "formatDomainValue", "formatRangeValue" ]
);
testMetadata = {
key: "testKey",
name: "Test Name"
};
mockFormatter.formatDomainValue.andReturn(TEST_DOMAIN_VALUE);
column = new DomainColumn(testMetadata, mockFormatter);
});
it("reports a column header from domain metadata", function () {
expect(column.getTitle()).toEqual("Test Name");
});
xit("looks up data from a data set", function () {
column.getValue(undefined, mockDataSet, 42);
expect(mockDataSet.getDomainValue)
.toHaveBeenCalledWith(42, "testKey");
});
xit("formats domain values as time", function () {
mockDataSet.getDomainValue.andReturn(402513731000);
// Should have just given the value the formatter gave
expect(column.getValue(undefined, mockDataSet, 42).text)
.toEqual(TEST_DOMAIN_VALUE);
// Make sure that service interactions were as expected
expect(mockFormatter.formatDomainValue)
.toHaveBeenCalledWith(402513731000);
expect(mockFormatter.formatRangeValue)
.not.toHaveBeenCalled();
});
});
}
);

View File

@@ -0,0 +1,58 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,describe,it,expect,beforeEach,waitsFor,jasmine*/
/**
* MergeModelsSpec. Created by vwoeltje on 11/6/14.
*/
define(
["../src/NameColumn"],
function (NameColumn) {
"use strict";
describe("A name column", function () {
var mockDomainObject,
column;
beforeEach(function () {
mockDomainObject = jasmine.createSpyObj(
"domainObject",
[ "getModel" ]
);
mockDomainObject.getModel.andReturn({
name: "Test object name"
});
column = new NameColumn();
});
it("reports a column header", function () {
expect(column.getTitle()).toEqual("Name");
});
it("looks up name from an object's model", function () {
expect(column.getValue(mockDomainObject).text)
.toEqual("Test object name");
});
});
}
);

View File

@@ -0,0 +1,76 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,describe,it,expect,beforeEach,waitsFor,jasmine,xit*/
/**
* MergeModelsSpec. Created by vwoeltje on 11/6/14.
*/
define(
["../src/RangeColumn"],
function (RangeColumn) {
"use strict";
var TEST_RANGE_VALUE = "some formatted range value";
describe("A range column", function () {
var testDatum,
testMetadata,
mockFormatter,
mockDomainObject,
column;
beforeEach(function () {
testDatum = { testKey: 123, otherKey: 456 };
mockFormatter = jasmine.createSpyObj(
"formatter",
[ "formatDomainValue", "formatRangeValue" ]
);
testMetadata = {
key: "testKey",
name: "Test Name"
};
mockDomainObject = jasmine.createSpyObj(
"domainObject",
[ "getModel", "getCapability" ]
);
mockFormatter.formatRangeValue.andReturn(TEST_RANGE_VALUE);
column = new RangeColumn(testMetadata, mockFormatter);
});
it("reports a column header from range metadata", function () {
expect(column.getTitle()).toEqual("Test Name");
});
it("formats range values as numbers", function () {
expect(column.getValue(mockDomainObject, testDatum).text)
.toEqual(TEST_RANGE_VALUE);
// Make sure that service interactions were as expected
expect(mockFormatter.formatRangeValue)
.toHaveBeenCalledWith(testDatum.testKey);
expect(mockFormatter.formatDomainValue)
.not.toHaveBeenCalled();
});
});
}
);

View File

@@ -0,0 +1,197 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,describe,it,expect,beforeEach,waitsFor,jasmine,xit*/
define(
[
"../src/TableConfiguration",
"../src/DomainColumn"
],
function (Table, DomainColumn) {
"use strict";
describe("A table", function () {
var mockDomainObject,
mockTelemetryFormatter,
table,
mockModel;
beforeEach(function () {
mockDomainObject = jasmine.createSpyObj('domainObject',
['getModel', 'useCapability', 'getCapability']
);
mockModel = {};
mockDomainObject.getModel.andReturn(mockModel);
mockTelemetryFormatter = jasmine.createSpyObj('telemetryFormatter',
[
'formatDomainValue',
'formatRangeValue'
]);
mockTelemetryFormatter.formatDomainValue.andCallFake(function(valueIn){
return valueIn;
});
mockTelemetryFormatter.formatRangeValue.andCallFake(function(valueIn){
return valueIn;
});
table = new Table(mockDomainObject, mockTelemetryFormatter);
});
it("Add column with no index adds new column to the end", function () {
var firstColumn = {title: 'First Column'},
secondColumn = {title: 'Second Column'},
thirdColumn = {title: 'Third Column'};
table.addColumn(firstColumn);
table.addColumn(secondColumn);
table.addColumn(thirdColumn);
expect(table.columns).toBeDefined();
expect(table.columns.length).toBe(3);
expect(table.columns[0]).toBe(firstColumn);
expect(table.columns[1]).toBe(secondColumn);
expect(table.columns[2]).toBe(thirdColumn);
});
it("Add column with index adds new column at the specified" +
" position", function () {
var firstColumn = {title: 'First Column'},
secondColumn = {title: 'Second Column'},
thirdColumn = {title: 'Third Column'};
table.addColumn(firstColumn);
table.addColumn(thirdColumn);
table.addColumn(secondColumn, 1);
expect(table.columns).toBeDefined();
expect(table.columns.length).toBe(3);
expect(table.columns[0]).toBe(firstColumn);
expect(table.columns[1]).toBe(secondColumn);
expect(table.columns[2]).toBe(thirdColumn);
});
describe("Building columns from telemetry metadata", function() {
var metadata = [{
ranges: [
{
name: 'Range 1',
key: 'range1'
},
{
name: 'Range 2',
key: 'range2'
}
],
domains: [
{
name: 'Domain 1',
key: 'domain1',
format: 'utc'
},
{
name: 'Domain 2',
key: 'domain2',
format: 'utc'
}
]
}];
beforeEach(function() {
table.buildColumns(metadata);
});
it("populates the columns attribute", function() {
expect(table.columns.length).toBe(4);
});
it("Build columns populates columns with domains to the left", function() {
expect(table.columns[0] instanceof DomainColumn).toBeTruthy();
expect(table.columns[1] instanceof DomainColumn).toBeTruthy();
expect(table.columns[2] instanceof DomainColumn).toBeFalsy();
});
it("Produces headers for each column based on title", function() {
var headers,
firstColumn = table.columns[0];
spyOn(firstColumn, 'getTitle');
headers = table.getHeaders();
expect(headers.length).toBe(4);
expect(firstColumn.getTitle).toHaveBeenCalled();
});
it("Provides a default configuration with all columns" +
" visible", function() {
var configuration = table.getColumnConfiguration();
expect(configuration).toBeDefined();
expect(Object.keys(configuration).every(function(key){
return configuration[key];
}));
});
it("Column configuration exposes persisted configuration", function() {
var tableConfig,
modelConfig = {
table: {
columns : {
'Range 1': false
}
}
};
mockModel.configuration = modelConfig;
tableConfig = table.getColumnConfiguration();
expect(tableConfig).toBeDefined();
expect(tableConfig['Range 1']).toBe(false);
});
describe('retrieving row values', function () {
var datum,
rowValues;
beforeEach(function() {
datum = {
'range1': 'range 1 value',
'range2': 'range 2 value',
'domain1': 0,
'domain2': 1
};
rowValues = table.getRowValues(mockDomainObject, datum);
});
it("Returns a value for every column", function() {
expect(rowValues['Range 1'].text).toBeDefined();
expect(rowValues['Range 1'].text).toEqual('range 1' +
' value');
});
it("Uses the telemetry formatter to appropriately format" +
" telemetry values", function() {
expect(mockTelemetryFormatter.formatRangeValue).toHaveBeenCalled();
});
});
});
});
}
);

View File

@@ -0,0 +1,155 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,describe,it,expect,beforeEach,waitsFor,jasmine,xit*/
define(
[
"../../src/controllers/MCTTableController"
],
function (MCTTableController) {
"use strict";
describe('The MCTTable Controller', function() {
var controller,
mockScope,
watches,
mockTimeout,
mockElement;
function promise(value) {
return {
then: function (callback){
return promise(callback(value));
}
};
}
beforeEach(function() {
watches = {};
mockScope = jasmine.createSpyObj('scope', [
'$watchCollection'
]);
mockScope.$watchCollection.andCallFake(function(event, callback) {
watches[event] = callback;
});
mockElement = jasmine.createSpyObj('element', [
'find',
'on'
]);
mockElement.find.andReturn(mockElement);
mockScope.displayHeaders = true;
mockTimeout = jasmine.createSpy('$timeout');
controller = new MCTTableController(mockScope, mockTimeout, mockElement);
});
it('Reacts to changes to filters, headers, and rows', function() {
expect(mockScope.$watchCollection).toHaveBeenCalledWith('filters', jasmine.any(Function));
expect(mockScope.$watchCollection).toHaveBeenCalledWith('headers', jasmine.any(Function));
expect(mockScope.$watchCollection).toHaveBeenCalledWith('rows', jasmine.any(Function));
});
describe('rows', function() {
var testRows = [];
beforeEach(function() {
testRows = [
{
'col1': {'text': 'row1 col1 match'},
'col2': {'text': 'def'},
'col3': {'text': 'row1 col3'}
},
{
'col1': {'text': 'row2 col1 match'},
'col2': {'text': 'abc'},
'col3': {'text': 'row2 col3'}
},
{
'col1': {'text': 'row3 col1'},
'col2': {'text': 'ghi'},
'col3': {'text': 'row3 col3'}
}
];
});
it('Filters results based on filter input', function() {
var filters = {},
filteredRows;
mockScope.filters = filters;
filteredRows = controller.filterRows(testRows);
expect(filteredRows.length).toBe(3);
filters.col1 = 'row1';
filteredRows = controller.filterRows(testRows);
expect(filteredRows.length).toBe(1);
filters.col1 = 'match';
filteredRows = controller.filterRows(testRows);
expect(filteredRows.length).toBe(2);
});
it('Sets rows on scope when rows change', function() {
controller.updateRows(testRows);
expect(mockScope.displayRows.length).toBe(3);
expect(mockScope.displayRows).toEqual(testRows);
});
describe('sorting', function() {
var sortedRows;
it('Sorts rows ascending', function() {
mockScope.sortColumn = 'col1';
mockScope.sortDirection = 'asc';
sortedRows = controller.sortRows(testRows);
expect(sortedRows[0].col1.text).toEqual('row1 col1 match');
expect(sortedRows[1].col1.text).toEqual('row2 col1' +
' match');
expect(sortedRows[2].col1.text).toEqual('row3 col1');
});
it('Sorts rows descending', function() {
mockScope.sortColumn = 'col1';
mockScope.sortDirection = 'desc';
sortedRows = controller.sortRows(testRows);
expect(sortedRows[0].col1.text).toEqual('row3 col1');
expect(sortedRows[1].col1.text).toEqual('row2 col1 match');
expect(sortedRows[2].col1.text).toEqual('row1 col1 match');
});
it('Sorts rows descending based on selected sort column', function() {
mockScope.sortColumn = 'col2';
mockScope.sortDirection = 'desc';
sortedRows = controller.sortRows(testRows);
expect(sortedRows[0].col2.text).toEqual('ghi');
expect(sortedRows[1].col2.text).toEqual('def');
expect(sortedRows[2].col2.text).toEqual('abc');
});
});
});
});
});

View File

@@ -0,0 +1,105 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,describe,it,expect,beforeEach,waitsFor,jasmine,xit*/
define(
[
"../../src/controllers/TableOptionsController"
],
function (TableOptionsController) {
"use strict";
describe('The Table Options Controller', function() {
var mockDomainObject,
mockCapability,
controller,
mockScope;
function promise(value) {
return {
then: function (callback){
return promise(callback(value));
}
};
}
beforeEach(function() {
mockCapability = jasmine.createSpyObj('mutationCapability', [
'listen'
]);
mockDomainObject = jasmine.createSpyObj('domainObject', [
'getCapability'
]);
mockDomainObject.getCapability.andReturn(mockCapability);
mockScope = jasmine.createSpyObj('scope', [
'$watchCollection'
]);
mockScope.domainObject = mockDomainObject;
controller = new TableOptionsController(mockScope);
});
it('Registers a listener for mutation events on the object', function() {
expect(mockCapability.listen).toHaveBeenCalled();
});
it('Listens for changes to object composition and updates' +
' options accordingly', function() {
expect(mockScope.$watchCollection).toHaveBeenCalledWith('configuration.table.columns', jasmine.any(Function));
});
describe('Populates scope with a form definition based on provided' +
' column configuration', function() {
var mockModel;
beforeEach(function() {
mockModel = {
configuration: {
table: {
columns: {
'column1': true,
'column2': true,
'column3': false,
'column4': true,
}
}
}
};
controller.populateForm(mockModel);
});
it('creates form on scope', function() {
expect(mockScope.columnsForm).toBeDefined();
expect(mockScope.columnsForm.sections[0]).toBeDefined();
expect(mockScope.columnsForm.sections[0].rows).toBeDefined();
expect(mockScope.columnsForm.sections[0].rows.length).toBe(4);
});
it('presents columns as checkboxes', function() {
expect(mockScope.columnsForm.sections[0].rows.every(function(row){
return row.control === 'checkbox';
})).toBe(true);
});
});
});
});

View File

@@ -0,0 +1,222 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*global define,describe,it,expect,beforeEach,waitsFor,jasmine,xit*/
define(
[
"../../src/controllers/TelemetryTableController"
],
function (TableController) {
"use strict";
describe('The Table Controller', function() {
var mockScope,
mockTelemetryHandler,
mockTelemetryHandle,
mockTelemetryFormatter,
mockDomainObject,
mockTable,
mockConfiguration,
watches,
controller;
function promise(value) {
return {
then: function (callback){
return promise(callback(value));
}
};
}
beforeEach(function() {
watches = {};
mockScope = jasmine.createSpyObj('scope', [
'$on',
'$watch',
'$watchCollection'
]);
mockScope.$on.andCallFake(function(expression, callback){
watches[expression] = callback;
});
mockScope.$watch.andCallFake(function(expression, callback){
watches[expression] = callback;
});
mockScope.$watchCollection.andCallFake(function(expression, callback){
watches[expression] = callback;
});
mockConfiguration = {
'range1': true,
'range2': true,
'domain1': true
};
mockTable = jasmine.createSpyObj('table',
[
'buildColumns',
'getColumnConfiguration',
'getRowValues',
'saveColumnConfiguration'
]
);
mockTable.columns = [];
mockTable.getColumnConfiguration.andReturn(mockConfiguration);
mockDomainObject= jasmine.createSpyObj('domainObject', [
'getCapability',
'useCapability',
'getModel'
]);
mockDomainObject.getModel.andReturn({});
mockScope.domainObject = mockDomainObject;
mockTelemetryHandle = jasmine.createSpyObj('telemetryHandle', [
'request',
'promiseTelemetryObjects',
'getMetadata',
'unsubscribe',
'makeDatum'
]);
mockTelemetryHandle.promiseTelemetryObjects.andReturn(promise(undefined));
mockTelemetryHandler = jasmine.createSpyObj('telemetryHandler', [
'handle'
]);
mockTelemetryHandler.handle.andReturn(mockTelemetryHandle);
controller = new TableController(mockScope, mockTelemetryHandler, mockTelemetryFormatter);
controller.table = mockTable;
controller.handle = mockTelemetryHandle;
});
it('subscribes to telemetry handler for telemetry updates', function() {
controller.subscribe();
expect(mockTelemetryHandler.handle).toHaveBeenCalled();
expect(mockTelemetryHandle.request).toHaveBeenCalled();
});
it('Unsubscribes from telemetry when scope is destroyed',function() {
controller.handle = mockTelemetryHandle;
watches.$destroy();
expect(mockTelemetryHandle.unsubscribe).toHaveBeenCalled();
});
describe('the controller makes use of the table', function() {
it('to create column definitions from telemetry' +
' metadata', function() {
controller.setup();
expect(mockTable.buildColumns).toHaveBeenCalled();
});
it('to create column configuration, which is written to the' +
' object model', function() {
var mockModel = {};
controller.setup();
expect(mockTable.getColumnConfiguration).toHaveBeenCalled();
expect(mockTable.saveColumnConfiguration).toHaveBeenCalled();
});
});
it('updates the rows on scope when historical telemetry is received', function(){
var mockSeries = {
getPointCount: function() {
return 5;
},
getDomainValue: function() {
return 'Domain Value';
},
getRangeValue: function() {
return 'Range Value';
}
},
mockRow = {'domain': 'Domain Value', 'range': 'Range' +
' Value'};
mockTelemetryHandle.makeDatum.andCallFake(function(){
return mockRow;
});
mockTable.getRowValues.andReturn(mockRow);
controller.addHistoricalData(mockDomainObject, mockSeries);
expect(controller.$scope.rows.length).toBe(5);
expect(controller.$scope.rows[0]).toBe(mockRow);
});
it('filters the visible columns based on configuration', function(){
controller.filterColumns();
expect(controller.$scope.headers.length).toBe(3);
expect(controller.$scope.headers[2]).toEqual('domain1');
mockConfiguration.domain1 = false;
controller.filterColumns();
expect(controller.$scope.headers.length).toBe(2);
expect(controller.$scope.headers[2]).toBeUndefined();
});
describe('creates event listeners', function(){
beforeEach(function() {
spyOn(controller,'subscribe');
spyOn(controller, 'filterColumns');
});
it('triggers telemetry subscription update when domain' +
' object changes', function() {
controller.registerChangeListeners();
//'watches' object is populated by fake scope watch and
// watchCollection functions defined above
expect(watches.domainObject).toBeDefined();
watches.domainObject(mockDomainObject);
expect(controller.subscribe).toHaveBeenCalled();
});
it('triggers telemetry subscription update when domain' +
' object composition changes', function() {
controller.registerChangeListeners();
expect(watches['domainObject.getModel().composition']).toBeDefined();
watches['domainObject.getModel().composition']();
expect(controller.subscribe).toHaveBeenCalled();
});
it('triggers telemetry subscription update when time' +
' conductor bounds change', function() {
controller.registerChangeListeners();
expect(watches['telemetry:display:bounds']).toBeDefined();
watches['telemetry:display:bounds']();
expect(controller.subscribe).toHaveBeenCalled();
});
it('triggers refiltering of the columns when configuration' +
' changes', function() {
controller.setup();
expect(watches['domainObject.getModel().configuration.table.columns']).toBeDefined();
watches['domainObject.getModel().configuration.table.columns']();
expect(controller.filterColumns).toHaveBeenCalled();
});
});
});
}
);

View File

@@ -39,6 +39,16 @@ define([
"./src/directives/MCTSwimlaneDrop",
"./src/directives/MCTSwimlaneDrag",
"./src/services/ObjectLoader",
"text!./res/templates/values.html",
"text!./res/templates/timeline.html",
"text!./res/templates/activity-gantt.html",
"text!./res/templates/tabular-swimlane-cols-tree.html",
"text!./res/templates/tabular-swimlane-cols-data.html",
"text!./res/templates/resource-graphs.html",
"text!./res/templates/resource-graph-labels.html",
"text!./res/templates/legend-item.html",
"text!./res/templates/ticks.html",
"text!./res/templates/controls/datetime.html",
'legacyRegistry'
], function (
ExportTimelineAsCSVAction,
@@ -58,6 +68,16 @@ define([
MCTSwimlaneDrop,
MCTSwimlaneDrag,
ObjectLoader,
valuesTemplate,
timelineTemplate,
activityGanttTemplate,
tabularSwimlaneColsTreeTemplate,
tabularSwimlaneColsDataTemplate,
resourceGraphsTemplate,
resourceGraphLabelsTemplate,
legendItemTemplate,
ticksTemplate,
datetimeTemplate,
legacyRegistry
) {
"use strict";
@@ -237,7 +257,7 @@ define([
"key": "values",
"name": "Values",
"glyph": "A",
"templateUrl": "templates/values.html",
"template": valuesTemplate,
"type": "mode",
"uses": [
"cost"
@@ -250,7 +270,7 @@ define([
"glyph": "S",
"type": "timeline",
"description": "A timeline view of Timelines and Activities.",
"templateUrl": "templates/timeline.html",
"template": timelineTemplate,
"editable": true,
"toolbar": {
"sections": [
@@ -346,7 +366,7 @@ define([
"representations": [
{
"key": "gantt",
"templateUrl": "templates/activity-gantt.html",
"template": activityGanttTemplate,
"uses": [
"timespan",
"type"
@@ -357,42 +377,42 @@ define([
{
"key": "timeline-tabular-swimlane-cols-tree",
"priority": "mandatory",
"templateUrl": "templates/tabular-swimlane-cols-tree.html"
"template": tabularSwimlaneColsTreeTemplate
},
{
"key": "timeline-tabular-swimlane-cols-data",
"priority": "mandatory",
"templateUrl": "templates/tabular-swimlane-cols-data.html"
"template": tabularSwimlaneColsDataTemplate
},
{
"key": "timeline-resource-graphs",
"priority": "mandatory",
"templateUrl": "templates/resource-graphs.html"
"template": resourceGraphsTemplate
},
{
"key": "timeline-resource-graph-labels",
"priority": "mandatory",
"templateUrl": "templates/resource-graph-labels.html"
"template": resourceGraphLabelsTemplate
},
{
"key": "timeline-legend-item",
"priority": "mandatory",
"templateUrl": "templates/legend-item.html"
"template": legendItemTemplate
},
{
"key": "timeline-ticks",
"priority": "mandatory",
"templateUrl": "templates/ticks.html"
"template": ticksTemplate
}
],
"controls": [
{
"key": "timeline-datetime",
"templateUrl": "templates/controls/datetime.html"
"template": datetimeTemplate
},
{
"key": "duration",
"templateUrl": "templates/controls/datetime.html"
"template": datetimeTemplate
}
],
"controllers": [

View File

@@ -1,26 +0,0 @@
# Require any additional compass plugins here.
# require "compass-growl"
# Set this to the root of your project when deployed:
http_path = "/"
css_dir = "css"
sass_dir = "sass"
images_dir = "images"
javascripts_dir = "js"
# You can select your preferred output style here (can be overridden via the command line):
# :expanded, :compressed, :nested
output_style = :nested
# To enable relative paths to assets via compass helper functions. Uncomment:
relative_assets = true
# To disable debugging comments that display the original location of your selectors. Uncomment:
# line_comments = false
# If you prefer the indented syntax, you might want to regenerate this
# project again passing --syntax sass, or you can uncomment this:
# preferred_syntax = :sass
# and then run:
# sass-convert -R --from scss --to sass vfn_platform/static/sass scss && rm -rf sass && mv scss sass

View File

@@ -1,291 +0,0 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*****************************************************************************
* 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.
*****************************************************************************/
/************************** FEATURES */
/************************** VERY INFLUENTIAL GLOBAL DIMENSIONS */
/************************** RATIOS */
/************************** LAYOUT */
/************************** CONTROLS */
/************************** PATHS */
/************************** TIMINGS */
/************************** LIMITS */
/*****************************************************************************
* 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.
*****************************************************************************/
/*********************************************** CONTROLS, FORM ELEMENTS */
/*****************************************************************************
* 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.
*****************************************************************************/
/*****************************************************************************
* 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.
*****************************************************************************/
/*****************************************************************************
* 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.
*****************************************************************************/
/* line 26, ../sass/_timeline-thematic.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-legend .l-legend-items {
color: #999; }
/* line 36, ../sass/_timeline-thematic.scss */
.s-timeline-gantt .bar {
color: #fff;
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjAuNSIgeTE9IjAuMCIgeDI9IjAuNSIgeTI9IjEuMCI+PHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iIzc3NzdiYiIvPjxzdG9wIG9mZnNldD0iMTAwJSIgc3RvcC1jb2xvcj0iIzU1NTVhYSIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #7777bb), color-stop(100%, #5555aa));
background-image: -moz-linear-gradient(#7777bb, #5555aa);
background-image: -webkit-linear-gradient(#7777bb, #5555aa);
background-image: linear-gradient(#7777bb, #5555aa);
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
-moz-box-shadow: rgba(0, 0, 0, 0.4) 0 1px 3px;
-webkit-box-shadow: rgba(0, 0, 0, 0.4) 0 1px 3px;
box-shadow: rgba(0, 0, 0, 0.4) 0 1px 3px; }
/* line 41, ../sass/_timeline-thematic.scss */
.s-timeline-gantt .bar.expanded {
-moz-border-radius-topleft: 3px;
-webkit-border-top-left-radius: 3px;
border-top-left-radius: 3px;
-moz-border-radius-topright: 3px;
-webkit-border-top-right-radius: 3px;
border-top-right-radius: 3px;
-moz-border-radius-bottomleft: 0;
-webkit-border-bottom-left-radius: 0;
border-bottom-left-radius: 0;
-moz-border-radius-bottomright: 0;
-webkit-border-bottom-right-radius: 0;
border-bottom-right-radius: 0; }
/* line 45, ../sass/_timeline-thematic.scss */
.s-timeline-gantt .bar.leaf {
-moz-border-radius-topleft: 0;
-webkit-border-top-left-radius: 0;
border-top-left-radius: 0;
-moz-border-radius-topright: 0;
-webkit-border-top-right-radius: 0;
border-top-right-radius: 0;
-moz-border-radius-bottomleft: 3px;
-webkit-border-bottom-left-radius: 3px;
border-bottom-left-radius: 3px;
-moz-border-radius-bottomright: 3px;
-webkit-border-bottom-right-radius: 3px;
border-bottom-right-radius: 3px; }
/* line 49, ../sass/_timeline-thematic.scss */
.s-timeline-gantt .bar .s-toggle {
color: #0099cc; }
/* line 57, ../sass/_timeline-thematic.scss */
.s-timeline-tabular .l-header .l-cols .l-col {
border-left: 1px solid #666666; }
/* line 65, ../sass/_timeline-thematic.scss */
.s-timeline-tabular .l-pane-l .l-cols .s-label .ui-symbol.icon {
color: #8594ff; }
/* line 74, ../sass/_timeline-thematic.scss */
.edit-mode .s-timeline-gantt .bar:hover {
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjAuNSIgeTE9IjAuMCIgeDI9IjAuNSIgeTI9IjEuMCI+PHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iIzk5OTljYyIvPjxzdG9wIG9mZnNldD0iMTAwJSIgc3RvcC1jb2xvcj0iIzc3NzdiYiIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #9999cc), color-stop(100%, #7777bb));
background-image: -moz-linear-gradient(#9999cc, #7777bb);
background-image: -webkit-linear-gradient(#9999cc, #7777bb);
background-image: linear-gradient(#9999cc, #7777bb); }
/* line 81, ../sass/_timeline-thematic.scss */
.s-timeline {
font-size: 0.75rem; }
/* line 83, ../sass/_timeline-thematic.scss */
.s-timeline .s-header {
background-color: #404040; }
/* line 86, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane {
border-bottom: 1px solid #4d4d4d;
line-height: 20px; }
/* line 89, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.exceeded {
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjEuMCIgeTE9IjEuMCIgeDI9IjAuMCIgeTI9IjAuMCI+PHN0b3Agb2Zmc2V0PSIyNSUiIHN0b3AtY29sb3I9IiNmZmZmZmYiIHN0b3Atb3BhY2l0eT0iMC4wNSIvPjxzdG9wIG9mZnNldD0iMjUlIiBzdG9wLWNvbG9yPSIjMDAwMDAwIiBzdG9wLW9wYWNpdHk9IjAuMCIvPjxzdG9wIG9mZnNldD0iNTAlIiBzdG9wLWNvbG9yPSIjMDAwMDAwIiBzdG9wLW9wYWNpdHk9IjAuMCIvPjxzdG9wIG9mZnNldD0iNTAlIiBzdG9wLWNvbG9yPSIjZmZmZmZmIiBzdG9wLW9wYWNpdHk9IjAuMDUiLz48c3RvcCBvZmZzZXQ9Ijc1JSIgc3RvcC1jb2xvcj0iI2ZmZmZmZiIgc3RvcC1vcGFjaXR5PSIwLjA1Ii8+PHN0b3Agb2Zmc2V0PSI3NSUiIHN0b3AtY29sb3I9IiMwMDAwMDAiIHN0b3Atb3BhY2l0eT0iMC4wIi8+PHN0b3Agb2Zmc2V0PSIxMDAlIiBzdG9wLWNvbG9yPSIjMDAwMDAwIiBzdG9wLW9wYWNpdHk9IjAuMCIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -moz-linear-gradient(135deg, rgba(255, 255, 255, 0.05) 25%, rgba(0, 0, 0, 0) 25%, rgba(0, 0, 0, 0) 50%, rgba(255, 255, 255, 0.05) 50%, rgba(255, 255, 255, 0.05) 75%, rgba(0, 0, 0, 0) 75%, rgba(0, 0, 0, 0) 100%);
background-image: -webkit-linear-gradient(135deg, rgba(255, 255, 255, 0.05) 25%, rgba(0, 0, 0, 0) 25%, rgba(0, 0, 0, 0) 50%, rgba(255, 255, 255, 0.05) 50%, rgba(255, 255, 255, 0.05) 75%, rgba(0, 0, 0, 0) 75%, rgba(0, 0, 0, 0) 100%);
background-image: linear-gradient(-45deg, rgba(255, 255, 255, 0.05) 25%, rgba(0, 0, 0, 0) 25%, rgba(0, 0, 0, 0) 50%, rgba(255, 255, 255, 0.05) 50%, rgba(255, 255, 255, 0.05) 75%, rgba(0, 0, 0, 0) 75%, rgba(0, 0, 0, 0) 100%);
background-repeat: repeat;
background-size: 22px 22px; }
/* line 93, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.selected {
background-color: #222;
color: #ccc; }
/* line 97, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.selected .s-timeline-gantt .bar {
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjAuNSIgeTE9IjAuMCIgeDI9IjAuNSIgeTI9IjEuMCI+PHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iI2U2ZTZlNiIvPjxzdG9wIG9mZnNldD0iMTAwJSIgc3RvcC1jb2xvcj0iI2NjY2NjYyIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #e6e6e6), color-stop(100%, #cccccc));
background-image: -moz-linear-gradient(#e6e6e6, #cccccc);
background-image: -webkit-linear-gradient(#e6e6e6, #cccccc);
background-image: linear-gradient(#e6e6e6, #cccccc);
color: #333; }
/* line 103, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.drop-into {
background-color: rgba(85, 85, 170, 0.7); }
/* line 105, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.drop-into .s-timeline-gantt {
opacity: 0.7; }
/* line 109, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.drop-after {
background-color: rgba(0, 0, 0, 0.2);
border-bottom-color: #5555aa; }
/* line 115, ../sass/_timeline-thematic.scss */
.s-timeline .s-ticks {
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjAuMCIgeTE9IjAuNSIgeDI9IjEuMCIgeTI9IjAuNSI+PHN0b3Agb2Zmc2V0PSIxcHgiIHN0b3AtY29sb3I9IiM1OTU5NTkiLz48c3RvcCBvZmZzZXQ9IjFweCIgc3RvcC1jb2xvcj0iIzAwMDAwMCIgc3RvcC1vcGFjaXR5PSIwLjAiLz48c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiMwMDAwMDAiIHN0b3Atb3BhY2l0eT0iMC4wIi8+PC9saW5lYXJHcmFkaWVudD48L2RlZnM+PHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgZmlsbD0idXJsKCNncmFkKSIgLz48L3N2Zz4g');
background-size: 100%;
background-image: -moz-linear-gradient(0deg, #595959 1px, rgba(0, 0, 0, 0) 1px, rgba(0, 0, 0, 0) 100%);
background-image: -webkit-linear-gradient(0deg, #595959 1px, rgba(0, 0, 0, 0) 1px, rgba(0, 0, 0, 0) 100%);
background-image: linear-gradient(90deg, #595959 1px, rgba(0, 0, 0, 0) 1px, rgba(0, 0, 0, 0) 100%);
background-repeat: repeat-x; }
/* line 118, ../sass/_timeline-thematic.scss */
.s-timeline .s-hover-btns-holder {
-moz-user-select: -moz-none;
-ms-user-select: none;
-webkit-user-select: none;
user-select: none;
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjEuMCIgeTE9IjAuNSIgeDI9IjAuMCIgeTI9IjAuNSI+PHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iIzQwNDA0MCIvPjxzdG9wIG9mZnNldD0iNzAlIiBzdG9wLWNvbG9yPSIjNDA0MDQwIi8+PHN0b3Agb2Zmc2V0PSIxMDAlIiBzdG9wLWNvbG9yPSIjNDA0MDQwIiBzdG9wLW9wYWNpdHk9IjAuMCIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -moz-linear-gradient(180deg, #404040, #404040 70%, rgba(64, 64, 64, 0) 100%);
background-image: -webkit-linear-gradient(180deg, #404040, #404040 70%, rgba(64, 64, 64, 0) 100%);
background-image: linear-gradient(-90deg, #404040, #404040 70%, rgba(64, 64, 64, 0) 100%); }
/* line 124, ../sass/_timeline-thematic.scss */
.s-timeline .s-hover-btns-holder .s-btn {
height: 16px;
line-height: 16px; }
/* line 127, ../sass/_timeline-thematic.scss */
.s-timeline .s-hover-btns-holder .s-btn .icon {
font-size: 0.7rem !important; }
/* line 134, ../sass/_timeline-thematic.scss */
.s-timeline .l-timeline-resource-graph .l-graph {
background: rgba(0, 0, 0, 0.2); }
/* line 137, ../sass/_timeline-thematic.scss */
.s-timeline .l-timeline-resource-graph .l-title {
color: #999; }
/* line 143, ../sass/_timeline-thematic.scss */
.edit-mode .s-swimlane {
cursor: pointer; }
/* line 145, ../sass/_timeline-thematic.scss */
.edit-mode .s-swimlane .t-object-label {
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
cursor: move;
padding: 2px 5px; }
/* line 149, ../sass/_timeline-thematic.scss */
.edit-mode .s-swimlane .t-object-label:hover {
background: rgba(153, 153, 153, 0.3);
color: #cccccc; }

View File

@@ -1,291 +0,0 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*****************************************************************************
* 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.
*****************************************************************************/
/************************** FEATURES */
/************************** VERY INFLUENTIAL GLOBAL DIMENSIONS */
/************************** RATIOS */
/************************** LAYOUT */
/************************** CONTROLS */
/************************** PATHS */
/************************** TIMINGS */
/************************** LIMITS */
/*****************************************************************************
* 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.
*****************************************************************************/
/*********************************************** CONTROLS, FORM ELEMENTS */
/*****************************************************************************
* 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.
*****************************************************************************/
/*****************************************************************************
* 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.
*****************************************************************************/
/*****************************************************************************
* 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.
*****************************************************************************/
/* line 26, ../sass/_timeline-thematic.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-legend .l-legend-items {
color: #666; }
/* line 36, ../sass/_timeline-thematic.scss */
.s-timeline-gantt .bar {
color: #fff;
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjAuNSIgeTE9IjAuMCIgeDI9IjAuNSIgeTI9IjEuMCI+PHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iIzc3NzdiYiIvPjxzdG9wIG9mZnNldD0iMTAwJSIgc3RvcC1jb2xvcj0iIzU1NTVhYSIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #7777bb), color-stop(100%, #5555aa));
background-image: -moz-linear-gradient(#7777bb, #5555aa);
background-image: -webkit-linear-gradient(#7777bb, #5555aa);
background-image: linear-gradient(#7777bb, #5555aa);
-moz-border-radius: 4px;
-webkit-border-radius: 4px;
border-radius: 4px;
-moz-box-shadow: rgba(0, 0, 0, 0.1) 0 1px 3px;
-webkit-box-shadow: rgba(0, 0, 0, 0.1) 0 1px 3px;
box-shadow: rgba(0, 0, 0, 0.1) 0 1px 3px; }
/* line 41, ../sass/_timeline-thematic.scss */
.s-timeline-gantt .bar.expanded {
-moz-border-radius-topleft: 4px;
-webkit-border-top-left-radius: 4px;
border-top-left-radius: 4px;
-moz-border-radius-topright: 4px;
-webkit-border-top-right-radius: 4px;
border-top-right-radius: 4px;
-moz-border-radius-bottomleft: 0;
-webkit-border-bottom-left-radius: 0;
border-bottom-left-radius: 0;
-moz-border-radius-bottomright: 0;
-webkit-border-bottom-right-radius: 0;
border-bottom-right-radius: 0; }
/* line 45, ../sass/_timeline-thematic.scss */
.s-timeline-gantt .bar.leaf {
-moz-border-radius-topleft: 0;
-webkit-border-top-left-radius: 0;
border-top-left-radius: 0;
-moz-border-radius-topright: 0;
-webkit-border-top-right-radius: 0;
border-top-right-radius: 0;
-moz-border-radius-bottomleft: 4px;
-webkit-border-bottom-left-radius: 4px;
border-bottom-left-radius: 4px;
-moz-border-radius-bottomright: 4px;
-webkit-border-bottom-right-radius: 4px;
border-bottom-right-radius: 4px; }
/* line 49, ../sass/_timeline-thematic.scss */
.s-timeline-gantt .bar .s-toggle {
color: #0099cc; }
/* line 57, ../sass/_timeline-thematic.scss */
.s-timeline-tabular .l-header .l-cols .l-col {
border-left: 1px solid #c9c9c9; }
/* line 65, ../sass/_timeline-thematic.scss */
.s-timeline-tabular .l-pane-l .l-cols .s-label .ui-symbol.icon {
color: #8594ff; }
/* line 74, ../sass/_timeline-thematic.scss */
.edit-mode .s-timeline-gantt .bar:hover {
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjAuNSIgeTE9IjAuMCIgeDI9IjAuNSIgeTI9IjEuMCI+PHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iIzk5OTljYyIvPjxzdG9wIG9mZnNldD0iMTAwJSIgc3RvcC1jb2xvcj0iIzc3NzdiYiIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #9999cc), color-stop(100%, #7777bb));
background-image: -moz-linear-gradient(#9999cc, #7777bb);
background-image: -webkit-linear-gradient(#9999cc, #7777bb);
background-image: linear-gradient(#9999cc, #7777bb); }
/* line 81, ../sass/_timeline-thematic.scss */
.s-timeline {
font-size: 0.75rem; }
/* line 83, ../sass/_timeline-thematic.scss */
.s-timeline .s-header {
background-color: #efefef; }
/* line 86, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane {
border-bottom: 1px solid #e3e3e3;
line-height: 20px; }
/* line 89, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.exceeded {
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjEuMCIgeTE9IjEuMCIgeDI9IjAuMCIgeTI9IjAuMCI+PHN0b3Agb2Zmc2V0PSIyNSUiIHN0b3AtY29sb3I9IiNmZmZmZmYiIHN0b3Atb3BhY2l0eT0iMC4wNSIvPjxzdG9wIG9mZnNldD0iMjUlIiBzdG9wLWNvbG9yPSIjMDAwMDAwIiBzdG9wLW9wYWNpdHk9IjAuMCIvPjxzdG9wIG9mZnNldD0iNTAlIiBzdG9wLWNvbG9yPSIjMDAwMDAwIiBzdG9wLW9wYWNpdHk9IjAuMCIvPjxzdG9wIG9mZnNldD0iNTAlIiBzdG9wLWNvbG9yPSIjZmZmZmZmIiBzdG9wLW9wYWNpdHk9IjAuMDUiLz48c3RvcCBvZmZzZXQ9Ijc1JSIgc3RvcC1jb2xvcj0iI2ZmZmZmZiIgc3RvcC1vcGFjaXR5PSIwLjA1Ii8+PHN0b3Agb2Zmc2V0PSI3NSUiIHN0b3AtY29sb3I9IiMwMDAwMDAiIHN0b3Atb3BhY2l0eT0iMC4wIi8+PHN0b3Agb2Zmc2V0PSIxMDAlIiBzdG9wLWNvbG9yPSIjMDAwMDAwIiBzdG9wLW9wYWNpdHk9IjAuMCIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -moz-linear-gradient(135deg, rgba(255, 255, 255, 0.05) 25%, rgba(0, 0, 0, 0) 25%, rgba(0, 0, 0, 0) 50%, rgba(255, 255, 255, 0.05) 50%, rgba(255, 255, 255, 0.05) 75%, rgba(0, 0, 0, 0) 75%, rgba(0, 0, 0, 0) 100%);
background-image: -webkit-linear-gradient(135deg, rgba(255, 255, 255, 0.05) 25%, rgba(0, 0, 0, 0) 25%, rgba(0, 0, 0, 0) 50%, rgba(255, 255, 255, 0.05) 50%, rgba(255, 255, 255, 0.05) 75%, rgba(0, 0, 0, 0) 75%, rgba(0, 0, 0, 0) 100%);
background-image: linear-gradient(-45deg, rgba(255, 255, 255, 0.05) 25%, rgba(0, 0, 0, 0) 25%, rgba(0, 0, 0, 0) 50%, rgba(255, 255, 255, 0.05) 50%, rgba(255, 255, 255, 0.05) 75%, rgba(0, 0, 0, 0) 75%, rgba(0, 0, 0, 0) 100%);
background-repeat: repeat;
background-size: 22px 22px; }
/* line 93, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.selected {
background-color: rgba(85, 85, 170, 0.25);
color: #4d4d4d; }
/* line 97, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.selected .s-timeline-gantt .bar {
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjAuNSIgeTE9IjAuMCIgeDI9IjAuNSIgeTI9IjEuMCI+PHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iIzc3NzdiYiIvPjxzdG9wIG9mZnNldD0iMTAwJSIgc3RvcC1jb2xvcj0iIzU1NTVhYSIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -webkit-gradient(linear, 50% 0%, 50% 100%, color-stop(0%, #7777bb), color-stop(100%, #5555aa));
background-image: -moz-linear-gradient(#7777bb, #5555aa);
background-image: -webkit-linear-gradient(#7777bb, #5555aa);
background-image: linear-gradient(#7777bb, #5555aa);
color: #fff; }
/* line 103, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.drop-into {
background-color: rgba(85, 85, 170, 0.7); }
/* line 105, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.drop-into .s-timeline-gantt {
opacity: 0.7; }
/* line 109, ../sass/_timeline-thematic.scss */
.s-timeline .s-swimlane.drop-after {
background-color: rgba(0, 0, 0, 0.2);
border-bottom-color: #5555aa; }
/* line 115, ../sass/_timeline-thematic.scss */
.s-timeline .s-ticks {
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjAuMCIgeTE9IjAuNSIgeDI9IjEuMCIgeTI9IjAuNSI+PHN0b3Agb2Zmc2V0PSIxcHgiIHN0b3AtY29sb3I9IiNkNmQ2ZDYiLz48c3RvcCBvZmZzZXQ9IjFweCIgc3RvcC1jb2xvcj0iIzAwMDAwMCIgc3RvcC1vcGFjaXR5PSIwLjAiLz48c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiMwMDAwMDAiIHN0b3Atb3BhY2l0eT0iMC4wIi8+PC9saW5lYXJHcmFkaWVudD48L2RlZnM+PHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgZmlsbD0idXJsKCNncmFkKSIgLz48L3N2Zz4g');
background-size: 100%;
background-image: -moz-linear-gradient(0deg, #d6d6d6 1px, rgba(0, 0, 0, 0) 1px, rgba(0, 0, 0, 0) 100%);
background-image: -webkit-linear-gradient(0deg, #d6d6d6 1px, rgba(0, 0, 0, 0) 1px, rgba(0, 0, 0, 0) 100%);
background-image: linear-gradient(90deg, #d6d6d6 1px, rgba(0, 0, 0, 0) 1px, rgba(0, 0, 0, 0) 100%);
background-repeat: repeat-x; }
/* line 118, ../sass/_timeline-thematic.scss */
.s-timeline .s-hover-btns-holder {
-moz-user-select: -moz-none;
-ms-user-select: none;
-webkit-user-select: none;
user-select: none;
background-image: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4gPHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IGlkPSJncmFkIiBncmFkaWVudFVuaXRzPSJvYmplY3RCb3VuZGluZ0JveCIgeDE9IjEuMCIgeTE9IjAuNSIgeDI9IjAuMCIgeTI9IjAuNSI+PHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iI2VmZWZlZiIvPjxzdG9wIG9mZnNldD0iNzAlIiBzdG9wLWNvbG9yPSIjZWZlZmVmIi8+PHN0b3Agb2Zmc2V0PSIxMDAlIiBzdG9wLWNvbG9yPSIjZWZlZmVmIiBzdG9wLW9wYWNpdHk9IjAuMCIvPjwvbGluZWFyR3JhZGllbnQ+PC9kZWZzPjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjZ3JhZCkiIC8+PC9zdmc+IA==');
background-size: 100%;
background-image: -moz-linear-gradient(180deg, #efefef, #efefef 70%, rgba(239, 239, 239, 0) 100%);
background-image: -webkit-linear-gradient(180deg, #efefef, #efefef 70%, rgba(239, 239, 239, 0) 100%);
background-image: linear-gradient(-90deg, #efefef, #efefef 70%, rgba(239, 239, 239, 0) 100%); }
/* line 124, ../sass/_timeline-thematic.scss */
.s-timeline .s-hover-btns-holder .s-btn {
height: 16px;
line-height: 16px; }
/* line 127, ../sass/_timeline-thematic.scss */
.s-timeline .s-hover-btns-holder .s-btn .icon {
font-size: 0.7rem !important; }
/* line 134, ../sass/_timeline-thematic.scss */
.s-timeline .l-timeline-resource-graph .l-graph {
background: rgba(0, 0, 0, 0.05); }
/* line 137, ../sass/_timeline-thematic.scss */
.s-timeline .l-timeline-resource-graph .l-title {
color: #666; }
/* line 143, ../sass/_timeline-thematic.scss */
.edit-mode .s-swimlane {
cursor: pointer; }
/* line 145, ../sass/_timeline-thematic.scss */
.edit-mode .s-swimlane .t-object-label {
-moz-border-radius: 4px;
-webkit-border-radius: 4px;
border-radius: 4px;
cursor: move;
padding: 2px 5px; }
/* line 149, ../sass/_timeline-thematic.scss */
.edit-mode .s-swimlane .t-object-label:hover {
background: rgba(102, 102, 102, 0.3);
color: #333333; }

View File

@@ -1,565 +0,0 @@
/*****************************************************************************
* 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.
*****************************************************************************/
/*****************************************************************************
* 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.
*****************************************************************************/
/************************** FEATURES */
/************************** VERY INFLUENTIAL GLOBAL DIMENSIONS */
/************************** RATIOS */
/************************** LAYOUT */
/************************** CONTROLS */
/************************** PATHS */
/************************** TIMINGS */
/************************** LIMITS */
/*****************************************************************************
* 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.
*****************************************************************************/
/*********************************************** CONTROLS, FORM ELEMENTS */
/*****************************************************************************
* 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.
*****************************************************************************/
/* line 1, ../sass/_activities.scss */
.l-timeline-gantt {
position: absolute;
top: 2px;
bottom: 2px; }
/* line 5, ../sass/_activities.scss */
.l-timeline-gantt .bar {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
height: 17px;
line-height: 19px;
padding: 0 5px; }
/* line 11, ../sass/_activities.scss */
.l-timeline-gantt .bar span {
display: inline; }
/* line 15, ../sass/_activities.scss */
.l-timeline-gantt .bar span.s-activity-type.timeline:before {
content: "S"; }
/* line 20, ../sass/_activities.scss */
.l-timeline-gantt .bar span.s-activity-type.activity:before {
content: "A"; }
/* line 25, ../sass/_activities.scss */
.l-timeline-gantt .bar span.s-title {
text-shadow: rgba(0, 0, 0, 0.1) 0 1px 2px; }
/* line 28, ../sass/_activities.scss */
.l-timeline-gantt .bar span.duration {
left: auto;
opacity: 0.75;
right: 0;
text-align: right;
width: 60px; }
/* line 35, ../sass/_activities.scss */
.l-timeline-gantt .bar span.handle {
top: 0;
bottom: 0;
height: auto;
width: 15px; }
/* line 40, ../sass/_activities.scss */
.l-timeline-gantt .bar span.handle.left {
right: auto; }
/* line 43, ../sass/_activities.scss */
.l-timeline-gantt .bar span.handle.middle {
right: 15px;
left: 15px;
width: auto; }
/* line 48, ../sass/_activities.scss */
.l-timeline-gantt .bar span.handle.right {
right: 0;
left: auto; }
/* line 58, ../sass/_activities.scss */
.edit-mode .s-timeline-gantt .handle {
cursor: col-resize; }
/* line 60, ../sass/_activities.scss */
.edit-mode .s-timeline-gantt .handle.mid {
cursor: ew-resize; }
/*****************************************************************************
* 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.
*****************************************************************************/
/* line 23, ../sass/_timelines.scss */
.l-timeline-holder {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto; }
/* line 26, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto; }
/* line 29, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane .l-width-control {
position: relative; }
/* line 33, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane .l-swimlanes-holder {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
top: 31px; }
/* line 40, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.s-timeline-tabular .t-pane-v {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto; }
/* line 43, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.s-timeline-tabular .t-pane-v.l-tabular-l {
right: auto;
width: 266px; }
/* line 48, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.s-timeline-tabular .t-pane-v.l-tabular-r {
overflow-x: auto;
overflow-y: hidden;
left: 266px; }
/* line 52, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.s-timeline-tabular .t-pane-v.l-tabular-r .l-width {
overflow: visible;
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
width: auto;
height: auto;
min-width: 590px;
width: 100%; }
/* line 60, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-gantt .l-swimlanes-holder {
overflow-x: hidden;
overflow-y: scroll; }
/* line 64, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-legend {
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
padding: 5px 0;
white-space: nowrap; }
/* line 69, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-legend .l-legend-items {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
overflow-x: hidden;
overflow-y: auto;
top: 25px; }
/* line 74, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-legend .legend-item {
display: block;
margin-bottom: 3px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap; }
/* line 81, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-legend .legend-item .color-swatch {
vertical-align: baseline; }
/* line 84, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-legend .legend-item .title-label {
vertical-align: baseline; }
/* line 93, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graphs-holder {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
bottom: 10px; }
/* line 97, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graphs-holder .l-graphs {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
overflow-x: hidden;
overflow-y: scroll; }
/* line 102, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graphs-holder .l-graph-labels-holder {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
overflow: hidden;
right: auto;
width: 400px; }
/* line 110, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-scroll-control {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
overflow-x: scroll;
overflow-y: hidden;
top: auto;
right: 10px;
height: 10px; }
/* line 116, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-scroll-control .l-width-control {
height: 10px; }
/* line 121, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graph,
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graph-labels {
height: 80px;
margin-bottom: 3px;
position: relative; }
/* line 128, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-title {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
top: 5px;
left: 5px;
position: absolute; }
/* line 134, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graph {
width: 100%; }
/* line 137, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graph .l-graph-area canvas {
width: 100%;
height: 100%; }
/* line 144, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graph-labels {
z-index: 10; }
/* line 148, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graph-area {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
top: 20px;
bottom: 5px; }
/* line 151, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graph-area .l-labels-holder {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
left: 5px; }
/* line 154, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.t-pane-h.l-timeline-resource-graph .l-graph-area .l-labels-holder .tick-label.tick-label-y {
text-align: left; }
/* line 162, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.l-pane-l {
right: auto;
min-width: 50px;
max-width: 90%;
width: 30%; }
/* line 169, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.l-pane-r {
left: 0; }
/* line 172, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.l-pane-r:hover .l-hover-btns-holder {
-moz-transition-property: opacity, background-color, border-color, color;
-o-transition-property: opacity, background-color, border-color, color;
-webkit-transition-property: opacity, background-color, border-color, color;
transition-property: opacity, background-color, border-color, color;
-moz-transition-duration: 100ms;
-o-transition-duration: 100ms;
-webkit-transition-duration: 100ms;
transition-duration: 100ms;
-moz-transition-timing-function: ease-in-out;
-o-transition-timing-function: ease-in-out;
-webkit-transition-timing-function: ease-in-out;
transition-timing-function: ease-in-out;
-moz-transition-delay: 0;
-o-transition-delay: 0;
-webkit-transition-delay: 0;
transition-delay: 0;
opacity: 1; }
/* line 179, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.l-pane-top {
bottom: 30%; }
/* line 182, ../sass/_timelines.scss */
.l-timeline-holder .l-timeline-pane.l-pane-btm {
top: auto;
min-height: 20px;
max-height: 80%;
height: 30%; }
/* line 190, ../sass/_timelines.scss */
.l-timeline-holder .l-swimlane {
height: 21px;
position: relative; }
/* line 196, ../sass/_timelines.scss */
.l-timeline-holder .s-timeline-tabular .l-header,
.l-timeline-holder .s-timeline-gantt .l-header {
overflow: visible;
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
width: auto;
height: auto;
bottom: auto;
height: 30px; }
/* line 201, ../sass/_timelines.scss */
.l-timeline-holder .s-timeline-tabular .l-header .l-header-elem,
.l-timeline-holder .s-timeline-gantt .l-header .l-header-elem {
overflow: visible;
position: absolute;
top: 5px;
right: 5px;
bottom: 5px;
left: 5px;
width: auto;
height: auto;
display: block; }
/* line 205, ../sass/_timelines.scss */
.l-timeline-holder .s-timeline-tabular .l-header .l-header-elem.l-labels .l-label,
.l-timeline-holder .s-timeline-gantt .l-header .l-header-elem.l-labels .l-label {
position: absolute;
width: 140px;
margin-left: -70px;
text-align: center; }
/* line 215, ../sass/_timelines.scss */
.l-timeline-holder .l-hover-btns-holder {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
-moz-transition-property: opacity, background-color, border-color, color;
-o-transition-property: opacity, background-color, border-color, color;
-webkit-transition-property: opacity, background-color, border-color, color;
transition-property: opacity, background-color, border-color, color;
-moz-transition-duration: 500ms;
-o-transition-duration: 500ms;
-webkit-transition-duration: 500ms;
transition-duration: 500ms;
-moz-transition-timing-function: ease-in-out;
-o-transition-timing-function: ease-in-out;
-webkit-transition-timing-function: ease-in-out;
transition-timing-function: ease-in-out;
-moz-transition-delay: 0;
-o-transition-delay: 0;
-webkit-transition-delay: 0;
transition-delay: 0;
opacity: 0;
height: 30px;
width: 100px;
left: auto;
padding: 5px;
text-align: right;
z-index: 10; }
/* line 228, ../sass/_timelines.scss */
.l-timeline-holder .l-cols {
overflow: visible;
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
width: auto;
height: auto;
text-wrap: none;
white-space: nowrap; }
/* line 232, ../sass/_timelines.scss */
.l-timeline-holder .l-cols .l-col {
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
display: inline-block;
height: 100%;
padding: 0 5px;
position: relative;
text-wrap: none;
white-space: nowrap; }
/* line 242, ../sass/_timelines.scss */
.l-timeline-holder .l-cols .l-col.l-col-icon {
width: 16px;
text-align: center;
padding: 0; }
/* line 246, ../sass/_timelines.scss */
.l-timeline-holder .l-cols .l-col.l-col-icon .ui-symbol {
color: #0099cc; }
/* line 251, ../sass/_timelines.scss */
.l-timeline-holder .l-cols .l-col.l-plot-resource {
border-left: none !important;
cursor: pointer;
padding-left: 0; }
/* line 257, ../sass/_timelines.scss */
.l-timeline-holder .l-cols .l-col.l-title {
width: 250px; }
/* line 261, ../sass/_timelines.scss */
.l-timeline-holder .l-cols .l-col.l-start, .l-timeline-holder .l-cols .l-col.l-end, .l-timeline-holder .l-cols .l-col.l-duration {
width: 110px; }
/* line 267, ../sass/_timelines.scss */
.l-timeline-holder .l-cols .l-col.l-activity-modes {
display: none;
width: 250px; }
/* line 275, ../sass/_timelines.scss */
.l-timeline-holder .s-timeline-tabular .l-header .l-cols {
top: 5px;
bottom: 5px; }
/* line 281, ../sass/_timelines.scss */
.l-timeline-holder .s-timeline-tabular .l-pane-l .l-cols {
left: 5px; }
/* line 287, ../sass/_timelines.scss */
.l-timeline-holder .splitter {
top: 0; }
/* line 293, ../sass/_timelines.scss */
.l-timeline-holder .l-ticks,
.l-timeline-holder .l-subticks {
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: auto;
height: auto;
top: auto;
bottom: 3px; }
/* line 299, ../sass/_timelines.scss */
.l-timeline-holder .l-ticks {
height: 10px; }
/* line 303, ../sass/_timelines.scss */
.l-timeline-holder .l-subticks {
height: 5px; }

View File

@@ -1,4 +0,0 @@
date
echo "*** Compiling sass"
compass compile --force

View File

@@ -23,7 +23,7 @@
}
}
&.s-title {
@include text-shadow(rgba(black, 0.1) 0 1px 2px);
text-shadow: rgba(black, 0.1) 0 1px 2px;
}
&.duration {
left: auto;

View File

@@ -36,8 +36,8 @@
.bar {
color: $colorGanttBarFg;
@include activityBg($colorGanttBarBg);
@include border-radius($br);
@include box-shadow($shdwGanttBar);
border-radius: $br;
box-shadow: $shdwGanttBar;
&.expanded {
@include border-top-radius($br);
@include border-bottom-radius(0);
@@ -145,7 +145,7 @@
.s-status-editing .s-swimlane {
cursor: pointer;
.t-object-label {
@include border-radius($controlCr);
border-radius: $controlCr;
cursor: move;
padding: 2px 5px;
&:hover {

View File

@@ -62,7 +62,7 @@
}
}
&.l-timeline-resource-legend {
@include box-sizing(border-box);
box-sizing: border-box;
padding: $interiorMargin 0;
white-space: nowrap;
@@ -214,7 +214,7 @@
.l-hover-btns-holder {
@include absPosDefault();
@include box-sizing(border-box);
box-sizing: border-box;
@include trans-prop-nice-fade(500ms);
opacity: 0;
height: $timelineTopPaneHeaderH;
@@ -230,7 +230,7 @@
text-wrap: none;
white-space: nowrap;
.l-col {
@include box-sizing(border-box);
box-sizing: border-box;
@include ellipsize();
display: inline-block;
height: 100%;
@@ -256,6 +256,16 @@
&.l-title {
width: $timelineColTitleW;
.rep-object-label[draggable="true"] {
border-radius: $basicCr;
@include transition(background-color, 0.25s);
cursor: pointer;
display: inline-block;
padding: 0 $interiorMarginSm;
&:hover {
background-color: $colorItemTreeHoverBg;
}
}
}
&.l-start,

View File

@@ -19,9 +19,7 @@
* this source code distribution or the Licensing information page available
* at runtime from the About dialog for additional information.
*****************************************************************************/
@import "compass";
@import "compass/css3";
@import "compass/utilities";
@import "bourbon";
@import "../../../../commonUI/general/res/sass/constants";
@import "../../../../commonUI/general/res/sass/mixins";

View File

@@ -19,9 +19,7 @@
* this source code distribution or the Licensing information page available
* at runtime from the About dialog for additional information.
*****************************************************************************/
@import "compass";
@import "compass/css3";
@import "compass/utilities";
@import "bourbon";
@import "../../../../commonUI/general/res/sass/constants";
@import "../../../../commonUI/general/res/sass/mixins";

View File

@@ -19,9 +19,7 @@
* this source code distribution or the Licensing information page available
* at runtime from the About dialog for additional information.
*****************************************************************************/
@import "compass";
@import "compass/css3";
@import "compass/utilities";
@import "bourbon";
@import "../../../../commonUI/general/res/sass/constants";
@import "../../../../commonUI/general/res/sass/mixins";
@@ -29,4 +27,4 @@
@import "../../../../commonUI/themes/espresso/res/sass/mixins";
@import "constants";
@import "activities";
@import "timelines";
@import "timelines";

View File

@@ -22,10 +22,10 @@
<div class="t-timeline-gantt l-timeline-gantt s-timeline-gantt"
title="{{model.name}}"
ng-controller="TimelineGanttController as gantt"
ng-style="{
ng-style="timespan ? {
left: gantt.left(timespan, parameters.scroll, parameters.toPixels) + 'px',
width: gantt.width(timespan, parameters.scroll, parameters.toPixels) + 'px'
}">
} : {}">
<div class="bar">
<span class="s-activity-type ui-symbol">

View File

@@ -50,6 +50,7 @@
ng-style="{ 'margin-left': 15 * ngModel.depth + 'px' }">
<mct-representation key="'label'"
mct-object="ngModel.domainObject"
class="rep-object-label"
mct-swimlane-drag="ngModel">
</mct-representation>
</span>

View File

@@ -98,7 +98,7 @@ define(
});
}
}
// Recalculate swimlane state on changes
$scope.$watch("domainObject", swimlanePopulator.populate);
@@ -108,6 +108,9 @@ define(
// Carry over changes in swimlane set to changes in graphs
$scope.$watch(graphMask, repopulateGraphs);
// Pass selection object into swimlane populator
$scope.$watch("selection", swimlanePopulator.selection);
// Convey current selection to drag handle populator
$scope.$watch("selection.get()", dragPopulator.select);

View File

@@ -46,7 +46,8 @@ define(
start = Number.POSITIVE_INFINITY,
end = Number.NEGATIVE_INFINITY,
colors = (configuration.colors || {}),
assigner = new TimelineColorAssigner(colors);
assigner = new TimelineColorAssigner(colors),
lastDomainObject;
// Track extremes of start/end times
function trackStartEnd(timespan) {
@@ -144,12 +145,25 @@ define(
domainObject && new TimelineProxy(domainObject, selection)
);
}
lastDomainObject = domainObject;
}
function setSelectionObject(s) {
selection = s;
recalculateSwimlanes(lastDomainObject);
}
// Ensure colors are exposed in configuration
configuration.colors = colors;
return {
/**
* Set the selection object associated with this timeline view.
* @param {Object} selection the selection object
*/
selection: setSelectionObject,
/**
* Update list of swimlanes to match those reachable from this
* object.

View File

@@ -85,6 +85,7 @@ define(
);
if (id) {
event.stopPropagation();
// Delegate the drop to the swimlane itself
swimlane.drop(id, (draggedSwimlane || {}).domainObject);
}

View File

@@ -150,6 +150,15 @@ define(
expect(mockSelection.proxy).toHaveBeenCalled();
});
it("allows selection object to be changed", function () {
var mockNewSelectionObject = jasmine.createSpyObj(
'new-selection',
['get', 'select', 'proxy']
);
populator.selection(mockNewSelectionObject);
expect(mockNewSelectionObject.proxy)
.toHaveBeenCalled();
});
});
}

View File

@@ -87,7 +87,8 @@ define(
testEvent = {
pageY: TEST_TOP + TEST_HEIGHT / 10,
dataTransfer: { getData: jasmine.createSpy() },
preventDefault: jasmine.createSpy()
preventDefault: jasmine.createSpy(),
stopPropagation: jasmine.createSpy()
};
testEvent.dataTransfer.getData.andReturn('abc');