@atlaskit/renderer 118.6.16 → 118.7.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 CHANGED
@@ -1,5 +1,17 @@
1
1
  # @atlaskit/renderer
2
2
 
3
+ ## 118.7.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#167885](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/167885)
8
+ [`c02ae038fca4f`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/c02ae038fca4f) -
9
+ [ux] Add optional CompetitorPrompt component to renderer for experiment
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies
14
+
3
15
  ## 118.6.16
4
16
 
5
17
  ### Patch Changes
@@ -51,7 +51,8 @@ function BlockCard(props) {
51
51
  onClick: onClick,
52
52
  container: portal,
53
53
  isDatasource: !!props.datasource,
54
- actionOptions: actionOptions
54
+ actionOptions: actionOptions,
55
+ CompetitorPrompt: smartLinks === null || smartLinks === void 0 ? void 0 : smartLinks.CompetitorPrompt
55
56
  };
56
57
  var analyticsData = {
57
58
  attributes: {
@@ -48,6 +48,11 @@ var InlineCard = function InlineCard(props) {
48
48
  location: 'renderer'
49
49
  };
50
50
  var inlineAnnotationProps = (0, _useInlineAnnotationProps.useInlineAnnotationProps)(props);
51
+ var CompetitorPrompt = smartLinks === null || smartLinks === void 0 ? void 0 : smartLinks.CompetitorPrompt;
52
+ var CompetitorPromptComponent = CompetitorPrompt && url && (0, _platformFeatureFlags.fg)('prompt_whiteboard_competitor_link_gate') ? (0, _react.jsx)(CompetitorPrompt, {
53
+ sourceUrl: url,
54
+ linkType: "inline"
55
+ }) : null;
51
56
  if (ssr && url) {
52
57
  if (
53
58
  // eslint-disable-next-line @atlaskit/platform/no-invalid-feature-flag-usage
@@ -110,6 +115,6 @@ var InlineCard = function InlineCard(props) {
110
115
  props.smartCardStorage.set(data.url, data.title);
111
116
  },
112
117
  onError: onError
113
- })))));
118
+ })), CompetitorPromptComponent)));
114
119
  };
115
120
  var _default = exports.default = (0, _SmartCardStorage.withSmartCardStorage)(InlineCard);
@@ -62,7 +62,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
62
62
  var NORMAL_SEVERITY_THRESHOLD = exports.NORMAL_SEVERITY_THRESHOLD = 2000;
63
63
  var DEGRADED_SEVERITY_THRESHOLD = exports.DEGRADED_SEVERITY_THRESHOLD = 3000;
64
64
  var packageName = "@atlaskit/renderer";
65
- var packageVersion = "118.6.16";
65
+ var packageVersion = "118.7.0";
66
66
  var setAsQueryContainerStyles = (0, _react2.css)({
67
67
  containerName: 'ak-renderer-wrapper',
68
68
  containerType: 'inline-size'
@@ -46,7 +46,8 @@ export default function BlockCard(props) {
46
46
  onClick,
47
47
  container: portal,
48
48
  isDatasource: !!props.datasource,
49
- actionOptions
49
+ actionOptions,
50
+ CompetitorPrompt: smartLinks === null || smartLinks === void 0 ? void 0 : smartLinks.CompetitorPrompt
50
51
  };
51
52
  const analyticsData = {
52
53
  attributes: {
@@ -43,6 +43,11 @@ const InlineCard = props => {
43
43
  location: 'renderer'
44
44
  };
45
45
  const inlineAnnotationProps = useInlineAnnotationProps(props);
46
+ const CompetitorPrompt = smartLinks === null || smartLinks === void 0 ? void 0 : smartLinks.CompetitorPrompt;
47
+ const CompetitorPromptComponent = CompetitorPrompt && url && fg('prompt_whiteboard_competitor_link_gate') ? jsx(CompetitorPrompt, {
48
+ sourceUrl: url,
49
+ linkType: "inline"
50
+ }) : null;
46
51
  if (ssr && url) {
47
52
  if (
48
53
  // eslint-disable-next-line @atlaskit/platform/no-invalid-feature-flag-usage
@@ -106,6 +111,6 @@ const InlineCard = props => {
106
111
  props.smartCardStorage.set(data.url, data.title);
107
112
  },
108
113
  onError: onError
109
- })))));
114
+ })), CompetitorPromptComponent)));
110
115
  };
111
116
  export default withSmartCardStorage(InlineCard);
@@ -48,7 +48,7 @@ import { PortalContext } from './PortalContext';
48
48
  export const NORMAL_SEVERITY_THRESHOLD = 2000;
49
49
  export const DEGRADED_SEVERITY_THRESHOLD = 3000;
50
50
  const packageName = "@atlaskit/renderer";
