@progress/kendo-vue-gauges 2.7.1 → 2.7.3-dev.202201070829

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.
Files changed (170) hide show
  1. package/dist/cdn/js/kendo-vue-gauges.js +1 -1
  2. package/dist/es/ArcCenter.d.ts +48 -0
  3. package/dist/es/ArcCenter.js +53 -0
  4. package/dist/es/ArcGauge.d.ts +43 -0
  5. package/dist/es/ArcGauge.js +196 -0
  6. package/dist/es/ArcGaugeProps.d.ts +33 -0
  7. package/dist/es/ArcGaugeProps.js +0 -0
  8. package/dist/es/BaseGauge.d.ts +42 -0
  9. package/dist/es/BaseGauge.js +222 -0
  10. package/dist/es/BaseGaugeProps.d.ts +42 -0
  11. package/dist/es/BaseGaugeProps.js +1 -0
  12. package/dist/es/CircularGauge.d.ts +38 -0
  13. package/dist/es/CircularGauge.js +33 -0
  14. package/dist/es/CircularGaugeProps.d.ts +17 -0
  15. package/dist/es/CircularGaugeProps.js +0 -0
  16. package/dist/es/GaugeContext.d.ts +1 -0
  17. package/dist/es/GaugeContext.js +12 -0
  18. package/dist/es/LinearGauge.d.ts +38 -0
  19. package/dist/es/LinearGauge.js +113 -0
  20. package/dist/es/LinearGaugeProps.d.ts +15 -0
  21. package/dist/es/LinearGaugeProps.js +0 -0
  22. package/dist/es/RadialGauge.d.ts +38 -0
  23. package/dist/es/RadialGauge.js +114 -0
  24. package/dist/es/RadialGaugeProps.d.ts +15 -0
  25. package/dist/es/RadialGaugeProps.js +0 -0
  26. package/dist/es/additionalTypes.ts +3 -0
  27. package/dist/es/common/gauges.d.ts +1 -0
  28. package/dist/es/common/gauges.js +5 -0
  29. package/dist/es/main.d.ts +10 -1
  30. package/dist/es/main.js +7 -8
  31. package/dist/es/package-metadata.js +1 -1
  32. package/dist/es/store/reducer.d.ts +14 -0
  33. package/dist/es/store/reducer.js +100 -0
  34. package/dist/es/store/store.d.ts +26 -0
  35. package/dist/es/store/store.js +28 -0
  36. package/dist/es/theming/theme-service.d.ts +3 -0
  37. package/dist/es/theming/theme-service.js +50 -0
  38. package/dist/es/types/arc-scale.interface.d.ts +28 -0
  39. package/dist/es/types/arc-scale.interface.js +1 -0
  40. package/dist/es/types/border.interface.d.ts +18 -0
  41. package/dist/es/types/border.interface.js +0 -0
  42. package/dist/es/types/cap.interface.d.ts +13 -0
  43. package/dist/es/types/cap.interface.js +0 -0
  44. package/dist/es/types/circular-scale.interface.d.ts +10 -0
  45. package/dist/es/types/circular-scale.interface.js +0 -0
  46. package/dist/es/types/color-range.interface.d.ts +21 -0
  47. package/dist/es/types/color-range.interface.js +0 -0
  48. package/dist/es/types/dash-type.interface.d.ts +4 -0
  49. package/dist/es/types/dash-type.interface.js +0 -0
  50. package/dist/es/types/gauge-area.interface.d.ts +27 -0
  51. package/dist/es/types/gauge-area.interface.js +0 -0
  52. package/dist/es/types/labels.interface.d.ts +47 -0
  53. package/dist/es/types/labels.interface.js +1 -0
  54. package/dist/es/types/line-cap.d.ts +4 -0
  55. package/dist/es/types/line-cap.js +0 -0
  56. package/dist/es/types/line.interface.d.ts +22 -0
  57. package/dist/es/types/line.interface.js +0 -0
  58. package/dist/es/types/linear-pointer-shape.d.ts +4 -0
  59. package/dist/es/types/linear-pointer-shape.js +0 -0
  60. package/dist/es/types/linear-pointer.interface.d.ts +36 -0
  61. package/dist/es/types/linear-pointer.interface.js +0 -0
  62. package/dist/es/types/linear-scale.interface.d.ts +26 -0
  63. package/dist/es/types/linear-scale.interface.js +1 -0
  64. package/dist/es/types/margin.interface.d.ts +21 -0
  65. package/dist/es/types/margin.interface.js +0 -0
  66. package/dist/es/types/padding.interface.d.ts +21 -0
  67. package/dist/es/types/padding.interface.js +0 -0
  68. package/dist/es/types/radial-label-position.d.ts +4 -0
  69. package/dist/es/types/radial-label-position.js +0 -0
  70. package/dist/es/types/radial-labels.interface.d.ts +8 -0
  71. package/dist/es/types/radial-labels.interface.js +0 -0
  72. package/dist/es/types/radial-pointer.interface.d.ts +22 -0
  73. package/dist/es/types/radial-pointer.interface.js +1 -0
  74. package/dist/es/types/radial-scale.interface.d.ts +28 -0
  75. package/dist/es/types/radial-scale.interface.js +1 -0
  76. package/dist/es/types/range.interface.d.ts +21 -0
  77. package/dist/es/types/range.interface.js +0 -0
  78. package/dist/es/types/scale.interface.d.ts +47 -0
  79. package/dist/es/types/scale.interface.js +0 -0
  80. package/dist/es/types/ticks.interface.d.ts +21 -0
  81. package/dist/es/types/ticks.interface.js +1 -0
  82. package/dist/es/types.d.ts +21 -0
  83. package/dist/es/types.js +0 -0
  84. package/dist/es/utils/common.d.ts +1 -0
  85. package/dist/es/utils/common.js +36 -0
  86. package/dist/npm/ArcCenter.d.ts +48 -0
  87. package/dist/npm/ArcCenter.js +63 -0
  88. package/dist/npm/ArcGauge.d.ts +43 -0
  89. package/dist/npm/ArcGauge.js +210 -0
  90. package/dist/npm/ArcGaugeProps.d.ts +33 -0
  91. package/dist/npm/ArcGaugeProps.js +5 -0
  92. package/dist/npm/BaseGauge.d.ts +42 -0
  93. package/dist/npm/BaseGauge.js +238 -0
  94. package/dist/npm/BaseGaugeProps.d.ts +42 -0
  95. package/dist/npm/BaseGaugeProps.js +5 -0
  96. package/dist/npm/CircularGauge.d.ts +38 -0
  97. package/dist/npm/CircularGauge.js +44 -0
  98. package/dist/npm/CircularGaugeProps.d.ts +17 -0
  99. package/dist/npm/CircularGaugeProps.js +5 -0
  100. package/dist/npm/GaugeContext.d.ts +1 -0
  101. package/dist/npm/GaugeContext.js +13 -0
  102. package/dist/npm/LinearGauge.d.ts +38 -0
  103. package/dist/npm/LinearGauge.js +126 -0
  104. package/dist/npm/LinearGaugeProps.d.ts +15 -0
  105. package/dist/npm/LinearGaugeProps.js +5 -0
  106. package/dist/npm/RadialGauge.d.ts +38 -0
  107. package/dist/npm/RadialGauge.js +127 -0
  108. package/dist/npm/RadialGaugeProps.d.ts +15 -0
  109. package/dist/npm/RadialGaugeProps.js +5 -0
  110. package/dist/npm/additionalTypes.ts +3 -0
  111. package/dist/npm/common/gauges.d.ts +1 -0
  112. package/dist/npm/common/gauges.js +5 -0
  113. package/dist/npm/main.d.ts +10 -1
  114. package/dist/npm/main.js +21 -8
  115. package/dist/npm/package-metadata.js +1 -1
  116. package/dist/npm/store/reducer.d.ts +14 -0
  117. package/dist/npm/store/reducer.js +105 -0
  118. package/dist/npm/store/store.d.ts +26 -0
  119. package/dist/npm/store/store.js +31 -0
  120. package/dist/npm/theming/theme-service.d.ts +3 -0
  121. package/dist/npm/theming/theme-service.js +53 -0
  122. package/dist/npm/types/arc-scale.interface.d.ts +28 -0
  123. package/dist/npm/types/arc-scale.interface.js +3 -0
  124. package/dist/npm/types/border.interface.d.ts +18 -0
  125. package/dist/npm/types/border.interface.js +2 -0
  126. package/dist/npm/types/cap.interface.d.ts +13 -0
  127. package/dist/npm/types/cap.interface.js +2 -0
  128. package/dist/npm/types/circular-scale.interface.d.ts +10 -0
  129. package/dist/npm/types/circular-scale.interface.js +2 -0
  130. package/dist/npm/types/color-range.interface.d.ts +21 -0
  131. package/dist/npm/types/color-range.interface.js +2 -0
  132. package/dist/npm/types/dash-type.interface.d.ts +4 -0
  133. package/dist/npm/types/dash-type.interface.js +2 -0
  134. package/dist/npm/types/gauge-area.interface.d.ts +27 -0
  135. package/dist/npm/types/gauge-area.interface.js +2 -0
  136. package/dist/npm/types/labels.interface.d.ts +47 -0
  137. package/dist/npm/types/labels.interface.js +3 -0
  138. package/dist/npm/types/line-cap.d.ts +4 -0
  139. package/dist/npm/types/line-cap.js +2 -0
  140. package/dist/npm/types/line.interface.d.ts +22 -0
  141. package/dist/npm/types/line.interface.js +2 -0
  142. package/dist/npm/types/linear-pointer-shape.d.ts +4 -0
  143. package/dist/npm/types/linear-pointer-shape.js +2 -0
  144. package/dist/npm/types/linear-pointer.interface.d.ts +36 -0
  145. package/dist/npm/types/linear-pointer.interface.js +2 -0
  146. package/dist/npm/types/linear-scale.interface.d.ts +26 -0
  147. package/dist/npm/types/linear-scale.interface.js +3 -0
  148. package/dist/npm/types/margin.interface.d.ts +21 -0
  149. package/dist/npm/types/margin.interface.js +2 -0
  150. package/dist/npm/types/padding.interface.d.ts +21 -0
  151. package/dist/npm/types/padding.interface.js +2 -0
  152. package/dist/npm/types/radial-label-position.d.ts +4 -0
  153. package/dist/npm/types/radial-label-position.js +2 -0
  154. package/dist/npm/types/radial-labels.interface.d.ts +8 -0
  155. package/dist/npm/types/radial-labels.interface.js +2 -0
  156. package/dist/npm/types/radial-pointer.interface.d.ts +22 -0
  157. package/dist/npm/types/radial-pointer.interface.js +3 -0
  158. package/dist/npm/types/radial-scale.interface.d.ts +28 -0
  159. package/dist/npm/types/radial-scale.interface.js +3 -0
  160. package/dist/npm/types/range.interface.d.ts +21 -0
  161. package/dist/npm/types/range.interface.js +2 -0
  162. package/dist/npm/types/scale.interface.d.ts +47 -0
  163. package/dist/npm/types/scale.interface.js +2 -0
  164. package/dist/npm/types/ticks.interface.d.ts +21 -0
  165. package/dist/npm/types/ticks.interface.js +3 -0
  166. package/dist/npm/types.d.ts +21 -0
  167. package/dist/npm/types.js +2 -0
  168. package/dist/npm/utils/common.d.ts +1 -0
  169. package/dist/npm/utils/common.js +39 -0
  170. package/package.json +7 -7
