@zohodesk/components 1.0.0-temp-219 → 1.0.0-temp-199.6
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/.cli/propValidation_report.html +1 -1
- package/es/Button/Button.js +2 -10
- package/es/ListItem/ListItem.js +2 -2
- package/es/ListItem/ListItem.module.css +85 -18
- package/es/ListItem/ListItemWithAvatar.js +3 -3
- package/es/ListItem/ListItemWithIcon.js +2 -2
- package/es/MultiSelect/AdvancedGroupMultiSelect.js +7 -2
- package/es/MultiSelect/AdvancedMultiSelect.js +2 -1
- package/es/MultiSelect/MultiSelect.js +7 -2
- package/es/MultiSelect/Suggestions.js +8 -4
- package/es/MultiSelect/props/defaultProps.js +6 -4
- package/es/MultiSelect/props/propTypes.js +6 -3
- package/es/Select/GroupSelect.js +5 -1
- package/es/Select/Select.js +1 -4
- package/es/Select/SelectWithAvatar.js +7 -2
- package/es/Select/SelectWithIcon.js +4 -2
- package/es/Select/props/defaultProps.js +2 -1
- package/es/Select/props/propTypes.js +4 -2
- package/es/Switch/Switch.js +2 -11
- package/es/TextBox/TextBox.js +2 -9
- package/es/v1/ListItem/ListItem.js +1 -1
- package/es/v1/MultiSelect/AdvancedMultiSelect.js +2 -1
- package/es/v1/MultiSelect/MultiSelect.js +7 -2
- package/es/v1/MultiSelect/Suggestions.js +8 -4
- package/es/v1/MultiSelect/props/defaultProps.js +4 -2
- package/es/v1/MultiSelect/props/propTypes.js +6 -2
- package/es/v1/Select/GroupSelect.js +7 -2
- package/es/v1/Select/SelectWithAvatar.js +7 -2
- package/es/v1/Select/props/defaultProps.js +4 -2
- package/es/v1/Select/props/propTypes.js +6 -2
- package/lib/Button/Button.js +2 -12
- package/lib/ListItem/ListItem.js +2 -2
- package/lib/ListItem/ListItem.module.css +85 -18
- package/lib/ListItem/ListItemWithAvatar.js +3 -3
- package/lib/ListItem/ListItemWithIcon.js +2 -2
- package/lib/MultiSelect/AdvancedGroupMultiSelect.js +7 -3
- package/lib/MultiSelect/AdvancedMultiSelect.js +3 -1
- package/lib/MultiSelect/MultiSelect.js +6 -3
- package/lib/MultiSelect/Suggestions.js +8 -4
- package/lib/MultiSelect/props/defaultProps.js +6 -4
- package/lib/MultiSelect/props/propTypes.js +5 -3
- package/lib/Select/GroupSelect.js +4 -2
- package/lib/Select/Select.js +1 -7
- package/lib/Select/SelectWithAvatar.js +8 -3
- package/lib/Select/SelectWithIcon.js +5 -3
- package/lib/Select/props/defaultProps.js +2 -1
- package/lib/Select/props/propTypes.js +4 -2
- package/lib/Switch/Switch.js +2 -11
- package/lib/TextBox/TextBox.js +2 -9
- package/lib/v1/ListItem/ListItem.js +1 -1
- package/lib/v1/MultiSelect/AdvancedMultiSelect.js +3 -1
- package/lib/v1/MultiSelect/MultiSelect.js +8 -3
- package/lib/v1/MultiSelect/Suggestions.js +8 -4
- package/lib/v1/MultiSelect/props/defaultProps.js +4 -2
- package/lib/v1/MultiSelect/props/propTypes.js +6 -2
- package/lib/v1/Select/GroupSelect.js +8 -3
- package/lib/v1/Select/SelectWithAvatar.js +8 -3
- package/lib/v1/Select/props/defaultProps.js +4 -2
- package/lib/v1/Select/props/propTypes.js +6 -2
- package/package.json +3 -5
- package/result.json +1 -1
package/es/TextBox/TextBox.js
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { defaultProps } from "./props/defaultProps";
|
|
3
3
|
import { propTypes } from "./props/propTypes";
|
|
4
|
-
import { ComponentCustomizer } from '@zohodesk/dotkit/es/react/components/ComponentCustomizer';
|
|
5
4
|
/* eslint css-modules/no-unused-class: [2, { markAsUsed: ['xmedium', 'medium', 'small', 'default', 'primary', 'secondary'] }] */
|
|
6
5
|
|
|
7
6
|
import style from "./TextBox.module.css";
|
|
8
|
-
|
|
9
|
-
class TextBox extends React.PureComponent {
|
|
7
|
+
export default class TextBox extends React.PureComponent {
|
|
10
8
|
constructor(props) {
|
|
11
9
|
super(props);
|
|
12
10
|
this.onChange = this.onChange.bind(this);
|
|
@@ -180,7 +178,6 @@ class TextBox extends React.PureComponent {
|
|
|
180
178
|
}
|
|
181
179
|
|
|
182
180
|
}
|
|
183
|
-
|
|
184
181
|
TextBox.defaultProps = defaultProps;
|
|
185
182
|
TextBox.propTypes = propTypes; // if (__DOCS__) {
|
|
186
183
|
// Textbox.docs = {
|
|
@@ -189,8 +186,4 @@ TextBox.propTypes = propTypes; // if (__DOCS__) {
|
|
|
189
186
|
// external: true,
|
|
190
187
|
// description: ' '
|
|
191
188
|
// };
|
|
192
|
-
// }
|
|
193
|
-
|
|
194
|
-
export default ComponentCustomizer(TextBox, {
|
|
195
|
-
name: 'TextBox'
|
|
196
|
-
});
|
|
189
|
+
// }
|
|
@@ -81,7 +81,7 @@ const ListItem = props => {
|
|
|
81
81
|
autoHover: autoHover,
|
|
82
82
|
needTick: needTick,
|
|
83
83
|
needBorder: needBorder,
|
|
84
|
-
customClass: customListItem
|
|
84
|
+
customClass: `${customListItem} ${needMultiLineText ? style.txtAlignBaseLine + ' ' + style.autoHeight : ''} ${customListItem}`,
|
|
85
85
|
dataId: dataIdString,
|
|
86
86
|
dataSelectorId: `${dataSelectorId}`,
|
|
87
87
|
isLink: isLink,
|
|
@@ -549,7 +549,8 @@ export class AdvancedMultiSelectComponent extends MultiSelectComponent {
|
|
|
549
549
|
role: 'option'
|
|
550
550
|
},
|
|
551
551
|
dataId: `${dataIdMultiSelectComp}_Options`,
|
|
552
|
-
...SuggestionsProps
|
|
552
|
+
...SuggestionsProps,
|
|
553
|
+
needMultiLineText: true
|
|
553
554
|
}) : /*#__PURE__*/React.createElement(EmptyState, {
|
|
554
555
|
isLoading: isFetchingOptions,
|
|
555
556
|
options: options,
|
|
@@ -1002,8 +1002,12 @@ export class MultiSelectComponent extends React.Component {
|
|
|
1002
1002
|
boxSize,
|
|
1003
1003
|
isLoading,
|
|
1004
1004
|
selectAllText,
|
|
1005
|
-
needSelectAll
|
|
1005
|
+
needSelectAll,
|
|
1006
|
+
customProps
|
|
1006
1007
|
} = this.props;
|
|
1008
|
+
const {
|
|
1009
|
+
suggestionsProps = {}
|
|
1010
|
+
} = customProps;
|
|
1007
1011
|
const {
|
|
1008
1012
|
selectedOptions,
|
|
1009
1013
|
searchStr,
|
|
@@ -1093,7 +1097,8 @@ export class MultiSelectComponent extends React.Component {
|
|
|
1093
1097
|
selectedOptions: selectedOptionIds,
|
|
1094
1098
|
a11y: {
|
|
1095
1099
|
role: 'option'
|
|
1096
|
-
}
|
|
1100
|
+
},
|
|
1101
|
+
...suggestionsProps
|
|
1097
1102
|
}) : /*#__PURE__*/React.createElement(EmptyState, {
|
|
1098
1103
|
isLoading: isFetchingOptions,
|
|
1099
1104
|
options: options,
|
|
@@ -27,7 +27,8 @@ export default class Suggestions extends React.PureComponent {
|
|
|
27
27
|
avatarPalette,
|
|
28
28
|
palette,
|
|
29
29
|
htmlId,
|
|
30
|
-
a11y
|
|
30
|
+
a11y,
|
|
31
|
+
needMultiLineText
|
|
31
32
|
} = this.props;
|
|
32
33
|
const {
|
|
33
34
|
ariaParentRole,
|
|
@@ -92,7 +93,8 @@ export default class Suggestions extends React.PureComponent {
|
|
|
92
93
|
size: listItemSize,
|
|
93
94
|
avatarPalette: avatarPalette,
|
|
94
95
|
palette: palette,
|
|
95
|
-
a11y: list_a11y
|
|
96
|
+
a11y: list_a11y,
|
|
97
|
+
needMultiLineText: needMultiLineText
|
|
96
98
|
});
|
|
97
99
|
} else if (optionType === 'icon') {
|
|
98
100
|
return /*#__PURE__*/React.createElement(ListItemWithIcon, { ...commonProps,
|
|
@@ -112,7 +114,8 @@ export default class Suggestions extends React.PureComponent {
|
|
|
112
114
|
iconSize: iconSize,
|
|
113
115
|
size: listItemSize,
|
|
114
116
|
palette: palette,
|
|
115
|
-
a11y: list_a11y
|
|
117
|
+
a11y: list_a11y,
|
|
118
|
+
needMultiLineText: needMultiLineText
|
|
116
119
|
});
|
|
117
120
|
}
|
|
118
121
|
|
|
@@ -131,7 +134,8 @@ export default class Suggestions extends React.PureComponent {
|
|
|
131
134
|
active: isActive,
|
|
132
135
|
size: listItemSize,
|
|
133
136
|
palette: palette,
|
|
134
|
-
a11y: list_a11y
|
|
137
|
+
a11y: list_a11y,
|
|
138
|
+
needMultiLineText: needMultiLineText
|
|
135
139
|
});
|
|
136
140
|
})));
|
|
137
141
|
}
|
|
@@ -117,7 +117,8 @@ export const MultiSelect_defaultProps = {
|
|
|
117
117
|
keepSelectedOptions: false,
|
|
118
118
|
selectedOptionsCount: 0,
|
|
119
119
|
cardHeaderName: '',
|
|
120
|
-
needResponsive: true
|
|
120
|
+
needResponsive: true,
|
|
121
|
+
customProps: {}
|
|
121
122
|
};
|
|
122
123
|
export const MultiSelectHeader_defaultProps = {
|
|
123
124
|
dataId: 'MultiSelectHeader'
|
|
@@ -161,5 +162,6 @@ export const SelectedOptions_defaultProps = {
|
|
|
161
162
|
dataId: 'selectedOptions'
|
|
162
163
|
};
|
|
163
164
|
export const Suggestions_defaultProps = {
|
|
164
|
-
a11y: {}
|
|
165
|
+
a11y: {},
|
|
166
|
+
needMultiLineText: false
|
|
165
167
|
};
|
|
@@ -108,7 +108,10 @@ export const MultiSelect_propTypes = {
|
|
|
108
108
|
needSelectAll: PropTypes.bool,
|
|
109
109
|
selectAllText: PropTypes.string,
|
|
110
110
|
setAriaId: PropTypes.string,
|
|
111
|
-
ariaErrorId: PropTypes.string
|
|
111
|
+
ariaErrorId: PropTypes.string,
|
|
112
|
+
customProps: {
|
|
113
|
+
suggestionsProps: PropTypes.object
|
|
114
|
+
}
|
|
112
115
|
};
|
|
113
116
|
export const MultiSelectHeader_propTypes = {
|
|
114
117
|
dataId: PropTypes.string,
|
|
@@ -173,7 +176,8 @@ export const Suggestions_propTypes = {
|
|
|
173
176
|
logo: PropTypes.string,
|
|
174
177
|
optionType: PropTypes.string,
|
|
175
178
|
listItemProps: PropTypes.object
|
|
176
|
-
}))
|
|
179
|
+
})),
|
|
180
|
+
needMultiLineText: PropTypes.bool
|
|
177
181
|
};
|
|
178
182
|
export const AdvancedGroupMultiSelect_propTypes = {
|
|
179
183
|
animationStyle: PropTypes.string,
|
|
@@ -590,8 +590,12 @@ export class GroupSelectComponent extends PureComponent {
|
|
|
590
590
|
htmlId,
|
|
591
591
|
iconOnHover,
|
|
592
592
|
isLoading,
|
|
593
|
-
dataSelectorId
|
|
593
|
+
dataSelectorId,
|
|
594
|
+
customProps
|
|
594
595
|
} = this.props;
|
|
596
|
+
const {
|
|
597
|
+
suggestionsProps = {}
|
|
598
|
+
} = customProps;
|
|
595
599
|
i18nKeys = Object.assign({}, i18nKeys, {
|
|
596
600
|
emptyText: i18nKeys.emptyText || emptyMessage,
|
|
597
601
|
searchEmptyText: i18nKeys.searchEmptyText || searchEmptyMessage
|
|
@@ -784,7 +788,8 @@ export class GroupSelectComponent extends PureComponent {
|
|
|
784
788
|
ariaParentRole: 'listbox',
|
|
785
789
|
role: 'option'
|
|
786
790
|
},
|
|
787
|
-
dataId: `${dataId}_Options
|
|
791
|
+
dataId: `${dataId}_Options`,
|
|
792
|
+
...suggestionsProps
|
|
788
793
|
}));
|
|
789
794
|
}) : /*#__PURE__*/React.createElement(EmptyState, {
|
|
790
795
|
options: revampedGroups,
|
|
@@ -163,8 +163,12 @@ class SelectWithAvatarComponent extends SelectComponent {
|
|
|
163
163
|
needEffect,
|
|
164
164
|
isLoading,
|
|
165
165
|
dataSelectorId,
|
|
166
|
-
getTargetRef
|
|
166
|
+
getTargetRef,
|
|
167
|
+
customProps
|
|
167
168
|
} = this.props;
|
|
169
|
+
const {
|
|
170
|
+
suggestionsProps = {}
|
|
171
|
+
} = customProps;
|
|
168
172
|
i18nKeys = Object.assign({}, i18nKeys, {
|
|
169
173
|
emptyText: i18nKeys.emptyText || emptyMessage,
|
|
170
174
|
searchEmptyText: i18nKeys.searchEmptyText || searchEmptyMessage
|
|
@@ -321,7 +325,8 @@ class SelectWithAvatarComponent extends SelectComponent {
|
|
|
321
325
|
a11y: {
|
|
322
326
|
ariaParentRole: 'listbox',
|
|
323
327
|
role: 'option'
|
|
324
|
-
}
|
|
328
|
+
},
|
|
329
|
+
...suggestionsProps
|
|
325
330
|
}) : /*#__PURE__*/React.createElement(EmptyState, {
|
|
326
331
|
isLoading: isFetchingOptions,
|
|
327
332
|
options: options,
|
|
@@ -69,7 +69,8 @@ export const GroupSelect_defaultProps = {
|
|
|
69
69
|
isRestrictScroll: false,
|
|
70
70
|
i18nKeys: {},
|
|
71
71
|
iconOnHover: false,
|
|
72
|
-
isLoading: false
|
|
72
|
+
isLoading: false,
|
|
73
|
+
customProps: {}
|
|
73
74
|
};
|
|
74
75
|
export const SelectWithAvatar_defaultProps = {
|
|
75
76
|
animationStyle: 'bounce',
|
|
@@ -95,7 +96,8 @@ export const SelectWithAvatar_defaultProps = {
|
|
|
95
96
|
isRestrictScroll: false,
|
|
96
97
|
i18nKeys: {},
|
|
97
98
|
needEffect: true,
|
|
98
|
-
isLoading: false
|
|
99
|
+
isLoading: false,
|
|
100
|
+
customProps: {}
|
|
99
101
|
};
|
|
100
102
|
export const SelectWithIcon_defaultProps = {
|
|
101
103
|
isReadOnly: false,
|
|
@@ -174,7 +174,10 @@ export const GroupSelect_propTypes = {
|
|
|
174
174
|
}),
|
|
175
175
|
isLoading: PropTypes.bool,
|
|
176
176
|
dataSelectorId: PropTypes.string,
|
|
177
|
-
isDefaultSelectValue: PropTypes.bool
|
|
177
|
+
isDefaultSelectValue: PropTypes.bool,
|
|
178
|
+
customProps: PropTypes.shape({
|
|
179
|
+
suggestionsProps: PropTypes.object
|
|
180
|
+
})
|
|
178
181
|
};
|
|
179
182
|
export const SelectWithAvatar_propTypes = { ...Select_propTypes,
|
|
180
183
|
textBoxClass: PropTypes.string,
|
|
@@ -235,7 +238,8 @@ export const SelectWithAvatar_propTypes = { ...Select_propTypes,
|
|
|
235
238
|
htmlId: PropTypes.string,
|
|
236
239
|
needEffect: PropTypes.bool,
|
|
237
240
|
isLoading: PropTypes.bool,
|
|
238
|
-
dataSelectorId: PropTypes.string
|
|
241
|
+
dataSelectorId: PropTypes.string,
|
|
242
|
+
customProps: PropTypes.object
|
|
239
243
|
};
|
|
240
244
|
export const SelectWithIcon_propTypes = {
|
|
241
245
|
animationStyle: PropTypes.oneOf(['default', 'bounce']),
|
package/lib/Button/Button.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports["default"] =
|
|
6
|
+
exports["default"] = Button;
|
|
7
7
|
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
|
|
@@ -11,8 +11,6 @@ var _defaultProps = require("./props/defaultProps");
|
|
|
11
11
|
|
|
12
12
|
var _propTypes = require("./props/propTypes");
|
|
13
13
|
|
|
14
|
-
var _ComponentCustomizer = require("@zohodesk/dotkit/es/react/components/ComponentCustomizer");
|
|
15
|
-
|
|
16
14
|
var _cssJSLogic2 = _interopRequireDefault(require("./css/cssJSLogic"));
|
|
17
15
|
|
|
18
16
|
var _utils = require("@zohodesk/utils");
|
|
@@ -83,12 +81,4 @@ Button.propTypes = _propTypes.propTypes; // if (__DOCS__) {
|
|
|
83
81
|
// componentGroup: 'Form Elements',
|
|
84
82
|
// folderName: 'Style Guide'
|
|
85
83
|
// };
|
|
86
|
-
// }
|
|
87
|
-
|
|
88
|
-
var _default = (0, _ComponentCustomizer.ComponentCustomizer)(Button, {
|
|
89
|
-
name: 'Button',
|
|
90
|
-
type: _ComponentCustomizer.PROP_CUSTOMIZE_TYPE.excludedProps,
|
|
91
|
-
props: ['text', 'children']
|
|
92
|
-
});
|
|
93
|
-
|
|
94
|
-
exports["default"] = _default;
|
|
84
|
+
// }
|
package/lib/ListItem/ListItem.js
CHANGED
|
@@ -150,7 +150,7 @@ var ListItem = /*#__PURE__*/function (_React$Component) {
|
|
|
150
150
|
autoHover: autoHover,
|
|
151
151
|
needTick: needTick,
|
|
152
152
|
needBorder: needBorder,
|
|
153
|
-
customClass: customListItem,
|
|
153
|
+
customClass: "".concat(needMultiLineText ? _ListItemModule["default"].txtAlignBaseLine + ' ' + _ListItemModule["default"].autoHeight : '', " ").concat(customListItem),
|
|
154
154
|
dataId: dataIdString,
|
|
155
155
|
dataSelectorId: "".concat(dataSelectorId),
|
|
156
156
|
isLink: isLink,
|
|
@@ -171,7 +171,7 @@ var ListItem = /*#__PURE__*/function (_React$Component) {
|
|
|
171
171
|
adjust: true,
|
|
172
172
|
className: _ListItemModule["default"].children
|
|
173
173
|
}, children) : null, needTick && active ? /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
174
|
-
className: "".concat(_ListItemModule["default"].tickIcon, " ").concat(tickIconPalette, " ").concat(customTickIcon),
|
|
174
|
+
className: "".concat(_ListItemModule["default"].tickIcon, " ").concat(tickIconPalette, " ").concat(customTickIcon, " ").concat(needMultiLineText ? _ListItemModule["default"].tickIconCenter : ''),
|
|
175
175
|
"aria-hidden": ariaHidden,
|
|
176
176
|
dataId: "".concat(dataIdString, "_tickIcon"),
|
|
177
177
|
dataSelectorId: "".concat(dataSelectorId, "_tickIcon")
|
|
@@ -17,8 +17,9 @@
|
|
|
17
17
|
}[dir=ltr] .varClass {
|
|
18
18
|
--listitem_avatar_margin: 0 var(--zd_size15) 0 0;
|
|
19
19
|
}[dir=rtl] .varClass {
|
|
20
|
-
--listitem_avatar_margin: 0
|
|
20
|
+
--listitem_avatar_margin: 0 var(--zd_size15) 0 0;
|
|
21
21
|
}
|
|
22
|
+
|
|
22
23
|
.list {
|
|
23
24
|
composes: varClass;
|
|
24
25
|
position: relative;
|
|
@@ -34,62 +35,84 @@
|
|
|
34
35
|
border-color: var(--listitem_border_color);
|
|
35
36
|
cursor: pointer;
|
|
36
37
|
}
|
|
38
|
+
|
|
37
39
|
.list, .default, .secondary {
|
|
38
40
|
background-color: var(--listitem_bg_color);
|
|
39
41
|
}
|
|
42
|
+
|
|
40
43
|
[dir=ltr] .withBorder {
|
|
41
|
-
--listitem_border_width: 0 0 0 1px
|
|
44
|
+
--listitem_border_width: 0 0 0 1px
|
|
45
|
+
/*rtl: 0 1px 0 0*/
|
|
46
|
+
;
|
|
42
47
|
}
|
|
48
|
+
|
|
43
49
|
[dir=rtl] .withBorder {
|
|
44
|
-
--listitem_border_width: 0
|
|
50
|
+
--listitem_border_width: 0 0 0 1px ;
|
|
45
51
|
}
|
|
52
|
+
|
|
46
53
|
.active {
|
|
47
54
|
--listitem_border_color: var(--zdt_listitem_active_border);
|
|
48
55
|
}
|
|
56
|
+
|
|
49
57
|
[dir=ltr] .small {
|
|
50
58
|
--listitem_padding: var(--zd_size7) var(--zd_size3) var(--zd_size7) var(--zd_size5);
|
|
51
59
|
}
|
|
60
|
+
|
|
52
61
|
[dir=rtl] .small {
|
|
53
|
-
--listitem_padding: var(--zd_size7) var(--
|
|
62
|
+
--listitem_padding: var(--zd_size7) var(--zd_size3) var(--zd_size7) var(--zd_size5);
|
|
54
63
|
}
|
|
64
|
+
|
|
55
65
|
.medium {
|
|
56
66
|
--listitem_padding: var(--zd_size7) var(--zd_size20);
|
|
57
67
|
--listitem_min_height: var(--zd_size35);
|
|
58
68
|
}
|
|
69
|
+
|
|
59
70
|
.large {
|
|
60
71
|
--listitem_height: var(--zd_size48);
|
|
61
72
|
}
|
|
73
|
+
|
|
62
74
|
[dir=ltr] .large {
|
|
63
75
|
--listitem_padding: var(--zd_size10) var(--zd_size3) var(--zd_size10) var(--zd_size25);
|
|
64
76
|
}
|
|
77
|
+
|
|
65
78
|
[dir=rtl] .large {
|
|
66
|
-
--listitem_padding: var(--zd_size10) var(--
|
|
79
|
+
--listitem_padding: var(--zd_size10) var(--zd_size3) var(--zd_size10) var(--zd_size25);
|
|
67
80
|
}
|
|
81
|
+
|
|
68
82
|
.value,
|
|
69
83
|
.children {
|
|
70
84
|
composes: dotted from '../common/common.module.css';
|
|
71
85
|
}
|
|
72
|
-
|
|
86
|
+
|
|
87
|
+
.value {
|
|
73
88
|
line-height: 1.5385;
|
|
74
89
|
}
|
|
75
|
-
|
|
90
|
+
|
|
91
|
+
.multiLineValue {
|
|
92
|
+
line-height: 1.5385;
|
|
76
93
|
word-break: break-word;
|
|
77
|
-
|
|
94
|
+
-webkit-line-clamp: 3;
|
|
95
|
+
composes: clamp from '../common/common.module.css';
|
|
78
96
|
}
|
|
97
|
+
|
|
79
98
|
.iconBox {
|
|
80
99
|
width: var(--zd_size20) ;
|
|
81
100
|
text-align: center;
|
|
82
101
|
}
|
|
102
|
+
|
|
83
103
|
[dir=ltr] .iconBox {
|
|
84
104
|
margin-right: var(--zd_size10) ;
|
|
85
105
|
}
|
|
106
|
+
|
|
86
107
|
[dir=rtl] .iconBox {
|
|
87
108
|
margin-left: var(--zd_size10) ;
|
|
88
109
|
}
|
|
110
|
+
|
|
89
111
|
.iconBox,
|
|
90
112
|
.leftAvatar {
|
|
91
113
|
font-size: 0 ;
|
|
92
114
|
}
|
|
115
|
+
|
|
93
116
|
.leftAvatar {
|
|
94
117
|
margin: var(--listitem_avatar_margin);
|
|
95
118
|
}
|
|
@@ -97,61 +120,78 @@
|
|
|
97
120
|
.defaultHover, .primaryHover, .secondaryHover, .darkHover {
|
|
98
121
|
background-color: var(--listitem_highlight_bg_color);
|
|
99
122
|
}
|
|
123
|
+
|
|
100
124
|
.activewithBorder {
|
|
101
125
|
--listitem_border_color: var(--zdt_listitem_active_border);
|
|
102
126
|
}
|
|
127
|
+
|
|
103
128
|
[dir=ltr] .activewithBorder {
|
|
104
|
-
--listitem_border_width: 0 0 0 1px
|
|
129
|
+
--listitem_border_width: 0 0 0 1px
|
|
130
|
+
/*rtl: 0 1px 0 0*/
|
|
131
|
+
;
|
|
105
132
|
}
|
|
133
|
+
|
|
106
134
|
[dir=rtl] .activewithBorder {
|
|
107
|
-
--listitem_border_width: 0
|
|
135
|
+
--listitem_border_width: 0 0 0 1px ;
|
|
108
136
|
}
|
|
109
137
|
|
|
110
138
|
.defaultHover,
|
|
111
139
|
.defaultEffect:hover
|
|
140
|
+
|
|
112
141
|
/* .defaultEffect:focus */
|
|
113
|
-
{
|
|
142
|
+
{
|
|
114
143
|
--listitem_bg_color: var(--zdt_listitem_highlight_bg);
|
|
115
144
|
}
|
|
145
|
+
|
|
116
146
|
.primaryHover,
|
|
117
147
|
.primaryEffect:hover
|
|
148
|
+
|
|
118
149
|
/* .primaryEffect:focus */
|
|
119
|
-
|
|
150
|
+
{
|
|
120
151
|
--listitem_bg_color: var(--zdt_listitem_primary_bg);
|
|
121
152
|
--listitem_highlight_bg_color: var(--zdt_listitem_primary_bg);
|
|
122
153
|
}
|
|
154
|
+
|
|
123
155
|
.secondaryHover,
|
|
124
156
|
.secondaryEffect:hover
|
|
157
|
+
|
|
125
158
|
/* .secondaryEffect:focus */
|
|
126
|
-
{
|
|
159
|
+
{
|
|
127
160
|
--listitem_bg_color: var(--zdt_listitem_secondary_bg);
|
|
128
161
|
--listitem_highlight_bg_color: var(--zdt_listitem_secondary_bg);
|
|
129
162
|
--listitem_text_color: var(--zdt_listitem_secondary_text);
|
|
130
163
|
}
|
|
164
|
+
|
|
131
165
|
.darkHover,
|
|
132
166
|
.darkEffect:hover
|
|
167
|
+
|
|
133
168
|
/* .darkEffect:focus */
|
|
134
|
-
|
|
169
|
+
{
|
|
135
170
|
--listitem_bg_color: var(--zdt_listitem_dark_effect_bg);
|
|
136
171
|
--listitem_highlight_bg_color: var(--zdt_listitem_dark_effect_bg);
|
|
137
172
|
}
|
|
173
|
+
|
|
138
174
|
.activedefault, .activeprimary, .activesecondary, .activedark {
|
|
139
175
|
background-color: var(--listitem_active_bg_color);
|
|
140
176
|
}
|
|
177
|
+
|
|
141
178
|
.activedefault,
|
|
142
179
|
.activedefault:hover,
|
|
143
180
|
.activeprimary,
|
|
144
181
|
.activeprimary:hover {
|
|
145
182
|
--listitem_active_bg_color: var(--zdt_listitem_primary_bg);
|
|
146
183
|
}
|
|
184
|
+
|
|
147
185
|
.activesecondary {
|
|
148
186
|
--listitem_active_bg_color: var(--zdt_listitem_secondary_bg);
|
|
149
187
|
--listitem_text_color: var(--zdt_listitem_secondary_text);
|
|
150
188
|
}
|
|
189
|
+
|
|
151
190
|
.dark {
|
|
152
191
|
--listitem_bg_color: var(--zdt_listitem_dark_bg);
|
|
153
192
|
--listitem_text_color: var(--zdt_listitem_dark_text);
|
|
154
193
|
}
|
|
194
|
+
|
|
155
195
|
.activedark {
|
|
156
196
|
--listitem_active_bg_color: var(--zdt_listitem_dark_active_bg);
|
|
157
197
|
}
|
|
@@ -170,36 +210,63 @@
|
|
|
170
210
|
[dir=rtl] .tickIcon, [dir=rtl] .defaultTick, [dir=rtl] .darkTick {
|
|
171
211
|
left: var(--zd_size20) ;
|
|
172
212
|
}
|
|
213
|
+
|
|
173
214
|
.defaultTick {
|
|
174
215
|
--listitem_tickicon_color: var(--zdt_listitem_default_tickicon);
|
|
175
216
|
}
|
|
217
|
+
|
|
176
218
|
.darkTick {
|
|
177
219
|
--listitem_tickicon_color: var(--zdt_listitem_dark_tickicon);
|
|
178
220
|
}
|
|
179
|
-
|
|
221
|
+
|
|
222
|
+
.defaultTick>i {
|
|
180
223
|
display: block;
|
|
181
224
|
}
|
|
225
|
+
|
|
182
226
|
[dir=ltr] .smallwithTick {
|
|
183
227
|
--listitem_padding: var(--zd_size7) var(--zd_size39) var(--zd_size7) var(--zd_size5);
|
|
184
228
|
}
|
|
229
|
+
|
|
185
230
|
[dir=rtl] .smallwithTick {
|
|
186
|
-
--listitem_padding: var(--zd_size7) var(--
|
|
231
|
+
--listitem_padding: var(--zd_size7) var(--zd_size39) var(--zd_size7) var(--zd_size5);
|
|
187
232
|
}
|
|
233
|
+
|
|
188
234
|
[dir=ltr] .mediumwithTick {
|
|
189
235
|
--listitem_padding: var(--zd_size7) var(--zd_size39) var(--zd_size7) var(--zd_size20);
|
|
190
236
|
}
|
|
237
|
+
|
|
191
238
|
[dir=rtl] .mediumwithTick {
|
|
192
|
-
--listitem_padding: var(--zd_size7) var(--
|
|
239
|
+
--listitem_padding: var(--zd_size7) var(--zd_size39) var(--zd_size7) var(--zd_size20);
|
|
193
240
|
}
|
|
241
|
+
|
|
194
242
|
[dir=ltr] .largewithTick {
|
|
195
243
|
--listitem_padding: var(--zd_size10) var(--zd_size39) var(--zd_size10) var(--zd_size25);
|
|
196
244
|
}
|
|
245
|
+
|
|
197
246
|
[dir=rtl] .largewithTick {
|
|
198
|
-
--listitem_padding: var(--zd_size10) var(--
|
|
247
|
+
--listitem_padding: var(--zd_size10) var(--zd_size39) var(--zd_size10) var(--zd_size25);
|
|
199
248
|
}
|
|
249
|
+
|
|
200
250
|
.responsiveHeight {
|
|
201
251
|
--listitem_min_height: var(--zd_size45);
|
|
202
252
|
font-size: var(--zd_font_size15) ;
|
|
203
253
|
padding-top: var(--zd_size10) ;
|
|
204
254
|
padding-bottom: var(--zd_size10) ;
|
|
205
255
|
}
|
|
256
|
+
|
|
257
|
+
.autoHeight {
|
|
258
|
+
height: auto ;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
.tickIconCenter {
|
|
262
|
+
top: 50% ;
|
|
263
|
+
transform: translateY(-50%);
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
.txtAlignBaseLine {
|
|
267
|
+
align-items: baseline;
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
.alignSelfTop {
|
|
271
|
+
align-self: start;
|
|
272
|
+
}
|
|
@@ -162,7 +162,7 @@ var ListItemWithAvatar = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
162
162
|
autoHover: autoHover,
|
|
163
163
|
needTick: needTick,
|
|
164
164
|
needBorder: needBorder,
|
|
165
|
-
customClass: customListItem,
|
|
165
|
+
customClass: "".concat(needMultiLineText ? _ListItemModule["default"].autoHeight : '', " ").concat(customListItem),
|
|
166
166
|
dataId: "".concat(dataIdString, "_ListItemWithAvatar"),
|
|
167
167
|
dataSelectorId: "".concat(dataSelectorId),
|
|
168
168
|
onClick: this.handleClick,
|
|
@@ -172,7 +172,7 @@ var ListItemWithAvatar = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
172
172
|
title: null,
|
|
173
173
|
customProps: ListItemProps
|
|
174
174
|
}, ContainerProps), name || imgSrc ? /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
175
|
-
className: _ListItemModule["default"].leftAvatar
|
|
175
|
+
className: "".concat(needMultiLineText ? _ListItemModule["default"].alignSelfTop : '', " ").concat(_ListItemModule["default"].leftAvatar)
|
|
176
176
|
}, isTeam ? /*#__PURE__*/_react["default"].createElement(_AvatarTeam["default"], _extends({
|
|
177
177
|
name: name,
|
|
178
178
|
size: "small",
|
|
@@ -199,7 +199,7 @@ var ListItemWithAvatar = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
199
199
|
"data-title": isDisabled ? null : title,
|
|
200
200
|
className: needMultiLineText ? _ListItemModule["default"].multiLineValue : _ListItemModule["default"].value
|
|
201
201
|
}, value) : null, needTick && active ? /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
202
|
-
className: _ListItemModule["default"].tickIcon,
|
|
202
|
+
className: "".concat(_ListItemModule["default"].tickIcon, " ").concat(needMultiLineText ? _ListItemModule["default"].tickIconCenter : ''),
|
|
203
203
|
"aria-hidden": ariaHidden,
|
|
204
204
|
dataId: "".concat(dataIdString, "_tickIcon"),
|
|
205
205
|
dataSelectorId: "".concat(dataSelectorId, "_tickIcon")
|
|
@@ -147,7 +147,7 @@ var ListItemWithIcon = /*#__PURE__*/function (_React$Component) {
|
|
|
147
147
|
autoHover: autoHover,
|
|
148
148
|
needTick: needTick,
|
|
149
149
|
needBorder: needBorder,
|
|
150
|
-
customClass: customClass,
|
|
150
|
+
customClass: "".concat(needMultiLineText ? _ListItemModule["default"].autoHeight : '', " ").concat(needMultiLineText && iconClass && !iconName ? _ListItemModule["default"].txtAlignBaseLine : '', " ").concat(customClass),
|
|
151
151
|
dataId: dataIdString,
|
|
152
152
|
dataSelectorId: dataSelectorId,
|
|
153
153
|
isLink: isLink,
|
|
@@ -176,7 +176,7 @@ var ListItemWithIcon = /*#__PURE__*/function (_React$Component) {
|
|
|
176
176
|
"data-title": isDisabled ? null : title,
|
|
177
177
|
dataId: "".concat(dataIdString, "_Text")
|
|
178
178
|
}, value), needTick && active ? /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
179
|
-
className: _ListItemModule["default"].tickIcon,
|
|
179
|
+
className: "".concat(_ListItemModule["default"].tickIcon, " ").concat(needMultiLineText ? _ListItemModule["default"].tickIconCenter : ''),
|
|
180
180
|
"aria-hidden": ariaHidden,
|
|
181
181
|
dataId: "".concat(dataIdString, "_tickIcon"),
|
|
182
182
|
dataSelectorId: "".concat(dataSelectorId, "_tickIcon")
|
|
@@ -53,6 +53,8 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
53
53
|
|
|
54
54
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
55
55
|
|
|
56
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
57
|
+
|
|
56
58
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
57
59
|
|
|
58
60
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -966,7 +968,9 @@ var AdvancedGroupMultiSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
966
968
|
needEffect = _this$props8.needEffect,
|
|
967
969
|
autoComplete = _this$props8.autoComplete,
|
|
968
970
|
getTargetRef = _this$props8.getTargetRef,
|
|
969
|
-
isFocus = _this$props8.isFocus
|
|
971
|
+
isFocus = _this$props8.isFocus,
|
|
972
|
+
customProps = _this$props8.customProps;
|
|
973
|
+
var suggestionsProps = customProps.suggestionsProps;
|
|
970
974
|
var _i18nKeys = i18nKeys,
|
|
971
975
|
_i18nKeys$clearText = _i18nKeys.clearText,
|
|
972
976
|
clearText = _i18nKeys$clearText === void 0 ? 'Clear all' : _i18nKeys$clearText;
|
|
@@ -1130,7 +1134,7 @@ var AdvancedGroupMultiSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
1130
1134
|
a11y: {
|
|
1131
1135
|
role: 'heading'
|
|
1132
1136
|
}
|
|
1133
|
-
})), /*#__PURE__*/_react["default"].createElement(_Suggestions["default"], {
|
|
1137
|
+
})), /*#__PURE__*/_react["default"].createElement(_Suggestions["default"], _extends({
|
|
1134
1138
|
suggestions: suggestions,
|
|
1135
1139
|
selectedOptions: selectedOptionIds,
|
|
1136
1140
|
getRef: _this5.suggestionItemRef,
|
|
@@ -1143,7 +1147,7 @@ var AdvancedGroupMultiSelect = /*#__PURE__*/function (_React$Component) {
|
|
|
1143
1147
|
role: 'option'
|
|
1144
1148
|
},
|
|
1145
1149
|
dataId: "".concat(dataId, "_Options")
|
|
1146
|
-
}));
|
|
1150
|
+
}, suggestionsProps)));
|
|
1147
1151
|
}) : /*#__PURE__*/_react["default"].createElement(_EmptyState["default"], {
|
|
1148
1152
|
options: revampedGroups,
|
|
1149
1153
|
searchString: searchStr,
|
|
@@ -613,7 +613,9 @@ var AdvancedMultiSelectComponent = /*#__PURE__*/function (_MultiSelectComponent)
|
|
|
613
613
|
role: 'option'
|
|
614
614
|
},
|
|
615
615
|
dataId: "".concat(dataIdMultiSelectComp, "_Options")
|
|
616
|
-
}, SuggestionsProps
|
|
616
|
+
}, SuggestionsProps, {
|
|
617
|
+
needMultiLineText: true
|
|
618
|
+
})) : /*#__PURE__*/_react["default"].createElement(_EmptyState["default"], {
|
|
617
619
|
isLoading: isFetchingOptions,
|
|
618
620
|
options: options,
|
|
619
621
|
searchString: searchStr,
|