@c8y/ng1-modules 1017.67.0 → 1017.69.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/NOTICES CHANGED
@@ -2304,7 +2304,7 @@ SOFTWARE
2304
2304
 
2305
2305
  -----
2306
2306
 
2307
- The following software may be included in this product: @types/babel__core, @types/babel__generator, @types/babel__template, @types/babel__traverse, @types/body-parser, @types/bonjour, @types/connect, @types/connect-history-api-fallback, @types/cron, @types/eslint, @types/eslint-scope, @types/estree, @types/express, @types/express-serve-static-core, @types/file-saver, @types/fs-extra, @types/graceful-fs, @types/html-minifier-terser, @types/http-proxy, @types/istanbul-lib-coverage, @types/istanbul-reports, @types/jest, @types/jsdom, @types/json-schema, @types/jsonfile, @types/marked, @types/mime, @types/node, @types/parse5, @types/prettier, @types/qs, @types/range-parser, @types/resolve, @types/semver, @types/serve-index, @types/serve-static, @types/sinonjs__fake-timers, @types/sizzle, @types/sockjs, @types/stack-utils, @types/tough-cookie, @types/webpack, @types/webpack-dev-server, @types/ws, @types/yargs, @types/yargs-parser, @types/yauzl. A copy of the source code may be downloaded from https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/babel__core), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/babel__generator), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/babel__template), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/babel__traverse), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/body-parser), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/bonjour), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/connect), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/connect-history-api-fallback), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/cron), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/eslint), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/eslint-scope), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/estree), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/express), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/express-serve-static-core), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/file-saver), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/fs-extra), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/graceful-fs), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/html-minifier-terser), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/http-proxy), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/istanbul-lib-coverage), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/istanbul-reports), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/jest), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/jsdom), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/json-schema), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/jsonfile), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/marked), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/mime), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/node), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/parse5), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/prettier), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/qs), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/range-parser), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/resolve), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/semver), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/serve-index), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/serve-static), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/sinonjs__fake-timers), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/sizzle), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/sockjs), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/stack-utils), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/tough-cookie), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/webpack), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/ws), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/yargs), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/yargs-parser), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/yauzl). This software contains the following license and notice below:
2307
+ The following software may be included in this product: @types/babel__core, @types/babel__generator, @types/babel__template, @types/babel__traverse, @types/body-parser, @types/bonjour, @types/connect, @types/connect-history-api-fallback, @types/cron, @types/eslint, @types/eslint-scope, @types/estree, @types/express, @types/express-serve-static-core, @types/file-saver, @types/fs-extra, @types/graceful-fs, @types/html-minifier-terser, @types/http-proxy, @types/istanbul-lib-coverage, @types/istanbul-reports, @types/jest, @types/jsdom, @types/json-schema, @types/jsonfile, @types/marked, @types/mime, @types/node, @types/parse5, @types/prettier, @types/qs, @types/range-parser, @types/resolve, @types/semver, @types/serve-index, @types/serve-static, @types/sinonjs__fake-timers, @types/sizzle, @types/sockjs, @types/stack-utils, @types/three, @types/tough-cookie, @types/webpack, @types/webpack-dev-server, @types/webxr, @types/ws, @types/yargs, @types/yargs-parser, @types/yauzl. A copy of the source code may be downloaded from https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/babel__core), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/babel__generator), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/babel__template), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/babel__traverse), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/body-parser), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/bonjour), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/connect), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/connect-history-api-fallback), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/cron), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/eslint), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/eslint-scope), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/estree), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/express), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/express-serve-static-core), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/file-saver), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/fs-extra), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/graceful-fs), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/html-minifier-terser), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/http-proxy), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/istanbul-lib-coverage), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/istanbul-reports), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/jest), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/jsdom), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/json-schema), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/jsonfile), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/marked), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/mime), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/node), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/parse5), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/prettier), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/qs), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/range-parser), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/resolve), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/semver), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/serve-index), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/serve-static), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/sinonjs__fake-timers), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/sizzle), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/sockjs), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/stack-utils), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/three), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/tough-cookie), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/webpack), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/webxr), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/ws), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/yargs), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/yargs-parser), https://github.com/DefinitelyTyped/DefinitelyTyped.git (@types/yauzl). This software contains the following license and notice below:
2308
2308
 
2309
2309
  MIT License
2310
2310
 
