@atlaskit/color-picker 3.0.2 → 3.0.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,19 @@
1
1
  # @atlaskit/color-picker
2
2
 
3
+ ## 3.0.4
4
+
5
+ ### Patch Changes
6
+
7
+ - [`cb8f8e76d25`](https://bitbucket.org/atlassian/atlassian-frontend/commits/cb8f8e76d25) - Update types for react-select and @atlaskit/select upgrade
8
+ Update commerce-ui entrypoints that caused a pipeline issue.
9
+ - Updated dependencies
10
+
11
+ ## 3.0.3
12
+
13
+ ### Patch Changes
14
+
15
+ - Updated dependencies
16
+
3
17
  ## 3.0.2
4
18
 
5
19
  ### Patch Changes
@@ -166,8 +166,7 @@ describe('Convert positionFixed:boolean to strategy:"fixed"|"absolute"', () => {
166
166
 
167
167
  describe('Warn use of the `modifiers` prop', () => {
168
168
  check({
169
- it:
170
- 'should add warning comment when using the modifier prop in `popperProps`',
169
+ it: 'should add warning comment when using the modifier prop in `popperProps`',
171
170
  original: `
172
171
  import ColorPicker from '@atlaskit/color-picker';
173
172
 
@@ -60,7 +60,7 @@ var defaultPopperProps = {
60
60
  placement: 'bottom-start'
61
61
  };
62
62
  var packageName = "@atlaskit/color-picker";
63
- var packageVersion = "3.0.2";
63
+ var packageVersion = "3.0.4";
64
64
 
65
65
  var ColorPickerWithoutAnalytics = /*#__PURE__*/function (_React$Component) {
66
66
  (0, _inherits2.default)(ColorPickerWithoutAnalytics, _React$Component);
@@ -46,19 +46,24 @@ var Option = function Option(props) {
46
46
  onOptionKeyDown = _props$selectProps.onOptionKeyDown,
47
47
  isTabbing = _props$selectProps.isTabbing,
48
48
  isFocused = props.isFocused,
49
- isSelected = props.isSelected;
50
- return /*#__PURE__*/_react.default.createElement(_ColorPalette.ColorCardWrapper, props.innerProps, /*#__PURE__*/_react.default.createElement(_ColorCard.default, {
51
- label: label,
52
- value: value,
53
- checkMarkColor: checkMarkColor,
54
- isOption: true,
55
- focused: isFocused,
56
- selected: isSelected,
57
- onKeyDown: function onKeyDown(value) {
58
- return onOptionKeyDown(value);
59
- },
60
- isTabbing: isTabbing
61
- }));
49
+ isSelected = props.isSelected,
50
+ innerProps = props.innerProps;
51
+ return (
52
+ /*#__PURE__*/
53
+ // @ts-expect-error - known issue: https://github.com/mui/material-ui/issues/13921. TS treats styled components to be different from HTMLDivElement
54
+ _react.default.createElement(_ColorPalette.ColorCardWrapper, innerProps, /*#__PURE__*/_react.default.createElement(_ColorCard.default, {
55
+ label: label,
56
+ value: value,
57
+ checkMarkColor: checkMarkColor,
58
+ isOption: true,
59
+ focused: isFocused,
60
+ selected: isSelected,
61
+ onKeyDown: function onKeyDown(value) {
62
+ return onOptionKeyDown(value);
63
+ },
64
+ isTabbing: isTabbing
65
+ }))
66
+ );
62
67
  };
63
68
 
64
69
  exports.Option = Option;
@@ -1,4 +1,4 @@
1
1
  {
2
2
  "name": "@atlaskit/color-picker",
3
- "version": "3.0.2"
3
+ "version": "3.0.4"
4
4
  }
@@ -19,7 +19,7 @@ const defaultPopperProps = {
19
19
  placement: 'bottom-start'
20
20
  };
21
21
  const packageName = "@atlaskit/color-picker";
22
- const packageVersion = "3.0.2";
22
+ const packageVersion = "3.0.4";
23
23
  export class ColorPickerWithoutAnalytics extends React.Component {
24
24
  constructor(...args) {
25
25
  super(...args);
@@ -32,18 +32,23 @@ export const Option = props => {
32
32
  isTabbing
33
33
  },
34
34
  isFocused,
35
- isSelected
35
+ isSelected,
36
+ innerProps
36
37
  } = props;
37
- return /*#__PURE__*/React.createElement(ColorCardWrapper, props.innerProps, /*#__PURE__*/React.createElement(ColorCard, {
38
- label: label,
39
- value: value,
40
- checkMarkColor: checkMarkColor,
41
- isOption: true,
42
- focused: isFocused,
43
- selected: isSelected,
44
- onKeyDown: value => onOptionKeyDown(value),
45
- isTabbing: isTabbing
46
- }));
38
+ return (
39
+ /*#__PURE__*/
40
+ // @ts-expect-error - known issue: https://github.com/mui/material-ui/issues/13921. TS treats styled components to be different from HTMLDivElement
41
+ React.createElement(ColorCardWrapper, innerProps, /*#__PURE__*/React.createElement(ColorCard, {
42
+ label: label,
43
+ value: value,
44
+ checkMarkColor: checkMarkColor,
45
+ isOption: true,
46
+ focused: isFocused,
47
+ selected: isSelected,
48
+ onKeyDown: value => onOptionKeyDown(value),
49
+ isTabbing: isTabbing
50
+ }))
51
+ );
47
52
  };
48
53
  export const DropdownIndicator = () => null;
49
54
  export const Placeholder = () => null;
@@ -1,4 +1,4 @@
1
1
  {
2
2
  "name": "@atlaskit/color-picker",
3
- "version": "3.0.2"
3
+ "version": "3.0.4"
4
4
  }
@@ -30,7 +30,7 @@ var defaultPopperProps = {
30
30
  placement: 'bottom-start'
31
31
  };
32
32
  var packageName = "@atlaskit/color-picker";
33
- var packageVersion = "3.0.2";
33
+ var packageVersion = "3.0.4";
34
34
  export var ColorPickerWithoutAnalytics = /*#__PURE__*/function (_React$Component) {
35
35
  _inherits(ColorPickerWithoutAnalytics, _React$Component);
36
36
 
@@ -28,19 +28,24 @@ export var Option = function Option(props) {
28
28
  onOptionKeyDown = _props$selectProps.onOptionKeyDown,
29
29
  isTabbing = _props$selectProps.isTabbing,
30
30
  isFocused = props.isFocused,
31
- isSelected = props.isSelected;
32
- return /*#__PURE__*/React.createElement(ColorCardWrapper, props.innerProps, /*#__PURE__*/React.createElement(ColorCard, {
33
- label: label,
34
- value: value,
35
- checkMarkColor: checkMarkColor,
36
- isOption: true,
37
- focused: isFocused,
38
- selected: isSelected,
39
- onKeyDown: function onKeyDown(value) {
40
- return onOptionKeyDown(value);
41
- },
42
- isTabbing: isTabbing
43
- }));
31
+ isSelected = props.isSelected,
32
+ innerProps = props.innerProps;
33
+ return (
34
+ /*#__PURE__*/
35
+ // @ts-expect-error - known issue: https://github.com/mui/material-ui/issues/13921. TS treats styled components to be different from HTMLDivElement
36
+ React.createElement(ColorCardWrapper, innerProps, /*#__PURE__*/React.createElement(ColorCard, {
37
+ label: label,
38
+ value: value,
39
+ checkMarkColor: checkMarkColor,
40
+ isOption: true,
41
+ focused: isFocused,
42
+ selected: isSelected,
43
+ onKeyDown: function onKeyDown(value) {
44
+ return onOptionKeyDown(value);
45
+ },
46
+ isTabbing: isTabbing
47
+ }))
48
+ );
44
49
  };
45
50
  export var DropdownIndicator = function DropdownIndicator() {
46
51
  return null;
@@ -1,4 +1,4 @@
1
1
  {
2
2
  "name": "@atlaskit/color-picker",
3
- "version": "3.0.2"
3
+ "version": "3.0.4"
4
4
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/color-picker",
3
- "version": "3.0.2",
3
+ "version": "3.0.4",
4
4
  "description": "Jira Color Picker Component",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -12,13 +12,6 @@
12
12
  "module": "dist/esm/index.js",
13
13
  "module:es2019": "dist/es2019/index.js",
14
14
  "types": "dist/types/index.d.ts",
15
- "typesVersions": {
16
- ">=4.0 <4.5": {
17
- "*": [
18
- "dist/types-ts4.0/*"
19
- ]
20
- }
21
- },
22
15
  "atlaskit:src": "src/index.ts",
23
16
  "atlassian": {
24
17
  "team": "Jira Software: Roadmaps",
@@ -29,10 +22,10 @@
29
22
  },
30
23
  "dependencies": {
31
24
  "@atlaskit/analytics-next": "^8.2.0",
32
- "@atlaskit/icon": "^21.10.0",
33
- "@atlaskit/select": "^15.7.0",
25
+ "@atlaskit/icon": "^21.11.0",
26
+ "@atlaskit/select": "^16.0.0",
34
27
  "@atlaskit/theme": "^12.2.0",
35
- "@atlaskit/tokens": "^0.10.0",
28
+ "@atlaskit/tokens": "^0.11.0",
36
29
  "@babel/runtime": "^7.0.0",
37
30
  "memoize-one": "^6.0.0",
38
31
  "styled-components": "^3.2.6"
package/report.api.md CHANGED
@@ -1,12 +1,18 @@
1
+ <!-- API Report Version: 2.3 -->
2
+
1
3
  ## API Report File for "@atlaskit/color-picker"
2
4
 
3
- > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
5
+ > Do not edit this file. This report is auto-generated using [API Extractor](https://api-extractor.com/).
6
+ > [Learn more about API reports](https://hello.atlassian.net/wiki/spaces/UR/pages/1825484529/Package+API+Reports)
7
+
8
+ ### Table of contents
4
9
 
5
- <!--
6
- Generated API Report version: 2.0
7
- -->
10
+ - [Main Entry Types](#main-entry-types)
11
+ - [Peer Dependencies](#peer-dependencies)
8
12
 
9
- [Learn more about API reports](https://hello.atlassian.net/wiki/spaces/UR/pages/1825484529/Package+API+Reports)
13
+ ### Main Entry Types
14
+
15
+ <!--SECTION START: Main Entry Types-->
10
16
 
11
17
  ```ts
12
18
  import { AnalyticsEventPayload } from '@atlaskit/analytics-next';
@@ -31,7 +37,7 @@ export const ColorPaletteMenu: React_2.ForwardRefExoticComponent<
31
37
  Pick<
32
38
  Pick<
33
39
  Omit<ColorPaletteMenuProps, keyof WithAnalyticsEventsProps>,
34
- 'label' | 'onChange' | 'checkMarkColor' | 'palette' | 'selectedColor'
40
+ 'checkMarkColor' | 'label' | 'onChange' | 'palette' | 'selectedColor'
35
41
  > &
36
42
  Partial<
37
43
  Pick<
@@ -50,15 +56,15 @@ export const ColorPaletteMenu: React_2.ForwardRefExoticComponent<
50
56
  > &
51
57
  React_2.RefAttributes<any> &
52
58
  WithContextProps,
53
- | 'label'
54
- | 'key'
55
- | 'onChange'
59
+ | 'analyticsContext'
56
60
  | 'checkMarkColor'
57
61
  | 'cols'
62
+ | 'key'
63
+ | 'label'
58
64
  | 'mode'
65
+ | 'onChange'
59
66
  | 'palette'
60
67
  | 'selectedColor'
61
- | 'analyticsContext'
62
68
  > &
63
69
  React_2.RefAttributes<any>
64
70
  >;
@@ -76,9 +82,7 @@ export interface ColorPaletteMenuProps {
76
82
  }
77
83
 
78
84
  // @public (undocumented)
79
- export class ColorPaletteMenuWithoutAnalytics extends React_2.Component<
80
- ColorPaletteMenuProps
81
- > {
85
+ export class ColorPaletteMenuWithoutAnalytics extends React_2.Component<ColorPaletteMenuProps> {
82
86
  // (undocumented)
83
87
  changeAnalyticsCaller: () => UIAnalyticsEvent | undefined;
84
88
  // (undocumented)
@@ -109,9 +113,7 @@ export interface ColorPickerProps {
109
113
  }
110
114
 
111
115
  // @public (undocumented)
112
- export class ColorPickerWithoutAnalytics extends React_2.Component<
113
- ColorPickerProps
114
- > {
116
+ export class ColorPickerWithoutAnalytics extends React_2.Component<ColorPickerProps> {
115
117
  // (undocumented)
116
118
  changeAnalyticsCaller: () => UIAnalyticsEvent | undefined;
117
119
  // (undocumented)
@@ -141,15 +143,15 @@ const _default: React_2.ForwardRefExoticComponent<
141
143
  Omit<ColorPickerProps, keyof WithAnalyticsEventsProps> &
142
144
  React_2.RefAttributes<any> &
143
145
  WithContextProps,
144
- | 'label'
145
- | 'key'
146
- | 'onChange'
146
+ | 'analyticsContext'
147
147
  | 'checkMarkColor'
148
148
  | 'cols'
149
- | 'popperProps'
149
+ | 'key'
150
+ | 'label'
151
+ | 'onChange'
150
152
  | 'palette'
153
+ | 'popperProps'
151
154
  | 'selectedColor'
152
- | 'analyticsContext'
153
155
  > &
154
156
  React_2.RefAttributes<any>
155
157
  >;
@@ -171,3 +173,17 @@ export const Standard: Mode;
171
173
 
172
174
  // (No @packageDocumentation comment for this package)
173
175
  ```
176
+
177
+ <!--SECTION END: Main Entry Types-->
178
+
179
+ ### Peer Dependencies
180
+
181
+ <!--SECTION START: Peer Dependencies-->
182
+
183
+ ```json
184
+ {
185
+ "react": "^16.8.0"
186
+ }
187
+ ```
188
+
189
+ <!--SECTION END: Peer Dependencies-->
@@ -0,0 +1,114 @@
1
+ ## API Report File for "@atlaskit/color-picker"
2
+
3
+ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
4
+
5
+ ```ts
6
+
7
+ import { AnalyticsEventPayload } from '@atlaskit/analytics-next';
8
+ import { CreateUIAnalyticsEvent } from '@atlaskit/analytics-next';
9
+ import { PopupSelectProps } from '@atlaskit/select';
10
+ import { default as React_2 } from 'react';
11
+ import { UIAnalyticsEvent } from '@atlaskit/analytics-next';
12
+ import { ValueType } from '@atlaskit/select';
13
+ import { WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
14
+ import { WithContextProps } from '@atlaskit/analytics-next';
15
+
16
+ // @public (undocumented)
17
+ interface Color {
18
+ // (undocumented)
19
+ label: string;
20
+ // (undocumented)
21
+ value: string;
22
+ }
23
+
24
+ // @public (undocumented)
25
+ export const ColorPaletteMenu: React_2.ForwardRefExoticComponent<Pick<Pick<Omit<ColorPaletteMenuProps, keyof WithAnalyticsEventsProps>, "checkMarkColor" | "label" | "onChange" | "palette" | "selectedColor"> & Partial<Pick<Omit<ColorPaletteMenuProps, keyof WithAnalyticsEventsProps>, "cols" | "mode">> & Partial<Pick<{
26
+ cols: number;
27
+ mode: Mode;
28
+ }, never>> & React_2.RefAttributes<any> & WithContextProps, "analyticsContext" | "checkMarkColor" | "cols" | "key" | "label" | "mode" | "onChange" | "palette" | "selectedColor"> & React_2.RefAttributes<any>>;
29
+
30
+ // @public (undocumented)
31
+ export interface ColorPaletteMenuProps {
32
+ checkMarkColor?: string;
33
+ cols: number;
34
+ createAnalyticsEvent?: any;
35
+ label?: string;
36
+ mode?: Mode;
37
+ onChange: (value: string, analyticsEvent?: object) => void;
38
+ palette: Palette;
39
+ selectedColor?: string;
40
+ }
41
+
42
+ // @public (undocumented)
43
+ export class ColorPaletteMenuWithoutAnalytics extends React_2.Component<ColorPaletteMenuProps> {
44
+ // (undocumented)
45
+ changeAnalyticsCaller: () => UIAnalyticsEvent | undefined;
46
+ // (undocumented)
47
+ createAndFireEventOnAtlaskit: (payload: AnalyticsEventPayload) => (createAnalyticsEvent: CreateUIAnalyticsEvent) => UIAnalyticsEvent;
48
+ // (undocumented)
49
+ static defaultProps: {
50
+ cols: number;
51
+ mode: Mode;
52
+ };
53
+ // (undocumented)
54
+ onChange: (value: string) => void;
55
+ // (undocumented)
56
+ render(): JSX.Element;
57
+ }
58
+
59
+ // @public (undocumented)
60
+ export interface ColorPickerProps {
61
+ checkMarkColor?: string;
62
+ cols?: number;
63
+ createAnalyticsEvent?: any;
64
+ label?: string;
65
+ onChange: (value: string, analyticsEvent?: object) => void;
66
+ palette: Palette;
67
+ popperProps?: PopupSelectProps['popperProps'];
68
+ selectedColor?: string;
69
+ }
70
+
71
+ // @public (undocumented)
72
+ export class ColorPickerWithoutAnalytics extends React_2.Component<ColorPickerProps> {
73
+ // (undocumented)
74
+ changeAnalyticsCaller: () => UIAnalyticsEvent | undefined;
75
+ // (undocumented)
76
+ createAndFireEventOnAtlaskit: (payload: AnalyticsEventPayload) => (createAnalyticsEvent: CreateUIAnalyticsEvent) => UIAnalyticsEvent;
77
+ // (undocumented)
78
+ onChangeSelect: (option: ValueType<Color>) => void;
79
+ // (undocumented)
80
+ onKeyDown: (e: React_2.KeyboardEvent<HTMLElement>) => void;
81
+ // (undocumented)
82
+ onOptionKeyDown: (value: string) => void;
83
+ // (undocumented)
84
+ render(): JSX.Element;
85
+ // (undocumented)
86
+ state: {
87
+ isTabbing: boolean;
88
+ };
89
+ }
90
+
91
+ // @public (undocumented)
92
+ export const Compact: Mode;
93
+
94
+ // @public (undocumented)
95
+ const _default: React_2.ForwardRefExoticComponent<Pick<Omit<ColorPickerProps, keyof WithAnalyticsEventsProps> & React_2.RefAttributes<any> & WithContextProps, "analyticsContext" | "checkMarkColor" | "cols" | "key" | "label" | "onChange" | "palette" | "popperProps" | "selectedColor"> & React_2.RefAttributes<any>>;
96
+ export default _default;
97
+
98
+ // @public (undocumented)
99
+ enum Mode {
100
+ // (undocumented)
101
+ Compact = 0,
102
+ // (undocumented)
103
+ Standard = 1
104
+ }
105
+
106
+ // @public (undocumented)
107
+ type Palette = Color[];
108
+
109
+ // @public (undocumented)
110
+ export const Standard: Mode;
111
+
112
+ // (No @packageDocumentation comment for this package)
113
+
114
+ ```
@@ -1,20 +0,0 @@
1
- import React from 'react';
2
- import { PureComponent } from 'react';
3
- export interface Props {
4
- value: string;
5
- label: string;
6
- onClick?: (value: string) => void;
7
- onKeyDown?: (value: string) => void;
8
- checkMarkColor?: string;
9
- selected?: boolean;
10
- focused?: boolean;
11
- isOption?: boolean;
12
- isTabbing?: boolean;
13
- }
14
- export default class ColorCard extends PureComponent<Props> {
15
- onMouseDown: (event: React.MouseEvent<HTMLDivElement>) => void;
16
- onClick: (event: React.MouseEvent<HTMLDivElement>) => void;
17
- onKeyDown: (event: React.KeyboardEvent<HTMLElement>) => void;
18
- ref: React.RefObject<HTMLButtonElement>;
19
- render(): JSX.Element;
20
- }
@@ -1,35 +0,0 @@
1
- import React from 'react';
2
- import { Palette, Mode } from '../types';
3
- export interface Props {
4
- /** color picker button label */
5
- label?: string;
6
- /** list of available colors */
7
- palette: Palette;
8
- /** selected color */
9
- selectedColor?: string;
10
- /** maximum column length */
11
- cols: number;
12
- /** color of checkmark on selected color */
13
- checkMarkColor?: string;
14
- /** onChange handler */
15
- onChange: (value: string, analyticsEvent?: object) => void;
16
- /** You should not be accessing this prop under any circumstances. It is provided by @atlaskit/analytics-next. */
17
- createAnalyticsEvent?: any;
18
- /** style of the color-picker, either 'Compact' or 'Standard', default value is 'Standard' */
19
- mode?: Mode;
20
- }
21
- export declare class ColorPaletteMenuWithoutAnalytics extends React.Component<Props> {
22
- static defaultProps: {
23
- cols: number;
24
- mode: Mode;
25
- };
26
- createAndFireEventOnAtlaskit: (payload: import("@atlaskit/analytics-next").AnalyticsEventPayload) => (createAnalyticsEvent: import("@atlaskit/analytics-next").CreateUIAnalyticsEvent) => import("@atlaskit/analytics-next").UIAnalyticsEvent;
27
- changeAnalyticsCaller: () => import("@atlaskit/analytics-next").UIAnalyticsEvent | undefined;
28
- onChange: (value: string) => void;
29
- render(): JSX.Element;
30
- }
31
- declare const _default: React.ForwardRefExoticComponent<Pick<Pick<Omit<Props, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "label" | "onChange" | "checkMarkColor" | "palette" | "selectedColor"> & Partial<Pick<Omit<Props, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "cols" | "mode">> & Partial<Pick<{
32
- cols: number;
33
- mode: Mode;
34
- }, never>> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "label" | "key" | "onChange" | "checkMarkColor" | "cols" | "mode" | "palette" | "selectedColor" | "analyticsContext"> & React.RefAttributes<any>>;
35
- export default _default;
@@ -1,34 +0,0 @@
1
- import React from 'react';
2
- import { ValueType, PopupSelectProps } from '@atlaskit/select';
3
- import { Palette, Color } from '../types';
4
- export interface Props {
5
- /** color picker button label */
6
- label?: string;
7
- /** list of available colors */
8
- palette: Palette;
9
- /** selected color */
10
- selectedColor?: string;
11
- /** maximum column length */
12
- cols?: number;
13
- /** color of checkmark on selected color */
14
- checkMarkColor?: string;
15
- /** props for react-popper */
16
- popperProps?: PopupSelectProps['popperProps'];
17
- /** onChange handler */
18
- onChange: (value: string, analyticsEvent?: object) => void;
19
- /** You should not be accessing this prop under any circumstances. It is provided by @atlaskit/analytics-next. */
20
- createAnalyticsEvent?: any;
21
- }
22
- export declare class ColorPickerWithoutAnalytics extends React.Component<Props> {
23
- createAndFireEventOnAtlaskit: (payload: import("@atlaskit/analytics-next").AnalyticsEventPayload) => (createAnalyticsEvent: import("@atlaskit/analytics-next").CreateUIAnalyticsEvent) => import("@atlaskit/analytics-next").UIAnalyticsEvent;
24
- state: {
25
- isTabbing: boolean;
26
- };
27
- changeAnalyticsCaller: () => import("@atlaskit/analytics-next").UIAnalyticsEvent | undefined;
28
- onChangeSelect: (option: ValueType<Color>) => void;
29
- onOptionKeyDown: (value: string) => void;
30
- onKeyDown: (e: React.KeyboardEvent<HTMLElement>) => void;
31
- render(): JSX.Element;
32
- }
33
- declare const _default: React.ForwardRefExoticComponent<Pick<Omit<Props, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "label" | "key" | "onChange" | "checkMarkColor" | "cols" | "popperProps" | "palette" | "selectedColor" | "analyticsContext"> & React.RefAttributes<any>>;
34
- export default _default;
@@ -1,12 +0,0 @@
1
- import React from 'react';
2
- export interface Props {
3
- value: string;
4
- label?: string;
5
- onClick?: () => void;
6
- expanded?: boolean;
7
- }
8
- export default class ColorCard extends React.PureComponent<Props> {
9
- onMouseDown: (event: React.MouseEvent<HTMLButtonElement>) => void;
10
- onClick: (event: React.MouseEvent<HTMLButtonElement>) => void;
11
- render(): JSX.Element;
12
- }
@@ -1,7 +0,0 @@
1
- /// <reference types="react" />
2
- import { MenuListComponentProps, OptionProps } from '@atlaskit/select';
3
- import { Color } from '../types';
4
- export declare const MenuList: (props: MenuListComponentProps<Color>) => JSX.Element;
5
- export declare const Option: (props: OptionProps<Color>) => JSX.Element;
6
- export declare const DropdownIndicator: () => null;
7
- export declare const Placeholder: () => null;
@@ -1,6 +0,0 @@
1
- export declare const COLOR_CARD_SIZE = 30;
2
- export declare const KEY_SPACE = " ";
3
- export declare const KEY_ENTER = "Enter";
4
- export declare const KEY_ARROW_UP = "ArrowDown";
5
- export declare const KEY_ARROW_DOWN = "ArrowUp";
6
- export declare const KEY_TAB = "Tab";
@@ -1,10 +0,0 @@
1
- import ColorPicker from './components/ColorPicker';
2
- import { Mode } from './types';
3
- declare const Compact: Mode, Standard: Mode;
4
- export { ColorPickerWithoutAnalytics } from './components/ColorPicker';
5
- export type { Props as ColorPickerProps } from './components/ColorPicker';
6
- export { ColorPaletteMenuWithoutAnalytics } from './components/ColorPaletteMenu';
7
- export type { Props as ColorPaletteMenuProps } from './components/ColorPaletteMenu';
8
- export default ColorPicker;
9
- export { default as ColorPaletteMenu } from './components/ColorPaletteMenu';
10
- export { Standard, Compact };
@@ -1,13 +0,0 @@
1
- /// <reference types="react" />
2
- declare type ColorCardProps = {
3
- focused?: boolean;
4
- isTabbing?: boolean;
5
- };
6
- export declare const ColorCardOption: import("styled-components").StyledComponentClass<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & ColorCardProps, any, import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & ColorCardProps>;
7
- export declare const ColorCardButton: import("styled-components").StyledComponentClass<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & ColorCardProps, any, import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & ColorCardProps>;
8
- declare type ColorCardContentProps = {
9
- color: string;
10
- };
11
- export declare const ColorCardContent: import("styled-components").StyledComponentClass<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & ColorCardContentProps, any, import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & ColorCardContentProps>;
12
- export declare const ColorCardContentCheckMark: import("styled-components").StyledComponentClass<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement>, any, import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement>>;
13
- export {};
@@ -1,13 +0,0 @@
1
- /// <reference types="react" />
2
- import { Mode } from '../types';
3
- declare type Props = {
4
- mode?: Mode;
5
- };
6
- declare type ColorPaletteMenuProps = {
7
- cols: number;
8
- mode?: Mode;
9
- };
10
- export declare const ColorCardWrapper: import("styled-components").StyledComponentClass<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement>, any, import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement>>;
11
- export declare const ColorPaletteContainer: import("styled-components").StyledComponentClass<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & Props, any, import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & Props>;
12
- export declare const ColorPaletteMenu: import("styled-components").StyledComponentClass<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & ColorPaletteMenuProps, any, import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & ColorPaletteMenuProps>;
13
- export {};
@@ -1,2 +0,0 @@
1
- /// <reference types="react" />
2
- export declare const ColorCardWrapper: import("styled-components").StyledComponentClass<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement>, any, import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement>>;
@@ -1,9 +0,0 @@
1
- export interface Color {
2
- label: string;
3
- value: string;
4
- }
5
- export declare type Palette = Color[];
6
- export declare enum Mode {
7
- Compact = 0,
8
- Standard = 1
9
- }
@@ -1,7 +0,0 @@
1
- import { Palette } from './types';
2
- export declare const getWidth: (cols: number) => number;
3
- export declare const getOptions: import("memoize-one").MemoizedFn<(palette: Palette, selectedColor?: string | undefined) => {
4
- options: Palette;
5
- value: import("./types").Color;
6
- focusedItemIndex: number;
7
- }>;