@atlaskit/datetime-picker 16.2.3 → 17.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +27 -0
- package/dist/cjs/components/date-picker-class.compiled.css +16 -0
- package/dist/cjs/components/date-picker-class.js +122 -146
- package/dist/cjs/components/date-picker-fc.compiled.css +16 -0
- package/dist/cjs/components/date-picker-fc.js +117 -144
- package/dist/cjs/components/date-time-picker-class.compiled.css +19 -0
- package/dist/cjs/components/date-time-picker-class.js +22 -47
- package/dist/cjs/components/date-time-picker-fc.compiled.css +6 -0
- package/dist/cjs/components/date-time-picker-fc.js +22 -27
- package/dist/cjs/components/time-picker.js +1 -1
- package/dist/cjs/internal/date-time-picker-container.compiled.css +21 -0
- package/dist/cjs/internal/date-time-picker-container.js +26 -71
- package/dist/cjs/internal/ff-component.js +0 -2
- package/dist/cjs/internal/fixed-layer-menu.js +8 -8
- package/dist/cjs/internal/fixed-layer.compiled.css +4 -0
- package/dist/cjs/internal/fixed-layer.js +14 -13
- package/dist/cjs/internal/indicators-container.compiled.css +2 -0
- package/dist/cjs/internal/indicators-container.js +14 -15
- package/dist/cjs/internal/menu.compiled.css +6 -0
- package/dist/cjs/internal/menu.js +15 -32
- package/dist/es2019/components/date-picker-class.compiled.css +16 -0
- package/dist/es2019/components/date-picker-class.js +117 -143
- package/dist/es2019/components/date-picker-fc.compiled.css +16 -0
- package/dist/es2019/components/date-picker-fc.js +114 -141
- package/dist/es2019/components/date-time-picker-class.compiled.css +19 -0
- package/dist/es2019/components/date-time-picker-class.js +21 -49
- package/dist/es2019/components/date-time-picker-fc.compiled.css +6 -0
- package/dist/es2019/components/date-time-picker-fc.js +19 -24
- package/dist/es2019/components/time-picker.js +1 -1
- package/dist/es2019/internal/date-time-picker-container.compiled.css +21 -0
- package/dist/es2019/internal/date-time-picker-container.js +18 -69
- package/dist/es2019/internal/ff-component.js +0 -2
- package/dist/es2019/internal/fixed-layer-menu.js +5 -8
- package/dist/es2019/internal/fixed-layer.compiled.css +4 -0
- package/dist/es2019/internal/fixed-layer.js +13 -12
- package/dist/es2019/internal/indicators-container.compiled.css +2 -0
- package/dist/es2019/internal/indicators-container.js +11 -16
- package/dist/es2019/internal/menu.compiled.css +6 -0
- package/dist/es2019/internal/menu.js +11 -30
- package/dist/esm/components/date-picker-class.compiled.css +16 -0
- package/dist/esm/components/date-picker-class.js +120 -147
- package/dist/esm/components/date-picker-fc.compiled.css +16 -0
- package/dist/esm/components/date-picker-fc.js +116 -144
- package/dist/esm/components/date-time-picker-class.compiled.css +19 -0
- package/dist/esm/components/date-time-picker-class.js +21 -49
- package/dist/esm/components/date-time-picker-fc.compiled.css +6 -0
- package/dist/esm/components/date-time-picker-fc.js +19 -24
- package/dist/esm/components/time-picker.js +1 -1
- package/dist/esm/internal/date-time-picker-container.compiled.css +21 -0
- package/dist/esm/internal/date-time-picker-container.js +22 -69
- package/dist/esm/internal/ff-component.js +0 -2
- package/dist/esm/internal/fixed-layer-menu.js +5 -8
- package/dist/esm/internal/fixed-layer.compiled.css +4 -0
- package/dist/esm/internal/fixed-layer.js +13 -13
- package/dist/esm/internal/indicators-container.compiled.css +2 -0
- package/dist/esm/internal/indicators-container.js +11 -16
- package/dist/esm/internal/menu.compiled.css +6 -0
- package/dist/esm/internal/menu.js +11 -30
- package/dist/types/components/date-picker-class.d.ts +2 -3
- package/dist/types/components/date-picker.d.ts +1 -1
- package/dist/types/components/date-time-picker-class.d.ts +4 -5
- package/dist/types/components/date-time-picker.d.ts +3 -3
- package/dist/types/internal/date-time-picker-container.d.ts +4 -0
- package/dist/types/internal/fixed-layer-menu.d.ts +2 -6
- package/dist/types/internal/fixed-layer.d.ts +5 -1
- package/dist/types/internal/indicators-container.d.ts +2 -2
- package/dist/types/internal/menu.d.ts +6 -2
- package/dist/types-ts4.5/components/date-picker-class.d.ts +2 -3
- package/dist/types-ts4.5/components/date-picker.d.ts +1 -1
- package/dist/types-ts4.5/components/date-time-picker-class.d.ts +4 -5
- package/dist/types-ts4.5/components/date-time-picker.d.ts +3 -3
- package/dist/types-ts4.5/internal/date-time-picker-container.d.ts +4 -0
- package/dist/types-ts4.5/internal/fixed-layer-menu.d.ts +2 -6
- package/dist/types-ts4.5/internal/fixed-layer.d.ts +5 -1
- package/dist/types-ts4.5/internal/indicators-container.d.ts +2 -2
- package/dist/types-ts4.5/internal/menu.d.ts +6 -2
- package/package.json +12 -12
|
@@ -1,70 +1,20 @@
|
|
|
1
|
+
/* date-time-picker-container.tsx generated by @compiled/babel-plugin v0.36.1 */
|
|
1
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
|
|
3
|
-
*
|
|
4
|
-
|
|
5
|
-
*/
|
|
6
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
3
|
+
import "./date-time-picker-container.compiled.css";
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
7
6
|
import { forwardRef } from 'react';
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
var
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
var
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
var
|
|
18
|
-
|
|
19
|
-
});
|
|
20
|
-
var subtleBgStyles = css({
|
|
21
|
-
backgroundColor: 'transparent',
|
|
22
|
-
borderColor: 'transparent'
|
|
23
|
-
});
|
|
24
|
-
var subtleFocusedBgStyles = css({
|
|
25
|
-
backgroundColor: "var(--ds-background-input-pressed, transparent)",
|
|
26
|
-
borderColor: 'transparent'
|
|
27
|
-
});
|
|
28
|
-
var noBgStyles = css({
|
|
29
|
-
backgroundColor: 'transparent',
|
|
30
|
-
borderColor: 'transparent',
|
|
31
|
-
'&:hover': {
|
|
32
|
-
backgroundColor: 'transparent',
|
|
33
|
-
borderColor: 'transparent'
|
|
34
|
-
}
|
|
35
|
-
});
|
|
36
|
-
var hoverStyles = css({
|
|
37
|
-
'&:hover': {
|
|
38
|
-
backgroundColor: "var(--ds-background-input-hovered, ".concat(N30, ")"),
|
|
39
|
-
borderColor: "var(--ds-border-input, ".concat(N100, ")")
|
|
40
|
-
}
|
|
41
|
-
});
|
|
42
|
-
var isInvalidHoverStyles = css({
|
|
43
|
-
'&:hover': {
|
|
44
|
-
backgroundColor: "var(--ds-background-input-hovered, ".concat(N0, ")"),
|
|
45
|
-
borderColor: "var(--ds-border-danger, ".concat(R400, ")")
|
|
46
|
-
}
|
|
47
|
-
});
|
|
48
|
-
var isDisabledStyles = css({
|
|
49
|
-
backgroundColor: "var(--ds-background-disabled, #091E4208)",
|
|
50
|
-
borderColor: "var(--ds-border-disabled, #091E420F)",
|
|
51
|
-
'&:hover': {
|
|
52
|
-
cursor: 'default'
|
|
53
|
-
}
|
|
54
|
-
});
|
|
55
|
-
var newBorderStyles = css({
|
|
56
|
-
border: "var(--ds-border-width, 1px)".concat(" solid ", "var(--ds-border-input, ".concat(N100, ")"))
|
|
57
|
-
});
|
|
58
|
-
var baseContainerStyles = css({
|
|
59
|
-
display: 'flex',
|
|
60
|
-
backgroundColor: "var(--ds-background-input, ".concat(N20, ")"),
|
|
61
|
-
border: "2px solid ".concat("var(--ds-border-input, ".concat(N20, ")")),
|
|
62
|
-
borderRadius: "var(--ds-border-radius, 3px)",
|
|
63
|
-
transition: 'background-color 200ms ease-in-out, border-color 200ms ease-in-out',
|
|
64
|
-
'&:hover': {
|
|
65
|
-
cursor: 'pointer'
|
|
66
|
-
}
|
|
67
|
-
});
|
|
7
|
+
var isInvalidBorderStyles = null;
|
|
8
|
+
var isFocusedBorderStyles = null;
|
|
9
|
+
var isFocusedStyles = null;
|
|
10
|
+
var subtleBgStyles = null;
|
|
11
|
+
var subtleFocusedBgStyles = null;
|
|
12
|
+
var noBgStyles = null;
|
|
13
|
+
var hoverStyles = null;
|
|
14
|
+
var isInvalidHoverStyles = null;
|
|
15
|
+
var isDisabledStyles = null;
|
|
16
|
+
var newBorderStyles = null;
|
|
17
|
+
var baseContainerStyles = null;
|
|
68
18
|
/**
|
|
69
19
|
* This is the container for the datetime picker component.
|
|
70
20
|
*/
|
|
@@ -79,10 +29,13 @@ export var DateTimePickerContainer = /*#__PURE__*/forwardRef(function (_ref, ref
|
|
|
79
29
|
var notFocusedOrIsDisabled = !(isFocused || isDisabled);
|
|
80
30
|
|
|
81
31
|
// we cannot use Box or Flex primitives because these do not allow ...innerProps to be passed
|
|
82
|
-
return
|
|
83
|
-
css: [baseContainerStyles, newBorderStyles, isDisabled && isDisabledStyles, isFocused && isFocusedStyles, appearance === 'subtle' && (isFocused ? subtleFocusedBgStyles : subtleBgStyles), isFocused && isFocusedBorderStyles, isInvalid && isInvalidBorderStyles, notFocusedOrIsDisabled && (isInvalid ? isInvalidHoverStyles : hoverStyles), appearance === 'none' && noBgStyles]
|
|
84
|
-
}, innerProps, {
|
|
32
|
+
return /*#__PURE__*/React.createElement("div", _extends({}, innerProps, {
|
|
85
33
|
"data-testid": testId,
|
|
86
|
-
ref: ref
|
|
34
|
+
ref: ref,
|
|
35
|
+
className: ax(["_2rkoglpi _v564r5cv _1e0c1txw _bfhk1j9a _d0altlke", "_19itp69y", isDisabled && "_1h6d13gt _bfhksyzs _d0al73ad", isFocused && "_bfhkr01l", appearance === 'subtle' && isFocused && "_1h6d1j28 _bfhk1y3p", appearance === 'subtle' && !isFocused && "_1h6d1j28 _bfhk1j28", isFocused && "_1h6d1p6i _16qsic8z", isInvalid && "_1h6d1bqt", notFocusedOrIsDisabled && isInvalid && "_4cvx1bqt _irr31d5g", notFocusedOrIsDisabled && !isInvalid && "_4cvx1elr _irr31d5g", appearance === 'none' && "_1h6d1j28 _bfhk1j28 _4cvx1j28 _irr31j28"]),
|
|
36
|
+
style: {
|
|
37
|
+
"--_1p9iyo2": ix("var(--ds-border-width, 1px)".concat(" solid ", "var(--ds-border-input, #8590A2)")),
|
|
38
|
+
"--_1p9nqfm": ix("inset 0 0 0 ".concat("var(--ds-border-width, 1px)", " ", "var(--ds-border-focused, #388BFF)"))
|
|
39
|
+
}
|
|
87
40
|
}), children);
|
|
88
41
|
});
|
|
@@ -43,7 +43,5 @@ export function componentWithCondition(condition, ComponentTrue, ComponentFalse)
|
|
|
43
43
|
if (ComponentTrue.name !== '') {
|
|
44
44
|
ComponentWithCondition.displayName = "ComponentWithCondition[".concat(condition.name, "]");
|
|
45
45
|
}
|
|
46
|
-
|
|
47
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-assertions
|
|
48
46
|
return ComponentWithCondition;
|
|
49
47
|
}
|
|
@@ -1,12 +1,9 @@
|
|
|
1
|
+
/* fixed-layer-menu.tsx generated by @compiled/babel-plugin v0.36.1 */
|
|
1
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
4
|
var _excluded = ["className", "clearValue", "cx", "getStyles", "getValue", "hasValue", "innerProps", "innerRef", "isLoading", "isMulti", "isRtl", "maxMenuHeight", "menuPlacement", "menuPosition", "menuShouldScrollIntoView", "minMenuHeight", "options", "placement", "selectOption", "selectProps", "setValue", "children"];
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
* @jsx jsx
|
|
7
|
-
*/
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
9
|
-
import { jsx } from '@emotion/react';
|
|
5
|
+
import * as React from 'react';
|
|
6
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
10
7
|
import { components } from '@atlaskit/select';
|
|
11
8
|
import FixedLayer from '../internal/fixed-layer';
|
|
12
9
|
|
|
@@ -37,12 +34,12 @@ export var FixedLayerMenu = function FixedLayerMenu(_ref) {
|
|
|
37
34
|
setValue = _ref.setValue,
|
|
38
35
|
children = _ref.children,
|
|
39
36
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
40
|
-
return
|
|
37
|
+
return /*#__PURE__*/React.createElement(FixedLayer, {
|
|
41
38
|
inputValue: selectProps.inputValue
|
|
42
39
|
//@ts-ignore react-select unsupported props
|
|
43
40
|
,
|
|
44
41
|
containerRef: selectProps.fixedLayerRef,
|
|
45
|
-
content:
|
|
42
|
+
content: /*#__PURE__*/React.createElement(components.Menu, _extends({}, rest, {
|
|
46
43
|
// eslint-disable-next-line @atlaskit/design-system/no-unsafe-style-overrides, @atlaskit/ui-styling-standard/no-classname-prop
|
|
47
44
|
className: className,
|
|
48
45
|
clearValue: clearValue,
|
|
@@ -1,19 +1,22 @@
|
|
|
1
|
+
/* fixed-layer.tsx generated by @compiled/babel-plugin v0.36.1 */
|
|
1
2
|
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
2
3
|
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
4
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
4
5
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
5
6
|
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
7
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
7
|
-
|
|
8
|
-
|
|
8
|
+
import "./fixed-layer.compiled.css";
|
|
9
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
9
10
|
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
10
11
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
11
12
|
import React from 'react';
|
|
12
13
|
import noop from '@atlaskit/ds-lib/noop';
|
|
13
14
|
import { sizes } from '@atlaskit/icon';
|
|
14
15
|
import { Manager, Popper, Reference } from '@atlaskit/popper';
|
|
15
|
-
|
|
16
|
-
|
|
16
|
+
var styles = {
|
|
17
|
+
root: "_bfhk1j28 _kqswstnw _154ize3t",
|
|
18
|
+
popperStyles: "_1pbyowjs"
|
|
19
|
+
};
|
|
17
20
|
/**
|
|
18
21
|
* This component renders layered content with fixed positioning.
|
|
19
22
|
* Scroll is locked outside the layer to prevent the layered content from detaching from the
|
|
@@ -53,12 +56,9 @@ var FixedLayer = /*#__PURE__*/function (_React$Component) {
|
|
|
53
56
|
return /*#__PURE__*/React.createElement("div", null);
|
|
54
57
|
}
|
|
55
58
|
var divStyles = {
|
|
56
|
-
background: 'transparent',
|
|
57
|
-
position: 'absolute',
|
|
58
|
-
top: 0,
|
|
59
59
|
height: containerRef.getBoundingClientRect().height,
|
|
60
60
|
// Don't block the clear button
|
|
61
|
-
width: containerRef.getBoundingClientRect().width - parseInt(sizes.small.slice(0, -2)) -
|
|
61
|
+
width: containerRef.getBoundingClientRect().width - parseInt(sizes.small.slice(0, -2)) - 8
|
|
62
62
|
};
|
|
63
63
|
return (
|
|
64
64
|
/*#__PURE__*/
|
|
@@ -70,7 +70,8 @@ var FixedLayer = /*#__PURE__*/function (_React$Component) {
|
|
|
70
70
|
return /*#__PURE__*/React.createElement("div", {
|
|
71
71
|
ref: ref,
|
|
72
72
|
"data-layer-child": true,
|
|
73
|
-
style: divStyles
|
|
73
|
+
style: divStyles,
|
|
74
|
+
className: ax([styles.root])
|
|
74
75
|
});
|
|
75
76
|
}), /*#__PURE__*/React.createElement(Popper, null, function (_ref2) {
|
|
76
77
|
var ref = _ref2.ref,
|
|
@@ -81,10 +82,9 @@ var FixedLayer = /*#__PURE__*/function (_React$Component) {
|
|
|
81
82
|
ref: ref
|
|
82
83
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
83
84
|
,
|
|
84
|
-
style:
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
"data-testid": testId && "".concat(testId, "--popper--container")
|
|
85
|
+
style: style,
|
|
86
|
+
"data-testid": testId && "".concat(testId, "--popper--container"),
|
|
87
|
+
className: ax([styles.popperStyles])
|
|
88
88
|
}, content);
|
|
89
89
|
}))
|
|
90
90
|
);
|
|
@@ -1,25 +1,20 @@
|
|
|
1
|
+
/* indicators-container.tsx generated by @compiled/babel-plugin v0.36.1 */
|
|
1
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
2
3
|
var _excluded = ["showClearIndicator"];
|
|
3
|
-
|
|
4
|
-
*
|
|
5
|
-
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
9
|
-
import { css, jsx } from '@emotion/react';
|
|
4
|
+
import "./indicators-container.compiled.css";
|
|
5
|
+
import * as React from 'react';
|
|
6
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
10
7
|
import { components } from '@atlaskit/select';
|
|
11
|
-
var
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
marginInlineStart: "var(--ds-space-300, 24px)"
|
|
16
|
-
});
|
|
8
|
+
var styles = {
|
|
9
|
+
calendarButtonInclusionStyles: "_ahbqxy5q",
|
|
10
|
+
calendarButtonOnlyInclusionStyles: "_ahbq1ejb"
|
|
11
|
+
};
|
|
17
12
|
|
|
18
13
|
// eslint-disable-next-line @repo/internal/react/require-jsdoc
|
|
19
14
|
export var IndicatorsContainer = function IndicatorsContainer(_ref) {
|
|
20
15
|
var showClearIndicator = _ref.showClearIndicator,
|
|
21
16
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
22
|
-
return
|
|
23
|
-
|
|
24
|
-
},
|
|
17
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
18
|
+
className: ax([showClearIndicator ? styles.calendarButtonInclusionStyles : styles.calendarButtonOnlyInclusionStyles])
|
|
19
|
+
}, /*#__PURE__*/React.createElement(components.IndicatorsContainer, rest));
|
|
25
20
|
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
|
|
2
|
+
._2rkoglpi{border-radius:var(--ds-border-radius,4px)}._16qs1cd0{box-shadow:var(--ds-shadow-overlay,0 8px 9pt #091e4226,0 0 1px #091e424f)}
|
|
3
|
+
._18m915vq{overflow-y:hidden}
|
|
4
|
+
._1pbyowjs{z-index:300}
|
|
5
|
+
._1reo15vq{overflow-x:hidden}
|
|
6
|
+
._bfhk1bhr{background-color:var(--ds-surface-overlay,#fff)}
|
|
@@ -1,16 +1,12 @@
|
|
|
1
|
+
/* menu.tsx generated by @compiled/babel-plugin v0.36.1 */
|
|
1
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
|
|
3
|
-
*
|
|
4
|
-
|
|
5
|
-
*/
|
|
6
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
3
|
+
import "./menu.compiled.css";
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
7
6
|
import { Fragment } from 'react';
|
|
8
|
-
import { css, jsx } from '@emotion/react';
|
|
9
7
|
import { isValid, parseISO } from 'date-fns';
|
|
10
8
|
import Calendar from '@atlaskit/calendar';
|
|
11
9
|
import { Layering } from '@atlaskit/layering';
|
|
12
|
-
import { N0, N50A, N60A } from '@atlaskit/theme/colors';
|
|
13
|
-
import { layers } from '@atlaskit/theme/constants';
|
|
14
10
|
import FixedLayer from '../internal/fixed-layer';
|
|
15
11
|
|
|
16
12
|
/**
|
|
@@ -27,13 +23,7 @@ function getValidDate(isos) {
|
|
|
27
23
|
} : acc;
|
|
28
24
|
}, {});
|
|
29
25
|
}
|
|
30
|
-
var menuStyles =
|
|
31
|
-
zIndex: layers.dialog(),
|
|
32
|
-
backgroundColor: "var(--ds-surface-overlay, ".concat(N0, ")"),
|
|
33
|
-
borderRadius: "var(--ds-border-radius, 3px)",
|
|
34
|
-
boxShadow: "var(--ds-shadow-overlay, ".concat("0 4px 8px -2px ".concat(N50A, ", 0 0 1px ").concat(N60A), ")"),
|
|
35
|
-
overflow: 'hidden'
|
|
36
|
-
});
|
|
26
|
+
var menuStyles = null;
|
|
37
27
|
|
|
38
28
|
/**
|
|
39
29
|
* This is the menu used in the select of the date picker.
|
|
@@ -56,24 +46,15 @@ export var Menu = function Menu(_ref) {
|
|
|
56
46
|
event.preventDefault();
|
|
57
47
|
};
|
|
58
48
|
var Wrapper = typeof MenuInnerWrapper === 'function' ? MenuInnerWrapper : Fragment;
|
|
59
|
-
return
|
|
49
|
+
return /*#__PURE__*/React.createElement(Layering, {
|
|
60
50
|
isDisabled: false
|
|
61
|
-
},
|
|
51
|
+
}, /*#__PURE__*/React.createElement(FixedLayer, {
|
|
62
52
|
inputValue: selectProps.inputValue,
|
|
63
53
|
containerRef: selectProps.calendarContainerRef,
|
|
64
|
-
content:
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
// `react-select` that will stop the calendar select event from
|
|
69
|
-
// firing. This is passed in via the `innerProps`. Therefore, we must
|
|
70
|
-
// pass it in *after* the `innerProps` spread.
|
|
71
|
-
// eslint-disable-next-line jsx-a11y/no-static-element-interactions
|
|
72
|
-
jsx("div", _extends({
|
|
73
|
-
css: menuStyles
|
|
74
|
-
}, innerProps, {
|
|
75
|
-
onMouseDown: onMenuMouseDown
|
|
76
|
-
}), jsx(Wrapper, null, jsx(Calendar, {
|
|
54
|
+
content: /*#__PURE__*/React.createElement("div", _extends({}, innerProps, {
|
|
55
|
+
onMouseDown: onMenuMouseDown,
|
|
56
|
+
className: ax(["_2rkoglpi _1reo15vq _18m915vq _1pbyowjs _bfhk1bhr _16qs1cd0"])
|
|
57
|
+
}), /*#__PURE__*/React.createElement(Wrapper, null, /*#__PURE__*/React.createElement(Calendar, {
|
|
77
58
|
day: day,
|
|
78
59
|
month: month,
|
|
79
60
|
year: year,
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import { Component } from 'react';
|
|
6
|
-
import { jsx } from '@emotion/react';
|
|
7
6
|
import { type LocalizationProvider } from '@atlaskit/locale';
|
|
8
7
|
import { type ActionMeta, type InputActionMeta } from '@atlaskit/select';
|
|
9
8
|
import { type DatePickerBaseProps } from '../types';
|
|
@@ -76,7 +75,7 @@ declare class DatePickerComponent extends Component<DatePickerProps, State> {
|
|
|
76
75
|
onSelectChange: (_value: unknown, action: ActionMeta) => void;
|
|
77
76
|
handleSelectInputChange: (selectInputValue: string, actionMeta: InputActionMeta) => void;
|
|
78
77
|
getContainerRef: (ref: HTMLElement | null) => void;
|
|
79
|
-
render():
|
|
78
|
+
render(): JSX.Element;
|
|
80
79
|
}
|
|
81
80
|
export { DatePickerComponent as DatePickerWithoutAnalytics };
|
|
82
81
|
/**
|
|
@@ -97,7 +96,7 @@ declare const DatePicker: import("react").ForwardRefExoticComponent<Omit<Pick<Om
|
|
|
97
96
|
onBlur: (_event: React.FocusEvent<HTMLInputElement>) => void;
|
|
98
97
|
onChange: (_value: string) => void;
|
|
99
98
|
onFocus: (_event: React.FocusEvent<HTMLInputElement>) => void;
|
|
100
|
-
} & DatePickerBaseProps, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "label" | "parseInputValue" | "dateFormat" | "formatDisplayLabel" | "placeholder" | "appearance" | "isDisabled" | "innerProps" | "selectProps" | "autoFocus" | "id" | "aria-describedby" | "value" | "
|
|
99
|
+
} & DatePickerBaseProps, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "label" | "parseInputValue" | "dateFormat" | "formatDisplayLabel" | "placeholder" | "icon" | "appearance" | "isDisabled" | "innerProps" | "selectProps" | "autoFocus" | "id" | "aria-describedby" | "value" | "name" | "spacing" | "testId" | "clearControlLabel" | "isInvalid" | "isRequired" | "menuInnerWrapper" | "maxDate" | "minDate" | "nextMonthLabel" | "previousMonthLabel" | "weekStartDay" | "isOpen" | "inputLabel" | "inputLabelId" | "openCalendarLabel" | "shouldShowCalendarButton" | "hideIcon"> & {
|
|
101
100
|
disabled?: string[] | undefined;
|
|
102
101
|
defaultValue?: string | undefined;
|
|
103
102
|
onFocus?: (((_event: React.FocusEvent<HTMLInputElement>) => void) & import("react").FocusEventHandler<HTMLInputElement>) | undefined;
|
|
@@ -8,7 +8,7 @@ declare const DatePicker: import("react").FC<Omit<Omit<import("./date-picker-fc"
|
|
|
8
8
|
onBlur: (_event: import("react").FocusEvent<HTMLInputElement, Element>) => void;
|
|
9
9
|
onChange: (_value: string) => void;
|
|
10
10
|
onFocus: (_event: import("react").FocusEvent<HTMLInputElement, Element>) => void;
|
|
11
|
-
} & import("..").DatePickerProps, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "label" | "parseInputValue" | "dateFormat" | "formatDisplayLabel" | "placeholder" | "appearance" | "isDisabled" | "innerProps" | "selectProps" | "autoFocus" | "id" | "aria-describedby" | "value" | "
|
|
11
|
+
} & import("..").DatePickerProps, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "label" | "parseInputValue" | "dateFormat" | "formatDisplayLabel" | "placeholder" | "icon" | "appearance" | "isDisabled" | "innerProps" | "selectProps" | "autoFocus" | "id" | "aria-describedby" | "value" | "name" | "spacing" | "testId" | "clearControlLabel" | "isInvalid" | "isRequired" | "menuInnerWrapper" | "maxDate" | "minDate" | "nextMonthLabel" | "previousMonthLabel" | "weekStartDay" | "isOpen" | "inputLabel" | "inputLabelId" | "openCalendarLabel" | "shouldShowCalendarButton" | "hideIcon"> & {
|
|
12
12
|
disabled?: string[] | undefined;
|
|
13
13
|
defaultValue?: string | undefined;
|
|
14
14
|
onFocus?: (((_event: import("react").FocusEvent<HTMLInputElement, Element>) => void) & import("react").FocusEventHandler<HTMLInputElement>) | undefined;
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
|
-
import { jsx } from '@emotion/react';
|
|
7
6
|
import { type DateTimePickerBaseProps } from '../types';
|
|
8
7
|
interface State {
|
|
9
8
|
dateValue: string;
|
|
@@ -40,7 +39,7 @@ declare class DateTimePickerComponent extends React.Component<DateTimePickerBase
|
|
|
40
39
|
timeValue: string;
|
|
41
40
|
zoneValue: string;
|
|
42
41
|
}): void;
|
|
43
|
-
render():
|
|
42
|
+
render(): JSX.Element;
|
|
44
43
|
}
|
|
45
44
|
export { DateTimePickerComponent as DateTimePickerWithoutAnalytics };
|
|
46
45
|
/**
|
|
@@ -64,13 +63,13 @@ declare const DateTimePicker: React.ForwardRefExoticComponent<Omit<Omit<Pick<Omi
|
|
|
64
63
|
onBlur?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
65
64
|
onChange?: ((value: string) => void) | undefined;
|
|
66
65
|
value?: string | undefined;
|
|
66
|
+
name?: string | undefined;
|
|
67
|
+
spacing?: import("../types").Spacing | undefined;
|
|
67
68
|
testId?: string | undefined;
|
|
68
|
-
locale?: string | undefined;
|
|
69
69
|
clearControlLabel?: string | undefined;
|
|
70
70
|
isInvalid?: boolean | undefined;
|
|
71
71
|
isRequired?: boolean | undefined;
|
|
72
|
-
|
|
73
|
-
spacing?: import("../types").Spacing | undefined;
|
|
72
|
+
locale?: string | undefined;
|
|
74
73
|
datePickerProps?: import("../types").DatePickerBaseProps | undefined;
|
|
75
74
|
timePickerProps?: import("../types").TimePickerBaseProps | undefined;
|
|
76
75
|
parseValue?: ((dateTimeValue: string, date: string, time: string, timezone: string) => {
|
|
@@ -11,13 +11,13 @@ declare const DateTimePicker: import("react").FC<Omit<Omit<import("..").DateTime
|
|
|
11
11
|
onBlur?: import("react").FocusEventHandler<HTMLInputElement> | undefined;
|
|
12
12
|
onChange?: ((value: string) => void) | undefined;
|
|
13
13
|
value?: string | undefined;
|
|
14
|
+
name?: string | undefined;
|
|
15
|
+
spacing?: import("..").Spacing | undefined;
|
|
14
16
|
testId?: string | undefined;
|
|
15
|
-
locale?: string | undefined;
|
|
16
17
|
clearControlLabel?: string | undefined;
|
|
17
18
|
isInvalid?: boolean | undefined;
|
|
18
19
|
isRequired?: boolean | undefined;
|
|
19
|
-
|
|
20
|
-
spacing?: import("..").Spacing | undefined;
|
|
20
|
+
locale?: string | undefined;
|
|
21
21
|
datePickerProps?: import("..").DatePickerProps | undefined;
|
|
22
22
|
timePickerProps?: import("..").TimePickerProps | undefined;
|
|
23
23
|
parseValue?: ((dateTimeValue: string, date: string, time: string, timezone: string) => {
|
|
@@ -1,10 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
* @jsxRuntime classic
|
|
3
|
-
* @jsx jsx
|
|
4
|
-
*/
|
|
5
|
-
import { jsx } from '@emotion/react';
|
|
1
|
+
/// <reference types="react" />
|
|
6
2
|
import { type MenuProps, type OptionType } from '@atlaskit/select';
|
|
7
3
|
/**
|
|
8
4
|
* This is the fixed layer menu used in the time picker.
|
|
9
5
|
*/
|
|
10
|
-
export declare const FixedLayerMenu: ({ className, clearValue, cx, getStyles, getValue, hasValue, innerProps, innerRef, isLoading, isMulti, isRtl, maxMenuHeight, menuPlacement, menuPosition, menuShouldScrollIntoView, minMenuHeight, options, placement, selectOption, selectProps, setValue, children, ...rest }: MenuProps<OptionType>) =>
|
|
6
|
+
export declare const FixedLayerMenu: ({ className, clearValue, cx, getStyles, getValue, hasValue, innerProps, innerRef, isLoading, isMulti, isRtl, maxMenuHeight, menuPlacement, menuPosition, menuShouldScrollIntoView, minMenuHeight, options, placement, selectOption, selectProps, setValue, children, ...rest }: MenuProps<OptionType>) => JSX.Element;
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
4
|
+
*/
|
|
1
5
|
import React from 'react';
|
|
2
6
|
interface FixedLayerProps {
|
|
3
7
|
/**
|
|
@@ -28,6 +32,6 @@ interface FixedLayerProps {
|
|
|
28
32
|
export default class FixedLayer extends React.Component<FixedLayerProps> {
|
|
29
33
|
update: () => void;
|
|
30
34
|
componentDidUpdate(prevProps: any): void;
|
|
31
|
-
render():
|
|
35
|
+
render(): JSX.Element;
|
|
32
36
|
}
|
|
33
37
|
export {};
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
* @jsxRuntime classic
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
|
-
|
|
5
|
+
/// <reference types="react" />
|
|
6
6
|
import { type IndicatorsContainerProps } from '@atlaskit/select';
|
|
7
7
|
export declare const IndicatorsContainer: ({ showClearIndicator, ...rest }: IndicatorsContainerProps<any, boolean, import("@atlaskit/select").GroupType<any>> & {
|
|
8
8
|
showClearIndicator?: boolean | undefined;
|
|
9
|
-
}) =>
|
|
9
|
+
}) => JSX.Element;
|
|
@@ -1,6 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
4
|
+
*/
|
|
5
|
+
/// <reference types="react" />
|
|
2
6
|
import { type MenuProps } from '@atlaskit/select';
|
|
3
7
|
/**
|
|
4
8
|
* This is the menu used in the select of the date picker.
|
|
5
9
|
*/
|
|
6
|
-
export declare const Menu: ({ selectProps, innerProps }: MenuProps<any>) =>
|
|
10
|
+
export declare const Menu: ({ selectProps, innerProps }: MenuProps<any>) => JSX.Element;
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import { Component } from 'react';
|
|
6
|
-
import { jsx } from '@emotion/react';
|
|
7
6
|
import { type LocalizationProvider } from '@atlaskit/locale';
|
|
8
7
|
import { type ActionMeta, type InputActionMeta } from '@atlaskit/select';
|
|
9
8
|
import { type DatePickerBaseProps } from '../types';
|
|
@@ -76,7 +75,7 @@ declare class DatePickerComponent extends Component<DatePickerProps, State> {
|
|
|
76
75
|
onSelectChange: (_value: unknown, action: ActionMeta) => void;
|
|
77
76
|
handleSelectInputChange: (selectInputValue: string, actionMeta: InputActionMeta) => void;
|
|
78
77
|
getContainerRef: (ref: HTMLElement | null) => void;
|
|
79
|
-
render():
|
|
78
|
+
render(): JSX.Element;
|
|
80
79
|
}
|
|
81
80
|
export { DatePickerComponent as DatePickerWithoutAnalytics };
|
|
82
81
|
/**
|
|
@@ -97,7 +96,7 @@ declare const DatePicker: import("react").ForwardRefExoticComponent<Omit<Pick<Om
|
|
|
97
96
|
onBlur: (_event: React.FocusEvent<HTMLInputElement>) => void;
|
|
98
97
|
onChange: (_value: string) => void;
|
|
99
98
|
onFocus: (_event: React.FocusEvent<HTMLInputElement>) => void;
|
|
100
|
-
} & DatePickerBaseProps, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "label" | "parseInputValue" | "dateFormat" | "formatDisplayLabel" | "placeholder" | "appearance" | "isDisabled" | "innerProps" | "selectProps" | "autoFocus" | "id" | "aria-describedby" | "value" | "
|
|
99
|
+
} & DatePickerBaseProps, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "label" | "parseInputValue" | "dateFormat" | "formatDisplayLabel" | "placeholder" | "icon" | "appearance" | "isDisabled" | "innerProps" | "selectProps" | "autoFocus" | "id" | "aria-describedby" | "value" | "name" | "spacing" | "testId" | "clearControlLabel" | "isInvalid" | "isRequired" | "menuInnerWrapper" | "maxDate" | "minDate" | "nextMonthLabel" | "previousMonthLabel" | "weekStartDay" | "isOpen" | "inputLabel" | "inputLabelId" | "openCalendarLabel" | "shouldShowCalendarButton" | "hideIcon"> & {
|
|
101
100
|
disabled?: string[] | undefined;
|
|
102
101
|
defaultValue?: string | undefined;
|
|
103
102
|
onFocus?: (((_event: React.FocusEvent<HTMLInputElement>) => void) & import("react").FocusEventHandler<HTMLInputElement>) | undefined;
|
|
@@ -8,7 +8,7 @@ declare const DatePicker: import("react").FC<Omit<Omit<import("./date-picker-fc"
|
|
|
8
8
|
onBlur: (_event: import("react").FocusEvent<HTMLInputElement, Element>) => void;
|
|
9
9
|
onChange: (_value: string) => void;
|
|
10
10
|
onFocus: (_event: import("react").FocusEvent<HTMLInputElement, Element>) => void;
|
|
11
|
-
} & import("..").DatePickerProps, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "label" | "parseInputValue" | "dateFormat" | "formatDisplayLabel" | "placeholder" | "appearance" | "isDisabled" | "innerProps" | "selectProps" | "autoFocus" | "id" | "aria-describedby" | "value" | "
|
|
11
|
+
} & import("..").DatePickerProps, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "label" | "parseInputValue" | "dateFormat" | "formatDisplayLabel" | "placeholder" | "icon" | "appearance" | "isDisabled" | "innerProps" | "selectProps" | "autoFocus" | "id" | "aria-describedby" | "value" | "name" | "spacing" | "testId" | "clearControlLabel" | "isInvalid" | "isRequired" | "menuInnerWrapper" | "maxDate" | "minDate" | "nextMonthLabel" | "previousMonthLabel" | "weekStartDay" | "isOpen" | "inputLabel" | "inputLabelId" | "openCalendarLabel" | "shouldShowCalendarButton" | "hideIcon"> & {
|
|
12
12
|
disabled?: string[] | undefined;
|
|
13
13
|
defaultValue?: string | undefined;
|
|
14
14
|
onFocus?: (((_event: import("react").FocusEvent<HTMLInputElement, Element>) => void) & import("react").FocusEventHandler<HTMLInputElement>) | undefined;
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
|
-
import { jsx } from '@emotion/react';
|
|
7
6
|
import { type DateTimePickerBaseProps } from '../types';
|
|
8
7
|
interface State {
|
|
9
8
|
dateValue: string;
|
|
@@ -40,7 +39,7 @@ declare class DateTimePickerComponent extends React.Component<DateTimePickerBase
|
|
|
40
39
|
timeValue: string;
|
|
41
40
|
zoneValue: string;
|
|
42
41
|
}): void;
|
|
43
|
-
render():
|
|
42
|
+
render(): JSX.Element;
|
|
44
43
|
}
|
|
45
44
|
export { DateTimePickerComponent as DateTimePickerWithoutAnalytics };
|
|
46
45
|
/**
|
|
@@ -64,13 +63,13 @@ declare const DateTimePicker: React.ForwardRefExoticComponent<Omit<Omit<Pick<Omi
|
|
|
64
63
|
onBlur?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
65
64
|
onChange?: ((value: string) => void) | undefined;
|
|
66
65
|
value?: string | undefined;
|
|
66
|
+
name?: string | undefined;
|
|
67
|
+
spacing?: import("../types").Spacing | undefined;
|
|
67
68
|
testId?: string | undefined;
|
|
68
|
-
locale?: string | undefined;
|
|
69
69
|
clearControlLabel?: string | undefined;
|
|
70
70
|
isInvalid?: boolean | undefined;
|
|
71
71
|
isRequired?: boolean | undefined;
|
|
72
|
-
|
|
73
|
-
spacing?: import("../types").Spacing | undefined;
|
|
72
|
+
locale?: string | undefined;
|
|
74
73
|
datePickerProps?: import("../types").DatePickerBaseProps | undefined;
|
|
75
74
|
timePickerProps?: import("../types").TimePickerBaseProps | undefined;
|
|
76
75
|
parseValue?: ((dateTimeValue: string, date: string, time: string, timezone: string) => {
|
|
@@ -11,13 +11,13 @@ declare const DateTimePicker: import("react").FC<Omit<Omit<import("..").DateTime
|
|
|
11
11
|
onBlur?: import("react").FocusEventHandler<HTMLInputElement> | undefined;
|
|
12
12
|
onChange?: ((value: string) => void) | undefined;
|
|
13
13
|
value?: string | undefined;
|
|
14
|
+
name?: string | undefined;
|
|
15
|
+
spacing?: import("..").Spacing | undefined;
|
|
14
16
|
testId?: string | undefined;
|
|
15
|
-
locale?: string | undefined;
|
|
16
17
|
clearControlLabel?: string | undefined;
|
|
17
18
|
isInvalid?: boolean | undefined;
|
|
18
19
|
isRequired?: boolean | undefined;
|
|
19
|
-
|
|
20
|
-
spacing?: import("..").Spacing | undefined;
|
|
20
|
+
locale?: string | undefined;
|
|
21
21
|
datePickerProps?: import("..").DatePickerProps | undefined;
|
|
22
22
|
timePickerProps?: import("..").TimePickerProps | undefined;
|
|
23
23
|
parseValue?: ((dateTimeValue: string, date: string, time: string, timezone: string) => {
|
|
@@ -1,10 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
* @jsxRuntime classic
|
|
3
|
-
* @jsx jsx
|
|
4
|
-
*/
|
|
5
|
-
import { jsx } from '@emotion/react';
|
|
1
|
+
/// <reference types="react" />
|
|
6
2
|
import { type MenuProps, type OptionType } from '@atlaskit/select';
|
|
7
3
|
/**
|
|
8
4
|
* This is the fixed layer menu used in the time picker.
|
|
9
5
|
*/
|
|
10
|
-
export declare const FixedLayerMenu: ({ className, clearValue, cx, getStyles, getValue, hasValue, innerProps, innerRef, isLoading, isMulti, isRtl, maxMenuHeight, menuPlacement, menuPosition, menuShouldScrollIntoView, minMenuHeight, options, placement, selectOption, selectProps, setValue, children, ...rest }: MenuProps<OptionType>) =>
|
|
6
|
+
export declare const FixedLayerMenu: ({ className, clearValue, cx, getStyles, getValue, hasValue, innerProps, innerRef, isLoading, isMulti, isRtl, maxMenuHeight, menuPlacement, menuPosition, menuShouldScrollIntoView, minMenuHeight, options, placement, selectOption, selectProps, setValue, children, ...rest }: MenuProps<OptionType>) => JSX.Element;
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
4
|
+
*/
|
|
1
5
|
import React from 'react';
|
|
2
6
|
interface FixedLayerProps {
|
|
3
7
|
/**
|
|
@@ -28,6 +32,6 @@ interface FixedLayerProps {
|
|
|
28
32
|
export default class FixedLayer extends React.Component<FixedLayerProps> {
|
|
29
33
|
update: () => void;
|
|
30
34
|
componentDidUpdate(prevProps: any): void;
|
|
31
|
-
render():
|
|
35
|
+
render(): JSX.Element;
|
|
32
36
|
}
|
|
33
37
|
export {};
|