@@ -17,8 +17,7 @@
17
17
  "webpackOverride": {
18
18
  "js": [
19
19
  "index.js",
20
- "services/navigator.js",
21
- "webpack-specific.js"
20
+ "services/navigator.js"
22
21
  ]
23
22
  }
24
23
  }
@@ -1 +1 @@
1
- "use strict";angular.module("c8y.cockpit.dataPointExplorer").controller("DataPointWidgetConfigCtrl",["$scope","c8yDataPointSvc",function(t,o){t.noActions=!0,t.dontSave=!0,t.onRealtimeAlarmFn=function(a){t.onAlarm=a},t.onRealtimeEventFn=function(a){t.onEvent=a};var a=function(a,t){var e=_.pick(t,"dateFrom","dateTo","aggregation","displayDateSelection","interval","realtime","displayDateSelection","widgetInstanceGlobalTimeContext","canDecoupleGlobalTimeContext"),n=o.getDefaultFilters();_.assign(a,n,e)};t.onBoxChanged=function(a){t.chartBox=a},t.data={},t.data.datapoints=_.cloneDeep(t.config.datapoints),t.data.alarmsEventsConfigs=_.cloneDeep(t.config.alarmsEventsConfigs),a(t.data,t.config),t.dateSelection=t.data.widgetInstanceGlobalTimeContext?"dashboard_context":t.data.displayDateSelection?"view_and_config":"config",t.$watch("dateSelection",function(){switch(t.dateSelection){case"dashboard_context":t.data.widgetInstanceGlobalTimeContext=!0;break;case"view_and_config":t.data.widgetInstanceGlobalTimeContext=!1,t.data.displayDateSelection=!0;break;case"config":default:t.data.widgetInstanceGlobalTimeContext=!1,t.data.displayDateSelection=!1}},!0),t.$watch("data",function(){t.data.widgetInstanceGlobalTimeContext&&(t.data.dateFrom=t.config.date?t.config.date[0]:t.data.dateFrom,t.data.dateTo=t.config.date?t.config.date[1]:t.data.dateTo,t.data.realtime=!1,t.data.displayDateSelection=!1,t.data.canDecoupleGlobalTimeContext=!1,t.data.interval=null),a(t.config,t.data),t.config.datapoints=t.data.graphDataPoints,t.config.alarmsEventsConfigs=t.data.graphAlarmsEventsConfigs},!0)}]);
1
+ "use strict";angular.module("c8y.cockpit.dataPointExplorer").controller("DataPointWidgetConfigCtrl",["$scope","c8yDataPointSvc","gettext",function(a,o,t){a.noActions=!0,a.dontSave=!0,a.onRealtimeAlarmFn=function(t){a.onAlarm=t},a.onRealtimeEventFn=function(t){a.onEvent=t},a.dateSelectionHelpPopoverText=t("Choose how to select a date range, the available options are:\n <ul class='m-l-0 p-l-8 m-t-8 m-b-0'>\n <li><b>Widget configuration:</b> restricts the date selection only to the widget configuration</li>\n <li><b>Widget and widget configuration:</b> restricts the date selection to the widget view and widget configuration only</li>\n <li><b>Dashboard time range:</b> restricts date selection to the global dashboard configuration only </li></ul>");var e=function(t,a){var e=_.pick(a,"dateFrom","dateTo","aggregation","displayDateSelection","interval","realtime","displayDateSelection","widgetInstanceGlobalTimeContext","canDecoupleGlobalTimeContext"),n=o.getDefaultFilters();_.assign(t,n,e)};a.onBoxChanged=function(t){a.chartBox=t},a.data={},a.data.datapoints=_.cloneDeep(a.config.datapoints),a.data.alarmsEventsConfigs=_.cloneDeep(a.config.alarmsEventsConfigs),e(a.data,a.config),a.dateSelection=a.data.widgetInstanceGlobalTimeContext?"dashboard_context":a.data.displayDateSelection?"view_and_config":"config",a.$watch("dateSelection",function(){switch(a.dateSelection){case"dashboard_context":a.data.widgetInstanceGlobalTimeContext=!0;break;case"view_and_config":a.data.widgetInstanceGlobalTimeContext=!1,a.data.displayDateSelection=!0;break;case"config":default:a.data.widgetInstanceGlobalTimeContext=!1,a.data.displayDateSelection=!1}},!0),a.$watch("data",function(){a.data.widgetInstanceGlobalTimeContext&&(a.data.dateFrom=a.config.date?a.config.date[0]:a.data.dateFrom,a.data.dateTo=a.config.date?a.config.date[1]:a.data.dateTo,a.data.realtime=!1,a.data.displayDateSelection=!1,a.data.canDecoupleGlobalTimeContext=!1,a.data.interval=null),e(a.config,a.data),a.config.datapoints=a.data.graphDataPoints,a.config.alarmsEventsConfigs=a.data.graphAlarmsEventsConfigs},!0)}]);
@@ -13,11 +13,7 @@
13
13
  type="button"