51
- const packageVersion = "118.6.16";
51
+ const packageVersion = "118.7.0";
52
52
  const setAsQueryContainerStyles = css({
53
53
  containerName: 'ak-renderer-wrapper',
54
54
  containerType: 'inline-size'
@@ -43,7 +43,8 @@ export default function BlockCard(props) {
43
43
  onClick: onClick,
44
44
  container: portal,
45
45
  isDatasource: !!props.datasource,
46
- actionOptions: actionOptions
46
+ actionOptions: actionOptions,
47
+ CompetitorPrompt: smartLinks === null || smartLinks === void 0 ? void 0 : smartLinks.CompetitorPrompt
47
48
  };
48
49
  var analyticsData = {
49
50
  attributes: {
@@ -40,6 +40,11 @@ var InlineCard = function InlineCard(props) {
40
40
  location: 'renderer'
41
41
  };
42
42
  var inlineAnnotationProps = useInlineAnnotationProps(props);
43
+ var CompetitorPrompt = smartLinks === null || smartLinks === void 0 ? void 0 : smartLinks.CompetitorPrompt;
44
+ var CompetitorPromptComponent = CompetitorPrompt && url && fg('prompt_whiteboard_competitor_link_gate') ? jsx(CompetitorPrompt, {
45
+ sourceUrl: url,
46
+ linkType: "inline"
47
+ }) : null;
43
48
  if (ssr && url) {
44
49
  if (
45
50
  // eslint-disable-next-line @atlaskit/platform/no-invalid-feature-flag-usage
@@ -102,6 +107,6 @@ var InlineCard = function InlineCard(props) {
102
107
  props.smartCardStorage.set(data.url, data.title);
103
108
  },
104
109
  onError: onError
105
- })))));
110
+ })), CompetitorPromptComponent)));
106
111
  };
107
112
  export default withSmartCardStorage(InlineCard);
@@ -53,7 +53,7 @@ import { PortalContext } from './PortalContext';
53
53
  export var NORMAL_SEVERITY_THRESHOLD = 2000;
54
54
  export var DEGRADED_SEVERITY_THRESHOLD = 3000;
55
55
  var packageName = "@atlaskit/renderer";
56
- var packageVersion = "118.6.16";
56
+ var packageVersion = "118.7.0";
57
57
  var setAsQueryContainerStyles = css({
58
58
  containerName: 'ak-renderer-wrapper',
59
59
  containerType: 'inline-size'
@@ -1,3 +1,4 @@
1
+ import type React from 'react';
1
2
  import type { CardProps } from '@atlaskit/smart-card';
2
3
  export interface SmartLinksOptions {
3
4
  /**
@@ -31,4 +32,11 @@ export interface SmartLinksOptions {
31
32
  * Component: embed
32
33
  */
33
34
  frameStyle?: CardProps['frameStyle'];
35
+ /**
36
+ * Competitor Prompt Component for Competitor link
37
+ */
38
+ CompetitorPrompt?: React.ComponentType<{
39
+ sourceUrl: string;
40
+ linkType?: string;
41
+ }>;
34
42
  }
@@ -1,3 +1,4 @@
1
+ import type React from 'react';
1
2
  import type { CardProps } from '@atlaskit/smart-card';
2
3
  export interface SmartLinksOptions {
3
4
  /**
@@ -31,4 +32,11 @@ export interface SmartLinksOptions {
31
32
  * Component: embed
32
33
  */
33
34
  frameStyle?: CardProps['frameStyle'];
35
+ /**
36
+ * Competitor Prompt Component for Competitor link
37
+ */
38
+ CompetitorPrompt?: React.ComponentType<{
39
+ sourceUrl: string;
40
+ linkType?: string;
41
+ }>;
34
42
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/renderer",
3
- "version": "118.6.16",
3
+ "version": "118.7.0",
4
4
  "description": "Renderer component",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -31,7 +31,7 @@
31
31
  "@atlaskit/analytics-next": "^11.1.0",
32
32
  "@atlaskit/button": "^23.2.0",
33
33
  "@atlaskit/code": "^17.2.0",
34
- "@atlaskit/editor-common": "^106.7.0",
34
+ "@atlaskit/editor-common": "^106.9.0",
35
35
  "@atlaskit/editor-json-transformer": "^8.24.0",
36
36
  "@atlaskit/editor-palette": "^2.1.0",
37
37
  "@atlaskit/editor-prosemirror": "7.0.0",
@@ -45,9 +45,9 @@
45
45
  "@atlaskit/media-card": "^79.3.0",
46
46
  "@atlaskit/media-client": "^33.4.0",
47
47
  "@atlaskit/media-client-react": "^4.1.0",
48
- "@atlaskit/media-common": "^12.1.0",
48
+ "@atlaskit/media-common": "^12.2.0",
49
49
  "@atlaskit/media-filmstrip": "^50.1.0",
50
- "@atlaskit/media-ui": "^28.2.0",
50
+ "@atlaskit/media-ui": "^28.3.0",
51
51
  "@atlaskit/media-viewer": "^52.2.0",
52
52
  "@atlaskit/platform-feature-flags": "^1.1.0",
53
53
  "@atlaskit/platform-feature-flags-react": "^0.2.0",
@@ -56,7 +56,7 @@
56
56
  "@atlaskit/status": "^3.0.0",
57
57
  "@atlaskit/task-decision": "^19.2.0",
58
58
  "@atlaskit/theme": "^18.0.0",
59
- "@atlaskit/tmp-editor-statsig": "^7.0.0",
59
+ "@atlaskit/tmp-editor-statsig": "^7.1.0",
60
60
  "@atlaskit/tokens": "^5.2.0",
61
61
  "@atlaskit/tooltip": "^20.3.0",
62
62
  "@atlaskit/visually-hidden": "^3.0.0",
@@ -265,6 +265,9 @@
265
265
  },
266
266
  "platform_fix_block_card_img_icon_vc": {
267
267
  "type": "boolean"
268
+ },
269
+ "prompt_whiteboard_competitor_link_gate": {
270
+ "type": "boolean"
268
271
  }
269
272
  },
270
273
  "af:exports": {