@expressms/smartapp-ui 2.9.14 → 3.0.0-alpha.1
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/main/assets/icons/arrow-down.svg +2 -2
- package/build/main/assets/icons/arrow-up.svg +2 -2
- package/build/main/assets/icons/attachment-loader.svg +2 -2
- package/build/main/assets/icons/avatar-arrow-down.svg +3 -0
- package/build/main/assets/icons/avatar-arrow-up.svg +3 -0
- package/build/main/assets/icons/{loader-medium.svg → avatar-loader.svg} +1 -1
- package/build/main/assets/icons/button-loader.svg +2 -2
- package/build/main/assets/icons/check-mark-square.svg +4 -0
- package/build/main/assets/icons/check-mark.svg +3 -3
- package/build/main/assets/icons/chip-info.svg +3 -1
- package/build/main/assets/icons/clear.svg +2 -2
- package/build/main/assets/icons/close-modal.svg +3 -0
- package/build/main/assets/icons/close.svg +2 -9
- package/build/main/assets/icons/contact-info.svg +3 -10
- package/build/main/assets/icons/corporate-user.svg +2 -9
- package/build/main/assets/icons/delete-chip.svg +2 -2
- package/build/main/assets/icons/doc-small.svg +11 -0
- package/build/main/assets/icons/doc.svg +11 -0
- package/build/main/assets/icons/eye-off.svg +4 -9
- package/build/main/assets/icons/eye-on.svg +4 -0
- package/build/main/assets/icons/file-small.svg +11 -0
- package/build/main/assets/icons/file.svg +10 -2
- package/build/main/assets/icons/global-address-book-user.svg +3 -9
- package/build/main/assets/icons/indeterminate-check-mark-square.svg +4 -0
- package/build/main/assets/icons/input-arrow-down.svg +3 -0
- package/build/main/assets/icons/input-arrow-up.svg +3 -0
- package/build/main/assets/icons/magnifying-glass.svg +2 -2
- package/build/main/assets/icons/notification-close.svg +1 -1
- package/build/main/assets/icons/notification-failure.svg +2 -2
- package/build/main/assets/icons/notification-info.svg +4 -4
- package/build/main/assets/icons/notification-success.svg +3 -3
- package/build/main/assets/icons/pdf-small.svg +11 -0
- package/build/main/assets/icons/pdf.svg +11 -0
- package/build/main/assets/icons/play-small.svg +3 -0
- package/build/main/assets/icons/play.svg +3 -0
- package/build/main/assets/icons/ppt-small.svg +11 -0
- package/build/main/assets/icons/ppt.svg +11 -0
- package/build/main/assets/icons/txt-small.svg +11 -0
- package/build/main/assets/icons/txt.svg +11 -0
- package/build/main/assets/icons/warning-avatar.svg +1 -1
- package/build/main/assets/icons/xls-small.svg +11 -0
- package/build/main/assets/icons/xls.svg +11 -0
- package/build/main/assets/storybook/index.d.ts +2 -1
- package/build/main/assets/storybook/index.js +2 -1
- package/build/main/assets/storybook/index.js.map +1 -1
- package/build/main/constants/constants.d.ts +43 -24
- package/build/main/constants/constants.js +41 -23
- package/build/main/constants/constants.js.map +1 -1
- package/build/main/constants/types.d.ts +26 -0
- package/build/main/helpers/index.d.ts +10 -7
- package/build/main/helpers/index.js +65 -13
- package/build/main/helpers/index.js.map +1 -1
- package/build/main/hooks/useModal.d.ts +2 -1
- package/build/main/hooks/useModal.js +5 -8
- package/build/main/hooks/useModal.js.map +1 -1
- package/build/main/styles/styles.scss +2 -2
- package/build/main//321/201omponents/ActionModal/ActionModal.d.ts +1 -1
- package/build/main//321/201omponents/ActionModal/ActionModal.js +13 -15
- package/build/main//321/201omponents/ActionModal/ActionModal.js.map +1 -1
- package/build/main//321/201omponents/ActionModal/types.d.ts +2 -3
- package/build/main//321/201omponents/AttachedFile/AttachedFile.d.ts +1 -1
- package/build/main//321/201omponents/AttachedFile/AttachedFile.js +69 -33
- package/build/main//321/201omponents/AttachedFile/AttachedFile.js.map +1 -1
- package/build/main//321/201omponents/AttachedFile/types.d.ts +3 -7
- package/build/main//321/201omponents/Avatar/Avatar.d.ts +1 -1
- package/build/main//321/201omponents/Avatar/Avatar.js +24 -25
- package/build/main//321/201omponents/Avatar/Avatar.js.map +1 -1
- package/build/main//321/201omponents/Avatar/types.d.ts +4 -4
- package/build/main//321/201omponents/Button/Button.d.ts +1 -1
- package/build/main//321/201omponents/Button/Button.js +13 -19
- package/build/main//321/201omponents/Button/Button.js.map +1 -1
- package/build/main//321/201omponents/Button/types.d.ts +6 -10
- package/build/main//321/201omponents/Button/types.js +1 -0
- package/build/main//321/201omponents/Button/types.js.map +1 -1
- package/build/main//321/201omponents/Calendar/Calendar.d.ts +1 -1
- package/build/main//321/201omponents/Calendar/Calendar.js +13 -12
- package/build/main//321/201omponents/Calendar/Calendar.js.map +1 -1
- package/build/main//321/201omponents/Calendar/types.d.ts +2 -1
- package/build/main//321/201omponents/Charts/ChartBar/ChartBar.d.ts +1 -1
- package/build/main//321/201omponents/Charts/ChartBar/ChartBar.js +8 -7
- package/build/main//321/201omponents/Charts/ChartBar/ChartBar.js.map +1 -1
- package/build/main//321/201omponents/Charts/ChartLine/ChartLine.d.ts +1 -1
- package/build/main//321/201omponents/Charts/ChartLine/ChartLine.js +8 -7
- package/build/main//321/201omponents/Charts/ChartLine/ChartLine.js.map +1 -1
- package/build/main//321/201omponents/Charts/ChartPie/ChartPie.d.ts +1 -1
- package/build/main//321/201omponents/Charts/ChartPie/ChartPie.js +9 -8
- package/build/main//321/201omponents/Charts/ChartPie/ChartPie.js.map +1 -1
- package/build/main//321/201omponents/Charts/constants.d.ts +0 -4
- package/build/main//321/201omponents/Charts/constants.js +1 -2
- package/build/main//321/201omponents/Charts/constants.js.map +1 -1
- package/build/main//321/201omponents/Charts/helpers.d.ts +2 -2
- package/build/main//321/201omponents/Charts/helpers.js +1 -1
- package/build/main//321/201omponents/Charts/helpers.js.map +1 -1
- package/build/main//321/201omponents/Charts/types.d.ts +3 -2
- package/build/main//321/201omponents/Charts/usePieEvents.js +1 -1
- package/build/main//321/201omponents/Charts/usePieEvents.js.map +1 -1
- package/build/main//321/201omponents/Checkbox/Checkbox.d.ts +5 -1
- package/build/main//321/201omponents/Checkbox/Checkbox.js +24 -14
- package/build/main//321/201omponents/Checkbox/Checkbox.js.map +1 -1
- package/build/main//321/201omponents/Checkbox/types.d.ts +2 -0
- package/build/main//321/201omponents/Chip/Chip.d.ts +1 -1
- package/build/main//321/201omponents/Chip/Chip.js +52 -25
- package/build/main//321/201omponents/Chip/Chip.js.map +1 -1
- package/build/main//321/201omponents/Chip/types.d.ts +3 -2
- package/build/main//321/201omponents/ConfirmationModal/ConfirmationModal.d.ts +1 -1
- package/build/main//321/201omponents/ConfirmationModal/ConfirmationModal.js +19 -26
- package/build/main//321/201omponents/ConfirmationModal/ConfirmationModal.js.map +1 -1
- package/build/main//321/201omponents/ConfirmationModal/types.d.ts +2 -2
- package/build/main//321/201omponents/ContextMenu/ContextMenu.d.ts +1 -1
- package/build/main//321/201omponents/ContextMenu/ContextMenu.js +3 -3
- package/build/main//321/201omponents/ContextMenu/ContextMenu.js.map +1 -1
- package/build/main//321/201omponents/ContextMenu/types.d.ts +2 -2
- package/build/main//321/201omponents/CustomSelect/CustomSelect.d.ts +1 -1
- package/build/main//321/201omponents/CustomSelect/CustomSelect.js +25 -21
- package/build/main//321/201omponents/CustomSelect/CustomSelect.js.map +1 -1
- package/build/main//321/201omponents/CustomSelect/selectStyles.d.ts +2 -2
- package/build/main//321/201omponents/CustomSelect/selectStyles.js +21 -18
- package/build/main//321/201omponents/CustomSelect/selectStyles.js.map +1 -1
- package/build/main//321/201omponents/CustomSelect/types.d.ts +3 -4
- package/build/main//321/201omponents/CustomSelectProfiles/CustomSelectProfiles.js.map +1 -1
- package/build/main//321/201omponents/DragAndDrop/DragAndDrop.js +3 -3
- package/build/main//321/201omponents/DragAndDrop/DragAndDrop.js.map +1 -1
- package/build/main//321/201omponents/DraggablePopup/DraggablePopup.d.ts +1 -1
- package/build/main//321/201omponents/DraggablePopup/DraggablePopup.js +5 -5
- package/build/main//321/201omponents/DraggablePopup/DraggablePopup.js.map +1 -1
- package/build/main//321/201omponents/DraggablePopup/types.d.ts +2 -2
- package/build/main//321/201omponents/Error/Error.d.ts +1 -1
- package/build/main//321/201omponents/Error/Error.js +3 -3
- package/build/main//321/201omponents/Error/Error.js.map +1 -1
- package/build/main//321/201omponents/Error/types.d.ts +2 -2
- package/build/main//321/201omponents/Flex/Flex.js.map +1 -1
- package/build/main//321/201omponents/Flex/HFlex/HFlex.d.ts +1 -1
- package/build/main//321/201omponents/Flex/HFlex/HFlex.js.map +1 -1
- package/build/main//321/201omponents/Flex/VFlex/VFlex.d.ts +1 -1
- package/build/main//321/201omponents/Header/Header.d.ts +1 -1
- package/build/main//321/201omponents/Header/Header.js +4 -4
- package/build/main//321/201omponents/Header/Header.js.map +1 -1
- package/build/main//321/201omponents/Header/types.d.ts +2 -2
- package/build/main//321/201omponents/Input/Input.d.ts +1 -1
- package/build/main//321/201omponents/Input/Input.js +68 -92
- package/build/main//321/201omponents/Input/Input.js.map +1 -1
- package/build/main//321/201omponents/Input/types.d.ts +6 -8
- package/build/main//321/201omponents/ListItem/ListItem.js +4 -4
- package/build/main//321/201omponents/ListItem/ListItem.js.map +1 -1
- package/build/main//321/201omponents/ListItem/types.d.ts +2 -2
- package/build/main//321/201omponents/Loader/Loader.d.ts +1 -1
- package/build/main//321/201omponents/Loader/Loader.js +3 -3
- package/build/main//321/201omponents/Loader/Loader.js.map +1 -1
- package/build/main//321/201omponents/Loader/types.d.ts +2 -2
- package/build/main//321/201omponents/Modal/Modal.d.ts +1 -1
- package/build/main//321/201omponents/Modal/Modal.js +59 -43
- package/build/main//321/201omponents/Modal/Modal.js.map +1 -1
- package/build/main//321/201omponents/Modal/types.d.ts +6 -7
- package/build/main//321/201omponents/Notification/Notification.d.ts +1 -1
- package/build/main//321/201omponents/Notification/Notification.js +52 -64
- package/build/main//321/201omponents/Notification/Notification.js.map +1 -1
- package/build/main//321/201omponents/Notification/types.d.ts +3 -4
- package/build/main//321/201omponents/Profile/Profile.js +2 -2
- package/build/main//321/201omponents/Profile/Profile.js.map +1 -1
- package/build/main//321/201omponents/ProgressBar/ProgressBar.d.ts +1 -1
- package/build/main//321/201omponents/ProgressBar/ProgressBar.js +3 -3
- package/build/main//321/201omponents/ProgressBar/ProgressBar.js.map +1 -1
- package/build/main//321/201omponents/ProgressBar/types.d.ts +2 -2
- package/build/main//321/201omponents/RadioButton/RadioButton.js +9 -13
- package/build/main//321/201omponents/RadioButton/RadioButton.js.map +1 -1
- package/build/main//321/201omponents/ScrollBar/ScrollBar.js +2 -2
- package/build/main//321/201omponents/ScrollBar/ScrollBar.js.map +1 -1
- package/build/main//321/201omponents/Skeleton/Skeleton.js.map +1 -1
- package/build/main//321/201omponents/Skeleton/types.d.ts +2 -2
- package/build/main//321/201omponents/Stories/Stories.js +15 -15
- package/build/main//321/201omponents/Stories/Stories.js.map +1 -1
- package/build/main//321/201omponents/Stories/types.d.ts +2 -3
- package/build/main//321/201omponents/Switcher/Switcher.js +1 -1
- package/build/main//321/201omponents/Switcher/Switcher.js.map +1 -1
- package/build/main//321/201omponents/SyncLoader/SyncLoader.js +4 -4
- package/build/main//321/201omponents/SyncLoader/SyncLoader.js.map +1 -1
- package/build/main//321/201omponents/SyncLoader/types.d.ts +2 -3
- package/build/main//321/201omponents/Textarea/Textarea.d.ts +1 -1
- package/build/main//321/201omponents/Textarea/Textarea.js +8 -48
- package/build/main//321/201omponents/Textarea/Textarea.js.map +1 -1
- package/build/main//321/201omponents/Textarea/types.d.ts +2 -4
- package/build/main//321/201omponents/Toggle/Toggle.js +11 -14
- package/build/main//321/201omponents/Toggle/Toggle.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/ContactBottomSheet/ContactBottomSheet.d.ts +1 -1
- package/build/main//321/201omponents/UserDropdown/ContactBottomSheet/ContactBottomSheet.js +5 -6
- package/build/main//321/201omponents/UserDropdown/ContactBottomSheet/ContactBottomSheet.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/MenuList/MenuList.js +5 -7
- package/build/main//321/201omponents/UserDropdown/MenuList/MenuList.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/MultiValueLabel/MultiValueLabel.js +8 -14
- package/build/main//321/201omponents/UserDropdown/MultiValueLabel/MultiValueLabel.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/Option/Option.js +6 -10
- package/build/main//321/201omponents/UserDropdown/Option/Option.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/SearchInCatalogButton/SearchInCatalogButton.js +2 -2
- package/build/main//321/201omponents/UserDropdown/UserDropdown.d.ts +1 -1
- package/build/main//321/201omponents/UserDropdown/UserDropdown.js +33 -48
- package/build/main//321/201omponents/UserDropdown/UserDropdown.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/helpers.js +1 -4
- package/build/main//321/201omponents/UserDropdown/helpers.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/selectStyles.d.ts +1 -1
- package/build/main//321/201omponents/UserDropdown/selectStyles.js +20 -36
- package/build/main//321/201omponents/UserDropdown/selectStyles.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/types.d.ts +7 -4
- package/build/main//321/201omponents/UserDropdown/types.js.map +1 -1
- package/package.json +1 -1
- package/build/main/assets/icons/cancel-cross.svg +0 -3
- package/build/main/assets/icons/download.svg +0 -4
- package/build/main/assets/icons/eye.svg +0 -10
- package/build/main/assets/icons/notification-error.svg +0 -3
- package/build/main/assets/icons/notification-warning.svg +0 -5
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactElement } from 'react';
|
|
2
|
-
import { IPlatformProps, TStyles } from '../../constants';
|
|
2
|
+
import { IFontFamilyProps, IPlatformProps, TStyles } from '../../constants';
|
|
3
3
|
import { IAvatarProps } from '../Avatar/types';
|
|
4
4
|
import { IntRange } from '../types';
|
|
5
5
|
export type TTitleIcon = {
|
|
@@ -23,7 +23,7 @@ export interface IHeaderIconProps {
|
|
|
23
23
|
icon: ReactElement;
|
|
24
24
|
onClick?: () => void;
|
|
25
25
|
}
|
|
26
|
-
export interface IHeaderProps extends IPlatformProps {
|
|
26
|
+
export interface IHeaderProps extends IPlatformProps, IFontFamilyProps {
|
|
27
27
|
title?: string;
|
|
28
28
|
counter?: number;
|
|
29
29
|
isBack?: boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { IInputProps } from './types';
|
|
2
2
|
import '../../styles/styles.scss';
|
|
3
|
-
declare const Input: ({ isPassword, isClearable, isSearchable, disabled, title, mask,
|
|
3
|
+
declare const Input: ({ fontFamily, isPassword, isClearable, isSearchable, disabled, disableErrorBorder, title, mask, hint, error, inlineLabel, type, fieldType, outerRef, additionalInputParams, width, iconColor, containerClassName, className, containerStyles, style, onChange, onFocus, onBlur, onEnterPress, onClearClick, ...props }: IInputProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
4
|
export default Input;
|
|
@@ -21,61 +21,53 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
21
21
|
return t;
|
|
22
22
|
};
|
|
23
23
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
24
|
-
import { useRef, useState
|
|
24
|
+
import { useEffect, useRef, useState } from 'react';
|
|
25
25
|
import classNames from 'classnames';
|
|
26
|
-
import { isEmpty
|
|
27
|
-
import { generateColor,
|
|
28
|
-
import { ADDITIONAL_INPUT_PR, ADDITIONAL_MAX_CHARACTERS, DEFAULT_INPUT_PADDING, ENTER_KEY,
|
|
29
|
-
import { ReactComponent as EyeIcon } from '../../assets/icons/eye.svg';
|
|
30
|
-
import { ReactComponent as EyeOffIcon } from '../../assets/icons/eye-off.svg';
|
|
26
|
+
import { isEmpty } from 'lodash';
|
|
27
|
+
import { generateColor, generateFontFamilyStyle } from '../../helpers';
|
|
28
|
+
import { ADDITIONAL_INPUT_PR, ADDITIONAL_MAX_CHARACTERS, DEFAULT_INPUT_PADDING, ENTER_KEY, EVENT_LISTENER_TYPES, INPUT_FIELD_TYPE, INPUT_TYPE_NUMBER, INPUT_TYPE_PASSWORD, INPUT_TYPE_TEXT, MASK_INPUT_PL, } from '../../constants';
|
|
31
29
|
import { ReactComponent as ClearIcon } from '../../assets/icons/clear.svg';
|
|
30
|
+
import { ReactComponent as EyeOffIcon } from '../../assets/icons/eye-off.svg';
|
|
31
|
+
import { ReactComponent as EyeOnIcon } from '../../assets/icons/eye-on.svg';
|
|
32
|
+
import { ReactComponent as InputArrowDownIcon } from '../../assets/icons/input-arrow-down.svg';
|
|
33
|
+
import { ReactComponent as InputArrowUpIcon } from '../../assets/icons/input-arrow-up.svg';
|
|
32
34
|
import { ReactComponent as MagnifyingGlassIcon } from '../../assets/icons/magnifying-glass.svg';
|
|
33
35
|
import '../../styles/styles.scss';
|
|
34
36
|
var Input = function (_a) {
|
|
35
|
-
var _b = _a.isPassword, isPassword = _b === void 0 ? false : _b, _c = _a.isClearable, isClearable = _c === void 0 ? false : _c, _d = _a.isSearchable, isSearchable = _d === void 0 ? false : _d, _e = _a.disabled, disabled = _e === void 0 ? false : _e,
|
|
37
|
+
var fontFamily = _a.fontFamily, _b = _a.isPassword, isPassword = _b === void 0 ? false : _b, _c = _a.isClearable, isClearable = _c === void 0 ? false : _c, _d = _a.isSearchable, isSearchable = _d === void 0 ? false : _d, _e = _a.disabled, disabled = _e === void 0 ? false : _e, _f = _a.disableErrorBorder, disableErrorBorder = _f === void 0 ? false : _f, title = _a.title, mask = _a.mask, hint = _a.hint, error = _a.error, inlineLabel = _a.inlineLabel, type = _a.type, _g = _a.fieldType, fieldType = _g === void 0 ? INPUT_FIELD_TYPE.text : _g, outerRef = _a.outerRef, additionalInputParams = _a.additionalInputParams, _h = _a.width, width = _h === void 0 ? 100 : _h, iconColor = _a.iconColor, containerClassName = _a.containerClassName, className = _a.className, containerStyles = _a.containerStyles, style = _a.style, onChange = _a.onChange, onFocus = _a.onFocus, onBlur = _a.onBlur, onEnterPress = _a.onEnterPress, onClearClick = _a.onClearClick, props = __rest(_a, ["fontFamily", "isPassword", "isClearable", "isSearchable", "disabled", "disableErrorBorder", "title", "mask", "hint", "error", "inlineLabel", "type", "fieldType", "outerRef", "additionalInputParams", "width", "iconColor", "containerClassName", "className", "containerStyles", "style", "onChange", "onFocus", "onBlur", "onEnterPress", "onClearClick"]);
|
|
36
38
|
var localRef = useRef(null);
|
|
37
39
|
var maskRef = useRef(null);
|
|
40
|
+
var inlineLabelRef = useRef(null);
|
|
38
41
|
var additionalInputRef = useRef(null);
|
|
39
42
|
var hiddenSpanRef = useRef(null);
|
|
40
43
|
var inputRef = outerRef || localRef;
|
|
41
|
-
var
|
|
42
|
-
var
|
|
43
|
-
var
|
|
44
|
-
var
|
|
45
|
-
var _q = useState(0), additionalWidth = _q[0], setAdditionalWidth = _q[1];
|
|
46
|
-
var _r = useState(0), minAdditionalWidth = _r[0], setMinAdditionalWidth = _r[1];
|
|
47
|
-
var _s = useState(false), isClearableIconVisible = _s[0], setIsClearableIconVisible = _s[1];
|
|
44
|
+
var _j = useState(false), isPasswordShown = _j[0], setIsPasswordShown = _j[1];
|
|
45
|
+
var _k = useState(0), additionalWidth = _k[0], setAdditionalWidth = _k[1];
|
|
46
|
+
var _l = useState(0), minAdditionalWidth = _l[0], setMinAdditionalWidth = _l[1];
|
|
47
|
+
var _m = useState(false), isClearableIconVisible = _m[0], setIsClearableIconVisible = _m[1];
|
|
48
48
|
var iconStyles = { color: generateColor(iconColor) };
|
|
49
|
-
var
|
|
49
|
+
var isClearIconVisible = isClearable && isClearableIconVisible;
|
|
50
|
+
var _o = additionalInputParams || {}, additionalClassName = _o.className, additionalPlaceholder = _o.placeholder, additionalDefaultValue = _o.defaultValue, onAdditionalChange = _o.onChange, additionalInputProps = __rest(_o, ["className", "placeholder", "defaultValue", "onChange"]);
|
|
50
51
|
useEffect(function () {
|
|
51
52
|
var inputElement = inputRef.current;
|
|
52
53
|
var setScrollLeftAsLeftByUser = function (event) {
|
|
53
54
|
var scrollLeft = event.target.scrollLeft;
|
|
54
|
-
setTimeout(function () {
|
|
55
|
-
event.target.scrollLeft = scrollLeft;
|
|
56
|
-
}, 0);
|
|
57
|
-
};
|
|
58
|
-
inputElement === null || inputElement === void 0 ? void 0 : inputElement.addEventListener('blur', setScrollLeftAsLeftByUser);
|
|
59
|
-
return function () {
|
|
60
|
-
inputElement === null || inputElement === void 0 ? void 0 : inputElement.removeEventListener('blur', setScrollLeftAsLeftByUser);
|
|
55
|
+
setTimeout(function () { return (event.target.scrollLeft = scrollLeft); }, 0);
|
|
61
56
|
};
|
|
57
|
+
inputElement === null || inputElement === void 0 ? void 0 : inputElement.addEventListener(EVENT_LISTENER_TYPES.blur, setScrollLeftAsLeftByUser);
|
|
58
|
+
return function () { return inputElement === null || inputElement === void 0 ? void 0 : inputElement.removeEventListener(EVENT_LISTENER_TYPES.blur, setScrollLeftAsLeftByUser); };
|
|
62
59
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
63
60
|
}, []);
|
|
64
61
|
useEffect(function () {
|
|
65
62
|
var inputElement = inputRef.current;
|
|
66
|
-
|
|
67
|
-
|
|
63
|
+
var textLength = inputElement === null || inputElement === void 0 ? void 0 : inputElement.value.length;
|
|
64
|
+
if (inputElement && textLength) {
|
|
68
65
|
inputElement.selectionStart = textLength;
|
|
69
66
|
inputElement.selectionEnd = textLength;
|
|
70
67
|
inputElement.focus();
|
|
71
68
|
}
|
|
72
69
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
73
70
|
}, [isPasswordShown]);
|
|
74
|
-
useEffect(function () {
|
|
75
|
-
if (!remainingCharacters) {
|
|
76
|
-
handleSetTimeoutForCounter();
|
|
77
|
-
}
|
|
78
|
-
}, [remainingCharacters]);
|
|
79
71
|
useEffect(function () {
|
|
80
72
|
var hiddenSpanRefCurrent = hiddenSpanRef.current;
|
|
81
73
|
if (hiddenSpanRefCurrent && additionalPlaceholder) {
|
|
@@ -83,125 +75,109 @@ var Input = function (_a) {
|
|
|
83
75
|
var minAdditionalWidthValue = hiddenSpanRefCurrent.getBoundingClientRect().width;
|
|
84
76
|
hiddenSpanRefCurrent.innerText = (additionalDefaultValue === null || additionalDefaultValue === void 0 ? void 0 : additionalDefaultValue.toString()) || additionalPlaceholder;
|
|
85
77
|
var additionalWidthValue = hiddenSpanRefCurrent.getBoundingClientRect().width;
|
|
86
|
-
setAdditionalWidth(additionalWidthValue
|
|
78
|
+
setAdditionalWidth(Math.max(additionalWidthValue, minAdditionalWidthValue));
|
|
87
79
|
setMinAdditionalWidth(minAdditionalWidthValue);
|
|
88
80
|
}
|
|
89
81
|
}, [additionalPlaceholder, additionalDefaultValue]);
|
|
90
82
|
var calculateInputPaddingLeft = function () {
|
|
91
|
-
var
|
|
83
|
+
var _a;
|
|
84
|
+
var maskWidth = ((_a = maskRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect().width) || null;
|
|
92
85
|
return "".concat(maskWidth ? maskWidth + MASK_INPUT_PL : DEFAULT_INPUT_PADDING, "px");
|
|
93
86
|
};
|
|
94
87
|
var calculateInputPaddingRight = function () {
|
|
95
|
-
var
|
|
96
|
-
|
|
88
|
+
var _a, _b;
|
|
89
|
+
var additionalInputWidth = ((_a = additionalInputRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect().width) || null;
|
|
90
|
+
var inlineLabelWidth = ((_b = inlineLabelRef.current) === null || _b === void 0 ? void 0 : _b.getBoundingClientRect().width) || null;
|
|
91
|
+
if (additionalInputWidth)
|
|
92
|
+
return "".concat(additionalInputWidth + ADDITIONAL_INPUT_PR, "px");
|
|
93
|
+
return inlineLabelWidth ? "".concat(inlineLabelWidth + DEFAULT_INPUT_PADDING, "px") : "".concat(DEFAULT_INPUT_PADDING, "px");
|
|
97
94
|
};
|
|
98
95
|
var generateInputType = function () {
|
|
99
|
-
if (isPassword)
|
|
96
|
+
if (isPassword)
|
|
100
97
|
return isPasswordShown ? INPUT_TYPE_TEXT : INPUT_TYPE_PASSWORD;
|
|
101
|
-
}
|
|
102
98
|
return type || INPUT_TYPE_TEXT;
|
|
103
99
|
};
|
|
104
|
-
var isTitleCounterType = function () { return counterType === INPUT_COUNTER_TYPE.title; };
|
|
105
|
-
var isTitleCounterVisible = function () { return isTitleCounterType() && !isNil(maxCharacters); };
|
|
106
|
-
var isTextCounterVisible = function () {
|
|
107
|
-
if (isNil(maxCharacters) || isTitleCounterType()) {
|
|
108
|
-
return false;
|
|
109
|
-
}
|
|
110
|
-
// 30 percent of the maximum characters
|
|
111
|
-
var charactersToCompare = (maxCharacters * 30) / 100;
|
|
112
|
-
return remainingCharacters < charactersToCompare;
|
|
113
|
-
};
|
|
114
|
-
var handleSetTimeoutForCounter = function () {
|
|
115
|
-
var id = setTimeout(function () { return setTimeoutId(null); }, INPUT_COUNTER_TIMEOUT);
|
|
116
|
-
setTimeoutId(id);
|
|
117
|
-
};
|
|
118
100
|
var handleKeyDown = function (_a) {
|
|
119
101
|
var key = _a.key;
|
|
120
|
-
|
|
121
|
-
onEnterPress();
|
|
122
|
-
}
|
|
123
|
-
if (!remainingCharacters) {
|
|
124
|
-
!isNull(timeoutId) && clearTimeout(timeoutId);
|
|
125
|
-
handleSetTimeoutForCounter();
|
|
126
|
-
}
|
|
102
|
+
return key === ENTER_KEY && (onEnterPress === null || onEnterPress === void 0 ? void 0 : onEnterPress());
|
|
127
103
|
};
|
|
128
|
-
var
|
|
104
|
+
var checkIsInputValueEmpty = function () { var _a; return isEmpty((_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.value); };
|
|
129
105
|
var handleFocus = function (e) {
|
|
130
|
-
setIsClearableIconVisible(!
|
|
131
|
-
onFocus
|
|
106
|
+
setIsClearableIconVisible(!checkIsInputValueEmpty());
|
|
107
|
+
onFocus === null || onFocus === void 0 ? void 0 : onFocus(e);
|
|
132
108
|
};
|
|
133
109
|
var handleBlur = function (e) {
|
|
134
|
-
setIsClearableIconVisible(fieldType === INPUT_FIELD_TYPE.search ? !
|
|
135
|
-
onBlur
|
|
110
|
+
setIsClearableIconVisible(fieldType === INPUT_FIELD_TYPE.search ? !checkIsInputValueEmpty() : false);
|
|
111
|
+
onBlur === null || onBlur === void 0 ? void 0 : onBlur(e);
|
|
136
112
|
};
|
|
137
113
|
var handleChange = function (_a) {
|
|
138
114
|
var value = _a.target.value;
|
|
139
115
|
var valueLength = value.length;
|
|
140
116
|
onChange(value);
|
|
141
|
-
setInputLength(valueLength);
|
|
142
117
|
setIsClearableIconVisible(!!valueLength);
|
|
143
|
-
if (maxCharacters) {
|
|
144
|
-
var remainingCharacters_1 = maxCharacters - valueLength;
|
|
145
|
-
setRemainingCharacters(remainingCharacters_1);
|
|
146
|
-
if (!!remainingCharacters_1 && !isNull(timeoutId)) {
|
|
147
|
-
clearTimeout(timeoutId);
|
|
148
|
-
setTimeoutId(null);
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
118
|
};
|
|
152
119
|
var handleAdditionalChange = function (_a) {
|
|
153
120
|
var value = _a.target.value;
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
var
|
|
159
|
-
setAdditionalWidth(
|
|
121
|
+
var hiddenSpanRefCurrent = hiddenSpanRef.current;
|
|
122
|
+
onAdditionalChange === null || onAdditionalChange === void 0 ? void 0 : onAdditionalChange(value);
|
|
123
|
+
if (hiddenSpanRefCurrent) {
|
|
124
|
+
hiddenSpanRefCurrent.innerText = value;
|
|
125
|
+
var spanWidth = hiddenSpanRefCurrent.getBoundingClientRect().width;
|
|
126
|
+
setAdditionalWidth(Math.max(spanWidth, minAdditionalWidth));
|
|
160
127
|
}
|
|
161
128
|
};
|
|
162
129
|
var handleClickButton = function () {
|
|
163
|
-
var
|
|
130
|
+
var inputRefCurrent = inputRef.current;
|
|
131
|
+
if (disabled)
|
|
132
|
+
return;
|
|
164
133
|
setIsPasswordShown(!isPasswordShown);
|
|
165
|
-
!(
|
|
134
|
+
!(inputRefCurrent === null || inputRefCurrent === void 0 ? void 0 : inputRefCurrent.value.length) && (inputRefCurrent === null || inputRefCurrent === void 0 ? void 0 : inputRefCurrent.focus());
|
|
166
135
|
};
|
|
167
136
|
var handleClearClick = function (event) {
|
|
137
|
+
var inputRefCurrent = inputRef.current;
|
|
138
|
+
if (disabled)
|
|
139
|
+
return;
|
|
168
140
|
event.preventDefault();
|
|
169
|
-
if (
|
|
170
|
-
|
|
141
|
+
if (inputRefCurrent && onClearClick) {
|
|
142
|
+
inputRefCurrent.value = '';
|
|
171
143
|
setIsClearableIconVisible(false);
|
|
172
144
|
onClearClick();
|
|
173
145
|
}
|
|
174
146
|
};
|
|
147
|
+
var handleArrowClick = function (isUpArrow) {
|
|
148
|
+
var inputRefCurrent = inputRef.current;
|
|
149
|
+
if (disabled || !inputRefCurrent)
|
|
150
|
+
return;
|
|
151
|
+
inputRefCurrent.focus();
|
|
152
|
+
isUpArrow ? inputRefCurrent.stepUp() : inputRefCurrent.stepDown();
|
|
153
|
+
};
|
|
154
|
+
var handleArrowUpClick = function () { return handleArrowClick(true); };
|
|
155
|
+
var handleArrowDownClick = function () { return handleArrowClick(); };
|
|
175
156
|
var renderInputTitle = function () {
|
|
176
|
-
return title && (
|
|
157
|
+
return title && (_jsx("div", __assign({ className: "smartapp-input__title" }, { children: _jsx("p", __assign({ className: "smartapp-input__title--text" }, { children: title })) })));
|
|
177
158
|
};
|
|
178
159
|
var renderMask = function () {
|
|
179
160
|
return mask && (_jsx("div", __assign({ ref: maskRef, className: "smartapp-input__container--mask" }, { children: mask })));
|
|
180
161
|
};
|
|
181
|
-
var renderTitleCounter = function () {
|
|
182
|
-
return isTitleCounterVisible() && (_jsx("div", __assign({ className: classNames('smartapp-input__title--counter', { 'smartapp-input__title--counter__error': !isNull(timeoutId) }) }, { children: "".concat(inputLength, "/").concat(maxCharacters) })));
|
|
183
|
-
};
|
|
184
162
|
var renderEyeIcon = function () {
|
|
185
|
-
return isPassword && (_jsx("button", __assign({ type: "button", className: "smartapp-input__container--eye-button", onClick: handleClickButton }, { children: isPasswordShown ? _jsx(
|
|
163
|
+
return isPassword && (_jsx("button", __assign({ type: "button", className: "smartapp-input__container--eye-button", onClick: handleClickButton }, { children: isPasswordShown ? _jsx(EyeOnIcon, { style: iconStyles }) : _jsx(EyeOffIcon, { style: iconStyles }) })));
|
|
186
164
|
};
|
|
187
165
|
var renderMagnifyingGlass = function () {
|
|
188
166
|
return isSearchable && _jsx(MagnifyingGlassIcon, { className: "smartapp-input__container--magnifying-glass-icon", style: iconStyles });
|
|
189
167
|
};
|
|
190
168
|
var renderClearIcon = function () {
|
|
191
|
-
return
|
|
192
|
-
isClearableIconVisible && (_jsx(ClearIcon, { className: "smartapp-input__container--clear-icon", style: iconStyles, onMouseDown: handleClearClick, onTouchEnd: handleClearClick }));
|
|
169
|
+
return isClearIconVisible && (_jsx(ClearIcon, { className: "smartapp-input__container--clear-icon", style: iconStyles, onMouseDown: handleClearClick, onTouchEnd: handleClearClick }));
|
|
193
170
|
};
|
|
194
|
-
var
|
|
195
|
-
return
|
|
171
|
+
var renderInlineLabelWithArrows = function () {
|
|
172
|
+
return type === INPUT_TYPE_NUMBER && (_jsxs("div", __assign({ ref: inlineLabelRef, className: "smartapp-input__container--number-type" }, { children: [_jsx("div", __assign({ className: "smartapp-input__container--number-type__label" }, { children: inlineLabel })), _jsxs("div", __assign({ className: "smartapp-input__container--number-type__arrows-icon" }, { children: [_jsx(InputArrowUpIcon, { style: iconStyles, onClick: handleArrowUpClick }), _jsx(InputArrowDownIcon, { style: iconStyles, onClick: handleArrowDownClick })] }))] })));
|
|
196
173
|
};
|
|
197
174
|
var renderError = function () { return error && _jsx("div", __assign({ className: "smartapp-input__container--error" }, { children: error })); };
|
|
198
175
|
var renderHint = function () { return hint && _jsx("div", __assign({ className: "smartapp-input__hint" }, { children: hint })); };
|
|
199
|
-
return (_jsxs("div", __assign({ style: __assign({ width: "".concat(width, "%") }, containerStyles), className: classNames('smartapp-input', containerClassName) }, { children: [renderInputTitle(), _jsxs("div", __assign({ className: "smartapp-input__container" }, { children: [renderMask(), _jsx("input", __assign({ ref: inputRef, className: classNames('smartapp-input__container--field', {
|
|
176
|
+
return (_jsxs("div", __assign({ style: __assign(__assign({ width: "".concat(width, "%") }, generateFontFamilyStyle(fontFamily)), containerStyles), className: classNames('smartapp-input', containerClassName) }, { children: [renderInputTitle(), _jsxs("div", __assign({ className: "smartapp-input__container" }, { children: [renderMask(), _jsx("input", __assign({ ref: inputRef, className: classNames('smartapp-input__container--field', {
|
|
200
177
|
'smartapp-input__container--field__with-button': isPassword || isClearable || isSearchable,
|
|
201
178
|
'smartapp-input__container--field__disabled': disabled,
|
|
202
179
|
'smartapp-input__container--field__error': error && !disableErrorBorder,
|
|
203
|
-
|
|
204
|
-
}, className), style: __assign({ paddingLeft: calculateInputPaddingLeft(), paddingRight: calculateInputPaddingRight() }, style), type: generateInputType(), disabled: disabled, maxLength: maxCharacters, onKeyDown: handleKeyDown, onChange: handleChange, onFocus: handleFocus, onBlur: handleBlur }, props)), onAdditionalChange && (_jsxs("div", __assign({ className: "smartapp-input__container--additional-field", style: { width: "".concat(additionalWidth, "px") } }, { children: [_jsx("input", __assign({ ref: additionalInputRef, className: classNames('smartapp-input__container--additional-field__input', { 'smartapp-input__container--additional-field__input--disabled': disabled }, additionalClassName), defaultValue: additionalDefaultValue, disabled: disabled, maxLength: ADDITIONAL_MAX_CHARACTERS, placeholder: additionalPlaceholder, onChange: handleAdditionalChange }, additionalInputProps)), _jsx("span", { ref: hiddenSpanRef, className: "smartapp-input__container--additional-field__hidden-span" })] }))), renderEyeIcon(), renderMagnifyingGlass(), renderClearIcon(), renderTextCounter(), renderError()] })), renderHint()] })));
|
|
180
|
+
}, className), style: __assign({ paddingLeft: calculateInputPaddingLeft(), paddingRight: calculateInputPaddingRight() }, style), type: generateInputType(), disabled: disabled, onKeyDown: handleKeyDown, onChange: handleChange, onFocus: handleFocus, onBlur: handleBlur }, props)), onAdditionalChange && (_jsxs("div", __assign({ className: "smartapp-input__container--additional-field", style: { width: "".concat(additionalWidth, "px") } }, { children: [_jsx("input", __assign({ ref: additionalInputRef, className: classNames('smartapp-input__container--additional-field__input', { 'smartapp-input__container--additional-field__input--disabled': disabled }, additionalClassName), defaultValue: additionalDefaultValue, disabled: disabled, maxLength: ADDITIONAL_MAX_CHARACTERS, placeholder: additionalPlaceholder, onChange: handleAdditionalChange }, additionalInputProps)), _jsx("span", { ref: hiddenSpanRef, className: "smartapp-input__container--additional-field__hidden-span" })] }))), renderEyeIcon(), renderMagnifyingGlass(), renderClearIcon(), renderInlineLabelWithArrows(), renderError()] })), renderHint()] })));
|
|
205
181
|
};
|
|
206
182
|
export default Input;
|
|
207
183
|
//# sourceMappingURL=Input.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Input.js","sourceRoot":"","sources":["../../../../src/сomponents/Input/Input.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAc,EAAE,MAAM,EAAE,QAAQ,EAAE,
|
|
1
|
+
{"version":3,"file":"Input.js","sourceRoot":"","sources":["../../../../src/сomponents/Input/Input.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAc,EAAc,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AACtE,OAAO,UAAU,MAAM,YAAY,CAAA;AACnC,OAAO,EAAE,OAAO,EAAE,MAAM,QAAQ,CAAA;AAChC,OAAO,EAAE,aAAa,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAA;AACtE,OAAO,EACL,mBAAmB,EACnB,yBAAyB,EACzB,qBAAqB,EACrB,SAAS,EACT,oBAAoB,EACpB,gBAAgB,EAChB,iBAAiB,EACjB,mBAAmB,EACnB,eAAe,EACf,aAAa,GACd,MAAM,iBAAiB,CAAA;AAExB,OAAO,EAAE,cAAc,IAAI,SAAS,EAAE,MAAM,8BAA8B,CAAA;AAC1E,OAAO,EAAE,cAAc,IAAI,UAAU,EAAE,MAAM,gCAAgC,CAAA;AAC7E,OAAO,EAAE,cAAc,IAAI,SAAS,EAAE,MAAM,+BAA+B,CAAA;AAC3E,OAAO,EAAE,cAAc,IAAI,kBAAkB,EAAE,MAAM,yCAAyC,CAAA;AAC9F,OAAO,EAAE,cAAc,IAAI,gBAAgB,EAAE,MAAM,uCAAuC,CAAA;AAC1F,OAAO,EAAE,cAAc,IAAI,mBAAmB,EAAE,MAAM,yCAAyC,CAAA;AAC/F,OAAO,0BAA0B,CAAA;AAEjC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C,EAAE,KAAK,IAAI,CAAC,kBAAkB;yBACxE,EACD,SAAS,CACV,EACD,KAAK,aAAI,WAAW,EAAE,yBAAyB,EAAE,EAAE,YAAY,EAAE,0BAA0B,EAAE,IAAK,KAAK,GACvG,IAAI,EAAE,iBAAiB,EAAE,EACzB,QAAQ,EAAE,QAAQ,EAClB,SAAS,EAAE,aAAa,EACxB,QAAQ,EAAE,YAAY,EACtB,OAAO,EAAE,WAAW,EACpB,MAAM,EAAE,UAAU,IACd,KAAK,EACT,EACD,kBAAkB,IAAI,CACrB,wBAAK,SAAS,EAAC,6CAA6C,EAAC,KAAK,EAAE,EAAE,KAAK,EAAE,UAAG,eAAe,OAAI,EAAE,iBACnG,yBACE,GAAG,EAAE,kBAAkB,EACvB,SAAS,EAAE,UAAU,CACnB,oDAAoD,EACpD,EAAE,8DAA8D,EAAE,QAAQ,EAAE,EAC5E,mBAAmB,CACpB,EACD,YAAY,EAAE,sBAAsB,EACpC,QAAQ,EAAE,QAAQ,EAClB,SAAS,EAAE,yBAAyB,EACpC,WAAW,EAAE,qBAAqB,EAClC,QAAQ,EAAE,sBAAsB,IAC5B,oBAAoB,EACxB,EACF,eAAM,GAAG,EAAE,aAAa,EAAE,SAAS,EAAC,0DAA0D,GAAG,KAC7F,CACP,EACA,aAAa,EAAE,EACf,qBAAqB,EAAE,EACvB,eAAe,EAAE,EACjB,2BAA2B,EAAE,EAC7B,WAAW,EAAE,KACV,EACL,UAAU,EAAE,KACT,CACP,CAAA;AACH,CAAC,CAAA;AAED,eAAe,KAAK,CAAA"}
|
|
@@ -1,29 +1,27 @@
|
|
|
1
1
|
import { InputHTMLAttributes, RefObject } from 'react';
|
|
2
|
+
import { IFontFamilyProps, TStyles } from '../../constants';
|
|
2
3
|
import { IntRange } from '../types';
|
|
3
|
-
import { IThemeProps, TStyles } from '../../constants';
|
|
4
4
|
interface IInputParams extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChange'> {
|
|
5
5
|
onChange: (str: string) => void;
|
|
6
6
|
}
|
|
7
|
-
export interface IInputProps extends
|
|
7
|
+
export interface IInputProps extends IInputParams, IFontFamilyProps {
|
|
8
8
|
isPassword?: boolean;
|
|
9
9
|
isClearable?: boolean;
|
|
10
10
|
isSearchable?: boolean;
|
|
11
|
+
disableErrorBorder?: boolean;
|
|
11
12
|
title?: string;
|
|
12
13
|
mask?: string;
|
|
13
|
-
maxCharacters?: number;
|
|
14
14
|
hint?: string;
|
|
15
15
|
error?: string;
|
|
16
|
+
inlineLabel?: string;
|
|
16
17
|
fieldType?: 'text' | 'search';
|
|
17
|
-
|
|
18
|
-
|
|
18
|
+
outerRef?: RefObject<HTMLInputElement | null>;
|
|
19
|
+
additionalInputParams?: IInputParams;
|
|
19
20
|
width?: IntRange<1, 101>;
|
|
20
21
|
iconColor?: string;
|
|
21
22
|
containerClassName?: string;
|
|
22
23
|
containerStyles?: TStyles;
|
|
23
24
|
onEnterPress?: () => void;
|
|
24
25
|
onClearClick?: () => void;
|
|
25
|
-
additionalInputParams?: IInputParams;
|
|
26
|
-
outerRef?: RefObject<HTMLInputElement | null>;
|
|
27
|
-
disableErrorBorder?: boolean;
|
|
28
26
|
}
|
|
29
27
|
export {};
|
|
@@ -12,10 +12,10 @@ var __assign = (this && this.__assign) || function () {
|
|
|
12
12
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
13
|
import { useCallback, useEffect, useRef } from 'react';
|
|
14
14
|
import classNames from 'classnames';
|
|
15
|
-
import RadioButton from '../RadioButton';
|
|
16
15
|
import Checkbox from '../Checkbox';
|
|
16
|
+
import RadioButton from '../RadioButton';
|
|
17
17
|
import Toggle from '../Toggle';
|
|
18
|
-
import { generateId } from '../../helpers';
|
|
18
|
+
import { generateFontFamilyStyle, generateId } from '../../helpers';
|
|
19
19
|
import '../../styles/styles.scss';
|
|
20
20
|
export var LIST_ITEM_TYPE = {
|
|
21
21
|
interactive: 'interactive',
|
|
@@ -52,7 +52,7 @@ var isElement = function (element) {
|
|
|
52
52
|
return { isIndicatorElement: isIndicatorElement, isIconElement: isIconElement, isNoElement: isNoElement };
|
|
53
53
|
};
|
|
54
54
|
var ListItem = function (props) {
|
|
55
|
-
var textRef = props.textRef, type = props.type, text = props.text, element = props.element, isDisabled = props.isDisabled, className = props.className, styles = props.styles, textStyles = props.textStyles, interactiveElementStyles = props.interactiveElementStyles;
|
|
55
|
+
var fontFamily = props.fontFamily, textRef = props.textRef, type = props.type, text = props.text, element = props.element, isDisabled = props.isDisabled, className = props.className, styles = props.styles, textStyles = props.textStyles, interactiveElementStyles = props.interactiveElementStyles;
|
|
56
56
|
var listItemRef = useRef(null);
|
|
57
57
|
var isRadioButtonOrCheckbox = element === INTERACTIVE_ELEMENT.radioButton || element === INTERACTIVE_ELEMENT.checkbox;
|
|
58
58
|
var _a = isType(type), isInteractiveType = _a.isInteractiveType, isNotInteractiveType = _a.isNotInteractiveType;
|
|
@@ -202,7 +202,7 @@ var ListItem = function (props) {
|
|
|
202
202
|
window.removeEventListener('mouseup', handleMouseUp);
|
|
203
203
|
};
|
|
204
204
|
}, [handleMouseUp]);
|
|
205
|
-
return (_jsxs("div", __assign({ ref: listItemRef, className: classNames(generateClassName()), style: styles, onMouseDown: handleMouseDown, onClick: handleClick }, { children: [renderLeftElement(), _jsxs("div", __assign({ className: classNames(generateTextClassName()), style: textStyles }, { children: [_jsx("div", __assign({ ref: textRef }, { children: text })), renderSecondaryText()] })), renderRightElement()] })));
|
|
205
|
+
return (_jsxs("div", __assign({ ref: listItemRef, className: classNames(generateClassName()), style: __assign(__assign({}, generateFontFamilyStyle(fontFamily)), styles), onMouseDown: handleMouseDown, onClick: handleClick }, { children: [renderLeftElement(), _jsxs("div", __assign({ className: classNames(generateTextClassName()), style: textStyles }, { children: [_jsx("div", __assign({ ref: textRef }, { children: text })), renderSecondaryText()] })), renderRightElement()] })));
|
|
206
206
|
};
|
|
207
207
|
export default ListItem;
|
|
208
208
|
//# sourceMappingURL=ListItem.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ListItem.js","sourceRoot":"","sources":["../../../../src/сomponents/ListItem/ListItem.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAc,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAA;AAC7D,OAAO,UAAU,MAAM,YAAY,CAAA;AACnC,OAAO,
|
|
1
|
+
{"version":3,"file":"ListItem.js","sourceRoot":"","sources":["../../../../src/сomponents/ListItem/ListItem.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAc,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAA;AAC7D,OAAO,UAAU,MAAM,YAAY,CAAA;AACnC,OAAO,QAAQ,MAAM,aAAa,CAAA;AAClC,OAAO,WAAW,MAAM,gBAAgB,CAAA;AACxC,OAAO,MAAM,MAAM,WAAW,CAAA;AAC9B,OAAO,EAAE,uBAAuB,EAAE,UAAU,EAAE,MAAM,eAAe,CAAA;AAQnE,OAAO,0BAA0B,CAAA;AAEjC,MAAM,CAAC,IAAM,cAAc,GAAG;IAC5B,WAAW,EAAE,aAAa;IAC1B,cAAc,EAAE,iBAAiB;CAClC,CAAA;AAED,MAAM,CAAC,IAAM,mBAAmB,GAAG;IACjC,WAAW,EAAE,cAAc;IAC3B,QAAQ,EAAE,UAAU;IACpB,MAAM,EAAE,QAAQ;CACjB,CAAA;AAED,MAAM,CAAC,IAAM,oBAAoB,GAAG;IAClC,IAAI,EAAE,MAAM;IACZ,KAAK,EAAE,OAAO;CACf,CAAA;AAED,MAAM,CAAC,IAAM,uBAAuB,GAAG;IACrC,IAAI,EAAE,MAAM;IACZ,SAAS,EAAE,WAAW;IACtB,SAAS,EAAE,YAAY;CACxB,CAAA;AAED,IAAM,oBAAoB,GAAG,EAAE,CAAA;AAC/B,MAAM,CAAC,IAAM,uBAAuB,GAAG,MAAM,CAAA;AAC7C,IAAM,yBAAyB,GAAG,8CAA8C,C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AC5B,OAAO,EAAE,WAAW,iBAEnB,iBAAiB,EAAE,EACpB,wBAAK,SAAS,EAAE,UAAU,CAAC,qBAAqB,EAAE,CAAC,EAAE,KAAK,EAAE,UAAU,iBACpE,uBAAK,GAAG,EAAE,OAAO,gBAAG,IAAI,IAAO,EAC9B,mBAAmB,EAAE,KAClB,EACL,kBAAkB,EAAE,KACjB,CACP,CAAA;AACH,CAAC,CAAA;AAED,eAAe,QAAQ,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactElement, RefObject } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { IFontFamilyProps, TStyles } from '../../constants';
|
|
3
3
|
export type TInteractivePosition = 'left' | 'right';
|
|
4
4
|
export type TInteractiveElement = 'radio-button' | 'checkbox' | 'toggle';
|
|
5
5
|
export type TNotInteractiveElement = 'icon' | 'indicator' | 'no-element';
|
|
@@ -31,7 +31,7 @@ export interface NotInteractiveNoElementItemProps {
|
|
|
31
31
|
export type NotInteractiveItemProps = (NotInteractiveIconItemProps | NotInteractiveIndicatorItemProps | NotInteractiveNoElementItemProps) & {
|
|
32
32
|
type: 'not-interactive';
|
|
33
33
|
};
|
|
34
|
-
export type IListItemProps =
|
|
34
|
+
export type IListItemProps = IFontFamilyProps & (InteractiveItemProps | NotInteractiveItemProps) & {
|
|
35
35
|
text: string;
|
|
36
36
|
isDisabled?: boolean;
|
|
37
37
|
className?: string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { ILoaderProps } from './types';
|
|
2
2
|
import '../../styles/styles.scss';
|
|
3
|
-
declare const Loader: ({ isLoader, isFullScreen, isTextItalic, title, textSize, width, iconSize, containerClassName, className, containerStyles, styles, color, backgroundColor, theme, icon, }: ILoaderProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
3
|
+
declare const Loader: ({ fontFamily, isLoader, isFullScreen, isTextItalic, title, textSize, width, iconSize, containerClassName, className, containerStyles, styles, color, backgroundColor, theme, icon, }: ILoaderProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
4
4
|
export default Loader;
|
|
@@ -12,12 +12,12 @@ var __assign = (this && this.__assign) || function () {
|
|
|
12
12
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
13
|
import { cloneElement } from 'react';
|
|
14
14
|
import classNames from 'classnames';
|
|
15
|
+
import { generateColor, generateFontFamilyStyle, isDarkTheme } from '../../helpers';
|
|
15
16
|
import { COLORS, FONT_SIZE, LINE_HEIGHT, THEME } from '../../constants';
|
|
16
|
-
import { generateColor, isDarkTheme } from '../../helpers';
|
|
17
17
|
import { ReactComponent as LoaderIcon } from '../../assets/icons/loader.svg';
|
|
18
18
|
import '../../styles/styles.scss';
|
|
19
19
|
var Loader = function (_a) {
|
|
20
|
-
var isLoader = _a.isLoader, _b = _a.isFullScreen, isFullScreen = _b === void 0 ? true : _b, _c = _a.isTextItalic, isTextItalic = _c === void 0 ? false : _c, title = _a.title, _d = _a.textSize, textSize = _d === void 0 ? 'small' : _d, _e = _a.width, width = _e === void 0 ? 150 : _e, _f = _a.iconSize, iconSize = _f === void 0 ? 25 : _f, containerClassName = _a.containerClassName, className = _a.className, containerStyles = _a.containerStyles, styles = _a.styles, color = _a.color, backgroundColor = _a.backgroundColor, _g = _a.theme, theme = _g === void 0 ? THEME.default : _g, _h = _a.icon, icon = _h === void 0 ? _jsx(LoaderIcon, {}) : _h;
|
|
20
|
+
var fontFamily = _a.fontFamily, isLoader = _a.isLoader, _b = _a.isFullScreen, isFullScreen = _b === void 0 ? true : _b, _c = _a.isTextItalic, isTextItalic = _c === void 0 ? false : _c, title = _a.title, _d = _a.textSize, textSize = _d === void 0 ? 'small' : _d, _e = _a.width, width = _e === void 0 ? 150 : _e, _f = _a.iconSize, iconSize = _f === void 0 ? 25 : _f, containerClassName = _a.containerClassName, className = _a.className, containerStyles = _a.containerStyles, styles = _a.styles, color = _a.color, backgroundColor = _a.backgroundColor, _g = _a.theme, theme = _g === void 0 ? THEME.default : _g, _h = _a.icon, icon = _h === void 0 ? _jsx(LoaderIcon, {}) : _h;
|
|
21
21
|
var loaderColor = generateColor(color, COLORS.blue);
|
|
22
22
|
var generateTextStyles = function () { return ({
|
|
23
23
|
fontSize: FONT_SIZE[textSize],
|
|
@@ -38,7 +38,7 @@ var Loader = function (_a) {
|
|
|
38
38
|
height: iconSize,
|
|
39
39
|
style: { color: loaderColor },
|
|
40
40
|
};
|
|
41
|
-
return (_jsx("div", __assign({ className: classNames('smartapp-loader-wrapper', { 'smartapp-loader-wrapper__full-screen': isFullScreen }, containerClassName), style: __assign({ background: generateBackgroundColor() }, containerStyles) }, { children: _jsxs("div", __assign({ className: classNames('smartapp-loader', className), style: __assign({ width: "".concat(width, "px") }, styles) }, { children: [cloneElement(icon, iconProps), title && (_jsx("p", __assign({ className: "smartapp-loader__title", style: generateTextStyles() }, { children: title })))] })) })));
|
|
41
|
+
return (_jsx("div", __assign({ className: classNames('smartapp-loader-wrapper', { 'smartapp-loader-wrapper__full-screen': isFullScreen }, containerClassName), style: __assign(__assign({ background: generateBackgroundColor() }, generateFontFamilyStyle(fontFamily)), containerStyles) }, { children: _jsxs("div", __assign({ className: classNames('smartapp-loader', className), style: __assign({ width: "".concat(width, "px") }, styles) }, { children: [cloneElement(icon, iconProps), title && (_jsx("p", __assign({ className: "smartapp-loader__title", style: generateTextStyles() }, { children: title })))] })) })));
|
|
42
42
|
};
|
|
43
43
|
export default Loader;
|
|
44
44
|
//# sourceMappingURL=Loader.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Loader.js","sourceRoot":"","sources":["../../../../src/сomponents/Loader/Loader.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAc,EAAE,YAAY,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,UAAU,MAAM,YAAY,CAAA;
|
|
1
|
+
{"version":3,"file":"Loader.js","sourceRoot":"","sources":["../../../../src/сomponents/Loader/Loader.tsx"],"names":[],"mappings":";;;;;;;;;;;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9B,IAAM,oBAAoB,GAAG,YAAY,CAAC,CAAC,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAA;QAC7E,IAAM,YAAY,GAAG,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,oBAAoB,CAAA;QAE9E,OAAO,aAAa,CAAC,eAAe,EAAE,YAAY,CAAC,CAAA;IACrD,CAAC,CAAA;IAED,IAAI,CAAC,QAAQ,EAAE;QACb,OAAO,IAAI,CAAA;KACZ;IAED,IAAM,SAAS,GAAG;QAChB,SAAS,EAAE,uBAAuB;QAClC,KAAK,EAAE,QAAQ;QACf,MAAM,EAAE,QAAQ;QAChB,KAAK,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE;KAC9B,CAAA;IAED,OAAO,CACL,uBACE,SAAS,EAAE,UAAU,CAAC,yBAAyB,EAAE,EAAE,sCAAsC,EAAE,YAAY,EAAE,EAAE,kBAAkB,CAAC,EAC9H,KAAK,sBAAI,UAAU,EAAE,uBAAuB,EAAE,IAAK,uBAAuB,CAAC,UAAU,CAAC,GAAK,eAAe,iBAE1G,wBAAK,SAAS,EAAE,UAAU,CAAC,iBAAiB,EAAE,SAAS,CAAC,EAAE,KAAK,aAAI,KAAK,EAAE,UAAG,KAAK,OAAI,IAAK,MAAM,kBAC9F,YAAY,CAAC,IAAI,EAAE,SAAS,CAAC,EAC7B,KAAK,IAAI,CACR,qBAAG,SAAS,EAAC,wBAAwB,EAAC,KAAK,EAAE,kBAAkB,EAAE,gBAC9D,KAAK,IACJ,CACL,KACG,IACF,CACP,CAAA;AACH,CAAC,CAAA;AAED,eAAe,MAAM,CAAA"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ReactElement } from 'react';
|
|
2
|
-
import { IThemeProps, TStyles } from '../../constants';
|
|
3
|
-
export interface ILoaderProps extends IThemeProps {
|
|
2
|
+
import { IFontFamilyProps, IThemeProps, TStyles } from '../../constants';
|
|
3
|
+
export interface ILoaderProps extends IThemeProps, IFontFamilyProps {
|
|
4
4
|
isLoader: boolean;
|
|
5
5
|
isFullScreen?: boolean;
|
|
6
6
|
isTextItalic?: boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { IModalProps } from './types';
|
|
2
2
|
import '../../styles/styles.scss';
|
|
3
|
-
declare const Modal: ({ isModalOpen, isClosableOutside, isCloseIconHidden, isPopup, isBottomSheet, isDisabledBottomSheet, isCloseButtonDisabled, isResetPaddingBottom, modalId, content,
|
|
3
|
+
declare const Modal: ({ fontFamily, isModalOpen, isClosableOutside, isCloseIconHidden, isPopup, isBottomSheet, isDisabledBottomSheet, isCloseButtonDisabled, isResetPaddingBottom, modalId, content, bottomContent, title, titleIcons, platform, popupClassName, className, popupStyles, styles, titleStyles, contentStyles, iconColor, backgroundColor, modalMaxHeight, bottomSheetProps, externalBottomSheetScrollContainer, contextMenuProps, handleCloseModal, titleClassName, }: IModalProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
4
4
|
export default Modal;
|