@dreamcommerce/aurora 0.3.4-166 → 0.3.4-167
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/build/cjs/_virtual/_tslib.js +9 -7
- package/build/cjs/_virtual/_tslib.js.map +1 -1
- package/build/cjs/packages/aurora/src/components/button/css_classes.js +6 -6
- package/build/cjs/packages/aurora/src/components/buttons_group/css_classes.js +3 -3
- package/build/cjs/packages/aurora/src/components/color_picker/components/hue_picker.js +1 -1
- package/build/cjs/packages/aurora/src/components/color_picker/components/label.js +1 -1
- package/build/cjs/packages/aurora/src/components/color_picker/components/saturation_lightness_picker.js +5 -6
- package/build/cjs/packages/aurora/src/components/color_picker/components/saturation_lightness_picker.js.map +1 -1
- package/build/cjs/packages/aurora/src/components/color_picker/css_classes.js +11 -11
- package/build/cjs/packages/aurora/src/components/color_picker/index.js +6 -6
- package/build/cjs/packages/aurora/src/components/color_picker/utilities.js +1 -1
- package/build/cjs/packages/aurora/src/components/controls/components/cell_selector.js +3 -3
- package/build/cjs/packages/aurora/src/components/controls/components/errors.js +1 -1
- package/build/cjs/packages/aurora/src/components/controls/css_classes.js +25 -25
- package/build/cjs/packages/aurora/src/components/controls/hoc/control_radio_group/index.js +1 -1
- package/build/cjs/packages/aurora/src/components/controls/index.js +1 -1
- package/build/cjs/packages/aurora/src/components/date_picker/components/days_grid.js +4 -4
- package/build/cjs/packages/aurora/src/components/date_picker/components/month_controller.js +4 -4
- package/build/cjs/packages/aurora/src/components/date_picker/components/month_year_picker/components/month_view.js +1 -1
- package/build/cjs/packages/aurora/src/components/date_picker/components/month_year_picker/components/month_year_controller.js +2 -2
- package/build/cjs/packages/aurora/src/components/date_picker/components/month_year_picker/components/month_year_picker_context_manager.js +1 -1
- package/build/cjs/packages/aurora/src/components/date_picker/components/month_year_picker/components/years_view.js +1 -1
- package/build/cjs/packages/aurora/src/components/date_picker/components/pure_date_picker.js +1 -1
- package/build/cjs/packages/aurora/src/components/date_picker/constants.js +6 -6
- package/build/cjs/packages/aurora/src/components/date_picker/css_classes.js +30 -30
- package/build/cjs/packages/aurora/src/components/date_picker/hoc/range_picker.js +4 -4
- package/build/cjs/packages/aurora/src/components/date_picker/hooks/use_animation.js +1 -1
- package/build/cjs/packages/aurora/src/components/date_picker/hooks/use_value_controller.js +2 -6
- package/build/cjs/packages/aurora/src/components/date_picker/hooks/use_value_controller.js.map +1 -1
- package/build/cjs/packages/aurora/src/components/dropdown/components/content.js +1 -1
- package/build/cjs/packages/aurora/src/components/dropdown/components/link.js +1 -1
- package/build/cjs/packages/aurora/src/components/dropdown/constants.js +1 -1
- package/build/cjs/packages/aurora/src/components/dropdown/css_classes.js +13 -13
- package/build/cjs/packages/aurora/src/components/dropdown/hooks/use_values.js +1 -1
- package/build/cjs/packages/aurora/src/components/dropdown/utilities.js +1 -1
- package/build/cjs/packages/aurora/src/components/file_picker/components/file_input.js +1 -1
- package/build/cjs/packages/aurora/src/components/flash_messenger/components/flash_message.js +1 -1
- package/build/cjs/packages/aurora/src/components/flash_messenger/index.js +5 -5
- package/build/cjs/packages/aurora/src/components/gallery/css_classes.js +24 -24
- package/build/cjs/packages/aurora/src/components/gallery/index.js +61 -62
- package/build/cjs/packages/aurora/src/components/gallery/index.js.map +1 -1
- package/build/cjs/packages/aurora/src/components/gallery/utilities/get_url.js +2 -2
- package/build/cjs/packages/aurora/src/components/gallery/utilities/handle_history.js +4 -4
- package/build/cjs/packages/aurora/src/components/grid/components/box.js +1 -1
- package/build/cjs/packages/aurora/src/components/grid/components/col.js +5 -5
- package/build/cjs/packages/aurora/src/components/grid/components/row.js +2 -2
- package/build/cjs/packages/aurora/src/components/grid/utils.js +5 -5
- package/build/cjs/packages/aurora/src/components/heading/index.js +1 -1
- package/build/cjs/packages/aurora/src/components/label/css_classes.js +2 -2
- package/build/cjs/packages/aurora/src/components/loader/css_classes.js +3 -3
- package/build/cjs/packages/aurora/src/components/message-box/index.js +1 -1
- package/build/cjs/packages/aurora/src/components/modal/components/modal.js +1 -1
- package/build/cjs/packages/aurora/src/components/modal/hoc/absolute_modal/index.js +1 -1
- package/build/cjs/packages/aurora/src/components/modal/hoc/relative_modal/index.js +1 -1
- package/build/cjs/packages/aurora/src/components/modal/index.js +1 -1
- package/build/cjs/packages/aurora/src/components/modal/utilities.js +4 -4
- package/build/cjs/packages/aurora/src/components/range/css_classes.js +1 -1
- package/build/cjs/packages/aurora/src/components/range/index.js +4 -4
- package/build/cjs/packages/aurora/src/components/range/utilities.js +4 -4
- package/build/cjs/packages/aurora/src/components/spacing/index.js +2 -2
- package/build/cjs/packages/aurora/src/components/table/components/cell.js +2 -2
- package/build/cjs/packages/aurora/src/components/table/hoc/data-table.js +3 -3
- package/build/cjs/packages/aurora/src/components/tag/css_classes.js +2 -2
- package/build/cjs/packages/aurora/src/components/tag/index.js +2 -2
- package/build/cjs/packages/aurora/src/components/tags_selector/components/list.js +2 -2
- package/build/cjs/packages/aurora/src/components/tags_selector/components/search.js +1 -1
- package/build/cjs/packages/aurora/src/components/tags_selector/components/wrapper.js +1 -1
- package/build/cjs/packages/aurora/src/components/tags_selector/css_classes.js +4 -4
- package/build/cjs/packages/aurora/src/components/tags_selector/index.js +2 -2
- package/build/cjs/packages/aurora/src/hooks/use_key_down.js +1 -1
- package/build/cjs/packages/aurora/src/hooks/use_unique_id.js +1 -1
- package/build/cjs/packages/aurora/src/utilities/colors/color_converter.js +1 -1
- package/build/cjs/packages/aurora/src/utilities/fuzzy_search/fuzzy_search.js +1 -1
- package/build/esm/_virtual/_tslib.js +9 -7
- package/build/esm/_virtual/_tslib.js.map +1 -1
- package/build/esm/packages/aurora/src/components/button/components/link/types.js +1 -0
- package/build/esm/packages/aurora/src/components/button/css_classes.js +6 -6
- package/build/esm/packages/aurora/src/components/buttons_group/css_classes.js +3 -3
- package/build/esm/packages/aurora/src/components/color_picker/components/hue_picker.js +1 -1
- package/build/esm/packages/aurora/src/components/color_picker/components/label.js +1 -1
- package/build/esm/packages/aurora/src/components/color_picker/components/saturation_lightness_picker.js +5 -6
- package/build/esm/packages/aurora/src/components/color_picker/components/saturation_lightness_picker.js.map +1 -1
- package/build/esm/packages/aurora/src/components/color_picker/css_classes.js +11 -11
- package/build/esm/packages/aurora/src/components/color_picker/index.js +6 -6
- package/build/esm/packages/aurora/src/components/color_picker/utilities.js +1 -1
- package/build/esm/packages/aurora/src/components/controls/components/cell_selector.js +3 -3
- package/build/esm/packages/aurora/src/components/controls/components/errors.js +1 -1
- package/build/esm/packages/aurora/src/components/controls/css_classes.js +25 -25
- package/build/esm/packages/aurora/src/components/controls/hoc/control_radio_group/index.js +1 -1
- package/build/esm/packages/aurora/src/components/controls/index.js +1 -1
- package/build/esm/packages/aurora/src/components/date_picker/components/days_grid.js +4 -4
- package/build/esm/packages/aurora/src/components/date_picker/components/month_controller.js +4 -4
- package/build/esm/packages/aurora/src/components/date_picker/components/month_year_picker/components/month_view.js +1 -1
- package/build/esm/packages/aurora/src/components/date_picker/components/month_year_picker/components/month_year_controller.js +2 -2
- package/build/esm/packages/aurora/src/components/date_picker/components/month_year_picker/components/month_year_picker_context_manager.js +1 -1
- package/build/esm/packages/aurora/src/components/date_picker/components/month_year_picker/components/years_view.js +1 -1
- package/build/esm/packages/aurora/src/components/date_picker/components/pure_date_picker.js +1 -1
- package/build/esm/packages/aurora/src/components/date_picker/constants.js +6 -6
- package/build/esm/packages/aurora/src/components/date_picker/css_classes.js +30 -30
- package/build/esm/packages/aurora/src/components/date_picker/hoc/range_picker.js +4 -4
- package/build/esm/packages/aurora/src/components/date_picker/hooks/use_animation.js +1 -1
- package/build/esm/packages/aurora/src/components/date_picker/hooks/use_value_controller.js +2 -6
- package/build/esm/packages/aurora/src/components/date_picker/hooks/use_value_controller.js.map +1 -1
- package/build/esm/packages/aurora/src/components/dropdown/components/content.js +1 -1
- package/build/esm/packages/aurora/src/components/dropdown/components/link.js +1 -1
- package/build/esm/packages/aurora/src/components/dropdown/constants.js +1 -1
- package/build/esm/packages/aurora/src/components/dropdown/context/types.js +1 -0
- package/build/esm/packages/aurora/src/components/dropdown/css_classes.js +13 -13
- package/build/esm/packages/aurora/src/components/dropdown/hooks/use_values.js +2 -2
- package/build/esm/packages/aurora/src/components/dropdown/utilities.d.ts +2 -2
- package/build/esm/packages/aurora/src/components/dropdown/utilities.js +1 -1
- package/build/esm/packages/aurora/src/components/file_picker/components/file_input.js +1 -1
- package/build/esm/packages/aurora/src/components/flash_messenger/components/flash_message.js +1 -1
- package/build/esm/packages/aurora/src/components/flash_messenger/index.js +6 -6
- package/build/esm/packages/aurora/src/components/gallery/css_classes.js +24 -24
- package/build/esm/packages/aurora/src/components/gallery/index.d.ts +1 -1
- package/build/esm/packages/aurora/src/components/gallery/index.js +61 -62
- package/build/esm/packages/aurora/src/components/gallery/index.js.map +1 -1
- package/build/esm/packages/aurora/src/components/gallery/types.js +1 -0
- package/build/esm/packages/aurora/src/components/gallery/utilities/get_url.js +2 -2
- package/build/esm/packages/aurora/src/components/gallery/utilities/handle_history.js +4 -4
- package/build/esm/packages/aurora/src/components/grid/components/box.js +1 -1
- package/build/esm/packages/aurora/src/components/grid/components/col.js +5 -5
- package/build/esm/packages/aurora/src/components/grid/components/row.js +2 -2
- package/build/esm/packages/aurora/src/components/grid/utils.js +5 -5
- package/build/esm/packages/aurora/src/components/heading/index.js +1 -1
- package/build/esm/packages/aurora/src/components/heading/types.js +1 -0
- package/build/esm/packages/aurora/src/components/label/css_classes.js +2 -2
- package/build/esm/packages/aurora/src/components/loader/css_classes.js +3 -3
- package/build/esm/packages/aurora/src/components/message-box/index.js +1 -1
- package/build/esm/packages/aurora/src/components/message-box/types.js +1 -0
- package/build/esm/packages/aurora/src/components/modal/components/modal.js +1 -1
- package/build/esm/packages/aurora/src/components/modal/hoc/absolute_modal/index.js +1 -1
- package/build/esm/packages/aurora/src/components/modal/hoc/relative_modal/index.js +1 -1
- package/build/esm/packages/aurora/src/components/modal/index.js +1 -1
- package/build/esm/packages/aurora/src/components/modal/utilities.js +4 -4
- package/build/esm/packages/aurora/src/components/range/css_classes.js +1 -1
- package/build/esm/packages/aurora/src/components/range/index.js +4 -4
- package/build/esm/packages/aurora/src/components/range/types.js +1 -0
- package/build/esm/packages/aurora/src/components/range/utilities.js +4 -4
- package/build/esm/packages/aurora/src/components/spacing/index.js +2 -2
- package/build/esm/packages/aurora/src/components/table/components/cell.js +2 -2
- package/build/esm/packages/aurora/src/components/table/hoc/data-table.js +3 -3
- package/build/esm/packages/aurora/src/components/tag/css_classes.js +2 -2
- package/build/esm/packages/aurora/src/components/tag/index.js +2 -2
- package/build/esm/packages/aurora/src/components/tags_selector/components/list.js +2 -2
- package/build/esm/packages/aurora/src/components/tags_selector/components/search.js +1 -1
- package/build/esm/packages/aurora/src/components/tags_selector/components/wrapper.js +1 -1
- package/build/esm/packages/aurora/src/components/tags_selector/css_classes.js +4 -4
- package/build/esm/packages/aurora/src/components/tags_selector/index.js +3 -3
- package/build/esm/packages/aurora/src/hooks/use_key_down.d.ts +1 -1
- package/build/esm/packages/aurora/src/hooks/use_key_down.js +1 -1
- package/build/esm/packages/aurora/src/hooks/use_unique_id.js +1 -1
- package/build/esm/packages/aurora/src/typings/general.js +1 -0
- package/build/esm/packages/aurora/src/utilities/colors/color_converter.js +1 -1
- package/build/esm/packages/aurora/src/utilities/colors/types.js +1 -0
- package/build/esm/packages/aurora/src/utilities/events/event_registration.d.ts +2 -2
- package/build/esm/packages/aurora/src/utilities/fuzzy_search/fuzzy_search.js +2 -2
- package/build/esm/packages/aurora/src/utilities/styles/classNames.d.ts +1 -1
- package/package.json +3 -3
|
@@ -7,11 +7,11 @@ var colClassName = function (_a) {
|
|
|
7
7
|
var auto = _a.auto, _b = _a.col, col = _b === void 0 ? 1 : _b, md = _a.md, sm = _a.sm, xs = _a.xs, lg = _a.lg, order = _a.order, className = _a.className;
|
|
8
8
|
return classNames([
|
|
9
9
|
className,
|
|
10
|
-
auto && "col_"
|
|
11
|
-
(xs || col) && "col_xs-"
|
|
12
|
-
(sm || col) && "col_sm-"
|
|
13
|
-
(md || col) && "col_md-"
|
|
14
|
-
(lg || col) && "col_lg-"
|
|
10
|
+
auto && "col_".concat(auto),
|
|
11
|
+
(xs || col) && "col_xs-".concat(xs || col),
|
|
12
|
+
(sm || col) && "col_sm-".concat(sm || col),
|
|
13
|
+
(md || col) && "col_md-".concat(md || col),
|
|
14
|
+
(lg || col) && "col_lg-".concat(lg || col),
|
|
15
15
|
columnOrderClass(order || {}),
|
|
16
16
|
], styles);
|
|
17
17
|
};
|
|
@@ -17,14 +17,14 @@ var rowClassName = function (_a) {
|
|
|
17
17
|
};
|
|
18
18
|
var Row = function (_a) {
|
|
19
19
|
var className = _a.className, children = _a.children, verticalPosition = _a.verticalPosition, horizontalPosition = _a.horizontalPosition, vertical = _a.vertical, inner = _a.inner, noWrap = _a.noWrap;
|
|
20
|
-
return (React.createElement("div", { className: ""
|
|
20
|
+
return (React.createElement("div", { className: "".concat(rowClassName({
|
|
21
21
|
verticalPosition: verticalPosition,
|
|
22
22
|
horizontalPosition: horizontalPosition,
|
|
23
23
|
vertical: vertical,
|
|
24
24
|
inner: inner,
|
|
25
25
|
noWrap: noWrap,
|
|
26
26
|
className: className,
|
|
27
|
-
}) }, children));
|
|
27
|
+
})) }, children));
|
|
28
28
|
};
|
|
29
29
|
|
|
30
30
|
export default Row;
|
|
@@ -6,7 +6,7 @@ import 'react';
|
|
|
6
6
|
var boxSpacing = function (_a) {
|
|
7
7
|
var size = _a.size, spacing = _a.spacing, horizontal = _a.horizontal, vertical = _a.vertical;
|
|
8
8
|
return spacing || horizontal || vertical || size
|
|
9
|
-
? "box_spacing"
|
|
9
|
+
? "box_spacing".concat(horizontal ? '-horizontal' : '').concat(vertical ? '-vertical' : '').concat(size ? "-".concat(size) : '')
|
|
10
10
|
: '';
|
|
11
11
|
};
|
|
12
12
|
/**
|
|
@@ -15,10 +15,10 @@ var boxSpacing = function (_a) {
|
|
|
15
15
|
var columnOrderClass = function (_a) {
|
|
16
16
|
var col = _a.col, md = _a.md, sm = _a.sm, xs = _a.xs, lg = _a.lg;
|
|
17
17
|
return [
|
|
18
|
-
(xs || col) && "col_order-xs-"
|
|
19
|
-
(sm || col) && "col_order-sm-"
|
|
20
|
-
(md || col) && "col_order-md-"
|
|
21
|
-
(lg || col) && "col_order-lg-"
|
|
18
|
+
(xs || col) && "col_order-xs-".concat(xs || col),
|
|
19
|
+
(sm || col) && "col_order-sm-".concat(sm || col),
|
|
20
|
+
(md || col) && "col_order-md-".concat(md || col),
|
|
21
|
+
(lg || col) && "col_order-lg-".concat(lg || col),
|
|
22
22
|
]
|
|
23
23
|
.filter(function (col) { return col; })
|
|
24
24
|
.join(' ');
|
|
@@ -6,7 +6,7 @@ var Heading = function (_a) {
|
|
|
6
6
|
var _b = _a.as, as = _b === void 0 ? 'h1' : _b, isSubheading = _a.isSubheading, withHeadline = _a.withHeadline, children = _a.children;
|
|
7
7
|
var classes = classnames(cssClasses[as], withHeadline && cssClasses.head_line);
|
|
8
8
|
if (!isSubheading) {
|
|
9
|
-
return React.createElement(""
|
|
9
|
+
return React.createElement("".concat(as), {
|
|
10
10
|
className: classes,
|
|
11
11
|
}, children);
|
|
12
12
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var cssLabel = 'label';
|
|
2
|
-
var cssLabelRequired = cssLabel
|
|
3
|
-
var cssLabelError = cssLabel
|
|
2
|
+
var cssLabelRequired = "".concat(cssLabel, "_required");
|
|
3
|
+
var cssLabelError = "".concat(cssLabel, "_error");
|
|
4
4
|
|
|
5
5
|
export { cssLabel, cssLabelError, cssLabelRequired };
|
|
6
6
|
//# sourceMappingURL=css_classes.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var cssLoader = 'loader';
|
|
2
|
-
var cssLoaderSizeSmall = cssLoader
|
|
3
|
-
var cssLoaderSizeLarge = cssLoader
|
|
4
|
-
var cssLoaderSizeExtraLarge = cssLoader
|
|
2
|
+
var cssLoaderSizeSmall = "".concat(cssLoader, "_s");
|
|
3
|
+
var cssLoaderSizeLarge = "".concat(cssLoader, "_l");
|
|
4
|
+
var cssLoaderSizeExtraLarge = "".concat(cssLoader, "_xl");
|
|
5
5
|
|
|
6
6
|
export { cssLoader, cssLoaderSizeExtraLarge, cssLoaderSizeLarge, cssLoaderSizeSmall };
|
|
7
7
|
//# sourceMappingURL=css_classes.js.map
|
|
@@ -4,7 +4,7 @@ import cssClasses from '../../css/message-box/main.module.less.js';
|
|
|
4
4
|
|
|
5
5
|
var MessageBox = function (_a) {
|
|
6
6
|
var children = _a.children, header = _a.header, type = _a.type, withoutIcon = _a.withoutIcon, fullWidth = _a.fullWidth, className = _a.className;
|
|
7
|
-
var messageBoxClassName = classNames([className, 'message-box', type && "message-box_"
|
|
7
|
+
var messageBoxClassName = classNames([className, 'message-box', type && "message-box_".concat(type), fullWidth && "message-box_full-width"], cssClasses);
|
|
8
8
|
return (React.createElement("div", { className: messageBoxClassName },
|
|
9
9
|
!withoutIcon && React.createElement("div", { className: cssClasses['message-box__icon'] }),
|
|
10
10
|
React.createElement("div", { className: cssClasses['message-box__content'] },
|
|
@@ -3,7 +3,7 @@ import cssClasses from '../../../css/modal/main.module.less.js';
|
|
|
3
3
|
|
|
4
4
|
var Modal = function (_a) {
|
|
5
5
|
var children = _a.children, className = _a.className, modalRef = _a.modalRef;
|
|
6
|
-
return (React.createElement("div", { "data-test-id": "modal", ref: modalRef, className: cssClasses['modal-window']
|
|
6
|
+
return (React.createElement("div", { "data-test-id": "modal", ref: modalRef, className: "".concat(cssClasses['modal-window'], " ").concat(cssClasses['modal-window_visible'], " ").concat(className) },
|
|
7
7
|
React.createElement("div", { className: cssClasses['modal-window__body'] }, children)));
|
|
8
8
|
};
|
|
9
9
|
|
|
@@ -53,7 +53,7 @@ var AbsoluteModal = function (_a) {
|
|
|
53
53
|
animationDirection: animationDirection,
|
|
54
54
|
}));
|
|
55
55
|
}, [animationDirection, hPosition, offset, transformLength, vPosition, isVisible]);
|
|
56
|
-
return createPortal(React.createElement(Modal, __assign({ className: classes.modal
|
|
56
|
+
return createPortal(React.createElement(Modal, __assign({ className: "".concat(classes.modal, " ").concat(isVisible ? cssClasses['modal-window_visible'] : ''), modalRef: modalRef }, rest), children), document.body);
|
|
57
57
|
};
|
|
58
58
|
|
|
59
59
|
export default AbsoluteModal;
|
|
@@ -59,7 +59,7 @@ var RelativeModal = function (_a) {
|
|
|
59
59
|
modalRect: (_b = modalRef === null || modalRef === void 0 ? void 0 : modalRef.current) === null || _b === void 0 ? void 0 : _b.getBoundingClientRect(),
|
|
60
60
|
}));
|
|
61
61
|
}, 50);
|
|
62
|
-
return createPortal(React.createElement(Modal, __assign({ className: classes.modal
|
|
62
|
+
return createPortal(React.createElement(Modal, __assign({ className: "".concat(classes.modal, " ").concat(isVisible ? cssClasses['modal-window_visible'] : ''), modalRef: modalRef }, rest), children), document.body);
|
|
63
63
|
};
|
|
64
64
|
|
|
65
65
|
export default RelativeModal;
|
|
@@ -6,7 +6,7 @@ import Footer from './components/footer.js';
|
|
|
6
6
|
|
|
7
7
|
var Modal = function (_a) {
|
|
8
8
|
var children = _a.children, className = _a.className, modalRef = _a.modalRef;
|
|
9
|
-
return (React.createElement("div", { ref: modalRef, className: cssClasses['modal-window']
|
|
9
|
+
return (React.createElement("div", { ref: modalRef, className: "".concat(cssClasses['modal-window'], " ").concat(className) },
|
|
10
10
|
React.createElement("div", { className: cssClasses['modal-window__body'] }, children)));
|
|
11
11
|
};
|
|
12
12
|
Modal.Header = Header;
|
|
@@ -14,15 +14,15 @@ var getTransformFromAnimationDirection = function (_a) {
|
|
|
14
14
|
return transform({ isVisible: isVisible });
|
|
15
15
|
}
|
|
16
16
|
if (animationDirection === 'bottomTop') {
|
|
17
|
-
return "translate(0px, "
|
|
17
|
+
return "translate(0px, ".concat(isVisible ? "-".concat(transformLength, "px") : '0px', ")");
|
|
18
18
|
}
|
|
19
19
|
if (animationDirection === 'leftRight') {
|
|
20
|
-
return "translate("
|
|
20
|
+
return "translate(".concat(isVisible ? "".concat(transformLength, "px") : '0px', ", 0px)");
|
|
21
21
|
}
|
|
22
22
|
if (animationDirection === 'rightLeft') {
|
|
23
|
-
return "translate("
|
|
23
|
+
return "translate(".concat(isVisible ? "-".concat(transformLength, "px") : '0px', ", 0px)");
|
|
24
24
|
}
|
|
25
|
-
return "translate(0px, "
|
|
25
|
+
return "translate(0px, ".concat(isVisible ? "".concat(transformLength, "px") : '0px', ")");
|
|
26
26
|
};
|
|
27
27
|
/**
|
|
28
28
|
* Function for relative to check if modal is still in viewport
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
var CSS_RANGE = 'range';
|
|
2
|
-
var CSS_RANGE_POINTER = CSS_RANGE
|
|
2
|
+
var CSS_RANGE_POINTER = "".concat(CSS_RANGE, "__pointer");
|
|
3
3
|
var CSS_RANGE_POINTER_DISABLED = CSS_RANGE_POINTER + '_disabled';
|
|
4
4
|
var CSS_RANGE_POINTER_INSIDE = CSS_RANGE_POINTER + '-inside';
|
|
5
5
|
var CSS_RANGE_POINTER_INSIDE_DISABLED = CSS_RANGE_POINTER_INSIDE + '_disabled';
|
|
@@ -10,7 +10,7 @@ var useStyles = createUseStyles({
|
|
|
10
10
|
pointer: {
|
|
11
11
|
transform: function (_a) {
|
|
12
12
|
var left = _a.left;
|
|
13
|
-
return "translate3d("
|
|
13
|
+
return "translate3d(".concat(left - 10, "px,0px,0px)");
|
|
14
14
|
},
|
|
15
15
|
background: function (_a) {
|
|
16
16
|
var isDragged = _a.isDragged, isDisabled = _a.isDisabled;
|
|
@@ -86,9 +86,9 @@ var Range = function (_a) {
|
|
|
86
86
|
onRangeChangeEvent(mapTouchEventToPosition(event));
|
|
87
87
|
registerOnTouchEvents(onRangeChangeEvent);
|
|
88
88
|
};
|
|
89
|
-
return (React.createElement("div", { className: styles[CSS_CLASSES.range]
|
|
90
|
-
React.createElement("div", { className: styles[CSS_CLASSES.rangePointer]
|
|
91
|
-
React.createElement("div", { className: styles[CSS_CLASSES.rangePointerInside]
|
|
89
|
+
return (React.createElement("div", { className: "".concat(styles[CSS_CLASSES.range], " ").concat(isDisabled ? styles[CSS_CLASSES.rangePointerDisabled] : ''), ref: rangeRef, onMouseDown: onSliderDown, onTouchStart: onTouchStart },
|
|
90
|
+
React.createElement("div", { className: "".concat(styles[CSS_CLASSES.rangePointer], " ").concat(classes.pointer), onDrag: onRangeChangeEvent, onTouchStart: onTouchStart },
|
|
91
|
+
React.createElement("div", { className: "".concat(styles[CSS_CLASSES.rangePointerInside], " ").concat(isDisabled ? styles[CSS_CLASSES.rangePointerInsideDisabled] : '') })),
|
|
92
92
|
name && React.createElement("input", { type: "hidden", name: name, value: value })));
|
|
93
93
|
};
|
|
94
94
|
|
|
@@ -2,8 +2,8 @@ import 'react';
|
|
|
2
2
|
import { constrainToRange } from '../../utilities/range/range_mappings.js';
|
|
3
3
|
|
|
4
4
|
var getPositionFromValue = function (_a) {
|
|
5
|
-
var value = _a.value, rangeRef = _a.rangeRef, max = _a.max, min = _a.min;
|
|
6
5
|
var _b;
|
|
6
|
+
var value = _a.value, rangeRef = _a.rangeRef, max = _a.max, min = _a.min;
|
|
7
7
|
var _c = ((_b = rangeRef === null || rangeRef === void 0 ? void 0 : rangeRef.current) === null || _b === void 0 ? void 0 : _b.getBoundingClientRect()) || {}, _d = _c.width, width = _d === void 0 ? 0 : _d, _e = _c.height, height = _e === void 0 ? 0 : _e;
|
|
8
8
|
var difference = max - min;
|
|
9
9
|
return {
|
|
@@ -12,8 +12,8 @@ var getPositionFromValue = function (_a) {
|
|
|
12
12
|
};
|
|
13
13
|
};
|
|
14
14
|
var getValueFromPosition = function (_a) {
|
|
15
|
-
var
|
|
16
|
-
var _f, _g;
|
|
15
|
+
var _b, _c;
|
|
16
|
+
var rangeRectangle = _a.rangeRectangle, position = _a.position, _d = _a.rotation, rotation = _d === void 0 ? 'horizontal' : _d, _e = _a.step, step = _e === void 0 ? 1 : _e, _f = _a.max, max = _f === void 0 ? 100 : _f, _g = _a.min, min = _g === void 0 ? 0 : _g;
|
|
17
17
|
var clientY = position.clientY, clientX = position.clientX;
|
|
18
18
|
var top = rangeRectangle.top, height = rangeRectangle.height, width = rangeRectangle.width, left = rangeRectangle.left;
|
|
19
19
|
var difference = max - min;
|
|
@@ -22,7 +22,7 @@ var getValueFromPosition = function (_a) {
|
|
|
22
22
|
var flooredValue = Math.floor(rawValue / step) * step;
|
|
23
23
|
var ceiledValue = Math.ceil(rawValue / step) * step + step;
|
|
24
24
|
var value = ceiledValue - rawValue < step / 2 ? flooredValue : ceiledValue;
|
|
25
|
-
var fractionDigits = ((
|
|
25
|
+
var fractionDigits = ((_c = (_b = "".concat(step).split('.')) === null || _b === void 0 ? void 0 : _b[1]) === null || _c === void 0 ? void 0 : _c.length) || 0;
|
|
26
26
|
var fixedValue = (value + min - step).toFixed(fractionDigits);
|
|
27
27
|
return Number(fixedValue);
|
|
28
28
|
};
|
|
@@ -6,7 +6,7 @@ var getClassNames = function (props) {
|
|
|
6
6
|
for (var _i = 0, _a = Object.entries(props); _i < _a.length; _i++) {
|
|
7
7
|
var _b = _a[_i], key = _b[0], value = _b[1];
|
|
8
8
|
if (typeof value === 'number') {
|
|
9
|
-
var cssClassName = key
|
|
9
|
+
var cssClassName = "".concat(key, "_").concat(value);
|
|
10
10
|
var className = cssClasses[cssClassName];
|
|
11
11
|
if (className) {
|
|
12
12
|
classes.push(className);
|
|
@@ -16,7 +16,7 @@ var getClassNames = function (props) {
|
|
|
16
16
|
return classes.join(' ');
|
|
17
17
|
};
|
|
18
18
|
var Spacing = function (props) {
|
|
19
|
-
return React.createElement(""
|
|
19
|
+
return React.createElement("".concat(props.as), {
|
|
20
20
|
className: getClassNames(props),
|
|
21
21
|
}, props.children);
|
|
22
22
|
};
|
|
@@ -10,8 +10,8 @@ var cellClassName = function (_a) {
|
|
|
10
10
|
highlight && 'cell_highlight',
|
|
11
11
|
sticky && 'cell_sticky',
|
|
12
12
|
header && 'cell_header',
|
|
13
|
-
color && "cell_"
|
|
14
|
-
size && "cell_"
|
|
13
|
+
color && "cell_".concat(color),
|
|
14
|
+
size && "cell_".concat(size),
|
|
15
15
|
], cssClasses);
|
|
16
16
|
};
|
|
17
17
|
var Cell = function (_a) {
|
|
@@ -7,11 +7,11 @@ var DataTable = function (_a) {
|
|
|
7
7
|
return (React.createElement(Table, null,
|
|
8
8
|
React.createElement(Table.THead, null, columns.map(function (_a) {
|
|
9
9
|
var name = _a.name, header = _a.header;
|
|
10
|
-
return (React.createElement("th", { key: "headers-header-"
|
|
10
|
+
return (React.createElement("th", { key: "headers-header-".concat(name) }, header));
|
|
11
11
|
})),
|
|
12
|
-
React.createElement(Table.TBody, null, data.map(function (item, rowIndex) { return (React.createElement(Table.Row, { key: "table-tr-"
|
|
12
|
+
React.createElement(Table.TBody, null, data.map(function (item, rowIndex) { return (React.createElement(Table.Row, { key: "table-tr-".concat(rowIndex) }, columns.map(function (_a, colIndex) {
|
|
13
13
|
var name = _a.name, CustomCell = _a.CustomCell, modifiers = _a.modifiers, header = _a.header;
|
|
14
|
-
return (React.createElement(Table.Cell, __assign({ key: "table-tr-"
|
|
14
|
+
return (React.createElement(Table.Cell, __assign({ key: "table-tr-".concat(rowIndex, "-td-").concat(colIndex) }, modifiers), CustomCell ? (React.createElement(CustomCell, { item: item, column: {
|
|
15
15
|
name: name,
|
|
16
16
|
CustomCell: CustomCell,
|
|
17
17
|
modifiers: modifiers,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var tag = 'tag';
|
|
2
|
-
var tagRemove = tag
|
|
2
|
+
var tagRemove = "".concat(tag, "__remove");
|
|
3
3
|
var icon = 'icon';
|
|
4
|
-
var iconClose = icon
|
|
4
|
+
var iconClose = "".concat(icon, "-close");
|
|
5
5
|
|
|
6
6
|
export { icon, iconClose, tag, tagRemove };
|
|
7
7
|
//# sourceMappingURL=css_classes.js.map
|
|
@@ -16,9 +16,9 @@ var Tag = function (_a) {
|
|
|
16
16
|
* Function called on whole tag component click event
|
|
17
17
|
*/
|
|
18
18
|
onClick = _a.onClick;
|
|
19
|
-
return (React.createElement("span", { className: ""
|
|
19
|
+
return (React.createElement("span", { className: "".concat(cssClasses[tag]), onClick: function () { return onClick === null || onClick === void 0 ? void 0 : onClick(label); } },
|
|
20
20
|
label,
|
|
21
|
-
hasCloseIcon && React.createElement("span", { className: cssClasses[tagRemove]
|
|
21
|
+
hasCloseIcon && React.createElement("span", { className: "".concat(cssClasses[tagRemove], " ").concat(cssClasses[icon], " ").concat(cssClasses[iconClose]) })));
|
|
22
22
|
};
|
|
23
23
|
|
|
24
24
|
export default Tag;
|
|
@@ -12,8 +12,8 @@ var TagsList = function (_a) {
|
|
|
12
12
|
* Function called on tag click which passes tag value
|
|
13
13
|
*/
|
|
14
14
|
onClick = _a.onClick;
|
|
15
|
-
return (React.createElement("ul", { className: ""
|
|
16
|
-
React.createElement("div", { className: ""
|
|
15
|
+
return (React.createElement("ul", { className: "".concat(cssClasses[tagsList]) }, value === null || value === void 0 ? void 0 : value.map(function (_tag, index) { return (React.createElement("li", { key: index, onClick: function () { return onClick(_tag); } },
|
|
16
|
+
React.createElement("div", { className: "".concat(cssClasses[tagsListItem]) },
|
|
17
17
|
React.createElement("label", null, _tag)))); })));
|
|
18
18
|
};
|
|
19
19
|
|
|
@@ -4,7 +4,7 @@ import cssClasses from '../../../css/tag/main.module.less.js';
|
|
|
4
4
|
|
|
5
5
|
var TagsSearch = function (_a) {
|
|
6
6
|
var children = _a.children;
|
|
7
|
-
return React.createElement("div", { className: ""
|
|
7
|
+
return React.createElement("div", { className: "".concat(cssClasses[tagsSearch]) }, children);
|
|
8
8
|
};
|
|
9
9
|
|
|
10
10
|
export default TagsSearch;
|
|
@@ -4,7 +4,7 @@ import cssClasses from '../../../css/tag/main.module.less.js';
|
|
|
4
4
|
|
|
5
5
|
var TagsWrapper = function (_a) {
|
|
6
6
|
var children = _a.children;
|
|
7
|
-
return React.createElement("div", { className: ""
|
|
7
|
+
return React.createElement("div", { className: "".concat(cssClasses[tagsSelectedTags]) }, children);
|
|
8
8
|
};
|
|
9
9
|
|
|
10
10
|
export default TagsWrapper;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
var tags = 'tags';
|
|
2
|
-
var tagsSelectedTags = tags
|
|
3
|
-
var tagsSearch = tags
|
|
4
|
-
var tagsList = tags
|
|
5
|
-
var tagsListItem = tags
|
|
2
|
+
var tagsSelectedTags = "".concat(tags, "__selected");
|
|
3
|
+
var tagsSearch = "".concat(tags, "__search");
|
|
4
|
+
var tagsList = "".concat(tags, "__list");
|
|
5
|
+
var tagsListItem = "".concat(tags, "__list-item");
|
|
6
6
|
|
|
7
7
|
export { tags, tagsList, tagsListItem, tagsSearch, tagsSelectedTags };
|
|
8
8
|
//# sourceMappingURL=css_classes.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { useState, useRef, useEffect } from 'react';
|
|
2
2
|
import { useTranslation } from '../../../../../external/react-i18next/dist/es/useTranslation.js';
|
|
3
|
-
import {
|
|
3
|
+
import { __spreadArray } from '../../../../../_virtual/_tslib.js';
|
|
4
4
|
import Button from '../button/index.js';
|
|
5
5
|
import Control from '../controls/index.js';
|
|
6
6
|
import { tags } from './css_classes.js';
|
|
@@ -59,7 +59,7 @@ var TagsSelector = function (_a) {
|
|
|
59
59
|
var addTag = function () {
|
|
60
60
|
var _a;
|
|
61
61
|
if (!tagsArray.includes(inputValue) && inputValue.length >= (minTagLength !== null && minTagLength !== void 0 ? minTagLength : 0) && inputValue.length > 0) {
|
|
62
|
-
setTagsArray(function (_tags) { return
|
|
62
|
+
setTagsArray(function (_tags) { return __spreadArray(__spreadArray([], _tags, true), [inputValue], false); });
|
|
63
63
|
var event_1 = new CustomEvent('tagsSelector:change', {
|
|
64
64
|
detail: {
|
|
65
65
|
changedTag: inputValue,
|
|
@@ -81,7 +81,7 @@ var TagsSelector = function (_a) {
|
|
|
81
81
|
});
|
|
82
82
|
(_a = tagsSelectorRef.current) === null || _a === void 0 ? void 0 : _a.dispatchEvent(event);
|
|
83
83
|
};
|
|
84
|
-
return (React.createElement("div", { id: id, className: ""
|
|
84
|
+
return (React.createElement("div", { id: id, className: "".concat(cssClasses[tags]), ref: tagsSelectorRef },
|
|
85
85
|
tagsArray.length > 0 && (React.createElement(TagsWrapper, null, tagsArray.map(function (_tag, index) { return (React.createElement(Tag, { key: index, label: _tag, onClick: function () { return removeTag(_tag); }, hasCloseIcon: true })); }))),
|
|
86
86
|
React.createElement(TagsSearch, null,
|
|
87
87
|
React.createElement(Control.Content, null,
|
|
@@ -11,4 +11,4 @@ import { RefObject } from 'react';
|
|
|
11
11
|
* @param ref reference to element that should have event listener when its focused, if is undefined then event
|
|
12
12
|
* listeners will be added to document object
|
|
13
13
|
*/
|
|
14
|
-
export declare const useKeyDown: (keys: string
|
|
14
|
+
export declare const useKeyDown: (keys: Array<string>, cb?: (() => void) | undefined, ref?: RefObject<HTMLElement> | undefined) => void;
|
|
@@ -25,7 +25,7 @@ var useKeyDown = function (keys, cb, ref) {
|
|
|
25
25
|
var parts = sequence.split('+');
|
|
26
26
|
var key = parts.pop();
|
|
27
27
|
var modifiers = parts;
|
|
28
|
-
if (modifiers.every(function (modifier) { return evt[modifier
|
|
28
|
+
if (modifiers.every(function (modifier) { return evt["".concat(modifier, "Key")] === true; }) && key && checkKeyMatch(evt.key, key)) {
|
|
29
29
|
cb();
|
|
30
30
|
}
|
|
31
31
|
return;
|
|
@@ -10,7 +10,7 @@ var ColorConverter = /** @class */ (function () {
|
|
|
10
10
|
};
|
|
11
11
|
ColorConverter.hsl2hex = function (_a) {
|
|
12
12
|
var hue = _a.hue, saturation = _a.saturation, lightness = _a.lightness;
|
|
13
|
-
return "#"
|
|
13
|
+
return "#".concat(colorConvert.hsl.hex([hue, saturation, lightness]));
|
|
14
14
|
};
|
|
15
15
|
return ColorConverter;
|
|
16
16
|
}());
|
|
@@ -5,6 +5,6 @@ export declare const registerOnMouseEvents: (listener: (event: IPosition) => voi
|
|
|
5
5
|
*
|
|
6
6
|
* @param e, TouchEvent which us mapped to MouseEvent
|
|
7
7
|
*/
|
|
8
|
-
export declare const mapMouseEventToPosition: (e:
|
|
9
|
-
export declare const mapTouchEventToPosition: (e: React.TouchEvent
|
|
8
|
+
export declare const mapMouseEventToPosition: (e: React.MouseEvent<HTMLElement, MouseEvent> | MouseEvent) => IPosition;
|
|
9
|
+
export declare const mapTouchEventToPosition: (e: React.TouchEvent | TouchEvent) => IPosition;
|
|
10
10
|
export declare const registerOnTouchEvents: (listener: (event: IPosition) => void) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __spreadArray } from '../../../../../_virtual/_tslib.js';
|
|
2
2
|
import union_1 from '../../../../../external/lodash/union.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
@@ -62,7 +62,7 @@ function fuzzySearch(searchQuery, arrayToFilter, key) {
|
|
|
62
62
|
return union_1(exact_1, first_1, loose_1, fuzzy_1);
|
|
63
63
|
}
|
|
64
64
|
else {
|
|
65
|
-
return
|
|
65
|
+
return __spreadArray([], arrayToFilter, true);
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
68
|
|
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
*
|
|
6
6
|
* @param cssClasses, object of less classNames taken
|
|
7
7
|
*/
|
|
8
|
-
export declare const classNames: (classList:
|
|
8
|
+
export declare const classNames: (classList: Array<string | null | undefined | false>, cssClasses: Object) => string;
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@dreamcommerce/aurora",
|
|
3
3
|
"packageManager": "yarn@3.1.1",
|
|
4
4
|
"sideEffects": false,
|
|
5
|
-
"version": "0.3.4-
|
|
5
|
+
"version": "0.3.4-167",
|
|
6
6
|
"description": "aurora",
|
|
7
7
|
"author": "k0ssak",
|
|
8
8
|
"license": "MIT",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"react-transition-group": "4.3.0"
|
|
35
35
|
},
|
|
36
36
|
"scripts": {
|
|
37
|
-
"prepublishOnly": "
|
|
37
|
+
"prepublishOnly": "yarn run tests:unit",
|
|
38
38
|
"build": "rimraf ./build/ && tsc -p . && rollup -c",
|
|
39
39
|
"start": "rollup -c -w",
|
|
40
40
|
"storybook": "start-storybook -p 6006",
|
|
@@ -50,5 +50,5 @@
|
|
|
50
50
|
"update-visuals": "jest -c .config/jest/jest.config.visual.js --updateSnapshot",
|
|
51
51
|
"clear-install": "rm -rf node_modules && rm package-lock.json && npm install"
|
|
52
52
|
},
|
|
53
|
-
"stableVersion": "0.3.4-
|
|
53
|
+
"stableVersion": "0.3.4-166"
|
|
54
54
|
}
|