@zohodesk/components 1.0.0-temp-204 → 1.0.0-temp-205
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/PropUnificationExcludeFilesArray.js +230 -230
- package/.cli/PropValidationExcludeFilesArray.js +1 -1
- package/.cli/propValidation_report.html +1 -1
- package/README.md +4 -0
- package/css_error.log +1 -1
- package/es/AppContainer/AppContainer.js +0 -1
- package/es/Avatar/Avatar.js +9 -9
- package/es/Avatar/Avatar.module.css +2 -2
- package/es/Avatar/__tests__/__snapshots__/Avatar.spec.js.snap +591 -591
- package/es/AvatarTeam/__tests__/__snapshots__/AvatarTeam.spec.js.snap +705 -705
- package/es/Button/css/Button.module.css +22 -6
- package/es/Buttongroup/Buttongroup.module.css +1 -1
- package/es/DateTime/DateTime.module.css +11 -8
- package/es/DropBox/DropBoxElement/css/DropBoxElement.module.css +24 -9
- package/es/DropBox/css/DropBox.module.css +1 -1
- package/es/Label/__tests__/__snapshots__/Label.spec.js.snap +312 -312
- package/es/ListItem/ListItemWithAvatar.js +5 -9
- package/es/ListItem/props/defaultProps.js +0 -1
- package/es/ListItem/props/propTypes.js +1 -4
- package/es/MultiSelect/Suggestions.js +0 -2
- package/es/MultiSelect/props/propTypes.js +0 -1
- package/es/Radio/Radio.js +3 -2
- package/es/Radio/Radio.module.css +2 -1
- package/es/Radio/props/propTypes.js +2 -1
- package/es/Ribbon/Ribbon.module.css +6 -6
- package/es/Ribbon/__tests__/__snapshots__/Ribbon.spec.js.snap +374 -374
- package/es/Stencils/__tests__/__snapshots__/Stencils.spec.js.snap +89 -89
- package/es/Switch/Switch.module.css +2 -1
- package/es/Switch/__tests__/__snapshots__/Switch.spec.js.snap +831 -831
- package/es/Tab/Tabs.js +20 -124
- package/es/Tab/Tabs.module.css +1 -32
- package/es/Tab/props/defaultProps.js +1 -3
- package/es/Tab/props/propTypes.js +1 -6
- package/es/Tooltip/Tooltip.module.css +3 -0
- package/es/v1/AppContainer/AppContainer.js +0 -1
- package/es/v1/Avatar/Avatar.js +5 -5
- package/es/v1/AvatarTeam/AvatarTeam.js +4 -4
- package/es/v1/Button/Button.js +4 -4
- package/es/v1/Card/Card.js +4 -4
- package/es/v1/ListItem/ListItemWithAvatar.js +5 -9
- package/es/v1/ListItem/props/defaultProps.js +0 -1
- package/es/v1/ListItem/props/propTypes.js +1 -4
- package/es/v1/MultiSelect/Suggestions.js +0 -2
- package/es/v1/MultiSelect/props/propTypes.js +0 -1
- package/es/v1/Tab/v1Tabs.module.css +3 -3
- package/lib/AppContainer/AppContainer.js +0 -2
- package/lib/Avatar/Avatar.js +9 -9
- package/lib/Avatar/Avatar.module.css +2 -2
- package/lib/Avatar/__tests__/__snapshots__/Avatar.spec.js.snap +591 -591
- package/lib/AvatarTeam/__tests__/__snapshots__/AvatarTeam.spec.js.snap +705 -705
- package/lib/Button/css/Button.module.css +22 -6
- package/lib/Buttongroup/Buttongroup.module.css +1 -1
- package/lib/DateTime/DateTime.module.css +11 -8
- package/lib/DropBox/DropBoxElement/css/DropBoxElement.module.css +24 -9
- package/lib/DropBox/css/DropBox.module.css +1 -1
- package/lib/Label/__tests__/__snapshots__/Label.spec.js.snap +312 -312
- package/lib/ListItem/ListItemWithAvatar.js +5 -9
- package/lib/ListItem/props/defaultProps.js +0 -1
- package/lib/ListItem/props/propTypes.js +2 -4
- package/lib/MultiSelect/Suggestions.js +0 -2
- package/lib/MultiSelect/props/propTypes.js +0 -1
- package/lib/Radio/Radio.js +3 -2
- package/lib/Radio/Radio.module.css +2 -1
- package/lib/Radio/props/propTypes.js +2 -1
- package/lib/Ribbon/Ribbon.module.css +6 -6
- package/lib/Ribbon/__tests__/__snapshots__/Ribbon.spec.js.snap +374 -374
- package/lib/Stencils/__tests__/__snapshots__/Stencils.spec.js.snap +89 -89
- package/lib/Switch/Switch.module.css +2 -1
- package/lib/Switch/__tests__/__snapshots__/Switch.spec.js.snap +831 -831
- package/lib/Tab/Tabs.js +27 -125
- package/lib/Tab/Tabs.module.css +1 -32
- package/lib/Tab/props/defaultProps.js +1 -3
- package/lib/Tab/props/propTypes.js +1 -6
- package/lib/Tooltip/Tooltip.module.css +3 -0
- package/lib/v1/AppContainer/AppContainer.js +0 -2
- package/lib/v1/Avatar/Avatar.js +5 -5
- package/lib/v1/AvatarTeam/AvatarTeam.js +4 -4
- package/lib/v1/Button/Button.js +4 -4
- package/lib/v1/Card/Card.js +4 -4
- package/lib/v1/ListItem/ListItemWithAvatar.js +5 -9
- package/lib/v1/ListItem/props/defaultProps.js +0 -1
- package/lib/v1/ListItem/props/propTypes.js +2 -4
- package/lib/v1/MultiSelect/Suggestions.js +0 -2
- package/lib/v1/MultiSelect/props/propTypes.js +0 -1
- package/lib/v1/Tab/v1Tabs.module.css +3 -3
- package/package.json +17 -13
- package/propValidationArg.json +11 -11
- package/result.json +1 -1
- /package/es/{select → Select}/GroupSelect.js +0 -0
- /package/es/{select → Select}/Select.js +0 -0
- /package/es/{select → Select}/Select.module.css +0 -0
- /package/es/{select → Select}/SelectWithAvatar.js +0 -0
- /package/es/{select → Select}/SelectWithIcon.js +0 -0
- /package/es/{select → Select}/__tests__/GroupSelect.spec.js +0 -0
- /package/es/{select → Select}/__tests__/Select.spec.js +0 -0
- /package/es/{select → Select}/__tests__/SelectWithAvatar.spec.js +0 -0
- /package/es/{select → Select}/__tests__/SelectWithIcon.spec.js +0 -0
- /package/es/{select → Select}/__tests__/__snapshots__/GroupSelect.spec.js.snap +0 -0
- /package/es/{select → Select}/__tests__/__snapshots__/Select.spec.js.snap +0 -0
- /package/es/{select → Select}/__tests__/__snapshots__/SelectWithAvatar.spec.js.snap +0 -0
- /package/es/{select → Select}/__tests__/__snapshots__/SelectWithIcon.spec.js.snap +0 -0
- /package/es/{select → Select}/index.js +0 -0
- /package/es/{select → Select}/props/defaultProps.js +0 -0
- /package/es/{select → Select}/props/propTypes.js +0 -0
- /package/es/{common → deprecated}/boxShadow.module.css +0 -0
- /package/lib/{select → Select}/GroupSelect.js +0 -0
- /package/lib/{select → Select}/Select.js +0 -0
- /package/lib/{select → Select}/Select.module.css +0 -0
- /package/lib/{select → Select}/SelectWithAvatar.js +0 -0
- /package/lib/{select → Select}/SelectWithIcon.js +0 -0
- /package/lib/{select → Select}/__tests__/GroupSelect.spec.js +0 -0
- /package/lib/{select → Select}/__tests__/Select.spec.js +0 -0
- /package/lib/{select → Select}/__tests__/SelectWithAvatar.spec.js +0 -0
- /package/lib/{select → Select}/__tests__/SelectWithIcon.spec.js +0 -0
- /package/lib/{select → Select}/__tests__/__snapshots__/GroupSelect.spec.js.snap +0 -0
- /package/lib/{select → Select}/__tests__/__snapshots__/Select.spec.js.snap +0 -0
- /package/lib/{select → Select}/__tests__/__snapshots__/SelectWithAvatar.spec.js.snap +0 -0
- /package/lib/{select → Select}/__tests__/__snapshots__/SelectWithIcon.spec.js.snap +0 -0
- /package/lib/{select → Select}/index.js +0 -0
- /package/lib/{select → Select}/props/defaultProps.js +0 -0
- /package/lib/{select → Select}/props/propTypes.js +0 -0
- /package/lib/{common → deprecated}/boxShadow.module.css +0 -0
package/es/Tab/Tabs.js
CHANGED
|
@@ -8,7 +8,6 @@
|
|
|
8
8
|
}]
|
|
9
9
|
*/
|
|
10
10
|
import React from 'react';
|
|
11
|
-
import EmptySearch from '@zohodesk/svg/lib/emptystate/version3/EmptySearch';
|
|
12
11
|
import Tab from './Tab';
|
|
13
12
|
import { Tabs_defaultProps } from './props/defaultProps';
|
|
14
13
|
import { Tabs_propTypes } from './props/propTypes';
|
|
@@ -19,7 +18,6 @@ import ListItem from '../ListItem/ListItem';
|
|
|
19
18
|
import { Icon } from '@zohodesk/icons';
|
|
20
19
|
import tabsStyle from './Tabs.module.css';
|
|
21
20
|
import Popup from '../Popup/Popup';
|
|
22
|
-
import TextBoxIcon from '../TextBoxIcon/TextBoxIcon';
|
|
23
21
|
import ResponsiveDropBox from '../ResponsiveDropBox/ResponsiveDropBox';
|
|
24
22
|
import { ResponsiveReceiver } from '../Responsive/CustomResponsive';
|
|
25
23
|
import btnstyle from '../semantic/Button/semanticButton.module.css';
|
|
@@ -32,10 +30,9 @@ class Tabs extends React.Component {
|
|
|
32
30
|
tabDimensions: {},
|
|
33
31
|
highlightInitialDimension: null,
|
|
34
32
|
renderVirtualTabs: true,
|
|
35
|
-
tabKeys: []
|
|
36
|
-
searchValue: ''
|
|
33
|
+
tabKeys: []
|
|
37
34
|
};
|
|
38
|
-
bind.apply(this, ['moreTabSelect', 'onResize', 'onTabResize', 'getHighlightRef', 'getTabsRef', 'getTabRef', 'getHighlightDim', 'onSizeChange', 'onScroll', 'togglePopup', 'setMaxDim'
|
|
35
|
+
bind.apply(this, ['moreTabSelect', 'onResize', 'onTabResize', 'getHighlightRef', 'getTabsRef', 'getTabRef', 'getHighlightDim', 'onSizeChange', 'onScroll', 'togglePopup', 'setMaxDim']);
|
|
39
36
|
this.tabsObserver = new ResizeObserver(this.onResize);
|
|
40
37
|
this.tabObserver = {};
|
|
41
38
|
}
|
|
@@ -133,14 +130,12 @@ class Tabs extends React.Component {
|
|
|
133
130
|
let {
|
|
134
131
|
children,
|
|
135
132
|
selectedTab,
|
|
136
|
-
childType
|
|
137
|
-
isPopupOpen
|
|
133
|
+
childType
|
|
138
134
|
} = this.props;
|
|
139
135
|
let {
|
|
140
136
|
tabDimensions,
|
|
141
137
|
totalDimension,
|
|
142
|
-
tabKeys
|
|
143
|
-
searchValue
|
|
138
|
+
tabKeys
|
|
144
139
|
} = this.state;
|
|
145
140
|
|
|
146
141
|
if (prevProps.children && children) {
|
|
@@ -174,10 +169,6 @@ class Tabs extends React.Component {
|
|
|
174
169
|
if (prevProps.selectedTab !== selectedTab || newTabKeys.length === 1) {
|
|
175
170
|
this.moveHighlight();
|
|
176
171
|
}
|
|
177
|
-
|
|
178
|
-
if (prevProps.isPopupOpen != isPopupOpen && searchValue.length) {
|
|
179
|
-
this.handleSearchValueClear();
|
|
180
|
-
}
|
|
181
172
|
}
|
|
182
173
|
}
|
|
183
174
|
|
|
@@ -382,7 +373,6 @@ class Tabs extends React.Component {
|
|
|
382
373
|
|
|
383
374
|
e.preventDefault();
|
|
384
375
|
onSelect(tab);
|
|
385
|
-
this.togglePopup();
|
|
386
376
|
}
|
|
387
377
|
|
|
388
378
|
onScroll(e) {
|
|
@@ -417,69 +407,6 @@ class Tabs extends React.Component {
|
|
|
417
407
|
};
|
|
418
408
|
}
|
|
419
409
|
|
|
420
|
-
handleChange(value, e) {
|
|
421
|
-
this.setState({
|
|
422
|
-
searchValue: value
|
|
423
|
-
});
|
|
424
|
-
}
|
|
425
|
-
|
|
426
|
-
handleSearchValueClear(e) {
|
|
427
|
-
this.setState({
|
|
428
|
-
searchValue: ''
|
|
429
|
-
});
|
|
430
|
-
}
|
|
431
|
-
|
|
432
|
-
getMoreList(_ref2) {
|
|
433
|
-
let {
|
|
434
|
-
moreTabs
|
|
435
|
-
} = _ref2;
|
|
436
|
-
const valideElements = [];
|
|
437
|
-
{
|
|
438
|
-
React.Children.map(moreTabs, child => {
|
|
439
|
-
const isValidElement = /*#__PURE__*/React.isValidElement(child);
|
|
440
|
-
|
|
441
|
-
if (isValidElement) {
|
|
442
|
-
valideElements.push(child.props);
|
|
443
|
-
}
|
|
444
|
-
});
|
|
445
|
-
}
|
|
446
|
-
return valideElements;
|
|
447
|
-
}
|
|
448
|
-
|
|
449
|
-
handleFilterSuggestions(_ref3) {
|
|
450
|
-
let {
|
|
451
|
-
moreTabs
|
|
452
|
-
} = _ref3;
|
|
453
|
-
const {
|
|
454
|
-
searchValue
|
|
455
|
-
} = this.state;
|
|
456
|
-
const options = this.getMoreList({
|
|
457
|
-
moreTabs
|
|
458
|
-
});
|
|
459
|
-
const filteredOptions = options.filter(list => {
|
|
460
|
-
const {
|
|
461
|
-
id = ''
|
|
462
|
-
} = list;
|
|
463
|
-
const value = id;
|
|
464
|
-
return value.toLowerCase().includes(searchValue);
|
|
465
|
-
});
|
|
466
|
-
return filteredOptions;
|
|
467
|
-
}
|
|
468
|
-
|
|
469
|
-
renderEmptyState() {
|
|
470
|
-
const {
|
|
471
|
-
searchErrorText
|
|
472
|
-
} = this.props;
|
|
473
|
-
return /*#__PURE__*/React.createElement("div", {
|
|
474
|
-
className: tabsStyle.emptyStateContainer
|
|
475
|
-
}, /*#__PURE__*/React.createElement(EmptySearch, {
|
|
476
|
-
size: "small"
|
|
477
|
-
}), /*#__PURE__*/React.createElement("div", {
|
|
478
|
-
className: tabsStyle.emptyStateTitle
|
|
479
|
-
}, searchErrorText));
|
|
480
|
-
return ''; // return <EmptySearch size='small' />;
|
|
481
|
-
}
|
|
482
|
-
|
|
483
410
|
renderTabs(mainTabs, moreTabs, isVirtual) {
|
|
484
411
|
let {
|
|
485
412
|
selectedTab,
|
|
@@ -507,26 +434,14 @@ class Tabs extends React.Component {
|
|
|
507
434
|
customProps,
|
|
508
435
|
getCustomDropBoxHeaderPlaceHolder,
|
|
509
436
|
dataSelectorId,
|
|
510
|
-
dataId
|
|
511
|
-
placeHolderText,
|
|
512
|
-
searchBoxSize,
|
|
513
|
-
ariaTitleId,
|
|
514
|
-
TextBoxIconProps,
|
|
515
|
-
removeClose
|
|
437
|
+
dataId
|
|
516
438
|
} = this.props;
|
|
517
|
-
const {
|
|
518
|
-
searchValue
|
|
519
|
-
} = this.state;
|
|
520
439
|
let {
|
|
521
440
|
DropBoxProps = {},
|
|
522
441
|
ListItemProps = {},
|
|
523
442
|
MoreButtonProps = {}
|
|
524
443
|
} = customProps;
|
|
525
444
|
let popupClass = align === 'vertical' ? tabsStyle[position] ? tabsStyle[position] : '' : '';
|
|
526
|
-
const listItemArray = this.handleFilterSuggestions({
|
|
527
|
-
moreTabs
|
|
528
|
-
});
|
|
529
|
-
const isSearch = moreTabs.length > 4;
|
|
530
445
|
return /*#__PURE__*/React.createElement(React.Fragment, null, React.Children.map(mainTabs, child => {
|
|
531
446
|
if (!child) {
|
|
532
447
|
return null;
|
|
@@ -576,10 +491,10 @@ class Tabs extends React.Component {
|
|
|
576
491
|
})), isPopupOpen && /*#__PURE__*/React.createElement(ResponsiveReceiver, {
|
|
577
492
|
query: this.responsiveFunc,
|
|
578
493
|
responsiveId: "Helmet"
|
|
579
|
-
},
|
|
494
|
+
}, _ref2 => {
|
|
580
495
|
let {
|
|
581
496
|
tabletMode
|
|
582
|
-
} =
|
|
497
|
+
} = _ref2;
|
|
583
498
|
return /*#__PURE__*/React.createElement(ResponsiveDropBox, {
|
|
584
499
|
isActive: isPopupReady,
|
|
585
500
|
isAnimate: true,
|
|
@@ -589,44 +504,25 @@ class Tabs extends React.Component {
|
|
|
589
504
|
},
|
|
590
505
|
boxPosition: position,
|
|
591
506
|
getRef: getContainerRef,
|
|
592
|
-
isBoxPaddingNeed:
|
|
507
|
+
isBoxPaddingNeed: true,
|
|
593
508
|
isArrow: false,
|
|
594
509
|
...DropBoxProps,
|
|
595
510
|
isResponsivePadding: true,
|
|
596
511
|
needFocusScope: true,
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
}, getCustomDropBoxHeaderPlaceHolder && getCustomDropBoxHeaderPlaceHolder(this.props),
|
|
600
|
-
className: tabsStyle.search
|
|
601
|
-
}, /*#__PURE__*/React.createElement(TextBoxIcon, {
|
|
602
|
-
placeHolder: placeHolderText,
|
|
603
|
-
onChange: this.handleChange,
|
|
604
|
-
value: searchValue,
|
|
605
|
-
onClear: this.handleSearchValueClear,
|
|
606
|
-
size: searchBoxSize,
|
|
607
|
-
customProps: {
|
|
608
|
-
TextBoxProps: {
|
|
609
|
-
'data-a11y-autofocus': true
|
|
610
|
-
}
|
|
611
|
-
} //search
|
|
612
|
-
,
|
|
613
|
-
dataId: `${dataId}_search`,
|
|
614
|
-
a11y: {
|
|
615
|
-
role: 'combobox',
|
|
616
|
-
ariaOwns: ariaTitleId,
|
|
617
|
-
ariaAutocomplete: 'list',
|
|
618
|
-
ariaHaspopup: true,
|
|
619
|
-
ariaExpanded: true
|
|
620
|
-
},
|
|
621
|
-
...TextBoxIconProps
|
|
622
|
-
})) : null, /*#__PURE__*/React.createElement(Box, {
|
|
512
|
+
onClose: this.togglePopup,
|
|
513
|
+
dataId: `${dataId}_dropbox`
|
|
514
|
+
}, getCustomDropBoxHeaderPlaceHolder && getCustomDropBoxHeaderPlaceHolder(this.props), /*#__PURE__*/React.createElement(Box, {
|
|
623
515
|
flexible: true,
|
|
624
516
|
shrink: true,
|
|
625
517
|
scroll: "vertical",
|
|
626
|
-
className: `${
|
|
518
|
+
className: `${tabletMode ? '' : tabsStyle.menuBox} ${moreBoxClass}`,
|
|
627
519
|
onScroll: this.onScroll,
|
|
628
520
|
dataId: `${dataId}_Tabs`
|
|
629
|
-
},
|
|
521
|
+
}, React.Children.map(moreTabs, child => {
|
|
522
|
+
if (!child) {
|
|
523
|
+
return null;
|
|
524
|
+
}
|
|
525
|
+
|
|
630
526
|
let {
|
|
631
527
|
text,
|
|
632
528
|
id,
|
|
@@ -635,9 +531,9 @@ class Tabs extends React.Component {
|
|
|
635
531
|
href,
|
|
636
532
|
children,
|
|
637
533
|
dataId
|
|
638
|
-
} =
|
|
534
|
+
} = child.props;
|
|
639
535
|
const value = text ? text : showTitleInMoreOptions ? title : null;
|
|
640
|
-
return /*#__PURE__*/React.createElement(ListItem, {
|
|
536
|
+
return /*#__PURE__*/React.isValidElement(child) && /*#__PURE__*/React.createElement(ListItem, {
|
|
641
537
|
key: id,
|
|
642
538
|
value: value,
|
|
643
539
|
onClick: this.moreTabSelect,
|
|
@@ -653,7 +549,7 @@ class Tabs extends React.Component {
|
|
|
653
549
|
dataId: `${dataId}_Tab`,
|
|
654
550
|
...ListItemProps
|
|
655
551
|
}, !showTitleInMoreOptions ? children : null);
|
|
656
|
-
})
|
|
552
|
+
})));
|
|
657
553
|
})) : null);
|
|
658
554
|
}
|
|
659
555
|
|
package/es/Tab/Tabs.module.css
CHANGED
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
bottom: 0 ;
|
|
32
32
|
height: var(--zd_size10) ;
|
|
33
33
|
border-radius: 100px / 5px;
|
|
34
|
-
box-shadow: var(--
|
|
34
|
+
box-shadow: 0 -2px 9px var(--zdt_tabs_alpha_box_shadow);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
[dir=ltr] .alpha::after {
|
|
@@ -134,35 +134,4 @@
|
|
|
134
134
|
|
|
135
135
|
.hidden {
|
|
136
136
|
visibility: hidden;
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
.search {
|
|
140
|
-
padding: 0 var(--zd_size20) 0 ;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
.emptyStateContainer {
|
|
144
|
-
padding-bottom: var(--zd_size25);
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
.emptyStateTitle {
|
|
148
|
-
font-family: var(--zd_semibold);
|
|
149
|
-
color: var(--zdt_commonEmptyState_default_title);
|
|
150
|
-
word-wrap: break-word;
|
|
151
|
-
font-size: var(--zd_font_size16) ;
|
|
152
|
-
max-width: var(--zd_size430) ;
|
|
153
|
-
text-align: center;
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
[dir=ltr] .emptyStateTitle {
|
|
157
|
-
margin-left: auto ;
|
|
158
|
-
margin-right: auto ;
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
[dir=rtl] .emptyStateTitle {
|
|
162
|
-
margin-right: auto ;
|
|
163
|
-
margin-left: auto ;
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
.listWrapper {
|
|
167
|
-
padding: var(--zd_size10) 0 ;
|
|
168
137
|
}
|
|
@@ -30,9 +30,7 @@ export const Tabs_defaultProps = {
|
|
|
30
30
|
iconSize: '7',
|
|
31
31
|
containerClass: '',
|
|
32
32
|
customProps: {},
|
|
33
|
-
dataSelectorId: 'tabs'
|
|
34
|
-
searchBoxSize: 'small',
|
|
35
|
-
searchErrorText: 'No results'
|
|
33
|
+
dataSelectorId: 'tabs'
|
|
36
34
|
};
|
|
37
35
|
export const TabWrapper_defaultProps = {
|
|
38
36
|
hookToDisableInternalState: false,
|
|
@@ -89,12 +89,7 @@ export const Tabs_propTypes = {
|
|
|
89
89
|
MoreButtonProps: PropTypes.object
|
|
90
90
|
}),
|
|
91
91
|
getCustomDropBoxHeaderPlaceHolder: PropTypes.func,
|
|
92
|
-
dataSelectorId: PropTypes.string
|
|
93
|
-
placeHolderText: PropTypes.string,
|
|
94
|
-
searchBoxSize: PropTypes.string,
|
|
95
|
-
ariaTitleId: PropTypes.string,
|
|
96
|
-
TextBoxIconProps: PropTypes.object,
|
|
97
|
-
searchErrorText: PropTypes.string
|
|
92
|
+
dataSelectorId: PropTypes.string
|
|
98
93
|
};
|
|
99
94
|
export const TabWrapper_propTypes = {
|
|
100
95
|
align: PropTypes.oneOf(['vertical', 'horizontal']),
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
z-index: 9999999;
|
|
4
4
|
/*Hook for editor alert*/
|
|
5
5
|
pointer-events: none;
|
|
6
|
+
/*css:validation:ignore*/
|
|
6
7
|
box-shadow: 0 4px 12px 0 var(--zdt_tooltip_default_box_shadow);
|
|
7
8
|
border-radius: var(--zd_size4);
|
|
8
9
|
}[dir=ltr] .tooltiptext {
|
|
@@ -51,6 +52,7 @@
|
|
|
51
52
|
border-left: solid 6px var(--zdt_tooltip_default_bg);
|
|
52
53
|
border-right: solid 6px transparent;
|
|
53
54
|
border-bottom: solid 6px transparent;
|
|
55
|
+
/*css:validation:ignore*/
|
|
54
56
|
box-shadow: 0 4px 12px 0 var(--zdt_tooltip_default_box_shadow);
|
|
55
57
|
z-index: -1;
|
|
56
58
|
}
|
|
@@ -71,6 +73,7 @@
|
|
|
71
73
|
border-left: solid 6px var(--zdt_tooltip_default_bg);
|
|
72
74
|
border-right: solid 6px transparent;
|
|
73
75
|
border-bottom: solid 6px transparent;
|
|
76
|
+
/*css:validation:ignore*/
|
|
74
77
|
box-shadow: 0 4px 12px 0 var(--zdt_tooltip_default_box_shadow);
|
|
75
78
|
z-index: -1;
|
|
76
79
|
}
|
|
@@ -12,7 +12,6 @@ import '@zohodesk/variables/lib/fontFamilyVariables.module.css';
|
|
|
12
12
|
import '@zohodesk/variables/assets/transitionVariables.module.css';
|
|
13
13
|
import '@zohodesk/variables/assets/no_transitionVariables.module.css';
|
|
14
14
|
import '../../common/a11y.module.css';
|
|
15
|
-
import '../../common/boxShadow.module.css';
|
|
16
15
|
import style from '../../AppContainer/AppContainer.module.css';
|
|
17
16
|
import { getLibraryConfig, setLibraryConfig } from '../../Provider/Config';
|
|
18
17
|
export default function AppContainer(props) {
|
package/es/v1/Avatar/Avatar.js
CHANGED
|
@@ -5,11 +5,11 @@ import { propTypes } from './props/propTypes';
|
|
|
5
5
|
import { getInitial } from '../../utils/getInitial';
|
|
6
6
|
import AvatarSize from '../../Provider/AvatarSize';
|
|
7
7
|
import style from '../../Avatar/Avatar.module.css';
|
|
8
|
-
/*
|
|
9
|
-
1. need to change name into firstName lastName
|
|
10
|
-
2. pattern support via context as well as props
|
|
11
|
-
3. prop high priority to arrange firstName lastName
|
|
12
|
-
4. team pass name as lastName and pass pattern via prop
|
|
8
|
+
/*
|
|
9
|
+
1. need to change name into firstName lastName
|
|
10
|
+
2. pattern support via context as well as props
|
|
11
|
+
3. prop high priority to arrange firstName lastName
|
|
12
|
+
4. team pass name as lastName and pass pattern via prop
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
function Avatar(props) {
|
|
@@ -3,10 +3,10 @@ import { defaultProps } from './props/defaultProps';
|
|
|
3
3
|
import { propTypes } from './props/propTypes';
|
|
4
4
|
import Avatar from '../Avatar/Avatar';
|
|
5
5
|
import style from '../../AvatarTeam/AvatarTeam.module.css';
|
|
6
|
-
/* once avatar support firstname lastname and pattern
|
|
7
|
-
pass lastName as team name and pattern ["FIRST_NAME","LAST_NAME"] as props
|
|
8
|
-
|
|
9
|
-
Not going to export to external then can kept inside supportapp
|
|
6
|
+
/* once avatar support firstname lastname and pattern
|
|
7
|
+
pass lastName as team name and pattern ["FIRST_NAME","LAST_NAME"] as props
|
|
8
|
+
|
|
9
|
+
Not going to export to external then can kept inside supportapp
|
|
10
10
|
*/
|
|
11
11
|
|
|
12
12
|
export default function AvatarTeam(props) {
|
package/es/v1/Button/Button.js
CHANGED
|
@@ -4,10 +4,10 @@ import { propTypes } from './props/propTypes';
|
|
|
4
4
|
import cssJSLogic from '../../Button/css/cssJSLogic';
|
|
5
5
|
import { mergeStyle } from '@zohodesk/utils';
|
|
6
6
|
import style from '../../Button/css/Button.module.css';
|
|
7
|
-
/*
|
|
8
|
-
Button text and children props?
|
|
9
|
-
use children for both cases
|
|
10
|
-
toLowerCase check needed?
|
|
7
|
+
/*
|
|
8
|
+
Button text and children props?
|
|
9
|
+
use children for both cases
|
|
10
|
+
toLowerCase check needed?
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
13
|
export default function Button(props) {
|
package/es/v1/Card/Card.js
CHANGED
|
@@ -7,10 +7,10 @@ import { getLibraryConfig } from '../../Provider/Config';
|
|
|
7
7
|
import style from '../../Card/Card.module.css';
|
|
8
8
|
/* eslint-disable react/forbid-component-props */
|
|
9
9
|
|
|
10
|
-
/*
|
|
11
|
-
isscroll header border change use ref
|
|
12
|
-
scroll logic remove from here
|
|
13
|
-
scroll logic move to virtualizer list
|
|
10
|
+
/*
|
|
11
|
+
isscroll header border change use ref
|
|
12
|
+
scroll logic remove from here
|
|
13
|
+
scroll logic move to virtualizer list
|
|
14
14
|
*/
|
|
15
15
|
|
|
16
16
|
/* performance handling pending in card component moving to ref instead of setState */
|
|
@@ -16,7 +16,6 @@ import style from '../../ListItem/ListItem.module.css';
|
|
|
16
16
|
const ListItemWithAvatar = props => {
|
|
17
17
|
let {
|
|
18
18
|
size,
|
|
19
|
-
avatarSize,
|
|
20
19
|
active,
|
|
21
20
|
highlight,
|
|
22
21
|
value,
|
|
@@ -43,8 +42,7 @@ const ListItemWithAvatar = props => {
|
|
|
43
42
|
id,
|
|
44
43
|
getRef,
|
|
45
44
|
onClick,
|
|
46
|
-
onMouseEnter
|
|
47
|
-
onAvatarClick
|
|
45
|
+
onMouseEnter
|
|
48
46
|
} = props;
|
|
49
47
|
|
|
50
48
|
function handleRef(ele) {
|
|
@@ -102,7 +100,7 @@ const ListItemWithAvatar = props => {
|
|
|
102
100
|
className: style.leftAvatar
|
|
103
101
|
}, isTeam ? /*#__PURE__*/React.createElement(AvatarTeam, {
|
|
104
102
|
name: name,
|
|
105
|
-
size:
|
|
103
|
+
size: "small",
|
|
106
104
|
src: imgSrc,
|
|
107
105
|
needTitle: needAvatarTitle,
|
|
108
106
|
textPalette: isDarkPalette ? 'white' : '',
|
|
@@ -110,18 +108,16 @@ const ListItemWithAvatar = props => {
|
|
|
110
108
|
customClass: {
|
|
111
109
|
customAvatar: customAvatar,
|
|
112
110
|
customAvatarTeam: customAvatarTeam
|
|
113
|
-
}
|
|
114
|
-
onClick: onAvatarClick
|
|
111
|
+
}
|
|
115
112
|
}) : /*#__PURE__*/React.createElement(Avatar, {
|
|
116
113
|
name: name,
|
|
117
|
-
size:
|
|
114
|
+
size: "small",
|
|
118
115
|
src: imgSrc,
|
|
119
116
|
initial: initial,
|
|
120
117
|
textPalette: isDarkPalette ? 'white' : '',
|
|
121
118
|
needTitle: needAvatarTitle,
|
|
122
119
|
palette: isDarkPalette ? 'info' : avatarPalette,
|
|
123
|
-
customClass: customAvatar
|
|
124
|
-
onClick: onAvatarClick
|
|
120
|
+
customClass: customAvatar
|
|
125
121
|
})) : null, value ? /*#__PURE__*/React.createElement(Box, {
|
|
126
122
|
flexible: true,
|
|
127
123
|
shrink: true,
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import PropTypes from 'prop-types';
|
|
2
|
-
import { propTypes as AvatarProps } from '../../Avatar/props/propTypes.js';
|
|
3
2
|
export const ListContainer_Props = {
|
|
4
3
|
active: PropTypes.bool,
|
|
5
4
|
autoHover: PropTypes.bool,
|
|
@@ -88,7 +87,6 @@ export const ListItemWithAvatar_Props = {
|
|
|
88
87
|
onMouseEnter: PropTypes.func,
|
|
89
88
|
palette: PropTypes.oneOf(['dark']),
|
|
90
89
|
size: PropTypes.string,
|
|
91
|
-
avatarSize: AvatarProps.size,
|
|
92
90
|
title: PropTypes.string,
|
|
93
91
|
value: PropTypes.string,
|
|
94
92
|
a11y: PropTypes.shape({
|
|
@@ -104,8 +102,7 @@ export const ListItemWithAvatar_Props = {
|
|
|
104
102
|
needMultiLineText: PropTypes.bool,
|
|
105
103
|
customProps: PropTypes.shape({
|
|
106
104
|
ListItemProps: PropTypes.object
|
|
107
|
-
})
|
|
108
|
-
onAvatarClick: PropTypes.func
|
|
105
|
+
})
|
|
109
106
|
};
|
|
110
107
|
export const ListItemWithCheckBox_Props = {
|
|
111
108
|
active: PropTypes.bool,
|
|
@@ -15,7 +15,6 @@ export default class Suggestions extends React.PureComponent {
|
|
|
15
15
|
getRef,
|
|
16
16
|
hoverOption,
|
|
17
17
|
onClick,
|
|
18
|
-
onAvatarClick,
|
|
19
18
|
onMouseEnter,
|
|
20
19
|
needTick,
|
|
21
20
|
needBorder,
|
|
@@ -84,7 +83,6 @@ export default class Suggestions extends React.PureComponent {
|
|
|
84
83
|
key: `${id}avatarListItem`,
|
|
85
84
|
name: value,
|
|
86
85
|
onClick: onClick,
|
|
87
|
-
onAvatarClick: onAvatarClick,
|
|
88
86
|
onMouseEnter: onMouseEnter,
|
|
89
87
|
value: value,
|
|
90
88
|
title: value,
|
|
@@ -158,7 +158,6 @@ export const Suggestions_propTypes = {
|
|
|
158
158
|
needBorder: PropTypes.bool,
|
|
159
159
|
needTick: PropTypes.bool,
|
|
160
160
|
onClick: PropTypes.func,
|
|
161
|
-
onAvatarClick: PropTypes.func,
|
|
162
161
|
onMouseEnter: PropTypes.func,
|
|
163
162
|
palette: PropTypes.string,
|
|
164
163
|
selectedOptions: PropTypes.array,
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
bottom: 0 ;
|
|
32
32
|
height: var(--zd_size10) ;
|
|
33
33
|
border-radius: 100px / 5px;
|
|
34
|
-
box-shadow: var(--
|
|
34
|
+
box-shadow: 0 -2px 9px var(--zdt_tabs_alpha_box_shadow);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
[dir=ltr] .alpha::after {
|
|
@@ -123,13 +123,13 @@
|
|
|
123
123
|
.bottomRightToLeft,
|
|
124
124
|
.topRightToLeft,
|
|
125
125
|
.bottomCenterToLeft {
|
|
126
|
-
right: calc(var(--tab_position_gap) * -1);
|
|
126
|
+
right: calc(var(--tab_position_gap) * -1);
|
|
127
127
|
}
|
|
128
128
|
|
|
129
129
|
.bottomLeftToRight,
|
|
130
130
|
.topLeftToRight,
|
|
131
131
|
.bottomCenterToRight {
|
|
132
|
-
left: calc(var(--tab_position_gap) * -1);
|
|
132
|
+
left: calc(var(--tab_position_gap) * -1);
|
|
133
133
|
}
|
|
134
134
|
|
|
135
135
|
.hidden {
|
|
@@ -35,8 +35,6 @@ require("@zohodesk/variables/assets/no_transitionVariables.module.css");
|
|
|
35
35
|
|
|
36
36
|
require("../common/a11y.module.css");
|
|
37
37
|
|
|
38
|
-
require("../common/boxShadow.module.css");
|
|
39
|
-
|
|
40
38
|
var _AppContainerModule = _interopRequireDefault(require("./AppContainer.module.css"));
|
|
41
39
|
|
|
42
40
|
var _Config = require("../Provider/Config");
|
package/lib/Avatar/Avatar.js
CHANGED
|
@@ -55,17 +55,17 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
55
55
|
|
|
56
56
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
57
57
|
|
|
58
|
-
/*
|
|
59
|
-
1. need to change name into firstName lastName
|
|
60
|
-
2. pattern support via context as well as props
|
|
61
|
-
3. prop high priority to arrange firstName lastName
|
|
62
|
-
4. team pass name as lastName and pass pattern via prop
|
|
58
|
+
/*
|
|
59
|
+
1. need to change name into firstName lastName
|
|
60
|
+
2. pattern support via context as well as props
|
|
61
|
+
3. prop high priority to arrange firstName lastName
|
|
62
|
+
4. team pass name as lastName and pass pattern via prop
|
|
63
63
|
*/
|
|
64
64
|
|
|
65
|
-
/*
|
|
66
|
-
eslint css-modules/no-unused-class: [2, { markAsUsed: ['circle', 'square',
|
|
67
|
-
'small','medium','xmedium',"xsmall", "large", "xlarge", "primary", "secondary",
|
|
68
|
-
"info","default"] }]
|
|
65
|
+
/*
|
|
66
|
+
eslint css-modules/no-unused-class: [2, { markAsUsed: ['circle', 'square',
|
|
67
|
+
'small','medium','xmedium',"xsmall", "large", "xlarge", "primary", "secondary",
|
|
68
|
+
"info","default"] }]
|
|
69
69
|
*/
|
|
70
70
|
var Avatar = /*#__PURE__*/function (_React$Component) {
|
|
71
71
|
_inherits(Avatar, _React$Component);
|
|
@@ -53,11 +53,11 @@
|
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
.shadow.black {
|
|
56
|
-
box-shadow: var(--
|
|
56
|
+
box-shadow: inset 0px 0px 5px var(--avatar_boxshadow);
|
|
57
57
|
}
|
|
58
58
|
|
|
59
59
|
.shadow.white {
|
|
60
|
-
box-shadow: var(--
|
|
60
|
+
box-shadow: inset 0px 0px 11px var(--avatar_boxshadow);
|
|
61
61
|
}
|
|
62
62
|
|
|
63
63
|
.avatar, .circle {
|