@atlaskit/checkbox 17.0.4 → 17.1.0

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 CHANGED
@@ -1,5 +1,17 @@
1
1
  # @atlaskit/checkbox
2
2
 
3
+ ## 17.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#142856](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/142856)
8
+ [`578fbeefd6128`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/578fbeefd6128) -
9
+ Remove feature flag to allow new controls
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies
14
+
3
15
  ## 17.0.4
4
16
 
5
17
  ### Patch Changes
@@ -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.4"
71
+ packageVersion: "17.1.0"
72
72
  });
73
73
  var internalRef = (0, _react.useRef)(null);
74
74
  var mergedRefs = (0, _mergeRefs.default)([internalRef, ref]);
@@ -16,8 +16,8 @@ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return
16
16
  function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
17
17
  function getIcon(isIndeterminate, isChecked) {
18
18
  if (isIndeterminate) {
19
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
20
- if ((0, _platformFeatureFlags.fg)('platform-visual-refresh-icons') && (0, _platformFeatureFlags.fg)('platform-icon-control-migration')) {
19
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
20
+ if ((0, _platformFeatureFlags.fg)('platform-visual-refresh-icons')) {
21
21
  return /*#__PURE__*/React.createElement("path", {
22
22
  fillRule: "evenodd",
23
23
  clipRule: "evenodd",
@@ -36,8 +36,8 @@ function getIcon(isIndeterminate, isChecked) {
36
36
  }
37
37
  }
38
38
  if (isChecked) {
39
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
40
- if ((0, _platformFeatureFlags.fg)('platform-visual-refresh-icons') && (0, _platformFeatureFlags.fg)('platform-icon-control-migration')) {
39
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
40
+ if ((0, _platformFeatureFlags.fg)('platform-visual-refresh-icons')) {
41
41
  return /*#__PURE__*/React.createElement("path", {
42
42
  fillRule: "evenodd",
43
43
  clipRule: "evenodd",
@@ -77,8 +77,8 @@ var CheckboxIcon = /*#__PURE__*/(0, _react.memo)(function (_ref) {
77
77
  }, /*#__PURE__*/React.createElement("g", {
78
78
  fillRule: "evenodd"
79
79
  },
80
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
81
- (0, _platformFeatureFlags.fg)('platform-visual-refresh-icons') && (0, _platformFeatureFlags.fg)('platform-icon-control-migration') ? /*#__PURE__*/React.createElement("rect", {
80
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
81
+ (0, _platformFeatureFlags.fg)('platform-visual-refresh-icons') ? /*#__PURE__*/React.createElement("rect", {
82
82
  fill: "currentColor",
83
83
  x: "5.5",
84
84
  y: "5.5",
@@ -49,7 +49,7 @@ const Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox({
49
49
  analyticsData: analyticsContext,
50
50
  componentName: 'checkbox',
51
51
  packageName: "@atlaskit/checkbox",
52
- packageVersion: "17.0.4"
52
+ packageVersion: "17.1.0"
53
53
  });
54
54
  const internalRef = useRef(null);
55
55
  const mergedRefs = mergeRefs([internalRef, ref]);
@@ -6,8 +6,8 @@ import PrimitiveSVGIcon from '@atlaskit/icon/svg';
6
6
  import { fg } from '@atlaskit/platform-feature-flags';
7
7
  function getIcon(isIndeterminate, isChecked) {
8
8
  if (isIndeterminate) {
9
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
10
- if (fg('platform-visual-refresh-icons') && fg('platform-icon-control-migration')) {
9
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
10
+ if (fg('platform-visual-refresh-icons')) {
11
11
  return /*#__PURE__*/React.createElement("path", {
12
12
  fillRule: "evenodd",
13
13
  clipRule: "evenodd",
@@ -26,8 +26,8 @@ function getIcon(isIndeterminate, isChecked) {
26
26
  }
27
27
  }
28
28
  if (isChecked) {
29
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
30
- if (fg('platform-visual-refresh-icons') && fg('platform-icon-control-migration')) {
29
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
30
+ if (fg('platform-visual-refresh-icons')) {
31
31
  return /*#__PURE__*/React.createElement("path", {
32
32
  fillRule: "evenodd",
33
33
  clipRule: "evenodd",
@@ -66,8 +66,8 @@ const CheckboxIcon = /*#__PURE__*/memo(({
66
66
  }, /*#__PURE__*/React.createElement("g", {
67
67
  fillRule: "evenodd"
68
68
  },
69
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
70
- fg('platform-visual-refresh-icons') && fg('platform-icon-control-migration') ? /*#__PURE__*/React.createElement("rect", {
69
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
70
+ fg('platform-visual-refresh-icons') ? /*#__PURE__*/React.createElement("rect", {
71
71
  fill: "currentColor",
72
72
  x: "5.5",
73
73
  y: "5.5",
@@ -58,7 +58,7 @@ var Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(_ref
58
58
  analyticsData: analyticsContext,
59
59
  componentName: 'checkbox',
60
60
  packageName: "@atlaskit/checkbox",
61
- packageVersion: "17.0.4"
61
+ packageVersion: "17.1.0"
62
62
  });
63
63
  var internalRef = useRef(null);
64
64
  var mergedRefs = mergeRefs([internalRef, ref]);
@@ -6,8 +6,8 @@ import PrimitiveSVGIcon from '@atlaskit/icon/svg';
6
6
  import { fg } from '@atlaskit/platform-feature-flags';
7
7
  function getIcon(isIndeterminate, isChecked) {
8
8
  if (isIndeterminate) {
9
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
10
- if (fg('platform-visual-refresh-icons') && fg('platform-icon-control-migration')) {
9
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
10
+ if (fg('platform-visual-refresh-icons')) {
11
11
  return /*#__PURE__*/React.createElement("path", {
12
12
  fillRule: "evenodd",
13
13
  clipRule: "evenodd",
@@ -26,8 +26,8 @@ function getIcon(isIndeterminate, isChecked) {
26
26
  }
27
27
  }
28
28
  if (isChecked) {
29
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
30
- if (fg('platform-visual-refresh-icons') && fg('platform-icon-control-migration')) {
29
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
30
+ if (fg('platform-visual-refresh-icons')) {
31
31
  return /*#__PURE__*/React.createElement("path", {
32
32
  fillRule: "evenodd",
33
33
  clipRule: "evenodd",
@@ -67,8 +67,8 @@ var CheckboxIcon = /*#__PURE__*/memo(function (_ref) {
67
67
  }, /*#__PURE__*/React.createElement("g", {
68
68
  fillRule: "evenodd"
69
69
  },
70
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
71
- fg('platform-visual-refresh-icons') && fg('platform-icon-control-migration') ? /*#__PURE__*/React.createElement("rect", {
70
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
71
+ fg('platform-visual-refresh-icons') ? /*#__PURE__*/React.createElement("rect", {
72
72
  fill: "currentColor",
73
73
  x: "5.5",
74
74
  y: "5.5",
@@ -103,6 +103,18 @@ export interface LabelProps extends React.HTMLProps<HTMLInputElement> {
103
103
  /**
104
104
  * Bounded style overrides. Defining allowed styles through this prop will be supported for future component
105
105
  * iterations. Any styles that are not allowed by this API will result in type and land blocking violations.
106
+ *
107
+ * @example
108
+ * ```tsx
109
+ * import { cssMap } from '@atlaskit/css';
110
+ * import { Checkbox } from '@atlaskit/checkbox';
111
+ *
112
+ * const styles = cssMap({
113
+ * checkbox: { alignItems: 'center' },
114
+ * });
115
+ *
116
+ * <Checkbox xcss={styles.checkbox} />
117
+ * ```
106
118
  */
107
119
  xcss?: StrictXCSSProp<'alignItems', never>;
108
120
  }
@@ -103,6 +103,18 @@ export interface LabelProps extends React.HTMLProps<HTMLInputElement> {
103
103
  /**
104
104
  * Bounded style overrides. Defining allowed styles through this prop will be supported for future component
105
105
  * iterations. Any styles that are not allowed by this API will result in type and land blocking violations.
106
+ *
107
+ * @example
108
+ * ```tsx
109
+ * import { cssMap } from '@atlaskit/css';
110
+ * import { Checkbox } from '@atlaskit/checkbox';
111
+ *
112
+ * const styles = cssMap({
113
+ * checkbox: { alignItems: 'center' },
114
+ * });
115
+ *
116
+ * <Checkbox xcss={styles.checkbox} />
117
+ * ```
106
118
  */
107
119
  xcss?: StrictXCSSProp<'alignItems', never>;
108
120
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/checkbox",
3
- "version": "17.0.4",
3
+ "version": "17.1.0",
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/"
@@ -39,10 +39,10 @@
39
39
  "@atlaskit/analytics-next": "^11.0.0",
40
40
  "@atlaskit/css": "^0.10.0",
41
41
  "@atlaskit/ds-lib": "^4.0.0",
42
- "@atlaskit/icon": "^25.0.0",
42
+ "@atlaskit/icon": "^25.6.0",
43
43
  "@atlaskit/platform-feature-flags": "^1.1.0",
44
44
  "@atlaskit/theme": "^18.0.0",
45
- "@atlaskit/tokens": "^4.5.0",
45
+ "@atlaskit/tokens": "^4.8.0",
46
46
  "@babel/runtime": "^7.0.0",
47
47
  "@compiled/react": "^0.18.3"
48
48
  },
@@ -53,17 +53,18 @@
53
53
  "@af/accessibility-testing": "^2.0.0",
54
54
  "@af/integration-testing": "^0.5.0",
55
55
  "@af/visual-regression": "^1.3.0",
56
- "@atlaskit/button": "^21.1.0",
56
+ "@atlaskit/button": "^23.0.0",
57
57
  "@atlaskit/docs": "^10.0.0",
58
58
  "@atlaskit/form": "^12.0.0",
59
- "@atlaskit/link": "^3.0.0",
60
- "@atlaskit/primitives": "^14.2.0",
59
+ "@atlaskit/link": "^3.1.0",
60
+ "@atlaskit/primitives": "^14.4.0",
61
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",
65
+ "@atlassian/ssr-tests": "^0.2.0",
65
66
  "@testing-library/react": "^13.4.0",
66
- "jscodeshift": "^0.16.1",
67
+ "jscodeshift": "^17.0.0",
67
68
  "react-dom": "^18.2.0",
68
69
  "storybook-addon-performance": "^0.17.3",
69
70
  "typescript": "~5.4.2"
@@ -97,9 +98,6 @@
97
98
  "platform-feature-flags": {
98
99
  "platform-visual-refresh-icons": {
99
100
  "type": "boolean"
100
- },
101
- "platform-icon-control-migration": {
102
- "type": "boolean"
103
101
  }
104
102
  }
105
103
  }