@zohodesk/components 1.0.0-temp-199.9 → 1.0.0-temp-216.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/.cli/propValidation_report.html +1 -1
- package/README.md +0 -9
- package/assets/Appearance/dark/mode/Component_DarkMode.module.css +9 -5
- package/assets/Appearance/dark/themes/blue/blue_ComponentTheme_DarkTheme.module.css +5 -0
- package/assets/Appearance/dark/themes/green/green_ComponentTheme_DarkTheme.module.css +5 -0
- package/assets/Appearance/dark/themes/orange/orange_ComponentTheme_DarkTheme.module.css +5 -0
- package/assets/Appearance/dark/themes/red/red_ComponentTheme_DarkTheme.module.css +5 -0
- package/assets/Appearance/dark/themes/yellow/yellow_ComponentTheme_DarkTheme.module.css +5 -0
- package/assets/Appearance/light/mode/Component_LightMode.module.css +9 -5
- package/assets/Appearance/light/themes/blue/blue_ComponentTheme_LightTheme.module.css +5 -0
- package/assets/Appearance/light/themes/green/green_ComponentTheme_LightTheme.module.css +5 -0
- package/assets/Appearance/light/themes/orange/orange_ComponentTheme_LightTheme.module.css +5 -0
- package/assets/Appearance/light/themes/red/red_ComponentTheme_LightTheme.module.css +5 -0
- package/assets/Appearance/light/themes/yellow/yellow_ComponentTheme_LightTheme.module.css +5 -0
- package/assets/Appearance/pureDark/mode/Component_PureDarkMode.module.css +9 -5
- package/assets/Appearance/pureDark/themes/blue/blue_ComponentTheme_PureDarkTheme.module.css +5 -0
- package/assets/Appearance/pureDark/themes/green/green_ComponentTheme_PureDarkTheme.module.css +5 -0
- package/assets/Appearance/pureDark/themes/orange/orange_ComponentTheme_PureDarkTheme.module.css +5 -0
- package/assets/Appearance/pureDark/themes/red/red_ComponentTheme_PureDarkTheme.module.css +5 -0
- package/assets/Appearance/pureDark/themes/yellow/yellow_ComponentTheme_PureDarkTheme.module.css +5 -0
- package/es/Button/Button.js +0 -2
- package/es/Button/css/Button.module.css +37 -1
- package/es/Button/css/cssJSLogic.js +10 -1
- package/es/DropBox/DropBoxElement/DropBoxElement.js +1 -3
- package/es/DropBox/DropBoxElement/__tests__/__snapshots__/DropBoxElement.spec.js.snap +2 -4
- package/es/DropBox/DropBoxElement/css/DropBoxElement.module.css +53 -56
- package/es/DropBox/DropBoxElement/css/cssJSLogic.js +4 -4
- package/es/DropBox/__tests__/__snapshots__/DropBox.spec.js.snap +2 -4
- package/es/DropDown/__tests__/__snapshots__/DropDown.spec.js.snap +1 -3
- package/es/ListItem/ListItem.js +2 -2
- package/es/ListItem/ListItem.module.css +2 -15
- package/es/ListItem/ListItemWithAvatar.js +3 -3
- package/es/ListItem/ListItemWithIcon.js +2 -2
- package/es/MultiSelect/AdvancedGroupMultiSelect.js +2 -7
- package/es/MultiSelect/MultiSelect.js +2 -7
- package/es/MultiSelect/Suggestions.js +5 -14
- package/es/MultiSelect/props/defaultProps.js +4 -9
- package/es/MultiSelect/props/propTypes.js +3 -9
- package/es/Popup/Popup.js +83 -232
- package/es/Provider/LibraryContext.js +3 -1
- package/es/ResponsiveDropBox/__tests__/__snapshots__/ResponsiveDropBox.spec.js.snap +2 -4
- package/es/Select/GroupSelect.js +1 -5
- package/es/Select/SelectWithAvatar.js +2 -7
- package/es/Select/SelectWithIcon.js +2 -4
- package/es/Select/props/defaultProps.js +1 -2
- package/es/Select/props/propTypes.js +2 -4
- package/es/common/common.module.css +0 -5
- package/es/utils/Common.js +1 -2
- package/es/v1/ListItem/ListItem.js +1 -1
- package/es/v1/MultiSelect/AdvancedMultiSelect.js +1 -2
- package/es/v1/MultiSelect/MultiSelect.js +2 -7
- package/es/v1/MultiSelect/Suggestions.js +4 -8
- package/es/v1/MultiSelect/props/defaultProps.js +2 -4
- package/es/v1/MultiSelect/props/propTypes.js +2 -6
- package/es/v1/Select/GroupSelect.js +2 -7
- package/es/v1/Select/SelectWithAvatar.js +2 -7
- package/es/v1/Select/props/defaultProps.js +2 -4
- package/es/v1/Select/props/propTypes.js +2 -6
- package/lib/Button/Button.js +0 -2
- package/lib/Button/css/Button.module.css +37 -1
- package/lib/Button/css/cssJSLogic.js +15 -2
- package/lib/DropBox/DropBoxElement/DropBoxElement.js +1 -3
- package/lib/DropBox/DropBoxElement/__tests__/__snapshots__/DropBoxElement.spec.js.snap +2 -4
- package/lib/DropBox/DropBoxElement/css/DropBoxElement.module.css +53 -56
- package/lib/DropBox/DropBoxElement/css/cssJSLogic.js +2 -2
- package/lib/DropBox/__tests__/__snapshots__/DropBox.spec.js.snap +2 -4
- package/lib/DropDown/__tests__/__snapshots__/DropDown.spec.js.snap +1 -3
- package/lib/ListItem/ListItem.js +2 -2
- package/lib/ListItem/ListItem.module.css +2 -15
- package/lib/ListItem/ListItemWithAvatar.js +3 -3
- package/lib/ListItem/ListItemWithIcon.js +2 -2
- package/lib/MultiSelect/AdvancedGroupMultiSelect.js +3 -7
- package/lib/MultiSelect/MultiSelect.js +3 -6
- package/lib/MultiSelect/Suggestions.js +5 -12
- package/lib/MultiSelect/props/defaultProps.js +4 -9
- package/lib/MultiSelect/props/propTypes.js +3 -8
- package/lib/Popup/Popup.js +114 -282
- package/lib/Provider/LibraryContext.js +3 -1
- package/lib/ResponsiveDropBox/__tests__/__snapshots__/ResponsiveDropBox.spec.js.snap +2 -4
- package/lib/Select/GroupSelect.js +2 -4
- package/lib/Select/SelectWithAvatar.js +3 -8
- package/lib/Select/SelectWithIcon.js +3 -5
- package/lib/Select/props/defaultProps.js +1 -2
- package/lib/Select/props/propTypes.js +2 -4
- package/lib/common/common.module.css +0 -5
- package/lib/utils/Common.js +1 -5
- package/lib/v1/ListItem/ListItem.js +1 -1
- package/lib/v1/MultiSelect/AdvancedMultiSelect.js +1 -3
- package/lib/v1/MultiSelect/MultiSelect.js +3 -8
- package/lib/v1/MultiSelect/Suggestions.js +4 -8
- package/lib/v1/MultiSelect/props/defaultProps.js +2 -4
- package/lib/v1/MultiSelect/props/propTypes.js +2 -6
- package/lib/v1/Select/GroupSelect.js +3 -8
- package/lib/v1/Select/SelectWithAvatar.js +3 -8
- package/lib/v1/Select/props/defaultProps.js +2 -4
- package/lib/v1/Select/props/propTypes.js +2 -6
- package/package.json +2 -2
- package/result.json +1 -1
|
@@ -81,7 +81,7 @@ const ListItem = props => {
|
|
|
81
81
|
autoHover: autoHover,
|
|
82
82
|
needTick: needTick,
|
|
83
83
|
needBorder: needBorder,
|
|
84
|
-
customClass:
|
|
84
|
+
customClass: customListItem,
|
|
85
85
|
dataId: dataIdString,
|
|
86
86
|
dataSelectorId: `${dataSelectorId}`,
|
|
87
87
|
isLink: isLink,
|
|
@@ -549,8 +549,7 @@ export class AdvancedMultiSelectComponent extends MultiSelectComponent {
|
|
|
549
549
|
role: 'option'
|
|
550
550
|
},
|
|
551
551
|
dataId: `${dataIdMultiSelectComp}_Options`,
|
|
552
|
-
...SuggestionsProps
|
|
553
|
-
needMultiLineText: true
|
|
552
|
+
...SuggestionsProps
|
|
554
553
|
}) : /*#__PURE__*/React.createElement(EmptyState, {
|
|
555
554
|
isLoading: isFetchingOptions,
|
|
556
555
|
options: options,
|
|
@@ -1002,12 +1002,8 @@ export class MultiSelectComponent extends React.Component {
|
|
|
1002
1002
|
boxSize,
|
|
1003
1003
|
isLoading,
|
|
1004
1004
|
selectAllText,
|
|
1005
|
-
needSelectAll
|
|
1006
|
-
customProps
|
|
1005
|
+
needSelectAll
|
|
1007
1006
|
} = this.props;
|
|
1008
|
-
const {
|
|
1009
|
-
suggestionsProps = {}
|
|
1010
|
-
} = customProps;
|
|
1011
1007
|
const {
|
|
1012
1008
|
selectedOptions,
|
|
1013
1009
|
searchStr,
|
|
@@ -1097,8 +1093,7 @@ export class MultiSelectComponent extends React.Component {
|
|
|
1097
1093
|
selectedOptions: selectedOptionIds,
|
|
1098
1094
|
a11y: {
|
|
1099
1095
|
role: 'option'
|
|
1100
|
-
}
|
|
1101
|
-
...suggestionsProps
|
|
1096
|
+
}
|
|
1102
1097
|
}) : /*#__PURE__*/React.createElement(EmptyState, {
|
|
1103
1098
|
isLoading: isFetchingOptions,
|
|
1104
1099
|
options: options,
|
|
@@ -27,8 +27,7 @@ export default class Suggestions extends React.PureComponent {
|
|
|
27
27
|
avatarPalette,
|
|
28
28
|
palette,
|
|
29
29
|
htmlId,
|
|
30
|
-
a11y
|
|
31
|
-
needMultiLineText
|
|
30
|
+
a11y
|
|
32
31
|
} = this.props;
|
|
33
32
|
const {
|
|
34
33
|
ariaParentRole,
|
|
@@ -93,8 +92,7 @@ export default class Suggestions extends React.PureComponent {
|
|
|
93
92
|
size: listItemSize,
|
|
94
93
|
avatarPalette: avatarPalette,
|
|
95
94
|
palette: palette,
|
|
96
|
-
a11y: list_a11y
|
|
97
|
-
needMultiLineText: needMultiLineText
|
|
95
|
+
a11y: list_a11y
|
|
98
96
|
});
|
|
99
97
|
} else if (optionType === 'icon') {
|
|
100
98
|
return /*#__PURE__*/React.createElement(ListItemWithIcon, { ...commonProps,
|
|
@@ -114,8 +112,7 @@ export default class Suggestions extends React.PureComponent {
|
|
|
114
112
|
iconSize: iconSize,
|
|
115
113
|
size: listItemSize,
|
|
116
114
|
palette: palette,
|
|
117
|
-
a11y: list_a11y
|
|
118
|
-
needMultiLineText: needMultiLineText
|
|
115
|
+
a11y: list_a11y
|
|
119
116
|
});
|
|
120
117
|
}
|
|
121
118
|
|
|
@@ -134,8 +131,7 @@ export default class Suggestions extends React.PureComponent {
|
|
|
134
131
|
active: isActive,
|
|
135
132
|
size: listItemSize,
|
|
136
133
|
palette: palette,
|
|
137
|
-
a11y: list_a11y
|
|
138
|
-
needMultiLineText: needMultiLineText
|
|
134
|
+
a11y: list_a11y
|
|
139
135
|
});
|
|
140
136
|
})));
|
|
141
137
|
}
|
|
@@ -117,8 +117,7 @@ export const MultiSelect_defaultProps = {
|
|
|
117
117
|
keepSelectedOptions: false,
|
|
118
118
|
selectedOptionsCount: 0,
|
|
119
119
|
cardHeaderName: '',
|
|
120
|
-
needResponsive: true
|
|
121
|
-
customProps: {}
|
|
120
|
+
needResponsive: true
|
|
122
121
|
};
|
|
123
122
|
export const MultiSelectHeader_defaultProps = {
|
|
124
123
|
dataId: 'MultiSelectHeader'
|
|
@@ -162,6 +161,5 @@ export const SelectedOptions_defaultProps = {
|
|
|
162
161
|
dataId: 'selectedOptions'
|
|
163
162
|
};
|
|
164
163
|
export const Suggestions_defaultProps = {
|
|
165
|
-
a11y: {}
|
|
166
|
-
needMultiLineText: false
|
|
164
|
+
a11y: {}
|
|
167
165
|
};
|
|
@@ -108,10 +108,7 @@ export const MultiSelect_propTypes = {
|
|
|
108
108
|
needSelectAll: PropTypes.bool,
|
|
109
109
|
selectAllText: PropTypes.string,
|
|
110
110
|
setAriaId: PropTypes.string,
|
|
111
|
-
ariaErrorId: PropTypes.string
|
|
112
|
-
customProps: {
|
|
113
|
-
suggestionsProps: PropTypes.object
|
|
114
|
-
}
|
|
111
|
+
ariaErrorId: PropTypes.string
|
|
115
112
|
};
|
|
116
113
|
export const MultiSelectHeader_propTypes = {
|
|
117
114
|
dataId: PropTypes.string,
|
|
@@ -176,8 +173,7 @@ export const Suggestions_propTypes = {
|
|
|
176
173
|
logo: PropTypes.string,
|
|
177
174
|
optionType: PropTypes.string,
|
|
178
175
|
listItemProps: PropTypes.object
|
|
179
|
-
}))
|
|
180
|
-
needMultiLineText: PropTypes.bool
|
|
176
|
+
}))
|
|
181
177
|
};
|
|
182
178
|
export const AdvancedGroupMultiSelect_propTypes = {
|
|
183
179
|
animationStyle: PropTypes.string,
|
|
@@ -590,12 +590,8 @@ export class GroupSelectComponent extends PureComponent {
|
|
|
590
590
|
htmlId,
|
|
591
591
|
iconOnHover,
|
|
592
592
|
isLoading,
|
|
593
|
-
dataSelectorId
|
|
594
|
-
customProps
|
|
593
|
+
dataSelectorId
|
|
595
594
|
} = this.props;
|
|
596
|
-
const {
|
|
597
|
-
suggestionsProps = {}
|
|
598
|
-
} = customProps;
|
|
599
595
|
i18nKeys = Object.assign({}, i18nKeys, {
|
|
600
596
|
emptyText: i18nKeys.emptyText || emptyMessage,
|
|
601
597
|
searchEmptyText: i18nKeys.searchEmptyText || searchEmptyMessage
|
|
@@ -788,8 +784,7 @@ export class GroupSelectComponent extends PureComponent {
|
|
|
788
784
|
ariaParentRole: 'listbox',
|
|
789
785
|
role: 'option'
|
|
790
786
|
},
|
|
791
|
-
dataId: `${dataId}_Options
|
|
792
|
-
...suggestionsProps
|
|
787
|
+
dataId: `${dataId}_Options`
|
|
793
788
|
}));
|
|
794
789
|
}) : /*#__PURE__*/React.createElement(EmptyState, {
|
|
795
790
|
options: revampedGroups,
|
|
@@ -163,12 +163,8 @@ class SelectWithAvatarComponent extends SelectComponent {
|
|
|
163
163
|
needEffect,
|
|
164
164
|
isLoading,
|
|
165
165
|
dataSelectorId,
|
|
166
|
-
getTargetRef
|
|
167
|
-
customProps
|
|
166
|
+
getTargetRef
|
|
168
167
|
} = this.props;
|
|
169
|
-
const {
|
|
170
|
-
suggestionsProps = {}
|
|
171
|
-
} = customProps;
|
|
172
168
|
i18nKeys = Object.assign({}, i18nKeys, {
|
|
173
169
|
emptyText: i18nKeys.emptyText || emptyMessage,
|
|
174
170
|
searchEmptyText: i18nKeys.searchEmptyText || searchEmptyMessage
|
|
@@ -325,8 +321,7 @@ class SelectWithAvatarComponent extends SelectComponent {
|
|
|
325
321
|
a11y: {
|
|
326
322
|
ariaParentRole: 'listbox',
|
|
327
323
|
role: 'option'
|
|
328
|
-
}
|
|
329
|
-
...suggestionsProps
|
|
324
|
+
}
|
|
330
325
|
}) : /*#__PURE__*/React.createElement(EmptyState, {
|
|
331
326
|
isLoading: isFetchingOptions,
|
|
332
327
|
options: options,
|
|
@@ -69,8 +69,7 @@ export const GroupSelect_defaultProps = {
|
|
|
69
69
|
isRestrictScroll: false,
|
|
70
70
|
i18nKeys: {},
|
|
71
71
|
iconOnHover: false,
|
|
72
|
-
isLoading: false
|
|
73
|
-
customProps: {}
|
|
72
|
+
isLoading: false
|
|
74
73
|
};
|
|
75
74
|
export const SelectWithAvatar_defaultProps = {
|
|
76
75
|
animationStyle: 'bounce',
|
|
@@ -96,8 +95,7 @@ export const SelectWithAvatar_defaultProps = {
|
|
|
96
95
|
isRestrictScroll: false,
|
|
97
96
|
i18nKeys: {},
|
|
98
97
|
needEffect: true,
|
|
99
|
-
isLoading: false
|
|
100
|
-
customProps: {}
|
|
98
|
+
isLoading: false
|
|
101
99
|
};
|
|
102
100
|
export const SelectWithIcon_defaultProps = {
|
|
103
101
|
isReadOnly: false,
|
|
@@ -174,10 +174,7 @@ export const GroupSelect_propTypes = {
|
|
|
174
174
|
}),
|
|
175
175
|
isLoading: PropTypes.bool,
|
|
176
176
|
dataSelectorId: PropTypes.string,
|
|
177
|
-
isDefaultSelectValue: PropTypes.bool
|
|
178
|
-
customProps: PropTypes.shape({
|
|
179
|
-
suggestionsProps: PropTypes.object
|
|
180
|
-
})
|
|
177
|
+
isDefaultSelectValue: PropTypes.bool
|
|
181
178
|
};
|
|
182
179
|
export const SelectWithAvatar_propTypes = { ...Select_propTypes,
|
|
183
180
|
textBoxClass: PropTypes.string,
|
|
@@ -238,8 +235,7 @@ export const SelectWithAvatar_propTypes = { ...Select_propTypes,
|
|
|
238
235
|
htmlId: PropTypes.string,
|
|
239
236
|
needEffect: PropTypes.bool,
|
|
240
237
|
isLoading: PropTypes.bool,
|
|
241
|
-
dataSelectorId: PropTypes.string
|
|
242
|
-
customProps: PropTypes.object
|
|
238
|
+
dataSelectorId: PropTypes.string
|
|
243
239
|
};
|
|
244
240
|
export const SelectWithIcon_propTypes = {
|
|
245
241
|
animationStyle: PropTypes.oneOf(['default', 'bounce']),
|
package/lib/Button/Button.js
CHANGED
|
@@ -26,8 +26,6 @@ Button text and children props?
|
|
|
26
26
|
use children for both cases
|
|
27
27
|
toLowerCase check needed?
|
|
28
28
|
*/
|
|
29
|
-
|
|
30
|
-
/* eslint css-modules/no-unused-class: [2, { markAsUsed: ['small','medium','large','xlarge','button_medium','button_small','primary','primaryfilled','danger','dangerfilled','plainprimary', 'plainsecondary', 'secondary', 'secondaryfilled', 'successFilled','tertiaryFilled'] }] */
|
|
31
29
|
function Button(props) {
|
|
32
30
|
var text = props.text,
|
|
33
31
|
disabled = props.disabled,
|
|
@@ -38,7 +38,6 @@
|
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
.native:disabled {
|
|
41
|
-
pointer-events: none;
|
|
42
41
|
--button_cursor: not-allowed;
|
|
43
42
|
--button_opacity: 0.4;
|
|
44
43
|
}
|
|
@@ -525,4 +524,41 @@
|
|
|
525
524
|
|
|
526
525
|
.loader{
|
|
527
526
|
color:var(--dot_mirror)
|
|
527
|
+
}
|
|
528
|
+
|
|
529
|
+
[dir=ltr] .strike {
|
|
530
|
+
background-image: repeating-linear-gradient(120deg, var(--button_strike_color), var(--button_strike_color) 1px, var(--button_bg_color) 0px, var(--button_bg_color) 8px);
|
|
531
|
+
}
|
|
532
|
+
|
|
533
|
+
[dir=rtl] .strike {
|
|
534
|
+
background-image: repeating-linear-gradient(-120deg, var(--button_strike_color), var(--button_strike_color) 1px, var(--button_bg_color) 0px, var(--button_bg_color) 8px);
|
|
535
|
+
}
|
|
536
|
+
.primaryStrike {
|
|
537
|
+
--button_strike_color: var(--zdt_button_primary_strike);
|
|
538
|
+
}
|
|
539
|
+
.primaryfilledStrike {
|
|
540
|
+
--button_strike_color: var(--zdt_button_primaryFilled_strike);
|
|
541
|
+
--button_border_color: var(--zdt_button_primaryfill_bg);
|
|
542
|
+
}
|
|
543
|
+
.dangerStrike {
|
|
544
|
+
--button_strike_color: var(--zdt_button_danger_strike);
|
|
545
|
+
}
|
|
546
|
+
.dangerfilledStrike {
|
|
547
|
+
--button_strike_color: var(--zdt_button_dangerFilled_strike);
|
|
548
|
+
--button_border_color: var(--zdt_button_dangerfill_bg);
|
|
549
|
+
}
|
|
550
|
+
.secondaryStrike {
|
|
551
|
+
--button_strike_color: var(--zdt_button_secondary_border);
|
|
552
|
+
}
|
|
553
|
+
.secondaryfilledStrike {
|
|
554
|
+
--button_strike_color: var(--zdt_button_secondaryFilled_strike);
|
|
555
|
+
--button_border_color: var(--zdt_button_secondaryfill_bg);
|
|
556
|
+
}
|
|
557
|
+
.tertiaryfilledStrike {
|
|
558
|
+
--button_strike_color: var(--zdt_button_tertiaryFilled_strike);
|
|
559
|
+
--button_border_color: var(--zdt_button_tertiaryfill_bg);
|
|
560
|
+
}
|
|
561
|
+
.successfilledStrike {
|
|
562
|
+
--button_strike_color: var(--zdt_button_successFilled_strike);
|
|
563
|
+
--button_border_color: var(--zdt_button_successfill_bg);
|
|
528
564
|
}
|
|
@@ -5,8 +5,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports["default"] = cssJSLogic;
|
|
7
7
|
|
|
8
|
+
var _react = require("react");
|
|
9
|
+
|
|
8
10
|
var _utils = require("@zohodesk/utils");
|
|
9
11
|
|
|
12
|
+
var _LibraryContextInit = _interopRequireDefault(require("../../Provider/LibraryContextInit"));
|
|
13
|
+
|
|
14
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
15
|
+
|
|
10
16
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
11
17
|
|
|
12
18
|
function cssJSLogic(_ref) {
|
|
@@ -21,16 +27,23 @@ function cssJSLogic(_ref) {
|
|
|
21
27
|
size = props.size,
|
|
22
28
|
children = props.children,
|
|
23
29
|
palette = props.palette,
|
|
24
|
-
status = props.status
|
|
30
|
+
status = props.status,
|
|
31
|
+
disabled = props.disabled;
|
|
25
32
|
var _customClass$customBu = customClass.customButton,
|
|
26
33
|
customButton = _customClass$customBu === void 0 ? '' : _customClass$customBu,
|
|
27
34
|
_customClass$customSt = customClass.customStatus,
|
|
28
35
|
customStatus = _customClass$customSt === void 0 ? '' : _customClass$customSt,
|
|
29
36
|
_customClass$customSt2 = customClass.customStatusSize,
|
|
30
37
|
customStatusSize = _customClass$customSt2 === void 0 ? '' : _customClass$customSt2;
|
|
38
|
+
|
|
39
|
+
var _useContext = (0, _react.useContext)(_LibraryContextInit["default"]),
|
|
40
|
+
shouldStrikeThroughDisabledButton = _useContext.shouldStrikeThroughDisabledButton;
|
|
41
|
+
|
|
42
|
+
var strikeExcludedPalettes = ['plainprimary', 'plainsecondary'];
|
|
31
43
|
var paletteLower = palette.toLowerCase();
|
|
32
44
|
var statusLower = status.toLowerCase();
|
|
33
|
-
var
|
|
45
|
+
var canStrikeThrough = !strikeExcludedPalettes.includes(paletteLower);
|
|
46
|
+
var buttonClass = (0, _utils.compileClassNames)((_compileClassNames = {}, _defineProperty(_compileClassNames, customButton, !!customButton), _defineProperty(_compileClassNames, style.bold, isBold), _defineProperty(_compileClassNames, style["default"], !needAppearance), _defineProperty(_compileClassNames, style[paletteLower], needAppearance), _defineProperty(_compileClassNames, style.rounded, needAppearance && rounded), _defineProperty(_compileClassNames, style[size.toLowerCase()], needAppearance && !children), _defineProperty(_compileClassNames, style["".concat(size, "Btn")], needAppearance && children), _defineProperty(_compileClassNames, style["".concat(size, "Btn").concat(paletteLower)], needAppearance && children && rounded), _defineProperty(_compileClassNames, "".concat(style["".concat(paletteLower, "Strike")], " ").concat(style.strike), disabled && canStrikeThrough && shouldStrikeThroughDisabledButton), _defineProperty(_compileClassNames, style.loader, !!needAppearance && statusLower !== 'none'), _compileClassNames));
|
|
34
47
|
var loaderParentClass = (0, _utils.compileClassNames)((_compileClassNames2 = {}, _defineProperty(_compileClassNames2, customStatusSize, !!customStatusSize), _defineProperty(_compileClassNames2, style.loading, statusLower === 'loading'), _defineProperty(_compileClassNames2, style["".concat(size, "loading")], statusLower === 'loading'), _defineProperty(_compileClassNames2, style.success, statusLower != 'loading'), _compileClassNames2));
|
|
35
48
|
var loaderChildClass = (0, _utils.compileClassNames)((_compileClassNames3 = {}, _defineProperty(_compileClassNames3, customStatus, !!customStatus), _defineProperty(_compileClassNames3, style.loadingelement, statusLower === 'loading'), _defineProperty(_compileClassNames3, style["".concat(paletteLower, "element")], statusLower === 'loading'), _defineProperty(_compileClassNames3, style.successelement, statusLower != 'loading'), _defineProperty(_compileClassNames3, style["".concat(paletteLower, "success")], statusLower != 'loading'), _compileClassNames3));
|
|
36
49
|
return {
|
|
@@ -115,8 +115,6 @@ function DropBoxElement(props) {
|
|
|
115
115
|
style: inlineStyle,
|
|
116
116
|
"data-tour": tourId,
|
|
117
117
|
"data-position": boxPosition,
|
|
118
|
-
"data-box-direction": boxDirection,
|
|
119
|
-
"data-arrow-position": arrowPosition,
|
|
120
118
|
id: htmlId,
|
|
121
119
|
role: role,
|
|
122
120
|
"aria-multiselectable": ariaMultiselectable,
|
|
@@ -136,7 +134,7 @@ function DropBoxElement(props) {
|
|
|
136
134
|
}, isModel ? /*#__PURE__*/_react["default"].createElement("div", {
|
|
137
135
|
className: _DropBoxElementModule["default"].closeBar
|
|
138
136
|
}) : null, isArrow && !isModel && /*#__PURE__*/_react["default"].createElement("div", {
|
|
139
|
-
className: _DropBoxElementModule["default"]
|
|
137
|
+
className: _DropBoxElementModule["default"][arrowPosition],
|
|
140
138
|
style: arrowstyle,
|
|
141
139
|
"data-id": "".concat(dataId, "_arrow"),
|
|
142
140
|
"data-test-id": "".concat(dataId, "_arrow"),
|
|
@@ -5,8 +5,6 @@ exports[`DropBoxElement rendering the defult props 1`] = `
|
|
|
5
5
|
<div
|
|
6
6
|
class="main hidden container bottomStart default"
|
|
7
7
|
data-a11y-focus-main-area="true"
|
|
8
|
-
data-arrow-position="end"
|
|
9
|
-
data-box-direction="bottom"
|
|
10
8
|
data-id="dropBox"
|
|
11
9
|
data-position="bottomStart"
|
|
12
10
|
data-selector-id="dropBox"
|
|
@@ -14,14 +12,14 @@ exports[`DropBoxElement rendering the defult props 1`] = `
|
|
|
14
12
|
dot-ui-element="dropbox"
|
|
15
13
|
>
|
|
16
14
|
<div
|
|
17
|
-
class="subContainer
|
|
15
|
+
class="subContainer bottom_shadow radius defaultPalette"
|
|
18
16
|
data-id="dropBox_subcontainer"
|
|
19
17
|
data-selector-id="dropBox_subcontainer"
|
|
20
18
|
data-test-id="dropBox_subcontainer"
|
|
21
19
|
tabindex="-1"
|
|
22
20
|
>
|
|
23
21
|
<div
|
|
24
|
-
class="
|
|
22
|
+
class="end"
|
|
25
23
|
data-id="dropBox_arrow"
|
|
26
24
|
data-selector-id="dropBox_arrow"
|
|
27
25
|
data-test-id="dropBox_arrow"
|
|
@@ -73,19 +73,19 @@
|
|
|
73
73
|
}
|
|
74
74
|
|
|
75
75
|
/* shadow */
|
|
76
|
-
|
|
76
|
+
.top_shadow {
|
|
77
77
|
--dropbox_box_shadow: var(--zd_bs_dropbox_top);
|
|
78
78
|
}
|
|
79
79
|
|
|
80
|
-
|
|
80
|
+
.left_shadow {
|
|
81
81
|
--dropbox_box_shadow: var(--zd_bs_dropbox_left);
|
|
82
82
|
}
|
|
83
83
|
|
|
84
|
-
|
|
84
|
+
.right_shadow {
|
|
85
85
|
--dropbox_box_shadow: var(--zd_bs_dropbox_right);
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
|
|
88
|
+
.bottom_shadow {
|
|
89
89
|
--dropbox_box_shadow: var(--zd_bs_dropbox_bottom);
|
|
90
90
|
}
|
|
91
91
|
|
|
@@ -158,41 +158,41 @@
|
|
|
158
158
|
transform: translateY(-50%);
|
|
159
159
|
}
|
|
160
160
|
|
|
161
|
-
/* space for arrow
|
|
162
|
-
.
|
|
161
|
+
/* space for arrow */
|
|
162
|
+
.arrowtop {
|
|
163
163
|
padding-bottom: var(--zd_size10) ;
|
|
164
164
|
}
|
|
165
165
|
|
|
166
|
-
.
|
|
166
|
+
.arrowright {
|
|
167
167
|
padding-left: var(--zd_size10) ;
|
|
168
168
|
}
|
|
169
169
|
|
|
170
|
-
.
|
|
170
|
+
.arrowleft {
|
|
171
171
|
padding-right: var(--zd_size10) ;
|
|
172
172
|
}
|
|
173
173
|
|
|
174
|
-
.
|
|
174
|
+
.arrowbottom {
|
|
175
175
|
padding-top: var(--zd_size10) ;
|
|
176
176
|
}
|
|
177
177
|
|
|
178
|
-
/* space from target
|
|
179
|
-
.
|
|
178
|
+
/* space from target */
|
|
179
|
+
.paddingSpace_top {
|
|
180
180
|
padding-bottom: var(--zd_size5) ;
|
|
181
181
|
}
|
|
182
182
|
|
|
183
|
-
.
|
|
183
|
+
.paddingSpace_right {
|
|
184
184
|
padding-left: var(--zd_size5) ;
|
|
185
185
|
}
|
|
186
186
|
|
|
187
|
-
.
|
|
187
|
+
.paddingSpace_left {
|
|
188
188
|
padding-right: var(--zd_size5) ;
|
|
189
189
|
}
|
|
190
190
|
|
|
191
|
-
.
|
|
191
|
+
.paddingSpace_bottom {
|
|
192
192
|
padding-top: var(--zd_size5) ;
|
|
193
193
|
}
|
|
194
194
|
|
|
195
|
-
.
|
|
195
|
+
.arrow {
|
|
196
196
|
position: absolute;
|
|
197
197
|
height: var(--zd_size34) ;
|
|
198
198
|
width: var(--zd_size34) ;
|
|
@@ -213,106 +213,107 @@
|
|
|
213
213
|
}
|
|
214
214
|
|
|
215
215
|
/* arrow placement styles */
|
|
216
|
-
.
|
|
217
|
-
|
|
216
|
+
.start,
|
|
217
|
+
.end,
|
|
218
|
+
.mid {
|
|
219
|
+
composes: arrow;
|
|
218
220
|
}
|
|
219
221
|
|
|
220
|
-
.
|
|
221
|
-
.
|
|
222
|
-
.
|
|
222
|
+
.top .start,
|
|
223
|
+
.top .end,
|
|
224
|
+
.top .mid {
|
|
223
225
|
bottom: calc( var(--zd_size17) * -1 ) ;
|
|
224
226
|
}
|
|
225
227
|
|
|
226
|
-
.
|
|
228
|
+
.top .start {
|
|
227
229
|
left: var(--zd_size28) ;
|
|
228
230
|
}
|
|
229
231
|
|
|
230
|
-
.
|
|
232
|
+
.top .end {
|
|
231
233
|
right: var(--zd_size28) ;
|
|
232
234
|
transform: rotate(180deg) translateX(-50%);
|
|
233
235
|
}
|
|
234
236
|
|
|
235
|
-
.
|
|
237
|
+
.top .mid {
|
|
236
238
|
left: 50% ;
|
|
237
239
|
}
|
|
238
240
|
|
|
239
|
-
.
|
|
240
|
-
.
|
|
241
|
+
.top .start,
|
|
242
|
+
.top .mid {
|
|
241
243
|
transform: rotate(180deg) translateX(50%);
|
|
242
244
|
}
|
|
243
245
|
|
|
244
|
-
.
|
|
245
|
-
.
|
|
246
|
-
.
|
|
246
|
+
.bottom .start,
|
|
247
|
+
.bottom .end,
|
|
248
|
+
.bottom .mid {
|
|
247
249
|
top: calc( var(--zd_size17) * -1 ) ;
|
|
248
250
|
}
|
|
249
251
|
|
|
250
|
-
.
|
|
252
|
+
.bottom .start {
|
|
251
253
|
left: var(--zd_size28) ;
|
|
252
254
|
}
|
|
253
255
|
|
|
254
|
-
.
|
|
256
|
+
.bottom .mid {
|
|
255
257
|
left: 50% ;
|
|
256
258
|
}
|
|
257
259
|
|
|
258
|
-
.
|
|
260
|
+
.bottom .end {
|
|
259
261
|
right: var(--zd_size28) ;
|
|
260
262
|
transform: translateX(50%);
|
|
261
263
|
}
|
|
262
264
|
|
|
263
|
-
.
|
|
264
|
-
.
|
|
265
|
+
.bottom .mid,
|
|
266
|
+
.bottom .start {
|
|
265
267
|
transform: translateX(-50%);
|
|
266
268
|
}
|
|
267
269
|
|
|
268
|
-
.
|
|
269
|
-
.
|
|
270
|
-
.
|
|
270
|
+
.left .start,
|
|
271
|
+
.left .mid,
|
|
272
|
+
.left .end {
|
|
271
273
|
right: calc( var(--zd_size17) * -1 ) ;
|
|
272
274
|
}
|
|
273
275
|
|
|
274
|
-
.
|
|
276
|
+
.left .start {
|
|
275
277
|
top: var(--zd_size28) ;
|
|
276
278
|
}
|
|
277
279
|
|
|
278
|
-
.
|
|
280
|
+
.left .end {
|
|
279
281
|
transform: rotate(90deg) translateX(50%);
|
|
280
282
|
bottom: var(--zd_size28) ;
|
|
281
283
|
}
|
|
282
284
|
|
|
283
|
-
.
|
|
285
|
+
.left .mid {
|
|
284
286
|
top: 50% ;
|
|
285
287
|
}
|
|
286
288
|
|
|
287
|
-
.
|
|
288
|
-
.
|
|
289
|
+
.left .start,
|
|
290
|
+
.left .mid {
|
|
289
291
|
transform: rotate(90deg) translateX(-50%);
|
|
290
292
|
}
|
|
291
293
|
|
|
292
|
-
.
|
|
293
|
-
.
|
|
294
|
-
.
|
|
294
|
+
.right .start,
|
|
295
|
+
.right .mid,
|
|
296
|
+
.right .end {
|
|
295
297
|
left: calc( var(--zd_size17) * -1 ) ;
|
|
296
298
|
}
|
|
297
299
|
|
|
298
|
-
.
|
|
300
|
+
.right .start {
|
|
299
301
|
top: var(--zd_size28) ;
|
|
300
302
|
}
|
|
301
303
|
|
|
302
|
-
.
|
|
304
|
+
.right .mid {
|
|
303
305
|
top: 50% ;
|
|
304
306
|
}
|
|
305
307
|
|
|
306
|
-
.
|
|
307
|
-
.
|
|
308
|
+
.right .start,
|
|
309
|
+
.right .mid {
|
|
308
310
|
transform: rotate(-90deg) translateX(50%);
|
|
309
311
|
}
|
|
310
312
|
|
|
311
|
-
.
|
|
313
|
+
.right .end {
|
|
312
314
|
bottom: var(--zd_size28) ;
|
|
313
315
|
transform: rotate(-90deg) translateX(-50%);
|
|
314
316
|
}
|
|
315
|
-
[data-visible="hidden"],
|
|
316
317
|
.hidden {
|
|
317
318
|
visibility: hidden;
|
|
318
319
|
opacity: 0;
|
|
@@ -320,7 +321,7 @@
|
|
|
320
321
|
pointer-events: none;
|
|
321
322
|
}
|
|
322
323
|
|
|
323
|
-
|
|
324
|
+
.hidden .subContainer {
|
|
324
325
|
box-shadow: none;
|
|
325
326
|
}
|
|
326
327
|
|
|
@@ -341,21 +342,17 @@
|
|
|
341
342
|
composes: animationBasic;
|
|
342
343
|
composes: fadeIn modeForward from '../../../common/animation.module.css';
|
|
343
344
|
}
|
|
344
|
-
|
|
345
345
|
.scaleIn {
|
|
346
346
|
composes: animationBasic;
|
|
347
347
|
composes: scaleIn from '../../../common/animation.module.css';
|
|
348
348
|
}
|
|
349
|
-
|
|
350
349
|
.bounce {
|
|
351
350
|
composes: animationBasic;
|
|
352
351
|
}
|
|
353
|
-
|
|
354
352
|
[dir=ltr] .bounce {
|
|
355
353
|
animation-name: animation;
|
|
356
354
|
animation-timing-function: cubic-bezier(0.4, 1, 0.65, 1.1);
|
|
357
355
|
}
|
|
358
|
-
|
|
359
356
|
[dir=rtl] .bounce {
|
|
360
357
|
animation-name: animation;
|
|
361
358
|
animation-timing-function: cubic-bezier(0.4, 1, 0.65, 1.1);
|
|
@@ -417,7 +414,7 @@
|
|
|
417
414
|
}
|
|
418
415
|
|
|
419
416
|
.closeBar {
|
|
420
|
-
|
|
417
|
+
/* Variable:Ignore */
|
|
421
418
|
height: 6px;
|
|
422
419
|
width: 20% ;
|
|
423
420
|
border-radius: 5px;
|
|
@@ -55,8 +55,8 @@ function cssJSLogic(_ref) {
|
|
|
55
55
|
customMobileDropBoxWrap = _customClass$customMo2 === void 0 ? '' : _customClass$customMo2;
|
|
56
56
|
var animationValue = animationStyle === 'default' ? 'fadeInScale' : animationStyle; // const {needBoxStyle,boxstyle} = useDropboxPosCalc(props)
|
|
57
57
|
|
|
58
|
-
var boxClassName = (0, _utils.compileClassNames)((_compileClassNames = {}, _defineProperty(_compileClassNames, style.main, true), _defineProperty(_compileClassNames, style.hidden, !isActive), _defineProperty(_compileClassNames, style.responsive, !!isModel), _defineProperty(_compileClassNames, customMobileDropBoxWrap, !!isModel), _defineProperty(_compileClassNames, customDropBoxWrap, !isModel), _defineProperty(_compileClassNames, style.container, isAbsolute && !isModel), _defineProperty(_compileClassNames, style[boxPosition], isAbsolute && !isModel), _defineProperty(_compileClassNames, style.fixedContainer, !isAbsolute && !isModel), _defineProperty(_compileClassNames, style[size], size && !isModel), _defineProperty(_compileClassNames, style
|
|
59
|
-
var subContainerClass = (0, _utils.compileClassNames)((_compileClassNames2 = {}, _defineProperty(_compileClassNames2, style.subContainer, true), _defineProperty(_compileClassNames2, customMobileDropBox, !!isModel), _defineProperty(_compileClassNames2, style.mobRadius, !!isModel), _defineProperty(_compileClassNames2, style.slideUp, !!isModel && isActive), _defineProperty(_compileClassNames2, customDropBox, !isModel), _defineProperty(_compileClassNames2, style.
|
|
58
|
+
var boxClassName = (0, _utils.compileClassNames)((_compileClassNames = {}, _defineProperty(_compileClassNames, style.main, true), _defineProperty(_compileClassNames, style.hidden, !isActive), _defineProperty(_compileClassNames, style.responsive, !!isModel), _defineProperty(_compileClassNames, customMobileDropBoxWrap, !!isModel), _defineProperty(_compileClassNames, customDropBoxWrap, !isModel), _defineProperty(_compileClassNames, style.container, isAbsolute && !isModel), _defineProperty(_compileClassNames, style[boxPosition], isAbsolute && !isModel), _defineProperty(_compileClassNames, style.fixedContainer, !isAbsolute && !isModel), _defineProperty(_compileClassNames, style[size], size && !isModel), _defineProperty(_compileClassNames, style[boxDirection], !isModel && isActive && isArrow), _defineProperty(_compileClassNames, style["arrow".concat(boxDirection)], !isModel && isActive && isArrow && isAbsolute), _defineProperty(_compileClassNames, style["paddingSpace_".concat(boxDirection)], !isModel && isActive && !isArrow && isPadding), _compileClassNames));
|
|
59
|
+
var subContainerClass = (0, _utils.compileClassNames)((_compileClassNames2 = {}, _defineProperty(_compileClassNames2, style.subContainer, true), _defineProperty(_compileClassNames2, customMobileDropBox, !!isModel), _defineProperty(_compileClassNames2, style.mobRadius, !!isModel), _defineProperty(_compileClassNames2, style.slideUp, !!isModel && isActive), _defineProperty(_compileClassNames2, customDropBox, !isModel), _defineProperty(_compileClassNames2, style["".concat(boxDirection, "_shadow")], !isModel), _defineProperty(_compileClassNames2, style.boxPadding, !isModel && isBoxPaddingNeed), _defineProperty(_compileClassNames2, style.radius, !isModel && isRadius), _defineProperty(_compileClassNames2, style[animationValue], !isModel && isAnimate && !isReducedMotion && isActive && !!animationStyle), _compileClassNames2));
|
|
60
60
|
var inlineStyle = !isModel ? isAbsolute ? needBoxStyle && boxstyle : positionsOffset && positionsOffset[boxPosition] || {} : {};
|
|
61
61
|
|
|
62
62
|
if (zIndexStyle) {
|