@zohodesk/components 1.2.4 → 1.2.5
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 +4 -0
- 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/index.html +1 -1
- package/coverage/utils/dummyFunction.js.html +1 -1
- package/coverage/utils/index.html +1 -1
- package/es/v1/Accordion/Accordion.js +65 -0
- package/es/v1/Accordion/AccordionItem.js +57 -0
- package/es/v1/Accordion/index.js +2 -0
- package/es/v1/Animation/Animation.js +127 -0
- package/es/v1/AppContainer/AppContainer.js +134 -0
- package/es/v1/Avatar/Avatar.js +189 -0
- package/es/v1/AvatarTeam/AvatarTeam.js +70 -0
- package/es/v1/Button/Button.js +68 -0
- package/es/v1/Buttongroup/Buttongroup.js +31 -0
- package/es/v1/Card/Card.js +271 -0
- package/es/v1/CheckBox/CheckBox.js +155 -0
- package/es/v1/DateTime/CalendarView.js +218 -0
- package/es/v1/DateTime/DateTime.js +783 -0
- package/es/v1/DateTime/DateTimePopupFooter.js +47 -0
- package/es/v1/DateTime/DateTimePopupHeader.js +105 -0
- package/es/v1/DateTime/DateWidget.js +1098 -0
- package/es/v1/DateTime/DaysRow.js +31 -0
- package/es/v1/DateTime/Time.js +166 -0
- package/es/v1/DateTime/YearView.js +264 -0
- package/es/v1/DateTime/index.js +1 -0
- package/es/v1/DropBox/DropBox.js +91 -0
- package/es/v1/DropBox/DropBoxElement/DropBoxElement.js +132 -0
- package/es/v1/DropDown/DropDown.js +73 -0
- package/es/v1/DropDown/DropDownHeading.js +44 -0
- package/es/v1/DropDown/DropDownItem.js +76 -0
- package/es/v1/DropDown/DropDownSearch.js +63 -0
- package/es/v1/DropDown/DropDownSeparator.js +15 -0
- package/es/v1/Heading/Heading.js +32 -0
- package/es/v1/Label/Label.js +40 -0
- package/es/v1/Layout/Box.js +115 -0
- package/es/v1/Layout/Container.js +132 -0
- package/es/v1/Layout/index.js +2 -0
- package/es/v1/ListItem/ListContainer.js +102 -0
- package/es/v1/ListItem/ListItem.js +124 -0
- package/es/v1/ListItem/ListItemWithAvatar.js +145 -0
- package/es/v1/ListItem/ListItemWithCheckBox.js +104 -0
- package/es/v1/ListItem/ListItemWithIcon.js +127 -0
- package/es/v1/ListItem/ListItemWithRadio.js +105 -0
- package/es/v1/ListItem/index.js +6 -0
- package/es/v1/Modal/Modal.js +154 -0
- package/es/v1/MultiSelect/AdvancedGroupMultiSelect.js +1079 -0
- package/es/v1/MultiSelect/AdvancedMultiSelect.js +568 -0
- package/es/v1/MultiSelect/EmptyState.js +64 -0
- package/es/v1/MultiSelect/MobileHeader/MobileHeader.js +50 -0
- package/es/v1/MultiSelect/MultiSelect.js +1120 -0
- package/es/v1/MultiSelect/MultiSelectHeader.js +32 -0
- package/es/v1/MultiSelect/MultiSelectWithAvatar.js +216 -0
- package/es/v1/MultiSelect/SelectedOptions.js +82 -0
- package/es/v1/MultiSelect/Suggestions.js +142 -0
- package/es/v1/MultiSelect/index.js +4 -0
- package/es/v1/PopOver/PopOver.js +211 -0
- package/es/v1/Popup/Popup.js +645 -0
- package/es/v1/Radio/Radio.js +115 -0
- package/es/v1/Responsive/CustomResponsive.js +195 -0
- package/es/v1/Responsive/RefWrapper.js +39 -0
- package/es/v1/Responsive/ResizeComponent.js +197 -0
- package/es/v1/Responsive/ResizeObserver.js +140 -0
- package/es/v1/Responsive/Responsive.js +194 -0
- package/es/v1/Responsive/index.js +9 -0
- package/es/v1/ResponsiveDropBox/ResponsiveDropBox.js +58 -0
- package/es/v1/Ribbon/Ribbon.js +33 -0
- package/es/v1/RippleEffect/RippleEffect.js +24 -0
- package/es/v1/Select/GroupSelect.js +803 -0
- package/es/v1/Select/Select.js +969 -0
- package/es/v1/Select/SelectWithAvatar.js +344 -0
- package/es/v1/Select/SelectWithIcon.js +535 -0
- package/es/v1/Select/index.js +4 -0
- package/es/v1/Stencils/Stencils.js +26 -0
- package/es/v1/Switch/Switch.js +94 -0
- package/es/v1/Tab/Tab.js +108 -0
- package/es/v1/Tab/TabContent.js +30 -0
- package/es/v1/Tab/TabContentWrapper.js +29 -0
- package/es/v1/Tab/TabWrapper.js +57 -0
- package/es/v1/Tab/Tabs.js +612 -0
- package/es/v1/Tab/index.js +5 -0
- package/es/v1/Tag/Tag.js +134 -0
- package/es/v1/TextBox/TextBox.js +154 -0
- package/es/v1/TextBoxIcon/TextBoxIcon.js +158 -0
- package/es/v1/Textarea/Textarea.js +102 -0
- package/es/v1/Tooltip/Tooltip.js +518 -0
- package/es/v1/Typography/Typography.js +38 -0
- package/es/v1/Typography/css/Typography.module.css +376 -0
- package/es/v1/Typography/css/cssJSLogic.js +46 -0
- package/es/v1/Typography/css/letterSpacingMap.js +12 -0
- package/es/v1/Typography/props/defaultProps.js +8 -0
- package/es/v1/Typography/props/propTypes.js +24 -0
- package/es/v1/VelocityAnimation/VelocityAnimation/VelocityAnimation.js +69 -0
- package/es/v1/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +100 -0
- package/es/v1/semantic/Button/Button.js +53 -0
- package/es/v1/semantic/index.js +1 -0
- package/lib/v1/Accordion/Accordion.js +96 -0
- package/lib/v1/Accordion/AccordionItem.js +68 -0
- package/lib/v1/Accordion/index.js +23 -0
- package/lib/v1/Animation/Animation.js +143 -0
- package/lib/v1/AppContainer/AppContainer.js +204 -0
- package/lib/v1/Avatar/Avatar.js +246 -0
- package/lib/v1/AvatarTeam/AvatarTeam.js +81 -0
- package/lib/v1/Button/Button.js +82 -0
- package/lib/v1/Buttongroup/Buttongroup.js +44 -0
- package/lib/v1/Card/Card.js +365 -0
- package/lib/v1/CheckBox/CheckBox.js +166 -0
- package/lib/v1/DateTime/CalendarView.js +285 -0
- package/lib/v1/DateTime/DateTime.js +872 -0
- package/lib/v1/DateTime/DateTimePopupFooter.js +96 -0
- package/lib/v1/DateTime/DateTimePopupHeader.js +166 -0
- package/lib/v1/DateTime/DateWidget.js +1125 -0
- package/lib/v1/DateTime/DaysRow.js +80 -0
- package/lib/v1/DateTime/Time.js +254 -0
- package/lib/v1/DateTime/YearView.js +325 -0
- package/lib/v1/DateTime/index.js +15 -0
- package/lib/v1/DropBox/DropBox.js +119 -0
- package/lib/v1/DropBox/DropBoxElement/DropBoxElement.js +145 -0
- package/lib/v1/DropDown/DropDown.js +170 -0
- package/lib/v1/DropDown/DropDownHeading.js +93 -0
- package/lib/v1/DropDown/DropDownItem.js +127 -0
- package/lib/v1/DropDown/DropDownSearch.js +113 -0
- package/lib/v1/DropDown/DropDownSeparator.js +64 -0
- package/lib/v1/Heading/Heading.js +49 -0
- package/lib/v1/Label/Label.js +51 -0
- package/lib/v1/Layout/Box.js +128 -0
- package/lib/v1/Layout/Container.js +145 -0
- package/lib/v1/Layout/index.js +23 -0
- package/lib/v1/ListItem/ListContainer.js +120 -0
- package/lib/v1/ListItem/ListItem.js +138 -0
- package/lib/v1/ListItem/ListItemWithAvatar.js +162 -0
- package/lib/v1/ListItem/ListItemWithCheckBox.js +125 -0
- package/lib/v1/ListItem/ListItemWithIcon.js +143 -0
- package/lib/v1/ListItem/ListItemWithRadio.js +126 -0
- package/lib/v1/ListItem/index.js +55 -0
- package/lib/v1/Modal/Modal.js +212 -0
- package/lib/v1/MultiSelect/AdvancedGroupMultiSelect.js +1167 -0
- package/lib/v1/MultiSelect/AdvancedMultiSelect.js +634 -0
- package/lib/v1/MultiSelect/EmptyState.js +112 -0
- package/lib/v1/MultiSelect/MobileHeader/MobileHeader.js +62 -0
- package/lib/v1/MultiSelect/MultiSelect.js +1201 -0
- package/lib/v1/MultiSelect/MultiSelectHeader.js +78 -0
- package/lib/v1/MultiSelect/MultiSelectWithAvatar.js +270 -0
- package/lib/v1/MultiSelect/SelectedOptions.js +126 -0
- package/lib/v1/MultiSelect/Suggestions.js +195 -0
- package/lib/v1/MultiSelect/index.js +39 -0
- package/lib/v1/PopOver/PopOver.js +293 -0
- package/lib/v1/Popup/Popup.js +715 -0
- package/lib/v1/Radio/Radio.js +126 -0
- package/lib/v1/Responsive/CustomResponsive.js +242 -0
- package/lib/v1/Responsive/RefWrapper.js +57 -0
- package/lib/v1/Responsive/ResizeComponent.js +268 -0
- package/lib/v1/Responsive/ResizeObserver.js +168 -0
- package/lib/v1/Responsive/Responsive.js +274 -0
- package/lib/v1/Responsive/index.js +55 -0
- package/lib/v1/ResponsiveDropBox/ResponsiveDropBox.js +79 -0
- package/lib/v1/Ribbon/Ribbon.js +44 -0
- package/lib/v1/RippleEffect/RippleEffect.js +39 -0
- package/lib/v1/Select/GroupSelect.js +877 -0
- package/lib/v1/Select/Select.js +1013 -0
- package/lib/v1/Select/SelectWithAvatar.js +394 -0
- package/lib/v1/Select/SelectWithIcon.js +597 -0
- package/lib/v1/Select/index.js +39 -0
- package/lib/v1/Stencils/Stencils.js +43 -0
- package/lib/v1/Switch/Switch.js +108 -0
- package/lib/v1/Tab/Tab.js +132 -0
- package/lib/v1/Tab/TabContent.js +42 -0
- package/lib/v1/Tab/TabContentWrapper.js +42 -0
- package/lib/v1/Tab/TabWrapper.js +89 -0
- package/lib/v1/Tab/Tabs.js +680 -0
- package/lib/v1/Tab/index.js +47 -0
- package/lib/v1/Tag/Tag.js +154 -0
- package/lib/v1/TextBox/TextBox.js +168 -0
- package/lib/v1/TextBoxIcon/TextBoxIcon.js +196 -0
- package/lib/v1/Textarea/Textarea.js +118 -0
- package/lib/v1/Tooltip/Tooltip.js +586 -0
- package/lib/v1/Typography/Typography.js +56 -0
- package/lib/v1/Typography/css/Typography.module.css +376 -0
- package/lib/v1/Typography/css/cssJSLogic.js +41 -0
- package/lib/v1/Typography/css/letterSpacingMap.js +20 -0
- package/lib/v1/Typography/props/defaultProps.js +15 -0
- package/lib/v1/Typography/props/propTypes.js +35 -0
- package/lib/v1/VelocityAnimation/VelocityAnimation/VelocityAnimation.js +90 -0
- package/lib/v1/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +126 -0
- package/lib/v1/semantic/Button/Button.js +63 -0
- package/lib/v1/semantic/index.js +15 -0
- package/package.json +1 -1
- package/result.json +1 -1
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"use strict";
|
|
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
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _propTypes = require("../../DateTime/props/propTypes");
|
|
13
|
+
|
|
14
|
+
var _defaultProps = require("../../DateTime/props/defaultProps");
|
|
15
|
+
|
|
16
|
+
var _Layout = require("../Layout");
|
|
17
|
+
|
|
18
|
+
var _Button = _interopRequireDefault(require("../Button/Button"));
|
|
19
|
+
|
|
20
|
+
var _DateTimeModule = _interopRequireDefault(require("../../DateTime/DateTime.module.css"));
|
|
21
|
+
|
|
22
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
23
|
+
|
|
24
|
+
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); }
|
|
25
|
+
|
|
26
|
+
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; }
|
|
27
|
+
|
|
28
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
29
|
+
|
|
30
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
31
|
+
|
|
32
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
33
|
+
|
|
34
|
+
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); }
|
|
35
|
+
|
|
36
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
37
|
+
|
|
38
|
+
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); }; }
|
|
39
|
+
|
|
40
|
+
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); }
|
|
41
|
+
|
|
42
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
43
|
+
|
|
44
|
+
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; } }
|
|
45
|
+
|
|
46
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
47
|
+
|
|
48
|
+
var DateTimePopupFooter = /*#__PURE__*/function (_PureComponent) {
|
|
49
|
+
_inherits(DateTimePopupFooter, _PureComponent);
|
|
50
|
+
|
|
51
|
+
var _super = _createSuper(DateTimePopupFooter);
|
|
52
|
+
|
|
53
|
+
function DateTimePopupFooter() {
|
|
54
|
+
_classCallCheck(this, DateTimePopupFooter);
|
|
55
|
+
|
|
56
|
+
return _super.apply(this, arguments);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
_createClass(DateTimePopupFooter, [{
|
|
60
|
+
key: "render",
|
|
61
|
+
value: function render() {
|
|
62
|
+
var _this$props = this.props,
|
|
63
|
+
submitText = _this$props.submitText,
|
|
64
|
+
onSubmit = _this$props.onSubmit,
|
|
65
|
+
cancelText = _this$props.cancelText,
|
|
66
|
+
onCancel = _this$props.onCancel,
|
|
67
|
+
dataId = _this$props.dataId;
|
|
68
|
+
return /*#__PURE__*/_react["default"].createElement(_Layout.Container, {
|
|
69
|
+
isCover: false,
|
|
70
|
+
align: "vertical",
|
|
71
|
+
alignBox: "row",
|
|
72
|
+
className: _DateTimeModule["default"].footer
|
|
73
|
+
}, /*#__PURE__*/_react["default"].createElement(_Button["default"], {
|
|
74
|
+
text: submitText,
|
|
75
|
+
size: "medium",
|
|
76
|
+
palette: "primaryFilled",
|
|
77
|
+
onClick: onSubmit,
|
|
78
|
+
dataId: "".concat(dataId, "_saveBtn")
|
|
79
|
+
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
80
|
+
className: _DateTimeModule["default"].space
|
|
81
|
+
}), /*#__PURE__*/_react["default"].createElement(_Button["default"], {
|
|
82
|
+
text: cancelText,
|
|
83
|
+
size: "medium",
|
|
84
|
+
palette: "secondary",
|
|
85
|
+
onClick: onCancel,
|
|
86
|
+
dataId: "".concat(dataId, "_clearBtn")
|
|
87
|
+
}));
|
|
88
|
+
}
|
|
89
|
+
}]);
|
|
90
|
+
|
|
91
|
+
return DateTimePopupFooter;
|
|
92
|
+
}(_react.PureComponent);
|
|
93
|
+
|
|
94
|
+
exports["default"] = DateTimePopupFooter;
|
|
95
|
+
DateTimePopupFooter.propTypes = _propTypes.DateTimePopupFooter_propTypes;
|
|
96
|
+
DateTimePopupFooter.defaultProps = _defaultProps.DateTimePopupFooter_defaultProps;
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
"use strict";
|
|
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
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _propTypes = require("../../DateTime/props/propTypes");
|
|
13
|
+
|
|
14
|
+
var _Layout = require("../Layout");
|
|
15
|
+
|
|
16
|
+
var _icons = require("@zohodesk/icons");
|
|
17
|
+
|
|
18
|
+
var _Heading = _interopRequireDefault(require("../Heading/Heading"));
|
|
19
|
+
|
|
20
|
+
var _DateTimeModule = _interopRequireDefault(require("../../DateTime/DateTime.module.css"));
|
|
21
|
+
|
|
22
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
23
|
+
|
|
24
|
+
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); }
|
|
25
|
+
|
|
26
|
+
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; }
|
|
27
|
+
|
|
28
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
29
|
+
|
|
30
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
31
|
+
|
|
32
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
33
|
+
|
|
34
|
+
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); }
|
|
35
|
+
|
|
36
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
37
|
+
|
|
38
|
+
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); }; }
|
|
39
|
+
|
|
40
|
+
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); }
|
|
41
|
+
|
|
42
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
43
|
+
|
|
44
|
+
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; } }
|
|
45
|
+
|
|
46
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
47
|
+
|
|
48
|
+
var Span = /*#__PURE__*/function (_React$PureComponent) {
|
|
49
|
+
_inherits(Span, _React$PureComponent);
|
|
50
|
+
|
|
51
|
+
var _super = _createSuper(Span);
|
|
52
|
+
|
|
53
|
+
function Span(props) {
|
|
54
|
+
var _this;
|
|
55
|
+
|
|
56
|
+
_classCallCheck(this, Span);
|
|
57
|
+
|
|
58
|
+
_this = _super.call(this, props);
|
|
59
|
+
_this.modifyCalendarChild = _this.modifyCalendarChild.bind(_assertThisInitialized(_this));
|
|
60
|
+
return _this;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
_createClass(Span, [{
|
|
64
|
+
key: "modifyCalendarChild",
|
|
65
|
+
value: function modifyCalendarChild() {
|
|
66
|
+
var _this$props = this.props,
|
|
67
|
+
modifyCalendar = _this$props.modifyCalendar,
|
|
68
|
+
type = _this$props.type;
|
|
69
|
+
modifyCalendar(type);
|
|
70
|
+
}
|
|
71
|
+
}, {
|
|
72
|
+
key: "render",
|
|
73
|
+
value: function render() {
|
|
74
|
+
var _this$props2 = this.props,
|
|
75
|
+
dataTitle = _this$props2.dataTitle,
|
|
76
|
+
children = _this$props2.children,
|
|
77
|
+
dataId = _this$props2.dataId,
|
|
78
|
+
_this$props2$classNam = _this$props2.className,
|
|
79
|
+
className = _this$props2$classNam === void 0 ? '' : _this$props2$classNam,
|
|
80
|
+
ariaLabel = _this$props2.ariaLabel;
|
|
81
|
+
return /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
82
|
+
"data-title": dataTitle,
|
|
83
|
+
dataId: dataId,
|
|
84
|
+
className: "".concat(_DateTimeModule["default"].thArrow, " ").concat(_DateTimeModule["default"].grid, " ").concat(className),
|
|
85
|
+
onClick: this.modifyCalendarChild,
|
|
86
|
+
"aria-label": ariaLabel,
|
|
87
|
+
tabindex: "0"
|
|
88
|
+
}, children);
|
|
89
|
+
}
|
|
90
|
+
}]);
|
|
91
|
+
|
|
92
|
+
return Span;
|
|
93
|
+
}(_react["default"].PureComponent);
|
|
94
|
+
|
|
95
|
+
var DateTimePopupHeader = /*#__PURE__*/function (_PureComponent) {
|
|
96
|
+
_inherits(DateTimePopupHeader, _PureComponent);
|
|
97
|
+
|
|
98
|
+
var _super2 = _createSuper(DateTimePopupHeader);
|
|
99
|
+
|
|
100
|
+
function DateTimePopupHeader() {
|
|
101
|
+
_classCallCheck(this, DateTimePopupHeader);
|
|
102
|
+
|
|
103
|
+
return _super2.apply(this, arguments);
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
_createClass(DateTimePopupHeader, [{
|
|
107
|
+
key: "render",
|
|
108
|
+
value: function render() {
|
|
109
|
+
var _this$props3 = this.props,
|
|
110
|
+
onOpenYearView = _this$props3.onOpenYearView,
|
|
111
|
+
showMonthTxt = _this$props3.showMonthTxt,
|
|
112
|
+
isYearView = _this$props3.isYearView,
|
|
113
|
+
prevMonthTitleText = _this$props3.prevMonthTitleText,
|
|
114
|
+
nextMonthTitleText = _this$props3.nextMonthTitleText,
|
|
115
|
+
onModifyCalendar = _this$props3.onModifyCalendar;
|
|
116
|
+
return /*#__PURE__*/_react["default"].createElement(_Layout.Container, {
|
|
117
|
+
alignBox: "row",
|
|
118
|
+
align: "both",
|
|
119
|
+
className: _DateTimeModule["default"].header
|
|
120
|
+
}, /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
121
|
+
className: _DateTimeModule["default"].dateText,
|
|
122
|
+
dataId: "selectYear",
|
|
123
|
+
onClick: onOpenYearView
|
|
124
|
+
}, /*#__PURE__*/_react["default"].createElement(_Heading["default"], {
|
|
125
|
+
className: _DateTimeModule["default"].thMonYear,
|
|
126
|
+
title: showMonthTxt,
|
|
127
|
+
tagName: "h2",
|
|
128
|
+
a11y: {
|
|
129
|
+
tabindex: '0'
|
|
130
|
+
}
|
|
131
|
+
}), /*#__PURE__*/_react["default"].createElement("span", null, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
|
|
132
|
+
name: "ZD-GN-dropdown",
|
|
133
|
+
size: "12",
|
|
134
|
+
iconClass: _DateTimeModule["default"].downArrow
|
|
135
|
+
}))), /*#__PURE__*/_react["default"].createElement(_Layout.Box, {
|
|
136
|
+
flexible: true
|
|
137
|
+
}), !isYearView ? /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement(Span, {
|
|
138
|
+
dataTitle: prevMonthTitleText,
|
|
139
|
+
dataId: "prevMonth",
|
|
140
|
+
modifyCalendar: onModifyCalendar,
|
|
141
|
+
type: "previousMonth",
|
|
142
|
+
ariaLabel: "prevMonth",
|
|
143
|
+
tabindex: "0"
|
|
144
|
+
}, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
|
|
145
|
+
name: "ZD-arrowLeft3",
|
|
146
|
+
isBold: true
|
|
147
|
+
})), /*#__PURE__*/_react["default"].createElement(Span, {
|
|
148
|
+
dataTitle: nextMonthTitleText,
|
|
149
|
+
dataId: "nextMonth",
|
|
150
|
+
modifyCalendar: onModifyCalendar,
|
|
151
|
+
type: "nextMonth",
|
|
152
|
+
className: _DateTimeModule["default"].navigation,
|
|
153
|
+
ariaLabel: "nextMonth",
|
|
154
|
+
tabindex: "0"
|
|
155
|
+
}, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
|
|
156
|
+
name: "ZD-arrowRight3",
|
|
157
|
+
isBold: true
|
|
158
|
+
}))) : null);
|
|
159
|
+
}
|
|
160
|
+
}]);
|
|
161
|
+
|
|
162
|
+
return DateTimePopupHeader;
|
|
163
|
+
}(_react.PureComponent);
|
|
164
|
+
|
|
165
|
+
exports["default"] = DateTimePopupHeader;
|
|
166
|
+
DateTimePopupHeader.propTypes = _propTypes.DateTimePopupHeader_propTypes;
|