@atlaskit/checkbox 15.2.4 → 15.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/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @atlaskit/checkbox
2
2
 
3
+ ## 15.2.5
4
+
5
+ ### Patch Changes
6
+
7
+ - [#105597](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/105597)
8
+ [`8713842724537`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8713842724537) -
9
+ Update dependencies and remove unused internal exports.
10
+
3
11
  ## 15.2.4
4
12
 
5
13
  ### Patch Changes
@@ -196,7 +196,7 @@ var Checkbox = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef
196
196
  analyticsData: analyticsContext,
197
197
  componentName: 'checkbox',
198
198
  packageName: "@atlaskit/checkbox",
199
- packageVersion: "15.2.4"
199
+ packageVersion: "15.2.5"
200
200
  });
201
201
  var internalRef = (0, _react.useRef)(null);
202
202
  var mergedRefs = (0, _mergeRefs.default)([internalRef, ref]);
@@ -182,7 +182,7 @@ const Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(pr
182
182
  analyticsData: analyticsContext,
183
183
  componentName: 'checkbox',
184
184
  packageName: "@atlaskit/checkbox",
185
- packageVersion: "15.2.4"
185
+ packageVersion: "15.2.5"
186
186
  });
187
187
  const internalRef = useRef(null);
188
188
  const mergedRefs = mergeRefs([internalRef, ref]);
@@ -190,7 +190,7 @@ var Checkbox = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Checkbox(prop
190
190
  analyticsData: analyticsContext,
191
191
  componentName: 'checkbox',
192
192
  packageName: "@atlaskit/checkbox",
193
- packageVersion: "15.2.4"
193
+ packageVersion: "15.2.5"
194
194
  });
195
195
  var internalRef = useRef(null);
196
196
  var mergedRefs = mergeRefs([internalRef, ref]);
@@ -1,4 +1,9 @@
1
- /// <reference types="react" />
1
+ /**
2
+ * @jsxRuntime classic
3
+ * @jsx jsx
4
+ */
5
+ import { type ChangeEvent } from 'react';
6
+ import type UIAnalyticsEvent from '@atlaskit/analytics-next/UIAnalyticsEvent';
2
7
  /**
3
8
  * __Checkbox__
4
9
  *
@@ -8,5 +13,35 @@
8
13
  * - [Code](https://atlassian.design/components/checkbox/code)
9
14
  * - [Usage](https://atlassian.design/components/checkbox/usage)
10
15
  */
11
- declare const Checkbox: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<Omit<Omit<import("react").InputHTMLAttributes<HTMLInputElement>, "css" | "disabled" | "required" | "checked">, keyof import("./types").OwnProps> & import("./types").OwnProps & import("react").RefAttributes<HTMLInputElement>>>;
16
+ declare const Checkbox: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<Omit<Omit<import("react").InputHTMLAttributes<HTMLInputElement>, "css" | "disabled" | "required" | "checked">, keyof {
17
+ defaultChecked?: boolean | undefined;
18
+ id?: string | undefined;
19
+ isChecked?: boolean | undefined;
20
+ isDisabled?: boolean | undefined;
21
+ isIndeterminate?: boolean | undefined;
22
+ isInvalid?: boolean | undefined;
23
+ isRequired?: boolean | undefined;
24
+ label?: import("react").ReactChild | undefined;
25
+ name?: string | undefined;
26
+ onChange?: ((e: ChangeEvent<HTMLInputElement>, analyticsEvent: UIAnalyticsEvent) => void) | undefined;
27
+ value?: string | number | undefined;
28
+ testId?: string | undefined;
29
+ analyticsContext?: Record<string, any> | undefined;
30
+ xcss?: import("@atlaskit/css").StrictXCSSProp<"alignItems", never>;
31
+ }> & {
32
+ defaultChecked?: boolean | undefined;
33
+ id?: string | undefined;
34
+ isChecked?: boolean | undefined;
35
+ isDisabled?: boolean | undefined;
36
+ isIndeterminate?: boolean | undefined;
37
+ isInvalid?: boolean | undefined;
38
+ isRequired?: boolean | undefined;
39
+ label?: import("react").ReactChild | undefined;
40
+ name?: string | undefined;
41
+ onChange?: ((e: ChangeEvent<HTMLInputElement>, analyticsEvent: UIAnalyticsEvent) => void) | undefined;
42
+ value?: string | number | undefined;
43
+ testId?: string | undefined;
44
+ analyticsContext?: Record<string, any> | undefined;
45
+ xcss?: import("@atlaskit/css").StrictXCSSProp<"alignItems", never>;
46
+ } & import("react").RefAttributes<HTMLInputElement>>>;
12
47
  export default Checkbox;
