@zohodesk/dot 1.0.0-temp-228.2 → 1.0.0-temp-229
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/README.md +16 -0
- package/assets/Appearance/dark/mode/Dot_DarkMode.module.css +2 -0
- package/assets/Appearance/light/mode/Dot_LightMode.module.css +2 -0
- package/assets/Appearance/pureDark/mode/Dot_PureDarkMode.module.css +2 -0
- package/es/ActionButton/ActionButton.module.css +12 -11
- package/es/ActionButton/__tests__/__snapshots__/ActionButton.spec.js.snap +47 -60
- package/es/AlphabeticList/AlphabeticList.module.css +7 -8
- package/es/Attachment/Attachment.module.css +9 -10
- package/es/AttachmentViewer/AttachmentViewer.module.css +24 -45
- package/es/AudioPlayer/AudioPlayer.module.css +5 -8
- package/es/DotProvider/DotProvider.js +2 -0
- package/es/DotProvider/__tests__/DotProvider.spec.js +106 -0
- package/es/DotProvider/hooks/useDotProvider.js +4 -2
- package/es/DotProvider/hooks/useDownloadAssetsAndSetAttr.js +44 -15
- package/es/DotProvider/props/defaultProps.js +2 -0
- package/es/DotProvider/props/propTypes.js +1 -0
- package/es/Drawer/Drawer.module.css +17 -64
- package/es/FormAction/FormAction.module.css +20 -54
- package/es/ImportantNotes/ImportantNotes.module.css +2 -9
- package/es/Message/Message.module.css +3 -16
- package/es/MessageBanner/MessageBanner.module.css +4 -13
- package/es/Separator/Separator.module.css +2 -1
- package/es/TagWithIcon/TagWithIcon.module.css +5 -8
- package/es/ToastMessage/ToastMessage.module.css +16 -30
- package/es/Upload/Upload.module.css +7 -9
- package/es/alert/AlertHeader/AlertHeader.module.css +11 -25
- package/es/alert/AlertLookup/AlertLookup.module.css +9 -10
- package/es/avatar/AvatarCollision/AvatarCollision.module.css +1 -1
- package/es/avatar/AvatarWithTeam/AvatarWithTeam.module.css +1 -1
- package/es/common/dot_boxShadow.module.css +2 -0
- package/es/dropdown/ToggleDropDown/ToggleDropDown.module.css +16 -16
- package/es/emptystate/CommonEmptyState/CommonEmptyState.module.css +7 -9
- package/es/emptystate/EditionPage/EditionPage.css +7 -4
- package/es/errorstate/EmptyStates.module.css +7 -8
- package/es/errorstate/Inconvenience/Inconvenience.module.css +2 -5
- package/es/errorstate/NoRequestFound/NoRequestFound.module.css +1 -1
- package/es/errorstate/PermissionPlay/PermissionPlay.module.css +5 -4
- package/es/errorstate/RequestUrlNotFound/RequestUrlNotFound.module.css +1 -1
- package/es/errorstate/UnableToProcess/UnableToProcess.module.css +1 -1
- package/es/errorstate/UnauthorizedLogin/UnauthorizedLogin.module.css +1 -1
- package/es/errorstate/WillBack/WillBack.module.css +6 -4
- package/es/form/fields/Fields.module.css +23 -68
- package/es/form/fields/SelectField/SelectField.js +4 -2
- package/es/form/fields/SelectField/props/propTypes.js +1 -0
- package/es/form/fields/TagsMultiSelect/TagsMultiSelect.module.css +11 -16
- package/es/form/fields/TagsMultiSelectField/TagsMultiSelectField.module.css +1 -4
- package/es/form/fields/TextEditor/TextEditor.module.css +40 -66
- package/es/form/fields/TextEditorWrapper/TextEditorWrapper.module.css +2 -7
- package/es/form/fields/ValidationMessage/ValidationMessage.module.css +4 -3
- package/es/layout/SetupDetailLayout/SetupDetailLayout.module.css +14 -36
- package/es/layout/SubtabLayout/SubtabLayout.module.css +33 -46
- package/es/list/BluePrintStatus/BluePrintStatus.module.css +1 -4
- package/es/list/Comment/Comment.module.css +2 -1
- package/es/list/Dot/Dot.module.css +4 -2
- package/es/list/GridStencils/GridStencils.module.css +7 -9
- package/es/list/ListLayout/ListLayout.module.css +7 -4
- package/es/list/ListStencils/ListStencils.module.css +14 -15
- package/es/list/SecondaryText/SecondaryText.module.css +4 -13
- package/es/list/SentimentStatus/SentimentStatus.module.css +2 -4
- package/es/list/TagNew/TagNew.module.css +3 -2
- package/es/list/listCommon.module.css +3 -7
- package/es/list/status/StatusDropdown/StatusDropdown.js +121 -79
- package/es/list/status/StatusDropdown/StatusDropdown.module.css +65 -18
- package/es/list/status/StatusDropdown/props/defaultProps.js +2 -1
- package/es/list/status/StatusDropdown/props/propTypes.js +1 -0
- package/es/list/status/StatusListItem/StatusListItem.module.css +10 -18
- package/es/lookup/EmptyPage/LookupEmptyPage.module.css +4 -3
- package/es/lookup/Lookup/Lookup.module.css +2 -2
- package/es/lookup/header/Search/LookupSearch.module.css +10 -23
- package/es/lookup/header/TicketHeader/TicketHeader.module.css +3 -2
- package/es/lookup/header/ViewDropDown/ViewDropDown.module.css +8 -12
- package/es/lookup/header/lookupHeaderCommon.module.css +8 -7
- package/es/lookup/header/lookupHeaderCommonResponsive.module.css +2 -6
- package/es/setup/header/Button/HeaderButton.module.css +2 -4
- package/es/setup/header/Link/HeaderLink.module.css +3 -9
- package/es/setup/header/Search/Search.module.css +2 -10
- package/es/setup/header/Views/Views.module.css +1 -4
- package/es/setup/helptips/Description/HelpTipsDescription.module.css +2 -1
- package/es/setup/helptips/Link/HelpTipsLink.module.css +2 -2
- package/es/setup/helptips/ListGroup/ListGroup.module.css +2 -6
- package/es/setup/table/TableData/SetupTableData.module.css +2 -4
- package/es/setup/table/TableHead/SetupTableHead.module.css +1 -6
- package/es/setup/table/TableRow/SetupTableRow.module.css +2 -7
- package/es/version2/GlobalNotification/GlobalNotification.module.css +7 -12
- package/es/version2/errorstate/V2_ErrorStates.module.css +5 -5
- package/es/version2/lookup/AlertHeader/css/AlertHeaderNew.module.css +8 -23
- package/es/version2/lookup/AlertLookup/AlertLookupNew.module.css +9 -10
- package/es/version2/lookup/alertLookupCommonNew.module.css +6 -4
- package/es/version2/notification/DesktopNotification/DesktopNotification.module.css +8 -11
- package/es/version2/notification/DesktopNotificationHeader/DesktopNotificationHeader.module.css +10 -22
- package/lib/ActionButton/ActionButton.module.css +12 -11
- package/lib/ActionButton/__tests__/__snapshots__/ActionButton.spec.js.snap +47 -60
- package/lib/AlphabeticList/AlphabeticList.module.css +7 -8
- package/lib/Attachment/Attachment.module.css +9 -10
- package/lib/AttachmentViewer/AttachmentViewer.module.css +24 -45
- package/lib/AudioPlayer/AudioPlayer.module.css +5 -8
- package/lib/DotProvider/DotProvider.js +3 -1
- package/lib/DotProvider/__tests__/DotProvider.spec.js +216 -0
- package/lib/DotProvider/hooks/useDotProvider.js +4 -2
- package/lib/DotProvider/hooks/useDownloadAssetsAndSetAttr.js +46 -15
- package/lib/DotProvider/props/defaultProps.js +3 -0
- package/lib/DotProvider/props/propTypes.js +1 -0
- package/lib/Drawer/Drawer.module.css +17 -64
- package/lib/FormAction/FormAction.module.css +20 -54
- package/lib/ImportantNotes/ImportantNotes.module.css +2 -9
- package/lib/Message/Message.module.css +3 -16
- package/lib/MessageBanner/MessageBanner.module.css +4 -13
- package/lib/Separator/Separator.module.css +2 -1
- package/lib/TagWithIcon/TagWithIcon.module.css +5 -8
- package/lib/ToastMessage/ToastMessage.module.css +16 -30
- package/lib/Upload/Upload.module.css +7 -9
- package/lib/alert/AlertHeader/AlertHeader.module.css +11 -25
- package/lib/alert/AlertLookup/AlertLookup.module.css +9 -10
- package/lib/avatar/AvatarCollision/AvatarCollision.module.css +1 -1
- package/lib/avatar/AvatarWithTeam/AvatarWithTeam.module.css +1 -1
- package/lib/common/dot_boxShadow.module.css +2 -0
- package/lib/dropdown/ToggleDropDown/ToggleDropDown.module.css +16 -16
- package/lib/emptystate/CommonEmptyState/CommonEmptyState.module.css +7 -9
- package/lib/emptystate/EditionPage/EditionPage.css +7 -4
- package/lib/errorstate/EmptyStates.module.css +7 -8
- package/lib/errorstate/Inconvenience/Inconvenience.module.css +2 -5
- package/lib/errorstate/NoRequestFound/NoRequestFound.module.css +1 -1
- package/lib/errorstate/PermissionPlay/PermissionPlay.module.css +5 -4
- package/lib/errorstate/RequestUrlNotFound/RequestUrlNotFound.module.css +1 -1
- package/lib/errorstate/UnableToProcess/UnableToProcess.module.css +1 -1
- package/lib/errorstate/UnauthorizedLogin/UnauthorizedLogin.module.css +1 -1
- package/lib/errorstate/WillBack/WillBack.module.css +6 -4
- package/lib/form/fields/Fields.module.css +23 -68
- package/lib/form/fields/SelectField/SelectField.js +4 -2
- package/lib/form/fields/SelectField/props/propTypes.js +1 -0
- package/lib/form/fields/TagsMultiSelect/TagsMultiSelect.module.css +11 -16
- package/lib/form/fields/TagsMultiSelectField/TagsMultiSelectField.module.css +1 -4
- package/lib/form/fields/TextEditor/TextEditor.module.css +40 -66
- package/lib/form/fields/TextEditorWrapper/TextEditorWrapper.module.css +2 -7
- package/lib/form/fields/ValidationMessage/ValidationMessage.module.css +4 -3
- package/lib/layout/SetupDetailLayout/SetupDetailLayout.module.css +14 -36
- package/lib/layout/SubtabLayout/SubtabLayout.module.css +33 -46
- package/lib/list/BluePrintStatus/BluePrintStatus.module.css +1 -4
- package/lib/list/Comment/Comment.module.css +2 -1
- package/lib/list/Dot/Dot.module.css +4 -2
- package/lib/list/GridStencils/GridStencils.module.css +7 -9
- package/lib/list/ListLayout/ListLayout.module.css +7 -4
- package/lib/list/ListStencils/ListStencils.module.css +14 -15
- package/lib/list/SecondaryText/SecondaryText.module.css +4 -13
- package/lib/list/SentimentStatus/SentimentStatus.module.css +2 -4
- package/lib/list/TagNew/TagNew.module.css +3 -2
- package/lib/list/listCommon.module.css +3 -7
- package/lib/list/status/StatusDropdown/StatusDropdown.js +133 -81
- package/lib/list/status/StatusDropdown/StatusDropdown.module.css +65 -18
- package/lib/list/status/StatusDropdown/props/defaultProps.js +2 -1
- package/lib/list/status/StatusDropdown/props/propTypes.js +1 -1
- package/lib/list/status/StatusListItem/StatusListItem.module.css +10 -18
- package/lib/lookup/EmptyPage/LookupEmptyPage.module.css +4 -3
- package/lib/lookup/Lookup/Lookup.module.css +2 -2
- package/lib/lookup/header/Search/LookupSearch.module.css +10 -23
- package/lib/lookup/header/TicketHeader/TicketHeader.module.css +3 -2
- package/lib/lookup/header/ViewDropDown/ViewDropDown.module.css +8 -12
- package/lib/lookup/header/lookupHeaderCommon.module.css +8 -7
- package/lib/lookup/header/lookupHeaderCommonResponsive.module.css +2 -6
- package/lib/setup/header/Button/HeaderButton.module.css +2 -4
- package/lib/setup/header/Link/HeaderLink.module.css +3 -9
- package/lib/setup/header/Search/Search.module.css +2 -10
- package/lib/setup/header/Views/Views.module.css +1 -4
- package/lib/setup/helptips/Description/HelpTipsDescription.module.css +2 -1
- package/lib/setup/helptips/Link/HelpTipsLink.module.css +2 -2
- package/lib/setup/helptips/ListGroup/ListGroup.module.css +2 -6
- package/lib/setup/table/TableData/SetupTableData.module.css +2 -4
- package/lib/setup/table/TableHead/SetupTableHead.module.css +1 -6
- package/lib/setup/table/TableRow/SetupTableRow.module.css +2 -7
- package/lib/version2/GlobalNotification/GlobalNotification.module.css +7 -12
- package/lib/version2/errorstate/V2_ErrorStates.module.css +5 -5
- package/lib/version2/lookup/AlertHeader/css/AlertHeaderNew.module.css +8 -23
- package/lib/version2/lookup/AlertLookup/AlertLookupNew.module.css +9 -10
- package/lib/version2/lookup/alertLookupCommonNew.module.css +6 -4
- package/lib/version2/notification/DesktopNotification/DesktopNotification.module.css +8 -11
- package/lib/version2/notification/DesktopNotificationHeader/DesktopNotificationHeader.module.css +10 -22
- package/package.json +14 -14
|
@@ -13,6 +13,7 @@ import StatusListItem from "../StatusListItem/StatusListItem";
|
|
|
13
13
|
import commonStyle from '@zohodesk/components/es/common/common.module.css';
|
|
14
14
|
import ResponsiveDropBox from '@zohodesk/components/es/ResponsiveDropBox/ResponsiveDropBox';
|
|
15
15
|
import { ResponsiveReceiver } from '@zohodesk/components/es/Responsive/CustomResponsive';
|
|
16
|
+
import Flex from '@zohodesk/layout/es/Flex/Flex';
|
|
16
17
|
import { getUniqueId } from '@zohodesk/components/es/Provider/IdProvider';
|
|
17
18
|
import btnStyle from '@zohodesk/components/es/semantic/Button/semanticButton.module.css';
|
|
18
19
|
import style from "./StatusDropdown.module.css";
|
|
@@ -30,6 +31,11 @@ export class StatusDropdown extends React.Component {
|
|
|
30
31
|
this.searchList = this.searchList.bind(this);
|
|
31
32
|
this.handleScroll = this.handleScroll.bind(this);
|
|
32
33
|
this.emptySearchSVG = this.emptySearchSVG.bind(this);
|
|
34
|
+
this.getSearchA11y = this.getSearchA11y.bind(this);
|
|
35
|
+
this.getHeadingA11y = this.getHeadingA11y.bind(this);
|
|
36
|
+
this.getListItemA11y = this.getListItemA11y.bind(this);
|
|
37
|
+
this.getTextBoxIconCustomProps = this.getTextBoxIconCustomProps.bind(this);
|
|
38
|
+
this.handleListItemClick = this.handleListItemClick.bind(this);
|
|
33
39
|
this.getAriaId = getUniqueId(this);
|
|
34
40
|
}
|
|
35
41
|
|
|
@@ -124,6 +130,44 @@ export class StatusDropdown extends React.Component {
|
|
|
124
130
|
};
|
|
125
131
|
}
|
|
126
132
|
|
|
133
|
+
getSearchA11y() {
|
|
134
|
+
return {
|
|
135
|
+
ariaHaspopup: this.props.isSearch ? 'listbox' : 'menu',
|
|
136
|
+
ariaExpanded: this.props.isPopupReady,
|
|
137
|
+
role: 'combobox',
|
|
138
|
+
ariaActivedescendant: this.props.isPopupReady ? this.props.value : '',
|
|
139
|
+
ariaOwns: this.getAriaId()
|
|
140
|
+
};
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
getHeadingA11y() {
|
|
144
|
+
return {
|
|
145
|
+
role: 'heading'
|
|
146
|
+
};
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
getListItemA11y(isActive, listItemText) {
|
|
150
|
+
return {
|
|
151
|
+
role: this.props.isSearch ? 'option' : 'menuitem',
|
|
152
|
+
ariaSelected: isActive,
|
|
153
|
+
ariaLabel: listItemText
|
|
154
|
+
};
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
getTextBoxIconCustomProps() {
|
|
158
|
+
return {
|
|
159
|
+
TextBoxProps: {
|
|
160
|
+
'data-a11y-autofocus': true
|
|
161
|
+
}
|
|
162
|
+
};
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
handleListItemClick(item) {
|
|
166
|
+
return e => {
|
|
167
|
+
this.onSelect(item, e);
|
|
168
|
+
};
|
|
169
|
+
}
|
|
170
|
+
|
|
127
171
|
render() {
|
|
128
172
|
let {
|
|
129
173
|
options
|
|
@@ -179,10 +223,12 @@ export class StatusDropdown extends React.Component {
|
|
|
179
223
|
renderTargetElement,
|
|
180
224
|
renderFooterElement,
|
|
181
225
|
a11y = {},
|
|
182
|
-
customClass
|
|
226
|
+
customClass,
|
|
227
|
+
renderSuggestedStatus
|
|
183
228
|
} = this.props;
|
|
184
229
|
const {
|
|
185
|
-
dropBoxClass = ''
|
|
230
|
+
dropBoxClass = '',
|
|
231
|
+
suggestedStatusWrapper = ''
|
|
186
232
|
} = customClass;
|
|
187
233
|
const {
|
|
188
234
|
tabIndex = 0,
|
|
@@ -195,6 +241,9 @@ export class StatusDropdown extends React.Component {
|
|
|
195
241
|
} = this.state;
|
|
196
242
|
let containerClass = `${className ? className : ''} ${isPopupReady ? activeStyle ? activeStyle : '' : showIconOnHover ? style.hoverIcon : ''} ${isDisabled ? commonStyle.disabled : isReadOnly ? style.readOnly : !isEditable ? style.cursorDefault : !showOnHover ? `${style.cursor} ${hoverStyle ? hoverStyle : ''}` : `${hoverStyle ? hoverStyle : ''} ${style.cursorDefault}`}`;
|
|
197
243
|
let ariaTitleId = this.getAriaId();
|
|
244
|
+
let textBoxA11y = this.getSearchA11y();
|
|
245
|
+
let headingA11y = this.getHeadingA11y();
|
|
246
|
+
let textBoxIconCustomProps = this.getTextBoxIconCustomProps();
|
|
198
247
|
return /*#__PURE__*/React.createElement("div", {
|
|
199
248
|
className: style.posRel,
|
|
200
249
|
onMouseEnter: showOnHover && !isDisabled && !isReadOnly && isEditable ? this.handleTogglePopup : undefined,
|
|
@@ -251,8 +300,8 @@ export class StatusDropdown extends React.Component {
|
|
|
251
300
|
isAnimate: true,
|
|
252
301
|
getRef: getContainerRef,
|
|
253
302
|
customClass: {
|
|
254
|
-
customDropBoxWrap: style.dropBoxContainer
|
|
255
|
-
customDropBox: dropBoxClass
|
|
303
|
+
customDropBoxWrap: `${style.dropBoxContainer} `,
|
|
304
|
+
customDropBox: `${dropBoxClass} ${renderSuggestedStatus ? style.dropBoxWithSuggestedStatus : ''}`
|
|
256
305
|
},
|
|
257
306
|
needResponsive: needResponsive,
|
|
258
307
|
isResponsivePadding: true,
|
|
@@ -270,81 +319,74 @@ export class StatusDropdown extends React.Component {
|
|
|
270
319
|
isFetchingOptions: isFetchingOptions
|
|
271
320
|
}
|
|
272
321
|
}
|
|
273
|
-
},
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
}
|
|
285
|
-
},
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
}
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
title: searchErrorText || 'No results',
|
|
342
|
-
description: searchEmptyHint,
|
|
343
|
-
size: "small",
|
|
344
|
-
getEmptyState: this.emptySearchSVG
|
|
345
|
-
}) : /*#__PURE__*/React.createElement("div", {
|
|
346
|
-
className: style.loader
|
|
347
|
-
}, /*#__PURE__*/React.createElement(Loader, null))), renderFooterElement ? renderFooterElement : null));
|
|
322
|
+
}, (() => {
|
|
323
|
+
const dropdownContent = /*#__PURE__*/React.createElement(React.Fragment, null, isSearch ? /*#__PURE__*/React.createElement(Box, {
|
|
324
|
+
className: style.search
|
|
325
|
+
}, /*#__PURE__*/React.createElement(TextBoxIcon, {
|
|
326
|
+
placeHolder: placeHolderText,
|
|
327
|
+
onChange: this.handleChange,
|
|
328
|
+
value: searchString,
|
|
329
|
+
onClear: this.onSearchClear,
|
|
330
|
+
size: searchBoxSize,
|
|
331
|
+
customProps: textBoxIconCustomProps,
|
|
332
|
+
a11y: textBoxA11y,
|
|
333
|
+
dataId: `${dataId}_search`
|
|
334
|
+
})) : null, title && options.length != 0 && /*#__PURE__*/React.createElement(Box, {
|
|
335
|
+
className: style.title
|
|
336
|
+
}, /*#__PURE__*/React.createElement(DropDownHeading, {
|
|
337
|
+
htmlId: ariaTitleId,
|
|
338
|
+
text: title,
|
|
339
|
+
a11y: headingA11y
|
|
340
|
+
})), /*#__PURE__*/React.createElement(Box, {
|
|
341
|
+
scroll: "vertical",
|
|
342
|
+
flexible: true,
|
|
343
|
+
shrink: true,
|
|
344
|
+
dataId: `${dataId}_list`,
|
|
345
|
+
preventParentScroll: "vertical",
|
|
346
|
+
className: `${tabletMode ? style.responsivemaxHgt : style.maxHgt}`,
|
|
347
|
+
onScroll: this.handleScroll,
|
|
348
|
+
role: isSearch ? 'listbox' : 'menu',
|
|
349
|
+
tabindex: "-1",
|
|
350
|
+
isScrollAttribute: true
|
|
351
|
+
}, options.length != 0 && isDataLoaded ? /*#__PURE__*/React.createElement(React.Fragment, null, options.map((item, i) => {
|
|
352
|
+
const listItemText = item[keyName];
|
|
353
|
+
const isActive = value === listItemText;
|
|
354
|
+
return /*#__PURE__*/React.createElement(StatusListItem, {
|
|
355
|
+
key: item[idName] || i,
|
|
356
|
+
dataId: `dataid_${i}`,
|
|
357
|
+
value: listItemText,
|
|
358
|
+
id: item[idName],
|
|
359
|
+
active: isActive,
|
|
360
|
+
onClick: this.handleListItemClick(item),
|
|
361
|
+
index: i,
|
|
362
|
+
needTick: needTick,
|
|
363
|
+
needBorder: false,
|
|
364
|
+
bulletColor: item[statusColor],
|
|
365
|
+
title: listItemText,
|
|
366
|
+
needMultiLineText: needMultiLineText,
|
|
367
|
+
autoHover: true,
|
|
368
|
+
a11y: this.getListItemA11y(isActive, listItemText)
|
|
369
|
+
});
|
|
370
|
+
}), isFetchingOptions && /*#__PURE__*/React.createElement(Container, {
|
|
371
|
+
isCover: false,
|
|
372
|
+
align: "both"
|
|
373
|
+
}, /*#__PURE__*/React.createElement(Loader, null))) : isDataLoaded ? /*#__PURE__*/React.createElement(CommonEmptyState, {
|
|
374
|
+
className: style.svgWrapper,
|
|
375
|
+
title: searchErrorText || 'No results',
|
|
376
|
+
description: searchEmptyHint,
|
|
377
|
+
size: "small",
|
|
378
|
+
getEmptyState: this.emptySearchSVG
|
|
379
|
+
}) : /*#__PURE__*/React.createElement("div", {
|
|
380
|
+
className: style.loader
|
|
381
|
+
}, /*#__PURE__*/React.createElement(Loader, null))), renderFooterElement ? renderFooterElement : null);
|
|
382
|
+
return renderSuggestedStatus ? /*#__PURE__*/React.createElement("div", {
|
|
383
|
+
className: style.dropBoxListContainer
|
|
384
|
+
}, /*#__PURE__*/React.createElement(Flex, {
|
|
385
|
+
$ui_className: `${suggestedStatusWrapper} ${style.suggestedStatusContainer}`
|
|
386
|
+
}, renderSuggestedStatus), /*#__PURE__*/React.createElement("div", {
|
|
387
|
+
className: style.dropdownOptions
|
|
388
|
+
}, dropdownContent)) : dropdownContent;
|
|
389
|
+
})());
|
|
348
390
|
}) : null);
|
|
349
391
|
}
|
|
350
392
|
|
|
@@ -1,83 +1,130 @@
|
|
|
1
1
|
.container {
|
|
2
2
|
max-width: 100% ;
|
|
3
3
|
}
|
|
4
|
+
|
|
5
|
+
.dropBoxListContainer {
|
|
6
|
+
border-radius: 7px;
|
|
7
|
+
padding: var(--zd_size10) ;
|
|
8
|
+
border: 1px solid var(--zdt_statusdropdown_wrapper_container_border);
|
|
9
|
+
background: var(--zdt_statusdropdown_wrapper_container_bg);
|
|
10
|
+
box-shadow: var(--zd_bs_statusdropdown_wrapper_container);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.dropdownOptions {
|
|
14
|
+
padding-inline: var(--zd_size1) ;
|
|
15
|
+
padding-block: var(--zd_size1) ;
|
|
16
|
+
background-color: var(--zdt_commentList_normal_bg);
|
|
17
|
+
border: 1px solid var(--zdt_statusdropdown_wrapper_container_border);
|
|
18
|
+
border-radius: 7px;
|
|
19
|
+
}
|
|
20
|
+
|
|
4
21
|
.posRel {
|
|
5
22
|
position: relative;
|
|
6
23
|
}
|
|
24
|
+
|
|
7
25
|
.maxHgt {
|
|
8
26
|
max-height: var(--zd_size265) ;
|
|
9
|
-
padding: var(--zd_size10)
|
|
27
|
+
padding-block: var(--zd_size10) ;
|
|
28
|
+
padding-inline: 0 ;
|
|
10
29
|
}
|
|
11
|
-
|
|
12
|
-
|
|
30
|
+
|
|
31
|
+
.responsivemaxHgt {
|
|
32
|
+
padding-block: var(--zd_size10) 0 ;
|
|
33
|
+
padding-inline: 0 ;
|
|
13
34
|
}
|
|
35
|
+
|
|
14
36
|
.title {
|
|
15
|
-
padding-
|
|
37
|
+
padding-block-start: var(--zd_size6) ;
|
|
16
38
|
}
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
padding: 0
|
|
39
|
+
|
|
40
|
+
.default_arrow,
|
|
41
|
+
.overlay_arrow {
|
|
42
|
+
padding-inline: var(--zd_size5) 0 ;
|
|
43
|
+
padding-block: 0 ;
|
|
22
44
|
}
|
|
45
|
+
|
|
23
46
|
.overlay_arrow {
|
|
24
47
|
position: absolute;
|
|
25
48
|
top: 50% ;
|
|
26
49
|
transform: translateY(-50%) perspective(1px);
|
|
27
50
|
}
|
|
51
|
+
|
|
28
52
|
[dir=ltr] .overlay_arrow {
|
|
29
53
|
left: 100% ;
|
|
30
54
|
}
|
|
55
|
+
|
|
31
56
|
[dir=rtl] .overlay_arrow {
|
|
32
57
|
right: 100% ;
|
|
33
58
|
}
|
|
59
|
+
|
|
34
60
|
.hoverIcon .arrow {
|
|
35
61
|
opacity: 0;
|
|
36
62
|
visibility: hidden;
|
|
37
63
|
}
|
|
64
|
+
|
|
38
65
|
.hoverIcon:hover .arrow {
|
|
39
66
|
opacity: 1;
|
|
40
67
|
visibility: visible;
|
|
41
68
|
}
|
|
69
|
+
|
|
42
70
|
.value {
|
|
43
71
|
composes: dotted from '~@zohodesk/components/es/common/common.module.css';
|
|
44
72
|
}
|
|
73
|
+
|
|
45
74
|
.search {
|
|
46
|
-
padding: var(--zd_size6)
|
|
75
|
+
padding-block: var(--zd_size6) 0 ;
|
|
76
|
+
padding-inline: var(--zd_size20) ;
|
|
47
77
|
}
|
|
78
|
+
|
|
48
79
|
.svgWrapper {
|
|
49
|
-
padding-
|
|
80
|
+
padding-block-end: var(--zd_size25) ;
|
|
50
81
|
}
|
|
82
|
+
|
|
51
83
|
.readOnly {
|
|
52
84
|
cursor: no-drop;
|
|
53
85
|
}
|
|
86
|
+
|
|
54
87
|
.cursorDefault {
|
|
55
88
|
cursor: default;
|
|
56
89
|
}
|
|
90
|
+
|
|
57
91
|
.cursor {
|
|
58
92
|
cursor: pointer;
|
|
59
93
|
}
|
|
94
|
+
|
|
60
95
|
[dir=ltr] .dropBoxContainer {
|
|
61
96
|
text-align: left;
|
|
62
97
|
}
|
|
98
|
+
|
|
63
99
|
[dir=rtl] .dropBoxContainer {
|
|
64
100
|
text-align: right;
|
|
65
101
|
}
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
[dir=rtl] .iconBox {
|
|
70
|
-
margin-left: var(--zd_size4) ;
|
|
102
|
+
|
|
103
|
+
.iconBox {
|
|
104
|
+
margin-inline-end: var(--zd_size4) ;
|
|
71
105
|
}
|
|
72
|
-
|
|
106
|
+
|
|
107
|
+
.iconBox>i {
|
|
73
108
|
display: block;
|
|
74
109
|
}
|
|
110
|
+
|
|
75
111
|
.loader {
|
|
76
112
|
width: var(--zd_size40) ;
|
|
77
113
|
margin: 0 auto ;
|
|
78
114
|
}
|
|
115
|
+
|
|
79
116
|
.seperatedLine {
|
|
80
117
|
height: var(--zd_size1) ;
|
|
118
|
+
margin-block: var(--zd_size9) var(--zd_size10) ;
|
|
119
|
+
margin-inline: 0 ;
|
|
81
120
|
border-bottom: 1px solid var(--zdt_statusdropdown_line_border);
|
|
82
|
-
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.suggestedStatusContainer {
|
|
124
|
+
margin-block-end: var(--zd_size6) ;
|
|
125
|
+
margin-inline: var(--zd_size1) ;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
.dropBoxWithSuggestedStatus {
|
|
129
|
+
border-radius: 7px;
|
|
83
130
|
}
|
|
@@ -56,6 +56,7 @@ export const propTypes = {
|
|
|
56
56
|
positionsOffset: PropTypes.object,
|
|
57
57
|
renderTargetElement: PropTypes.func,
|
|
58
58
|
renderFooterElement: PropTypes.node,
|
|
59
|
+
renderSuggestedStatus: PropTypes.node,
|
|
59
60
|
targetOffset: PropTypes.object,
|
|
60
61
|
customClass: PropTypes.shape({
|
|
61
62
|
dropBoxClass: PropTypes.string
|
|
@@ -19,24 +19,19 @@
|
|
|
19
19
|
[dir=rtl] .withBorder {
|
|
20
20
|
border-right: 1px solid var(--zdt_statuslistitem_default_border);
|
|
21
21
|
}
|
|
22
|
-
|
|
23
|
-
padding: var(--zd_size7)
|
|
24
|
-
|
|
25
|
-
[dir=rtl] .small {
|
|
26
|
-
padding: var(--zd_size7) var(--zd_size5) var(--zd_size7) var(--zd_size3) ;
|
|
22
|
+
.small {
|
|
23
|
+
padding-block: var(--zd_size7) ;
|
|
24
|
+
padding-inline:var(--zd_size3) var(--zd_size5) ;
|
|
27
25
|
}
|
|
28
26
|
.medium {
|
|
29
|
-
padding: var(--zd_size7)
|
|
27
|
+
padding-block: var(--zd_size7) ;
|
|
28
|
+
padding-inline:var(--zd_size20) ;
|
|
30
29
|
}
|
|
31
30
|
.large {
|
|
31
|
+
padding-block: var(--zd_size10) ;
|
|
32
|
+
padding-inline:var(--zd_size25) var(--zd_size3) ;
|
|
32
33
|
--statuslistitem_min_height: var(--zd_size48);
|
|
33
34
|
}
|
|
34
|
-
[dir=ltr] .large {
|
|
35
|
-
padding: var(--zd_size10) var(--zd_size3) var(--zd_size10) var(--zd_size25) ;
|
|
36
|
-
}
|
|
37
|
-
[dir=rtl] .large {
|
|
38
|
-
padding: var(--zd_size10) var(--zd_size25) var(--zd_size10) var(--zd_size3) ;
|
|
39
|
-
}
|
|
40
35
|
.value,.multiLineValue {
|
|
41
36
|
line-height: 1.5385;
|
|
42
37
|
}
|
|
@@ -88,11 +83,8 @@
|
|
|
88
83
|
.tickIcon > i {
|
|
89
84
|
display: block;
|
|
90
85
|
}
|
|
91
|
-
|
|
92
|
-
padding-
|
|
93
|
-
}
|
|
94
|
-
[dir=rtl] .active.withTick {
|
|
95
|
-
padding-left: var(--zd_size39) ;
|
|
86
|
+
.active.withTick {
|
|
87
|
+
padding-inline-end: var(--zd_size39) ;
|
|
96
88
|
}
|
|
97
89
|
.contentWrapper {
|
|
98
90
|
composes: dflex flexrow alignVertical from '~@zohodesk/components/es/common/common.module.css';
|
|
@@ -129,4 +121,4 @@
|
|
|
129
121
|
}
|
|
130
122
|
.green.statusType::after {
|
|
131
123
|
background-color: var(--zdt_statuslistitem_green_bg);
|
|
132
|
-
}
|
|
124
|
+
}
|
|
@@ -3,12 +3,13 @@
|
|
|
3
3
|
}
|
|
4
4
|
|
|
5
5
|
.image {
|
|
6
|
-
margin: var(--zd_size20)
|
|
6
|
+
margin-block: var(--zd_size20) ;
|
|
7
|
+
margin-inline:auto ;
|
|
7
8
|
}
|
|
8
9
|
|
|
9
10
|
.contentDiv {
|
|
10
11
|
font-size: var(--zd_font_size20) ;
|
|
11
12
|
font-weight: var(--zd-fw-semibold);
|
|
12
13
|
composes: ftsmooth from '~@zohodesk/components/es/common/common.module.css';
|
|
13
|
-
margin-
|
|
14
|
-
}
|
|
14
|
+
margin-block-start: var(--zd_size15) ;
|
|
15
|
+
}
|
|
@@ -26,38 +26,25 @@
|
|
|
26
26
|
.drpSearchBox {
|
|
27
27
|
position: relative;
|
|
28
28
|
height: var(--zd_size28) ;
|
|
29
|
+
padding-inline-start: var(--zd_size12) ;
|
|
29
30
|
cursor: pointer;
|
|
30
31
|
}
|
|
31
|
-
|
|
32
|
-
padding-
|
|
32
|
+
.searchIcon {
|
|
33
|
+
padding-inline-end: var(--zd_size8) ;
|
|
33
34
|
}
|
|
34
|
-
|
|
35
|
-
padding-
|
|
36
|
-
}
|
|
37
|
-
[dir=ltr] .searchIcon {
|
|
38
|
-
padding-right: var(--zd_size8) ;
|
|
39
|
-
}
|
|
40
|
-
[dir=rtl] .searchIcon {
|
|
41
|
-
padding-left: var(--zd_size8) ;
|
|
42
|
-
}
|
|
43
|
-
[dir=ltr] .searchIconBox {
|
|
44
|
-
padding-left: var(--zd_size12) ;
|
|
45
|
-
}
|
|
46
|
-
[dir=rtl] .searchIconBox {
|
|
47
|
-
padding-right: var(--zd_size12) ;
|
|
35
|
+
.searchIconBox {
|
|
36
|
+
padding-inline-start: var(--zd_size12) ;
|
|
48
37
|
}
|
|
49
38
|
.active, .boxStyle.active, .lineActive.drpSearchBox::after {
|
|
50
39
|
border-color: var(--zdt_lookupsearch_boxstyle_activer_border);
|
|
51
40
|
}
|
|
52
|
-
|
|
53
|
-
margin-
|
|
54
|
-
}
|
|
55
|
-
[dir=rtl] .iconArrow {
|
|
56
|
-
margin-right: var(--zd_size6) ;
|
|
41
|
+
.iconArrow {
|
|
42
|
+
margin-inline-start: var(--zd_size6) ;
|
|
57
43
|
}
|
|
58
44
|
.separator {
|
|
59
45
|
width: var(--zd_size1) ;
|
|
60
46
|
height: var(--zd_size16) ;
|
|
61
|
-
margin:
|
|
47
|
+
margin-inline: var(--zd_size12) ;
|
|
48
|
+
margin-block:0 ;
|
|
62
49
|
background-color: var(--zdt_lookupsearch_boxstyle_border);
|
|
63
|
-
}
|
|
50
|
+
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
.dropdown {
|
|
2
|
-
margin:
|
|
2
|
+
margin-inline: var(--zd_size20) ;
|
|
3
|
+
margin-block:0 ;
|
|
3
4
|
}
|
|
4
5
|
/* Responsive */
|
|
5
6
|
[dir=ltr] .small .searchContainer {
|
|
@@ -20,4 +21,4 @@
|
|
|
20
21
|
.extraSmall .container {
|
|
21
22
|
flex-direction: column;
|
|
22
23
|
}
|
|
23
|
-
.menuWrapper{display: inline-block;}
|
|
24
|
+
.menuWrapper{display: inline-block;}
|
|
@@ -12,10 +12,11 @@
|
|
|
12
12
|
|
|
13
13
|
.emptyState {
|
|
14
14
|
font-size: var(--zd_font_size14) ;
|
|
15
|
+
padding-block: var(--zd_size12) ;
|
|
16
|
+
padding-inline:var(--zd_size15) ;
|
|
15
17
|
color: var(--zdt_viewdropdown_empty_text);
|
|
16
18
|
font-weight: var(--zd-fw-semibold);
|
|
17
19
|
composes: ftsmooth from '~@zohodesk/components/es/common/common.module.css';
|
|
18
|
-
padding: var(--zd_size12) var(--zd_size15) ;
|
|
19
20
|
}
|
|
20
21
|
|
|
21
22
|
.hide {
|
|
@@ -27,7 +28,8 @@
|
|
|
27
28
|
}
|
|
28
29
|
|
|
29
30
|
.listItemContainer {
|
|
30
|
-
padding: var(--zd_size10)
|
|
31
|
+
padding-block: var(--zd_size10) ;
|
|
32
|
+
padding-inline:0 ;
|
|
31
33
|
}
|
|
32
34
|
|
|
33
35
|
/* Label Style */
|
|
@@ -40,22 +42,16 @@
|
|
|
40
42
|
|
|
41
43
|
.labelText {
|
|
42
44
|
font-size: var(--zd_font_size12) ;
|
|
45
|
+
margin-inline-end: var(--zd_size5) ;
|
|
43
46
|
max-width: var(--zd_size180) ;
|
|
44
47
|
composes: dotted from '~@zohodesk/components/es/common/common.module.css';
|
|
45
48
|
}
|
|
46
49
|
|
|
47
|
-
[dir=ltr] .labelText {
|
|
48
|
-
margin-right: var(--zd_size5) ;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
[dir=rtl] .labelText {
|
|
52
|
-
margin-left: var(--zd_size5) ;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
50
|
.labelCnt:hover .arrowIcon {
|
|
56
51
|
color: var(--zdt_viewdropdown_hover_label_text);
|
|
57
52
|
}
|
|
58
53
|
|
|
59
54
|
.loader {
|
|
60
|
-
padding: var(--zd_size12)
|
|
61
|
-
|
|
55
|
+
padding-block: var(--zd_size12) ;
|
|
56
|
+
padding-inline:var(--zd_size15) ;
|
|
57
|
+
}
|
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
.container {
|
|
2
2
|
min-height: var(--zd_size51) ;
|
|
3
3
|
position: relative;
|
|
4
|
-
|
|
5
|
-
padding:
|
|
6
|
-
}[dir=rtl] .container {
|
|
7
|
-
padding: 0 var(--zd_size10) 0 var(--zd_size30) ;
|
|
4
|
+
padding-inline:var(--zd_size10) var(--zd_size30) ;
|
|
5
|
+
padding-block:0 ;
|
|
8
6
|
}
|
|
9
7
|
.default {
|
|
10
8
|
background-color: var(--zdt_lookupheader_default_bg);
|
|
@@ -14,8 +12,10 @@
|
|
|
14
12
|
background-color: var(--zdt_lookupheader_white_bg);
|
|
15
13
|
border-bottom: solid 1px var(--zdt_lookupheader_white_border);
|
|
16
14
|
}
|
|
17
|
-
.searchContainer,
|
|
18
|
-
|
|
15
|
+
.searchContainer,
|
|
16
|
+
.title {
|
|
17
|
+
margin-inline: var(--zd_size20) ;
|
|
18
|
+
margin-block:0 ;
|
|
19
19
|
}
|
|
20
20
|
[dir=ltr] .searchContainer {
|
|
21
21
|
text-align: right;
|
|
@@ -30,7 +30,8 @@
|
|
|
30
30
|
composes: middleY from '~@zohodesk/components/es/common/common.module.css'; */
|
|
31
31
|
}
|
|
32
32
|
.para {
|
|
33
|
+
margin-inline: var(--zd_size20) ;
|
|
34
|
+
margin-block:0 ;
|
|
33
35
|
font-size: var(--zd_font_size12) ;
|
|
34
36
|
color: var(--zdt_lookupheader_para_text);
|
|
35
|
-
margin: 0 var(--zd_size20) ;
|
|
36
37
|
}
|
|
@@ -1,15 +1,11 @@
|
|
|
1
1
|
/* Responsive */
|
|
2
2
|
.extraSmall {
|
|
3
|
+
padding-block: var(--zd_size12) ;
|
|
4
|
+
padding-inline:0 var(--zd_size45) ;
|
|
3
5
|
justify-content: normal;
|
|
4
6
|
flex-direction: column;
|
|
5
7
|
align-items: flex-start;
|
|
6
8
|
}
|
|
7
|
-
[dir=ltr] .extraSmall {
|
|
8
|
-
padding: var(--zd_size12) var(--zd_size45) var(--zd_size12) 0 ;
|
|
9
|
-
}
|
|
10
|
-
[dir=rtl] .extraSmall {
|
|
11
|
-
padding: var(--zd_size12) 0 var(--zd_size12) var(--zd_size45) ;
|
|
12
|
-
}
|
|
13
9
|
|
|
14
10
|
[dir=ltr] .extraSmall .searchContainer {
|
|
15
11
|
text-align: left;
|