inviton-powerduck 0.0.183 → 0.0.185
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/common/ajax-xhr.ts +4 -1
- package/common/api-http.ts +8 -0
- package/common/css/ladda-themeless-zoomin.min.css +89 -89
- package/common/extensions/temporal-extensions.ts +25 -1
- package/common/utils/temporal-utils.ts +38 -1
- package/components/chart-js/thirdparty/flot/jquery.flot.categories.min.js +93 -93
- package/components/chart-js/thirdparty/flot/jquery.flot.crosshair.min.js +83 -83
- package/components/chart-js/thirdparty/flot/jquery.flot.navigate.min.js +270 -270
- package/components/chart-js/thirdparty/flot/jquery.flot.pie.min.js +507 -507
- package/components/chart-js/thirdparty/flot/jquery.flot.stack.min.js +104 -104
- package/components/dropdown/index.tsx +39 -31
- package/components/image-crop/vendor/jquery.Jcrop.min.css +344 -344
- package/components/input/plugins/daterangepicker/daterangepicker.min.css +400 -400
- package/components/svg/skilift-svg.tsx +6 -6
- package/package.json +1 -1
|
@@ -1,104 +1,104 @@
|
|
|
1
|
-
/* Javascript plotting library for jQuery, version 0.8.3.
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2007-2014 IOLA and Ole Laursen.
|
|
4
|
-
Licensed under the MIT license.
|
|
5
|
-
|
|
6
|
-
*/
|
|
7
|
-
(function ($) {
|
|
8
|
-
var options = { series: { stack: null } };
|
|
9
|
-
function init(plot) {
|
|
10
|
-
function findMatchingSeries(s, allseries) {
|
|
11
|
-
var res = null;
|
|
12
|
-
for (var i = 0; i < allseries.length; ++i) {
|
|
13
|
-
if (s == allseries[i]) break;
|
|
14
|
-
if (allseries[i].stack == s.stack) res = allseries[i];
|
|
15
|
-
}
|
|
16
|
-
return res;
|
|
17
|
-
}
|
|
18
|
-
function stackData(plot, s, datapoints) {
|
|
19
|
-
if (s.stack == null || s.stack === false) return;
|
|
20
|
-
var other = findMatchingSeries(s, plot.getData());
|
|
21
|
-
if (!other) return;
|
|
22
|
-
var ps = datapoints.pointsize,
|
|
23
|
-
points = datapoints.points,
|
|
24
|
-
otherps = other.datapoints.pointsize,
|
|
25
|
-
otherpoints = other.datapoints.points,
|
|
26
|
-
newpoints = [],
|
|
27
|
-
px,
|
|
28
|
-
py,
|
|
29
|
-
intery,
|
|
30
|
-
qx,
|
|
31
|
-
qy,
|
|
32
|
-
bottom,
|
|
33
|
-
withlines = s.lines.show,
|
|
34
|
-
horizontal = s.bars.horizontal,
|
|
35
|
-
withbottom = ps > 2 && (horizontal ? datapoints.format[2].x : datapoints.format[2].y),
|
|
36
|
-
withsteps = withlines && s.lines.steps,
|
|
37
|
-
fromgap = true,
|
|
38
|
-
keyOffset = horizontal ? 1 : 0,
|
|
39
|
-
accumulateOffset = horizontal ? 0 : 1,
|
|
40
|
-
i = 0,
|
|
41
|
-
j = 0,
|
|
42
|
-
l,
|
|
43
|
-
m;
|
|
44
|
-
while (true) {
|
|
45
|
-
if (i >= points.length) break;
|
|
46
|
-
l = newpoints.length;
|
|
47
|
-
if (points[i] == null) {
|
|
48
|
-
for (m = 0; m < ps; ++m) newpoints.push(points[i + m]);
|
|
49
|
-
i += ps;
|
|
50
|
-
} else if (j >= otherpoints.length) {
|
|
51
|
-
if (!withlines) {
|
|
52
|
-
for (m = 0; m < ps; ++m) newpoints.push(points[i + m]);
|
|
53
|
-
}
|
|
54
|
-
i += ps;
|
|
55
|
-
} else if (otherpoints[j] == null) {
|
|
56
|
-
for (m = 0; m < ps; ++m) newpoints.push(null);
|
|
57
|
-
fromgap = true;
|
|
58
|
-
j += otherps;
|
|
59
|
-
} else {
|
|
60
|
-
px = points[i + keyOffset];
|
|
61
|
-
py = points[i + accumulateOffset];
|
|
62
|
-
qx = otherpoints[j + keyOffset];
|
|
63
|
-
qy = otherpoints[j + accumulateOffset];
|
|
64
|
-
bottom = 0;
|
|
65
|
-
if (px == qx) {
|
|
66
|
-
for (m = 0; m < ps; ++m) newpoints.push(points[i + m]);
|
|
67
|
-
newpoints[l + accumulateOffset] += qy;
|
|
68
|
-
bottom = qy;
|
|
69
|
-
i += ps;
|
|
70
|
-
j += otherps;
|
|
71
|
-
} else if (px > qx) {
|
|
72
|
-
if (withlines && i > 0 && points[i - ps] != null) {
|
|
73
|
-
intery = py + ((points[i - ps + accumulateOffset] - py) * (qx - px)) / (points[i - ps + keyOffset] - px);
|
|
74
|
-
newpoints.push(qx);
|
|
75
|
-
newpoints.push(intery + qy);
|
|
76
|
-
for (m = 2; m < ps; ++m) newpoints.push(points[i + m]);
|
|
77
|
-
bottom = qy;
|
|
78
|
-
}
|
|
79
|
-
j += otherps;
|
|
80
|
-
} else {
|
|
81
|
-
if (fromgap && withlines) {
|
|
82
|
-
i += ps;
|
|
83
|
-
continue;
|
|
84
|
-
}
|
|
85
|
-
for (m = 0; m < ps; ++m) newpoints.push(points[i + m]);
|
|
86
|
-
if (withlines && j > 0 && otherpoints[j - otherps] != null)
|
|
87
|
-
bottom = qy + ((otherpoints[j - otherps + accumulateOffset] - qy) * (px - qx)) / (otherpoints[j - otherps + keyOffset] - qx);
|
|
88
|
-
newpoints[l + accumulateOffset] += bottom;
|
|
89
|
-
i += ps;
|
|
90
|
-
}
|
|
91
|
-
fromgap = false;
|
|
92
|
-
if (l != newpoints.length && withbottom) newpoints[l + 2] += bottom;
|
|
93
|
-
}
|
|
94
|
-
if (withsteps && l != newpoints.length && l > 0 && newpoints[l] != null && newpoints[l] != newpoints[l - ps] && newpoints[l + 1] != newpoints[l - ps + 1]) {
|
|
95
|
-
for (m = 0; m < ps; ++m) newpoints[l + ps + m] = newpoints[l + m];
|
|
96
|
-
newpoints[l + 1] = newpoints[l - ps + 1];
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
datapoints.points = newpoints;
|
|
100
|
-
}
|
|
101
|
-
plot.hooks.processDatapoints.push(stackData);
|
|
102
|
-
}
|
|
103
|
-
$.plot.plugins.push({ init: init, options: options, name: "stack", version: "1.2" });
|
|
104
|
-
})(jQuery);
|
|
1
|
+
/* Javascript plotting library for jQuery, version 0.8.3.
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2007-2014 IOLA and Ole Laursen.
|
|
4
|
+
Licensed under the MIT license.
|
|
5
|
+
|
|
6
|
+
*/
|
|
7
|
+
(function ($) {
|
|
8
|
+
var options = { series: { stack: null } };
|
|
9
|
+
function init(plot) {
|
|
10
|
+
function findMatchingSeries(s, allseries) {
|
|
11
|
+
var res = null;
|
|
12
|
+
for (var i = 0; i < allseries.length; ++i) {
|
|
13
|
+
if (s == allseries[i]) break;
|
|
14
|
+
if (allseries[i].stack == s.stack) res = allseries[i];
|
|
15
|
+
}
|
|
16
|
+
return res;
|
|
17
|
+
}
|
|
18
|
+
function stackData(plot, s, datapoints) {
|
|
19
|
+
if (s.stack == null || s.stack === false) return;
|
|
20
|
+
var other = findMatchingSeries(s, plot.getData());
|
|
21
|
+
if (!other) return;
|
|
22
|
+
var ps = datapoints.pointsize,
|
|
23
|
+
points = datapoints.points,
|
|
24
|
+
otherps = other.datapoints.pointsize,
|
|
25
|
+
otherpoints = other.datapoints.points,
|
|
26
|
+
newpoints = [],
|
|
27
|
+
px,
|
|
28
|
+
py,
|
|
29
|
+
intery,
|
|
30
|
+
qx,
|
|
31
|
+
qy,
|
|
32
|
+
bottom,
|
|
33
|
+
withlines = s.lines.show,
|
|
34
|
+
horizontal = s.bars.horizontal,
|
|
35
|
+
withbottom = ps > 2 && (horizontal ? datapoints.format[2].x : datapoints.format[2].y),
|
|
36
|
+
withsteps = withlines && s.lines.steps,
|
|
37
|
+
fromgap = true,
|
|
38
|
+
keyOffset = horizontal ? 1 : 0,
|
|
39
|
+
accumulateOffset = horizontal ? 0 : 1,
|
|
40
|
+
i = 0,
|
|
41
|
+
j = 0,
|
|
42
|
+
l,
|
|
43
|
+
m;
|
|
44
|
+
while (true) {
|
|
45
|
+
if (i >= points.length) break;
|
|
46
|
+
l = newpoints.length;
|
|
47
|
+
if (points[i] == null) {
|
|
48
|
+
for (m = 0; m < ps; ++m) newpoints.push(points[i + m]);
|
|
49
|
+
i += ps;
|
|
50
|
+
} else if (j >= otherpoints.length) {
|
|
51
|
+
if (!withlines) {
|
|
52
|
+
for (m = 0; m < ps; ++m) newpoints.push(points[i + m]);
|
|
53
|
+
}
|
|
54
|
+
i += ps;
|
|
55
|
+
} else if (otherpoints[j] == null) {
|
|
56
|
+
for (m = 0; m < ps; ++m) newpoints.push(null);
|
|
57
|
+
fromgap = true;
|
|
58
|
+
j += otherps;
|
|
59
|
+
} else {
|
|
60
|
+
px = points[i + keyOffset];
|
|
61
|
+
py = points[i + accumulateOffset];
|
|
62
|
+
qx = otherpoints[j + keyOffset];
|
|
63
|
+
qy = otherpoints[j + accumulateOffset];
|
|
64
|
+
bottom = 0;
|
|
65
|
+
if (px == qx) {
|
|
66
|
+
for (m = 0; m < ps; ++m) newpoints.push(points[i + m]);
|
|
67
|
+
newpoints[l + accumulateOffset] += qy;
|
|
68
|
+
bottom = qy;
|
|
69
|
+
i += ps;
|
|
70
|
+
j += otherps;
|
|
71
|
+
} else if (px > qx) {
|
|
72
|
+
if (withlines && i > 0 && points[i - ps] != null) {
|
|
73
|
+
intery = py + ((points[i - ps + accumulateOffset] - py) * (qx - px)) / (points[i - ps + keyOffset] - px);
|
|
74
|
+
newpoints.push(qx);
|
|
75
|
+
newpoints.push(intery + qy);
|
|
76
|
+
for (m = 2; m < ps; ++m) newpoints.push(points[i + m]);
|
|
77
|
+
bottom = qy;
|
|
78
|
+
}
|
|
79
|
+
j += otherps;
|
|
80
|
+
} else {
|
|
81
|
+
if (fromgap && withlines) {
|
|
82
|
+
i += ps;
|
|
83
|
+
continue;
|
|
84
|
+
}
|
|
85
|
+
for (m = 0; m < ps; ++m) newpoints.push(points[i + m]);
|
|
86
|
+
if (withlines && j > 0 && otherpoints[j - otherps] != null)
|
|
87
|
+
bottom = qy + ((otherpoints[j - otherps + accumulateOffset] - qy) * (px - qx)) / (otherpoints[j - otherps + keyOffset] - qx);
|
|
88
|
+
newpoints[l + accumulateOffset] += bottom;
|
|
89
|
+
i += ps;
|
|
90
|
+
}
|
|
91
|
+
fromgap = false;
|
|
92
|
+
if (l != newpoints.length && withbottom) newpoints[l + 2] += bottom;
|
|
93
|
+
}
|
|
94
|
+
if (withsteps && l != newpoints.length && l > 0 && newpoints[l] != null && newpoints[l] != newpoints[l - ps] && newpoints[l + 1] != newpoints[l - ps + 1]) {
|
|
95
|
+
for (m = 0; m < ps; ++m) newpoints[l + ps + m] = newpoints[l + m];
|
|
96
|
+
newpoints[l + 1] = newpoints[l - ps + 1];
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
datapoints.points = newpoints;
|
|
100
|
+
}
|
|
101
|
+
plot.hooks.processDatapoints.push(stackData);
|
|
102
|
+
}
|
|
103
|
+
$.plot.plugins.push({ init: init, options: options, name: "stack", version: "1.2" });
|
|
104
|
+
})(jQuery);
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { DropdownButtonItemArgs } from '../dropdown-button/dropdown-button-item';
|
|
2
2
|
import type { FormItemWrapperArgs, MarginType } from '../form/form-item-wrapper';
|
|
3
|
-
import { globalState } from '../../app/global-state';
|
|
4
3
|
import Sortable from 'sortablejs';
|
|
5
4
|
import { h as _h, h, render, VNodeChild } from 'vue';
|
|
6
5
|
import { Prop, toNative } from 'vue-facing-decorator';
|
|
6
|
+
import { globalState } from '../../app/global-state';
|
|
7
7
|
import PowerduckState from '../../app/powerduck-state';
|
|
8
8
|
import TsxComponent, { Component } from '../../app/vuetsx';
|
|
9
9
|
import { remove } from '../../common/extensions/array-extensions';
|
|
@@ -327,16 +327,30 @@ class DropdownListComponent extends TsxComponent<DropdownListArgs> implements Dr
|
|
|
327
327
|
return retArr;
|
|
328
328
|
}
|
|
329
329
|
|
|
330
|
-
getMobileSelectionText(): string {
|
|
330
|
+
getMobileSelectionText(): { text: string; placeholder: boolean } {
|
|
331
331
|
const opts = this.getOptions();
|
|
332
332
|
const selectedItems = this.getSelectedItems();
|
|
333
333
|
|
|
334
334
|
if (selectedItems.length > 2 || (this.mobileShortMode == true && selectedItems.length > 0)) {
|
|
335
|
-
return
|
|
335
|
+
return {
|
|
336
|
+
text: PowerduckState.getResourceValue('itemsOutOfArray').replace('{0}', selectedItems.length.toString()).replace('{1}', opts.length.toString()),
|
|
337
|
+
placeholder: false,
|
|
338
|
+
};
|
|
336
339
|
} else if (selectedItems.length == 1) {
|
|
337
|
-
return
|
|
340
|
+
return {
|
|
341
|
+
placeholder: false,
|
|
342
|
+
text: selectedItems[0].text,
|
|
343
|
+
};
|
|
344
|
+
} else if ((selectedItems == null || selectedItems.length == 0) && this.placeholder?.length > 0) {
|
|
345
|
+
return {
|
|
346
|
+
placeholder: true,
|
|
347
|
+
text: this.placeholder,
|
|
348
|
+
};
|
|
338
349
|
} else {
|
|
339
|
-
return
|
|
350
|
+
return {
|
|
351
|
+
placeholder: false,
|
|
352
|
+
text: selectedItems.map(p => p.text).join(', '),
|
|
353
|
+
};
|
|
340
354
|
}
|
|
341
355
|
}
|
|
342
356
|
|
|
@@ -418,21 +432,14 @@ class DropdownListComponent extends TsxComponent<DropdownListArgs> implements Dr
|
|
|
418
432
|
}
|
|
419
433
|
|
|
420
434
|
renderMobileComponent(h) {
|
|
421
|
-
|
|
422
|
-
if (selectedText == null || selectedText.length == 0) {
|
|
423
|
-
selectedText = this.placeholder || '';
|
|
424
|
-
}
|
|
425
|
-
|
|
426
|
-
if (isNullOrEmpty(selectedText) && this.multiselect == true) {
|
|
427
|
-
selectedText = `[${PowerduckState.getResourceValue('all')}]`;
|
|
428
|
-
}
|
|
435
|
+
const selText = this.getMobileSelectionText();
|
|
429
436
|
|
|
430
437
|
return (
|
|
431
438
|
<span ref="mobileModeRoot" onClick={e => this.showMobilePicker(h)} class={`select2 select2-container select2-container--default s2-pseudo maxwidth-input ${this.getRootBaseCssClass()}`} dir="ltr">
|
|
432
439
|
<span class="selection">
|
|
433
440
|
<span class="select2-selection select2-selection--single" role="combobox" aria-haspopup="true">
|
|
434
|
-
<span class=
|
|
435
|
-
{
|
|
441
|
+
<span class={`select2-selection__rendered mbl-ddl-text ${selText.placeholder ? 'mbl-ddl-placeholder' : 'mbl-ddl-selval'}`} title={selText.text} style="font-size: inherit;">
|
|
442
|
+
{selText.text}
|
|
436
443
|
</span>
|
|
437
444
|
<span class="select2-selection__arrow" role="presentation">
|
|
438
445
|
<b role="presentation"></b>
|
|
@@ -449,10 +456,10 @@ class DropdownListComponent extends TsxComponent<DropdownListArgs> implements Dr
|
|
|
449
456
|
const self = this;
|
|
450
457
|
return (row) => {
|
|
451
458
|
const retVal = $(`<span class="s2-ri-withtb">${row.text
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
459
|
+
}<button class="s2-trailing-button ${self.trailingButton.cssClass || ''
|
|
460
|
+
} btn-sm">${self.trailingButton.icon != null ? `<i class="${self.trailingButton.icon}"></i> ` : ''
|
|
461
|
+
}${self.trailingButton.text || ''
|
|
462
|
+
}</button></span>`);
|
|
456
463
|
retVal.find('button').click((e) => {
|
|
457
464
|
try {
|
|
458
465
|
clearTimeout(self.preventDefaultTimeout);
|
|
@@ -543,10 +550,10 @@ class DropdownListComponent extends TsxComponent<DropdownListArgs> implements Dr
|
|
|
543
550
|
useListviewBuilder: false,
|
|
544
551
|
formatSelection: this.customRenderSelectionResult != null
|
|
545
552
|
? this.handleCustomRenderResult(
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
553
|
+
h,
|
|
554
|
+
this.customRenderSelectionResult,
|
|
555
|
+
'mobile',
|
|
556
|
+
)
|
|
550
557
|
: null,
|
|
551
558
|
formatResult: this.getCustomFormatOptions(h, 'mobile'),
|
|
552
559
|
onItemSelected: (items, exclusivity) => {
|
|
@@ -566,16 +573,17 @@ class DropdownListComponent extends TsxComponent<DropdownListArgs> implements Dr
|
|
|
566
573
|
|
|
567
574
|
setMobilePickerInputText(h: any, items: DropdownDisplayArgs[]): void {
|
|
568
575
|
this.$nextTick(() => {
|
|
569
|
-
|
|
576
|
+
const textVal = this.getMobileSelectionText();
|
|
570
577
|
const textContext = $(this.$el).find('.mbl-ddl-text') as any;
|
|
571
|
-
const isPlaceholder =
|
|
572
|
-
|
|
573
|
-
if (isNullOrEmpty(selectedText)) {
|
|
574
|
-
selectedText = this.placeholder;
|
|
575
|
-
}
|
|
578
|
+
const isPlaceholder = textVal.placeholder;
|
|
579
|
+
const selectedText = textVal.text;
|
|
576
580
|
|
|
577
|
-
if (
|
|
578
|
-
|
|
581
|
+
if (isPlaceholder) {
|
|
582
|
+
textContext.text(selectedText);
|
|
583
|
+
textContext.addClass('mbl-ddl-placeholder').removeClass('mbl-ddl-selval');
|
|
584
|
+
return;
|
|
585
|
+
} else {
|
|
586
|
+
textContext.removeClass('mbl-ddl-placeholder').addClass('mbl-ddl-selval');
|
|
579
587
|
}
|
|
580
588
|
|
|
581
589
|
if (this.customRenderSelectionResult == null) {
|