@atlaskit/smart-card 40.4.1 → 40.4.3

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.
Files changed (56) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/dist/cjs/utils/analytics/analytics.js +1 -1
  3. package/dist/cjs/view/BlockCard/views/ErroredView.js +2 -2
  4. package/dist/cjs/view/EmbedCard/views/ErroredView.js +2 -2
  5. package/dist/cjs/view/EmbedModal/components/link-info/index.js +3 -3
  6. package/dist/cjs/view/FlexibleCard/components/actions/delete-action/index.js +2 -2
  7. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +2 -2
  8. package/dist/cjs/view/FlexibleCard/components/elements/comment-count-element/index.js +3 -9
  9. package/dist/cjs/view/FlexibleCard/components/elements/common/base-badge-element/index.js +1 -2
  10. package/dist/cjs/view/FlexibleCard/components/elements/common/base-date-time-element/index.js +2 -2
  11. package/dist/cjs/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-error/index.js +2 -2
  12. package/dist/cjs/view/FlexibleCard/components/elements/common/base-text-element/index.js +5 -16
  13. package/dist/cjs/view/FlexibleCard/components/elements/modified-on-element/index.js +3 -8
  14. package/dist/cjs/view/FlexibleCard/components/elements/owned-by-element/index.js +3 -8
  15. package/dist/cjs/view/FlexibleCard/components/elements/owned-by-group-element/index.js +3 -8
  16. package/dist/cjs/view/FlexibleCard/components/elements/react-count-element/index.js +3 -8
  17. package/dist/cjs/view/FlexibleCard/external.js +32 -53
  18. package/dist/cjs/view/InlineCard/ErroredView/index.js +2 -2
  19. package/dist/cjs/view/LinkUrl/index.js +1 -1
  20. package/dist/es2019/utils/analytics/analytics.js +1 -1
  21. package/dist/es2019/view/BlockCard/views/ErroredView.js +1 -1
  22. package/dist/es2019/view/EmbedCard/views/ErroredView.js +1 -1
  23. package/dist/es2019/view/EmbedModal/components/link-info/index.js +1 -1
  24. package/dist/es2019/view/FlexibleCard/components/actions/delete-action/index.js +1 -1
  25. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +1 -1
  26. package/dist/es2019/view/FlexibleCard/components/elements/comment-count-element/index.js +3 -9
  27. package/dist/es2019/view/FlexibleCard/components/elements/common/base-badge-element/index.js +1 -2
  28. package/dist/es2019/view/FlexibleCard/components/elements/common/base-date-time-element/index.js +2 -2
  29. package/dist/es2019/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-error/index.js +1 -1
  30. package/dist/es2019/view/FlexibleCard/components/elements/common/base-text-element/index.js +5 -16
  31. package/dist/es2019/view/FlexibleCard/components/elements/modified-on-element/index.js +3 -8
  32. package/dist/es2019/view/FlexibleCard/components/elements/owned-by-element/index.js +3 -8
  33. package/dist/es2019/view/FlexibleCard/components/elements/owned-by-group-element/index.js +3 -8
  34. package/dist/es2019/view/FlexibleCard/components/elements/react-count-element/index.js +3 -8
  35. package/dist/es2019/view/FlexibleCard/external.js +32 -53
  36. package/dist/es2019/view/InlineCard/ErroredView/index.js +1 -1
  37. package/dist/es2019/view/LinkUrl/index.js +1 -1
  38. package/dist/esm/utils/analytics/analytics.js +1 -1
  39. package/dist/esm/view/BlockCard/views/ErroredView.js +1 -1
  40. package/dist/esm/view/EmbedCard/views/ErroredView.js +1 -1
  41. package/dist/esm/view/EmbedModal/components/link-info/index.js +1 -1
  42. package/dist/esm/view/FlexibleCard/components/actions/delete-action/index.js +1 -1
  43. package/dist/esm/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +1 -1
  44. package/dist/esm/view/FlexibleCard/components/elements/comment-count-element/index.js +3 -9
  45. package/dist/esm/view/FlexibleCard/components/elements/common/base-badge-element/index.js +1 -2
  46. package/dist/esm/view/FlexibleCard/components/elements/common/base-date-time-element/index.js +2 -2
  47. package/dist/esm/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-error/index.js +1 -1
  48. package/dist/esm/view/FlexibleCard/components/elements/common/base-text-element/index.js +5 -16
  49. package/dist/esm/view/FlexibleCard/components/elements/modified-on-element/index.js +3 -8
  50. package/dist/esm/view/FlexibleCard/components/elements/owned-by-element/index.js +3 -8
  51. package/dist/esm/view/FlexibleCard/components/elements/owned-by-group-element/index.js +3 -8
  52. package/dist/esm/view/FlexibleCard/components/elements/react-count-element/index.js +3 -8
  53. package/dist/esm/view/FlexibleCard/external.js +32 -53
  54. package/dist/esm/view/InlineCard/ErroredView/index.js +1 -1
  55. package/dist/esm/view/LinkUrl/index.js +1 -1
  56. package/package.json +2 -5
