@atlaskit/smart-card 26.9.11 → 26.9.13
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/version.json +1 -1
- package/dist/cjs/view/EmbedModal/components/link-info/styled.js +4 -1
- package/dist/cjs/view/EmbedModal/utils.js +5 -2
- package/dist/es2019/version.json +1 -1
- package/dist/es2019/view/EmbedModal/components/link-info/styled.js +7 -0
- package/dist/es2019/view/EmbedModal/utils.js +4 -1
- package/dist/esm/version.json +1 -1
- package/dist/esm/view/EmbedModal/components/link-info/styled.js +4 -1
- package/dist/esm/view/EmbedModal/utils.js +5 -2
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atlaskit/smart-card
|
|
2
2
|
|
|
3
|
+
## 26.9.13
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`68956c0d353`](https://bitbucket.org/atlassian/atlassian-frontend/commits/68956c0d353) - Embed Modal: Fix icon alignment when triggered from flexible and block card component
|
|
8
|
+
|
|
9
|
+
## 26.9.12
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- Updated dependencies
|
|
14
|
+
|
|
3
15
|
## 26.9.11
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/dist/cjs/version.json
CHANGED
|
@@ -12,7 +12,10 @@ var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
|
12
12
|
var containerStyles = (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n align-items: center;\n display: flex;\n gap: ", ";\n justify-content: space-between;\n // AK ModalBody has 2px padding top and bottom.\n // Using 14px here to create 16px gap between\n // link info and iframe\n padding: ", " ", " 14px\n ", ";\n"])), "var(--ds-space-100, 8px)", "var(--ds-space-300, 24px)", "var(--ds-space-300, 24px)", "var(--ds-space-300, 24px)");
|
|
13
13
|
exports.containerStyles = containerStyles;
|
|
14
14
|
var iconSize = '24px';
|
|
15
|
-
|
|
15
|
+
// EDM-7328: CSS Specificity
|
|
16
|
+
// An embed modal icon css for img, span, svg has specificity weight of 0-1-1.
|
|
17
|
+
// Specify flex ui icon selector to increase specificity weight to 0-2-1.
|
|
18
|
+
var iconCss = (0, _react.css)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n &,\n [data-smart-element-icon] img,\n [data-smart-element-icon] span,\n [data-smart-element-icon] svg,\n img,\n span,\n svg {\n height: ", ";\n min-height: ", ";\n max-height: ", ";\n width: ", ";\n min-width: ", ";\n max-width: ", ";\n }\n"])), iconSize, iconSize, iconSize, iconSize, iconSize, iconSize);
|
|
16
19
|
exports.iconCss = iconCss;
|
|
17
20
|
var height = '20px';
|
|
18
21
|
var titleCss = (0, _react.css)(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n flex: 1 1 auto;\n\n h3 {\n flex: 1 1 auto;\n font-size: 16px;\n font-weight: 400;\n line-height: ", ";\n\n display: -webkit-box;\n margin-bottom: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n word-break: break-word;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical;\n // Fallback options\n @supports not (-webkit-line-clamp: 1) {\n max-height: ", ";\n }\n }\n"])), height, height);
|
|
@@ -8,13 +8,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
8
8
|
exports.openPreviewModal = void 0;
|
|
9
9
|
exports.previewFunction = previewFunction;
|
|
10
10
|
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
11
|
-
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
12
11
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
13
12
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
13
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
14
14
|
var _react = _interopRequireDefault(require("react"));
|
|
15
15
|
var _reactDom = _interopRequireDefault(require("react-dom"));
|
|
16
16
|
var _reactIntlNext = require("react-intl-next");
|
|
17
17
|
var _icon = _interopRequireDefault(require("../FlexibleCard/components/elements/icon"));
|
|
18
|
+
var _constants = require("../../constants");
|
|
18
19
|
var _excluded = ["popupMountPointId", "onClose"];
|
|
19
20
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
20
21
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
@@ -30,7 +31,9 @@ var openPreviewModal = function openPreviewModal(_ref) {
|
|
|
30
31
|
title = _ref.title,
|
|
31
32
|
url = _ref.url;
|
|
32
33
|
var EmbedIcon = {
|
|
33
|
-
icon: /*#__PURE__*/_react.default.createElement(_icon.default,
|
|
34
|
+
icon: /*#__PURE__*/_react.default.createElement(_icon.default, (0, _extends2.default)({}, linkIcon, {
|
|
35
|
+
size: _constants.SmartLinkSize.Large
|
|
36
|
+
})),
|
|
34
37
|
isFlexibleUi: true
|
|
35
38
|
};
|
|
36
39
|
return previewFunction({
|
package/dist/es2019/version.json
CHANGED
|
@@ -12,7 +12,14 @@ export const containerStyles = css`
|
|
|
12
12
|
${"var(--ds-space-300, 24px)"};
|
|
13
13
|
`;
|
|
14
14
|
const iconSize = '24px';
|
|
15
|
+
// EDM-7328: CSS Specificity
|
|
16
|
+
// An embed modal icon css for img, span, svg has specificity weight of 0-1-1.
|
|
17
|
+
// Specify flex ui icon selector to increase specificity weight to 0-2-1.
|
|
15
18
|
export const iconCss = css`
|
|
19
|
+
&,
|
|
20
|
+
[data-smart-element-icon] img,
|
|
21
|
+
[data-smart-element-icon] span,
|
|
22
|
+
[data-smart-element-icon] svg,
|
|
16
23
|
img,
|
|
17
24
|
span,
|
|
18
25
|
svg {
|
|
@@ -3,6 +3,7 @@ import React from 'react';
|
|
|
3
3
|
import ReactDOM from 'react-dom';
|
|
4
4
|
import { IntlProvider } from 'react-intl-next';
|
|
5
5
|
import Icon from '../FlexibleCard/components/elements/icon';
|
|
6
|
+
import { SmartLinkSize } from '../../constants';
|
|
6
7
|
export const openPreviewModal = ({
|
|
7
8
|
analytics,
|
|
8
9
|
downloadUrl: download,
|
|
@@ -15,7 +16,9 @@ export const openPreviewModal = ({
|
|
|
15
16
|
url
|
|
16
17
|
}) => {
|
|
17
18
|
const EmbedIcon = {
|
|
18
|
-
icon: /*#__PURE__*/React.createElement(Icon, linkIcon
|
|
19
|
+
icon: /*#__PURE__*/React.createElement(Icon, _extends({}, linkIcon, {
|
|
20
|
+
size: SmartLinkSize.Large
|
|
21
|
+
})),
|
|
19
22
|
isFlexibleUi: true
|
|
20
23
|
};
|
|
21
24
|
return previewFunction({
|
package/dist/esm/version.json
CHANGED
|
@@ -4,7 +4,10 @@ import { css } from '@emotion/react';
|
|
|
4
4
|
// eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage
|
|
5
5
|
export var containerStyles = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n align-items: center;\n display: flex;\n gap: ", ";\n justify-content: space-between;\n // AK ModalBody has 2px padding top and bottom.\n // Using 14px here to create 16px gap between\n // link info and iframe\n padding: ", " ", " 14px\n ", ";\n"])), "var(--ds-space-100, 8px)", "var(--ds-space-300, 24px)", "var(--ds-space-300, 24px)", "var(--ds-space-300, 24px)");
|
|
6
6
|
var iconSize = '24px';
|
|
7
|
-
|
|
7
|
+
// EDM-7328: CSS Specificity
|
|
8
|
+
// An embed modal icon css for img, span, svg has specificity weight of 0-1-1.
|
|
9
|
+
// Specify flex ui icon selector to increase specificity weight to 0-2-1.
|
|
10
|
+
export var iconCss = css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n &,\n [data-smart-element-icon] img,\n [data-smart-element-icon] span,\n [data-smart-element-icon] svg,\n img,\n span,\n svg {\n height: ", ";\n min-height: ", ";\n max-height: ", ";\n width: ", ";\n min-width: ", ";\n max-width: ", ";\n }\n"])), iconSize, iconSize, iconSize, iconSize, iconSize, iconSize);
|
|
8
11
|
var height = '20px';
|
|
9
12
|
export var titleCss = css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n flex: 1 1 auto;\n\n h3 {\n flex: 1 1 auto;\n font-size: 16px;\n font-weight: 400;\n line-height: ", ";\n\n display: -webkit-box;\n margin-bottom: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n word-break: break-word;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical;\n // Fallback options\n @supports not (-webkit-line-clamp: 1) {\n max-height: ", ";\n }\n }\n"])), height, height);
|
|
10
13
|
export var actionCss = css(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n display: flex;\n flex: 0 0 auto;\n gap: ", ";\n line-height: ", ";\n span {\n line-height: ", ";\n }\n\n @media only screen and (max-width: 980px) {\n // Hide resize button if the screen is smaller than the min width\n // or too small to have enough impact to matter.\n .smart-link-resize-button {\n display: none;\n }\n }\n"])), "var(--ds-space-050, 4px)", height, height);
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
1
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
2
|
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
3
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
4
4
|
var _excluded = ["popupMountPointId", "onClose"];
|
|
5
5
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
6
6
|
import React from 'react';
|
|
7
7
|
import ReactDOM from 'react-dom';
|
|
8
8
|
import { IntlProvider } from 'react-intl-next';
|
|
9
9
|
import Icon from '../FlexibleCard/components/elements/icon';
|
|
10
|
+
import { SmartLinkSize } from '../../constants';
|
|
10
11
|
export var openPreviewModal = function openPreviewModal(_ref) {
|
|
11
12
|
var analytics = _ref.analytics,
|
|
12
13
|
download = _ref.downloadUrl,
|
|
@@ -19,7 +20,9 @@ export var openPreviewModal = function openPreviewModal(_ref) {
|
|
|
19
20
|
title = _ref.title,
|
|
20
21
|
url = _ref.url;
|
|
21
22
|
var EmbedIcon = {
|
|
22
|
-
icon: /*#__PURE__*/React.createElement(Icon, linkIcon
|
|
23
|
+
icon: /*#__PURE__*/React.createElement(Icon, _extends({}, linkIcon, {
|
|
24
|
+
size: SmartLinkSize.Large
|
|
25
|
+
})),
|
|
23
26
|
isFlexibleUi: true
|
|
24
27
|
};
|
|
25
28
|
return previewFunction({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/smart-card",
|
|
3
|
-
"version": "26.9.
|
|
3
|
+
"version": "26.9.13",
|
|
4
4
|
"description": "Smart card component",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@atlaskit/link-analytics": "^8.2.0",
|
|
39
39
|
"@atlaskit/link-client-extension": "^1.5.0",
|
|
40
40
|
"@atlaskit/link-extractors": "^1.1.0",
|
|
41
|
-
"@atlaskit/linking-common": "^
|
|
41
|
+
"@atlaskit/linking-common": "^4.0.0",
|
|
42
42
|
"@atlaskit/linking-types": "^8.2.0",
|
|
43
43
|
"@atlaskit/logo": "^13.14.0",
|
|
44
44
|
"@atlaskit/lozenge": "^11.4.0",
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
"@atlaskit/popup": "^1.8.0",
|
|
50
50
|
"@atlaskit/spinner": "^15.5.0",
|
|
51
51
|
"@atlaskit/theme": "^12.5.0",
|
|
52
|
-
"@atlaskit/tokens": "^1.
|
|
52
|
+
"@atlaskit/tokens": "^1.13.0",
|
|
53
53
|
"@atlaskit/tooltip": "^17.8.0",
|
|
54
54
|
"@atlaskit/ufo": "^0.2.0",
|
|
55
55
|
"@babel/runtime": "^7.0.0",
|