14
14
  class="btn-help btn-help--sm"
15
15
  aria-label="{{ 'Help' | translate }}"
16
- uib-popover-html="'Choose how to select a date range, the available options are:
17
- <ul class=\'m-l-0 p-l-8 m-t-8 m-b-0\'>
18
- <li><b>Widget configuration:</b> restricts the date selection only to the widget configuration</li>
19
- <li><b>Widget and widget configuration:</b> restricts the date selection to the widget view and widget configuration only</li>
20
- <li><b>Dashboard time range:</b> restricts date selection to the global dashboard configuration only </li></ul>' | translate"
16
+ uib-popover-html="dateSelectionHelpPopoverText | translate"
21
17
  popover-placement="right"
22
18
  popover-trigger="'focus'"
23
19
  popover-append-to-body="true"
@@ -1 +1 @@
1
- "use strict";!function(){function t(t,e){t.add({name:"Data points table",nameDisplay:e("Data points table"),description:e("A table display of a collection of data points"),templateUrl:":::PLUGIN_PATH:::/views/widget.html",configTemplateUrl:":::PLUGIN_PATH:::/views/widgetConfig.html",previewImage:":::PLUGIN_PATH:::/img/data-point-table-widget-pr.png",options:{noDeviceTarget:!0,minCol:6,datapointAttributes:["datapoints"]}})}t.$inject=["c8yComponentsProvider","gettext"],angular.module("c8y.cockpit.dataPointTable",[]).config(t)}();
1
+ "use strict";!function(){function t(t,e){t.add({name:"Data points table",nameDisplay:e("Data points table"),description:e("A table display of a collection of data points"),templateUrl:":::PLUGIN_PATH:::/views/widget.html",configTemplateUrl:":::PLUGIN_PATH:::/views/widgetConfig.html",previewImage:":::PLUGIN_PATH:::/img/data-point-table-widget-pr.png",options:{noDeviceTarget:!0,minCol:6,datapointAttributes:["datapoints"]},displaySettings:{globalTimeContext:!0}})}t.$inject=["c8yComponentsProvider","gettext"],angular.module("c8y.cockpit.dataPointTable",[]).config(t)}();
@@ -2,10 +2,16 @@
2
2
  <table class="table table-condensed table-striped table-vertical-middle table-fixed">
3
3
  <thead class="headers table-header-sticky">
4
4
  <tr>
5
- <th style="min-width: 140px !important; top: 33px; z-index: 9">
5
+ <th
6
+ style="
7
+ min-width: 140px !important;
8
+ top: var(--data-point-table-header-height);
9
+ z-index: 9;
10
+ "
11
+ >
6
12
  <div translate class="header-cell">Date and time</div>
7
13
  </th>
8
- <th ng-show="displayTarget" style="top: 33px; z-index: 9">
14
+ <th ng-show="displayTarget" style="top: var(--data-point-table-header-height); z-index: 9">
9
15
  <div translate class="header-cell">Device</div>
10
16
  </th>
11
17
  <th
@@ -14,7 +20,7 @@
14
20
  tooltip-popup-delay="500"
15
21
  tooltip-append-to-body="true"
16
22
  class="header-cell text-right"
17
- style="top: 33px; z-index: 9"
23
+ style="top: var(--data-point-table-header-height); z-index: 9"
18
24
  >
19
25
  <div class="text-truncate-wrap text-center d-inline-block">
20
26
  {{ datapoint.label }}
@@ -1,13 +1,20 @@
1
- <div ng-controller="c8yDataPointTableWidgetCtrl as ctrl">
1
+ <div
2
+ ng-controller="c8yDataPointTableWidgetCtrl as ctrl"
3
+ style="--data-point-table-header-height: {{
4
+ !child.config.widgetInstanceGlobalTimeContext
5
+ ? child.config.displayDateSelection || ctrl.realtime
6
+ ? ' 32px'
7
+ : '0'
8
+ : '0'
9
+ }}"
10
+ >
2
11
  <c8y-realtime-button
3
12
  ng-show="false"