@@ -75,7 +75,7 @@ const BaseDateTimeElement = ({
75
75
  });
76
76
  }
77
77
  let content;
78
- if (hideDatePrefix && fg('platform-linking-additional-flexible-element-props')) {
78
+ if (hideDatePrefix) {
79
79
  content = context;
80
80
  } else if (text) {
81
81
  content = `${text} ${context}`;
@@ -88,7 +88,7 @@ const BaseDateTimeElement = ({
88
88
  }
89
89
  return /*#__PURE__*/React.createElement("span", {
90
90
  style: {
91
- color: color && fg('platform-linking-additional-flexible-element-props') ? color : undefined
91
+ color
92
92
  },
93
93
  "data-separator": true,
94
94
  "data-smart-element": name,
@@ -5,7 +5,7 @@ import { ax, ix } from "@compiled/react/runtime";
5
5
  import { Fragment, useCallback, useMemo } from 'react';
6
6
  import { FormattedMessage } from 'react-intl-next';
7
7
  import { DropdownItem, DropdownItemGroup } from '@atlaskit/dropdown-menu';
8
- import ErrorIcon from '@atlaskit/icon/core/migration/error';
8
+ import ErrorIcon from '@atlaskit/icon/core/migration/status-error--error';
9
9
  import { fg } from '@atlaskit/platform-feature-flags';
10
10
  import { N800, R50, R500 } from '@atlaskit/theme/colors';
11
11
  import { useAnalyticsEvents } from '../../../../../../../../common/analytics/generated/use-analytics-events';
@@ -32,8 +32,7 @@ export const BaseTextElement = ({
32
32
  return null;
33
33
  }
34
34
  const dynamicCss = null;
35
- const newContent = hideFormat && content ? content : getFormattedMessage(message) || content;
36
- const oldContent = getFormattedMessage(message) || content;
35
+ const formattedContent = hideFormat && content ? content : getFormattedMessage(message) || content;
37
36
  return /*#__PURE__*/React.createElement("span", {
38
37
  "data-separator": true,
39
38
  "data-smart-element": name,
@@ -43,31 +42,21 @@ export const BaseTextElement = ({
43
42
  ,
44
43
  className: ax(["_11c81o8v _1reo15vq _18m915vq _syaz1gjq _o5724jg8 _1e0ccj1k _1ul9idpf _1bto1l2s _1nmz1hna _sudp1e54", fontSize !== undefined && fg('bandicoots-smart-card-teamwork-context') && fontOverrideStyleMap[fontSize], "_1yyjr31u _102k1dud", className]),
45
44
  style: {
46
- color: color && fg('platform-linking-additional-flexible-element-props') ? color : undefined,
45
+ color,
47
46
  "--_1erfju8": ix(maxLines)
48
47
  }
49
- }, fg('platform-linking-additional-flexible-element-props') ? newContent : oldContent);
48
+ }, formattedContent);
50
49
  };
51
50
  export default BaseTextElement;
52
51
  export const toFormattedTextProps = (descriptor, context) => {
53
- if (fg('platform-linking-additional-flexible-element-props')) {
54
- return context ? {
55
- message: {
56
- descriptor,
57
- values: {
58
- context
59
- }
60
- },
61
- content: context
62
- } : undefined;
63
- }
64
52
  return context ? {
65
53
  message: {
66
54
  descriptor,
67
55
  values: {
68
56
  context
69
57
  }
70
- }
58
+ },
59
+ content: context
71
60
  } : undefined;
72
61
  };
73
62
  export const toTextProps = content => {
@@ -1,6 +1,5 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import React, { useEffect } from 'react';
3
- import { fg } from '@atlaskit/platform-feature-flags';
4
3
  import { ElementName } from '../../../../../constants';
5
4
  import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
6
5
  import { BaseDateTimeElement, toDateTimeProps } from '../common';
@@ -11,13 +10,9 @@ const ModifiedOnElement = props => {
11
10
  onRender,
12
11
  ...restProps
13
12
  } = props || {};
14
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
15
- if (fg('platform-linking-additional-flexible-element-props')) {
16
- // eslint-disable-next-line react-hooks/rules-of-hooks
17
- useEffect(() => {
18
- onRender === null || onRender === void 0 ? void 0 : onRender(!!data);
19
- }, [data, onRender]);
20
- }
13
+ useEffect(() => {
14
+ onRender === null || onRender === void 0 ? void 0 : onRender(!!data);
15
+ }, [data, onRender]);
21
16
  return data ? /*#__PURE__*/React.createElement(BaseDateTimeElement, _extends({}, data, restProps, {
22
17
  name: ElementName.ModifiedOn
23
18
  })) : null;
@@ -13,14 +13,9 @@ const OwnedByElement = props => {
13
13
  ...restProps
14
14
  } = props || {};
15
15
  const data = context ? toFormattedTextProps(fg('bandicoots-smart-card-teamwork-context') ? messages[textPrefix] : messages.owned_by, context === null || context === void 0 ? void 0 : context.ownedBy) : null;
16
-
17
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
18
- if (fg('platform-linking-additional-flexible-element-props')) {
19
- // eslint-disable-next-line react-hooks/rules-of-hooks
20
- useEffect(() => {
21
- onRender === null || onRender === void 0 ? void 0 : onRender(!!data);
22
- }, [data, onRender]);
23
- }
16
+ useEffect(() => {
17
+ onRender === null || onRender === void 0 ? void 0 : onRender(!!data);
18
+ }, [data, onRender]);
24
19
  return data ? /*#__PURE__*/React.createElement(BaseTextElement, _extends({}, data, restProps, {
25
20
  name: ElementName.OwnedBy
26
21
  })) : null;
@@ -1,6 +1,5 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import React, { useEffect } from 'react';
3
- import { fg } from '@atlaskit/platform-feature-flags';
4
3
  import { ElementName } from '../../../../../constants';
5
4
  import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
6
5
  import { BaseAvatarGroupElement, toAvatarGroupProps } from '../common';
@@ -11,13 +10,9 @@ const OwnedByGroupElement = props => {
11
10
  onRender,
12
11
  ...restProps
13
12
  } = props || {};
14
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
15
- if (fg('platform-linking-additional-flexible-element-props')) {
16
- // eslint-disable-next-line react-hooks/rules-of-hooks
17
- useEffect(() => {
18
- onRender === null || onRender === void 0 ? void 0 : onRender(!!data);
19
- }, [data, onRender]);
20
- }
13
+ useEffect(() => {
14
+ onRender === null || onRender === void 0 ? void 0 : onRender(!!data);
15
+ }, [data, onRender]);
21
16
  return data ? /*#__PURE__*/React.createElement(BaseAvatarGroupElement, _extends({}, data, restProps, {
22
17
  name: ElementName.OwnedByGroup
23
18
  })) : null;
@@ -1,6 +1,5 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import React, { useEffect } from 'react';
3
- import { fg } from '@atlaskit/platform-feature-flags';
4
3
  import { ElementName, IconType } from '../../../../../constants';
5
4
  import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
6
5
  import { BaseBadgeElement, toBadgeProps } from '../common';
@@ -12,13 +11,9 @@ const ReactCountElement = props => {
12
11
  onRender,
13
12
  ...restProps
14
13
  } = props || {};
15
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
16
- if (fg('platform-linking-additional-flexible-element-props')) {
17
- // eslint-disable-next-line react-hooks/rules-of-hooks
18
- useEffect(() => {
19
- onRender === null || onRender === void 0 ? void 0 : onRender(!!data);
20
- }, [data, onRender]);
21
- }
14
+ useEffect(() => {
15
+ onRender === null || onRender === void 0 ? void 0 : onRender(!!data);
16
+ }, [data, onRender]);
22
17
  return data ? /*#__PURE__*/React.createElement(BaseBadgeElement, _extends({
23
18
  icon: IconType.React
24
19
  }, data, restProps, {
@@ -21,80 +21,59 @@ export const AuthorGroupElement = () => /*#__PURE__*/React.createElement(AuthorG
21
21
  export const ChecklistProgressElement = () => /*#__PURE__*/React.createElement(ChecklistProgress, null);
22
22
  export const CollaboratorGroupElement = () => /*#__PURE__*/React.createElement(CollaboratorGroup, null);
23
23
  export const CommentCountElement = props => {
24
- if (fg('platform-linking-additional-flexible-element-props')) {
25
- return /*#__PURE__*/React.createElement(CommentCount, {
26
- color: props === null || props === void 0 ? void 0 : props.color,
27
- onRender: props === null || props === void 0 ? void 0 : props.onRender
28
- });
29
- }
30
- return /*#__PURE__*/React.createElement(CommentCount, null);
24
+ return /*#__PURE__*/React.createElement(CommentCount, {
25
+ color: props === null || props === void 0 ? void 0 : props.color,
26
+ onRender: props === null || props === void 0 ? void 0 : props.onRender
27
+ });
31
28
  };
32
29
  export const CreatedOnElement = () => /*#__PURE__*/React.createElement(CreatedOn, null);
33
30
  export const CreatedByElement = () => /*#__PURE__*/React.createElement(CreatedBy, null);
34
31
  export const DueOnElement = () => /*#__PURE__*/React.createElement(DueOn, null);
35
32
  export const LatestCommitElement = () => /*#__PURE__*/React.createElement(LatestCommit, null);
36
33
  export const LinkIconElement = props => {
37
- if (fg('platform-linking-additional-flexible-element-props')) {
38
- return /*#__PURE__*/React.createElement(LinkIcon, {
39
- size: (props === null || props === void 0 ? void 0 : props.iconTileSize) === 24 ? SmartLinkSize.Large : SmartLinkSize.Medium,
40
- render: props === null || props === void 0 ? void 0 : props.render
41
- });
42
- }
43
- return /*#__PURE__*/React.createElement(LinkIcon, null);
34
+ return /*#__PURE__*/React.createElement(LinkIcon, {
35
+ size: (props === null || props === void 0 ? void 0 : props.iconTileSize) === 24 ? SmartLinkSize.Large : SmartLinkSize.Medium,
36
+ render: props === null || props === void 0 ? void 0 : props.render
37
+ });
44
38
  };
45
39
  export const LocationElement = () => /*#__PURE__*/React.createElement(Location, null);
46
40
  export const ModifiedByElement = () => /*#__PURE__*/React.createElement(ModifiedBy, null);
47
41
  export const ModifiedOnElement = props => {
48
- if (fg('platform-linking-additional-flexible-element-props')) {
49
- return /*#__PURE__*/React.createElement(ModifiedOn, {
50
- hideDatePrefix: props === null || props === void 0 ? void 0 : props.hideDatePrefix,
51
- color: props === null || props === void 0 ? void 0 : props.color,
52
- onRender: props === null || props === void 0 ? void 0 : props.onRender,
53
- fontSize: props === null || props === void 0 ? void 0 : props.fontSize
54
- });
55
- }
56
- return /*#__PURE__*/React.createElement(ModifiedOn, null);
42
+ return /*#__PURE__*/React.createElement(ModifiedOn, {
43
+ hideDatePrefix: props === null || props === void 0 ? void 0 : props.hideDatePrefix,
44
+ color: props === null || props === void 0 ? void 0 : props.color,
45
+ onRender: props === null || props === void 0 ? void 0 : props.onRender,
46
+ fontSize: props === null || props === void 0 ? void 0 : props.fontSize
47
+ });
57
48
  };
58
49
  export const OwnedByElement = props => {
59
- if (fg('platform-linking-additional-flexible-element-props')) {
60
- return /*#__PURE__*/React.createElement(OwnedBy, _extends({
61
- hideFormat: props === null || props === void 0 ? void 0 : props.hideFormat,
62
- color: props === null || props === void 0 ? void 0 : props.color,
63
- onRender: props === null || props === void 0 ? void 0 : props.onRender
64
- }, fg('bandicoots-smart-card-teamwork-context') ? {
65
- textPrefix: props === null || props === void 0 ? void 0 : props.textPrefix,
66
- fontSize: props === null || props === void 0 ? void 0 : props.fontSize
67
- } : undefined));
68
- }
69
- return /*#__PURE__*/React.createElement(OwnedBy, null);
50
+ return /*#__PURE__*/React.createElement(OwnedBy, _extends({
51
+ hideFormat: props === null || props === void 0 ? void 0 : props.hideFormat,
52
+ color: props === null || props === void 0 ? void 0 : props.color,
53
+ onRender: props === null || props === void 0 ? void 0 : props.onRender
54
+ }, fg('bandicoots-smart-card-teamwork-context') ? {
55
+ textPrefix: props === null || props === void 0 ? void 0 : props.textPrefix,
56
+ fontSize: props === null || props === void 0 ? void 0 : props.fontSize
57
+ } : undefined));
70
58
  };
71
59
  export const OwnedByGroupElement = props => {
72
- if (fg('platform-linking-additional-flexible-element-props')) {
73
- return /*#__PURE__*/React.createElement(OwnedByGroup, {
74
- onRender: props === null || props === void 0 ? void 0 : props.onRender
75
- });
76
- }
77
- return /*#__PURE__*/React.createElement(OwnedByGroup, null);
60
+ return /*#__PURE__*/React.createElement(OwnedByGroup, {
61
+ onRender: props === null || props === void 0 ? void 0 : props.onRender
62
+ });
78
63
  };
79
64
  export const PreviewElement = props => {
80
- if (fg('platform-linking-additional-flexible-element-props')) {
81
- return /*#__PURE__*/React.createElement(Preview, {
82
- overrideUrl: props === null || props === void 0 ? void 0 : props.url
83
- });
84
- }
85
- return /*#__PURE__*/React.createElement(Preview, null);
65
+ return /*#__PURE__*/React.createElement(Preview, {
66
+ overrideUrl: props === null || props === void 0 ? void 0 : props.url
67
+ });
86
68
  };
87
69
  export const PriorityElement = () => /*#__PURE__*/React.createElement(Priority, null);
88
70
  export const ProgrammingLanguageElement = () => /*#__PURE__*/React.createElement(ProgrammingLanguage, null);
89
71
  export const ProviderElement = () => /*#__PURE__*/React.createElement(Provider, null);
90
72
  export const ReactCountElement = props => {
91
- if (fg('platform-linking-additional-flexible-element-props')) {
92
- return /*#__PURE__*/React.createElement(ReactCount, {
93
- color: props === null || props === void 0 ? void 0 : props.color,
94
- onRender: props === null || props === void 0 ? void 0 : props.onRender
95
- });
96
- }
97
- return /*#__PURE__*/React.createElement(ReactCount, null);
73
+ return /*#__PURE__*/React.createElement(ReactCount, {
74
+ color: props === null || props === void 0 ? void 0 : props.color,
75
+ onRender: props === null || props === void 0 ? void 0 : props.onRender
76
+ });
98
77
  };
99
78
  export const ReadTimeElement = () => /*#__PURE__*/React.createElement(ReadTime, null);
100
79
  export const SentOnElement = () => /*#__PURE__*/React.createElement(SentOn, null);
@@ -2,7 +2,7 @@
2
2
  import { ax, ix } from "@compiled/react/runtime";
3
3
  import React from 'react';
4
4
  import { FormattedMessage } from 'react-intl-next';
5
- import ErrorIcon from '@atlaskit/icon/core/migration/error';
5
+ import ErrorIcon from '@atlaskit/icon/core/migration/status-error--error';
6
6
  import { messages } from '../../../messages';
7
7
  import { HoverCard } from '../../HoverCard';
8
8
  import { ActionButton } from '../common/action-button';
@@ -10,7 +10,7 @@ import LinkWarningModal from './LinkWarningModal';
10
10
  import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
11
11
  const PACKAGE_DATA = {
12
12
  packageName: "@atlaskit/smart-card",
13
- packageVersion: "40.4.0",
13
+ packageVersion: "40.4.2",
14
14
  componentName: 'linkUrl'
15
15
  };
16
16
  const Anchor = withLinkClickedEvent('a');
@@ -4,7 +4,7 @@ export var ANALYTICS_CHANNEL = 'media';
4
4
  export var context = {
5
5
  componentName: 'smart-cards',
6
6
  packageName: "@atlaskit/smart-card",
7
- packageVersion: "40.4.0"
7
+ packageVersion: "40.4.2"
8
8
  };
9
9
  export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
10
10
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
3
  var _excluded = ["testId"];
4
4
  import React, { useMemo } from 'react';
5
- import WarningIcon from '@atlaskit/icon/core/migration/warning';
5
+ import WarningIcon from '@atlaskit/icon/core/migration/status-warning--warning';
6
6
  import { messages } from '../../../messages';
7
7
  import Text from '../../FlexibleCard/components/elements/common/base-text-element';
8
8
  import { RetryAction } from '../actions/RetryAction';
@@ -5,7 +5,7 @@ import { ax, ix } from "@compiled/react/runtime";
5
5
  import { FormattedMessage } from 'react-intl-next';
6
6
  import ButtonOld from '@atlaskit/button';
7
7
  import Button from '@atlaskit/button/new';
8
- import ErrorIcon from '@atlaskit/icon/core/migration/error';
8
+ import ErrorIcon from '@atlaskit/icon/core/migration/status-error--error';
9
9
  import { fg } from '@atlaskit/platform-feature-flags';
10
10
  import { Box, Inline } from '@atlaskit/primitives/compiled';
11
11
  import { R300 } from '@atlaskit/theme/colors';
@@ -6,7 +6,7 @@ import { FormattedMessage } from 'react-intl-next';
6
6
  import Heading from '@atlaskit/heading';
7
7
  import DownloadIcon from '@atlaskit/icon/core/download';
8
8
  import FullscreenExitIcon from '@atlaskit/icon/core/fullscreen-exit';
9
- import CrossIcon from '@atlaskit/icon/core/migration/close--cross';
9
+ import CrossIcon from '@atlaskit/icon/core/migration/cross';
10
10
  import VidFullScreenOnIcon from '@atlaskit/icon/core/migration/fullscreen-enter--vid-full-screen-on';
11
11
  import ShortcutIcon from '@atlaskit/icon/core/migration/link-external--shortcut';
12
12
  import DownloadIconLegacy from '@atlaskit/icon/glyph/download';
@@ -1,7 +1,7 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import React from 'react';
3
3
  import { FormattedMessage } from 'react-intl-next';
4
- import CrossIcon from '@atlaskit/icon/core/migration/close--cross';
4
+ import CrossIcon from '@atlaskit/icon/core/migration/cross';
5
5
  import { messages } from '../../../../../messages';
6
6
  import Action from '../action';
7
7
  var DeleteAction = function DeleteAction(props) {
@@ -2,7 +2,7 @@
2
2
  import "./index.compiled.css";
3
3
  import * as React from 'react';
4
4
  import { ax, ix } from "@compiled/react/runtime";
5
- import ErrorIcon from '@atlaskit/icon/core/migration/error';
5
+ import ErrorIcon from '@atlaskit/icon/core/migration/status-error--error';
6
6
  import { Box, Inline } from '@atlaskit/primitives/compiled';
7
7
  import MotionWrapper from '../../../common/motion-wrapper';
8
8
  var styles = {
@@ -2,7 +2,6 @@ import _extends from "@babel/runtime/helpers/extends";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
3
  var _excluded = ["onRender"];
4
4
  import React, { useEffect } from 'react';
5
- import { fg } from '@atlaskit/platform-feature-flags';
6
5
  import { ElementName, IconType } from '../../../../../constants';
7
6
  import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
8
7
  import { BaseBadgeElement, toBadgeProps } from '../common';
@@ -13,14 +12,9 @@ var CommentCountElement = function CommentCountElement(props) {
13
12
  var _ref = props || {},
14
13
  onRender = _ref.onRender,
15
14
  restProps = _objectWithoutProperties(_ref, _excluded);
16
-
17
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
18
- if (fg('platform-linking-additional-flexible-element-props')) {
19
- // eslint-disable-next-line react-hooks/rules-of-hooks
20
- useEffect(function () {
21
- onRender === null || onRender === void 0 || onRender(!!data);
22
- }, [data, onRender]);
23
- }
15
+ useEffect(function () {
16
+ onRender === null || onRender === void 0 || onRender(!!data);
17
+ }, [data, onRender]);
24
18
  return data ? /*#__PURE__*/React.createElement(BaseBadgeElement, _extends({
25
19
  icon: IconType.Comment
26
20
  }, data, restProps, {
@@ -6,7 +6,6 @@ import { ax, ix } from "@compiled/react/runtime";
6
6
  /* eslint-disable @atlaskit/design-system/use-tokens-typography */
7
7
 
8
8
  import React, { forwardRef } from 'react';
9
- import { fg } from '@atlaskit/platform-feature-flags';
10
9
  import { Box } from '@atlaskit/primitives/compiled';
11
10
  import { IconType } from '../../../../../../constants';
12
11
  import { messages } from '../../../../../../messages';
@@ -87,7 +86,7 @@ var BaseBadgeRefreshNew = /*#__PURE__*/forwardRef(function (_ref, ref) {
87
86
  "data-testid": testId,
88
87
  ref: ref,
89
88
  style: {
90
- color: color && fg('platform-linking-additional-flexible-element-props') ? color : undefined
89
+ color: color
91
90
  },
92
91
  className: ax([styles.container, colorMap[appearance]])
93
92
  }, !hideIcon && /*#__PURE__*/React.createElement(Box, {
@@ -74,7 +74,7 @@ var BaseDateTimeElement = function BaseDateTimeElement(_ref) {
74
74
  });
75
75
  }
76
76
  var content;
77
- if (hideDatePrefix && fg('platform-linking-additional-flexible-element-props')) {
77
+ if (hideDatePrefix) {
78
78
  content = context;
79
79
  } else if (text) {
80
80
  content = "".concat(text, " ").concat(context);
@@ -87,7 +87,7 @@ var BaseDateTimeElement = function BaseDateTimeElement(_ref) {
87
87
  }
88
88
  return /*#__PURE__*/React.createElement("span", {
89
89
  style: {
90
- color: color && fg('platform-linking-additional-flexible-element-props') ? color : undefined
90
+ color: color
91
91
  },
92
92
  "data-separator": true,
93
93
  "data-smart-element": name,
@@ -5,7 +5,7 @@ import { ax, ix } from "@compiled/react/runtime";
5
5
  import { Fragment, useCallback, useMemo } from 'react';
6
6
  import { FormattedMessage } from 'react-intl-next';
7
7
  import { DropdownItem, DropdownItemGroup } from '@atlaskit/dropdown-menu';
8
- import ErrorIcon from '@atlaskit/icon/core/migration/error';
8
+ import ErrorIcon from '@atlaskit/icon/core/migration/status-error--error';
9
9
  import { fg } from '@atlaskit/platform-feature-flags';
10
10
  import { N800, R50, R500 } from '@atlaskit/theme/colors';
11
11
  import { useAnalyticsEvents } from '../../../../../../../../common/analytics/generated/use-analytics-events';
@@ -34,8 +34,7 @@ export var BaseTextElement = function BaseTextElement(_ref) {
34
34
  return null;
35
35
  }
36
36
  var dynamicCss = null;
37
- var newContent = hideFormat && content ? content : getFormattedMessage(message) || content;
38
- var oldContent = getFormattedMessage(message) || content;
37
+ var formattedContent = hideFormat && content ? content : getFormattedMessage(message) || content;
39
38
  return /*#__PURE__*/React.createElement("span", {
40
39
  "data-separator": true,
41
40
  "data-smart-element": name,
@@ -45,32 +44,22 @@ export var BaseTextElement = function BaseTextElement(_ref) {
45
44
  ,
46
45
  className: ax(["_11c81o8v _1reo15vq _18m915vq _syaz1gjq _o5724jg8 _1e0ccj1k _1ul9idpf _1bto1l2s _1nmz1hna _sudp1e54", fontSize !== undefined && fg('bandicoots-smart-card-teamwork-context') && fontOverrideStyleMap[fontSize], "_1yyjr31u _102klxil", className]),
47
46
  style: {
48
- color: color && fg('platform-linking-additional-flexible-element-props') ? color : undefined,
47
+ color: color,
49
48
  "--_1erfju8": ix(maxLines),
50
49
  "--_ohw86c": ix("calc(".concat(maxLines, " * 1rem)"))
51
50
  }
52
- }, fg('platform-linking-additional-flexible-element-props') ? newContent : oldContent);
51
+ }, formattedContent);
53
52
  };
54
53
  export default BaseTextElement;
55
54
  export var toFormattedTextProps = function toFormattedTextProps(descriptor, context) {
56
- if (fg('platform-linking-additional-flexible-element-props')) {
57
- return context ? {
58
- message: {
59
- descriptor: descriptor,
60
- values: {
61
- context: context
62
- }
63
- },
64
- content: context
65
- } : undefined;
66
- }
67
55
  return context ? {
68
56
  message: {
69
57
  descriptor: descriptor,
70
58
  values: {
71
59
  context: context
72
60
  }
73
- }
61
+ },
62
+ content: context
74
63
  } : undefined;
75
64
  };
76
65
  export var toTextProps = function toTextProps(content) {
@@ -2,7 +2,6 @@ import _extends from "@babel/runtime/helpers/extends";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
3
  var _excluded = ["onRender"];
4
4
  import React, { useEffect } from 'react';
5
- import { fg } from '@atlaskit/platform-feature-flags';
6
5
  import { ElementName } from '../../../../../constants';
7
6
  import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
8
7
  import { BaseDateTimeElement, toDateTimeProps } from '../common';
@@ -12,13 +11,9 @@ var ModifiedOnElement = function ModifiedOnElement(props) {
12
11
  var _ref = props || {},
13
12
  onRender = _ref.onRender,
14
13
  restProps = _objectWithoutProperties(_ref, _excluded);
15
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
16
- if (fg('platform-linking-additional-flexible-element-props')) {
17
- // eslint-disable-next-line react-hooks/rules-of-hooks
18
- useEffect(function () {
19
- onRender === null || onRender === void 0 || onRender(!!data);
20
- }, [data, onRender]);
21
- }
14
+ useEffect(function () {
15
+ onRender === null || onRender === void 0 || onRender(!!data);
16
+ }, [data, onRender]);
22
17
  return data ? /*#__PURE__*/React.createElement(BaseDateTimeElement, _extends({}, data, restProps, {
23
18
  name: ElementName.ModifiedOn
24
19
  })) : null;
@@ -15,14 +15,9 @@ var OwnedByElement = function OwnedByElement(props) {
15
15
  textPrefix = _ref$textPrefix === void 0 ? 'owned_by' : _ref$textPrefix,
16
16
  restProps = _objectWithoutProperties(_ref, _excluded);
17
17
  var data = context ? toFormattedTextProps(fg('bandicoots-smart-card-teamwork-context') ? messages[textPrefix] : messages.owned_by, context === null || context === void 0 ? void 0 : context.ownedBy) : null;
18
-
19
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
20
- if (fg('platform-linking-additional-flexible-element-props')) {
21
- // eslint-disable-next-line react-hooks/rules-of-hooks
22
- useEffect(function () {
23
- onRender === null || onRender === void 0 || onRender(!!data);
24
- }, [data, onRender]);
25
- }
18
+ useEffect(function () {
19
+ onRender === null || onRender === void 0 || onRender(!!data);
20
+ }, [data, onRender]);
26
21
  return data ? /*#__PURE__*/React.createElement(BaseTextElement, _extends({}, data, restProps, {
27
22
  name: ElementName.OwnedBy
28
23
  })) : null;
@@ -2,7 +2,6 @@ import _extends from "@babel/runtime/helpers/extends";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
3
  var _excluded = ["onRender"];
4
4
  import React, { useEffect } from 'react';
5
- import { fg } from '@atlaskit/platform-feature-flags';
6
5
  import { ElementName } from '../../../../../constants';
7
6
  import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
8
7
  import { BaseAvatarGroupElement, toAvatarGroupProps } from '../common';
@@ -12,13 +11,9 @@ var OwnedByGroupElement = function OwnedByGroupElement(props) {
12
11
  var _ref = props || {},
13
12
  onRender = _ref.onRender,
14
13
  restProps = _objectWithoutProperties(_ref, _excluded);
15
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
16
- if (fg('platform-linking-additional-flexible-element-props')) {
17
- // eslint-disable-next-line react-hooks/rules-of-hooks
18
- useEffect(function () {
19
- onRender === null || onRender === void 0 || onRender(!!data);
20
- }, [data, onRender]);
21
- }
14
+ useEffect(function () {
15
+ onRender === null || onRender === void 0 || onRender(!!data);
16
+ }, [data, onRender]);
22
17
  return data ? /*#__PURE__*/React.createElement(BaseAvatarGroupElement, _extends({}, data, restProps, {
23
18
  name: ElementName.OwnedByGroup
24
19
  })) : null;
@@ -2,7 +2,6 @@ import _extends from "@babel/runtime/helpers/extends";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
3
  var _excluded = ["onRender"];
4
4
  import React, { useEffect } from 'react';
5
- import { fg } from '@atlaskit/platform-feature-flags';
6
5
  import { ElementName, IconType } from '../../../../../constants';
7
6
  import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
8
7
  import { BaseBadgeElement, toBadgeProps } from '../common';
@@ -13,13 +12,9 @@ var ReactCountElement = function ReactCountElement(props) {
13
12
  var _ref = props || {},
14
13
  onRender = _ref.onRender,
15
14
  restProps = _objectWithoutProperties(_ref, _excluded);
16
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
17
- if (fg('platform-linking-additional-flexible-element-props')) {
18
- // eslint-disable-next-line react-hooks/rules-of-hooks
19
- useEffect(function () {
20
- onRender === null || onRender === void 0 || onRender(!!data);
21
- }, [data, onRender]);
22
- }
15
+ useEffect(function () {
16
+ onRender === null || onRender === void 0 || onRender(!!data);
17
+ }, [data, onRender]);
23
18
  return data ? /*#__PURE__*/React.createElement(BaseBadgeElement, _extends({
24
19
  icon: IconType.React
25
20
  }, data, restProps, {