@expressms/smartapp-ui 3.0.0-alpha.2 → 3.0.0-alpha.200
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/accepted-invite-status.svg +4 -0
- package/build/main/assets/icons/calendar-arrow-next.svg +3 -0
- package/build/main/assets/icons/calendar-arrow-prev.svg +3 -0
- package/build/main/assets/icons/chevron.svg +3 -0
- package/build/main/assets/icons/close-modal.svg +1 -1
- package/build/main/assets/icons/copy.svg +3 -0
- package/build/main/assets/icons/declined-invite-status.svg +4 -0
- package/build/main/assets/icons/department.svg +3 -0
- package/build/main/assets/icons/doc-small.svg +5 -5
- package/build/main/assets/icons/download.svg +3 -0
- package/build/main/assets/icons/file-small.svg +5 -5
- package/build/main/assets/icons/file.svg +1 -1
- package/build/main/assets/icons/image-no-preview-small.svg +11 -0
- package/build/main/assets/icons/image-no-preview.svg +11 -0
- package/build/main/assets/icons/job-position.svg +3 -0
- package/build/main/assets/icons/needs-action-invite-status.svg +4 -0
- package/build/main/assets/icons/notification-close.svg +1 -1
- package/build/main/assets/icons/notification-error.svg +5 -0
- package/build/main/assets/icons/notification-failure-filled.svg +3 -0
- package/build/main/assets/icons/notification-info-filled.svg +5 -0
- package/build/main/assets/icons/notification-success-filled.svg +4 -0
- package/build/main/assets/icons/office.svg +3 -0
- package/build/main/assets/icons/pdf-small.svg +5 -5
- package/build/main/assets/icons/ppt-small.svg +5 -5
- package/build/main/assets/icons/private.svg +4 -11
- package/build/main/assets/icons/search.svg +1 -1
- package/build/main/assets/icons/select-arrow-down.svg +3 -0
- package/build/main/assets/icons/select-arrow-up.svg +3 -0
- package/build/main/assets/icons/server.svg +3 -0
- package/build/main/assets/icons/txt-small.svg +5 -5
- package/build/main/assets/icons/video-no-preview-small.svg +11 -0
- package/build/main/assets/icons/video-no-preview.svg +11 -0
- package/build/main/assets/icons/xls-small.svg +5 -5
- package/build/main/assets/storybook/index.d.ts +4 -0
- package/build/main/assets/storybook/index.js +4 -0
- package/build/main/assets/storybook/index.js.map +1 -1
- package/build/main/constants/constants.d.ts +95 -47
- package/build/main/constants/constants.js +136 -50
- package/build/main/constants/constants.js.map +1 -1
- package/build/main/constants/types.d.ts +11 -1
- package/build/main/helpers/index.d.ts +3 -1
- package/build/main/helpers/index.js +21 -2
- package/build/main/helpers/index.js.map +1 -1
- package/build/main/hooks/useCharHintDisplay.d.ts +9 -0
- package/build/main/hooks/useCharHintDisplay.js +35 -0
- package/build/main/hooks/useCharHintDisplay.js.map +1 -0
- package/build/main/hooks/useMobileLongTap.d.ts +16 -0
- package/build/main/hooks/useMobileLongTap.js +65 -0
- package/build/main/hooks/useMobileLongTap.js.map +1 -0
- package/build/main/hooks/useModal.d.ts +18 -10
- package/build/main/hooks/useModal.js +235 -14
- package/build/main/hooks/useModal.js.map +1 -1
- package/build/main/index.d.ts +2 -0
- package/build/main/index.js +2 -0
- package/build/main/index.js.map +1 -1
- package/build/main/styles/styles.scss +2 -2
- package/build/main//321/201omponents/ActionModal/ActionModal.js +1 -1
- package/build/main//321/201omponents/ActionModal/ActionModal.js.map +1 -1
- package/build/main//321/201omponents/AttachedFile/AttachedFile.d.ts +1 -1
- package/build/main//321/201omponents/AttachedFile/AttachedFile.js +133 -28
- package/build/main//321/201omponents/AttachedFile/AttachedFile.js.map +1 -1
- package/build/main//321/201omponents/AttachedFile/types.d.ts +7 -5
- package/build/main//321/201omponents/Avatar/Avatar.d.ts +3 -2
- package/build/main//321/201omponents/Avatar/Avatar.js +56 -27
- package/build/main//321/201omponents/Avatar/Avatar.js.map +1 -1
- package/build/main//321/201omponents/Avatar/types.d.ts +9 -5
- package/build/main//321/201omponents/Avatar/types.js +5 -2
- package/build/main//321/201omponents/Avatar/types.js.map +1 -1
- package/build/main//321/201omponents/Button/Button.d.ts +1 -1
- package/build/main//321/201omponents/Button/Button.js +22 -11
- package/build/main//321/201omponents/Button/Button.js.map +1 -1
- package/build/main//321/201omponents/Button/types.d.ts +9 -2
- package/build/main//321/201omponents/Button/types.js +3 -0
- package/build/main//321/201omponents/Button/types.js.map +1 -1
- package/build/main//321/201omponents/Calendar/Calendar.d.ts +14 -2
- package/build/main//321/201omponents/Calendar/Calendar.js +238 -45
- package/build/main//321/201omponents/Calendar/Calendar.js.map +1 -1
- package/build/main//321/201omponents/Calendar/types.d.ts +22 -8
- package/build/main//321/201omponents/Charts/ChartBar/ChartBar.js +1 -1
- package/build/main//321/201omponents/Charts/ChartLine/ChartLine.js +1 -1
- package/build/main//321/201omponents/Charts/ChartPie/ChartPie.js +1 -1
- package/build/main//321/201omponents/Chip/Chip.d.ts +3 -2
- package/build/main//321/201omponents/Chip/Chip.js +198 -45
- package/build/main//321/201omponents/Chip/Chip.js.map +1 -1
- package/build/main//321/201omponents/Chip/types.d.ts +15 -5
- package/build/main//321/201omponents/ChipDndContext/ChipDndContext.d.ts +13 -0
- package/build/main//321/201omponents/ChipDndContext/ChipDndContext.js +76 -0
- package/build/main//321/201omponents/ChipDndContext/ChipDndContext.js.map +1 -0
- package/build/main//321/201omponents/ChipDndContext/index.d.ts +1 -0
- package/build/main//321/201omponents/ChipDndContext/index.js +2 -0
- package/build/main//321/201omponents/ChipDndContext/index.js.map +1 -0
- package/build/main//321/201omponents/ConfirmationModal/ConfirmationModal.d.ts +1 -1
- package/build/main//321/201omponents/ConfirmationModal/ConfirmationModal.js +3 -2
- package/build/main//321/201omponents/ConfirmationModal/ConfirmationModal.js.map +1 -1
- package/build/main//321/201omponents/ConfirmationModal/types.d.ts +5 -2
- package/build/main//321/201omponents/ContextMenu/ContextMenu.d.ts +1 -1
- package/build/main//321/201omponents/ContextMenu/ContextMenu.js +68 -27
- package/build/main//321/201omponents/ContextMenu/ContextMenu.js.map +1 -1
- package/build/main//321/201omponents/ContextMenu/types.d.ts +14 -7
- package/build/main//321/201omponents/ContextMenuItem/ContextMenuItem.d.ts +4 -0
- package/build/main//321/201omponents/ContextMenuItem/ContextMenuItem.js +49 -0
- package/build/main//321/201omponents/ContextMenuItem/ContextMenuItem.js.map +1 -0
- package/build/main//321/201omponents/ContextMenuItem/index.d.ts +1 -0
- package/build/main//321/201omponents/ContextMenuItem/index.js +2 -0
- package/build/main//321/201omponents/ContextMenuItem/index.js.map +1 -0
- package/build/main//321/201omponents/ContextMenuItem/types.d.ts +28 -0
- package/build/main//321/201omponents/ContextMenuItem/types.js +6 -0
- package/build/main//321/201omponents/ContextMenuItem/types.js.map +1 -0
- package/build/main//321/201omponents/CustomSelect/CustomSelect.d.ts +1 -1
- package/build/main//321/201omponents/CustomSelect/CustomSelect.js +57 -23
- 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 +35 -28
- package/build/main//321/201omponents/CustomSelect/selectStyles.js.map +1 -1
- package/build/main//321/201omponents/CustomSelect/types.d.ts +23 -4
- package/build/main//321/201omponents/CustomSelectProfiles/CustomSelectProfiles.d.ts +1 -1
- package/build/main//321/201omponents/CustomSelectProfiles/CustomSelectProfiles.js +33 -24
- package/build/main//321/201omponents/CustomSelectProfiles/CustomSelectProfiles.js.map +1 -1
- package/build/main//321/201omponents/CustomSelectProfiles/selectStyles.d.ts +11 -0
- package/build/main//321/201omponents/CustomSelectProfiles/selectStyles.js +39 -0
- package/build/main//321/201omponents/CustomSelectProfiles/selectStyles.js.map +1 -0
- package/build/main//321/201omponents/CustomSelectProfiles/types.d.ts +6 -5
- package/build/main//321/201omponents/DragAndDrop/DragAndDrop.js +2 -2
- 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 +25 -20
- package/build/main//321/201omponents/DraggablePopup/DraggablePopup.js.map +1 -1
- package/build/main//321/201omponents/DraggablePopup/types.d.ts +13 -11
- package/build/main//321/201omponents/Flex/Flex.d.ts +1 -1
- package/build/main//321/201omponents/Flex/Flex.js +2 -2
- package/build/main//321/201omponents/Flex/Flex.js.map +1 -1
- package/build/main//321/201omponents/Flex/types.d.ts +2 -0
- package/build/main//321/201omponents/Input/Input.d.ts +1 -1
- package/build/main//321/201omponents/Input/Input.js +90 -33
- package/build/main//321/201omponents/Input/Input.js.map +1 -1
- package/build/main//321/201omponents/Input/types.d.ts +10 -3
- package/build/main//321/201omponents/ListItem/ListItem.js +26 -20
- package/build/main//321/201omponents/ListItem/ListItem.js.map +1 -1
- package/build/main//321/201omponents/ListItem/types.d.ts +9 -4
- package/build/main//321/201omponents/Modal/Modal.d.ts +3 -2
- package/build/main//321/201omponents/Modal/Modal.js +276 -61
- package/build/main//321/201omponents/Modal/Modal.js.map +1 -1
- package/build/main//321/201omponents/Modal/types.d.ts +44 -2
- package/build/main//321/201omponents/Notification/Notification.d.ts +4 -6
- package/build/main//321/201omponents/Notification/Notification.js +88 -30
- package/build/main//321/201omponents/Notification/Notification.js.map +1 -1
- package/build/main//321/201omponents/Notification/types.d.ts +23 -5
- package/build/main//321/201omponents/Skeleton/Skeleton.js +1 -1
- package/build/main//321/201omponents/Skeleton/Skeleton.js.map +1 -1
- package/build/main//321/201omponents/Stories/Stories.js +72 -4
- package/build/main//321/201omponents/Stories/Stories.js.map +1 -1
- package/build/main//321/201omponents/Textarea/Textarea.d.ts +1 -1
- package/build/main//321/201omponents/Textarea/Textarea.js +9 -6
- package/build/main//321/201omponents/Textarea/Textarea.js.map +1 -1
- package/build/main//321/201omponents/Textarea/types.d.ts +6 -3
- package/build/main//321/201omponents/UserDropdown/ContactBottomSheet/ContactBottomSheet.d.ts +1 -1
- package/build/main//321/201omponents/UserDropdown/ContactBottomSheet/ContactBottomSheet.js +12 -2
- package/build/main//321/201omponents/UserDropdown/ContactBottomSheet/ContactBottomSheet.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/ContactInfo/ContactInfo.js +28 -12
- package/build/main//321/201omponents/UserDropdown/ContactInfo/ContactInfo.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/LoadingMessage/LoadingMessage.d.ts +2 -1
- package/build/main//321/201omponents/UserDropdown/LoadingMessage/LoadingMessage.js +4 -3
- package/build/main//321/201omponents/UserDropdown/LoadingMessage/LoadingMessage.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/MenuList/MenuList.js +35 -59
- package/build/main//321/201omponents/UserDropdown/MenuList/MenuList.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/MultiValueLabel/MultiValueLabel.d.ts +3 -2
- package/build/main//321/201omponents/UserDropdown/MultiValueLabel/MultiValueLabel.js +33 -24
- package/build/main//321/201omponents/UserDropdown/MultiValueLabel/MultiValueLabel.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/Option/Option.js +16 -11
- package/build/main//321/201omponents/UserDropdown/Option/Option.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/SearchInCatalogButton/SearchInCatalogButton.d.ts +1 -1
- package/build/main//321/201omponents/UserDropdown/SearchInCatalogButton/SearchInCatalogButton.js +7 -9
- package/build/main//321/201omponents/UserDropdown/SearchInCatalogButton/SearchInCatalogButton.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/UserDropdown.d.ts +3 -3
- package/build/main//321/201omponents/UserDropdown/UserDropdown.js +239 -262
- package/build/main//321/201omponents/UserDropdown/UserDropdown.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/components/Delimiter.d.ts +8 -0
- package/build/main//321/201omponents/UserDropdown/components/Delimiter.js +10 -0
- package/build/main//321/201omponents/UserDropdown/components/Delimiter.js.map +1 -0
- package/build/main//321/201omponents/UserDropdown/components/Hint.d.ts +6 -0
- package/build/main//321/201omponents/UserDropdown/components/Hint.js +21 -0
- package/build/main//321/201omponents/UserDropdown/components/Hint.js.map +1 -0
- package/build/main//321/201omponents/UserDropdown/components/Input.d.ts +2 -0
- package/build/main//321/201omponents/UserDropdown/components/Input.js +24 -0
- package/build/main//321/201omponents/UserDropdown/components/Input.js.map +1 -0
- package/build/main//321/201omponents/UserDropdown/components/Mask.d.ts +7 -0
- package/build/main//321/201omponents/UserDropdown/components/Mask.js +18 -0
- package/build/main//321/201omponents/UserDropdown/components/Mask.js.map +1 -0
- package/build/main//321/201omponents/UserDropdown/components/Title.d.ts +5 -0
- package/build/main//321/201omponents/UserDropdown/components/Title.js +18 -0
- package/build/main//321/201omponents/UserDropdown/components/Title.js.map +1 -0
- package/build/main//321/201omponents/UserDropdown/constants.d.ts +57 -0
- package/build/main//321/201omponents/UserDropdown/constants.js +73 -0
- package/build/main//321/201omponents/UserDropdown/constants.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/helpers.d.ts +84 -41
- package/build/main//321/201omponents/UserDropdown/helpers.js +184 -14
- 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 +58 -27
- package/build/main//321/201omponents/UserDropdown/selectStyles.js.map +1 -1
- package/build/main//321/201omponents/UserDropdown/types.d.ts +146 -60
- package/build/main//321/201omponents/UserDropdown/types.js +1 -8
- package/build/main//321/201omponents/UserDropdown/types.js.map +1 -1
- package/package.json +12 -7
- package/build/main/assets/icons/avatar-arrow-down.svg +0 -3
- package/build/main/assets/icons/avatar-arrow-up.svg +0 -3
- package/build/main/hooks/useLongTap.d.ts +0 -12
- package/build/main/hooks/useLongTap.js +0 -29
- package/build/main/hooks/useLongTap.js.map +0 -1
|
@@ -12,10 +12,13 @@ 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 { isUndefined } from 'lodash';
|
|
16
|
+
import Avatar from '../Avatar';
|
|
15
17
|
import Checkbox from '../Checkbox';
|
|
16
18
|
import RadioButton from '../RadioButton';
|
|
17
19
|
import Toggle from '../Toggle';
|
|
18
20
|
import { generateFontFamilyStyle, generateId } from '../../helpers';
|
|
21
|
+
import { AVATAR_SIZES } from '../Avatar/types';
|
|
19
22
|
import '../../styles/styles.scss';
|
|
20
23
|
export var LIST_ITEM_TYPE = {
|
|
21
24
|
interactive: 'interactive',
|
|
@@ -52,24 +55,21 @@ var isElement = function (element) {
|
|
|
52
55
|
return { isIndicatorElement: isIndicatorElement, isIconElement: isIconElement, isNoElement: isNoElement };
|
|
53
56
|
};
|
|
54
57
|
var ListItem = function (props) {
|
|
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;
|
|
58
|
+
var platform = props.platform, fontFamily = props.fontFamily, textRef = props.textRef, type = props.type, text = props.text, element = props.element, isDisabled = props.isDisabled, isTextTruncated = props.isTextTruncated, className = props.className, styles = props.styles, textStyles = props.textStyles, primaryTextStyles = props.primaryTextStyles, primaryTextClassName = props.primaryTextClassName, interactiveElementStyles = props.interactiveElementStyles, avatar = props.avatar;
|
|
56
59
|
var listItemRef = useRef(null);
|
|
57
60
|
var isRadioButtonOrCheckbox = element === INTERACTIVE_ELEMENT.radioButton || element === INTERACTIVE_ELEMENT.checkbox;
|
|
61
|
+
var isUserListItem = !isUndefined(avatar);
|
|
58
62
|
var _a = isType(type), isInteractiveType = _a.isInteractiveType, isNotInteractiveType = _a.isNotInteractiveType;
|
|
59
63
|
var _b = isElement(element), isIndicatorElement = _b.isIndicatorElement, isIconElement = _b.isIconElement, isNoElement = _b.isNoElement;
|
|
60
64
|
var isLeftPosition = function (position) { return position === INTERACTIVE_POSITION.left; };
|
|
61
65
|
var isRightPosition = function (position) { return position === INTERACTIVE_POSITION.right; };
|
|
62
66
|
var generatePressedClassName = useCallback(function () {
|
|
63
|
-
var isElementHasSelectedProps = isIndicatorElement || isNoElement;
|
|
64
67
|
if (isNotInteractiveType && !isDisabled) {
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
return isSelected ? SELECTED_PRESSED_CLASSNAME : DEFAULT_PRESSED_CLASSNAME;
|
|
68
|
-
}
|
|
69
|
-
return DEFAULT_PRESSED_CLASSNAME;
|
|
68
|
+
var isSelected = props.isSelected;
|
|
69
|
+
return isSelected ? SELECTED_PRESSED_CLASSNAME : DEFAULT_PRESSED_CLASSNAME;
|
|
70
70
|
}
|
|
71
71
|
return '';
|
|
72
|
-
}, [isDisabled,
|
|
72
|
+
}, [isDisabled, isNotInteractiveType, props]);
|
|
73
73
|
var handleMouseDown = useCallback(function () {
|
|
74
74
|
var _a;
|
|
75
75
|
var pressedClassName = generatePressedClassName();
|
|
@@ -127,13 +127,17 @@ var ListItem = function (props) {
|
|
|
127
127
|
return null;
|
|
128
128
|
};
|
|
129
129
|
var renderLeftElement = function () {
|
|
130
|
+
if (isUserListItem) {
|
|
131
|
+
var secondaryText = props.secondaryText;
|
|
132
|
+
var username = secondaryText || text;
|
|
133
|
+
return _jsx(Avatar, { fontFamily: fontFamily, className: "smartapp-list-item__avatar", avatar: avatar, username: username, size: AVATAR_SIZES.size_32 });
|
|
134
|
+
}
|
|
130
135
|
if (isInteractiveType) {
|
|
131
136
|
var _a = props, _b = _a.position, position = _b === void 0 ? INTERACTIVE_POSITION.right : _b, _c = _a.isIndicator, isIndicator = _c === void 0 ? false : _c, color = _a.color;
|
|
132
137
|
return isLeftPosition(position) ? renderInteractiveElement() : renderIndicatorElement({ isIndicator: isIndicator, color: color });
|
|
133
138
|
}
|
|
134
|
-
if (isNotInteractiveType)
|
|
139
|
+
if (isNotInteractiveType)
|
|
135
140
|
return renderNotInteractiveElement();
|
|
136
|
-
}
|
|
137
141
|
};
|
|
138
142
|
var renderRightElement = function () {
|
|
139
143
|
if (isInteractiveType) {
|
|
@@ -143,12 +147,13 @@ var ListItem = function (props) {
|
|
|
143
147
|
};
|
|
144
148
|
var renderSecondaryText = function () {
|
|
145
149
|
if (isNotInteractiveType && isNoElement) {
|
|
146
|
-
var _a = props, secondaryText = _a.secondaryText, secondaryTextColor = _a.secondaryTextColor;
|
|
147
|
-
return secondaryText ? _jsx("div", __assign({ style: { color: secondaryTextColor } }, { children: secondaryText })) : null;
|
|
150
|
+
var _a = props, secondaryText = _a.secondaryText, secondaryTextColor = _a.secondaryTextColor, _b = _a.secondaryTextStyles, secondaryTextStyles = _b === void 0 ? {} : _b, secondaryTextClassName = _a.secondaryTextClassName;
|
|
151
|
+
return secondaryText ? (_jsx("div", __assign({ className: secondaryTextClassName, style: __assign({ color: secondaryTextColor }, secondaryTextStyles) }, { children: secondaryText }))) : null;
|
|
148
152
|
}
|
|
149
153
|
};
|
|
150
154
|
var generateTextClassName = function () {
|
|
151
|
-
var
|
|
155
|
+
var defaultTextClassname = 'smartapp-list-item__text';
|
|
156
|
+
var classNames = isUserListItem || isTextTruncated ? [defaultTextClassname, "".concat(defaultTextClassname, "--wrap")] : [defaultTextClassname];
|
|
152
157
|
if (isInteractiveType) {
|
|
153
158
|
var _a = props, _b = _a.position, position = _b === void 0 ? INTERACTIVE_POSITION.right : _b, isIndicator = _a.isIndicator;
|
|
154
159
|
var isLeftClassNeeded = isLeftPosition(position) || isIndicator;
|
|
@@ -157,21 +162,22 @@ var ListItem = function (props) {
|
|
|
157
162
|
isIndicator && isRightPosition(position) && classNames.push('smartapp-list-item__text--ellipse');
|
|
158
163
|
}
|
|
159
164
|
if (isNotInteractiveType && (isIconElement || isIndicatorElement)) {
|
|
160
|
-
classNames.push('smartapp-list-item__text--left');
|
|
165
|
+
classNames.push(isIconElement ? 'smartapp-list-item__text--increased-left' : 'smartapp-list-item__text--left');
|
|
161
166
|
}
|
|
162
167
|
isDisabled && classNames.push('smartapp-list-item__text--disabled');
|
|
163
168
|
return classNames;
|
|
164
169
|
};
|
|
165
170
|
var generateClassName = function () {
|
|
166
|
-
var
|
|
167
|
-
var
|
|
168
|
-
|
|
171
|
+
var typeClassName = "smartapp-list-item__".concat(type);
|
|
172
|
+
var selectedClassName = "".concat(typeClassName, "--selected");
|
|
173
|
+
var classNames = ['smartapp-list-item', typeClassName, "".concat(typeClassName, "--").concat(platform)];
|
|
174
|
+
if (isNotInteractiveType) {
|
|
169
175
|
var isSelected = props.isSelected;
|
|
170
|
-
isSelected && classNames.push("
|
|
176
|
+
isSelected && classNames.push.apply(classNames, [selectedClassName, "".concat(selectedClassName, "__").concat(platform)]);
|
|
171
177
|
}
|
|
172
178
|
if (isNoElement) {
|
|
173
179
|
var secondaryText = props.secondaryText;
|
|
174
|
-
secondaryText && classNames.push("
|
|
180
|
+
secondaryText && classNames.push("".concat(typeClassName, "--with-secondary-text"));
|
|
175
181
|
}
|
|
176
182
|
isDisabled && classNames.push('smartapp-list-item__disabled');
|
|
177
183
|
className && classNames.push(className);
|
|
@@ -202,7 +208,7 @@ var ListItem = function (props) {
|
|
|
202
208
|
window.removeEventListener('mouseup', handleMouseUp);
|
|
203
209
|
};
|
|
204
210
|
}, [handleMouseUp]);
|
|
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()] })));
|
|
211
|
+
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, className: primaryTextClassName, style: primaryTextStyles }, { children: text })), renderSecondaryText()] })), renderRightElement()] })));
|
|
206
212
|
};
|
|
207
213
|
export default ListItem;
|
|
208
214
|
//# 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,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;
|
|
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,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AACpC,OAAO,MAAM,MAAM,WAAW,CAAA;AAC9B,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;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AAS9C,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;IACl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EAAE,oBAAoB,EAAE,KAAK,EAAE,iBAAiB,gBACzE,IAAI,IACD,EACL,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 { IFontFamilyProps, TStyles } from '../../constants';
|
|
2
|
+
import { IFontFamilyProps, IPlatformProps, TAvatar, 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';
|
|
@@ -20,23 +20,28 @@ export interface NotInteractiveIconItemProps {
|
|
|
20
20
|
export interface NotInteractiveIndicatorItemProps {
|
|
21
21
|
element: 'indicator';
|
|
22
22
|
color?: TIndicatorColor;
|
|
23
|
-
isSelected?: boolean;
|
|
24
23
|
}
|
|
25
24
|
export interface NotInteractiveNoElementItemProps {
|
|
26
25
|
element: 'no-element';
|
|
27
|
-
isSelected?: boolean;
|
|
28
26
|
secondaryText?: string;
|
|
29
27
|
secondaryTextColor?: string;
|
|
28
|
+
secondaryTextStyles?: TStyles;
|
|
29
|
+
secondaryTextClassName?: string;
|
|
30
30
|
}
|
|
31
31
|
export type NotInteractiveItemProps = (NotInteractiveIconItemProps | NotInteractiveIndicatorItemProps | NotInteractiveNoElementItemProps) & {
|
|
32
32
|
type: 'not-interactive';
|
|
33
|
+
isSelected?: boolean;
|
|
33
34
|
};
|
|
34
|
-
export type IListItemProps = IFontFamilyProps & (InteractiveItemProps | NotInteractiveItemProps) & {
|
|
35
|
+
export type IListItemProps = IFontFamilyProps & IPlatformProps & (InteractiveItemProps | NotInteractiveItemProps) & {
|
|
35
36
|
text: string;
|
|
36
37
|
isDisabled?: boolean;
|
|
38
|
+
isTextTruncated?: boolean;
|
|
37
39
|
className?: string;
|
|
38
40
|
styles?: TStyles;
|
|
39
41
|
textStyles?: TStyles;
|
|
42
|
+
primaryTextStyles?: TStyles;
|
|
43
|
+
primaryTextClassName?: string;
|
|
40
44
|
interactiveElementStyles?: TStyles;
|
|
41
45
|
textRef?: RefObject<HTMLDivElement | null>;
|
|
46
|
+
avatar?: TAvatar;
|
|
42
47
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { IModalProps } from './types';
|
|
1
|
+
import { IModalProps, TBottomSheetScrollMobileConfig } from './types';
|
|
2
2
|
import '../../styles/styles.scss';
|
|
3
|
-
declare const
|
|
3
|
+
export declare const DEFAULT_BOTTOM_SHEET_SCROLL_MOBILE_CONFIG: TBottomSheetScrollMobileConfig;
|
|
4
|
+
declare const Modal: ({ fontFamily, isModalOpen, isClosableOutside, isCloseIconHidden, isPopup, isBottomSheet, isDisabledBottomSheet, isCloseButtonDisabled, isResetPaddingBottom, isScrollBordersVisible, isDisableTitleCollapsing, isBottomContentBorderShown, isNeedToScrollUp, isDisablePopupDragging, modalId, contentId, mobileContentId, modalRef: outerModalRef, content, bottomContent, title, titleIcons, platform, popupClassName, className, titleClassName, iconsClassName, popupStyles, styles, titleStyles, contentStyles, scrollableContentStyles, iconColor, backgroundColor, modalMaxHeight, bottomSheetProps, bottomSheetDetent, bottomSheetStyles, externalBottomSheetScrollContainer, contextMenuProps, bottomSheetScrollMobileConfig, handleChangeTitleBorderDisplayed, handleClickOutside, handleCloseModal, handleBottomSheetInitialized, onScroll: externalHandleScroll, }: IModalProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
4
5
|
export default Modal;
|