@@ -8,7 +8,7 @@ import { type StrictXCSSProp } from '@atlaskit/css';
8
8
  *
9
9
  *
10
10
  */
11
- export type OwnProps = {
11
+ type OwnProps = {
12
12
  /**
13
13
  * Sets whether the checkbox begins as checked or unchecked.
14
14
  */
@@ -1,4 +1,9 @@
1
- /// <reference types="react" />
1
+ /**
2
+ * @jsxRuntime classic
3
+ * @jsx jsx
4
+ */
5
+ import { type ChangeEvent } from 'react';
6
+ import type UIAnalyticsEvent from '@atlaskit/analytics-next/UIAnalyticsEvent';
2
7
  /**
3
8
  * __Checkbox__
4
9
  *
@@ -8,5 +13,35 @@
8
13
  * - [Code](https://atlassian.design/components/checkbox/code)
9
14
  * - [Usage](https://atlassian.design/components/checkbox/usage)
10
15
  */
11
- declare const Checkbox: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<Omit<Omit<import("react").InputHTMLAttributes<HTMLInputElement>, "css" | "disabled" | "required" | "checked">, keyof import("./types").OwnProps> & import("./types").OwnProps & import("react").RefAttributes<HTMLInputElement>>>;
16
+ declare const Checkbox: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<Omit<Omit<import("react").InputHTMLAttributes<HTMLInputElement>, "css" | "disabled" | "required" | "checked">, keyof {
17
+ defaultChecked?: boolean | undefined;
18
+ id?: string | undefined;
19
+ isChecked?: boolean | undefined;
20
+ isDisabled?: boolean | undefined;
21
+ isIndeterminate?: boolean | undefined;
22
+ isInvalid?: boolean | undefined;
23
+ isRequired?: boolean | undefined;
24
+ label?: import("react").ReactChild | undefined;
25
+ name?: string | undefined;
26
+ onChange?: ((e: ChangeEvent<HTMLInputElement>, analyticsEvent: UIAnalyticsEvent) => void) | undefined;
27
+ value?: string | number | undefined;
28
+ testId?: string | undefined;
29
+ analyticsContext?: Record<string, any> | undefined;
30
+ xcss?: import("@atlaskit/css").StrictXCSSProp<"alignItems", never>;
31
+ }> & {
32
+ defaultChecked?: boolean | undefined;
33
+ id?: string | undefined;
34
+ isChecked?: boolean | undefined;
35
+ isDisabled?: boolean | undefined;
36
+ isIndeterminate?: boolean | undefined;
37
+ isInvalid?: boolean | undefined;
38
+ isRequired?: boolean | undefined;
39
+ label?: import("react").ReactChild | undefined;
40
+ name?: string | undefined;
41
+ onChange?: ((e: ChangeEvent<HTMLInputElement>, analyticsEvent: UIAnalyticsEvent) => void) | undefined;
42
+ value?: string | number | undefined;
43
+ testId?: string | undefined;
44
+ analyticsContext?: Record<string, any> | undefined;
45
+ xcss?: import("@atlaskit/css").StrictXCSSProp<"alignItems", never>;
46
+ } & import("react").RefAttributes<HTMLInputElement>>>;
12
47
  export default Checkbox;
@@ -8,7 +8,7 @@ import { type StrictXCSSProp } from '@atlaskit/css';
8
8
  *
9
9
  *
10
10
  */
11
- export type OwnProps = {
11
+ type OwnProps = {
12
12
  /**
13
13
  * Sets whether the checkbox begins as checked or unchecked.
14
14
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/checkbox",
3
- "version": "15.2.4",
3
+ "version": "15.2.5",
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/"
@@ -40,9 +40,9 @@
40
40
  "@atlaskit/css": "^0.7.0",
41
41
  "@atlaskit/ds-lib": "^3.3.0",
42
42
  "@atlaskit/icon": "^23.4.0",
43
- "@atlaskit/platform-feature-flags": "^0.3.0",
43
+ "@atlaskit/platform-feature-flags": "*",
44
44
  "@atlaskit/theme": "^14.0.0",
45
- "@atlaskit/tokens": "^3.1.0",
45
+ "@atlaskit/tokens": "^3.2.0",
46
46
  "@babel/runtime": "^7.0.0",
47
47
  "@emotion/react": "^11.7.1"
48
48
  },
@@ -53,7 +53,12 @@
53
53
  "@af/accessibility-testing": "*",
54
54
  "@af/integration-testing": "*",
55
55
  "@af/visual-regression": "*",
56
+ "@atlaskit/button": "^20.3.10",
57
+ "@atlaskit/docs": "*",
58
+ "@atlaskit/form": "^11.0.2",
59
+ "@atlaskit/link": "*",
56
60
  "@atlaskit/primitives": "^13.3.0",
61
+ "@atlaskit/section-message": "*",
57
62
  "@atlaskit/ssr": "*",
58
63
  "@atlaskit/visual-regression": "*",
59
64
  "@atlassian/feature-flags-test-utils": "*",
@@ -1,70 +0,0 @@
1
- import React from 'react';
2
-
3
- import { fireEvent } from '@testing-library/react';
4
- import { type InteractionTaskArgs, type PublicInteractionTask } from 'storybook-addon-performance';
5
-
6
- import { Checkbox } from '../src';
7
-
8
- const interactionTasks: PublicInteractionTask[] = [
9
- {
10
- name: 'Select checkbox',
11
- description: 'Select checkbox',
12
- run: async ({ container, controls }: InteractionTaskArgs): Promise<void> => {
13
- const checkbox: HTMLElement | null = container.querySelector('input[name="checkbox-basic"]');
14
- if (checkbox == null) {
15
- throw new Error('Could not find checkbox element');
16
- }
17
- await controls.time(async () => {
18
- fireEvent.click(checkbox);
19
- });
20
- },
21
- },
22
- {
23
- name: 'Hover checkbox',
24
- description: 'Hover checkbox',
25
- run: async ({ container, controls }: InteractionTaskArgs): Promise<void> => {
26
- const checkbox: HTMLElement | null = container.querySelector('input[name="checkbox-basic"]');
27
- if (checkbox == null) {
28
- throw new Error('Could not find checkbox element');
29
- }
30
- await controls.time(async () => {
31
- fireEvent.mouseOver(checkbox);
32
- });
33
- },
34
- },
35
- {
36
- name: 'Focus checkbox',
37
- description: 'Focus checkbox',
38
- run: async ({ container, controls }: InteractionTaskArgs): Promise<void> => {
39
- const checkbox: HTMLElement | null = container.querySelector('input[name="checkbox-basic"]');
40
- if (checkbox == null) {
41
- throw new Error('Could not find checkbox element');
42
- }
43
- await controls.time(async () => {
44
- fireEvent.focus(checkbox);
45
- });
46
- },
47
- },
48
- ];
49
-
50
- function PerformanceComponent() {
51
- return (
52
- <Checkbox
53
- value="Basic checkbox"
54
- label="Basic checkbox"
55
- name="checkbox-basic"
56
- testId="cb-basic"
57
- />
58
- );
59
- }
60
-
61
- PerformanceComponent.story = {
62
- name: 'Performance',
63
- parameters: {
64
- performance: {
65
- interactions: interactionTasks,
66
- },
67
- },
68
- };
69
-
70
- export default PerformanceComponent;
@@ -1,13 +0,0 @@
1
- import React from 'react';
2
-
3
- import { Checkbox } from '../src';
4
-
5
- export default () => (
6
- <Checkbox
7
- value="default checkbox"
8
- label="Default checkbox"
9
- onChange={() => {}}
10
- name="checkbox-default"
11
- testId="cb-default"
12
- />
13
- );