@@ -0,0 +1,105 @@
1
+ "use strict";
2
+ var __spreadArrays = (this && this.__spreadArrays) || function () {
3
+ for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
4
+ for (var r = Array(s), k = 0, i = 0; i < il; i++)
5
+ for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
6
+ r[k] = a[j];
7
+ return r;
8
+ };
9
+ Object.defineProperty(exports, "__esModule", { value: true });
10
+ exports.observersReducer = exports.themeReducer = exports.optionsReducer = void 0;
11
+ /**
12
+ * @hidden
13
+ */
14
+ var optionsReducer = function (currentState, action) {
15
+ if (action.gaugeCollectionIdxKey) {
16
+ return reducers.collectionConfigurationItem(currentState, action);
17
+ }
18
+ else if (action.gaugeKey) {
19
+ return reducers.configurationItem(currentState, action);
20
+ }
21
+ else {
22
+ return {};
23
+ }
24
+ };
25
+ exports.optionsReducer = optionsReducer;
26
+ /**
27
+ * @hidden
28
+ */
29
+ var themeReducer = function (currentState, action) {
30
+ if (action.type) {
31
+ switch (action.type) {
32
+ case 'set':
33
+ return reducers.themeItem(currentState, action);
34
+ case 'push':
35
+ return Object.assign(currentState, action.payload);
36
+ default:
37
+ return currentState;
38
+ }
39
+ }
40
+ else {
41
+ return {};
42
+ }
43
+ };
44
+ exports.themeReducer = themeReducer;
45
+ /**
46
+ * @hidden
47
+ */
48
+ var observersReducer = function (currentState, action) {
49
+ if (action.type) {
50
+ switch (action.type) {
51
+ case 'add':
52
+ return __spreadArrays(currentState, [action.payload]);
53
+ case 'remove':
54
+ return currentState.filter(function (element) { return element !== action.payload; });
55
+ default:
56
+ return currentState;
57
+ }
58
+ }
59
+ else {
60
+ return [];
61
+ }
62
+ };
63
+ exports.observersReducer = observersReducer;
64
+ /**
65
+ * @hidden
66
+ */
67
+ var reducers = {
68
+ configurationItem: function (currentState, action) {
69
+ var _a;
70
+ return Object.assign(currentState, (_a = {},
71
+ _a[action.gaugeKey] = action.payload,
72
+ _a));
73
+ },
74
+ collectionConfigurationItem: function (currentState, action) {
75
+ var _a;
76
+ var inCollection = false;
77
+ var _b = action.gaugeCollectionIdxKey.split('_'), collectionName = _b[0], collectionIdx = _b[1];
78
+ var collection = currentState[collectionName].map(function (item, index) {
79
+ if (parseInt(collectionIdx, 10) === index) {
80
+ inCollection = true;
81
+ return action.payload;
82
+ }
83
+ return item;
84
+ });
85
+ if (inCollection === false) {
86
+ collection.splice(parseInt(collectionIdx, 10), 0, action.payload);
87
+ }
88
+ return Object.assign(currentState, (_a = {},
89
+ _a[collectionName] = collection,
90
+ _a));
91
+ },
92
+ themeItem: function (currentState, action) {
93
+ var store = {};
94
+ var nextStore = Object.assign(store, currentState);
95
+ var _a = action.payload, field = _a.field, value = _a.value;
96
+ var parts = field.split('.');
97
+ var key = parts.shift();
98
+ while (parts.length > 0) {
99
+ store = store[key] = store[key] || {};
100
+ key = parts.shift();
101
+ }
102
+ store[key] = value;
103
+ return nextStore;
104
+ }
105
+ };
@@ -0,0 +1,26 @@
1
+ /**
2
+ * @hidden
3
+ */
4
+ export declare const THROTTLE_MS: number;
5
+ /**
6
+ * @hidden
7
+ */
8
+ export interface StoreAction {
9
+ gaugeKey?: string;
10
+ gaugeCollectionIdxKey?: string;
11
+ type?: string;
12
+ payload: any;
13
+ }
14
+ /**
15
+ * @hidden
16
+ */
17
+ export interface Store {
18
+ getState(): any;
19
+ dispatch(action: StoreAction | object): void;
20
+ subscribe(f: Function): Function;
21
+ }
22
+ /**
23
+ * @hidden
24
+ */
25
+ declare const createStore: (reducer: any) => Store;
26
+ export default createStore;
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.THROTTLE_MS = void 0;
4
+ var kendo_vue_common_1 = require("@progress/kendo-vue-common");
5
+ /**
6
+ * @hidden
7
+ */
8
+ exports.THROTTLE_MS = 1000 / 60;
9
+ /**
10
+ * @hidden
11
+ */
12
+ var createStore = function (reducer) {
13
+ var state;
14
+ var timerId;
15
+ var listeners = [];
16
+ var getState = function () { return state; };
17
+ var dispatch = function (action) {
18
+ state = reducer(state, action);
19
+ if (kendo_vue_common_1.canUseDOM) {
20
+ window.clearTimeout(timerId);
21
+ timerId = window.setTimeout(function () { return listeners.forEach(function (l) { return l(); }); }, exports.THROTTLE_MS);
22
+ }
23
+ };
24
+ var subscribe = function (listener) {
25
+ listeners.push(listener);
26
+ return function () { return listeners = listeners.filter(function (l) { return l !== listener; }); };
27
+ };
28
+ dispatch({});
29
+ return { getState: getState, dispatch: dispatch, subscribe: subscribe };
30
+ };
31
+ exports.default = createStore;
@@ -0,0 +1,3 @@
1
+ import { Store } from './../store/store';
2
+ declare const loadTheme: (store: Store, done: any) => void;
3
+ export { loadTheme };
@@ -0,0 +1,53 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.loadTheme = void 0;
4
+ var kendo_charts_1 = require("@progress/kendo-charts");
5
+ var template = "\n <div class=\"k-var--gauge-pointer\"></div>\n <div class=\"k-var--gauge-track\"></div>\n <div class=\"k-var--normal-text-color\"></div>\n";
6
+ /**
7
+ * @hidden
8
+ */
9
+ var ThemeService = /** @class */ (function () {
10
+ function ThemeService(store) {
11
+ this.store = store;
12
+ }
13
+ ThemeService.prototype.setStyle = function (field, value) {
14
+ this.store.dispatch({ type: 'set', payload: { field: field, value: value } });
15
+ };
16
+ ThemeService.prototype.setColors = function () {
17
+ this.mapColor('pointer.color', 'gauge-pointer');
18
+ this.mapColor('scale.rangePlaceholderColor', 'gauge-track');
19
+ this.mapColor('scale.labels.color', 'normal-text-color');
20
+ this.mapColor('scale.minorTicks.color', 'normal-text-color');
21
+ this.mapColor('scale.majorTicks.color', 'normal-text-color');
22
+ this.mapColor('scale.line.color', 'normal-text-color');
23
+ };
24
+ ThemeService.prototype.mapColor = function (key, varName) {
25
+ this.setStyle(key, this.queryStyle(varName).backgroundColor);
26
+ };
27
+ ThemeService.prototype.queryStyle = function (varName) {
28
+ var element = this.element;
29
+ return window.getComputedStyle(element.querySelector(".k-var--" + varName));
30
+ };
31
+ return ThemeService;
32
+ }());
33
+ var loadTheme = function (store, done) {
34
+ var service = new ThemeService(store);
35
+ if (typeof document === 'undefined') {
36
+ store.dispatch({ type: 'push', payload: kendo_charts_1.chartBaseTheme() });
37
+ return;
38
+ }
39
+ var container = service.element = document.createElement('div');
40
+ container.style.display = 'none';
41
+ container.innerHTML = template;
42
+ document.body.appendChild(container);
43
+ try {
44
+ store.dispatch({ type: 'push', payload: kendo_charts_1.chartBaseTheme() });
45
+ service.setColors();
46
+ }
47
+ finally {
48
+ document.body.removeChild(service.element);
49
+ delete service.element;
50
+ done();
51
+ }
52
+ };
53
+ exports.loadTheme = loadTheme;
@@ -0,0 +1,28 @@
1
+ import { RadialLabels } from './radial-labels.interface';
2
+ import { Scale } from './scale.interface';
3
+ import { LineCap } from './line-cap';
4
+ /**
5
+ * The scale options of the Gauge.
6
+ */
7
+ export interface ArcScale extends Scale {
8
+ /**
9
+ * Configures the scale labels.
10
+ */
11
+ labels?: RadialLabels;
12
+ /**
13
+ * The distance between the range indicators and the ticks.
14
+ */
15
+ rangeDistance?: number;
16
+ /**
17
+ * The `lineCap` style of the ranges.
18
+ */
19
+ rangeLineCap?: LineCap;
20
+ /**
21
+ * The starting angle of the Gauge. The Gauge is rendered clockwise (0 degrees equal 180 degrees in the polar coordinate system).
22
+ */
23
+ startAngle?: number;
24
+ /**
25
+ * The ending angle of the Gauge. The Gauge is rendered clockwise (0 degrees equals 180 degrees in the polar coordinate system).
26
+ */
27
+ endAngle?: number;
28
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // tslint:enable:max-line-length
@@ -0,0 +1,18 @@
1
+ import { DashType } from './dash-type.interface';
2
+ /**
3
+ * The appearance settings for the border lines.
4
+ */
5
+ export interface Border {
6
+ /**
7
+ * The color of the border line. Accepts valid CSS color strings, including hex and rgb.
8
+ */
9
+ color?: string;
10
+ /**
11
+ * The dash type of the border line.
12
+ */
13
+ dashType?: DashType;
14
+ /**
15
+ * The width of the border line in pixels.
16
+ */
17
+ width?: number;
18
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,13 @@
1
+ /**
2
+ * The configuration options for the RadialGauge pointer cap.
3
+ */
4
+ export interface Cap {
5
+ /**
6
+ * The color of the cap. Accepts valid CSS color strings, including hex and rgb.
7
+ */
8
+ color?: string;
9
+ /**
10
+ * The size of the cap in percent (from 0 to 1).
11
+ */
12
+ size?: number;
13
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,10 @@
1
+ import { ArcScale } from './arc-scale.interface';
2
+ /**
3
+ * The scale options of the Gauge.
4
+ */
5
+ export interface CircularScale extends ArcScale {
6
+ /**
7
+ * @hidden
8
+ */
9
+ endAngle?: number;
10
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,21 @@
1
+ /**
2
+ * The color range configuration.
3
+ */
4
+ export interface ColorRange {
5
+ /**
6
+ * The color of the range. Accepts valid CSS color strings, including hex and rgb.
7
+ */
8
+ color?: string;
9
+ /**
10
+ * The opacity of the range.
11
+ */
12
+ opacity?: number;
13
+ /**
14
+ * The range start value.
15
+ */
16
+ from?: number;
17
+ /**
18
+ * The range end value.
19
+ */
20
+ to?: number;
21
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,4 @@
1
+ /**
2
+ * The dash type of a line.
3
+ */
4
+ export declare type DashType = 'dash' | 'dashDot' | 'dot' | 'longDash' | 'longDashDot' | 'longDashDotDot' | 'solid';
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,27 @@
1
+ import { Border } from './border.interface';
2
+ import { Margin } from './margin.interface';
3
+ /**
4
+ * The configuration options for the Gauge area. Represents the entire visible area of the Gauge.
5
+ */
6
+ export interface GaugeArea {
7
+ /**
8
+ * The background of the Gauge area. Accepts valid CSS color strings, including hex and rgb.
9
+ */
10
+ background?: string;
11
+ /**
12
+ * The border of the Gauge area.
13
+ */
14
+ border?: Border;
15
+ /**
16
+ * The height of the Gauge area.
17
+ */
18
+ height?: number;
19
+ /**
20
+ * The margin of the Gauge area.
21
+ */
22
+ margin?: number | Margin;
23
+ /**
24
+ * The height of the Gauge area.
25
+ */
26
+ width?: number;
27
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,47 @@
1
+ import { Border } from './border.interface';
2
+ import { Margin } from './margin.interface';
3
+ import { Padding } from './padding.interface';
4
+ /**
5
+ * The configuration of the scale labels.
6
+ */
7
+ export interface Labels {
8
+ /**
9
+ * The background of the labels. Accepts valid CSS color strings, including hex and rgb.
10
+ */
11
+ background?: string;
12
+ /**
13
+ * The border of the labels.
14
+ */
15
+ border?: Border;
16
+ /**
17
+ * The color of the labels. Accepts valid CSS color strings, including hex and rgb.
18
+ */
19
+ color?: string;
20
+ /**
21
+ * The font of the labels.
22
+ */
23
+ font?: string;
24
+ /**
25
+ * The format that is used to display the labels. Uses the IntlService [`format`]({% slug api_intl_intlservice %}#toc-format) method.
26
+ */
27
+ format?: string;
28
+ /**
29
+ * The margin of the labels.
30
+ */
31
+ margin?: number | Margin;
32
+ /**
33
+ * The padding of the labels.
34
+ */
35
+ padding?: number | Padding;
36
+ /**
37
+ * The function which returns the label content.
38
+ *
39
+ * The available fields in the function argument are:
40
+ * - `value`&mdash;The value of the label.
41
+ */
42
+ content?: (e: any) => string;
43
+ /**
44
+ * The visibility of the labels.
45
+ */
46
+ visible?: boolean;
47
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // tslint:enable:max-line-length
@@ -0,0 +1,4 @@
1
+ /**
2
+ * The cap style of a line.
3
+ */
4
+ export declare type LineCap = 'butt' | 'round' | 'square';
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,22 @@
1
+ import { DashType } from './dash-type.interface';
2
+ /**
3
+ * The scale line options.
4
+ */
5
+ export interface Line {
6
+ /**
7
+ * The color of the lines. Accepts valid CSS color strings, including hex and rgb.
8
+ */
9
+ color?: string;
10
+ /**
11
+ * The dash type of the line.
12
+ */
13
+ dashType?: DashType;
14
+ /**
15
+ * The visibility of the lines.
16
+ */
17
+ visible?: boolean;
18
+ /**
19
+ * The width of the line.
20
+ */
21
+ width?: number;
22
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,4 @@
1
+ /**
2
+ * The shape of the pointer.
3
+ */
4
+ export declare type LinearPointerShape = 'barIndicator' | 'arrow';
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,36 @@
1
+ import { Border } from './border.interface';
2
+ import { Margin } from './margin.interface';
3
+ import { LinearPointerShape } from './linear-pointer-shape';
4
+ /**
5
+ * The configuration options for the LinearGauge pointer.
6
+ */
7
+ export interface LinearPointer {
8
+ /**
9
+ * The border of the Gauge area.
10
+ */
11
+ border?: Border;
12
+ /**
13
+ * The color of the pointer. Accepts valid CSS color strings, including hex and rgb.
14
+ */
15
+ color?: string;
16
+ /**
17
+ * The margin of the pointer.
18
+ */
19
+ margin?: number | Margin;
20
+ /**
21
+ * The opacity of the pointer.
22
+ */
23
+ opacity?: number;
24
+ /**
25
+ * The shape of the pointer.
26
+ */
27
+ shape?: LinearPointerShape;
28
+ /**
29
+ * The size of the pointer.
30
+ */
31
+ size?: number;
32
+ /**
33
+ * The value of the pointer.
34
+ */
35
+ value?: number;
36
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,26 @@
1
+ import { Scale } from './scale.interface';
2
+ import { Line } from './line.interface';
3
+ import { Range } from './range.interface';
4
+ /**
5
+ * The scale options of the Gauge.
6
+ */
7
+ export interface LinearScale extends Scale {
8
+ /**
9
+ * Configures the scale line.
10
+ */
11
+ line?: Line;
12
+ /**
13
+ * The ranges of the scale.
14
+ */
15
+ ranges?: Range[];
16
+ /**
17
+ * Mirrors the scale labels and ticks. If the labels are normally on the left side of the scale, the mirroring of the scale will render them to the right.
18
+ */
19
+ mirror?: boolean;
20
+ /**
21
+ * Specifies if the scale will be vertical ([see example]({% slug orientation_lineargauge %})).
22
+ *
23
+ * @default true
24
+ */
25
+ vertical?: boolean;
26
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // tslint:enable:max-line-length
@@ -0,0 +1,21 @@
1
+ /**
2
+ * The margin configuration for each side.
3
+ */
4
+ export interface Margin {
5
+ /**
6
+ * The top margin in pixels.
7
+ */
8
+ top?: number;
9
+ /**
10
+ * The right margin in pixels.
11
+ */
12
+ right?: number;
13
+ /**
14
+ * The bottom margin in pixels.
15
+ */
16
+ bottom?: number;
17
+ /**
18
+ * The left margin in pixels.
19
+ */
20
+ left?: number;
21
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,21 @@
1
+ /**
2
+ * The padding configuration for each side.
3
+ */
4
+ export interface Padding {
5
+ /**
6
+ * The top padding in pixels.
7
+ */
8
+ top?: number;
9
+ /**
10
+ * The right padding in pixels.
11
+ */
12
+ right?: number;
13
+ /**
14
+ * The bottom padding in pixels.
15
+ */
16
+ bottom?: number;
17
+ /**
18
+ * The left padding in pixels.
19
+ */
20
+ left?: number;
21
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,4 @@
1
+ /**
2
+ * The position of the RadialGauge labels.
3
+ */
4
+ export declare type RadialLabelPosition = 'inside' | 'outside';
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,8 @@
1
+ import { Labels } from './labels.interface';
2
+ import { RadialLabelPosition } from './radial-label-position';
3
+ export interface RadialLabels extends Labels {
4
+ /**
5
+ * The position of the labels.
6
+ */
7
+ position?: RadialLabelPosition;
8
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,22 @@
1
+ import { Cap } from './cap.interface';
2
+ /**
3
+ * The configuration options for the RadialGauge pointer.
4
+ */
5
+ export interface RadialPointer {
6
+ /**
7
+ * The configuration options for the cap.
8
+ */
9
+ cap?: Cap;
10
+ /**
11
+ * The color of the pointer. Accepts valid CSS color strings, including hex and rgb.
12
+ */
13
+ color?: string;
14
+ /**
15
+ * The pointer length (in percent) that is based on the distance to the scale. The default length of `1` indicates that the pointer exactly reaches the scale. Accepts values between `0.1` and `1.5`.
16
+ */
17
+ length?: number;
18
+ /**
19
+ * The pointer value.
20
+ */
21
+ value?: number;
22
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ // tslint:enable:max-line-length