@atlaskit/button 16.3.3 → 16.3.4

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,11 @@
1
1
  # @atlaskit/button
2
2
 
3
+ ## 16.3.4
4
+
5
+ ### Patch Changes
6
+
7
+ - [`65a90f6ba14`](https://bitbucket.org/atlassian/atlassian-frontend/commits/65a90f6ba14) - Use medium icons for button examples
8
+
3
9
  ## 16.3.3
4
10
 
5
11
  ### Patch Changes
@@ -101,7 +101,7 @@ var _default = /*#__PURE__*/_react.default.forwardRef(function ButtonBase(props,
101
101
  action: 'clicked',
102
102
  componentName: 'button',
103
103
  packageName: "@atlaskit/button",
104
- packageVersion: "16.3.3",
104
+ packageVersion: "16.3.4",
105
105
  analyticsData: analyticsContext
106
106
  }); // Button currently calls preventDefault, which is not standard button behaviour
107
107
 
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/button",
3
- "version": "16.3.3",
3
+ "version": "16.3.4",
4
4
  "sideEffects": false
5
5
  }
@@ -70,7 +70,7 @@ export default /*#__PURE__*/React.forwardRef(function ButtonBase(props, ref) {
70
70
  action: 'clicked',
71
71
  componentName: 'button',
72
72
  packageName: "@atlaskit/button",
73
- packageVersion: "16.3.3",
73
+ packageVersion: "16.3.4",
74
74
  analyticsData: analyticsContext
75
75
  }); // Button currently calls preventDefault, which is not standard button behaviour
76
76
 
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/button",
3
- "version": "16.3.3",
3
+ "version": "16.3.4",
4
4
  "sideEffects": false
5
5
  }
@@ -79,7 +79,7 @@ export default /*#__PURE__*/React.forwardRef(function ButtonBase(props, ref) {
79
79
  action: 'clicked',
80
80
  componentName: 'button',
81
81
  packageName: "@atlaskit/button",
82
- packageVersion: "16.3.3",
82
+ packageVersion: "16.3.4",
83
83
  analyticsData: analyticsContext
84
84
  }); // Button currently calls preventDefault, which is not standard button behaviour
85
85
 
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/button",
3
- "version": "16.3.3",
3
+ "version": "16.3.4",
4
4
  "sideEffects": false
5
5
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/button",
3
- "version": "16.3.3",
3
+ "version": "16.3.4",
4
4
  "description": "A button triggers an event or action. They let users know what will happen next.",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
