@zohodesk/components 1.0.0-temp-220.8 → 1.0.0-temp-224
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -1
- package/es/Accordion/Accordion.js +2 -2
- package/es/Accordion/AccordionItem.js +4 -4
- package/es/Accordion/__tests__/Accordion.spec.js +1 -1
- package/es/Accordion/__tests__/AccordionItem.spec.js +1 -1
- package/es/Accordion/index.js +2 -2
- package/es/Animation/Animation.js +3 -3
- package/es/Animation/__tests__/Animation.spec.js +1 -1
- package/es/Animation/utils.js +1 -1
- package/es/AppContainer/AppContainer.js +9 -9
- package/es/AppContainer/__tests__/AppContainer.spec.js +1 -1
- package/es/Avatar/Avatar.js +5 -5
- package/es/Avatar/__tests__/Avatar.spec.js +1 -1
- package/es/AvatarTeam/AvatarTeam.js +4 -4
- package/es/AvatarTeam/__tests__/AvatarTeam.spec.js +1 -1
- package/es/AvatarTeam/props/propTypes.js +1 -1
- package/es/Button/Button.js +4 -4
- package/es/Button/__tests__/Button.spec.js +1 -1
- package/es/Button/index.js +2 -2
- package/es/Button/props/defaultProps.js +1 -1
- package/es/Buttongroup/Buttongroup.js +3 -3
- package/es/Buttongroup/__tests__/Buttongroup.spec.js +1 -1
- package/es/Card/Card.js +5 -5
- package/es/Card/__tests__/Card.spec.js +1 -1
- package/es/Card/index.js +4 -4
- package/es/CheckBox/CheckBox.js +6 -6
- package/es/CheckBox/__tests__/CheckBox.spec.js +1 -1
- package/es/DateTime/CalendarView.js +6 -6
- package/es/DateTime/DateTime.js +15 -15
- package/es/DateTime/DateTimePopupFooter.js +5 -5
- package/es/DateTime/DateTimePopupHeader.js +4 -4
- package/es/DateTime/DateWidget.js +17 -17
- package/es/DateTime/DaysRow.js +3 -3
- package/es/DateTime/Time.js +5 -5
- package/es/DateTime/YearView.js +6 -6
- package/es/DateTime/__tests__/CalendarView.spec.js +1 -1
- package/es/DateTime/__tests__/DateTime.spec.js +1 -1
- package/es/DateTime/__tests__/DateTimePopupFooter.spec.js +1 -1
- package/es/DateTime/__tests__/DateTimePopupHeader.spec.js +1 -1
- package/es/DateTime/__tests__/DateWidget.spec.js +1 -1
- package/es/DateTime/__tests__/DaysRow.spec.js +1 -1
- package/es/DateTime/__tests__/Time.spec.js +1 -1
- package/es/DateTime/__tests__/YearView.spec.js +1 -1
- package/es/DateTime/dateFormatUtils/dateFormat.js +4 -4
- package/es/DateTime/dateFormatUtils/dayChange.js +2 -2
- package/es/DateTime/dateFormatUtils/index.js +3 -3
- package/es/DateTime/dateFormatUtils/monthChange.js +2 -2
- package/es/DateTime/dateFormatUtils/timeChange.js +2 -2
- package/es/DateTime/dateFormatUtils/yearChange.js +2 -2
- package/es/DateTime/index.js +1 -1
- package/es/DateTime/props/propTypes.js +1 -1
- package/es/DateTime/validator.js +2 -2
- package/es/DropBox/DropBox.js +9 -9
- package/es/DropBox/DropBoxElement/DropBoxElement.js +6 -6
- package/es/DropBox/DropBoxElement/__tests__/DropBoxElement.spec.js +1 -1
- package/es/DropBox/DropBoxElement/css/cssJSLogic.js +1 -1
- package/es/DropBox/DropBoxElement/useDropboxPosCalc.js +1 -1
- package/es/DropBox/__tests__/DropBox.spec.js +1 -1
- package/es/DropBox/css/cssJSLogic.js +1 -1
- package/es/DropBox/props/defaultProps.js +1 -1
- package/es/DropBox/props/propTypes.js +1 -1
- package/es/DropBox/utils/isMobilePopover.js +1 -1
- package/es/DropDown/DropDown.js +4 -4
- package/es/DropDown/DropDownHeading.js +3 -3
- package/es/DropDown/DropDownItem.js +3 -3
- package/es/DropDown/DropDownSearch.js +4 -4
- package/es/DropDown/DropDownSeparator.js +2 -2
- package/es/DropDown/__tests__/DropDown.spec.js +1 -1
- package/es/DropDown/__tests__/DropDownHeading.spec.js +1 -1
- package/es/DropDown/__tests__/DropDownItem.spec.js +1 -1
- package/es/DropDown/__tests__/DropDownSearch.spec.js +1 -1
- package/es/DropDown/__tests__/DropDownSeparator.spec.js +1 -1
- package/es/DropDown/index.js +7 -7
- package/es/DropDown/props/propTypes.js +1 -1
- package/es/Heading/Heading.js +4 -4
- package/es/Heading/__tests__/Heading.spec.js +1 -1
- package/es/Label/Label.js +4 -4
- package/es/Label/__tests__/Label.spec.js +1 -1
- package/es/Layout/Box.js +4 -4
- package/es/Layout/Container.js +4 -4
- package/es/Layout/__tests__/Box.spec.js +1 -1
- package/es/Layout/__tests__/Container.spec.js +1 -1
- package/es/Layout/index.js +2 -2
- package/es/ListItem/ListContainer.js +6 -6
- package/es/ListItem/ListItem.js +5 -5
- package/es/ListItem/ListItemWithAvatar.js +7 -7
- package/es/ListItem/ListItemWithCheckBox.js +6 -6
- package/es/ListItem/ListItemWithIcon.js +5 -5
- package/es/ListItem/ListItemWithRadio.js +6 -6
- package/es/ListItem/__tests__/ListContainer.spec.js +1 -1
- package/es/ListItem/__tests__/ListItem.spec.js +1 -1
- package/es/ListItem/__tests__/ListItemWithAvatar.spec.js +1 -1
- package/es/ListItem/__tests__/ListItemWithCheckBox.spec.js +1 -1
- package/es/ListItem/__tests__/ListItemWithIcon.spec.js +1 -1
- package/es/ListItem/__tests__/ListItemWithRadio.spec.js +1 -1
- package/es/ListItem/index.js +6 -6
- package/es/ListItem/props/propTypes.js +2 -2
- package/es/Modal/Modal.js +3 -3
- package/es/Modal/__tests__/Modal.spec.js +1 -1
- package/es/MultiSelect/AdvancedGroupMultiSelect.js +17 -17
- package/es/MultiSelect/AdvancedMultiSelect.js +17 -17
- package/es/MultiSelect/EmptyState.js +3 -3
- package/es/MultiSelect/MobileHeader/MobileHeader.js +5 -5
- package/es/MultiSelect/MobileHeader/__tests__/MobileHeader.spec.js +1 -1
- package/es/MultiSelect/MultiSelect.js +20 -20
- package/es/MultiSelect/MultiSelectHeader.js +4 -4
- package/es/MultiSelect/MultiSelectWithAvatar.js +16 -16
- package/es/MultiSelect/SelectedOptions.js +5 -5
- package/es/MultiSelect/Suggestions.js +6 -6
- package/es/MultiSelect/__tests__/AdvancedGroupMultiSelect.spec.js +1 -1
- package/es/MultiSelect/__tests__/AdvancedMultiSelect.spec.js +1 -1
- package/es/MultiSelect/__tests__/EmptyState.spec.js +1 -1
- package/es/MultiSelect/__tests__/MultiSelect.spec.js +1 -1
- package/es/MultiSelect/__tests__/MultiSelectHeader.spec.js +1 -1
- package/es/MultiSelect/__tests__/MultiSelectWithAvatar.spec.js +1 -1
- package/es/MultiSelect/__tests__/SelectedOptions.spec.js +1 -1
- package/es/MultiSelect/__tests__/Suggestions.spec.js +1 -1
- package/es/MultiSelect/index.js +4 -4
- package/es/MultiSelect/props/defaultProps.js +1 -1
- package/es/PopOver/PopOver.js +6 -6
- package/es/PopOver/__tests__/PopOver.spec.js +1 -1
- package/es/PopOver/index.js +3 -3
- package/es/Popup/Popup.js +46 -114
- package/es/Provider/AvatarSize.js +1 -1
- package/es/Provider/Config.js +1 -2
- package/es/Provider/CssProvider.js +1 -1
- package/es/Provider/IdProvider.js +2 -2
- package/es/Provider/LibraryContext.js +2 -2
- package/es/Provider/ZindexProvider.js +2 -2
- package/es/Provider/index.js +4 -4
- package/es/Radio/Radio.js +6 -6
- package/es/Radio/__tests__/Radio.spec.js +1 -1
- package/es/Responsive/CustomResponsive.js +7 -7
- package/es/Responsive/ResizeComponent.js +2 -2
- package/es/Responsive/Responsive.js +6 -6
- package/es/Responsive/index.js +3 -3
- package/es/Responsive/utils/index.js +1 -1
- package/es/Responsive/windowResizeObserver.js +1 -1
- package/es/ResponsiveDropBox/ResponsiveDropBox.js +6 -6
- package/es/ResponsiveDropBox/__tests__/ResponsiveDropBox.spec.js +1 -1
- package/es/ResponsiveDropBox/props/propTypes.js +1 -1
- package/es/Ribbon/Ribbon.js +3 -3
- package/es/Ribbon/__tests__/Ribbon.spec.js +1 -1
- package/es/RippleEffect/RippleEffect.js +4 -4
- package/es/RippleEffect/__tests__/RippleEffect.spec.js +1 -1
- package/es/Select/GroupSelect.js +16 -16
- package/es/Select/Select.js +15 -15
- package/es/Select/SelectWithAvatar.js +17 -17
- package/es/Select/SelectWithIcon.js +13 -13
- package/es/Select/__tests__/GroupSelect.spec.js +1 -1
- package/es/Select/__tests__/Select.spec.js +1 -1
- package/es/Select/__tests__/SelectWithAvatar.spec.js +1 -1
- package/es/Select/__tests__/SelectWithIcon.spec.js +1 -1
- package/es/Select/index.js +4 -4
- package/es/Select/props/defaultProps.js +1 -1
- package/es/Stencils/Stencils.js +3 -3
- package/es/Stencils/__tests__/Stencils.spec.js +1 -1
- package/es/Switch/Switch.js +5 -5
- package/es/Switch/__tests__/Switch.spec.js +1 -1
- package/es/Tab/Tab.js +5 -5
- package/es/Tab/TabContent.js +4 -4
- package/es/Tab/TabContentWrapper.js +3 -3
- package/es/Tab/TabWrapper.js +6 -5
- package/es/Tab/Tabs.js +13 -13
- package/es/Tab/__tests__/Tab.spec.js +1 -1
- package/es/Tab/__tests__/TabContent.spec.js +1 -1
- package/es/Tab/__tests__/TabContentWrapper.spec.js +1 -1
- package/es/Tab/__tests__/TabWrapper.spec.js +1 -1
- package/es/Tab/__tests__/Tabs.spec.js +1 -1
- package/es/Tab/index.js +5 -5
- package/es/Tag/Tag.js +7 -7
- package/es/Tag/__tests__/Tag.spec.js +1 -1
- package/es/Tag/props/propTypes.js +1 -1
- package/es/TextBox/TextBox.js +3 -3
- package/es/TextBox/__tests__/TextBox.spec.js +1 -1
- package/es/TextBoxIcon/TextBoxIcon.js +6 -6
- package/es/TextBoxIcon/__tests__/TextBoxIcon.spec.js +1 -1
- package/es/TextBoxIcon/props/propTypes.js +1 -1
- package/es/Textarea/Textarea.js +3 -3
- package/es/Textarea/__tests__/Textarea.spec.js +1 -1
- package/es/Tooltip/Tooltip.js +6 -6
- package/es/Typography/Typography.js +4 -4
- package/es/Typography/css/cssJSLogic.js +1 -1
- package/es/VelocityAnimation/VelocityAnimation/VelocityAnimation.js +3 -3
- package/es/VelocityAnimation/VelocityAnimation/__tests__/VelocityAnimation.spec.js +1 -1
- package/es/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +3 -3
- package/es/VelocityAnimation/VelocityAnimationGroup/__tests__/VelocityAnimationGroup.spec.js +1 -1
- package/es/VelocityAnimation/index.js +2 -2
- package/es/css.js +37 -37
- package/es/deprecated/PortalLayer/PortalLayer.js +3 -3
- package/es/index.js +39 -39
- package/es/semantic/Button/Button.js +3 -3
- package/es/semantic/Button/__tests__/Button.spec.js +1 -1
- package/es/semantic/index.js +1 -1
- package/es/utils/Common.js +1 -1
- package/es/utils/ContextOptimizer.js +1 -1
- package/es/utils/cssUtils.js +1 -1
- package/es/utils/datetime/common.js +1 -1
- package/es/utils/dropDownUtils.js +1 -1
- package/es/utils/index.js +1 -1
- package/es/v1/Accordion/Accordion.js +2 -2
- package/es/v1/Accordion/AccordionItem.js +4 -4
- package/es/v1/Accordion/index.js +2 -2
- package/es/v1/Animation/Animation.js +3 -3
- package/es/v1/Animation/utils.js +1 -1
- package/es/v1/AppContainer/AppContainer.js +8 -8
- 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/Button/props/defaultProps.js +1 -1
- package/es/v1/Buttongroup/Buttongroup.js +3 -3
- package/es/v1/Card/Card.js +5 -5
- package/es/v1/Card/index.js +4 -4
- package/es/v1/CheckBox/CheckBox.js +6 -6
- package/es/v1/DateTime/CalendarView.js +7 -7
- package/es/v1/DateTime/DateTime.js +15 -15
- package/es/v1/DateTime/DateTimePopupFooter.js +5 -5
- package/es/v1/DateTime/DateTimePopupHeader.js +4 -4
- package/es/v1/DateTime/DateWidget.js +17 -17
- package/es/v1/DateTime/DaysRow.js +3 -3
- package/es/v1/DateTime/Time.js +5 -5
- package/es/v1/DateTime/YearView.js +6 -6
- package/es/v1/DateTime/index.js +1 -1
- package/es/v1/DateTime/props/propTypes.js +1 -1
- package/es/v1/DropBox/DropBox.js +9 -9
- package/es/v1/DropBox/DropBoxElement/DropBoxElement.js +6 -6
- package/es/v1/DropBox/props/defaultProps.js +1 -1
- package/es/v1/DropBox/props/propTypes.js +1 -1
- package/es/v1/DropBox/utils/isMobilePopover.js +1 -1
- package/es/v1/DropDown/DropDown.js +4 -4
- package/es/v1/DropDown/DropDownHeading.js +3 -3
- package/es/v1/DropDown/DropDownItem.js +3 -3
- package/es/v1/DropDown/DropDownSearch.js +4 -4
- package/es/v1/DropDown/DropDownSeparator.js +2 -2
- package/es/v1/DropDown/props/propTypes.js +1 -1
- package/es/v1/Heading/Heading.js +4 -4
- package/es/v1/Label/Label.js +4 -4
- package/es/v1/Layout/Box.js +4 -4
- package/es/v1/Layout/Container.js +4 -4
- package/es/v1/Layout/index.js +2 -2
- package/es/v1/ListItem/ListContainer.js +6 -6
- package/es/v1/ListItem/ListItem.js +5 -5
- package/es/v1/ListItem/ListItemWithAvatar.js +7 -7
- package/es/v1/ListItem/ListItemWithCheckBox.js +6 -6
- package/es/v1/ListItem/ListItemWithIcon.js +5 -5
- package/es/v1/ListItem/ListItemWithRadio.js +6 -6
- package/es/v1/ListItem/index.js +6 -6
- package/es/v1/Modal/Modal.js +3 -3
- package/es/v1/MultiSelect/AdvancedGroupMultiSelect.js +17 -17
- package/es/v1/MultiSelect/AdvancedMultiSelect.js +17 -17
- package/es/v1/MultiSelect/EmptyState.js +3 -3
- package/es/v1/MultiSelect/MobileHeader/MobileHeader.js +5 -5
- package/es/v1/MultiSelect/MultiSelect.js +19 -19
- package/es/v1/MultiSelect/MultiSelectHeader.js +4 -4
- package/es/v1/MultiSelect/MultiSelectWithAvatar.js +16 -16
- package/es/v1/MultiSelect/SelectedOptions.js +5 -5
- package/es/v1/MultiSelect/Suggestions.js +6 -6
- package/es/v1/MultiSelect/index.js +4 -4
- package/es/v1/MultiSelect/props/defaultProps.js +1 -1
- package/es/v1/PopOver/PopOver.js +6 -6
- package/es/v1/Popup/Popup.js +3 -3
- package/es/v1/Radio/Radio.js +5 -5
- package/es/v1/ResponsiveDropBox/ResponsiveDropBox.js +6 -6
- package/es/v1/ResponsiveDropBox/props/propTypes.js +1 -1
- package/es/v1/Ribbon/Ribbon.js +3 -3
- package/es/v1/RippleEffect/RippleEffect.js +4 -4
- package/es/v1/Select/GroupSelect.js +16 -16
- package/es/v1/Select/Select.js +15 -15
- package/es/v1/Select/SelectWithAvatar.js +17 -17
- package/es/v1/Select/SelectWithIcon.js +13 -13
- package/es/v1/Select/index.js +4 -4
- package/es/v1/Select/props/defaultProps.js +1 -1
- package/es/v1/Stencils/Stencils.js +3 -3
- package/es/v1/Switch/Switch.js +5 -5
- package/es/v1/Tab/Tab.js +5 -5
- package/es/v1/Tab/TabContent.js +4 -4
- package/es/v1/Tab/TabContentWrapper.js +3 -3
- package/es/v1/Tab/TabWrapper.js +3 -3
- package/es/v1/Tab/Tabs.js +13 -13
- package/es/v1/Tab/index.js +5 -5
- package/es/v1/Tag/Tag.js +7 -7
- package/es/v1/TextBox/TextBox.js +3 -3
- package/es/v1/TextBoxIcon/TextBoxIcon.js +6 -6
- package/es/v1/TextBoxIcon/props/propTypes.js +1 -1
- package/es/v1/Textarea/Textarea.js +3 -3
- package/es/v1/Tooltip/Tooltip.js +6 -6
- package/es/v1/Typography/Typography.js +4 -4
- package/es/v1/Typography/css/cssJSLogic.js +1 -1
- package/es/v1/VelocityAnimation/VelocityAnimation/VelocityAnimation.js +3 -3
- package/es/v1/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +3 -3
- package/es/v1/semantic/Button/Button.js +3 -3
- package/es/v1/semantic/index.js +1 -1
- package/lib/Popup/Popup.js +92 -168
- package/lib/Provider/Config.js +1 -2
- package/lib/Tab/TabWrapper.js +3 -2
- package/package.json +4 -4
- package/result.json +1 -1
package/es/v1/Tab/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { default as TabWrapper } from
|
|
2
|
-
export { default as TabContentWrapper } from
|
|
3
|
-
export { default as TabContent } from
|
|
4
|
-
export { default as Tabs } from
|
|
5
|
-
export { default as Tab } from
|
|
1
|
+
export { default as TabWrapper } from './TabWrapper';
|
|
2
|
+
export { default as TabContentWrapper } from './TabContentWrapper';
|
|
3
|
+
export { default as TabContent } from './TabContent';
|
|
4
|
+
export { default as Tabs } from './Tabs';
|
|
5
|
+
export { default as Tab } from './Tab';
|
package/es/v1/Tag/Tag.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import React, { memo } from 'react';
|
|
2
|
-
import { defaultProps } from
|
|
3
|
-
import { propTypes } from
|
|
2
|
+
import { defaultProps } from './props/defaultProps';
|
|
3
|
+
import { propTypes } from './props/propTypes';
|
|
4
4
|
import { Icon } from '@zohodesk/icons';
|
|
5
|
-
import Avatar from
|
|
6
|
-
import { Container } from
|
|
7
|
-
import Button from
|
|
8
|
-
import { useUniqueId } from
|
|
9
|
-
import style from
|
|
5
|
+
import Avatar from '../Avatar/Avatar';
|
|
6
|
+
import { Container } from '../Layout';
|
|
7
|
+
import Button from '../semantic/Button/Button';
|
|
8
|
+
import { useUniqueId } from '../../Provider/IdProvider';
|
|
9
|
+
import style from '../../Tag/Tag.module.css';
|
|
10
10
|
/*
|
|
11
11
|
* eslint css-modules/no-unused-class: [2, { markAsUsed: ['small', 'medium',
|
|
12
12
|
* 'closedanger', 'closeprimary', 'default', 'danger', 'secondary',
|
package/es/v1/TextBox/TextBox.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { memo, useRef, useCallback } from 'react';
|
|
2
|
-
import { defaultProps } from
|
|
3
|
-
import { propTypes } from
|
|
4
|
-
import style from
|
|
2
|
+
import { defaultProps } from './props/defaultProps';
|
|
3
|
+
import { propTypes } from './props/propTypes';
|
|
4
|
+
import style from '../../TextBox/TextBox.module.css';
|
|
5
5
|
|
|
6
6
|
function TextBox(props) {
|
|
7
7
|
let {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React, { useState, useRef, useCallback } from 'react';
|
|
2
|
-
import { defaultProps } from
|
|
3
|
-
import { propTypes } from
|
|
4
|
-
import TextBox from
|
|
5
|
-
import { Container, Box } from
|
|
2
|
+
import { defaultProps } from './props/defaultProps';
|
|
3
|
+
import { propTypes } from './props/propTypes';
|
|
4
|
+
import TextBox from '../TextBox/TextBox';
|
|
5
|
+
import { Container, Box } from '../Layout';
|
|
6
6
|
import { Icon } from '@zohodesk/icons';
|
|
7
|
-
import btnStyle from
|
|
8
|
-
import style from
|
|
7
|
+
import btnStyle from '../../semantic/Button/semanticButton.module.css';
|
|
8
|
+
import style from '../../TextBoxIcon/TextBoxIcon.module.css';
|
|
9
9
|
/* eslint-disable react/forbid-component-props */
|
|
10
10
|
|
|
11
11
|
export default function TextBoxIcon(props) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import PropTypes from 'prop-types';
|
|
2
|
-
import { propTypes as TextBox_propTypes } from
|
|
2
|
+
import { propTypes as TextBox_propTypes } from '../../TextBox/props/propTypes';
|
|
3
3
|
export const propTypes = { ...TextBox_propTypes,
|
|
4
4
|
borderColor: PropTypes.oneOf(['transparent', 'default', 'error']),
|
|
5
5
|
children: PropTypes.node,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useRef } from 'react';
|
|
2
|
-
import { defaultProps } from
|
|
3
|
-
import { propTypes } from
|
|
4
|
-
import style from
|
|
2
|
+
import { defaultProps } from './props/defaultProps';
|
|
3
|
+
import { propTypes } from './props/propTypes';
|
|
4
|
+
import style from '../../Textarea/Textarea.module.css';
|
|
5
5
|
export default function Textarea(props) {
|
|
6
6
|
let {
|
|
7
7
|
size,
|
package/es/v1/Tooltip/Tooltip.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { defaultProps } from
|
|
3
|
-
import { propTypes } from
|
|
4
|
-
import { getLibraryConfig } from
|
|
5
|
-
import ResizeObserver from
|
|
2
|
+
import { defaultProps } from './props/defaultProps';
|
|
3
|
+
import { propTypes } from './props/propTypes';
|
|
4
|
+
import { getLibraryConfig } from '../../Provider/Config';
|
|
5
|
+
import ResizeObserver from '../../Responsive/ResizeObserver';
|
|
6
6
|
import selectn from 'selectn';
|
|
7
|
-
import { whiteSpaceClassMapping } from
|
|
8
|
-
import style from
|
|
7
|
+
import { whiteSpaceClassMapping } from '../../utils/cssUtils';
|
|
8
|
+
import style from '../../Tooltip/Tooltip.module.css';
|
|
9
9
|
export default class Tooltip extends React.Component {
|
|
10
10
|
constructor(props) {
|
|
11
11
|
super(props);
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { defaultProps } from
|
|
3
|
-
import { propTypes } from
|
|
4
|
-
import cssJSLogic from
|
|
2
|
+
import { defaultProps } from './props/defaultProps';
|
|
3
|
+
import { propTypes } from './props/propTypes';
|
|
4
|
+
import cssJSLogic from './css/cssJSLogic';
|
|
5
5
|
import { mergeStyle } from '@zohodesk/utils';
|
|
6
|
-
import defaultStyle from
|
|
6
|
+
import defaultStyle from './css/v1_Typography.module.css';
|
|
7
7
|
|
|
8
8
|
const Typography = props => {
|
|
9
9
|
const {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React, { useContext } from 'react';
|
|
2
|
-
import { defaultProps } from
|
|
3
|
-
import { propTypes } from
|
|
2
|
+
import { defaultProps } from './props/defaultProps';
|
|
3
|
+
import { propTypes } from './props/propTypes';
|
|
4
4
|
import { VelocityComponent } from 'velocity-react';
|
|
5
5
|
import 'velocity-animate/velocity.ui';
|
|
6
|
-
import LibraryContext from
|
|
6
|
+
import LibraryContext from '../../../Provider/LibraryContextInit';
|
|
7
7
|
export default function VelocityAnimation(props) {
|
|
8
8
|
let {
|
|
9
9
|
children,
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React, { useContext } from 'react';
|
|
2
|
-
import { defaultProps } from
|
|
3
|
-
import { propTypes } from
|
|
2
|
+
import { defaultProps } from './props/defaultProps';
|
|
3
|
+
import { propTypes } from './props/propTypes';
|
|
4
4
|
import { VelocityTransitionGroup } from 'velocity-react';
|
|
5
5
|
import 'velocity-animate/velocity.ui';
|
|
6
|
-
import LibraryContext from
|
|
6
|
+
import LibraryContext from '../../../Provider/LibraryContextInit';
|
|
7
7
|
|
|
8
8
|
function clearProps(props) {
|
|
9
9
|
let newProps = Object.assign({}, props);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { defaultProps } from
|
|
3
|
-
import { propTypes } from
|
|
4
|
-
import style from
|
|
2
|
+
import { defaultProps } from './props/defaultProps';
|
|
3
|
+
import { propTypes } from './props/propTypes';
|
|
4
|
+
import style from '../../../semantic/Button/semanticButton.module.css';
|
|
5
5
|
export default function Button(props) {
|
|
6
6
|
const {
|
|
7
7
|
value,
|
package/es/v1/semantic/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default as SemanticButton } from
|
|
1
|
+
export { default as SemanticButton } from './Button/Button';
|
package/lib/Popup/Popup.js
CHANGED
|
@@ -29,8 +29,6 @@ var _isMobilePopover = _interopRequireDefault(require("../DropBox/utils/isMobile
|
|
|
29
29
|
|
|
30
30
|
var _selectn = _interopRequireDefault(require("selectn"));
|
|
31
31
|
|
|
32
|
-
var _Config = require("../Provider/Config.js");
|
|
33
|
-
|
|
34
32
|
var _excluded = ["isMobile"];
|
|
35
33
|
|
|
36
34
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -99,53 +97,6 @@ var defaultState = {
|
|
|
99
97
|
//{height: ‘’, width: ‘’,}
|
|
100
98
|
isAbsolutePositioningNeeded: true
|
|
101
99
|
};
|
|
102
|
-
var SCROLL_BLOCK_EVENTS = Object.freeze([{
|
|
103
|
-
name: 'wheel',
|
|
104
|
-
handlerName: 'handleBlockScroll',
|
|
105
|
-
options: {
|
|
106
|
-
capture: true,
|
|
107
|
-
passive: false
|
|
108
|
-
}
|
|
109
|
-
}, {
|
|
110
|
-
name: 'touchmove',
|
|
111
|
-
handlerName: 'handleBlockScroll',
|
|
112
|
-
options: {
|
|
113
|
-
capture: true,
|
|
114
|
-
passive: false
|
|
115
|
-
}
|
|
116
|
-
}, {
|
|
117
|
-
name: 'scroll',
|
|
118
|
-
handlerName: 'handlePositionChange',
|
|
119
|
-
options: {
|
|
120
|
-
capture: true,
|
|
121
|
-
passive: false
|
|
122
|
-
}
|
|
123
|
-
}, {
|
|
124
|
-
name: 'keydown',
|
|
125
|
-
handlerName: 'preventKeyboardScroll',
|
|
126
|
-
options: {
|
|
127
|
-
capture: true,
|
|
128
|
-
passive: false
|
|
129
|
-
}
|
|
130
|
-
}]);
|
|
131
|
-
var IFRAME_SCROLL_BLOCK_EVENTS = Object.freeze(SCROLL_BLOCK_EVENTS.filter(function (event) {
|
|
132
|
-
return event.name !== 'keydown';
|
|
133
|
-
}));
|
|
134
|
-
var CLICK_EVENTS = Object.freeze([{
|
|
135
|
-
name: 'click',
|
|
136
|
-
handlerName: 'documentClickHandler',
|
|
137
|
-
options: {
|
|
138
|
-
capture: false,
|
|
139
|
-
passive: false
|
|
140
|
-
}
|
|
141
|
-
}, {
|
|
142
|
-
name: 'click',
|
|
143
|
-
handlerName: 'documentClickHandler1',
|
|
144
|
-
options: {
|
|
145
|
-
capture: true,
|
|
146
|
-
passive: false
|
|
147
|
-
}
|
|
148
|
-
}]);
|
|
149
100
|
/* eslint-disable react/no-deprecated */
|
|
150
101
|
|
|
151
102
|
/* eslint-disable react/prop-types */
|
|
@@ -221,7 +172,6 @@ var Popup = function Popup(Component) {
|
|
|
221
172
|
_this.handleBlockScroll = _this.handleBlockScroll.bind(_assertThisInitialized(_this));
|
|
222
173
|
_this.handlePositionChange = _this.handlePositionChange.bind(_assertThisInitialized(_this));
|
|
223
174
|
_this.preventKeyboardScroll = _this.preventKeyboardScroll.bind(_assertThisInitialized(_this));
|
|
224
|
-
_this.updateListeners = _this.updateListeners.bind(_assertThisInitialized(_this));
|
|
225
175
|
_this.addScrollBlockListeners = _this.addScrollBlockListeners.bind(_assertThisInitialized(_this));
|
|
226
176
|
_this.removeScrollBlockListeners = _this.removeScrollBlockListeners.bind(_assertThisInitialized(_this));
|
|
227
177
|
_this.handleAddingScrollBlock = _this.handleAddingScrollBlock.bind(_assertThisInitialized(_this));
|
|
@@ -233,11 +183,8 @@ var Popup = function Popup(Component) {
|
|
|
233
183
|
_this.setContainerDynamicPositioning = _this.setContainerDynamicPositioning.bind(_assertThisInitialized(_this));
|
|
234
184
|
_this.updatePopupState = _this.updatePopupState.bind(_assertThisInitialized(_this));
|
|
235
185
|
_this.handleScrollAndBlockEvents = _this.handleScrollAndBlockEvents.bind(_assertThisInitialized(_this));
|
|
236
|
-
_this.handleIframeEventListeners = _this.handleIframeEventListeners.bind(_assertThisInitialized(_this));
|
|
237
186
|
_this.handleDropElementStyleUpdate = _this.handleDropElementStyleUpdate.bind(_assertThisInitialized(_this));
|
|
238
|
-
_this.getRootElement = _this.getRootElement.bind(_assertThisInitialized(_this));
|
|
239
187
|
_this.positionRef = /*#__PURE__*/_react["default"].createRef();
|
|
240
|
-
_this.rootElement = _this.getRootElement();
|
|
241
188
|
_this.popupObserver = new _ResizeObserver["default"](_this.handlePopupResize); //dropBoxSize
|
|
242
189
|
|
|
243
190
|
_this.size = null;
|
|
@@ -265,10 +212,11 @@ var Popup = function Popup(Component) {
|
|
|
265
212
|
popups[group] = groupPopups;
|
|
266
213
|
|
|
267
214
|
if (Object.keys(popups).length === 1 && groupPopups.length === 1) {
|
|
268
|
-
|
|
215
|
+
document.addEventListener('click', this.documentClickHandler, false);
|
|
269
216
|
document.addEventListener('keyup', this.documentKeyupHandler, false); // document.addEventListener('scroll', this.handleScroll, true);
|
|
270
217
|
|
|
271
218
|
window.addEventListener('resize', this.handleResize);
|
|
219
|
+
document.addEventListener('click', this.documentClickHandler1, true);
|
|
272
220
|
document.addEventListener('mousedown', this.handleDocumentMouseDown, true);
|
|
273
221
|
document.addEventListener('focus', this.handleDocumentFocus, true);
|
|
274
222
|
}
|
|
@@ -285,25 +233,10 @@ var Popup = function Popup(Component) {
|
|
|
285
233
|
});
|
|
286
234
|
}
|
|
287
235
|
}
|
|
288
|
-
}, {
|
|
289
|
-
key: "getRootElement",
|
|
290
|
-
value: function getRootElement() {
|
|
291
|
-
var getRootElement = (0, _Config.getLibraryConfig)('getRootElement');
|
|
292
|
-
|
|
293
|
-
if (getRootElement && typeof getRootElement === 'function') {
|
|
294
|
-
var parent = getRootElement();
|
|
295
|
-
|
|
296
|
-
if (parent) {
|
|
297
|
-
return parent;
|
|
298
|
-
}
|
|
299
|
-
}
|
|
300
|
-
|
|
301
|
-
return document;
|
|
302
|
-
}
|
|
303
236
|
}, {
|
|
304
237
|
key: "handleScrollAndBlockEvents",
|
|
305
|
-
value: function handleScrollAndBlockEvents(
|
|
306
|
-
if (
|
|
238
|
+
value: function handleScrollAndBlockEvents(isPopupReady, isMobile) {
|
|
239
|
+
if (isPopupReady && !isMobile) {
|
|
307
240
|
this.handleAddingScrollBlock();
|
|
308
241
|
this.handleAddingScrollToUpdatePosition();
|
|
309
242
|
} else {
|
|
@@ -311,19 +244,6 @@ var Popup = function Popup(Component) {
|
|
|
311
244
|
this.handleRemovingScrollToUpdatePosition();
|
|
312
245
|
}
|
|
313
246
|
}
|
|
314
|
-
}, {
|
|
315
|
-
key: "handleIframeEventListeners",
|
|
316
|
-
value: function handleIframeEventListeners(shouldAdd, eventList) {
|
|
317
|
-
var _this2 = this;
|
|
318
|
-
|
|
319
|
-
this.rootElement.querySelectorAll('iframe').forEach(function (frame) {
|
|
320
|
-
var frameDocument = frame.contentDocument;
|
|
321
|
-
|
|
322
|
-
if (frameDocument) {
|
|
323
|
-
_this2.updateListeners(shouldAdd, eventList, frameDocument);
|
|
324
|
-
}
|
|
325
|
-
});
|
|
326
|
-
}
|
|
327
247
|
}, {
|
|
328
248
|
key: "componentDidUpdate",
|
|
329
249
|
value: function componentDidUpdate(prevProps, prevState) {
|
|
@@ -349,22 +269,20 @@ var Popup = function Popup(Component) {
|
|
|
349
269
|
}
|
|
350
270
|
|
|
351
271
|
if (oldStateOpen !== isPopupReady && !isMobile || oldIsMobileState !== isMobile) {
|
|
352
|
-
|
|
353
|
-
this.handleScrollAndBlockEvents(shouldAdd);
|
|
354
|
-
this.handleIframeEventListeners(shouldAdd, CLICK_EVENTS);
|
|
272
|
+
this.handleScrollAndBlockEvents(isPopupReady, isMobile);
|
|
355
273
|
}
|
|
356
274
|
}
|
|
357
275
|
}, {
|
|
358
276
|
key: "componentWillUnmount",
|
|
359
277
|
value: function componentWillUnmount() {
|
|
360
|
-
var
|
|
278
|
+
var _this2 = this;
|
|
361
279
|
|
|
362
280
|
var group = this.getGroup();
|
|
363
281
|
popups = Object.keys(popups).reduce(function (res, groupName) {
|
|
364
282
|
if (groupName === group) {
|
|
365
283
|
var groupPopups = popups[group];
|
|
366
284
|
var newGroupPopups = groupPopups.filter(function (popup) {
|
|
367
|
-
return popup !==
|
|
285
|
+
return popup !== _this2;
|
|
368
286
|
});
|
|
369
287
|
newGroupPopups.length === 0 && lastOpenedGroup.indexOf(group) >= 0 && lastOpenedGroup.splice(lastOpenedGroup.indexOf(group), 1);
|
|
370
288
|
res[group] = newGroupPopups;
|
|
@@ -374,7 +292,6 @@ var Popup = function Popup(Component) {
|
|
|
374
292
|
}, popups);
|
|
375
293
|
this.handleRemovingScrollBlock();
|
|
376
294
|
this.handleRemovingScrollToUpdatePosition();
|
|
377
|
-
this.handleIframeEventListeners(false, CLICK_EVENTS);
|
|
378
295
|
var noPopups = true;
|
|
379
296
|
|
|
380
297
|
for (var i in popups) {
|
|
@@ -389,10 +306,11 @@ var Popup = function Popup(Component) {
|
|
|
389
306
|
}
|
|
390
307
|
|
|
391
308
|
if (noPopups) {
|
|
392
|
-
|
|
309
|
+
document.removeEventListener('click', this.documentClickHandler);
|
|
393
310
|
document.removeEventListener('keyup', this.documentKeyupHandler); // document.removeEventListener('scroll', this.handleScroll);
|
|
394
311
|
|
|
395
312
|
window.removeEventListener('resize', this.handleResize);
|
|
313
|
+
document.removeEventListener('click', this.documentClickHandler1, true);
|
|
396
314
|
document.removeEventListener('mousedown', this.handleDocumentMouseDown, true);
|
|
397
315
|
document.removeEventListener('focus', this.handleDocumentFocus, true);
|
|
398
316
|
}
|
|
@@ -511,39 +429,45 @@ var Popup = function Popup(Component) {
|
|
|
511
429
|
this.handlePopupPosition(defaultPosition, true);
|
|
512
430
|
}
|
|
513
431
|
}
|
|
514
|
-
}, {
|
|
515
|
-
key: "updateListeners",
|
|
516
|
-
value: function updateListeners() {
|
|
517
|
-
var _this4 = this;
|
|
518
|
-
|
|
519
|
-
var add = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
|
|
520
|
-
var eventList = arguments.length > 1 ? arguments[1] : undefined;
|
|
521
|
-
var element = arguments.length > 2 ? arguments[2] : undefined;
|
|
522
|
-
var method = add ? 'addEventListener' : 'removeEventListener';
|
|
523
|
-
eventList.forEach(function (_ref5) {
|
|
524
|
-
var name = _ref5.name,
|
|
525
|
-
handlerName = _ref5.handlerName,
|
|
526
|
-
options = _ref5.options;
|
|
527
|
-
var handler = _this4[handlerName];
|
|
528
|
-
|
|
529
|
-
if (handler) {
|
|
530
|
-
element[method](name, handler, options);
|
|
531
|
-
}
|
|
532
|
-
});
|
|
533
|
-
}
|
|
534
432
|
}, {
|
|
535
433
|
key: "addScrollBlockListeners",
|
|
536
434
|
value: function addScrollBlockListeners() {
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
435
|
+
document.addEventListener('wheel', this.handleBlockScroll, {
|
|
436
|
+
capture: true,
|
|
437
|
+
passive: false
|
|
438
|
+
});
|
|
439
|
+
document.addEventListener('touchmove', this.handleBlockScroll, {
|
|
440
|
+
capture: true,
|
|
441
|
+
passive: false
|
|
442
|
+
});
|
|
443
|
+
document.addEventListener('scroll', this.handlePositionChange, {
|
|
444
|
+
capture: true,
|
|
445
|
+
passive: false
|
|
446
|
+
});
|
|
447
|
+
document.addEventListener('keydown', this.preventKeyboardScroll, {
|
|
448
|
+
capture: true,
|
|
449
|
+
passive: false
|
|
450
|
+
});
|
|
541
451
|
}
|
|
542
452
|
}, {
|
|
543
453
|
key: "removeScrollBlockListeners",
|
|
544
454
|
value: function removeScrollBlockListeners() {
|
|
545
|
-
|
|
546
|
-
|
|
455
|
+
document.removeEventListener('wheel', this.handleBlockScroll, {
|
|
456
|
+
capture: true,
|
|
457
|
+
passive: false
|
|
458
|
+
});
|
|
459
|
+
document.removeEventListener('touchmove', this.handleBlockScroll, {
|
|
460
|
+
capture: true,
|
|
461
|
+
passive: false
|
|
462
|
+
});
|
|
463
|
+
document.removeEventListener('scroll', this.handlePositionChange, {
|
|
464
|
+
capture: true,
|
|
465
|
+
passive: false
|
|
466
|
+
});
|
|
467
|
+
document.removeEventListener('keydown', this.preventKeyboardScroll, {
|
|
468
|
+
capture: true,
|
|
469
|
+
passive: false
|
|
470
|
+
});
|
|
547
471
|
}
|
|
548
472
|
}, {
|
|
549
473
|
key: "handleBlockScroll",
|
|
@@ -653,7 +577,7 @@ var Popup = function Popup(Component) {
|
|
|
653
577
|
}, {
|
|
654
578
|
key: "togglePopup",
|
|
655
579
|
value: function togglePopup(e, defaultPosition) {
|
|
656
|
-
var
|
|
580
|
+
var _this3 = this;
|
|
657
581
|
|
|
658
582
|
var group = this.getGroup();
|
|
659
583
|
this.removeClose(e);
|
|
@@ -662,7 +586,7 @@ var Popup = function Popup(Component) {
|
|
|
662
586
|
lastOpenedGroup = !isPopupOpen && lastOpenedGroup.indexOf(group) === -1 ? [group].concat(_toConsumableArray(lastOpenedGroup)) : lastOpenedGroup;
|
|
663
587
|
isPopupOpen && lastOpenedGroup.splice(0, 1);
|
|
664
588
|
groupPopups.forEach(function (popup) {
|
|
665
|
-
if (popup !==
|
|
589
|
+
if (popup !== _this3 && popup.state.isPopupOpen) {
|
|
666
590
|
popup.setState({
|
|
667
591
|
isPopupOpen: false,
|
|
668
592
|
isPopupReady: false
|
|
@@ -832,14 +756,14 @@ var Popup = function Popup(Component) {
|
|
|
832
756
|
}, {
|
|
833
757
|
key: "handlePopupPosition",
|
|
834
758
|
value: function handlePopupPosition() {
|
|
835
|
-
var
|
|
759
|
+
var _this4 = this;
|
|
836
760
|
|
|
837
761
|
var defaultPosition = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'bottomCenter';
|
|
838
762
|
var isUpdatePosition = arguments.length > 1 ? arguments[1] : undefined;
|
|
839
763
|
|
|
840
764
|
// isUpdatePosition --->>> Window resize and dropBox resize and to update the position
|
|
841
|
-
var
|
|
842
|
-
direction =
|
|
765
|
+
var _ref5 = this.context || {},
|
|
766
|
+
direction = _ref5.direction;
|
|
843
767
|
|
|
844
768
|
var placeHolderElement = this.placeHolderElement,
|
|
845
769
|
dropElement = this.dropElement;
|
|
@@ -865,11 +789,11 @@ var Popup = function Popup(Component) {
|
|
|
865
789
|
|
|
866
790
|
var setPosition = function setPosition() {
|
|
867
791
|
requestAnimationFrame(function () {
|
|
868
|
-
var placeHolderElement =
|
|
869
|
-
dropElement =
|
|
870
|
-
var
|
|
871
|
-
position =
|
|
872
|
-
isPopupReady =
|
|
792
|
+
var placeHolderElement = _this4.placeHolderElement,
|
|
793
|
+
dropElement = _this4.dropElement;
|
|
794
|
+
var _this4$state = _this4.state,
|
|
795
|
+
position = _this4$state.position,
|
|
796
|
+
isPopupReady = _this4$state.isPopupReady;
|
|
873
797
|
var scrollContainer = placeHolderElement.closest('[data-scroll=true]') || document.body;
|
|
874
798
|
|
|
875
799
|
var betterPosition = _viewPort["default"].betterView(dropElement, placeHolderElement, defaultPosition, scrollContainer, {
|
|
@@ -878,26 +802,26 @@ var Popup = function Popup(Component) {
|
|
|
878
802
|
customOrder: customOrder
|
|
879
803
|
});
|
|
880
804
|
|
|
881
|
-
var
|
|
882
|
-
view =
|
|
883
|
-
views =
|
|
884
|
-
viewsOffset =
|
|
885
|
-
targetOffset =
|
|
886
|
-
popupOffset =
|
|
805
|
+
var _ref6 = betterPosition || _Common.DUMMY_OBJECT,
|
|
806
|
+
view = _ref6.view,
|
|
807
|
+
views = _ref6.views,
|
|
808
|
+
viewsOffset = _ref6.viewsOffset,
|
|
809
|
+
targetOffset = _ref6.targetOffset,
|
|
810
|
+
popupOffset = _ref6.popupOffset;
|
|
887
811
|
|
|
888
812
|
if (!isAbsolute) {
|
|
889
813
|
if (!isPopupReady) {
|
|
890
|
-
|
|
814
|
+
_this4.updatePopupState(view, views, viewsOffset, targetOffset, popupOffset, isAbsolute);
|
|
891
815
|
}
|
|
892
816
|
|
|
893
817
|
if (!dropElement) {
|
|
894
818
|
return;
|
|
895
819
|
}
|
|
896
820
|
|
|
897
|
-
|
|
821
|
+
_this4.setContainerDynamicPositioning(betterPosition, needArrow);
|
|
898
822
|
} else {
|
|
899
823
|
if (position !== view || !isPopupReady) {
|
|
900
|
-
|
|
824
|
+
_this4.updatePopupState(view, views, viewsOffset, targetOffset, popupOffset, isAbsolute);
|
|
901
825
|
}
|
|
902
826
|
}
|
|
903
827
|
});
|
|
@@ -916,7 +840,7 @@ var Popup = function Popup(Component) {
|
|
|
916
840
|
}, {
|
|
917
841
|
key: "handleOpenPopupPositionChange",
|
|
918
842
|
value: function handleOpenPopupPositionChange() {
|
|
919
|
-
var
|
|
843
|
+
var _this5 = this;
|
|
920
844
|
|
|
921
845
|
Object.keys(popups).forEach(function (groupName) {
|
|
922
846
|
var groupPopups = popups[groupName] || [];
|
|
@@ -933,11 +857,11 @@ var Popup = function Popup(Component) {
|
|
|
933
857
|
if (placeHolderElement && dropElement) {
|
|
934
858
|
var scrollContainer = placeHolderElement.closest('[data-scroll=true]') || document.body;
|
|
935
859
|
requestAnimationFrame(function () {
|
|
936
|
-
var needArrow =
|
|
860
|
+
var needArrow = _this5.getNeedArrow(popup);
|
|
937
861
|
|
|
938
|
-
var isAbsolute =
|
|
862
|
+
var isAbsolute = _this5.getIsAbsolutePopup(popup);
|
|
939
863
|
|
|
940
|
-
var customOrder =
|
|
864
|
+
var customOrder = _this5.getCustomPositionOrder(popup);
|
|
941
865
|
|
|
942
866
|
var isMobile = (0, _isMobilePopover["default"])(true);
|
|
943
867
|
|
|
@@ -947,33 +871,33 @@ var Popup = function Popup(Component) {
|
|
|
947
871
|
customOrder: customOrder
|
|
948
872
|
});
|
|
949
873
|
|
|
950
|
-
var
|
|
951
|
-
view =
|
|
952
|
-
views =
|
|
953
|
-
|
|
954
|
-
viewsOffset =
|
|
955
|
-
targetOffset =
|
|
956
|
-
popupOffset =
|
|
957
|
-
|
|
958
|
-
var
|
|
874
|
+
var _ref7 = betterPosition || {},
|
|
875
|
+
view = _ref7.view,
|
|
876
|
+
views = _ref7.views,
|
|
877
|
+
_ref7$viewsOffset = _ref7.viewsOffset,
|
|
878
|
+
viewsOffset = _ref7$viewsOffset === void 0 ? {} : _ref7$viewsOffset,
|
|
879
|
+
targetOffset = _ref7.targetOffset,
|
|
880
|
+
popupOffset = _ref7.popupOffset;
|
|
881
|
+
|
|
882
|
+
var _ref8 = positionsOffset[position] || {},
|
|
883
|
+
_ref8$left = _ref8.left,
|
|
884
|
+
oldLeft = _ref8$left === void 0 ? '' : _ref8$left,
|
|
885
|
+
_ref8$top = _ref8.top,
|
|
886
|
+
oldTop = _ref8$top === void 0 ? '' : _ref8$top,
|
|
887
|
+
_ref8$bottom = _ref8.bottom,
|
|
888
|
+
oldBottom = _ref8$bottom === void 0 ? '' : _ref8$bottom,
|
|
889
|
+
_ref8$right = _ref8.right,
|
|
890
|
+
oldRight = _ref8$right === void 0 ? '' : _ref8$right;
|
|
891
|
+
|
|
892
|
+
var _ref9 = viewsOffset[view] || {},
|
|
959
893
|
_ref9$left = _ref9.left,
|
|
960
|
-
|
|
894
|
+
left = _ref9$left === void 0 ? '' : _ref9$left,
|
|
961
895
|
_ref9$top = _ref9.top,
|
|
962
|
-
|
|
896
|
+
top = _ref9$top === void 0 ? '' : _ref9$top,
|
|
963
897
|
_ref9$bottom = _ref9.bottom,
|
|
964
|
-
|
|
898
|
+
bottom = _ref9$bottom === void 0 ? '' : _ref9$bottom,
|
|
965
899
|
_ref9$right = _ref9.right,
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
var _ref10 = viewsOffset[view] || {},
|
|
969
|
-
_ref10$left = _ref10.left,
|
|
970
|
-
left = _ref10$left === void 0 ? '' : _ref10$left,
|
|
971
|
-
_ref10$top = _ref10.top,
|
|
972
|
-
top = _ref10$top === void 0 ? '' : _ref10$top,
|
|
973
|
-
_ref10$bottom = _ref10.bottom,
|
|
974
|
-
bottom = _ref10$bottom === void 0 ? '' : _ref10$bottom,
|
|
975
|
-
_ref10$right = _ref10.right,
|
|
976
|
-
right = _ref10$right === void 0 ? '' : _ref10$right;
|
|
900
|
+
right = _ref9$right === void 0 ? '' : _ref9$right;
|
|
977
901
|
|
|
978
902
|
var changeState = isAbsolute ? position !== view : oldLeft !== left || oldTop !== top || oldBottom !== bottom || oldRight !== right; // let isInViewPort = viewPort.isInViewPort(
|
|
979
903
|
// placeHolderElement,
|
|
@@ -1032,11 +956,11 @@ var Popup = function Popup(Component) {
|
|
|
1032
956
|
var height = popupSize.height,
|
|
1033
957
|
width = popupSize.width;
|
|
1034
958
|
|
|
1035
|
-
var
|
|
1036
|
-
|
|
1037
|
-
oldHeight =
|
|
1038
|
-
|
|
1039
|
-
oldWidth =
|
|
959
|
+
var _ref10 = this.size || {},
|
|
960
|
+
_ref10$height = _ref10.height,
|
|
961
|
+
oldHeight = _ref10$height === void 0 ? 0 : _ref10$height,
|
|
962
|
+
_ref10$width = _ref10.width,
|
|
963
|
+
oldWidth = _ref10$width === void 0 ? 0 : _ref10$width;
|
|
1040
964
|
|
|
1041
965
|
var _this$state2 = this.state,
|
|
1042
966
|
isPopupReady = _this$state2.isPopupReady,
|
package/lib/Provider/Config.js
CHANGED
package/lib/Tab/TabWrapper.js
CHANGED
|
@@ -46,7 +46,8 @@ function TabWrapper(_ref) {
|
|
|
46
46
|
align = _ref.align,
|
|
47
47
|
dataId = _ref.dataId,
|
|
48
48
|
children = _ref.children,
|
|
49
|
-
dataSelectorId = _ref.dataSelectorId
|
|
49
|
+
dataSelectorId = _ref.dataSelectorId,
|
|
50
|
+
alignWrapper = _ref.alignWrapper;
|
|
50
51
|
|
|
51
52
|
var _useState = (0, _react.useState)(!hookToDisableInternalState ? defaultTab || 0 : null),
|
|
52
53
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -61,7 +62,7 @@ function TabWrapper(_ref) {
|
|
|
61
62
|
onSelect && onSelect(id);
|
|
62
63
|
}, [hookToDisableInternalState, onSelect]);
|
|
63
64
|
return /*#__PURE__*/_react["default"].createElement(_Layout.Container, {
|
|
64
|
-
alignBox: align === 'vertical' ? 'column' : 'row',
|
|
65
|
+
alignBox: alignWrapper ? alignWrapper : align === 'vertical' ? 'column' : 'row',
|
|
65
66
|
dataId: dataId,
|
|
66
67
|
dataSelectorId: dataSelectorId
|
|
67
68
|
}, _react["default"].Children.map(children, function (child) {
|