4
13
  channel="{{ ctrl.channel }}"
5
14
  state="ctrl.realtime"
6
15
  on-data="onData($data)"
7
- >
8
- </c8y-realtime-button>
9
-
10
- <div class="d-flex sticky-top bg-level-0">
16
+ ></c8y-realtime-button>
17
+ <div class="d-flex sticky-top bg-level-0" ng-if="!child.config.widgetInstanceGlobalTimeContext">
11
18
  <div class="datepicker-container clearfix p-l-8 flex-grow">
12
19
  <div ng-if="child.config.displayDateSelection">
13
20
  <c8y-date-time-picker
@@ -18,8 +25,7 @@
18
25
  show-weeks="false"
19
26
  show-spinners="false"
20
27
  append-to-body="true"
21
- >
22
- </c8y-date-time-picker>
28
+ ></c8y-date-time-picker>
23
29
  <c8y-date-time-picker
24
30
  ng-model-options="{ debounce: 500 }"
25
31
  ng-model="child.config.dateTo"
@@ -28,11 +34,11 @@
28
34
  show-weeks="false"
29
35
  show-spinners="false"
30
36
  append-to-body="true"
31
- >
32
- </c8y-date-time-picker>
37
+ ></c8y-date-time-picker>
33
38
  </div>
34
39
  </div>
35
40
  <label
41
+ ng-if="ctrl.realtime"
36
42
  class="c8y-switch m-r-8 flex-no-shrink"
37
43
  title="{{ 'Automatically scrolls to the latest value' | translate }}"
38
44
  >
@@ -52,6 +58,5 @@
52
58
  rows-selectable="child.config.selectable"
53
59
  selected="child.config.selected"
54
60
  scroll-locked="ctrl.scrollLocked"
55
- >
56
- </c8y-data-point-table>
61
+ ></c8y-data-point-table>
57
62
  </div>
