@atlaskit/smart-card 26.35.3 → 26.36.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 +6 -0
- package/dist/cjs/utils/analytics/analytics.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/blocks/title-block/resolved/index.js +4 -2
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/view/FlexibleCard/components/blocks/title-block/resolved/index.js +2 -1
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/esm/utils/analytics/analytics.js +1 -1
- package/dist/esm/view/FlexibleCard/components/blocks/title-block/resolved/index.js +4 -2
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/types/view/FlexibleCard/components/blocks/title-block/types.d.ts +4 -0
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/title-block/types.d.ts +4 -0
- package/package.json +1 -1
- package/report.api.md +1 -0
- package/tmp/api-report-tmp.d.ts +1 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @atlaskit/smart-card
|
|
2
2
|
|
|
3
|
+
## 26.36.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#41842](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/41842) [`228a14ec749`](https://bitbucket.org/atlassian/atlassian-frontend/commits/228a14ec749) - [ux] Add hideIcon param which allows us to hide the Link Icon in Title Block
|
|
8
|
+
|
|
3
9
|
## 26.35.3
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
|
@@ -22,7 +22,7 @@ var ANALYTICS_CHANNEL = exports.ANALYTICS_CHANNEL = 'media';
|
|
|
22
22
|
var context = exports.context = {
|
|
23
23
|
componentName: 'smart-cards',
|
|
24
24
|
packageName: "@atlaskit/smart-card",
|
|
25
|
-
packageVersion: "26.
|
|
25
|
+
packageVersion: "26.36.0"
|
|
26
26
|
};
|
|
27
27
|
var TrackQuickActionType = exports.TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
28
28
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -16,7 +16,7 @@ var _elementGroup = _interopRequireDefault(require("../../element-group"));
|
|
|
16
16
|
var _constants = require("../../../../../../constants");
|
|
17
17
|
var _utils = require("../../utils");
|
|
18
18
|
var _templateObject;
|
|
19
|
-
var _excluded = ["actionGroup", "metadata", "position", "subtitle", "testId", "text", "title", "metadataPosition"];
|
|
19
|
+
var _excluded = ["actionGroup", "metadata", "position", "subtitle", "testId", "text", "title", "metadataPosition", "hideIcon"];
|
|
20
20
|
/**
|
|
21
21
|
* This renders a fully resolved TitleBlock.
|
|
22
22
|
* This should render when a Smart Link returns a valid response.
|
|
@@ -33,12 +33,14 @@ var TitleBlockResolvedView = function TitleBlockResolvedView(_ref) {
|
|
|
33
33
|
text = _ref.text,
|
|
34
34
|
title = _ref.title,
|
|
35
35
|
metadataPosition = _ref.metadataPosition,
|
|
36
|
+
_ref$hideIcon = _ref.hideIcon,
|
|
37
|
+
hideIcon = _ref$hideIcon === void 0 ? false : _ref$hideIcon,
|
|
36
38
|
blockProps = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
37
39
|
var metadataElements = (0, _utils.renderElementItems)(metadata);
|
|
38
40
|
var subtitleElements = (0, _utils.renderElementItems)(subtitle);
|
|
39
41
|
return /*#__PURE__*/_react.default.createElement(_block.default, (0, _extends2.default)({}, blockProps, {
|
|
40
42
|
testId: "".concat(testId, "-resolved-view")
|
|
41
|
-
}), /*#__PURE__*/_react.default.createElement(_elements.LinkIcon, {
|
|
43
|
+
}), !hideIcon && /*#__PURE__*/_react.default.createElement(_elements.LinkIcon, {
|
|
42
44
|
position: position
|
|
43
45
|
}), /*#__PURE__*/_react.default.createElement(_elementGroup.default, {
|
|
44
46
|
direction: _constants.SmartLinkDirection.Vertical,
|
|
@@ -18,7 +18,7 @@ var _excluded = ["href", "children", "checkSafety", "onClick", "testId"],
|
|
|
18
18
|
_excluded2 = ["isLinkSafe", "showSafetyWarningModal"];
|
|
19
19
|
var PACKAGE_DATA = {
|
|
20
20
|
packageName: "@atlaskit/smart-card",
|
|
21
|
-
packageVersion: "26.
|
|
21
|
+
packageVersion: "26.36.0",
|
|
22
22
|
componentName: 'linkUrl'
|
|
23
23
|
};
|
|
24
24
|
var Link = (0, _click.withLinkClickedEvent)('a');
|
|
@@ -4,7 +4,7 @@ export const ANALYTICS_CHANNEL = 'media';
|
|
|
4
4
|
export const context = {
|
|
5
5
|
componentName: 'smart-cards',
|
|
6
6
|
packageName: "@atlaskit/smart-card",
|
|
7
|
-
packageVersion: "26.
|
|
7
|
+
packageVersion: "26.36.0"
|
|
8
8
|
};
|
|
9
9
|
export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
10
10
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -21,13 +21,14 @@ const TitleBlockResolvedView = ({
|
|
|
21
21
|
text,
|
|
22
22
|
title,
|
|
23
23
|
metadataPosition,
|
|
24
|
+
hideIcon = false,
|
|
24
25
|
...blockProps
|
|
25
26
|
}) => {
|
|
26
27
|
const metadataElements = renderElementItems(metadata);
|
|
27
28
|
const subtitleElements = renderElementItems(subtitle);
|
|
28
29
|
return /*#__PURE__*/React.createElement(Block, _extends({}, blockProps, {
|
|
29
30
|
testId: `${testId}-resolved-view`
|
|
30
|
-
}), /*#__PURE__*/React.createElement(LinkIcon, {
|
|
31
|
+
}), !hideIcon && /*#__PURE__*/React.createElement(LinkIcon, {
|
|
31
32
|
position: position
|
|
32
33
|
}), /*#__PURE__*/React.createElement(ElementGroup, {
|
|
33
34
|
direction: SmartLinkDirection.Vertical,
|
|
@@ -8,7 +8,7 @@ import LinkWarningModal from './LinkWarningModal';
|
|
|
8
8
|
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
9
9
|
const PACKAGE_DATA = {
|
|
10
10
|
packageName: "@atlaskit/smart-card",
|
|
11
|
-
packageVersion: "26.
|
|
11
|
+
packageVersion: "26.36.0",
|
|
12
12
|
componentName: 'linkUrl'
|
|
13
13
|
};
|
|
14
14
|
const Link = withLinkClickedEvent('a');
|
|
@@ -15,7 +15,7 @@ export var ANALYTICS_CHANNEL = 'media';
|
|
|
15
15
|
export var context = {
|
|
16
16
|
componentName: 'smart-cards',
|
|
17
17
|
packageName: "@atlaskit/smart-card",
|
|
18
|
-
packageVersion: "26.
|
|
18
|
+
packageVersion: "26.36.0"
|
|
19
19
|
};
|
|
20
20
|
export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
21
21
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
4
|
var _templateObject;
|
|
5
|
-
var _excluded = ["actionGroup", "metadata", "position", "subtitle", "testId", "text", "title", "metadataPosition"];
|
|
5
|
+
var _excluded = ["actionGroup", "metadata", "position", "subtitle", "testId", "text", "title", "metadataPosition", "hideIcon"];
|
|
6
6
|
import React from 'react';
|
|
7
7
|
import { css } from '@emotion/react';
|
|
8
8
|
import { LinkIcon } from '../../../elements';
|
|
@@ -27,12 +27,14 @@ var TitleBlockResolvedView = function TitleBlockResolvedView(_ref) {
|
|
|
27
27
|
text = _ref.text,
|
|
28
28
|
title = _ref.title,
|
|
29
29
|
metadataPosition = _ref.metadataPosition,
|
|
30
|
+
_ref$hideIcon = _ref.hideIcon,
|
|
31
|
+
hideIcon = _ref$hideIcon === void 0 ? false : _ref$hideIcon,
|
|
30
32
|
blockProps = _objectWithoutProperties(_ref, _excluded);
|
|
31
33
|
var metadataElements = renderElementItems(metadata);
|
|
32
34
|
var subtitleElements = renderElementItems(subtitle);
|
|
33
35
|
return /*#__PURE__*/React.createElement(Block, _extends({}, blockProps, {
|
|
34
36
|
testId: "".concat(testId, "-resolved-view")
|
|
35
|
-
}), /*#__PURE__*/React.createElement(LinkIcon, {
|
|
37
|
+
}), !hideIcon && /*#__PURE__*/React.createElement(LinkIcon, {
|
|
36
38
|
position: position
|
|
37
39
|
}), /*#__PURE__*/React.createElement(ElementGroup, {
|
|
38
40
|
direction: SmartLinkDirection.Vertical,
|
|
@@ -11,7 +11,7 @@ import LinkWarningModal from './LinkWarningModal';
|
|
|
11
11
|
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
12
12
|
var PACKAGE_DATA = {
|
|
13
13
|
packageName: "@atlaskit/smart-card",
|
|
14
|
-
packageVersion: "26.
|
|
14
|
+
packageVersion: "26.36.0",
|
|
15
15
|
componentName: 'linkUrl'
|
|
16
16
|
};
|
|
17
17
|
var Link = withLinkClickedEvent('a');
|
|
@@ -90,6 +90,10 @@ export type TitleBlockProps = {
|
|
|
90
90
|
* @internal
|
|
91
91
|
*/
|
|
92
92
|
metadataPosition?: SmartLinkPosition;
|
|
93
|
+
/**
|
|
94
|
+
* Determines whether TitleBlock will hide the Link Icon.
|
|
95
|
+
*/
|
|
96
|
+
hideIcon?: boolean;
|
|
93
97
|
} & BlockProps;
|
|
94
98
|
export type TitleBlockViewProps = TitleBlockProps & {
|
|
95
99
|
actionGroup?: React.ReactNode;
|
|
@@ -90,6 +90,10 @@ export type TitleBlockProps = {
|
|
|
90
90
|
* @internal
|
|
91
91
|
*/
|
|
92
92
|
metadataPosition?: SmartLinkPosition;
|
|
93
|
+
/**
|
|
94
|
+
* Determines whether TitleBlock will hide the Link Icon.
|
|
95
|
+
*/
|
|
96
|
+
hideIcon?: boolean;
|
|
93
97
|
} & BlockProps;
|
|
94
98
|
export type TitleBlockViewProps = TitleBlockProps & {
|
|
95
99
|
actionGroup?: React.ReactNode;
|
package/package.json
CHANGED
package/report.api.md
CHANGED