trip-animation-widget.tpl.html 2.85 KB
<!--

    Copyright © 2016-2019 The Thingsboard Authors

    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.

-->
<div class="heat-map-widget tracking-widget" layout="column" layout-align="center start"
     ng-style="{'padding-top' : (!vm.widgetConfig.showTitle && vm.ctx.settings.showLabel) ? '5px' : '0px'}">
    <div ng-show="vm.ctx.settings.showLabel">
        {{vm.trips[vm.activeTripIndex].settings.labelText}}
    </div>
    <div class="heat-map-control-panel" lang="row" layout-align="center start">
        <md-slider-container>
            <md-slider ng-model="vm.index" min="{{vm.minTime}}" max="{{vm.maxTime}}" ng-change="vm.recalculateTrips()"></md-slider>
            <md-button aria-label="Play" ng-click="vm.playMove(true)" ng-disabled="vm.isPlaying">
                <ng-md-icon icon="play_circle_outline"></ng-md-icon>
            </md-button>
            <md-select ng-model="vm.speed" aria-label="Speed selector">
                <md-option ng-value="speed" flex="1" ng-repeat="speed in vm.speeds track by $index">{{ speed}}
                </md-option>
            </md-select>
            <md-button aria-label="Stop playing" ng-click="vm.stopPlay()">
                <ng-md-icon icon="pause_circle_outline"></ng-md-icon>
            </md-button>
            <div class="panel-timer">{{vm.trips[vm.activeTripIndex].timeRange[vm.index].ts | date:'medium'}}
            </div>
        </md-slider-container>
    </div>
    <div class="heat-map-container" layout="column">
        <div flex id='heat-map'></div>
        <div class="heat-map-info-panel" layout="row">
            <md-button aria-label="tooltip" ng-show="vm.staticSettings.displayTooltip" ng-click="vm.showHideTooltip()">
                <ng-md-icon icon="info"></ng-md-icon>
            </md-button>
            <!--<md-button aria-label="settings" ng-click="vm.openHideSettings()">-->
                <!--<ng-md-icon icon="settings_applications"></ng-md-icon>-->
            <!--</md-button>-->
        </div>
        <div class="heat-map-tooltip" class="heat-map-title" layout="column" ng-class="!vm.staticSettings.showTooltip ? 'heat-map-tooltip-hidden':''" ng-bind-html="vm.trips[vm.activeTripIndex].settings.tooltipText"
        ng-style="{'background-color': vm.staticSettings.tooltipColor, 'opacity': vm.staticSettings.tooltipOpacity, 'color': vm.staticSettings.tooltipFontColor}">
        </div>
    </div>
</div>