@atlaskit/icon 25.8.0 → 26.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 +26 -0
- package/core/chevron-double-left.d.ts +13 -0
- package/core/chevron-double-left.js +27 -0
- package/core/chevron-double-right.d.ts +13 -0
- package/core/chevron-double-right.js +27 -0
- package/core/chevron-down.d.ts +13 -0
- package/core/chevron-down.js +27 -0
- package/core/chevron-left.d.ts +13 -0
- package/core/chevron-left.js +27 -0
- package/core/chevron-right.d.ts +13 -0
- package/core/chevron-right.js +27 -0
- package/core/chevron-up.d.ts +13 -0
- package/core/chevron-up.js +27 -0
- package/core/migration/chevron-down--chevron-down-circle.d.ts +15 -0
- package/core/migration/chevron-down--chevron-down-circle.js +30 -0
- package/core/migration/chevron-down--hipchat-chevron-down.d.ts +15 -0
- package/core/migration/chevron-down--hipchat-chevron-down.js +30 -0
- package/core/migration/chevron-down.d.ts +15 -0
- package/core/migration/chevron-down.js +30 -0
- package/core/migration/chevron-left--chevron-left-circle.d.ts +15 -0
- package/core/migration/chevron-left--chevron-left-circle.js +30 -0
- package/core/migration/chevron-left--chevron-left-large.d.ts +15 -0
- package/core/migration/chevron-left--chevron-left-large.js +30 -0
- package/core/migration/chevron-left.d.ts +15 -0
- package/core/migration/chevron-left.js +30 -0
- package/core/migration/chevron-right--chevron-right-circle.d.ts +15 -0
- package/core/migration/chevron-right--chevron-right-circle.js +30 -0
- package/core/migration/chevron-right--chevron-right-large.d.ts +15 -0
- package/core/migration/chevron-right--chevron-right-large.js +30 -0
- package/core/migration/chevron-right.d.ts +15 -0
- package/core/migration/chevron-right.js +30 -0
- package/core/migration/chevron-up--chevron-up-circle.d.ts +15 -0
- package/core/migration/chevron-up--chevron-up-circle.js +30 -0
- package/core/migration/chevron-up--hipchat-chevron-up.d.ts +15 -0
- package/core/migration/chevron-up--hipchat-chevron-up.js +30 -0
- package/core/migration/chevron-up.d.ts +15 -0
- package/core/migration/chevron-up.js +30 -0
- package/dist/cjs/components/icon-facade.js +9 -7
- package/dist/cjs/components/icon-new.compiled.css +22 -0
- package/dist/cjs/components/icon-new.js +67 -100
- package/dist/cjs/components/icon-tile.compiled.css +48 -0
- package/dist/cjs/components/icon-tile.js +40 -125
- package/dist/cjs/components/icon.compiled.css +30 -0
- package/dist/cjs/components/icon.js +31 -76
- package/dist/cjs/components/skeleton.compiled.css +12 -0
- package/dist/cjs/components/skeleton.js +20 -24
- package/dist/cjs/components/svg.compiled.css +13 -0
- package/dist/cjs/components/svg.js +20 -17
- package/dist/cjs/metadata-core.js +65 -1
- package/dist/cjs/migration-map.js +254 -182
- package/dist/es2019/components/icon-facade.js +8 -6
- package/dist/es2019/components/icon-new.compiled.css +22 -0
- package/dist/es2019/components/icon-new.js +62 -98
- package/dist/es2019/components/icon-tile.compiled.css +48 -0
- package/dist/es2019/components/icon-tile.js +37 -124
- package/dist/es2019/components/icon.compiled.css +30 -0
- package/dist/es2019/components/icon.js +26 -77
- package/dist/es2019/components/skeleton.compiled.css +12 -0
- package/dist/es2019/components/skeleton.js +15 -21
- package/dist/es2019/components/svg.compiled.css +13 -0
- package/dist/es2019/components/svg.js +16 -15
- package/dist/es2019/metadata-core.js +65 -1
- package/dist/es2019/migration-map.js +254 -182
- package/dist/esm/components/icon-facade.js +9 -7
- package/dist/esm/components/icon-new.compiled.css +22 -0
- package/dist/esm/components/icon-new.js +63 -98
- package/dist/esm/components/icon-tile.compiled.css +48 -0
- package/dist/esm/components/icon-tile.js +37 -124
- package/dist/esm/components/icon.compiled.css +30 -0
- package/dist/esm/components/icon.js +26 -77
- package/dist/esm/components/skeleton.compiled.css +12 -0
- package/dist/esm/components/skeleton.js +15 -21
- package/dist/esm/components/svg.compiled.css +13 -0
- package/dist/esm/components/svg.js +16 -15
- package/dist/esm/metadata-core.js +65 -1
- package/dist/esm/migration-map.js +254 -182
- package/dist/types/components/icon-tile.d.ts +2 -2
- package/dist/types/index.d.ts +1 -1
- package/dist/types/metadata-core.d.ts +1 -1
- package/dist/types/types.d.ts +25 -8
- package/dist/types-ts4.5/components/icon-tile.d.ts +2 -2
- package/dist/types-ts4.5/index.d.ts +1 -1
- package/dist/types-ts4.5/metadata-core.d.ts +1 -1
- package/dist/types-ts4.5/types.d.ts +25 -8
- package/glyph/chevron-down-circle.js +2 -3
- package/glyph/chevron-down.js +2 -3
- package/glyph/chevron-left-circle.js +2 -3
- package/glyph/chevron-left-large.js +2 -3
- package/glyph/chevron-left.js +2 -3
- package/glyph/chevron-right-circle.js +2 -3
- package/glyph/chevron-right-large.js +2 -3
- package/glyph/chevron-right.js +2 -3
- package/glyph/chevron-up-circle.js +2 -3
- package/glyph/chevron-up.js +2 -3
- package/glyph/hipchat/chevron-down.js +2 -3
- package/glyph/hipchat/chevron-up.js +2 -3
- package/package.json +8 -10
- package/svgs/core/chevron-double-left.svg +1 -0
- package/svgs/core/chevron-double-right.svg +1 -0
- package/svgs/core/chevron-down.svg +1 -0
- package/svgs/core/chevron-left.svg +1 -0
- package/svgs/core/chevron-right.svg +1 -0
- package/svgs/core/chevron-up.svg +1 -0
- package/dist/cjs/components/styles.js +0 -64
- package/dist/cjs/components/utils.js +0 -9
- package/dist/es2019/components/styles.js +0 -58
- package/dist/es2019/components/utils.js +0 -1
- package/dist/esm/components/styles.js +0 -57
- package/dist/esm/components/utils.js +0 -3
- package/dist/types/components/styles.d.ts +0 -28
- package/dist/types/components/utils.d.ts +0 -1
- package/dist/types-ts4.5/components/styles.d.ts +0 -28
- package/dist/types-ts4.5/components/utils.d.ts +0 -1
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
|
|
3
|
+
* @codegen <<SignedSource::740f6cddb95c56c5c4c0beb67f7dccb3>>
|
|
4
|
+
* @codegenCommand yarn build:icon-glyphs
|
|
5
|
+
*/
|
|
6
|
+
"use strict";
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, "__esModule", {
|
|
9
|
+
value: true
|
|
10
|
+
});
|
|
11
|
+
exports.default = void 0;
|
|
12
|
+
var _react = _interopRequireDefault(require("react"));
|
|
13
|
+
var _chevronRight = _interopRequireDefault(require("@atlaskit/icon/core/chevron-right"));
|
|
14
|
+
var _chevronRightLarge = _interopRequireDefault(require("@atlaskit/icon/glyph/chevron-right-large"));
|
|
15
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
16
|
+
/**
|
|
17
|
+
* Migration Icon component for ChevronRightIcon.
|
|
18
|
+
* This component is ChevronRightIcon, with `UNSAFE_fallbackIcon` set to "ChevronRightLargeIcon".
|
|
19
|
+
*
|
|
20
|
+
* Category: multi-purpose
|
|
21
|
+
* Location: @atlaskit/icon
|
|
22
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/icon)
|
|
23
|
+
* - [Code](https://atlaskit.atlassian.com/packages/design-system/icon/docs/custom-icons)
|
|
24
|
+
*/
|
|
25
|
+
const ChevronRightIcon = props => /*#__PURE__*/_react.default.createElement(_chevronRight.default, Object.assign({
|
|
26
|
+
LEGACY_fallbackIcon: _chevronRightLarge.default
|
|
27
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
28
|
+
}, props));
|
|
29
|
+
ChevronRightIcon.Name = 'ChevronRightIconMigration';
|
|
30
|
+
var _default = exports.default = ChevronRightIcon;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
|
|
3
|
+
* @codegen <<SignedSource::f57fa70ce1ea0c1f422ada2e278f57fc>>
|
|
4
|
+
* @codegenCommand yarn build:icon-glyphs
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import type { NewCoreIconProps } from '@atlaskit/icon/base-new';
|
|
9
|
+
import Icon from '@atlaskit/icon/base-new';
|
|
10
|
+
|
|
11
|
+
declare const ChevronRightIconMigration: {
|
|
12
|
+
(props: Omit<NewCoreIconProps, | 'LEGACY_fallbackIcon'> ): JSX.Element;
|
|
13
|
+
displayName: string;
|
|
14
|
+
};
|
|
15
|
+
export default ChevronRightIconMigration;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
|
|
3
|
+
* @codegen <<SignedSource::005d53414e0b7fe018aceef15094403a>>
|
|
4
|
+
* @codegenCommand yarn build:icon-glyphs
|
|
5
|
+
*/
|
|
6
|
+
"use strict";
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, "__esModule", {
|
|
9
|
+
value: true
|
|
10
|
+
});
|
|
11
|
+
exports.default = void 0;
|
|
12
|
+
var _react = _interopRequireDefault(require("react"));
|
|
13
|
+
var _chevronRight = _interopRequireDefault(require("@atlaskit/icon/core/chevron-right"));
|
|
14
|
+
var _chevronRight2 = _interopRequireDefault(require("@atlaskit/icon/glyph/chevron-right"));
|
|
15
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
16
|
+
/**
|
|
17
|
+
* Migration Icon component for ChevronRightIcon.
|
|
18
|
+
* This component is ChevronRightIcon, with `UNSAFE_fallbackIcon` set to "ChevronRightIcon".
|
|
19
|
+
*
|
|
20
|
+
* Category: multi-purpose
|
|
21
|
+
* Location: @atlaskit/icon
|
|
22
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/icon)
|
|
23
|
+
* - [Code](https://atlaskit.atlassian.com/packages/design-system/icon/docs/custom-icons)
|
|
24
|
+
*/
|
|
25
|
+
const ChevronRightIcon = props => /*#__PURE__*/_react.default.createElement(_chevronRight.default, Object.assign({
|
|
26
|
+
LEGACY_fallbackIcon: _chevronRight2.default
|
|
27
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
28
|
+
}, props));
|
|
29
|
+
ChevronRightIcon.Name = 'ChevronRightIconMigration';
|
|
30
|
+
var _default = exports.default = ChevronRightIcon;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
|
|
3
|
+
* @codegen <<SignedSource::38f279ef382eea10dc428e9c0befb5a8>>
|
|
4
|
+
* @codegenCommand yarn build:icon-glyphs
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import type { NewCoreIconProps } from '@atlaskit/icon/base-new';
|
|
9
|
+
import Icon from '@atlaskit/icon/base-new';
|
|
10
|
+
|
|
11
|
+
declare const ChevronUpIconMigration: {
|
|
12
|
+
(props: Omit<NewCoreIconProps, | 'LEGACY_fallbackIcon'> ): JSX.Element;
|
|
13
|
+
displayName: string;
|
|
14
|
+
};
|
|
15
|
+
export default ChevronUpIconMigration;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
|
|
3
|
+
* @codegen <<SignedSource::82273d7016fe9d19fcef25761ebc96ae>>
|
|
4
|
+
* @codegenCommand yarn build:icon-glyphs
|
|
5
|
+
*/
|
|
6
|
+
"use strict";
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, "__esModule", {
|
|
9
|
+
value: true
|
|
10
|
+
});
|
|
11
|
+
exports.default = void 0;
|
|
12
|
+
var _react = _interopRequireDefault(require("react"));
|
|
13
|
+
var _chevronUp = _interopRequireDefault(require("@atlaskit/icon/core/chevron-up"));
|
|
14
|
+
var _chevronUpCircle = _interopRequireDefault(require("@atlaskit/icon/glyph/chevron-up-circle"));
|
|
15
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
16
|
+
/**
|
|
17
|
+
* Migration Icon component for ChevronUpIcon.
|
|
18
|
+
* This component is ChevronUpIcon, with `UNSAFE_fallbackIcon` set to "ChevronUpCircleIcon".
|
|
19
|
+
*
|
|
20
|
+
* Category: multi-purpose
|
|
21
|
+
* Location: @atlaskit/icon
|
|
22
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/icon)
|
|
23
|
+
* - [Code](https://atlaskit.atlassian.com/packages/design-system/icon/docs/custom-icons)
|
|
24
|
+
*/
|
|
25
|
+
const ChevronUpIcon = props => /*#__PURE__*/_react.default.createElement(_chevronUp.default, Object.assign({
|
|
26
|
+
LEGACY_fallbackIcon: _chevronUpCircle.default
|
|
27
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
28
|
+
}, props));
|
|
29
|
+
ChevronUpIcon.Name = 'ChevronUpIconMigration';
|
|
30
|
+
var _default = exports.default = ChevronUpIcon;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
|
|
3
|
+
* @codegen <<SignedSource::38f279ef382eea10dc428e9c0befb5a8>>
|
|
4
|
+
* @codegenCommand yarn build:icon-glyphs
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import type { NewCoreIconProps } from '@atlaskit/icon/base-new';
|
|
9
|
+
import Icon from '@atlaskit/icon/base-new';
|
|
10
|
+
|
|
11
|
+
declare const ChevronUpIconMigration: {
|
|
12
|
+
(props: Omit<NewCoreIconProps, | 'LEGACY_fallbackIcon'> ): JSX.Element;
|
|
13
|
+
displayName: string;
|
|
14
|
+
};
|
|
15
|
+
export default ChevronUpIconMigration;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
|
|
3
|
+
* @codegen <<SignedSource::0e6f3dc0e27d0c7d3b6cfe94e38052b6>>
|
|
4
|
+
* @codegenCommand yarn build:icon-glyphs
|
|
5
|
+
*/
|
|
6
|
+
"use strict";
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, "__esModule", {
|
|
9
|
+
value: true
|
|
10
|
+
});
|
|
11
|
+
exports.default = void 0;
|
|
12
|
+
var _react = _interopRequireDefault(require("react"));
|
|
13
|
+
var _chevronUp = _interopRequireDefault(require("@atlaskit/icon/core/chevron-up"));
|
|
14
|
+
var _chevronUp2 = _interopRequireDefault(require("@atlaskit/icon/glyph/hipchat/chevron-up"));
|
|
15
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
16
|
+
/**
|
|
17
|
+
* Migration Icon component for ChevronUpIcon.
|
|
18
|
+
* This component is ChevronUpIcon, with `UNSAFE_fallbackIcon` set to "HipchatChevronUpIcon".
|
|
19
|
+
*
|
|
20
|
+
* Category: multi-purpose
|
|
21
|
+
* Location: @atlaskit/icon
|
|
22
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/icon)
|
|
23
|
+
* - [Code](https://atlaskit.atlassian.com/packages/design-system/icon/docs/custom-icons)
|
|
24
|
+
*/
|
|
25
|
+
const ChevronUpIcon = props => /*#__PURE__*/_react.default.createElement(_chevronUp.default, Object.assign({
|
|
26
|
+
LEGACY_fallbackIcon: _chevronUp2.default
|
|
27
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
28
|
+
}, props));
|
|
29
|
+
ChevronUpIcon.Name = 'ChevronUpIconMigration';
|
|
30
|
+
var _default = exports.default = ChevronUpIcon;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
|
|
3
|
+
* @codegen <<SignedSource::38f279ef382eea10dc428e9c0befb5a8>>
|
|
4
|
+
* @codegenCommand yarn build:icon-glyphs
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import type { NewCoreIconProps } from '@atlaskit/icon/base-new';
|
|
9
|
+
import Icon from '@atlaskit/icon/base-new';
|
|
10
|
+
|
|
11
|
+
declare const ChevronUpIconMigration: {
|
|
12
|
+
(props: Omit<NewCoreIconProps, | 'LEGACY_fallbackIcon'> ): JSX.Element;
|
|
13
|
+
displayName: string;
|
|
14
|
+
};
|
|
15
|
+
export default ChevronUpIconMigration;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
|
|
3
|
+
* @codegen <<SignedSource::0291258c506777aac220262c44f610b3>>
|
|
4
|
+
* @codegenCommand yarn build:icon-glyphs
|
|
5
|
+
*/
|
|
6
|
+
"use strict";
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, "__esModule", {
|
|
9
|
+
value: true
|
|
10
|
+
});
|
|
11
|
+
exports.default = void 0;
|
|
12
|
+
var _react = _interopRequireDefault(require("react"));
|
|
13
|
+
var _chevronUp = _interopRequireDefault(require("@atlaskit/icon/core/chevron-up"));
|
|
14
|
+
var _chevronUp2 = _interopRequireDefault(require("@atlaskit/icon/glyph/chevron-up"));
|
|
15
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
16
|
+
/**
|
|
17
|
+
* Migration Icon component for ChevronUpIcon.
|
|
18
|
+
* This component is ChevronUpIcon, with `UNSAFE_fallbackIcon` set to "ChevronUpIcon".
|
|
19
|
+
*
|
|
20
|
+
* Category: multi-purpose
|
|
21
|
+
* Location: @atlaskit/icon
|
|
22
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/icon)
|
|
23
|
+
* - [Code](https://atlaskit.atlassian.com/packages/design-system/icon/docs/custom-icons)
|
|
24
|
+
*/
|
|
25
|
+
const ChevronUpIcon = props => /*#__PURE__*/_react.default.createElement(_chevronUp.default, Object.assign({
|
|
26
|
+
LEGACY_fallbackIcon: _chevronUp2.default
|
|
27
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
28
|
+
}, props));
|
|
29
|
+
ChevronUpIcon.Name = 'ChevronUpIconMigration';
|
|
30
|
+
var _default = exports.default = ChevronUpIcon;
|
|
@@ -11,7 +11,7 @@ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/h
|
|
|
11
11
|
var _react = _interopRequireWildcard(require("react"));
|
|
12
12
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
13
13
|
var _icon = require("./icon");
|
|
14
|
-
var _excluded = ["dangerouslySetGlyph"];
|
|
14
|
+
var _excluded = ["dangerouslySetGlyph", "size"];
|
|
15
15
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
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
|
var sizeSpacingMap = {
|
|
@@ -34,34 +34,36 @@ var sizeSpacingMap = {
|
|
|
34
34
|
* @returns A React element representing either the new or legacy icon based on the feature flag and icon size.
|
|
35
35
|
*/
|
|
36
36
|
var IconFacade = exports.IconFacade = /*#__PURE__*/(0, _react.memo)(function IconFacade(_ref) {
|
|
37
|
-
var _props$size;
|
|
38
37
|
var dangerouslySetGlyph = _ref.dangerouslySetGlyph,
|
|
38
|
+
size = _ref.size,
|
|
39
39
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
40
40
|
var NewIcon = props.newIcon;
|
|
41
41
|
|
|
42
42
|
// By default, the icon size will be medium for core icons and small for utility icons
|
|
43
|
-
var
|
|
43
|
+
var iconSize = size !== null && size !== void 0 ? size : 'medium';
|
|
44
44
|
var useNewIcon = !props.isFacadeDisabled &&
|
|
45
45
|
// eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
|
|
46
46
|
(0, _platformFeatureFlags.fg)('platform-visual-refresh-icons-legacy-facade');
|
|
47
|
-
if (useNewIcon && NewIcon && (
|
|
47
|
+
if (useNewIcon && NewIcon && (iconSize === 'small' || iconSize === 'medium')) {
|
|
48
48
|
if (props.iconType === 'utility') {
|
|
49
49
|
var Icon = NewIcon;
|
|
50
50
|
return /*#__PURE__*/_react.default.createElement(Icon, (0, _extends2.default)({}, props, {
|
|
51
|
-
spacing: (0, _platformFeatureFlags.fg)('platform-visual-refresh-icons-facade-button-fix') ? sizeSpacingMap['utility'][
|
|
51
|
+
spacing: (0, _platformFeatureFlags.fg)('platform-visual-refresh-icons-facade-button-fix') ? sizeSpacingMap['utility'][iconSize] : 'none',
|
|
52
52
|
color: props.primaryColor || 'currentColor',
|
|
53
53
|
type: props.iconType
|
|
54
54
|
}));
|
|
55
55
|
} else {
|
|
56
56
|
var _Icon = NewIcon;
|
|
57
57
|
return /*#__PURE__*/_react.default.createElement(_Icon, (0, _extends2.default)({}, props, {
|
|
58
|
-
|
|
58
|
+
size: iconSize,
|
|
59
|
+
spacing: sizeSpacingMap['core'][iconSize],
|
|
59
60
|
color: props.primaryColor || 'currentColor',
|
|
60
61
|
type: props.iconType
|
|
61
62
|
}));
|
|
62
63
|
}
|
|
63
64
|
}
|
|
64
65
|
return /*#__PURE__*/_react.default.createElement(_icon.Icon, (0, _extends2.default)({
|
|
65
|
-
dangerouslySetGlyph: dangerouslySetGlyph
|
|
66
|
+
dangerouslySetGlyph: dangerouslySetGlyph,
|
|
67
|
+
size: size
|
|
66
68
|
}, props));
|
|
67
69
|
});
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
._18m915vq{overflow-y:hidden}
|
|
2
|
+
._1bsb1ejb{width:var(--ds-space-300,24px)}
|
|
3
|
+
._1bsb1kw7{width:inherit}
|
|
4
|
+
._1bsbpxbi{width:var(--ds-space-200,1pc)}
|
|
5
|
+
._1bsbutpp{width:var(--ds-space-150,9pt)}
|
|
6
|
+
._1e0c1o8l{display:inline-block}
|
|
7
|
+
._1o9zidpf{flex-shrink:0}
|
|
8
|
+
._1reo15vq{overflow-x:hidden}
|
|
9
|
+
._4t3i1ejb{height:var(--ds-space-300,24px)}
|
|
10
|
+
._4t3i1kw7{height:inherit}
|
|
11
|
+
._4t3ipxbi{height:var(--ds-space-200,1pc)}
|
|
12
|
+
._4t3iutpp{height:var(--ds-space-150,9pt)}
|
|
13
|
+
._bozg1mb9{padding-inline-start:var(--ds--button--new-icon-padding-start,0)}
|
|
14
|
+
._lcxvglyw{pointer-events:none}
|
|
15
|
+
._s7n4yfq0{vertical-align:bottom}
|
|
16
|
+
._syaz1r31{color:currentColor}
|
|
17
|
+
._vc881r31 stop{stop-color:currentColor}
|
|
18
|
+
._vchhusvi{box-sizing:border-box}
|
|
19
|
+
._vwz4kb7n{line-height:1}
|
|
20
|
+
._vwz4utpp{line-height:var(--ds-space-150,9pt)}
|
|
21
|
+
._y4ti1igz{padding-inline-end:var(--ds--button--new-icon-padding-end,0)}
|
|
22
|
+
@media screen and (forced-colors:active){._12va1onz{color:CanvasText}._jcxd1r8n{filter:grayscale(1)}}
|
|
@@ -1,97 +1,47 @@
|
|
|
1
|
+
/* icon-new.tsx generated by @compiled/babel-plugin v0.36.1 */
|
|
1
2
|
"use strict";
|
|
2
3
|
|
|
4
|
+
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
3
5
|
Object.defineProperty(exports, "__esModule", {
|
|
4
6
|
value: true
|
|
5
7
|
});
|
|
6
8
|
exports.default = exports.Icon = void 0;
|
|
7
|
-
|
|
8
|
-
var
|
|
9
|
+
require("./icon-new.compiled.css");
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
var React = _react;
|
|
12
|
+
var _runtime = require("@compiled/react/runtime");
|
|
9
13
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
* @jsx jsx
|
|
13
|
-
*/
|
|
14
|
-
|
|
15
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
16
|
-
|
|
14
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
15
|
+
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
16
|
/**
|
|
18
17
|
* We are hiding this props from consumers as it's reserved
|
|
19
18
|
* for use by Icon Tile.
|
|
20
19
|
*/
|
|
21
20
|
|
|
22
|
-
var
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
* Stop-color doesn't properly apply in chrome when the inherited/current color changes.
|
|
27
|
-
* We have to initially set stop-color to inherit (either via DOM attribute or an initial CSS
|
|
28
|
-
* rule) and then override it with currentColor for the color changes to be picked up.
|
|
29
|
-
*/
|
|
30
|
-
// eslint-disable-next-line @atlaskit/design-system/no-nested-styles, @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
|
|
31
|
-
stop: {
|
|
32
|
-
stopColor: 'currentColor'
|
|
33
|
-
}
|
|
34
|
-
});
|
|
35
|
-
var svgStyles = (0, _react2.css)({
|
|
36
|
-
color: 'currentColor',
|
|
37
|
-
verticalAlign: 'bottom'
|
|
38
|
-
});
|
|
39
|
-
var iconStyles = (0, _react2.css)({
|
|
40
|
-
display: 'inline-block',
|
|
41
|
-
boxSizing: 'border-box',
|
|
42
|
-
flexShrink: 0,
|
|
43
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
44
|
-
lineHeight: 1,
|
|
45
|
-
paddingInlineEnd: 'var(--ds--button--new-icon-padding-end, 0)',
|
|
46
|
-
paddingInlineStart: 'var(--ds--button--new-icon-padding-start, 0)'
|
|
47
|
-
});
|
|
48
|
-
var utilityIconStyles = (0, _react2.css)({
|
|
49
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
50
|
-
lineHeight: "var(--ds-space-150, 12px)"
|
|
51
|
-
});
|
|
52
|
-
var scaleStyles = (0, _react2.css)({
|
|
53
|
-
width: 'inherit',
|
|
54
|
-
height: 'inherit'
|
|
55
|
-
});
|
|
21
|
+
var svgStyles = null;
|
|
22
|
+
var iconStyles = null;
|
|
23
|
+
var utilityIconStyles = null;
|
|
24
|
+
var scaleStyles = null;
|
|
56
25
|
|
|
57
26
|
/**
|
|
58
27
|
* For windows high contrast mode
|
|
59
28
|
*/
|
|
60
|
-
var baseHcmStyles =
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
spacious: (0, _react2.css)({
|
|
77
|
-
width: "var(--ds-space-300, 24px)",
|
|
78
|
-
height: "var(--ds-space-300, 24px)"
|
|
79
|
-
})
|
|
80
|
-
},
|
|
81
|
-
utility: {
|
|
82
|
-
none: (0, _react2.css)({
|
|
83
|
-
width: "var(--ds-space-150, 12px)",
|
|
84
|
-
height: "var(--ds-space-150, 12px)"
|
|
85
|
-
}),
|
|
86
|
-
compact: (0, _react2.css)({
|
|
87
|
-
width: "var(--ds-space-200, 16px)",
|
|
88
|
-
height: "var(--ds-space-200, 16px)"
|
|
89
|
-
}),
|
|
90
|
-
spacious: (0, _react2.css)({
|
|
91
|
-
width: "var(--ds-space-300, 24px)",
|
|
92
|
-
height: "var(--ds-space-300, 24px)"
|
|
93
|
-
})
|
|
94
|
-
}
|
|
29
|
+
var baseHcmStyles = null;
|
|
30
|
+
var scaleSize = null;
|
|
31
|
+
var coreSizeMedium = {
|
|
32
|
+
none: "_1bsbpxbi _4t3ipxbi",
|
|
33
|
+
compact: "_1bsb1ejb _4t3i1ejb",
|
|
34
|
+
spacious: "_1bsb1ejb _4t3i1ejb"
|
|
35
|
+
};
|
|
36
|
+
var coreSizeSmall = {
|
|
37
|
+
none: "_1bsbutpp _4t3iutpp",
|
|
38
|
+
compact: "_1bsbpxbi _4t3ipxbi",
|
|
39
|
+
spacious: "_1bsb1ejb _4t3i1ejb"
|
|
40
|
+
};
|
|
41
|
+
var utilSizes = {
|
|
42
|
+
none: "_1bsbutpp _4t3iutpp",
|
|
43
|
+
compact: "_1bsbpxbi _4t3ipxbi",
|
|
44
|
+
spacious: "_1bsb1ejb _4t3i1ejb"
|
|
95
45
|
};
|
|
96
46
|
var baseSizeMap = {
|
|
97
47
|
core: 16,
|
|
@@ -99,13 +49,28 @@ var baseSizeMap = {
|
|
|
99
49
|
};
|
|
100
50
|
var paddingMap = {
|
|
101
51
|
core: {
|
|
102
|
-
|
|
103
|
-
|
|
52
|
+
medium: {
|
|
53
|
+
none: 0,
|
|
54
|
+
compact: 4,
|
|
55
|
+
spacious: 4
|
|
56
|
+
},
|
|
57
|
+
small: {
|
|
58
|
+
none: 0,
|
|
59
|
+
compact: 2.66,
|
|
60
|
+
spacious: 8
|
|
61
|
+
}
|
|
104
62
|
},
|
|
105
63
|
utility: {
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
64
|
+
medium: {
|
|
65
|
+
none: 0,
|
|
66
|
+
compact: 2,
|
|
67
|
+
spacious: 6
|
|
68
|
+
},
|
|
69
|
+
small: {
|
|
70
|
+
none: 0,
|
|
71
|
+
compact: 2,
|
|
72
|
+
spacious: 6
|
|
73
|
+
}
|
|
109
74
|
}
|
|
110
75
|
};
|
|
111
76
|
|
|
@@ -118,7 +83,7 @@ var paddingMap = {
|
|
|
118
83
|
* - [Code](https://atlaskit.atlassian.com/packages/design-system/icon/docs/custom-icons)
|
|
119
84
|
*/
|
|
120
85
|
var Icon = exports.Icon = /*#__PURE__*/(0, _react.memo)(function Icon(props) {
|
|
121
|
-
var _props$type
|
|
86
|
+
var _props$type;
|
|
122
87
|
var _ref = props,
|
|
123
88
|
_ref$color = _ref.color,
|
|
124
89
|
color = _ref$color === void 0 ? 'currentColor' : _ref$color,
|
|
@@ -130,15 +95,18 @@ var Icon = exports.Icon = /*#__PURE__*/(0, _react.memo)(function Icon(props) {
|
|
|
130
95
|
FallbackIcon = _ref.LEGACY_fallbackIcon,
|
|
131
96
|
dangerouslySetGlyph = _ref.dangerouslySetGlyph,
|
|
132
97
|
shouldScale = _ref.shouldScale,
|
|
133
|
-
LEGACY_margin = _ref.LEGACY_margin
|
|
98
|
+
LEGACY_margin = _ref.LEGACY_margin,
|
|
99
|
+
_ref$spacing = _ref.spacing,
|
|
100
|
+
spacing = _ref$spacing === void 0 ? 'none' : _ref$spacing;
|
|
134
101
|
var dangerouslySetInnerHTML = dangerouslySetGlyph ? {
|
|
135
102
|
__html: dangerouslySetGlyph
|
|
136
103
|
} : undefined;
|
|
137
104
|
|
|
138
105
|
// Fall back to old icon
|
|
106
|
+
// eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
|
|
139
107
|
if (FallbackIcon && !(0, _platformFeatureFlags.fg)('platform-visual-refresh-icons')) {
|
|
140
108
|
// parse out unnecessary props
|
|
141
|
-
return
|
|
109
|
+
return /*#__PURE__*/React.createElement(FallbackIcon, {
|
|
142
110
|
primaryColor: LEGACY_primaryColor !== null && LEGACY_primaryColor !== void 0 ? LEGACY_primaryColor : color,
|
|
143
111
|
secondaryColor: LEGACY_secondaryColor,
|
|
144
112
|
size: LEGACY_size,
|
|
@@ -149,17 +117,16 @@ var Icon = exports.Icon = /*#__PURE__*/(0, _react.memo)(function Icon(props) {
|
|
|
149
117
|
UNSAFE_margin: LEGACY_margin
|
|
150
118
|
});
|
|
151
119
|
}
|
|
152
|
-
var
|
|
153
|
-
var
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
}
|
|
120
|
+
var type = (_props$type = props.type) !== null && _props$type !== void 0 ? _props$type : 'core';
|
|
121
|
+
var size = 'size' in props && props.size !== undefined && (
|
|
122
|
+
// This prevents invalid sizes being passed in, which is required
|
|
123
|
+
// for handling unsupported legacy icon sizes which can
|
|
124
|
+
// cause errors.
|
|
125
|
+
props.size === 'small' || props.size === 'medium') ? props.size : 'medium';
|
|
126
|
+
var baseSize = baseSizeMap[type];
|
|
127
|
+
var viewBoxPadding = paddingMap[type][size][spacing];
|
|
161
128
|
var viewBoxSize = baseSize + 2 * viewBoxPadding;
|
|
162
|
-
return
|
|
129
|
+
return /*#__PURE__*/React.createElement("span", {
|
|
163
130
|
"data-testid": testId,
|
|
164
131
|
role: label ? 'img' : undefined,
|
|
165
132
|
"aria-label": label ? label : undefined,
|
|
@@ -167,16 +134,16 @@ var Icon = exports.Icon = /*#__PURE__*/(0, _react.memo)(function Icon(props) {
|
|
|
167
134
|
style: {
|
|
168
135
|
color: color
|
|
169
136
|
},
|
|
170
|
-
|
|
171
|
-
},
|
|
137
|
+
className: (0, _runtime.ax)(["_1e0c1o8l _vchhusvi _1o9zidpf _vwz4kb7n _y4ti1igz _bozg1mb9", "_12va1onz _jcxd1r8n", shouldScale && "_1bsb1kw7 _4t3i1kw7", (type === 'utility' || size === 'small') && "_vwz4utpp"])
|
|
138
|
+
}, /*#__PURE__*/React.createElement("svg", {
|
|
172
139
|
fill: "none"
|
|
173
140
|
// Adjusting the viewBox allows the icon padding to scale with the contents of the SVG, which
|
|
174
141
|
// we want for Icon Tile
|
|
175
142
|
,
|
|
176
143
|
viewBox: "".concat(0 - viewBoxPadding, " ").concat(0 - viewBoxPadding, " ").concat(viewBoxSize, " ").concat(viewBoxSize),
|
|
177
144
|
role: "presentation",
|
|
178
|
-
|
|
179
|
-
|
|
145
|
+
dangerouslySetInnerHTML: dangerouslySetInnerHTML,
|
|
146
|
+
className: (0, _runtime.ax)(["_1reo15vq _18m915vq _syaz1r31 _lcxvglyw _s7n4yfq0 _vc881r31", shouldScale ? "_1bsb1kw7 _4t3i1kw7" : type === 'utility' ? utilSizes[spacing] : size === 'small' ? coreSizeSmall[spacing] : coreSizeMedium[spacing]])
|
|
180
147
|
}));
|
|
181
148
|
});
|
|
182
149
|
var _default = exports.default = Icon;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
|
|
2
|
+
._2rko14q2{border-radius:var(--ds-border-radius-circle,2002pc)}
|
|
3
|
+
._2rkoiti9{border-radius:var(--ds-border-radius-100,4px)}._1bah1h6o{justify-content:center}
|
|
4
|
+
._1bsb1tcg{width:24px}
|
|
5
|
+
._1bsb1ylp{width:40px}
|
|
6
|
+
._1bsb7vkz{width:1pc}
|
|
7
|
+
._1bsbckbl{width:3pc}
|
|
8
|
+
._1bsbzwfg{width:2pc}
|
|
9
|
+
._1e0c116y{display:inline-flex}
|
|
10
|
+
._1wybidpf{font-size:0}
|
|
11
|
+
._4cvr1h6o{align-items:center}
|
|
12
|
+
._4t3i1tcg{height:24px}
|
|
13
|
+
._4t3i1ylp{height:40px}
|
|
14
|
+
._4t3i7vkz{height:1pc}
|
|
15
|
+
._4t3ickbl{height:3pc}
|
|
16
|
+
._4t3izwfg{height:2pc}
|
|
17
|
+
._bfhk1a17{background-color:var(--ds-background-accent-teal-subtler,#c6edfb)}
|
|
18
|
+
._bfhk1e5c{background-color:var(--ds-background-accent-green-bolder,#1f845a)}
|
|
19
|
+
._bfhk1jkz{background-color:var(--ds-background-accent-purple-subtler,#dfd8fd)}
|
|
20
|
+
._bfhk1rtt{background-color:var(--ds-background-accent-red-subtler,#ffd5d2)}
|
|
21
|
+
._bfhk1t1b{background-color:var(--ds-background-accent-gray-bolder,#626f86)}
|
|
22
|
+
._bfhk1v33{background-color:var(--ds-background-accent-gray-subtler,#dcdfe4)}
|
|
23
|
+
._bfhk1vop{background-color:var(--ds-background-accent-yellow-bolder,#946f00)}
|
|
24
|
+
._bfhk1wnw{background-color:var(--ds-background-accent-green-subtler,#baf3db)}
|
|
25
|
+
._bfhk2c8p{background-color:var(--ds-background-accent-teal-bolder,#227d9b)}
|
|
26
|
+
._bfhk3fv2{background-color:var(--ds-background-accent-yellow-subtler,#f8e6a0)}
|
|
27
|
+
._bfhk4v9p{background-color:var(--ds-background-accent-blue-subtler,#cce0ff)}
|
|
28
|
+
._bfhkc3uk{background-color:var(--ds-background-accent-magenta-bolder,#ae4787)}
|
|
29
|
+
._bfhkc8cv{background-color:var(--ds-background-accent-blue-bolder,#0c66e4)}
|
|
30
|
+
._bfhkf2vu{background-color:var(--ds-background-accent-orange-subtler,#fedec8)}
|
|
31
|
+
._bfhkjgng{background-color:var(--ds-background-accent-orange-bolder,#c25100)}
|
|
32
|
+
._bfhktde4{background-color:var(--ds-background-accent-lime-bolder,#5b7f24)}
|
|
33
|
+
._bfhkuibq{background-color:var(--ds-background-accent-red-bolder,#c9372c)}
|
|
34
|
+
._bfhkv9ra{background-color:var(--ds-background-accent-magenta-subtler,#fdd0ec)}
|
|
35
|
+
._bfhkygwo{background-color:var(--ds-background-accent-purple-bolder,#6e5dc6)}
|
|
36
|
+
._bfhkz2ec{background-color:var(--ds-background-accent-lime-subtler,#d3f1a7)}
|
|
37
|
+
._syaz16ni{color:var(--ds-icon-accent-gray,#758195)}
|
|
38
|
+
._syaz17hp{color:var(--ds-icon-accent-green,#22a06b)}
|
|
39
|
+
._syaz1oqg{color:var(--ds-icon-accent-yellow,#b38600)}
|
|
40
|
+
._syaz1ov1{color:var(--ds-icon-accent-blue,#1d7afc)}
|
|
41
|
+
._syaz5w2r{color:var(--ds-icon-inverse,#fff)}
|
|
42
|
+
._syaz5yjc{color:var(--ds-icon-accent-purple,#8270db)}
|
|
43
|
+
._syaz7r97{color:var(--ds-icon-accent-orange,#e56910)}
|
|
44
|
+
._syaz8645{color:var(--ds-icon-accent-lime,#6a9a23)}
|
|
45
|
+
._syaz8uof{color:var(--ds-icon-accent-teal,#2898bd)}
|
|
46
|
+
._syaznbxb{color:var(--ds-icon-accent-red,#c9372c)}
|
|
47
|
+
._syazv8hk{color:var(--ds-icon-accent-magenta,#cd519d)}
|
|
48
|
+
._vchhusvi{box-sizing:border-box}
|