@@ -1,64 +1,111 @@
1
- <div ng-controller="DataPointWidgetConfigCtrl" ng-init="disableLocalStorage = true" class="no-card-context">
2
- <div class="row" style="height: calc(100vh - 406px);" ng-controller="c8yDataPointExplorerCtrl">
3
- <div class="col-md-5 bg-level-1 separator-top inner-scroll">
4
- <div class="p-l-24 bg-inherit">
5
- <div class="form-group m-b-0 p-b-8 p-t-8 separator-bottom">
6
- <label
7
- class="c8y-switch"
8
- title="{{ 'Show date selection' | translate }}"
9
- >
10
- <input type="checkbox" ng-model="data.displayDateSelection" />
11
- <span></span>
12
- <span>{{ 'Display date selection on the widget' | translate }}</span>
13
- </label>
14
- </div>
15
- <c8y-data-point-list
16
- datapoints="data.datapoints"
17
- allow-adding-data-points-from-context-mo-only="dashboard.deviceType && dashboard.deviceTypeValue"
18
- dont-save="true"
19
- class="bg-level-1"
20
- ></c8y-data-point-list>
21
- </div>
22
- </div>
23
- <div class="col-md-7 sticky-top">
24
- <div class="p-r-24 p-t-8">
25
- <div class="m-b-4 d-flex j-c-end gap-8">
26
- <c8y-realtime-button
27
- class="top-right-control"
28
- channel="{{ channel }}"
29
- state="data.realtime"
30
- on-data="onData($data)"
31
- ></c8y-realtime-button>
32
- <c8y-aggregation
33
- class="top-right-control"
34
- date-from="data.dateFrom"
35
- date-to="data.dateTo"
36
- aggregation="data.aggregation"
37
- realtime="data.realtime"
38
- auto="true"
39
- ></c8y-aggregation>
40
- <c8y-interval
41
- class="top-right-control"
42
- date-from="data.dateFrom"
43
- date-to="data.dateTo"
44
- interval="data.interval"
45
- ></c8y-interval>
46
- </div>
47
- <div class="c8yGraphFill" style="height: calc(100vh - 458px);">
48
- <c8y-chart
49
- datapoints="data.graphDataPoints"
50
- date-from="data.dateFrom"
51
- date-to="data.dateTo"
52
- realtime="data.realtime"
53
- aggregation="data.aggregation"
54
- show-time="true"
55
- on-data="(onData)"
56
- on-update-dates="onUpdateDates($dateFrom, $dateTo)"
57
- on-update-displayed-dates="onUpdateDisplayedDates($dateFrom, $dateTo)"
58
- on-box-changed="onBoxChanged(box)"
59
- ></c8y-chart>
60
- </div>
61
- </div>
62
- </div>
63
- </div>
64
- </div>
1
+ <div
2
+ ng-controller="DataPointWidgetConfigCtrl"
3
+ ng-init="disableLocalStorage = true"
4
+ class="row no-card-context d-flex"
5
+ style="height: calc(100vh - 406px);"
6
+ >
7
+ <div class="col-md-5 bg-level-1 a-s-stretch inner-scroll">
8
+ <div class="p-l-24 bg-inherit p-t-8">
9
+ <div class="form-group m-b-0 p-b-16 separator-bottom">
10
+ <label for="dateSelection">
11
+ {{ 'Date selection' | translate }}
12
+ <button
13
+ type="button"
14
+ class="btn-help btn-help--sm"
15
+ aria-label="{{ 'Help' | translate }}"
16
+ uib-popover-html="dateSelectionHelpPopoverText | translate"
17
+ popover-placement="right"
18
+ popover-trigger="'focus'"
19
+ popover-append-to-body="true"
20
+ ></button>
21
+ </label>
22
+ <div class="c8y-select-wrapper">
23
+ <select
24
+ id="dateSelection"
25
+ class="form-control"
26
+ title="{{ 'Date selection' | translate }}"
27
+ aria-label="{{ 'Date selection' | translate }}"
28
+ ng-model="dateSelection"
29
+ >
30
+ <option
31
+ title="{{ 'Widget configuration' | translate }}"
32
+ value="{{ 'config' }}"
33
+ >
34
+ {{ 'Widget configuration' | translate }}
35
+ </option>
36
+ <option
37
+ title="{{ 'Widget and widget configuration' | translate }}"
38
+ value="{{ 'view_and_config' }}"
39
+ >
40
+ {{ 'Widget and widget configuration' | translate }}
41
+ </option>
42
+ <option
43
+ title="{{ 'Dashboard time range' | translate }}"
44
+ value="{{ 'dashboard_context' }}"
45
+ >
46
+ {{ 'Dashboard time range' | translate }}
47
+ </option>
48
+ </select>
49
+ </div>
50
+ </div>
51
+
52
+ <c8y-data-point-list
53
+ datapoints="data.datapoints"
54
+ allow-adding-data-points-from-context-mo-only="dashboard.deviceType && dashboard.deviceTypeValue"
55
+ dont-save="true"
56
+ class="bg-inherit separator-bottom"
57
+ ></c8y-data-point-list>
58
+ </div>
59
+ </div>
60
+
61
+ <div class="col-md-7 sticky-top">
62
+ <div class="p-r-24 p-t-8">
63
+ <div
64
+ class="data-point-explorer d-flex d-col"
65
+ ng-controller="c8yDataPointExplorerCtrl"
66
+ >
67
+ <div class="m-b-4 m-t-4 d-flex j-c-end gap-8">
68
+ <c8y-realtime-button
69
+ ng-show="!data.widgetInstanceGlobalTimeContext"
70
+ class="top-right-control"
71
+ channel="{{ channel }}"
72
+ state="data.realtime"
73
+ on-data="onData($data)"
74
+ ></c8y-realtime-button>
75
+ <c8y-aggregation
76
+ class="top-right-control"
77
+ date-from="data.dateFrom"
78
+ date-to="data.dateTo"
79
+ aggregation="data.aggregation"
80
+ realtime="data.realtime"
81
+ auto="true"
82
+ ></c8y-aggregation>
83
+ <c8y-interval
84
+ ng-show="!data.widgetInstanceGlobalTimeContext"
85
+ class="top-right-control"
86
+ date-from="data.dateFrom"
87
+ date-to="data.dateTo"
88
+ interval="data.interval"
89
+ ></c8y-interval>
90
+ </div>
91
+ <div
92
+ class="c8yGraphFill"
93
+ style="height: calc(100vh - 520px);"
94
+ >
95
+ <c8y-chart
96
+ datapoints="data.graphDataPoints"
97
+ date-from="data.dateFrom"
98
+ date-to="data.dateTo"
99
+ realtime="data.realtime"
100
+ aggregation="data.aggregation"
101
+ show-time="!data.widgetInstanceGlobalTimeContext"
102
+ on-data="(onData)"
103
+ on-update-dates="onUpdateDates($dateFrom, $dateTo)"
104
+ on-update-displayed-dates="onUpdateDisplayedDates($dateFrom, $dateTo)"
105
+ on-box-changed="onBoxChanged(box)"
106
+ ></c8y-chart>
107
+ </div>
108
+ </div>
109
+ </div>
110
+ </div>
111
+ </div>
@@ -1 +1 @@
1
- "use strict";!function(){function t(i,c){var a=this;i.$watch("child.config.datapoints",function(t){var n=_(t).map("__target.id").compact().uniq().value();n.length?a.channel="/measurements/".concat(n.join(",")):a.channel=""}),i.$watch("child.config.realtime",function(t){a.realtime=!!t}),function(){var t=i.child.config.interval;if(t&&t!==c.custom.id){var n=_.find(c.intervals,function(t){return t.id===i.child.config.interval})||{};n.qty&&(i.child.config.dateFrom=moment().subtract(n.qty,n.unit).toDate(),i.child.config.dateTo=moment().toDate())}}()}t.$inject=["$scope","INTERVAL_CONSTANTS"],angular.module("c8y.cockpit.dataPointTable").controller("c8yDataPointTableWidgetCtrl",t)}();
1
+ "use strict";!function(){function t(n,c){var a=this;n.$watch("child.config.datapoints",function(t){var i=_(t).map("__target.id").compact().uniq().value();i.length?a.channel="/measurements/".concat(i.join(",")):a.channel=""}),n.$watch("child.config.realtime",function(t){a.realtime=!!t}),n.$watch("child.config.date",function(){n.child.config.widgetInstanceGlobalTimeContext&&(n.child.config.dateFrom=new Date(n.child.config.date[0]),n.child.config.dateTo=new Date(n.child.config.date[1]))}),function(){var t=n.child.config.interval;if(t&&t!==c.custom.id){var i=_.find(c.intervals,function(t){return t.id===n.child.config.interval})||{};i.qty&&(n.child.config.dateFrom=moment().subtract(i.qty,i.unit).toDate(),n.child.config.dateTo=moment().toDate())}}()}t.$inject=["$scope","INTERVAL_CONSTANTS"],angular.module("c8y.cockpit.dataPointTable").controller("c8yDataPointTableWidgetCtrl",t)}();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@c8y/ng1-modules",
3
- "version": "1017.67.0",
3
+ "version": "1017.69.0",
4
4
  "license": "Apache-2.0",
