@zohodesk/components 1.0.0-temp-169 → 1.0.0-temp-170
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/PropLessFiles.html +1 -1
- package/.cli/PropValidationExcludeFilesArray.js +7 -13
- package/.cli/propValidation_report.html +1 -1
- package/README.md +1335 -1325
- package/assets/Appearance/light/themes/blue/blue_CTA_LightModifyCategory.module.css +180 -180
- package/assets/Appearance/light/themes/blue/blue_CTA_LightTheme.module.css +12 -12
- package/coverage/Button/Button.js.html +1 -1
- package/coverage/Button/css/Button.module.css.html +1 -1
- package/coverage/Button/css/cssJSLogic.js.html +1 -1
- package/coverage/Button/css/index.html +1 -1
- package/coverage/Button/index.html +1 -1
- package/coverage/Button/props/defaultProps.js.html +1 -1
- package/coverage/Button/props/index.html +1 -1
- package/coverage/Button/props/propTypes.js.html +1 -1
- package/coverage/Buttongroup/Buttongroup.js.html +1 -1
- package/coverage/Buttongroup/Buttongroup.module.css.html +1 -1
- package/coverage/Buttongroup/index.html +1 -1
- package/coverage/Buttongroup/props/defaultProps.js.html +1 -1
- package/coverage/Buttongroup/props/index.html +1 -1
- package/coverage/Buttongroup/props/propTypes.js.html +1 -1
- package/coverage/coverage-final.json +10 -10
- package/coverage/coverage-summary.json +10 -10
- package/coverage/index.html +1 -1
- package/coverage/utils/dummyFunction.js.html +1 -1
- package/coverage/utils/index.html +1 -1
- package/es/AppContainer/AppContainer.module.css +18 -18
- package/es/Avatar/Avatar.js +9 -9
- package/es/Avatar/Avatar.module.css +175 -175
- package/es/AvatarTeam/AvatarTeam.js +7 -7
- package/es/AvatarTeam/AvatarTeam.module.css +189 -189
- package/es/Button/Button.js +4 -4
- package/es/Button/__tests__/__snapshots__/Button.spec.js.snap +440 -440
- package/es/Button/css/Button.module.css +525 -525
- package/es/Buttongroup/Buttongroup.js +1 -1
- package/es/Buttongroup/Buttongroup.module.css +105 -105
- package/es/Buttongroup/__tests__/__snapshots__/Buttongroup.spec.js.snap +191 -191
- package/es/Card/Card.js +4 -4
- package/es/Card/Card.module.css +20 -20
- package/es/CheckBox/CheckBox.js +0 -0
- package/es/CheckBox/CheckBox.module.css +157 -157
- package/es/DateTime/CalendarView.js +0 -0
- package/es/DateTime/DateTime.js +0 -0
- package/es/DateTime/DateTime.module.css +237 -237
- package/es/DateTime/DateWidget.js +0 -0
- package/es/DateTime/DateWidget.module.css +38 -38
- package/es/DateTime/YearView.js +0 -0
- package/es/DateTime/YearView.module.css +98 -98
- package/es/DateTime/common.js +0 -0
- package/es/DateTime/index.js +0 -0
- package/es/DateTime/objectUtils.js +0 -0
- package/es/DateTime/typeChecker.js +0 -0
- package/es/DateTime/validator.js +0 -0
- package/es/DropBox/DropBox.js +0 -0
- package/es/DropBox/DropBoxElement/css/DropBoxElement.module.css +434 -434
- package/es/DropBox/DropBoxPositionMapping.json +144 -144
- package/es/DropBox/css/DropBox.module.css +58 -58
- package/es/DropDown/DropDown.js +0 -0
- package/es/DropDown/DropDown.module.css +5 -5
- package/es/DropDown/DropDownHeading.js +0 -0
- package/es/DropDown/DropDownHeading.module.css +53 -53
- package/es/DropDown/DropDownItem.js +0 -0
- package/es/DropDown/DropDownItem.module.css +94 -94
- package/es/DropDown/DropDownSearch.js +0 -0
- package/es/DropDown/DropDownSearch.module.css +14 -14
- package/es/DropDown/DropDownSeparator.js +0 -0
- package/es/DropDown/DropDownSeparator.module.css +7 -7
- package/es/Heading/Heading.module.css +4 -4
- package/es/Label/Label.js +2 -2
- package/es/Label/Label.module.css +52 -52
- package/es/Label/LabelColors.module.css +20 -20
- package/es/Layout/Box.js +0 -0
- package/es/Layout/Container.js +0 -0
- package/es/Layout/Layout.module.css +335 -335
- package/es/Layout/utils.js +0 -0
- package/es/ListItem/ListItem.js +0 -0
- package/es/ListItem/ListItem.module.css +216 -216
- package/es/MultiSelect/AdvancedGroupMultiSelect.js +5 -5
- package/es/MultiSelect/MobileHeader/MobileHeader.module.css +16 -16
- package/es/MultiSelect/MultiSelect.js +5 -5
- package/es/MultiSelect/MultiSelect.module.css +204 -204
- package/es/MultiSelect/MultiSelectWithAvatar.js +0 -0
- package/es/MultiSelect/SelectedOptions.module.css +15 -15
- package/es/MultiSelect/props/propTypes.js +140 -138
- package/es/PopOver/PopOver.module.css +8 -8
- package/es/Popup/Popup.js +0 -0
- package/es/Popup/PositionMapping.json +73 -73
- package/es/Radio/Radio.js +0 -0
- package/es/Radio/Radio.module.css +112 -112
- package/es/Responsive/CustomResponsive.js +0 -0
- package/es/ResponsiveDropBox/ResponsiveDropBox.module.css +6 -6
- package/es/Ribbon/Ribbon.js +0 -0
- package/es/Ribbon/Ribbon.module.css +454 -454
- package/es/RippleEffect/RippleEffect.module.css +92 -92
- package/es/Select/GroupSelect.js +0 -0
- package/es/Select/Select.js +0 -0
- package/es/Select/Select.module.css +108 -108
- package/es/Select/SelectWithAvatar.js +0 -0
- package/es/Select/SelectWithIcon.js +0 -0
- package/es/Select/props/propTypes.js +3 -1
- package/es/Stencils/Stencils.js +0 -0
- package/es/Stencils/Stencils.module.css +96 -96
- package/es/Switch/Switch.js +0 -0
- package/es/Switch/Switch.module.css +127 -127
- package/es/Tab/Tab.module.css +100 -100
- package/es/Tab/TabContent.module.css +4 -4
- package/es/Tab/Tabs.js +17 -17
- package/es/Tab/Tabs.module.css +136 -136
- package/es/Tag/Tag.js +8 -8
- package/es/Tag/Tag.module.css +254 -254
- package/es/TextBox/TextBox.js +0 -0
- package/es/TextBox/TextBox.module.css +158 -159
- package/es/TextBoxIcon/TextBoxIcon.js +0 -0
- package/es/TextBoxIcon/TextBoxIcon.module.css +79 -79
- package/es/Textarea/Textarea.js +0 -0
- package/es/Textarea/Textarea.module.css +139 -138
- package/es/Tooltip/Tooltip.module.css +140 -140
- package/es/common/a11y.module.css +3 -3
- package/es/common/animation.module.css +624 -624
- package/es/common/avatarsizes.module.css +48 -48
- package/es/common/basic.module.css +33 -33
- package/es/common/basicReset.module.css +40 -40
- package/es/common/boxShadow.module.css +33 -33
- package/es/common/common.module.css +524 -524
- package/es/common/customscroll.module.css +91 -91
- package/es/common/reset.module.css +13 -13
- package/es/common/transition.module.css +146 -146
- package/es/semantic/Button/semanticButton.module.css +9 -9
- package/es/utils/Common.js +0 -0
- package/es/utils/dropDownUtils.js +0 -0
- package/es/v1/AppContainer/AppContainer.js +75 -92
- 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 +147 -181
- package/es/v1/Card/index.js +4 -0
- package/es/v1/CheckBox/CheckBox.js +0 -0
- package/es/v1/DateTime/DateTime.js +0 -0
- package/es/v1/DateTime/DateWidget.js +0 -0
- package/es/v1/DateTime/YearView.js +0 -0
- package/es/v1/DateTime/index.js +0 -0
- package/es/v1/DropBox/DropBox.js +0 -0
- package/es/v1/DropDown/DropDown.js +31 -52
- package/es/v1/DropDown/DropDownHeading.js +29 -37
- package/es/v1/DropDown/DropDownItem.js +38 -58
- package/es/v1/DropDown/DropDownSearch.js +41 -49
- package/es/v1/DropDown/DropDownSeparator.js +7 -10
- package/es/v1/Layout/Box.js +0 -0
- package/es/v1/Layout/Container.js +0 -0
- package/es/v1/ListItem/ListItem.js +0 -0
- package/es/v1/MultiSelect/AdvancedGroupMultiSelect.js +5 -5
- package/es/v1/MultiSelect/MultiSelect.js +6 -5
- package/es/v1/MultiSelect/MultiSelectWithAvatar.js +1 -0
- package/es/v1/Provider/AvatarSize.js +13 -0
- package/es/v1/Provider/Config.js +18 -0
- package/es/v1/Provider/CssProvider.js +16 -0
- package/es/v1/Provider/IdProvider.js +66 -0
- package/es/v1/Provider/LibraryContext.js +37 -0
- package/es/v1/Provider/LibraryContextInit.js +3 -0
- package/es/v1/Provider/NumberGenerator/NumberGenerator.js +136 -0
- package/es/v1/Provider/ZindexProvider.js +57 -0
- package/es/v1/Provider/index.js +4 -0
- package/es/v1/Radio/Radio.js +0 -0
- package/es/v1/Responsive/CustomResponsive.js +0 -0
- package/es/v1/Select/GroupSelect.js +0 -0
- package/es/v1/Select/Select.js +0 -0
- package/es/v1/Select/SelectWithAvatar.js +0 -0
- package/es/v1/Select/SelectWithIcon.js +0 -0
- package/es/v1/Switch/Switch.js +0 -0
- package/es/v1/Tab/Tabs.js +17 -17
- package/es/v1/Tag/Tag.js +8 -8
- package/es/v1/TextBox/TextBox.js +0 -0
- package/es/v1/Typography/css/Typography.module.css +376 -376
- package/install.md +10 -10
- package/lib/AppContainer/AppContainer.module.css +18 -18
- package/lib/Avatar/Avatar.js +9 -9
- package/lib/Avatar/Avatar.module.css +175 -175
- package/lib/AvatarTeam/AvatarTeam.js +7 -7
- package/lib/AvatarTeam/AvatarTeam.module.css +189 -189
- package/lib/Button/Button.js +4 -4
- package/lib/Button/__tests__/__snapshots__/Button.spec.js.snap +440 -440
- package/lib/Button/css/Button.module.css +525 -525
- package/lib/Buttongroup/Buttongroup.js +1 -1
- package/lib/Buttongroup/Buttongroup.module.css +105 -105
- package/lib/Buttongroup/__tests__/__snapshots__/Buttongroup.spec.js.snap +191 -191
- package/lib/Card/Card.js +4 -4
- package/lib/Card/Card.module.css +20 -20
- package/lib/CheckBox/CheckBox.js +0 -0
- package/lib/CheckBox/CheckBox.module.css +157 -157
- package/lib/DateTime/CalendarView.js +0 -0
- package/lib/DateTime/DateTime.js +0 -0
- package/lib/DateTime/DateTime.module.css +237 -237
- package/lib/DateTime/DateWidget.js +0 -0
- package/lib/DateTime/DateWidget.module.css +38 -38
- package/lib/DateTime/YearView.js +0 -0
- package/lib/DateTime/YearView.module.css +98 -98
- package/lib/DateTime/common.js +0 -0
- package/lib/DateTime/index.js +0 -0
- package/lib/DateTime/objectUtils.js +0 -0
- package/lib/DateTime/typeChecker.js +0 -0
- package/lib/DateTime/validator.js +0 -0
- package/lib/DropBox/DropBox.js +0 -0
- package/lib/DropBox/DropBoxElement/css/DropBoxElement.module.css +434 -434
- package/lib/DropBox/DropBoxPositionMapping.json +144 -144
- package/lib/DropBox/css/DropBox.module.css +58 -58
- package/lib/DropDown/DropDown.js +0 -0
- package/lib/DropDown/DropDown.module.css +5 -5
- package/lib/DropDown/DropDownHeading.js +0 -0
- package/lib/DropDown/DropDownHeading.module.css +53 -53
- package/lib/DropDown/DropDownItem.js +0 -0
- package/lib/DropDown/DropDownItem.module.css +94 -94
- package/lib/DropDown/DropDownSearch.js +0 -0
- package/lib/DropDown/DropDownSearch.module.css +14 -14
- package/lib/DropDown/DropDownSeparator.js +0 -0
- package/lib/DropDown/DropDownSeparator.module.css +7 -7
- package/lib/Heading/Heading.module.css +4 -4
- package/lib/Label/Label.js +0 -0
- package/lib/Label/Label.module.css +52 -52
- package/lib/Label/LabelColors.module.css +20 -20
- package/lib/Layout/Box.js +0 -0
- package/lib/Layout/Container.js +0 -0
- package/lib/Layout/Layout.module.css +335 -335
- package/lib/Layout/utils.js +0 -0
- package/lib/ListItem/ListItem.js +0 -0
- package/lib/ListItem/ListItem.module.css +216 -216
- package/lib/MultiSelect/AdvancedGroupMultiSelect.js +5 -5
- package/lib/MultiSelect/MobileHeader/MobileHeader.module.css +16 -16
- package/lib/MultiSelect/MultiSelect.js +5 -5
- package/lib/MultiSelect/MultiSelect.module.css +204 -204
- package/lib/MultiSelect/MultiSelectWithAvatar.js +0 -0
- package/lib/MultiSelect/SelectedOptions.module.css +15 -15
- package/lib/MultiSelect/props/propTypes.js +146 -141
- package/lib/PopOver/PopOver.module.css +8 -8
- package/lib/Popup/Popup.js +0 -0
- package/lib/Popup/PositionMapping.json +73 -73
- package/lib/Radio/Radio.js +0 -0
- package/lib/Radio/Radio.module.css +112 -112
- package/lib/Responsive/CustomResponsive.js +0 -0
- package/lib/ResponsiveDropBox/ResponsiveDropBox.module.css +6 -6
- package/lib/Ribbon/Ribbon.js +0 -0
- package/lib/Ribbon/Ribbon.module.css +454 -454
- package/lib/RippleEffect/RippleEffect.module.css +92 -92
- package/lib/Select/GroupSelect.js +0 -0
- package/lib/Select/Select.js +0 -0
- package/lib/Select/Select.module.css +108 -108
- package/lib/Select/SelectWithAvatar.js +0 -0
- package/lib/Select/SelectWithIcon.js +0 -0
- package/lib/Select/props/propTypes.js +12 -2
- package/lib/Stencils/Stencils.js +0 -0
- package/lib/Stencils/Stencils.module.css +96 -96
- package/lib/Switch/Switch.js +0 -0
- package/lib/Switch/Switch.module.css +127 -127
- package/lib/Tab/Tab.module.css +100 -100
- package/lib/Tab/TabContent.module.css +4 -4
- package/lib/Tab/Tabs.js +11 -11
- package/lib/Tab/Tabs.module.css +136 -136
- package/lib/Tag/Tag.js +8 -8
- package/lib/Tag/Tag.module.css +254 -254
- package/lib/TextBox/TextBox.js +0 -0
- package/lib/TextBox/TextBox.module.css +158 -159
- package/lib/TextBoxIcon/TextBoxIcon.js +0 -0
- package/lib/TextBoxIcon/TextBoxIcon.module.css +79 -79
- package/lib/Textarea/Textarea.js +0 -0
- package/lib/Textarea/Textarea.module.css +139 -138
- package/lib/Tooltip/Tooltip.module.css +140 -140
- package/lib/common/a11y.module.css +3 -3
- package/lib/common/animation.module.css +624 -624
- package/lib/common/avatarsizes.module.css +48 -48
- package/lib/common/basic.module.css +33 -33
- package/lib/common/basicReset.module.css +40 -40
- package/lib/common/boxShadow.module.css +33 -33
- package/lib/common/common.module.css +524 -524
- package/lib/common/customscroll.module.css +91 -91
- package/lib/common/reset.module.css +13 -13
- package/lib/common/transition.module.css +146 -146
- package/lib/semantic/Button/semanticButton.module.css +9 -9
- package/lib/utils/Common.js +0 -0
- package/lib/utils/dropDownUtils.js +0 -0
- package/lib/v1/AppContainer/AppContainer.js +87 -138
- 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 +194 -290
- package/lib/v1/Card/index.js +37 -0
- package/lib/v1/CheckBox/CheckBox.js +0 -0
- package/lib/v1/DateTime/DateTime.js +0 -0
- package/lib/v1/DateTime/DateWidget.js +0 -0
- package/lib/v1/DateTime/YearView.js +0 -0
- package/lib/v1/DateTime/index.js +0 -0
- package/lib/v1/DropBox/DropBox.js +0 -0
- package/lib/v1/DropDown/DropDown.js +34 -130
- package/lib/v1/DropDown/DropDownHeading.js +29 -75
- package/lib/v1/DropDown/DropDownItem.js +50 -102
- package/lib/v1/DropDown/DropDownSearch.js +50 -89
- package/lib/v1/DropDown/DropDownSeparator.js +8 -48
- package/lib/v1/Layout/Box.js +0 -0
- package/lib/v1/Layout/Container.js +0 -0
- package/lib/v1/ListItem/ListItem.js +0 -0
- package/lib/v1/MultiSelect/AdvancedGroupMultiSelect.js +5 -5
- package/lib/v1/MultiSelect/MultiSelect.js +8 -6
- package/lib/v1/MultiSelect/MultiSelectWithAvatar.js +3 -1
- package/lib/v1/Provider/AvatarSize.js +24 -0
- package/lib/v1/Provider/Config.js +27 -0
- package/lib/v1/Provider/CssProvider.js +27 -0
- package/lib/v1/Provider/IdProvider.js +79 -0
- package/lib/v1/Provider/LibraryContext.js +76 -0
- package/lib/v1/Provider/LibraryContextInit.js +15 -0
- package/lib/v1/Provider/NumberGenerator/NumberGenerator.js +174 -0
- package/lib/v1/Provider/ZindexProvider.js +69 -0
- package/lib/v1/Provider/index.js +81 -0
- package/lib/v1/Radio/Radio.js +0 -0
- package/lib/v1/Responsive/CustomResponsive.js +0 -0
- package/lib/v1/Select/GroupSelect.js +0 -0
- package/lib/v1/Select/Select.js +0 -0
- package/lib/v1/Select/SelectWithAvatar.js +0 -0
- package/lib/v1/Select/SelectWithIcon.js +0 -0
- package/lib/v1/Switch/Switch.js +0 -0
- package/lib/v1/Tab/Tabs.js +11 -11
- package/lib/v1/Tag/Tag.js +8 -8
- package/lib/v1/TextBox/TextBox.js +0 -0
- package/lib/v1/Typography/css/Typography.module.css +376 -376
- package/package.json +93 -93
- package/postPublish.js +8 -8
- package/prePublish.js +70 -70
- package/react-cli.config.js +23 -23
- package/result.json +1 -1
- package/unittest/index.html +1 -1
|
@@ -5,7 +5,10 @@ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" =
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports
|
|
8
|
+
exports.DropDownContainer = DropDownContainer;
|
|
9
|
+
exports.DropDownItemContainer = DropDownItemContainer;
|
|
10
|
+
exports.DropDownTarget = DropDownTarget;
|
|
11
|
+
exports["default"] = DropDown;
|
|
9
12
|
|
|
10
13
|
var _react = _interopRequireDefault(require("react"));
|
|
11
14
|
|
|
@@ -23,148 +26,49 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
23
26
|
|
|
24
27
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
25
28
|
|
|
26
|
-
function
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
31
|
-
|
|
32
|
-
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
33
|
-
|
|
34
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
35
|
-
|
|
36
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
37
|
-
|
|
38
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
39
|
-
|
|
40
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
41
|
-
|
|
42
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
43
|
-
|
|
44
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
45
|
-
|
|
46
|
-
var DropDown = /*#__PURE__*/function (_React$Component) {
|
|
47
|
-
_inherits(DropDown, _React$Component);
|
|
48
|
-
|
|
49
|
-
var _super = _createSuper(DropDown);
|
|
50
|
-
|
|
51
|
-
function DropDown() {
|
|
52
|
-
_classCallCheck(this, DropDown);
|
|
53
|
-
|
|
54
|
-
return _super.apply(this, arguments);
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
_createClass(DropDown, [{
|
|
58
|
-
key: "render",
|
|
59
|
-
value: function render() {
|
|
60
|
-
var children = this.props.children;
|
|
61
|
-
return /*#__PURE__*/_react["default"].createElement(_PopOver["default"], this.props, /*#__PURE__*/_react["default"].createElement(_PopOver.PopOverTarget, null, children[0]), /*#__PURE__*/_react["default"].createElement(_PopOver.PopOverContainer, null, children[1]));
|
|
62
|
-
}
|
|
63
|
-
}]);
|
|
64
|
-
|
|
65
|
-
return DropDown;
|
|
66
|
-
}(_react["default"].Component);
|
|
29
|
+
function DropDown(props) {
|
|
30
|
+
var children = props.children;
|
|
31
|
+
return /*#__PURE__*/_react["default"].createElement(_PopOver["default"], props, /*#__PURE__*/_react["default"].createElement(_PopOver.PopOverTarget, null, children[0]), /*#__PURE__*/_react["default"].createElement(_PopOver.PopOverContainer, null, children[1]));
|
|
32
|
+
}
|
|
67
33
|
|
|
68
|
-
exports["default"] = DropDown;
|
|
69
34
|
DropDown.propTypes = _propTypes.DropDown_propTypes;
|
|
70
35
|
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
function DropDownTarget() {
|
|
77
|
-
_classCallCheck(this, DropDownTarget);
|
|
78
|
-
|
|
79
|
-
return _super2.apply(this, arguments);
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
_createClass(DropDownTarget, [{
|
|
83
|
-
key: "render",
|
|
84
|
-
value: function render() {
|
|
85
|
-
var children = this.props.children;
|
|
86
|
-
return /*#__PURE__*/_react["default"].createElement("div", null, children);
|
|
87
|
-
}
|
|
88
|
-
}]);
|
|
89
|
-
|
|
90
|
-
return DropDownTarget;
|
|
91
|
-
}(_react["default"].Component);
|
|
36
|
+
function DropDownTarget(props) {
|
|
37
|
+
var children = props.children;
|
|
38
|
+
return /*#__PURE__*/_react["default"].createElement("div", null, children);
|
|
39
|
+
}
|
|
92
40
|
|
|
93
|
-
exports.DropDownTarget = DropDownTarget;
|
|
94
41
|
DropDownTarget.propTypes = _propTypes.DropDownTarget_propTypes;
|
|
95
42
|
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
function DropDownContainer() {
|
|
102
|
-
_classCallCheck(this, DropDownContainer);
|
|
43
|
+
function DropDownContainer(props) {
|
|
44
|
+
var children = props.children;
|
|
45
|
+
return /*#__PURE__*/_react["default"].createElement("div", null, " ", children, " ");
|
|
46
|
+
}
|
|
103
47
|
|
|
104
|
-
return _super3.apply(this, arguments);
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
_createClass(DropDownContainer, [{
|
|
108
|
-
key: "render",
|
|
109
|
-
value: function render() {
|
|
110
|
-
var children = this.props.children;
|
|
111
|
-
return /*#__PURE__*/_react["default"].createElement("div", null, " ", children, " ");
|
|
112
|
-
}
|
|
113
|
-
}]);
|
|
114
|
-
|
|
115
|
-
return DropDownContainer;
|
|
116
|
-
}(_react["default"].Component);
|
|
117
|
-
|
|
118
|
-
exports.DropDownContainer = DropDownContainer;
|
|
119
48
|
DropDownContainer.propTypes = _propTypes.DropDownContainer_propTypes;
|
|
120
49
|
|
|
121
|
-
|
|
122
|
-
|
|
50
|
+
function DropDownItemContainer(props) {
|
|
51
|
+
var children = props.children,
|
|
52
|
+
dataId = props.dataId,
|
|
53
|
+
getRef = props.getRef,
|
|
54
|
+
onScroll = props.onScroll;
|
|
123
55
|
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
var _this;
|
|
128
|
-
|
|
129
|
-
_classCallCheck(this, DropDownItemContainer);
|
|
56
|
+
function handleScroll(e) {
|
|
57
|
+
onScroll && onScroll(e);
|
|
58
|
+
}
|
|
130
59
|
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
_this.onScroll = _this.onScroll.bind(_assertThisInitialized(_this));
|
|
134
|
-
return _this;
|
|
60
|
+
function getReference(ele) {
|
|
61
|
+
getRef && getRef(ele);
|
|
135
62
|
}
|
|
136
63
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
},
|
|
144
|
-
|
|
145
|
-
value: function getRef(ele) {
|
|
146
|
-
var getRef = this.props.getRef;
|
|
147
|
-
getRef && getRef(ele);
|
|
148
|
-
}
|
|
149
|
-
}, {
|
|
150
|
-
key: "render",
|
|
151
|
-
value: function render() {
|
|
152
|
-
var _this$props = this.props,
|
|
153
|
-
children = _this$props.children,
|
|
154
|
-
dataId = _this$props.dataId;
|
|
155
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
156
|
-
className: _DropDownModule["default"].listGroup,
|
|
157
|
-
onScroll: this.onScroll,
|
|
158
|
-
ref: this.getRef,
|
|
159
|
-
"data-id": dataId,
|
|
160
|
-
"data-test-id": dataId
|
|
161
|
-
}, children);
|
|
162
|
-
}
|
|
163
|
-
}]);
|
|
164
|
-
|
|
165
|
-
return DropDownItemContainer;
|
|
166
|
-
}(_react["default"].Component);
|
|
64
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
65
|
+
className: _DropDownModule["default"].listGroup,
|
|
66
|
+
onScroll: handleScroll,
|
|
67
|
+
ref: getReference,
|
|
68
|
+
"data-id": dataId,
|
|
69
|
+
"data-test-id": dataId
|
|
70
|
+
}, children);
|
|
71
|
+
}
|
|
167
72
|
|
|
168
|
-
exports.DropDownItemContainer = DropDownItemContainer;
|
|
169
73
|
DropDownItemContainer.propTypes = _propTypes.DropDownItemContainer_propTypes;
|
|
170
74
|
DropDownItemContainer.defaultProps = _defaultProps.DropDownItemContainer_defaultProps;
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
-
|
|
5
3
|
Object.defineProperty(exports, "__esModule", {
|
|
6
4
|
value: true
|
|
7
5
|
});
|
|
8
|
-
exports["default"] =
|
|
6
|
+
exports["default"] = DropDownHeading;
|
|
9
7
|
|
|
10
8
|
var _react = _interopRequireDefault(require("react"));
|
|
11
9
|
|
|
@@ -17,77 +15,33 @@ var _DropDownHeadingModule = _interopRequireDefault(require("../../DropDown/Drop
|
|
|
17
15
|
|
|
18
16
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
19
17
|
|
|
20
|
-
function
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
18
|
+
function DropDownHeading(props) {
|
|
19
|
+
var text = props.text,
|
|
20
|
+
_props$title = props.title,
|
|
21
|
+
title = _props$title === void 0 ? text : _props$title,
|
|
22
|
+
children = props.children,
|
|
23
|
+
customClass = props.customClass,
|
|
24
|
+
palette = props.palette,
|
|
25
|
+
htmlId = props.htmlId,
|
|
26
|
+
a11y = props.a11y,
|
|
27
|
+
dataId = props.dataId,
|
|
28
|
+
dataSelectorId = props.dataSelectorId;
|
|
29
|
+
var role = a11y.role,
|
|
30
|
+
ariaLabelledby = a11y.ariaLabelledby,
|
|
31
|
+
ariaLabel = a11y.ariaLabel;
|
|
32
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
33
|
+
className: "".concat(_DropDownHeadingModule["default"][palette], " ").concat(customClass),
|
|
34
|
+
"data-title": title,
|
|
35
|
+
role: role,
|
|
36
|
+
"aria-labelledby": ariaLabelledby,
|
|
37
|
+
"aria-label": ariaLabel,
|
|
38
|
+
id: htmlId,
|
|
39
|
+
"data-id": dataId,
|
|
40
|
+
"data-test-id": dataId,
|
|
41
|
+
"data-selector-id": dataSelectorId // tabindex='0'
|
|
42
|
+
|
|
43
|
+
}, text, children);
|
|
44
|
+
}
|
|
37
45
|
|
|
38
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
39
|
-
|
|
40
|
-
var DropDownHeading = /*#__PURE__*/function (_React$Component) {
|
|
41
|
-
_inherits(DropDownHeading, _React$Component);
|
|
42
|
-
|
|
43
|
-
var _super = _createSuper(DropDownHeading);
|
|
44
|
-
|
|
45
|
-
function DropDownHeading() {
|
|
46
|
-
_classCallCheck(this, DropDownHeading);
|
|
47
|
-
|
|
48
|
-
return _super.apply(this, arguments);
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
_createClass(DropDownHeading, [{
|
|
52
|
-
key: "render",
|
|
53
|
-
value: function render() {
|
|
54
|
-
var _this$props = this.props,
|
|
55
|
-
text = _this$props.text,
|
|
56
|
-
_this$props$title = _this$props.title,
|
|
57
|
-
title = _this$props$title === void 0 ? text : _this$props$title,
|
|
58
|
-
children = _this$props.children,
|
|
59
|
-
customClass = _this$props.customClass,
|
|
60
|
-
palette = _this$props.palette,
|
|
61
|
-
htmlId = _this$props.htmlId,
|
|
62
|
-
a11y = _this$props.a11y,
|
|
63
|
-
dataId = _this$props.dataId,
|
|
64
|
-
dataSelectorId = _this$props.dataSelectorId;
|
|
65
|
-
var role = a11y.role,
|
|
66
|
-
ariaLabelledby = a11y.ariaLabelledby,
|
|
67
|
-
ariaLabel = a11y.ariaLabel;
|
|
68
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
69
|
-
className: "".concat(_DropDownHeadingModule["default"][palette], " ").concat(customClass),
|
|
70
|
-
"data-title": title,
|
|
71
|
-
role: role,
|
|
72
|
-
"aria-labelledby": ariaLabelledby,
|
|
73
|
-
"aria-label": ariaLabel,
|
|
74
|
-
id: htmlId,
|
|
75
|
-
"data-id": dataId,
|
|
76
|
-
"data-test-id": dataId,
|
|
77
|
-
"data-selector-id": dataSelectorId // tabindex='0'
|
|
78
|
-
|
|
79
|
-
}, text, children);
|
|
80
|
-
}
|
|
81
|
-
}]);
|
|
82
|
-
|
|
83
|
-
return DropDownHeading;
|
|
84
|
-
}(_react["default"].Component);
|
|
85
|
-
|
|
86
|
-
exports["default"] = DropDownHeading;
|
|
87
46
|
DropDownHeading.propTypes = _propTypes.DropDownHeading_propTypes;
|
|
88
|
-
DropDownHeading.defaultProps = _defaultProps.DropDownHeading_defaultProps;
|
|
89
|
-
// DropDownHeading.docs = {
|
|
90
|
-
// componentGroup: 'Form Elements',
|
|
91
|
-
// folderName: 'Style Guide'
|
|
92
|
-
// };
|
|
93
|
-
// }
|
|
47
|
+
DropDownHeading.defaultProps = _defaultProps.DropDownHeading_defaultProps;
|
|
@@ -5,9 +5,9 @@ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" =
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports["default"] =
|
|
8
|
+
exports["default"] = DropDownItem;
|
|
9
9
|
|
|
10
|
-
var _react =
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
11
|
|
|
12
12
|
var _propTypes = require("../../DropDown/props/propTypes");
|
|
13
13
|
|
|
@@ -17,111 +17,59 @@ var _DropDownItemModule = _interopRequireDefault(require("../../DropDown/DropDow
|
|
|
17
17
|
|
|
18
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
19
19
|
|
|
20
|
-
function
|
|
21
|
-
|
|
22
|
-
function
|
|
23
|
-
|
|
24
|
-
function
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
var _super = _createSuper(DropDownItem);
|
|
20
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
21
|
+
|
|
22
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
23
|
+
|
|
24
|
+
function DropDownItem(props) {
|
|
25
|
+
var value = props.value,
|
|
26
|
+
active = props.active,
|
|
27
|
+
children = props.children,
|
|
28
|
+
hightlight = props.hightlight,
|
|
29
|
+
dataId = props.dataId,
|
|
30
|
+
_props$customClass = props.customClass,
|
|
31
|
+
customClass = _props$customClass === void 0 ? '' : _props$customClass,
|
|
32
|
+
index = props.index,
|
|
33
|
+
getRef = props.getRef,
|
|
34
|
+
onClick = props.onClick,
|
|
35
|
+
id = props.id,
|
|
36
|
+
onHover = props.onHover;
|
|
37
|
+
var eleRef = (0, _react.useRef)(null);
|
|
38
|
+
|
|
39
|
+
function getReference(ele) {
|
|
40
|
+
eleRef.current = ele;
|
|
41
|
+
getRef && getRef(ele, index);
|
|
42
|
+
}
|
|
44
43
|
|
|
45
|
-
function
|
|
46
|
-
|
|
44
|
+
function getSelectedElement() {
|
|
45
|
+
return eleRef.current ? eleRef.current : null;
|
|
46
|
+
}
|
|
47
47
|
|
|
48
|
-
|
|
48
|
+
function handleClick(e) {
|
|
49
|
+
onClick && onClick(id, value, index, e);
|
|
50
|
+
}
|
|
49
51
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
_this.getRef = _this.getRef.bind(_assertThisInitialized(_this));
|
|
53
|
-
_this.getSelectedElement = _this.getSelectedElement.bind(_assertThisInitialized(_this));
|
|
54
|
-
_this.onHover = _this.onHover.bind(_assertThisInitialized(_this));
|
|
55
|
-
return _this;
|
|
52
|
+
function handleHover(e) {
|
|
53
|
+
onHover && onHover(id, value, index, e);
|
|
56
54
|
}
|
|
57
55
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
}, {
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
var _this$props2 = this.props,
|
|
76
|
-
onClick = _this$props2.onClick,
|
|
77
|
-
id = _this$props2.id,
|
|
78
|
-
value = _this$props2.value,
|
|
79
|
-
index = _this$props2.index;
|
|
80
|
-
onClick && onClick(id, value, index, e);
|
|
81
|
-
}
|
|
82
|
-
}, {
|
|
83
|
-
key: "onHover",
|
|
84
|
-
value: function onHover(e) {
|
|
85
|
-
var _this$props3 = this.props,
|
|
86
|
-
onHover = _this$props3.onHover,
|
|
87
|
-
id = _this$props3.id,
|
|
88
|
-
value = _this$props3.value,
|
|
89
|
-
index = _this$props3.index;
|
|
90
|
-
onHover && onHover(id, value, index, e);
|
|
91
|
-
}
|
|
92
|
-
}, {
|
|
93
|
-
key: "render",
|
|
94
|
-
value: function render() {
|
|
95
|
-
var _this$props4 = this.props,
|
|
96
|
-
value = _this$props4.value,
|
|
97
|
-
active = _this$props4.active,
|
|
98
|
-
children = _this$props4.children,
|
|
99
|
-
hightlight = _this$props4.hightlight,
|
|
100
|
-
dataId = _this$props4.dataId,
|
|
101
|
-
_this$props4$customCl = _this$props4.customClass,
|
|
102
|
-
customClass = _this$props4$customCl === void 0 ? '' : _this$props4$customCl;
|
|
103
|
-
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
104
|
-
className: "".concat(_DropDownItemModule["default"].list, " ").concat(customClass, " ").concat(active ? _DropDownItemModule["default"].listActive : hightlight ? _DropDownItemModule["default"].listHover : '', " ").concat(children && children[1] ? _DropDownItemModule["default"].padding : ''),
|
|
105
|
-
onClick: this.onClick,
|
|
106
|
-
onMouseOver: this.onHover,
|
|
107
|
-
ref: this.getRef,
|
|
108
|
-
"data-id": dataId,
|
|
109
|
-
"data-test-id": dataId
|
|
110
|
-
}, children && children[0] ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
111
|
-
className: _DropDownItemModule["default"].children
|
|
112
|
-
}, " ", children[0], " ") : children !== undefined ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
113
|
-
className: _DropDownItemModule["default"].children
|
|
114
|
-
}, " ", children, " ") : null, value ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
115
|
-
className: _DropDownItemModule["default"].value
|
|
116
|
-
}, value) : '', children && children[1] ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
117
|
-
className: _DropDownItemModule["default"].user
|
|
118
|
-
}, " ", children[1], " ") : '');
|
|
119
|
-
}
|
|
120
|
-
}]);
|
|
121
|
-
|
|
122
|
-
return DropDownItem;
|
|
123
|
-
}(_react["default"].Component);
|
|
56
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
57
|
+
className: "".concat(_DropDownItemModule["default"].list, " ").concat(customClass, " ").concat(active ? _DropDownItemModule["default"].listActive : hightlight ? _DropDownItemModule["default"].listHover : '', " ").concat(children && children[1] ? _DropDownItemModule["default"].padding : ''),
|
|
58
|
+
onClick: handleClick,
|
|
59
|
+
onMouseOver: handleHover,
|
|
60
|
+
ref: getReference,
|
|
61
|
+
"data-id": dataId,
|
|
62
|
+
"data-test-id": dataId
|
|
63
|
+
}, children && children[0] ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
64
|
+
className: _DropDownItemModule["default"].children
|
|
65
|
+
}, " ", children[0], " ") : children !== undefined ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
66
|
+
className: _DropDownItemModule["default"].children
|
|
67
|
+
}, " ", children, " ") : null, value ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
68
|
+
className: _DropDownItemModule["default"].value
|
|
69
|
+
}, value) : '', children && children[1] ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
70
|
+
className: _DropDownItemModule["default"].user
|
|
71
|
+
}, " ", children[1], " ") : '');
|
|
72
|
+
}
|
|
124
73
|
|
|
125
|
-
exports["default"] = DropDownItem;
|
|
126
74
|
DropDownItem.propTypes = _propTypes.DropDownItem_propTypes;
|
|
127
75
|
DropDownItem.defaultProps = _defaultProps.DropDownItem_defaultProps;
|