indicator-ui 0.0.49 → 0.0.51
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/index.js
CHANGED
|
@@ -3290,7 +3290,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
3290
3290
|
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
3291
3291
|
/* harmony export */ });
|
|
3292
3292
|
// extracted by mini-css-extract-plugin
|
|
3293
|
-
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({"tag":"Tag-module__tag___z87CD","main":"Tag-module__main___M5V6V","label":"Tag-module__label___SRW7b","dotIcon":"Tag-module__dotIcon___GkMuO","active":"Tag-module__active___uw5nt","small":"Tag-module__small___ob2Q8","isAction":"Tag-module__isAction___ReWct","isCheckbox":"Tag-module__isCheckbox___qHbJo","medium":"Tag-module__medium___TjmGK","large":"Tag-module__large___rpGp5"});
|
|
3293
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({"tag":"Tag-module__tag___z87CD","main":"Tag-module__main___M5V6V","label":"Tag-module__label___SRW7b","dotIcon":"Tag-module__dotIcon___GkMuO","active":"Tag-module__active___uw5nt","small":"Tag-module__small___ob2Q8","isAction":"Tag-module__isAction___ReWct","isCheckbox":"Tag-module__isCheckbox___qHbJo","medium":"Tag-module__medium___TjmGK","large":"Tag-module__large___rpGp5","clicked":"Tag-module__clicked___Db5ww"});
|
|
3294
3294
|
|
|
3295
3295
|
/***/ }),
|
|
3296
3296
|
|
|
@@ -7539,7 +7539,11 @@ const getInitChosenInterval = ({ start, end, multiple, formatIn }) => {
|
|
|
7539
7539
|
};
|
|
7540
7540
|
const getInitTargetDate = ({ start, end, formatIn }) => {
|
|
7541
7541
|
const chosenDate = start || end;
|
|
7542
|
-
|
|
7542
|
+
let formatDate;
|
|
7543
|
+
try {
|
|
7544
|
+
formatDate = chosenDate ? (0,date_fns__WEBPACK_IMPORTED_MODULE_11__.parse)(chosenDate, formatIn || 'yyyy-MM-dd', new Date()).toISOString() : undefined;
|
|
7545
|
+
}
|
|
7546
|
+
catch (e) { }
|
|
7543
7547
|
if (formatDate) {
|
|
7544
7548
|
return formatDate;
|
|
7545
7549
|
}
|
|
@@ -7828,8 +7832,18 @@ function DatePicker({ chosenStart, chosenEnd, markFun, infoFun, onSubmit, format
|
|
|
7828
7832
|
setTargetDate(prevState => (0,date_fns__WEBPACK_IMPORTED_MODULE_8__.addMonths)(prevState, 1).toISOString());
|
|
7829
7833
|
};
|
|
7830
7834
|
const handleSubmit = () => {
|
|
7831
|
-
|
|
7832
|
-
|
|
7835
|
+
let start = undefined;
|
|
7836
|
+
let end = undefined;
|
|
7837
|
+
try {
|
|
7838
|
+
start = chosenInterval.start ? (0,date_fns__WEBPACK_IMPORTED_MODULE_9__.format)(chosenInterval.start, formatOut || 'yyyy-MM-dd') : undefined;
|
|
7839
|
+
}
|
|
7840
|
+
catch (e) {
|
|
7841
|
+
}
|
|
7842
|
+
try {
|
|
7843
|
+
end = chosenInterval.end ? (0,date_fns__WEBPACK_IMPORTED_MODULE_9__.format)(chosenInterval.end, formatOut || 'yyyy-MM-dd') : undefined;
|
|
7844
|
+
}
|
|
7845
|
+
catch (e) {
|
|
7846
|
+
}
|
|
7833
7847
|
onSubmit && onSubmit({ start: start, end: end });
|
|
7834
7848
|
};
|
|
7835
7849
|
const onClickDate = (date) => {
|
|
@@ -10430,6 +10444,7 @@ function Tag({ active = false, size = 'medium', icon = false, label, checkbox =
|
|
|
10430
10444
|
[_styles__WEBPACK_IMPORTED_MODULE_4__.TagStyle?.large]: size === 'large',
|
|
10431
10445
|
[_styles__WEBPACK_IMPORTED_MODULE_4__.TagStyle?.isAction]: actions !== 'text-only' && actions !== undefined,
|
|
10432
10446
|
[_styles__WEBPACK_IMPORTED_MODULE_4__.TagStyle?.isCheckbox]: checkbox,
|
|
10447
|
+
[_styles__WEBPACK_IMPORTED_MODULE_4__.TagStyle?.clicked]: onClick !== undefined,
|
|
10433
10448
|
}), children: [getIcon(), (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", { className: _styles__WEBPACK_IMPORTED_MODULE_4__.TagStyle?.main, children: [getCheckbox(), getLabel(), getAction()] })] }));
|
|
10434
10449
|
}
|
|
10435
10450
|
|