package/report.api.md ADDED
@@ -0,0 +1,164 @@
1
+ ## API Report File for "@atlaskit/button"
2
+
3
+ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
4
+
5
+ ```ts
6
+ /// <reference types="react" />
7
+
8
+ import { ComponentType } from 'react';
9
+ import { CSSObject } from '@emotion/core';
10
+ import { default as React_2 } from 'react';
11
+ import { ReactNode } from 'react';
12
+ import { ThemeModes } from '@atlaskit/theme/types';
13
+ import { ThemeModes as ThemeModes_2 } from '@atlaskit/theme';
14
+ import { ThemeProp } from '@atlaskit/theme/components';
15
+ import { UIAnalyticsEvent } from '@atlaskit/analytics-next';
16
+
17
+ // @public (undocumented)
18
+ export type Appearance =
19
+ | 'default'
20
+ | 'danger'
21
+ | 'link'
22
+ | 'primary'
23
+ | 'subtle'
24
+ | 'subtle-link'
25
+ | 'warning';
26
+
27
+ // @public (undocumented)
28
+ export type BaseOwnProps = {
29
+ appearance?: Appearance;
30
+ autoFocus?: boolean;
31
+ className?: string;
32
+ overlay?: React_2.ReactNode;
33
+ href?: string;
34
+ iconAfter?: React_2.ReactChild;
35
+ iconBefore?: React_2.ReactChild;
36
+ isDisabled?: boolean;
37
+ isSelected?: boolean;
38
+ onBlur?: React_2.FocusEventHandler<HTMLElement>;
39
+ onClick?: (
40
+ e: React_2.MouseEvent<HTMLElement>,
41
+ analyticsEvent: UIAnalyticsEvent,
42
+ ) => void;
43
+ onFocus?: React_2.FocusEventHandler<HTMLElement>;
44
+ spacing?: Spacing;
45
+ target?: React_2.AnchorHTMLAttributes<HTMLAnchorElement>['target'];
46
+ type?: React_2.ButtonHTMLAttributes<HTMLButtonElement>['type'];
47
+ shouldFitContainer?: boolean;
48
+ children?: React_2.ReactNode;
49
+ testId?: string;
50
+ component?:
51
+ | React_2.ComponentType<React_2.AllHTMLAttributes<HTMLElement>>
52
+ | React_2.ElementType;
53
+ analyticsContext?: Record<string, any>;
54
+ };
55
+
56
+ // @public (undocumented)
57
+ export type BaseProps = Combine<
58
+ Combine<
59
+ Omit<React_2.AllHTMLAttributes<HTMLElement>, 'disabled'>,
60
+ {
61
+ 'data-testid'?: never;
62
+ 'data-has-overlay'?: never;
63
+ }
64
+ >,
65
+ BaseOwnProps
66
+ >;
67
+
68
+ // @public (undocumented)
69
+ const Button: React_2.MemoExoticComponent<React_2.ForwardRefExoticComponent<
70
+ ButtonProps & React_2.RefAttributes<HTMLElement>
71
+ >>;
72
+ export default Button;
73
+
74
+ // @public (undocumented)
75
+ export function ButtonGroup({
76
+ appearance,
77
+ children,
78
+ }: ButtonGroupProps): JSX.Element;
79
+
80
+ // @public (undocumented)
81
+ export interface ButtonProps extends BaseProps {}
82
+
83
+ // @public (undocumented)
84
+ export const CustomThemeButton: React_2.MemoExoticComponent<React_2.ForwardRefExoticComponent<
85
+ Omit<BaseProps, 'overlay'> &
86
+ CustomThemeButtonOwnProps &
87
+ React_2.RefAttributes<HTMLElement>
88
+ >>;
89
+
90
+ // @public (undocumented)
91
+ export type CustomThemeButtonOwnProps = {
92
+ isLoading?: boolean;
93
+ theme?: (
94
+ current: (props: ThemeProps) => ThemeTokens,
95
+ props: ThemeProps,
96
+ ) => ThemeTokens;
97
+ };
98
+
99
+ // @public (undocumented)
100
+ export type CustomThemeButtonProps = Omit<BaseProps, 'overlay'> &
101
+ CustomThemeButtonOwnProps;
102
+
103
+ // @public (undocumented)
104
+ export type InteractionState =
105
+ | 'disabled'
106
+ | 'focusSelected'
107
+ | 'selected'
108
+ | 'active'
109
+ | 'hover'
110
+ | 'focus'
111
+ | 'default';
112
+
113
+ // @public (undocumented)
114
+ export const LoadingButton: React_2.ForwardRefExoticComponent<
115
+ Omit<BaseProps, 'overlay'> &
116
+ LoadingButtonOwnProps &
117
+ React_2.RefAttributes<HTMLElement>
118
+ >;
119
+
120
+ // @public (undocumented)
121
+ export type LoadingButtonOwnProps = {
122
+ isLoading?: boolean;
123
+ };
124
+
125
+ // @public (undocumented)
126
+ export type LoadingButtonProps = Omit<BaseProps, 'overlay'> &
127
+ LoadingButtonOwnProps;
128
+
129
+ // @public (undocumented)
130
+ export type Spacing = 'compact' | 'default' | 'none';
131
+
132
+ // @public (undocumented)
133
+ export const Theme: {
134
+ Consumer: ComponentType<
135
+ {
136
+ children: (tokens: ThemeTokens) => ReactNode;
137
+ } & Partial<CustomThemeButtonProps> & {
138
+ state: InteractionState;
139
+ iconIsOnlyChild?: boolean | undefined;
140
+ mode?: ThemeModes_2 | undefined;
141
+ }
142
+ >;
143
+ Provider: ComponentType<{
144
+ children?: ReactNode;
145
+ value?: ThemeProp<ThemeTokens, ThemeProps> | undefined;
146
+ }>;
147
+ useTheme: (props: ThemeProps) => ThemeTokens;
148
+ };
149
+
150
+ // @public (undocumented)
151
+ export type ThemeProps = Partial<CustomThemeButtonProps> & {
152
+ state: InteractionState;
153
+ iconIsOnlyChild?: boolean;
154
+ mode?: ThemeModes;
155
+ };
156
+
157
+ // @public (undocumented)
158
+ export type ThemeTokens = {
159
+ buttonStyles: CSSObject;
160
+ spinnerStyles: CSSObject;
161
+ };
162
+
163
+ // (No @packageDocumentation comment for this package)
164
+ ```