@atlaskit/select 17.0.0 → 17.0.2
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 +12 -0
- package/dist/cjs/CountrySelect.js +5 -7
- package/dist/cjs/PopupSelect/components.js +7 -8
- package/dist/cjs/Select.js +1 -1
- package/dist/cjs/components/index.js +2 -4
- package/dist/cjs/components/indicators.js +8 -7
- package/dist/cjs/components/input-options.js +8 -7
- package/dist/cjs/index.js +7 -0
- package/dist/es2019/CountrySelect.js +6 -8
- package/dist/es2019/PopupSelect/components.js +8 -10
- package/dist/es2019/Select.js +1 -1
- package/dist/es2019/components/index.js +3 -4
- package/dist/es2019/components/indicators.js +8 -8
- package/dist/es2019/components/input-options.js +8 -8
- package/dist/es2019/index.js +1 -0
- package/dist/esm/CountrySelect.js +6 -8
- package/dist/esm/PopupSelect/components.js +8 -10
- package/dist/esm/Select.js +1 -1
- package/dist/esm/components/index.js +3 -4
- package/dist/esm/components/indicators.js +8 -8
- package/dist/esm/components/input-options.js +8 -8
- package/dist/esm/index.js +1 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types-ts4.5/index.d.ts +1 -0
- package/package.json +3 -3
- package/tmp/api-report-tmp.d.ts +0 -701
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import { jsx, css } from '@emotion/react';
|
|
1
|
+
import { css } from '@emotion/react';
|
|
3
2
|
import SelectClearIcon from '@atlaskit/icon/glyph/select-clear';
|
|
4
3
|
import { components } from 'react-select';
|
|
5
4
|
export { ClearIndicator, DropdownIndicator, LoadingIndicator } from './indicators';
|
|
@@ -11,10 +10,10 @@ var enabledStyles = css({
|
|
|
11
10
|
});
|
|
12
11
|
export var MultiValueRemove = function MultiValueRemove(props) {
|
|
13
12
|
var isDisabled = props.selectProps.isDisabled;
|
|
14
|
-
return
|
|
13
|
+
return /*#__PURE__*/React.createElement(components.MultiValueRemove, props, /*#__PURE__*/React.createElement("div", {
|
|
15
14
|
css: isDisabled ? disabledStyles : enabledStyles,
|
|
16
15
|
"data-testid": isDisabled ? 'hide-clear-icon' : 'show-clear-icon'
|
|
17
|
-
},
|
|
16
|
+
}, /*#__PURE__*/React.createElement(SelectClearIcon, {
|
|
18
17
|
label: "Clear",
|
|
19
18
|
size: "small",
|
|
20
19
|
primaryColor: "transparent",
|
|
@@ -2,8 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4
4
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
5
|
-
|
|
6
|
-
import { jsx, css } from '@emotion/react';
|
|
5
|
+
import { css } from '@emotion/react';
|
|
7
6
|
import { components } from 'react-select';
|
|
8
7
|
import Spinner from '@atlaskit/spinner';
|
|
9
8
|
import SelectClearIcon from '@atlaskit/icon/glyph/select-clear';
|
|
@@ -15,33 +14,34 @@ var iconContainerStyles = css({
|
|
|
15
14
|
alignItems: 'center'
|
|
16
15
|
});
|
|
17
16
|
export var ClearIndicator = function ClearIndicator(props) {
|
|
18
|
-
return
|
|
17
|
+
return /*#__PURE__*/React.createElement(components.ClearIndicator, _objectSpread(_objectSpread({}, props), {}, {
|
|
19
18
|
innerProps: _objectSpread(_objectSpread({}, props.innerProps), {}, {
|
|
20
19
|
'aria-hidden': 'false'
|
|
21
20
|
})
|
|
22
|
-
}),
|
|
21
|
+
}), /*#__PURE__*/React.createElement("button", {
|
|
23
22
|
css: iconContainerStyles,
|
|
24
23
|
type: "button",
|
|
25
24
|
tabIndex: -1
|
|
26
|
-
},
|
|
25
|
+
}, /*#__PURE__*/React.createElement(SelectClearIcon, {
|
|
27
26
|
size: "small",
|
|
28
27
|
label: "clear"
|
|
29
28
|
})));
|
|
30
29
|
};
|
|
31
30
|
export var DropdownIndicator = function DropdownIndicator(props) {
|
|
32
|
-
return
|
|
31
|
+
return /*#__PURE__*/React.createElement(components.DropdownIndicator, props, /*#__PURE__*/React.createElement(DownIcon, {
|
|
33
32
|
label: "open"
|
|
34
33
|
}));
|
|
35
34
|
};
|
|
36
35
|
export var LoadingIndicator = function LoadingIndicator(props) {
|
|
37
36
|
var loadingStyles = css(props.getStyles('loadingIndicator', props));
|
|
38
37
|
return (
|
|
38
|
+
/*#__PURE__*/
|
|
39
39
|
// This *must* be constructed this way because this is being consumed by
|
|
40
40
|
// `react-select` and we don't control what it wants.
|
|
41
41
|
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
42
|
-
|
|
42
|
+
React.createElement("div", _extends({
|
|
43
43
|
css: loadingStyles
|
|
44
|
-
}, props.innerProps),
|
|
44
|
+
}, props.innerProps), /*#__PURE__*/React.createElement(Spinner, {
|
|
45
45
|
size: "small"
|
|
46
46
|
}))
|
|
47
47
|
);
|
|
@@ -13,8 +13,7 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
|
|
|
13
13
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
14
14
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
15
15
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
16
|
-
|
|
17
|
-
import { css, jsx } from '@emotion/react';
|
|
16
|
+
import { css } from '@emotion/react';
|
|
18
17
|
import { Component } from 'react';
|
|
19
18
|
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
20
19
|
import RadioIcon from '@atlaskit/icon/glyph/radio';
|
|
@@ -195,14 +194,15 @@ var ControlOption = /*#__PURE__*/function (_Component) {
|
|
|
195
194
|
styles = _getPrimitiveStyles2[0],
|
|
196
195
|
classes = _getPrimitiveStyles2[1];
|
|
197
196
|
return (
|
|
197
|
+
/*#__PURE__*/
|
|
198
198
|
// These need to remain this way because `react-select` passes props with
|
|
199
199
|
// styles inside, and that must be done dynamically.
|
|
200
200
|
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
201
|
-
|
|
201
|
+
React.createElement("div", _extends({
|
|
202
202
|
css: styles,
|
|
203
203
|
className: classes,
|
|
204
204
|
ref: innerRef
|
|
205
|
-
}, props),
|
|
205
|
+
}, props), /*#__PURE__*/React.createElement("div", {
|
|
206
206
|
css: [baseIconStyles,
|
|
207
207
|
// Here we are adding a border to the Checkbox and Radio SVG icons
|
|
208
208
|
// This is an a11y fix for Select only for now but it may be rolled
|
|
@@ -219,11 +219,11 @@ var ControlOption = /*#__PURE__*/function (_Component) {
|
|
|
219
219
|
stroke: getBorderColor(_objectSpread(_objectSpread({}, this.props), this.state))
|
|
220
220
|
}
|
|
221
221
|
}]
|
|
222
|
-
}, !!Icon ?
|
|
222
|
+
}, !!Icon ? /*#__PURE__*/React.createElement(Icon, {
|
|
223
223
|
label: "",
|
|
224
224
|
primaryColor: getPrimaryColor(_objectSpread(_objectSpread({}, this.props), this.state)),
|
|
225
225
|
secondaryColor: getSecondaryColor(_objectSpread(_objectSpread({}, this.props), this.state))
|
|
226
|
-
}) : null),
|
|
226
|
+
}) : null), /*#__PURE__*/React.createElement("div", {
|
|
227
227
|
css: baseOptionStyles
|
|
228
228
|
}, children))
|
|
229
229
|
);
|
|
@@ -232,12 +232,12 @@ var ControlOption = /*#__PURE__*/function (_Component) {
|
|
|
232
232
|
return ControlOption;
|
|
233
233
|
}(Component);
|
|
234
234
|
export var CheckboxOption = function CheckboxOption(props) {
|
|
235
|
-
return
|
|
235
|
+
return /*#__PURE__*/React.createElement(ControlOption, _extends({
|
|
236
236
|
Icon: CheckboxIcon
|
|
237
237
|
}, props));
|
|
238
238
|
};
|
|
239
239
|
export var RadioOption = function RadioOption(props) {
|
|
240
|
-
return
|
|
240
|
+
return /*#__PURE__*/React.createElement(ControlOption, _extends({
|
|
241
241
|
Icon: RadioIcon
|
|
242
242
|
}, props));
|
|
243
243
|
};
|
package/dist/esm/index.js
CHANGED
|
@@ -6,6 +6,7 @@ export { default, SelectWithoutAnalytics } from './entry-points/select';
|
|
|
6
6
|
export { default as AsyncSelect } from './entry-points/async-select';
|
|
7
7
|
export { default as CreatableSelect } from './entry-points/creatable-select';
|
|
8
8
|
export { default as AsyncCreatableSelect } from './entry-points/async-creatable-select';
|
|
9
|
+
export { isOptionsGrouped } from './utils/grouped-options-announcement';
|
|
9
10
|
export { default as CheckboxSelect } from './CheckboxSelect';
|
|
10
11
|
export { default as CountrySelect } from './CountrySelect';
|
|
11
12
|
export { default as RadioSelect } from './RadioSelect';
|
package/dist/types/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ export { default, SelectWithoutAnalytics } from './entry-points/select';
|
|
|
6
6
|
export { default as AsyncSelect } from './entry-points/async-select';
|
|
7
7
|
export { default as CreatableSelect } from './entry-points/creatable-select';
|
|
8
8
|
export { default as AsyncCreatableSelect } from './entry-points/async-creatable-select';
|
|
9
|
+
export { isOptionsGrouped } from './utils/grouped-options-announcement';
|
|
9
10
|
export { default as CheckboxSelect } from './CheckboxSelect';
|
|
10
11
|
export { default as CountrySelect } from './CountrySelect';
|
|
11
12
|
export { default as RadioSelect } from './RadioSelect';
|
|
@@ -6,6 +6,7 @@ export { default, SelectWithoutAnalytics } from './entry-points/select';
|
|
|
6
6
|
export { default as AsyncSelect } from './entry-points/async-select';
|
|
7
7
|
export { default as CreatableSelect } from './entry-points/creatable-select';
|
|
8
8
|
export { default as AsyncCreatableSelect } from './entry-points/async-creatable-select';
|
|
9
|
+
export { isOptionsGrouped } from './utils/grouped-options-announcement';
|
|
9
10
|
export { default as CheckboxSelect } from './CheckboxSelect';
|
|
10
11
|
export { default as CountrySelect } from './CountrySelect';
|
|
11
12
|
export { default as RadioSelect } from './RadioSelect';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/select",
|
|
3
|
-
"version": "17.0.
|
|
3
|
+
"version": "17.0.2",
|
|
4
4
|
"description": "Select allows users to make a single selection or multiple selections from a list of options.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -39,11 +39,11 @@
|
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"@atlaskit/analytics-next": "^9.1.0",
|
|
42
|
-
"@atlaskit/icon": "^
|
|
42
|
+
"@atlaskit/icon": "^22.0.0",
|
|
43
43
|
"@atlaskit/platform-feature-flags": "^0.2.0",
|
|
44
44
|
"@atlaskit/spinner": "^16.0.0",
|
|
45
45
|
"@atlaskit/theme": "^12.6.0",
|
|
46
|
-
"@atlaskit/tokens": "^1.
|
|
46
|
+
"@atlaskit/tokens": "^1.29.0",
|
|
47
47
|
"@atlaskit/visually-hidden": "^1.2.0",
|
|
48
48
|
"@babel/runtime": "^7.0.0",
|
|
49
49
|
"@emotion/react": "^11.7.1",
|