@sme.up/ketchup 5.2.0-SNAPSHOT → 6.0.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/dist/cjs/{cell-utils-5b16c180.js → cell-utils-a78d6fac.js} +2 -2
- package/dist/cjs/{component-d1496215.js → component-72a5b626.js} +30 -0
- package/dist/cjs/{f-button-3b9f32af.js → f-button-ac179257.js} +2 -2
- package/dist/cjs/{f-cell-c6ad973a.js → f-cell-69294bca.js} +33 -121
- package/dist/cjs/{f-chip-bed86c4a.js → f-chip-b00897d7.js} +5 -4
- package/dist/cjs/{f-image-08a3d340.js → f-image-89f25556.js} +2 -2
- package/dist/cjs/f-paginator-utils-8fa501b3.js +1898 -0
- package/dist/cjs/f-text-field-e1e45ade.js +94 -0
- package/dist/cjs/f-text-field-mdc-85997738.js +2570 -0
- package/dist/cjs/{index-8d7bb3be.js → index-eb556444.js} +2 -0
- package/dist/cjs/ketchup.cjs.js +3 -3
- package/dist/cjs/kup-accordion.cjs.entry.js +5 -5
- package/dist/cjs/{kup-autocomplete_27.cjs.entry.js → kup-autocomplete_25.cjs.entry.js} +1788 -8378
- package/dist/cjs/{kup-echart.cjs.entry.js → kup-box_2.cjs.entry.js} +17102 -14788
- package/dist/cjs/kup-calendar.cjs.entry.js +42 -34
- package/dist/cjs/kup-cell.cjs.entry.js +8 -7
- package/dist/cjs/kup-dash-list.cjs.entry.js +4 -4
- package/dist/cjs/kup-dash_2.cjs.entry.js +3 -3
- package/dist/cjs/kup-drawer.cjs.entry.js +12 -5
- package/dist/cjs/kup-field.cjs.entry.js +2 -2
- package/dist/cjs/kup-form-editor.cjs.entry.js +404 -0
- package/dist/cjs/kup-iframe.cjs.entry.js +3 -3
- package/dist/cjs/kup-image-list.cjs.entry.js +228 -0
- package/dist/cjs/kup-lazy.cjs.entry.js +3 -3
- package/dist/cjs/kup-magic-box.cjs.entry.js +4 -4
- package/dist/cjs/kup-manager-7a941909.js +16703 -0
- package/dist/cjs/kup-nav-bar.cjs.entry.js +3 -3
- package/dist/cjs/kup-numeric-picker.cjs.entry.js +423 -0
- package/dist/cjs/kup-photo-frame.cjs.entry.js +5 -5
- package/dist/cjs/kup-probe.cjs.entry.js +2 -2
- package/dist/cjs/kup-qlik.cjs.entry.js +2 -2
- package/dist/cjs/kup-snackbar.cjs.entry.js +6 -6
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/{utils-b9df398c.js → utils-6287d878.js} +1 -1
- package/dist/collection/assets/card.js +4 -5
- package/dist/collection/assets/data-table.js +44 -79
- package/dist/collection/assets/form-editor.js +338 -0
- package/dist/collection/assets/image-list.js +624 -0
- package/dist/collection/assets/index.js +16 -0
- package/dist/collection/assets/kupdata.js +0 -3
- package/dist/collection/assets/kuptooltip.js +654 -0
- package/dist/collection/assets/tree.js +0 -128
- package/dist/collection/collection-manifest.json +8 -6
- package/dist/collection/components/kup-autocomplete/kup-autocomplete.js +1 -1
- package/dist/collection/components/kup-box/kup-box-declarations.js +0 -4
- package/dist/collection/components/kup-box/kup-box.js +7 -135
- package/dist/collection/components/kup-card/built-in/kup-card-built-in.js +10 -0
- package/dist/collection/components/kup-card/built-in/kup-card-clock.js +1 -1
- package/dist/collection/components/kup-card/built-in/kup-card-column-drop-menu.js +1 -2
- package/dist/collection/components/kup-card/built-in/kup-card-numeric.js +153 -0
- package/dist/collection/components/kup-card/kup-card.css +61 -8
- package/dist/collection/components/kup-card/kup-card.js +2 -2
- package/dist/collection/components/kup-card/standard/kup-card-standard.js +14 -6
- package/dist/collection/components/kup-combobox/kup-combobox.js +1 -1
- package/dist/collection/components/kup-data-table/kup-data-table-declarations.js +1 -3
- package/dist/collection/components/kup-data-table/kup-data-table-state.js +1 -1
- package/dist/collection/components/kup-data-table/kup-data-table.js +50 -138
- package/dist/collection/components/kup-date-picker/kup-date-picker.js +1 -1
- package/dist/collection/components/kup-drawer/kup-drawer.css +1 -0
- package/dist/collection/components/kup-drawer/kup-drawer.js +8 -1
- package/dist/collection/components/kup-form-editor/kup-form-editor-declarations.js +23 -0
- package/dist/collection/components/kup-form-editor/kup-form-editor.css +80 -0
- package/dist/collection/components/kup-form-editor/kup-form-editor.js +561 -0
- package/dist/collection/components/kup-image-list/kup-image-list-declarations.js +10 -0
- package/dist/collection/components/kup-image-list/kup-image-list.css +166 -0
- package/dist/collection/components/kup-image-list/kup-image-list.js +432 -0
- package/dist/collection/components/kup-numeric-picker/kup-numeric-picker-declarations.js +16 -0
- package/dist/collection/components/kup-numeric-picker/kup-numeric-picker.css +50 -0
- package/dist/collection/components/kup-numeric-picker/kup-numeric-picker.js +895 -0
- package/dist/collection/components/kup-photo-frame/kup-photo-frame.css +3 -13
- package/dist/collection/components/kup-photo-frame/kup-photo-frame.js +1 -1
- package/dist/collection/components/kup-snackbar/kup-snackbar.css +4 -0
- package/dist/collection/components/kup-tab-bar/kup-tab-bar.js +18 -19
- package/dist/collection/components/kup-time-picker/kup-time-picker.js +2 -2
- package/dist/collection/components/kup-tree/kup-tree-declarations.js +0 -4
- package/dist/collection/components/kup-tree/kup-tree.css +10 -3
- package/dist/collection/components/kup-tree/kup-tree.js +81 -145
- package/dist/collection/f-components/f-cell/f-cell.js +7 -7
- package/dist/collection/f-components/f-chip/f-chip.js +2 -1
- package/dist/collection/managers/kup-data/kup-data-node-helper.js +24 -0
- package/dist/collection/managers/kup-data/kup-data.js +4 -1
- package/dist/collection/managers/kup-debug/kup-debug.js +1 -0
- package/dist/collection/managers/kup-dynamic-position/kup-dynamic-position.js +4 -2
- package/dist/collection/managers/kup-interact/kup-interact.js +1 -22
- package/dist/collection/managers/kup-language/kup-language-declarations.js +2 -0
- package/dist/collection/managers/kup-manager/kup-manager.js +31 -1
- package/dist/collection/managers/kup-math/kup-math.js +11 -1
- package/dist/collection/managers/kup-theme/kup-theme-declarations.js +6 -0
- package/dist/collection/managers/kup-tooltip/kup-tooltip-declarations.js +1 -0
- package/dist/collection/managers/kup-tooltip/kup-tooltip.js +224 -0
- package/dist/collection/types/GenericTypes.js +3 -0
- package/dist/collection/utils/kup-column-menu/kup-column-menu.js +8 -12
- package/dist/esm/{cell-utils-69f75e2e.js → cell-utils-964da6b5.js} +3 -3
- package/dist/esm/{component-c4eb6153.js → component-b1bedf1d.js} +27 -2
- package/dist/esm/{f-button-7e7607d8.js → f-button-871a544b.js} +2 -2
- package/dist/esm/{f-cell-e4d83c27.js → f-cell-521ef17a.js} +33 -120
- package/dist/esm/{f-chip-51dfefaf.js → f-chip-1dda722f.js} +6 -5
- package/dist/esm/{f-image-de331954.js → f-image-c468d8ae.js} +2 -2
- package/dist/esm/f-paginator-utils-7dff8ff0.js +1884 -0
- package/dist/esm/f-text-field-d6c61c73.js +92 -0
- package/dist/esm/f-text-field-mdc-d42d3f9e.js +2568 -0
- package/dist/esm/{index-aeec9835.js → index-baeab1ac.js} +2 -1
- package/dist/esm/ketchup.js +3 -3
- package/dist/esm/kup-accordion.entry.js +6 -6
- package/dist/esm/{kup-autocomplete_27.entry.js → kup-autocomplete_25.entry.js} +1724 -8312
- package/dist/esm/{kup-echart.entry.js → kup-box_2.entry.js} +17102 -14789
- package/dist/esm/kup-calendar.entry.js +43 -35
- package/dist/esm/kup-cell.entry.js +8 -7
- package/dist/esm/kup-dash-list.entry.js +4 -4
- package/dist/esm/kup-dash_2.entry.js +3 -3
- package/dist/esm/kup-drawer.entry.js +12 -5
- package/dist/esm/kup-field.entry.js +2 -2
- package/dist/esm/kup-form-editor.entry.js +400 -0
- package/dist/esm/kup-iframe.entry.js +3 -3
- package/dist/esm/kup-image-list.entry.js +224 -0
- package/dist/esm/kup-lazy.entry.js +3 -3
- package/dist/esm/kup-magic-box.entry.js +4 -4
- package/dist/esm/kup-manager-58b075b4.js +16686 -0
- package/dist/esm/kup-nav-bar.entry.js +3 -3
- package/dist/esm/kup-numeric-picker.entry.js +419 -0
- package/dist/esm/kup-photo-frame.entry.js +5 -5
- package/dist/esm/kup-probe.entry.js +2 -2
- package/dist/esm/kup-qlik.entry.js +2 -2
- package/dist/esm/kup-snackbar.entry.js +6 -6
- package/dist/esm/loader.js +3 -3
- package/dist/esm/polyfills/css-shim.js +1 -1
- package/dist/esm/{tslib.es6-8f2d44b6.js → tslib.es6-3eea2234.js} +1 -1
- package/dist/esm/{utils-35c7a90d.js → utils-d7e4b3c2.js} +2 -2
- package/dist/ketchup/ketchup.esm.js +1 -1
- package/dist/ketchup/{p-5d190cf5.js → p-1ae66cc5.js} +1 -1
- package/dist/ketchup/{p-8be1337b.js → p-34b74425.js} +1 -1
- package/dist/ketchup/{p-fea316ab.entry.js → p-3c11e615.entry.js} +1 -1
- package/dist/ketchup/p-44ec4f03.js +1 -0
- package/dist/ketchup/p-4ffbc3ff.js +1 -0
- package/dist/ketchup/p-5264a3e6.entry.js +1 -0
- package/dist/ketchup/{p-d7af8156.entry.js → p-65974e48.entry.js} +1 -1
- package/dist/ketchup/p-65b46587.entry.js +40 -0
- package/dist/ketchup/{p-3813281b.entry.js → p-6dff70f8.entry.js} +1 -1
- package/dist/ketchup/{p-33073f4a.js → p-7454cb92.js} +1 -1
- package/dist/ketchup/{p-a0b1d769.js → p-79b0730b.js} +1 -1
- package/dist/ketchup/p-7eff4eee.js +1 -0
- package/dist/ketchup/p-80968627.entry.js +1 -0
- package/dist/ketchup/{p-8c44c3b9.js → p-81605f08.js} +4 -5
- package/dist/ketchup/p-8cdf61a4.js +1 -0
- package/dist/ketchup/{p-f9c41e20.entry.js → p-954cc340.entry.js} +1 -1
- package/dist/ketchup/p-99e0d768.entry.js +1 -0
- package/dist/ketchup/{p-8f735633.entry.js → p-a0f6e25c.entry.js} +1 -1
- package/dist/ketchup/p-a203f78b.js +45 -0
- package/dist/ketchup/{p-9bcda66f.entry.js → p-a615a92b.entry.js} +1 -1
- package/dist/ketchup/p-aca0e54b.js +30 -0
- package/dist/ketchup/p-b8939a8b.entry.js +1 -0
- package/dist/ketchup/p-bfc3bac7.js +1 -0
- package/dist/ketchup/{p-67c64257.entry.js → p-c5ce8951.entry.js} +1 -1
- package/dist/ketchup/p-cad1e097.entry.js +9 -0
- package/dist/ketchup/{p-68fc1428.entry.js → p-d2ee56dd.entry.js} +1 -1
- package/dist/ketchup/p-db71436b.entry.js +27 -0
- package/dist/ketchup/{p-10c8d755.js → p-e0035c58.js} +1 -1
- package/dist/ketchup/p-e1039cf2.entry.js +1 -0
- package/dist/ketchup/{p-b5e1dbfa.entry.js → p-ea10176c.entry.js} +1 -1
- package/dist/ketchup/p-f09f2f98.entry.js +1 -0
- package/dist/ketchup/{p-0751aaf6.entry.js → p-f71a1675.entry.js} +1 -1
- package/dist/ketchup/{p-4081f5f7.entry.js → p-fac1a08b.entry.js} +1 -1
- package/dist/types/components/kup-box/kup-box-declarations.d.ts +3 -5
- package/dist/types/components/kup-box/kup-box.d.ts +0 -22
- package/dist/types/components/kup-card/built-in/kup-card-built-in.d.ts +7 -0
- package/dist/types/components/kup-card/built-in/kup-card-numeric.d.ts +2 -0
- package/dist/types/components/kup-card/kup-card-declarations.d.ts +26 -1
- package/dist/types/components/kup-data-table/kup-data-table-declarations.d.ts +4 -4
- package/dist/types/components/kup-data-table/kup-data-table-state.d.ts +1 -1
- package/dist/types/components/kup-data-table/kup-data-table.d.ts +5 -19
- package/dist/types/components/kup-form-editor/kup-form-editor-declarations.d.ts +79 -0
- package/dist/types/components/kup-form-editor/kup-form-editor.d.ts +72 -0
- package/dist/types/components/kup-image-list/kup-image-list-declarations.d.ts +14 -0
- package/dist/types/components/kup-image-list/kup-image-list.d.ts +56 -0
- package/dist/types/components/kup-numeric-picker/kup-numeric-picker-declarations.d.ts +19 -0
- package/dist/types/components/kup-numeric-picker/kup-numeric-picker.d.ts +121 -0
- package/dist/types/components/kup-tab-bar/kup-tab-bar-declarations.d.ts +3 -9
- package/dist/types/components/kup-tab-bar/kup-tab-bar.d.ts +6 -6
- package/dist/types/components/kup-tree/kup-tree-declarations.d.ts +1 -5
- package/dist/types/components/kup-tree/kup-tree.d.ts +1 -25
- package/dist/types/components.d.ts +265 -232
- package/dist/types/managers/kup-data/kup-data-declarations.d.ts +1 -0
- package/dist/types/managers/kup-data/kup-data-node-helper.d.ts +7 -0
- package/dist/types/managers/kup-data/kup-data.d.ts +1 -0
- package/dist/types/managers/kup-language/kup-language-declarations.d.ts +2 -0
- package/dist/types/managers/kup-manager/kup-manager-declarations.d.ts +14 -0
- package/dist/types/managers/kup-manager/kup-manager.d.ts +14 -0
- package/dist/types/managers/kup-math/kup-math-declarations.d.ts +6 -0
- package/dist/types/managers/kup-math/kup-math.d.ts +2 -1
- package/dist/types/managers/kup-tooltip/kup-tooltip-declarations.d.ts +8 -0
- package/dist/types/managers/kup-tooltip/kup-tooltip.d.ts +51 -0
- package/dist/types/types/GenericTypes.d.ts +3 -0
- package/dist/types/utils/kup-column-menu/kup-column-menu.d.ts +1 -3
- package/package.json +16 -15
- package/dist/cjs/kup-manager-4227f0a2.js +0 -8582
- package/dist/collection/assets/tooltip.js +0 -73
- package/dist/collection/components/kup-tooltip/kup-tooltip-declarations.js +0 -20
- package/dist/collection/components/kup-tooltip/kup-tooltip.css +0 -149
- package/dist/collection/components/kup-tooltip/kup-tooltip.js +0 -1205
- package/dist/collection/utils/helpers.js +0 -38
- package/dist/esm/kup-manager-0ab94726.js +0 -8565
- package/dist/ketchup/p-24df4f29.entry.js +0 -27
- package/dist/ketchup/p-2d4f19f4.js +0 -1
- package/dist/ketchup/p-3445be1e.entry.js +0 -1
- package/dist/ketchup/p-3aab1f0d.entry.js +0 -1
- package/dist/ketchup/p-47b57d97.js +0 -1
- package/dist/ketchup/p-5186885c.entry.js +0 -1
- package/dist/ketchup/p-78223dc0.entry.js +0 -143
- package/dist/ketchup/p-96101f09.entry.js +0 -39
- package/dist/ketchup/p-c314b1e6.js +0 -1
- package/dist/ketchup/p-ee33cbe9.js +0 -9
- package/dist/types/components/kup-tooltip/kup-tooltip-declarations.d.ts +0 -93
- package/dist/types/components/kup-tooltip/kup-tooltip.d.ts +0 -142
- package/dist/types/utils/helpers.d.ts +0 -4
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const utils = require('./utils-
|
|
4
|
-
const kupManager = require('./kup-manager-
|
|
3
|
+
const utils = require('./utils-6287d878.js');
|
|
4
|
+
const kupManager = require('./kup-manager-7a941909.js');
|
|
5
5
|
|
|
6
6
|
const dom = document.documentElement;
|
|
7
7
|
// -------------
|
|
@@ -258,6 +258,31 @@ function matches(element, selector) {
|
|
|
258
258
|
|| element.msMatchesSelector;
|
|
259
259
|
return nativeMatches.call(element, selector);
|
|
260
260
|
}
|
|
261
|
+
/**
|
|
262
|
+
* Used to compute the estimated scroll width of elements. When an element is
|
|
263
|
+
* hidden due to display: none; being applied to a parent element, the width is
|
|
264
|
+
* returned as 0. However, the element will have a true width once no longer
|
|
265
|
+
* inside a display: none context. This method computes an estimated width when
|
|
266
|
+
* the element is hidden or returns the true width when the element is visble.
|
|
267
|
+
* @param {Element} element the element whose width to estimate
|
|
268
|
+
*/
|
|
269
|
+
function estimateScrollWidth(element) {
|
|
270
|
+
// Check the offsetParent. If the element inherits display: none from any
|
|
271
|
+
// parent, the offsetParent property will be null (see
|
|
272
|
+
// https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/offsetParent).
|
|
273
|
+
// This check ensures we only clone the node when necessary.
|
|
274
|
+
var htmlEl = element;
|
|
275
|
+
if (htmlEl.offsetParent !== null) {
|
|
276
|
+
return htmlEl.scrollWidth;
|
|
277
|
+
}
|
|
278
|
+
var clone = htmlEl.cloneNode(true);
|
|
279
|
+
clone.style.setProperty('position', 'absolute');
|
|
280
|
+
clone.style.setProperty('transform', 'translate(-9999px, -9999px)');
|
|
281
|
+
document.documentElement.appendChild(clone);
|
|
282
|
+
var scrollWidth = clone.scrollWidth;
|
|
283
|
+
document.documentElement.removeChild(clone);
|
|
284
|
+
return scrollWidth;
|
|
285
|
+
}
|
|
261
286
|
|
|
262
287
|
/**
|
|
263
288
|
* @license
|
|
@@ -992,5 +1017,10 @@ var MDCRipple = /** @class */ (function (_super) {
|
|
|
992
1017
|
return MDCRipple;
|
|
993
1018
|
}(MDCComponent));
|
|
994
1019
|
|
|
1020
|
+
exports.MDCComponent = MDCComponent;
|
|
1021
|
+
exports.MDCFoundation = MDCFoundation;
|
|
995
1022
|
exports.MDCRipple = MDCRipple;
|
|
996
1023
|
exports.MDCRippleFoundation = MDCRippleFoundation;
|
|
1024
|
+
exports.applyPassive = applyPassive;
|
|
1025
|
+
exports.estimateScrollWidth = estimateScrollWidth;
|
|
1026
|
+
exports.matches = matches;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
3
|
+
const index = require('./index-eb556444.js');
|
|
4
4
|
const fButtonDeclarations = require('./f-button-declarations-b611587f.js');
|
|
5
|
-
const fImage = require('./f-image-
|
|
5
|
+
const fImage = require('./f-image-89f25556.js');
|
|
6
6
|
|
|
7
7
|
/*-------------------------------------------------*/
|
|
8
8
|
/* C o m p o n e n t */
|
|
@@ -1,99 +1,36 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const kupManager = require('./kup-manager-
|
|
4
|
-
const index = require('./index-
|
|
5
|
-
const cellUtils = require('./cell-utils-
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
const
|
|
3
|
+
const kupManager = require('./kup-manager-7a941909.js');
|
|
4
|
+
const index = require('./index-eb556444.js');
|
|
5
|
+
const cellUtils = require('./cell-utils-a78d6fac.js');
|
|
6
|
+
const fTextField = require('./f-text-field-e1e45ade.js');
|
|
7
|
+
const utils = require('./utils-6287d878.js');
|
|
8
|
+
const fImage = require('./f-image-89f25556.js');
|
|
9
|
+
const fChip = require('./f-chip-b00897d7.js');
|
|
9
10
|
|
|
10
11
|
/*-------------------------------------------------*/
|
|
11
12
|
/* C o m p o n e n t */
|
|
12
13
|
/*-------------------------------------------------*/
|
|
13
|
-
const
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
setHelper(props),
|
|
18
|
-
index.h("label", null, props.label),
|
|
19
|
-
])) : ([setContent(props), setHelper(props)]),
|
|
20
|
-
children));
|
|
21
|
-
};
|
|
22
|
-
/*-------------------------------------------------*/
|
|
23
|
-
/* M e t h o d s */
|
|
24
|
-
/*-------------------------------------------------*/
|
|
25
|
-
function setContent(props) {
|
|
26
|
-
const isOutlined = props.textArea || props.outlined;
|
|
27
|
-
let labelEl;
|
|
28
|
-
let iconEl;
|
|
29
|
-
if (props.label && !props.leadingLabel && !props.trailingLabel) {
|
|
30
|
-
labelEl = (index.h("label", { class: "mdc-floating-label", htmlFor: "kup-input" }, props.label));
|
|
31
|
-
}
|
|
32
|
-
if (props.icon) {
|
|
33
|
-
let iconStyle;
|
|
34
|
-
let iconClass = '';
|
|
35
|
-
if (Object.values(kupManager.KupThemeIconValues).indexOf(props.icon) > -1) {
|
|
36
|
-
iconClass = props.icon.replace('--', '');
|
|
37
|
-
}
|
|
38
|
-
else {
|
|
39
|
-
let svg = `url('${index.getAssetPath(`./assets/svg/${props.icon}.svg`)}') no-repeat center`;
|
|
40
|
-
iconStyle = {
|
|
41
|
-
mask: svg,
|
|
42
|
-
webkitMask: svg,
|
|
43
|
-
};
|
|
44
|
-
}
|
|
45
|
-
iconEl = (index.h("span", { style: iconStyle, onClick: props.onIconClick, class: `mdc-text-field__icon kup-icon action ${iconClass}` }));
|
|
46
|
-
}
|
|
14
|
+
const FCheckbox = (props) => {
|
|
15
|
+
const indeterminateAttr = {
|
|
16
|
+
'data-indeterminate': props.indeterminate ? true : false,
|
|
17
|
+
};
|
|
47
18
|
const classObj = {
|
|
48
|
-
|
|
49
|
-
'
|
|
50
|
-
'
|
|
51
|
-
'
|
|
52
|
-
'mdc-text-field--no-label': !props.label,
|
|
53
|
-
'mdc-text-field--fullwidth': props.fullWidth,
|
|
54
|
-
'mdc-text-field--outlined': isOutlined,
|
|
55
|
-
'mdc-text-field--textarea': props.textArea,
|
|
56
|
-
'mdc-text-field--with-leading-icon': props.icon && !props.trailingIcon,
|
|
57
|
-
'mdc-text-field--with-trailing-icon': props.icon && props.trailingIcon,
|
|
19
|
+
checkbox: true,
|
|
20
|
+
'checkbox--checked': props.checked && !props.indeterminate ? true : false,
|
|
21
|
+
'checkbox--disabled': props.disabled ? true : false,
|
|
22
|
+
'checkbox--indeterminate': props.indeterminate ? true : false,
|
|
58
23
|
};
|
|
59
|
-
return (index.h("div", { class:
|
|
60
|
-
|
|
61
|
-
"
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
isOutlined ? (index.h("div", { class: "mdc-notched-outline" },
|
|
70
|
-
index.h("div", { class: "mdc-notched-outline__leading" }),
|
|
71
|
-
index.h("div", { class: "mdc-notched-outline__notch" }, labelEl),
|
|
72
|
-
index.h("div", { class: "mdc-notched-outline__trailing" }))) : (index.h("span", { class: "mdc-line-ripple" }))));
|
|
73
|
-
}
|
|
74
|
-
function setHelper(props) {
|
|
75
|
-
if (props.helperEnabled !== false) {
|
|
76
|
-
if (props.helper) {
|
|
77
|
-
const classObj = {
|
|
78
|
-
'mdc-text-field-helper-text': true,
|
|
79
|
-
'mdc-text-field-helper-text--persistent': !props.helperWhenFocused,
|
|
80
|
-
};
|
|
81
|
-
return (index.h("div", { class: "mdc-text-field-helper-line" },
|
|
82
|
-
index.h("div", { class: classObj }, props.helper),
|
|
83
|
-
props.maxLength && !props.textArea ? (index.h("div", { class: "mdc-text-field-character-counter" },
|
|
84
|
-
"'0 / ' + ",
|
|
85
|
-
props.maxLength.toString())) : undefined));
|
|
86
|
-
}
|
|
87
|
-
else {
|
|
88
|
-
if (props.maxLength && !props.textArea) {
|
|
89
|
-
return (index.h("div", { class: "mdc-text-field-helper-line" },
|
|
90
|
-
index.h("div", { class: "mdc-text-field-character-counter" },
|
|
91
|
-
"'0 / ' + ",
|
|
92
|
-
props.maxLength)));
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
}
|
|
24
|
+
return (index.h("div", Object.assign({ class: `f-checkbox ${props.danger ? 'kup-danger' : ''} ${props.info ? 'kup-info' : ''} ${props.secondary ? 'kup-secondary' : ''} ${props.success ? 'kup-success' : ''} ${props.warning ? 'kup-warning' : ''} ${props.wrapperClass ? props.wrapperClass : ''}` }, props.dataSet, { id: props.id, title: props.title }),
|
|
25
|
+
index.h("div", { class: `form-field ${props.leadingLabel ? 'form-field--align-end' : ''}` },
|
|
26
|
+
index.h("div", { class: classObj },
|
|
27
|
+
index.h("input", Object.assign({ type: "checkbox", class: "checkbox__native-control", checked: props.checked, disabled: props.disabled, onBlur: props.onBlur, onChange: props.onChange, onFocus: props.onFocus }, indeterminateAttr, { value: props.checked ? 'on' : 'off' })),
|
|
28
|
+
index.h("div", { class: "checkbox__background", onClick: props.onChange },
|
|
29
|
+
index.h("svg", { class: "checkbox__checkmark", viewBox: "0 0 24 24" },
|
|
30
|
+
index.h("path", { class: "checkbox__checkmark-path", fill: "none", d: "M1.73,12.91 8.1,19.28 22.79,4.59" })),
|
|
31
|
+
index.h("div", { class: "checkbox__mixedmark" }))),
|
|
32
|
+
props.label ? index.h("label", null, props.label) : undefined)));
|
|
33
|
+
};
|
|
97
34
|
|
|
98
35
|
const autoAlignComps = [kupManager.KupTagNames.DATA_TABLE, kupManager.KupTagNames.TREE];
|
|
99
36
|
/**
|
|
@@ -240,35 +177,11 @@ const kupTypes = [
|
|
|
240
177
|
FCellTypes.RATING,
|
|
241
178
|
];
|
|
242
179
|
|
|
243
|
-
/*-------------------------------------------------*/
|
|
244
|
-
/* C o m p o n e n t */
|
|
245
|
-
/*-------------------------------------------------*/
|
|
246
|
-
const FCheckbox = (props) => {
|
|
247
|
-
const indeterminateAttr = {
|
|
248
|
-
'data-indeterminate': props.indeterminate ? true : false,
|
|
249
|
-
};
|
|
250
|
-
const classObj = {
|
|
251
|
-
checkbox: true,
|
|
252
|
-
'checkbox--checked': props.checked && !props.indeterminate ? true : false,
|
|
253
|
-
'checkbox--disabled': props.disabled ? true : false,
|
|
254
|
-
'checkbox--indeterminate': props.indeterminate ? true : false,
|
|
255
|
-
};
|
|
256
|
-
return (index.h("div", Object.assign({ class: `f-checkbox ${props.danger ? 'kup-danger' : ''} ${props.info ? 'kup-info' : ''} ${props.secondary ? 'kup-secondary' : ''} ${props.success ? 'kup-success' : ''} ${props.warning ? 'kup-warning' : ''} ${props.wrapperClass ? props.wrapperClass : ''}` }, props.dataSet, { id: props.id, title: props.title }),
|
|
257
|
-
index.h("div", { class: `form-field ${props.leadingLabel ? 'form-field--align-end' : ''}` },
|
|
258
|
-
index.h("div", { class: classObj },
|
|
259
|
-
index.h("input", Object.assign({ type: "checkbox", class: "checkbox__native-control", checked: props.checked, disabled: props.disabled, onBlur: props.onBlur, onChange: props.onChange, onFocus: props.onFocus }, indeterminateAttr, { value: props.checked ? 'on' : 'off' })),
|
|
260
|
-
index.h("div", { class: "checkbox__background", onClick: props.onChange },
|
|
261
|
-
index.h("svg", { class: "checkbox__checkmark", viewBox: "0 0 24 24" },
|
|
262
|
-
index.h("path", { class: "checkbox__checkmark-path", fill: "none", d: "M1.73,12.91 8.1,19.28 22.79,4.59" })),
|
|
263
|
-
index.h("div", { class: "checkbox__mixedmark" }))),
|
|
264
|
-
props.label ? index.h("label", null, props.label) : undefined)));
|
|
265
|
-
};
|
|
266
|
-
|
|
267
180
|
const dom = document.documentElement;
|
|
268
181
|
/*-------------------------------------------------*/
|
|
269
182
|
/* C o m p o n e n t */
|
|
270
183
|
/*-------------------------------------------------*/
|
|
271
|
-
const FCell = (props) => {
|
|
184
|
+
const FCell = (props, children) => {
|
|
272
185
|
const cell = props.cell;
|
|
273
186
|
const column = props.column;
|
|
274
187
|
const row = props.row;
|
|
@@ -356,12 +269,12 @@ const FCell = (props) => {
|
|
|
356
269
|
};
|
|
357
270
|
infoEl = index.h(fImage.FImage, Object.assign({}, fProps));
|
|
358
271
|
}
|
|
359
|
-
return (index.h("div", { class: classObj,
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
content)));
|
|
272
|
+
return (index.h("div", { class: classObj, "kup-get-cell-props": () => {
|
|
273
|
+
return props;
|
|
274
|
+
}, style: cell.style },
|
|
275
|
+
index.h("div", { class: "f-cell__content", style: cell.styleContent, title: cellTitle }, children && children.length > 0
|
|
276
|
+
? children
|
|
277
|
+
: [props.indents, infoEl, icon, content])));
|
|
365
278
|
};
|
|
366
279
|
function setCellSize(cellType, subcomponentProps, cell, props) {
|
|
367
280
|
switch (cellType) {
|
|
@@ -477,7 +390,7 @@ function setEditableCell(cellType, classObj, cell, column, props) {
|
|
|
477
390
|
case FCellTypes.NUMBER:
|
|
478
391
|
classObj[FCellClasses.C_RIGHT_ALIGNED] = true;
|
|
479
392
|
case FCellTypes.STRING:
|
|
480
|
-
return (index.h(FTextField, Object.assign({}, cell.data, { icon: cell.icon ? cell.icon : column.icon ? column.icon : null, fullWidth: true, inputType: cellType === FCellTypes.NUMBER ? 'number' : null, value: cellType === FCellTypes.NUMBER
|
|
393
|
+
return (index.h(fTextField.FTextField, Object.assign({}, cell.data, { icon: cell.icon ? cell.icon : column.icon ? column.icon : null, fullWidth: true, inputType: cellType === FCellTypes.NUMBER ? 'number' : null, value: cellType === FCellTypes.NUMBER
|
|
481
394
|
? utils.stringToNumber(cell.value).toString()
|
|
482
395
|
: cell.value, onChange: (e) => cellEvent(e, props, cellType, FCellEvents.UPDATE), onInput: (e) => cellEvent(e, props, cellType, FCellEvents.INPUT), onIconClick: (e) => cellEvent(e, props, cellType, FCellEvents.ICON_CLICK) })));
|
|
483
396
|
}
|
|
@@ -738,4 +651,3 @@ function cellEvent(e, props, cellType, cellEventName) {
|
|
|
738
651
|
|
|
739
652
|
exports.FCell = FCell;
|
|
740
653
|
exports.FCheckbox = FCheckbox;
|
|
741
|
-
exports.FTextField = FTextField;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const fImage = require('./f-image-
|
|
5
|
-
const kupManager = require('./kup-manager-
|
|
3
|
+
const index = require('./index-eb556444.js');
|
|
4
|
+
const fImage = require('./f-image-89f25556.js');
|
|
5
|
+
const kupManager = require('./kup-manager-7a941909.js');
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Types of the f-chip component.
|
|
@@ -76,7 +76,8 @@ function createChipList(props, isChoice, isFilter, isInput) {
|
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
function createChip(chip) {
|
|
79
|
-
|
|
79
|
+
const onlyIcon = !!(chip.icon && !chip.value);
|
|
80
|
+
let componentClass = `chip ${onlyIcon ? 'chip--only-icon' : ''}`;
|
|
80
81
|
let iconEl = [];
|
|
81
82
|
let iconClass = 'chip__icon chip__icon--leading';
|
|
82
83
|
if (isFilter || isChoice) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const kupManager = require('./kup-manager-
|
|
3
|
+
const index = require('./index-eb556444.js');
|
|
4
|
+
const kupManager = require('./kup-manager-7a941909.js');
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* The type of a CSS step in CSS-drawing mode.
|