5
5
  "author": "Cumulocity",
6
6
  "description": "AngularJS modules for Cumulocity IoT applications.",
@@ -44,7 +44,6 @@
44
44
  "nvd3": "https://github.com/piotrjaw/nvd3/archive/v1.1.19.tar.gz",
45
45
  "objectpath": "1.1.0",
46
46
  "payment": "2.2.1",
47
- "three": "0.141.0",
48
47
  "tv4": "1.3.0",
49
48
  "ui-select": "0.19.8",
50
49
  "xterm": "3.14.5",
@@ -1 +0,0 @@
1
- "use strict";var options=window.C8Y_APP;options.sensorPhone&&(options.modules.push("c8y.rotation3d"),require("@c8y/ng1-modules/rotation3dWidget/cumulocity"));
@@ -1 +0,0 @@
1
- "use strict";!function(){function e(e,t){var n=this;function a(e){var t=_.get(e,"c8y_Acceleration");t&&(n.rotate=function(e){var t,n,a=_.round(e.accelerationX.value),c=_.round(e.accelerationY.value),o=_.round(e.accelerationZ.value);return t=Math.atan2(c,o),n=Math.atan2(a,Math.sqrt(c*c+o*o)),t=t?t%(2*Math.PI):0,n=n?n%(2*Math.PI):0,{x:t,y:0,z:n}}(t))}_.assign(n,{$onInit:function(){!function(){var e={fragment:"c8y_Acceleration",series:"accelerationZ"};n.config.device&&(e.device=n.config.device.id,t.latest(e,!0).then(function(e){n.latestMeasurement=e}))}(),e.$watch("vm.latestMeasurement",a,!0)}})}e.$inject=["$scope","c8yMeasurements"],angular.module("c8y.rotation3d").component("rotation3d",{templateUrl:":::PLUGIN_PATH:::/views/viewer3d.html",bindings:{config:"<"},controller:e,controllerAs:"vm"})}();
@@ -1 +0,0 @@
1
- "use strict";angular.module("c8y.rotation3d").component("rotation3dConfig",{templateUrl:":::PLUGIN_PATH:::/views/rotation3dConfig.html",bindings:{config:"="},controller:function(){var o=this;_.assign(o,{$onInit:function(){_.defaults(o.config,{objectModel:"box.min.json",isWireframe:!0,cameraType:"PC"})}})},controllerAs:"vm"});
@@ -1 +0,0 @@
1
- "use strict";function _slicedToArray(e,r){return _arrayWithHoles(e)||_iterableToArrayLimit(e,r)||_unsupportedIterableToArray(e,r)||_nonIterableRest()}function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _unsupportedIterableToArray(e,r){if(e){if("string"==typeof e)return _arrayLikeToArray(e,r);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?_arrayLikeToArray(e,r):void 0}}function _arrayLikeToArray(e,r){(null==r||r>e.length)&&(r=e.length);for(var t=0,n=new Array(r);t<r;t++)n[t]=e[t];return n}function _iterableToArrayLimit(e,r){var t=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=t){var n,a,i,o,c=[],l=!0,u=!1;try{if(i=(t=t.call(e)).next,0===r){if(Object(t)!==t)return;l=!1}else for(;!(l=(n=i.call(t)).done)&&(c.push(n.value),c.length!==r);l=!0);}catch(e){u=!0,a=e}finally{try{if(!l&&null!=t.return&&(o=t.return(),Object(o)!==o))return}finally{if(u)throw a}}return c}}function _arrayWithHoles(e){if(Array.isArray(e))return e}!function(){function e(e,r,a,t){var i,o,c=this,l=r.THREE;_.assign(c,{$onChanges:function(e){var r=e.rotate&&e.rotate.currentValue;r&&function(e){var t=s;_.isUndefined(t&&e)||_.forIn(e,function(e,r){!function(e,r,t){e.rotation[r]=t}(t,r,e)})}(r);(e.objectModel||e.isWireframe||e.cameraType)&&(i&&_.forEach(i.children,function(e){i.remove(e)}),function(){i=new l.Scene,o=window.WebGLRenderingContext?new l.WebGLRenderer({canvas:d,alpha:!0}):new l.CanvasRenderer;var e=new l.AmbientLight(16777215,.5),r=new l.DirectionalLight(16777215),t=new l.DirectionalLight(16777215);switch(c.cameraType){case"OC":u=new l.OrthographicCamera(-15,15,15,-15,1,1e3);break;case"PC":default:u=new l.PerspectiveCamera(30,d.clientWidth/d.clientHeight,.1,1e3)}r.position.set(20,25,30),t.position.set(-20,-25,-30),i.add(r),i.add(t),i.add(e),u.rotateX(Math.PI/2),u.rotateY(Math.PI/2),u.position.z=23,u.position.x=14,u.position.y=7,i.add(u),a.load(c.objectModel).then(function(e){_.forEach(e.children,function(e){e.material&&!_.isUndefined(e.material.wireframe)&&(e.material.wireframe=c.isWireframe)}),s=e,i.add(s)});var n=new l.OrbitControls(u,o.domElement);n.enableDamping=!0,n.dampingFactor=.25,n.rotateSpeed=.35,o.setClearColor(16777215,0)}(),n.runOutsideAngular(function(){f()}))}});var u,s,n,d=_slicedToArray(e.find("canvas"),1)[0];function f(){!function(){var e=d.clientWidth,r=d.clientHeight;d.width===e&&d.height===r||o.setSize(e,r,!1)}(),o.render(i,u),requestAnimationFrame(f)}n=t.has("ngZone")?t.get("ngZone"):{runOutsideAngular:function(e){return e()}}}e.$inject=["$element","$window","c8yWebSceneLoader","$injector"],angular.module("c8y.rotation3d").component("c8yWebScene",{template:'<canvas style="width:100%;"></canvas>',bindings:{rotate:"<",objectModel:"<",isWireframe:"<",cameraType:"<"},controller:e,controllerAs:"vm"})}();
@@ -1,26 +0,0 @@
1
- {
2
- "name": "rotation3d",
3
- "ngModules": ["c8y.rotation3d"],
4
- "category": "Widgets",
5
- "description": "widget for 3d position preview",
6
- "js": [
7
- "index.js",
8
- "components/viewer3d.component.js",
9
- "components/webscene.component.js",
10
- "components/viewer3dConfig.component.js",
11
- "webscene-loader.service.js",
12
- "node_modules/three/build/three.min.js",
13
- "node_modules/three/examples/js/controls/OrbitControls.js"
14
- ],
15
- "webpackOverride": {
16
- "js": [
17
- "index.js",
18
- "webpack-specific.js",
19
- "components/viewer3d.component.js",
20
- "components/webscene.component.js",
21
- "components/viewer3dConfig.component.js",
22
- "webscene-loader.service.js"
23
- ],
24
- "copy": ["img/*"]
25
- }
26
- }
@@ -1 +0,0 @@
1
- "use strict";!function(){function t(t,e){t.add({name:"rotation3d",nameDisplay:e("Rotation widget"),description:e("Displays current device orientation"),templateUrl:":::PLUGIN_PATH:::/views/rotation.html",configTemplateUrl:":::PLUGIN_PATH:::/views/rotationConfig.html",previewImage:":::PLUGIN_PATH:::/img/rotation-widget-pr.png",options:{groupSelectable:!1}})}t.$inject=["c8yComponentsProvider","gettext"],angular.module("c8y.rotation3d",[]).config(t)}();
@@ -1,82 +0,0 @@
1
- {
2
- "metadata": {
3
- "version": 4.5,
4
- "type": "Object",
5
- "generator": "Object3D.toJSON"
6
- },
7
- "geometries": [
8
- {
9
- "uuid": "008a44cb-1e9a-411b-a60b-24033a399485",
10
- "type": "BufferGeometry",
11
- "data": {
12
- "attributes": {
13
- "position": {
14
- "itemSize": 3,
15
- "type": "Float32Array",
16
- "array": [-1,-1,-1,-1,-1,1,-1,1,-1,-1,-1,1,-1,1,1,-1,1,-1,-1,1,-1,-1,1,1,1,1,-1,-1,1,1,1,1,1,1,1,-1,1,1,-1,1,1,1,1,-1,-1,1,1,1,1,-1,1,1,-1,-1,-1,-1,1,-1,-1,-1,1,-1,1,-1,-1,-1,1,-1,-1,1,-1,1,1,-1,-1,-1,-1,-1,1,1,-1,-1,-1,-1,-1,1,-1,1,1,-1,1,1,1,-1,1,1,1,-1,1,-1,1,1,-1,-1,1,1,-1,1],
17
- "normalized": false
18
- },
19
- "normal": {
20
- "itemSize": 3,
21
- "type": "Float32Array",
22
- "array": [-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0],
23
- "normalized": false
24
- },
25
- "color": {
26
- "itemSize": 3,
27
- "type": "Float32Array",
28
- "array": [1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1],
29
- "normalized": false
30
- }
31
- },
32
- "boundingSphere": {
33
- "center": [0,0,0],
34
- "radius": 1.7320508075688772
35
- }
36
- }
37
- }],
38
- "materials": [
39
- {
40
- "uuid": "12611d36-1d7a-4452-9611-cc8f8930ba98",
41
- "type": "MeshStandardMaterial",
42
- "name": "Material.001",
43
- "color": 4539084,
44
- "roughness": 0.5,
45
- "metalness": 0.5,
46
- "emissive": 0,
47
- "envMapIntensity": 1,
48
- "vertexColors": true,
49
- "depthFunc": 3,
50
- "depthTest": true,
51
- "depthWrite": true,
52
- "colorWrite": true,
53
- "stencilWrite": false,
54
- "stencilWriteMask": 255,
55
- "stencilFunc": 519,
56
- "stencilRef": 0,
57
- "stencilFuncMask": 255,
58
- "stencilFail": 7680,
59
- "stencilZFail": 7680,
60
- "stencilZPass": 7680
61
- }],
62
- "object": {
63
- "uuid": "9a04d950-5931-4eb9-bbbd-2214e520f6df",
64
- "type": "Group",
65
- "name": "box.gltf",
66
- "layers": 1,
67
- "matrix": [1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],
68
- "children": [
69
- {
70
- "uuid": "e0d36a1d-88cd-4f0b-83f3-cdd467b3416b",
71
- "type": "Mesh",
72
- "name": "Cube",
73
- "userData": {
74
- "name": "Cube"
75
- },
76
- "layers": 1,
77
- "matrix": [-3.5,0,0,0,0,-1.3322676295501878e-15,6,0,0,0.203663,4.5222270372846654e-17,0,-0.0451503,0.0332229,-0.03196,1],
78
- "geometry": "008a44cb-1e9a-411b-a60b-24033a399485",
79
- "material": "12611d36-1d7a-4452-9611-cc8f8930ba98"
80
- }]
81
- }
82
- }