@zeedhi/teknisa-components-common 1.72.0 → 1.74.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/coverage/clover.xml +25 -11
- package/coverage/coverage-final.json +3 -3
- package/coverage/lcov-report/index.html +5 -5
- package/coverage/lcov-report/tests/__helpers__/component-event-helper.ts.html +1 -1
- package/coverage/lcov-report/tests/__helpers__/get-child-helper.ts.html +1 -1
- package/coverage/lcov-report/tests/__helpers__/index.html +1 -1
- package/coverage/lcov-report/tests/__helpers__/index.ts.html +1 -1
- package/coverage/lcov-report/tests/__helpers__/mock-created-helper.ts.html +1 -1
- package/coverage/lcov.info +29 -15
- package/dist/tek-components-common.esm.js +42 -1
- package/dist/tek-components-common.umd.js +42 -1
- package/package.json +2 -2
- package/tests/unit/components/tek-image/Image.spec.ts +21 -0
- package/tests/unit/components/tek-iterable-component-render/iterable-component-render.spec.ts +1 -1
- package/types/components/tek-image/image.d.ts +34 -0
- package/types/components/tek-image/interfaces.d.ts +7 -0
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
<div class='fl pad1y space-right2'>
|
|
26
26
|
<span class="strong">100% </span>
|
|
27
27
|
<span class="quiet">Statements</span>
|
|
28
|
-
<span class='fraction'>
|
|
28
|
+
<span class='fraction'>1426/1426</span>
|
|
29
29
|
</div>
|
|
30
30
|
|
|
31
31
|
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
<div class='fl pad1y space-right2'>
|
|
47
47
|
<span class="strong">100% </span>
|
|
48
48
|
<span class="quiet">Lines</span>
|
|
49
|
-
<span class='fraction'>
|
|
49
|
+
<span class='fraction'>1361/1361</span>
|
|
50
50
|
</div>
|
|
51
51
|
|
|
52
52
|
|
|
@@ -189,13 +189,13 @@
|
|
|
189
189
|
<div class="chart"><div class="cover-fill cover-full" style="width: 100%"></div><div class="cover-empty" style="width: 0%"></div></div>
|
|
190
190
|
</td>
|
|
191
191
|
<td data-value="100" class="pct high">100%</td>
|
|
192
|
-
<td data-value="
|
|
192
|
+
<td data-value="22" class="abs high">22/22</td>
|
|
193
193
|
<td data-value="100" class="pct high">100%</td>
|
|
194
194
|
<td data-value="0" class="abs high">0/0</td>
|
|
195
195
|
<td data-value="100" class="pct high">100%</td>
|
|
196
196
|
<td data-value="1" class="abs high">1/1</td>
|
|
197
197
|
<td data-value="100" class="pct high">100%</td>
|
|
198
|
-
<td data-value="
|
|
198
|
+
<td data-value="22" class="abs high">22/22</td>
|
|
199
199
|
</tr>
|
|
200
200
|
|
|
201
201
|
<tr>
|
|
@@ -371,7 +371,7 @@
|
|
|
371
371
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
372
372
|
Code coverage generated by
|
|
373
373
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
374
|
-
at 2023-
|
|
374
|
+
at 2023-04-05T00:15:06.091Z
|
|
375
375
|
</div>
|
|
376
376
|
<script src="prettify.js"></script>
|
|
377
377
|
<script>
|
|
@@ -85,7 +85,7 @@ export { setClick };
|
|
|
85
85
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
86
86
|
Code coverage generated by
|
|
87
87
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
88
|
-
at 2023-
|
|
88
|
+
at 2023-04-05T00:15:06.091Z
|
|
89
89
|
</div>
|
|
90
90
|
<script src="../../prettify.js"></script>
|
|
91
91
|
<script>
|
|
@@ -151,7 +151,7 @@ export { getChild };
|
|
|
151
151
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
152
152
|
Code coverage generated by
|
|
153
153
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
154
|
-
at 2023-
|
|
154
|
+
at 2023-04-05T00:15:06.091Z
|
|
155
155
|
</div>
|
|
156
156
|
<script src="../../prettify.js"></script>
|
|
157
157
|
<script>
|
|
@@ -146,7 +146,7 @@
|
|
|
146
146
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
147
147
|
Code coverage generated by
|
|
148
148
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
149
|
-
at 2023-
|
|
149
|
+
at 2023-04-05T00:15:06.091Z
|
|
150
150
|
</div>
|
|
151
151
|
<script src="../../prettify.js"></script>
|
|
152
152
|
<script>
|
|
@@ -79,7 +79,7 @@ export * from './mock-created-helper';
|
|
|
79
79
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
80
80
|
Code coverage generated by
|
|
81
81
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
82
|
-
at 2023-
|
|
82
|
+
at 2023-04-05T00:15:06.091Z
|
|
83
83
|
</div>
|
|
84
84
|
<script src="../../prettify.js"></script>
|
|
85
85
|
<script>
|
|
@@ -106,7 +106,7 @@ export { mockCreated };
|
|
|
106
106
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
107
107
|
Code coverage generated by
|
|
108
108
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
109
|
-
at 2023-
|
|
109
|
+
at 2023-04-05T00:15:06.091Z
|
|
110
110
|
</div>
|
|
111
111
|
<script src="../../prettify.js"></script>
|
|
112
112
|
<script>
|
package/coverage/lcov.info
CHANGED
|
@@ -1172,9 +1172,9 @@ FNDA:2,(anonymous_31)
|
|
|
1172
1172
|
FNDA:3,(anonymous_32)
|
|
1173
1173
|
FNDA:107,(anonymous_33)
|
|
1174
1174
|
FNDA:107,(anonymous_34)
|
|
1175
|
-
FNDA:
|
|
1176
|
-
FNDA:
|
|
1177
|
-
FNDA:
|
|
1175
|
+
FNDA:92,(anonymous_35)
|
|
1176
|
+
FNDA:92,(anonymous_36)
|
|
1177
|
+
FNDA:90,(anonymous_37)
|
|
1178
1178
|
FNDA:79,(anonymous_38)
|
|
1179
1179
|
FNDA:120,(anonymous_40)
|
|
1180
1180
|
FNDA:18,(anonymous_41)
|
|
@@ -1357,9 +1357,9 @@ DA:503,107
|
|
|
1357
1357
|
DA:504,107
|
|
1358
1358
|
DA:505,107
|
|
1359
1359
|
DA:509,107
|
|
1360
|
-
DA:510,
|
|
1360
|
+
DA:510,90
|
|
1361
1361
|
DA:514,16
|
|
1362
|
-
DA:517,
|
|
1362
|
+
DA:517,90
|
|
1363
1363
|
DA:521,107
|
|
1364
1364
|
DA:523,79
|
|
1365
1365
|
DA:529,79
|
|
@@ -1556,9 +1556,9 @@ BRDA:425,15,0,1
|
|
|
1556
1556
|
BRDA:438,16,0,1
|
|
1557
1557
|
BRDA:469,17,0,1
|
|
1558
1558
|
BRDA:510,18,0,16
|
|
1559
|
-
BRDA:511,19,0,
|
|
1560
|
-
BRDA:511,19,1,
|
|
1561
|
-
BRDA:511,19,2,
|
|
1559
|
+
BRDA:511,19,0,90
|
|
1560
|
+
BRDA:511,19,1,75
|
|
1561
|
+
BRDA:511,19,2,74
|
|
1562
1562
|
BRDA:533,20,0,17
|
|
1563
1563
|
BRDA:533,20,1,62
|
|
1564
1564
|
BRDA:534,21,0,79
|
|
@@ -1879,7 +1879,7 @@ BRH:53
|
|
|
1879
1879
|
end_of_record
|
|
1880
1880
|
TN:
|
|
1881
1881
|
SF:src/components/tek-image/image.ts
|
|
1882
|
-
FN:
|
|
1882
|
+
FN:63,(anonymous_0)
|
|
1883
1883
|
FNF:1
|
|
1884
1884
|
FNH:1
|
|
1885
1885
|
FNDA:3,(anonymous_0)
|
|
@@ -1887,12 +1887,26 @@ DA:1,26
|
|
|
1887
1887
|
DA:7,26
|
|
1888
1888
|
DA:11,3
|
|
1889
1889
|
DA:16,3
|
|
1890
|
-
DA:
|
|
1891
|
-
DA:
|
|
1892
|
-
DA:
|
|
1893
|
-
DA:
|
|
1894
|
-
|
|
1895
|
-
|
|
1890
|
+
DA:22,3
|
|
1891
|
+
DA:28,3
|
|
1892
|
+
DA:34,3
|
|
1893
|
+
DA:39,3
|
|
1894
|
+
DA:45,3
|
|
1895
|
+
DA:51,3
|
|
1896
|
+
DA:57,3
|
|
1897
|
+
DA:64,3
|
|
1898
|
+
DA:65,3
|
|
1899
|
+
DA:66,3
|
|
1900
|
+
DA:67,3
|
|
1901
|
+
DA:68,3
|
|
1902
|
+
DA:69,3
|
|
1903
|
+
DA:70,3
|
|
1904
|
+
DA:71,3
|
|
1905
|
+
DA:72,3
|
|
1906
|
+
DA:73,3
|
|
1907
|
+
DA:74,3
|
|
1908
|
+
LF:22
|
|
1909
|
+
LH:22
|
|
1896
1910
|
BRF:0
|
|
1897
1911
|
BRH:0
|
|
1898
1912
|
end_of_record
|
|
@@ -367,8 +367,49 @@ class Image extends ComponentRender {
|
|
|
367
367
|
* Image source.
|
|
368
368
|
*/
|
|
369
369
|
this.src = '';
|
|
370
|
+
/**
|
|
371
|
+
* Defines the component height. Possible values for this property can be
|
|
372
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
373
|
+
*/
|
|
374
|
+
this.height = 'auto';
|
|
375
|
+
/**
|
|
376
|
+
* Defines the component min height. Possible values for this property can be
|
|
377
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
378
|
+
*/
|
|
379
|
+
this.minHeight = 'auto';
|
|
380
|
+
/**
|
|
381
|
+
* Defines the component max height. Possible values for this property can be
|
|
382
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
383
|
+
*/
|
|
384
|
+
this.maxHeight = 'none';
|
|
385
|
+
/**
|
|
386
|
+
* Set component height to fill all space available
|
|
387
|
+
*/
|
|
388
|
+
this.fillHeight = false;
|
|
389
|
+
/**
|
|
390
|
+
* Defines the component width. Possible values for this property can be
|
|
391
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
392
|
+
*/
|
|
393
|
+
this.width = 'auto';
|
|
394
|
+
/**
|
|
395
|
+
* Defines the component min width. Possible values for this property can be
|
|
396
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
397
|
+
*/
|
|
398
|
+
this.minWidth = 'auto';
|
|
399
|
+
/**
|
|
400
|
+
* Defines the component max height. Possible values for this property can be
|
|
401
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
402
|
+
*/
|
|
403
|
+
this.maxWidth = 'none';
|
|
370
404
|
this.to = this.getInitValue('to', props.to, this.to);
|
|
371
405
|
this.src = this.getInitValue('src', props.src, this.src);
|
|
406
|
+
this.height = this.getInitValue('height', props.height, this.height);
|
|
407
|
+
this.minHeight = this.getInitValue('minHeight', props.minHeight, this.minHeight);
|
|
408
|
+
this.maxHeight = this.getInitValue('maxHeight', props.maxHeight, this.maxHeight);
|
|
409
|
+
this.fillHeight = this.getInitValue('fillHeight', props.fillHeight, this.fillHeight);
|
|
410
|
+
this.width = this.getInitValue('width', props.width, this.width);
|
|
411
|
+
this.minWidth = this.getInitValue('minWidth', props.minWidth, this.minWidth);
|
|
412
|
+
this.maxWidth = this.getInitValue('maxWidth', props.maxWidth, this.maxWidth);
|
|
372
413
|
this.createAccessors();
|
|
373
414
|
}
|
|
374
415
|
}
|
|
@@ -2063,7 +2104,7 @@ class TekGridColumn extends GridColumnEditable {
|
|
|
2063
2104
|
data.forEach((row) => {
|
|
2064
2105
|
lookupData[row[lookupColumn]] = row;
|
|
2065
2106
|
});
|
|
2066
|
-
this.lookupData = lookupData;
|
|
2107
|
+
this.lookupData = Object.assign(Object.assign({}, this.lookupData), lookupData);
|
|
2067
2108
|
this.lookupDataCount += 1;
|
|
2068
2109
|
this.loading = false;
|
|
2069
2110
|
});
|
|
@@ -372,8 +372,49 @@
|
|
|
372
372
|
* Image source.
|
|
373
373
|
*/
|
|
374
374
|
this.src = '';
|
|
375
|
+
/**
|
|
376
|
+
* Defines the component height. Possible values for this property can be
|
|
377
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
378
|
+
*/
|
|
379
|
+
this.height = 'auto';
|
|
380
|
+
/**
|
|
381
|
+
* Defines the component min height. Possible values for this property can be
|
|
382
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
383
|
+
*/
|
|
384
|
+
this.minHeight = 'auto';
|
|
385
|
+
/**
|
|
386
|
+
* Defines the component max height. Possible values for this property can be
|
|
387
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
388
|
+
*/
|
|
389
|
+
this.maxHeight = 'none';
|
|
390
|
+
/**
|
|
391
|
+
* Set component height to fill all space available
|
|
392
|
+
*/
|
|
393
|
+
this.fillHeight = false;
|
|
394
|
+
/**
|
|
395
|
+
* Defines the component width. Possible values for this property can be
|
|
396
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
397
|
+
*/
|
|
398
|
+
this.width = 'auto';
|
|
399
|
+
/**
|
|
400
|
+
* Defines the component min width. Possible values for this property can be
|
|
401
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
402
|
+
*/
|
|
403
|
+
this.minWidth = 'auto';
|
|
404
|
+
/**
|
|
405
|
+
* Defines the component max height. Possible values for this property can be
|
|
406
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
407
|
+
*/
|
|
408
|
+
this.maxWidth = 'none';
|
|
375
409
|
this.to = this.getInitValue('to', props.to, this.to);
|
|
376
410
|
this.src = this.getInitValue('src', props.src, this.src);
|
|
411
|
+
this.height = this.getInitValue('height', props.height, this.height);
|
|
412
|
+
this.minHeight = this.getInitValue('minHeight', props.minHeight, this.minHeight);
|
|
413
|
+
this.maxHeight = this.getInitValue('maxHeight', props.maxHeight, this.maxHeight);
|
|
414
|
+
this.fillHeight = this.getInitValue('fillHeight', props.fillHeight, this.fillHeight);
|
|
415
|
+
this.width = this.getInitValue('width', props.width, this.width);
|
|
416
|
+
this.minWidth = this.getInitValue('minWidth', props.minWidth, this.minWidth);
|
|
417
|
+
this.maxWidth = this.getInitValue('maxWidth', props.maxWidth, this.maxWidth);
|
|
377
418
|
this.createAccessors();
|
|
378
419
|
}
|
|
379
420
|
}
|
|
@@ -2068,7 +2109,7 @@
|
|
|
2068
2109
|
data.forEach((row) => {
|
|
2069
2110
|
lookupData[row[lookupColumn]] = row;
|
|
2070
2111
|
});
|
|
2071
|
-
this.lookupData = lookupData;
|
|
2112
|
+
this.lookupData = Object.assign(Object.assign({}, this.lookupData), lookupData);
|
|
2072
2113
|
this.lookupDataCount += 1;
|
|
2073
2114
|
this.loading = false;
|
|
2074
2115
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zeedhi/teknisa-components-common",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.74.0",
|
|
4
4
|
"description": "Teknisa Components Common",
|
|
5
5
|
"author": "Zeedhi <zeedhi@teknisa.com>",
|
|
6
6
|
"license": "ISC",
|
|
@@ -31,5 +31,5 @@
|
|
|
31
31
|
"peerDependencies": {
|
|
32
32
|
"@zeedhi/core": "*"
|
|
33
33
|
},
|
|
34
|
-
"gitHead": "
|
|
34
|
+
"gitHead": "c549372b7bf5fb85808a5bf8cb9c250289c9c3e7"
|
|
35
35
|
}
|
|
@@ -9,6 +9,13 @@ describe('Image', () => {
|
|
|
9
9
|
});
|
|
10
10
|
expect(instance.src).toBe('');
|
|
11
11
|
expect(instance.to).toBe('');
|
|
12
|
+
expect(instance.height).toBe('auto');
|
|
13
|
+
expect(instance.minHeight).toBe('auto');
|
|
14
|
+
expect(instance.maxHeight).toBe('none');
|
|
15
|
+
expect(instance.fillHeight).toBeFalsy();
|
|
16
|
+
expect(instance.width).toBe('auto');
|
|
17
|
+
expect(instance.minWidth).toBe('auto');
|
|
18
|
+
expect(instance.maxWidth).toBe('none');
|
|
12
19
|
});
|
|
13
20
|
|
|
14
21
|
it('should create new image replacing default values', () => {
|
|
@@ -17,9 +24,23 @@ describe('Image', () => {
|
|
|
17
24
|
component: 'Image',
|
|
18
25
|
src: '/img/zeedhi.svg',
|
|
19
26
|
to: 'google.com.br',
|
|
27
|
+
height: '400px',
|
|
28
|
+
maxHeight: '500px',
|
|
29
|
+
minHeight: '500px',
|
|
30
|
+
width: '400px',
|
|
31
|
+
maxWidth: '500px',
|
|
32
|
+
minWidth: '500px',
|
|
33
|
+
fillHeight: true,
|
|
20
34
|
});
|
|
21
35
|
expect(instance.src).toBe('/img/zeedhi.svg');
|
|
22
36
|
expect(instance.to).toBe('google.com.br');
|
|
37
|
+
expect(instance.height).toBe('400px');
|
|
38
|
+
expect(instance.maxHeight).toBe('500px');
|
|
39
|
+
expect(instance.minHeight).toBe('500px');
|
|
40
|
+
expect(instance.width).toBe('400px');
|
|
41
|
+
expect(instance.maxWidth).toBe('500px');
|
|
42
|
+
expect(instance.minWidth).toBe('500px');
|
|
43
|
+
expect(instance.fillHeight).toBeTruthy();
|
|
23
44
|
});
|
|
24
45
|
});
|
|
25
46
|
});
|
package/tests/unit/components/tek-iterable-component-render/iterable-component-render.spec.ts
CHANGED
|
@@ -28,7 +28,7 @@ describe('IterableComponentRender', () => {
|
|
|
28
28
|
]);
|
|
29
29
|
expect(instance.height).toBe('auto');
|
|
30
30
|
expect(instance.maxHeight).toBe('none');
|
|
31
|
-
expect(instance.minHeight).toBe('
|
|
31
|
+
expect(instance.minHeight).toBe('auto');
|
|
32
32
|
});
|
|
33
33
|
|
|
34
34
|
it('should create new IterableComponentRender replacing default values', () => {
|
|
@@ -12,6 +12,40 @@ export declare class Image extends ComponentRender implements IImage {
|
|
|
12
12
|
* Image source.
|
|
13
13
|
*/
|
|
14
14
|
src: string;
|
|
15
|
+
/**
|
|
16
|
+
* Defines the component height. Possible values for this property can be
|
|
17
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
18
|
+
*/
|
|
19
|
+
height: string | number;
|
|
20
|
+
/**
|
|
21
|
+
* Defines the component min height. Possible values for this property can be
|
|
22
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
23
|
+
*/
|
|
24
|
+
minHeight: string | number;
|
|
25
|
+
/**
|
|
26
|
+
* Defines the component max height. Possible values for this property can be
|
|
27
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
28
|
+
*/
|
|
29
|
+
maxHeight: string | number;
|
|
30
|
+
/**
|
|
31
|
+
* Set component height to fill all space available
|
|
32
|
+
*/
|
|
33
|
+
fillHeight: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* Defines the component width. Possible values for this property can be
|
|
36
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
37
|
+
*/
|
|
38
|
+
width: string | number;
|
|
39
|
+
/**
|
|
40
|
+
* Defines the component min width. Possible values for this property can be
|
|
41
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
42
|
+
*/
|
|
43
|
+
minWidth: string | number;
|
|
44
|
+
/**
|
|
45
|
+
* Defines the component max height. Possible values for this property can be
|
|
46
|
+
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
47
|
+
*/
|
|
48
|
+
maxWidth: string | number;
|
|
15
49
|
/**
|
|
16
50
|
* Creates a new instance of ImgLink
|
|
17
51
|
* @param props Image Link props
|
|
@@ -2,4 +2,11 @@ import { IComponentRender } from '@zeedhi/common';
|
|
|
2
2
|
export interface IImage extends IComponentRender {
|
|
3
3
|
to?: string;
|
|
4
4
|
src?: string;
|
|
5
|
+
height?: number | string;
|
|
6
|
+
maxHeight?: number | string;
|
|
7
|
+
minHeight?: number | string;
|
|
8
|
+
fillHeight?: boolean;
|
|
9
|
+
width?: number | string;
|
|
10
|
+
maxWidth?: number | string;
|
|
11
|
+
minWidth?: number | string;
|
|
5
12
|
}
|