@atlaskit/checkbox 17.0.2 → 17.0.3
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 +9 -0
- package/dist/cjs/checkbox.js +21 -22
- package/dist/es2019/checkbox.js +18 -20
- package/dist/esm/checkbox.js +21 -22
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @atlaskit/checkbox
|
|
2
2
|
|
|
3
|
+
## 17.0.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#129972](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/129972)
|
|
8
|
+
[`b2d69a39e6687`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/b2d69a39e6687) -
|
|
9
|
+
Update `@compiled/react` dependency for improved type checking support.
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
3
12
|
## 17.0.2
|
|
4
13
|
|
|
5
14
|
### Patch Changes
|
package/dist/cjs/checkbox.js
CHANGED
|
@@ -32,26 +32,26 @@ var checkboxStyles = null;
|
|
|
32
32
|
* - [Code](https://atlassian.design/components/checkbox/code)
|
|
33
33
|
* - [Usage](https://atlassian.design/components/checkbox/usage)
|
|
34
34
|
*/
|
|
35
|
-
var Checkbox = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef)(function Checkbox(
|
|
36
|
-
var isCheckedProp =
|
|
37
|
-
|
|
38
|
-
isDisabled =
|
|
39
|
-
|
|
40
|
-
isInvalid =
|
|
41
|
-
|
|
42
|
-
defaultChecked =
|
|
43
|
-
|
|
44
|
-
isIndeterminate =
|
|
45
|
-
onChangeProps =
|
|
46
|
-
analyticsContext =
|
|
47
|
-
label =
|
|
48
|
-
name =
|
|
49
|
-
value =
|
|
50
|
-
isRequired =
|
|
51
|
-
testId =
|
|
52
|
-
xcss =
|
|
53
|
-
className =
|
|
54
|
-
rest = (0, _objectWithoutProperties2.default)(
|
|
35
|
+
var Checkbox = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef)(function Checkbox(_ref, ref) {
|
|
36
|
+
var isCheckedProp = _ref.isChecked,
|
|
37
|
+
_ref$isDisabled = _ref.isDisabled,
|
|
38
|
+
isDisabled = _ref$isDisabled === void 0 ? false : _ref$isDisabled,
|
|
39
|
+
_ref$isInvalid = _ref.isInvalid,
|
|
40
|
+
isInvalid = _ref$isInvalid === void 0 ? false : _ref$isInvalid,
|
|
41
|
+
_ref$defaultChecked = _ref.defaultChecked,
|
|
42
|
+
defaultChecked = _ref$defaultChecked === void 0 ? false : _ref$defaultChecked,
|
|
43
|
+
_ref$isIndeterminate = _ref.isIndeterminate,
|
|
44
|
+
isIndeterminate = _ref$isIndeterminate === void 0 ? false : _ref$isIndeterminate,
|
|
45
|
+
onChangeProps = _ref.onChange,
|
|
46
|
+
analyticsContext = _ref.analyticsContext,
|
|
47
|
+
label = _ref.label,
|
|
48
|
+
name = _ref.name,
|
|
49
|
+
value = _ref.value,
|
|
50
|
+
isRequired = _ref.isRequired,
|
|
51
|
+
testId = _ref.testId,
|
|
52
|
+
xcss = _ref.xcss,
|
|
53
|
+
className = _ref.className,
|
|
54
|
+
rest = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
55
55
|
var _useState = (0, _react.useState)(isCheckedProp !== undefined ? isCheckedProp : defaultChecked),
|
|
56
56
|
_useState2 = (0, _slicedToArray2.default)(_useState, 2),
|
|
57
57
|
isCheckedState = _useState2[0],
|
|
@@ -68,7 +68,7 @@ var Checkbox = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef
|
|
|
68
68
|
analyticsData: analyticsContext,
|
|
69
69
|
componentName: 'checkbox',
|
|
70
70
|
packageName: "@atlaskit/checkbox",
|
|
71
|
-
packageVersion: "17.0.
|
|
71
|
+
packageVersion: "17.0.3"
|
|
72
72
|
});
|
|
73
73
|
var internalRef = (0, _react.useRef)(null);
|
|
74
74
|
var mergedRefs = (0, _mergeRefs.default)([internalRef, ref]);
|
|
@@ -87,7 +87,6 @@ var Checkbox = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef
|
|
|
87
87
|
testId: testId && "".concat(testId, "--checkbox-label")
|
|
88
88
|
// Currently the rule hasn't been updated to enable "allowed" dynamic pass-throughs.
|
|
89
89
|
// When there is more usage of this pattern we'll update the lint rule.
|
|
90
|
-
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
91
90
|
,
|
|
92
91
|
xcss: xcss
|
|
93
92
|
}, /*#__PURE__*/React.createElement("input", (0, _extends2.default)({
|
package/dist/es2019/checkbox.js
CHANGED
|
@@ -19,24 +19,23 @@ const checkboxStyles = null;
|
|
|
19
19
|
* - [Code](https://atlassian.design/components/checkbox/code)
|
|
20
20
|
* - [Usage](https://atlassian.design/components/checkbox/usage)
|
|
21
21
|
*/
|
|
22
|
-
const Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
} = props;
|
|
22
|
+
const Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox({
|
|
23
|
+
isChecked: isCheckedProp,
|
|
24
|
+
isDisabled = false,
|
|
25
|
+
isInvalid = false,
|
|
26
|
+
defaultChecked = false,
|
|
27
|
+
isIndeterminate = false,
|
|
28
|
+
onChange: onChangeProps,
|
|
29
|
+
analyticsContext,
|
|
30
|
+
label,
|
|
31
|
+
name,
|
|
32
|
+
value,
|
|
33
|
+
isRequired,
|
|
34
|
+
testId,
|
|
35
|
+
xcss,
|
|
36
|
+
className,
|
|
37
|
+
...rest
|
|
38
|
+
}, ref) {
|
|
40
39
|
const [isCheckedState, setIsCheckedState] = useState(isCheckedProp !== undefined ? isCheckedProp : defaultChecked);
|
|
41
40
|
const onChange = useCallback((e, analyticsEvent) => {
|
|
42
41
|
setIsCheckedState(e.target.checked);
|
|
@@ -50,7 +49,7 @@ const Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(pr
|
|
|
50
49
|
analyticsData: analyticsContext,
|
|
51
50
|
componentName: 'checkbox',
|
|
52
51
|
packageName: "@atlaskit/checkbox",
|
|
53
|
-
packageVersion: "17.0.
|
|
52
|
+
packageVersion: "17.0.3"
|
|
54
53
|
});
|
|
55
54
|
const internalRef = useRef(null);
|
|
56
55
|
const mergedRefs = mergeRefs([internalRef, ref]);
|
|
@@ -69,7 +68,6 @@ const Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(pr
|
|
|
69
68
|
testId: testId && `${testId}--checkbox-label`
|
|
70
69
|
// Currently the rule hasn't been updated to enable "allowed" dynamic pass-throughs.
|
|
71
70
|
// When there is more usage of this pattern we'll update the lint rule.
|
|
72
|
-
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
73
71
|
,
|
|
74
72
|
xcss: xcss
|
|
75
73
|
}, /*#__PURE__*/React.createElement("input", _extends({
|
package/dist/esm/checkbox.js
CHANGED
|
@@ -22,26 +22,26 @@ var checkboxStyles = null;
|
|
|
22
22
|
* - [Code](https://atlassian.design/components/checkbox/code)
|
|
23
23
|
* - [Usage](https://atlassian.design/components/checkbox/usage)
|
|
24
24
|
*/
|
|
25
|
-
var Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(
|
|
26
|
-
var isCheckedProp =
|
|
27
|
-
|
|
28
|
-
isDisabled =
|
|
29
|
-
|
|
30
|
-
isInvalid =
|
|
31
|
-
|
|
32
|
-
defaultChecked =
|
|
33
|
-
|
|
34
|
-
isIndeterminate =
|
|
35
|
-
onChangeProps =
|
|
36
|
-
analyticsContext =
|
|
37
|
-
label =
|
|
38
|
-
name =
|
|
39
|
-
value =
|
|
40
|
-
isRequired =
|
|
41
|
-
testId =
|
|
42
|
-
xcss =
|
|
43
|
-
className =
|
|
44
|
-
rest = _objectWithoutProperties(
|
|
25
|
+
var Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(_ref, ref) {
|
|
26
|
+
var isCheckedProp = _ref.isChecked,
|
|
27
|
+
_ref$isDisabled = _ref.isDisabled,
|
|
28
|
+
isDisabled = _ref$isDisabled === void 0 ? false : _ref$isDisabled,
|
|
29
|
+
_ref$isInvalid = _ref.isInvalid,
|
|
30
|
+
isInvalid = _ref$isInvalid === void 0 ? false : _ref$isInvalid,
|
|
31
|
+
_ref$defaultChecked = _ref.defaultChecked,
|
|
32
|
+
defaultChecked = _ref$defaultChecked === void 0 ? false : _ref$defaultChecked,
|
|
33
|
+
_ref$isIndeterminate = _ref.isIndeterminate,
|
|
34
|
+
isIndeterminate = _ref$isIndeterminate === void 0 ? false : _ref$isIndeterminate,
|
|
35
|
+
onChangeProps = _ref.onChange,
|
|
36
|
+
analyticsContext = _ref.analyticsContext,
|
|
37
|
+
label = _ref.label,
|
|
38
|
+
name = _ref.name,
|
|
39
|
+
value = _ref.value,
|
|
40
|
+
isRequired = _ref.isRequired,
|
|
41
|
+
testId = _ref.testId,
|
|
42
|
+
xcss = _ref.xcss,
|
|
43
|
+
className = _ref.className,
|
|
44
|
+
rest = _objectWithoutProperties(_ref, _excluded);
|
|
45
45
|
var _useState = useState(isCheckedProp !== undefined ? isCheckedProp : defaultChecked),
|
|
46
46
|
_useState2 = _slicedToArray(_useState, 2),
|
|
47
47
|
isCheckedState = _useState2[0],
|
|
@@ -58,7 +58,7 @@ var Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(prop
|
|
|
58
58
|
analyticsData: analyticsContext,
|
|
59
59
|
componentName: 'checkbox',
|
|
60
60
|
packageName: "@atlaskit/checkbox",
|
|
61
|
-
packageVersion: "17.0.
|
|
61
|
+
packageVersion: "17.0.3"
|
|
62
62
|
});
|
|
63
63
|
var internalRef = useRef(null);
|
|
64
64
|
var mergedRefs = mergeRefs([internalRef, ref]);
|
|
@@ -77,7 +77,6 @@ var Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(prop
|
|
|
77
77
|
testId: testId && "".concat(testId, "--checkbox-label")
|
|
78
78
|
// Currently the rule hasn't been updated to enable "allowed" dynamic pass-throughs.
|
|
79
79
|
// When there is more usage of this pattern we'll update the lint rule.
|
|
80
|
-
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
81
80
|
,
|
|
82
81
|
xcss: xcss
|
|
83
82
|
}, /*#__PURE__*/React.createElement("input", _extends({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/checkbox",
|
|
3
|
-
"version": "17.0.
|
|
3
|
+
"version": "17.0.3",
|
|
4
4
|
"description": "A checkbox is an input control that allows a user to select one or more options from a number of choices.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -42,9 +42,9 @@
|
|
|
42
42
|
"@atlaskit/icon": "^25.0.0",
|
|
43
43
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
44
44
|
"@atlaskit/theme": "^18.0.0",
|
|
45
|
-
"@atlaskit/tokens": "^4.
|
|
45
|
+
"@atlaskit/tokens": "^4.5.0",
|
|
46
46
|
"@babel/runtime": "^7.0.0",
|
|
47
|
-
"@compiled/react": "^0.18.
|
|
47
|
+
"@compiled/react": "^0.18.3"
|
|
48
48
|
},
|
|
49
49
|
"peerDependencies": {
|
|
50
50
|
"react": "^18.2.0"
|
|
@@ -57,8 +57,8 @@
|
|
|
57
57
|
"@atlaskit/docs": "^10.0.0",
|
|
58
58
|
"@atlaskit/form": "^12.0.0",
|
|
59
59
|
"@atlaskit/link": "^3.0.0",
|
|
60
|
-
"@atlaskit/primitives": "^14.
|
|
61
|
-
"@atlaskit/section-message": "^8.
|
|
60
|
+
"@atlaskit/primitives": "^14.2.0",
|
|
61
|
+
"@atlaskit/section-message": "^8.2.0",
|
|
62
62
|
"@atlaskit/ssr": "^0.4.0",
|
|
63
63
|
"@atlaskit/visual-regression": "^0.10.0",
|
|
64
64
|
"@atlassian/feature-flags-test-utils": "^0.3.0",
|