@atlaskit/renderer 153.0.1 → 153.0.2

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,16 @@
1
1
  # @atlaskit/renderer
2
2
 
3
+ ## 153.0.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [`8c836aa200b92`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/8c836aa200b92) -
8
+ Keep top-level expands inside the content width on comment surfaces (Jira description and
9
+ comments) behind platform_editor_expand_standard_width_fix or the work_item_modernization
10
+ experiment: the renderer drops the -12px gutter offset for comment appearance, and the editor
11
+ applies the block menu useStandardNodeWidth config without the platform_editor_controls
12
+ experiment, including chromeless.
13
+
3
14
  ## 153.0.1
4
15
 
5
16
  ### Patch Changes
@@ -19,6 +19,7 @@ var _WidthProvider = require("@atlaskit/editor-common/WidthProvider");
19
19
  var _constants = require("@atlaskit/editor-shared-styles/constants");
20
20
  var _chevronRight = _interopRequireDefault(require("@atlaskit/icon/core/chevron-right"));
21
21
  var _isExperimentEnabled = require("@atlaskit/platform-feature-experiments/is-experiment-enabled");
22
+ var _fg = require("@atlaskit/platform-feature-flags/fg");
22
23
  var _Tooltip = _interopRequireDefault(require("@atlaskit/tooltip/Tooltip"));
23
24
  var _events = require("../analytics/events");
24
25
  var _activeHeaderIdProvider = require("./active-header-id-provider");
@@ -174,7 +175,7 @@ var clearNextSiblingMarginTopStyle = (0, _react2.css)({
174
175
  });
175
176
  var Container = function Container(props) {
176
177
  return (0, _react2.jsx)("div", {
177
- css: [containerStyles, props['data-node-type'] === 'expand' && containerStylesDataNodeTypeExpand, props.expanded && containerStylesExpanded, props.focused && containerStylesFocused],
178
+ css: [containerStyles, props['data-node-type'] === 'expand' && !props.useStandardWidth && containerStylesDataNodeTypeExpand, props.expanded && containerStylesExpanded, props.focused && containerStylesFocused],
178
179
  "data-testid": props['data-testid'],
179
180
  "data-node-type": props['data-node-type'],
180
181
  "data-title": props['data-title'],
@@ -229,6 +230,7 @@ function Expand(_ref) {
229
230
  fireAnalyticsEvent = _ref.fireAnalyticsEvent,
230
231
  localId = _ref.localId,
231
232
  nestedHeaderIds = _ref.nestedHeaderIds,
233
+ rendererAppearance = _ref.rendererAppearance,
232
234
  rendererContentMode = _ref.rendererContentMode,
233
235
  node = _ref.node;
234
236
  var ancestorBody = (0, _expandBody.useExpandBody)();
@@ -395,6 +397,9 @@ function Expand(_ref) {
395
397
  "data-local-id": localId,
396
398
  expanded: expanded,
397
399
  focused: focused
400
+ // Comment surfaces (Jira description and comments) have no gutter for the expand to sit in.
401
+ ,
402
+ useStandardWidth: ((0, _fg.fg)('platform_editor_expand_standard_width_fix') || (0, _isExperimentEnabled.isExperimentEnabled)('work_item_modernization')) && rendererAppearance === 'comment'
398
403
  }, nestedHeaderIds && nestedHeaderIds.length > 0 ? (0, _react2.jsx)(_activeHeaderIdProvider.ActiveHeaderIdConsumer, {
399
404
  nestedHeaderIds: nestedHeaderIds,
400
405
  onNestedHeaderIdMatch: openBody
@@ -80,7 +80,7 @@ var DEGRADED_SEVERITY_THRESHOLD = exports.DEGRADED_SEVERITY_THRESHOLD = 3000;
80
80
  var TABLE_INFO_TIMEOUT = 10000;
81
81
  var RENDER_EVENT_SAMPLE_RATE = 0.1;
82
82
  var packageName = "@atlaskit/renderer";
83
- var packageVersion = "153.0.0";
83
+ var packageVersion = "153.0.1";
84
84
  var setAsQueryContainerStyles = (0, _react2.css)({
85
85
  containerName: 'ak-renderer-wrapper',
86
86
  containerType: 'inline-size'
@@ -17,6 +17,7 @@ import { WidthProvider } from '@atlaskit/editor-common/WidthProvider';
17
17
  import { akEditorLineHeight, akEditorSwoopCubicBezier, akLayoutGutterOffset } from '@atlaskit/editor-shared-styles/constants';
18
18
  import ChevronRightIcon from '@atlaskit/icon/core/chevron-right';
19
19
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
20
+ import { fg } from '@atlaskit/platform-feature-flags/fg';
20
21
  import Tooltip from '@atlaskit/tooltip/Tooltip';
21
22
  import { MODE, PLATFORM } from '../analytics/events';
22
23
  import { ActiveHeaderIdConsumer } from './active-header-id-provider';
@@ -164,7 +165,7 @@ const clearNextSiblingMarginTopStyle = css({
164
165
  });
165
166
  const Container = props => {
166
167
  return jsx("div", {
167
- css: [containerStyles, props['data-node-type'] === 'expand' && containerStylesDataNodeTypeExpand, props.expanded && containerStylesExpanded, props.focused && containerStylesFocused],
168
+ css: [containerStyles, props['data-node-type'] === 'expand' && !props.useStandardWidth && containerStylesDataNodeTypeExpand, props.expanded && containerStylesExpanded, props.focused && containerStylesFocused],
168
169
  "data-testid": props['data-testid'],
169
170
  "data-node-type": props['data-node-type'],
170
171
  "data-title": props['data-title'],
@@ -220,6 +221,7 @@ function Expand({
220
221
  fireAnalyticsEvent,
221
222
  localId,
222
223
  nestedHeaderIds,
224
+ rendererAppearance,
223
225
  rendererContentMode,
224
226
  node
225
227
  }) {
@@ -371,6 +373,9 @@ function Expand({
371
373
  "data-local-id": localId,
372
374
  expanded: expanded,
373
375
  focused: focused
376
+ // Comment surfaces (Jira description and comments) have no gutter for the expand to sit in.
377
+ ,
378
+ useStandardWidth: (fg('platform_editor_expand_standard_width_fix') || isExperimentEnabled('work_item_modernization')) && rendererAppearance === 'comment'
374
379
  }, nestedHeaderIds && nestedHeaderIds.length > 0 ? jsx(ActiveHeaderIdConsumer, {
375
380
  nestedHeaderIds: nestedHeaderIds,
376
381
  onNestedHeaderIdMatch: openBody
@@ -65,7 +65,7 @@ export const DEGRADED_SEVERITY_THRESHOLD = 3000;
65
65
  const TABLE_INFO_TIMEOUT = 10000;
66
66
  const RENDER_EVENT_SAMPLE_RATE = 0.1;
67
67
  const packageName = "@atlaskit/renderer";
68
- const packageVersion = "153.0.0";
68
+ const packageVersion = "153.0.1";
69
69
  const setAsQueryContainerStyles = css({
70
70
  containerName: 'ak-renderer-wrapper',
71
71
  containerType: 'inline-size'
@@ -18,6 +18,7 @@ import { WidthProvider } from '@atlaskit/editor-common/WidthProvider';
18
18
  import { akEditorLineHeight, akEditorSwoopCubicBezier, akLayoutGutterOffset } from '@atlaskit/editor-shared-styles/constants';
19
19
  import ChevronRightIcon from '@atlaskit/icon/core/chevron-right';
20
20
  import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
21
+ import { fg } from '@atlaskit/platform-feature-flags/fg';
21
22
  import Tooltip from '@atlaskit/tooltip/Tooltip';
22
23
  import { MODE, PLATFORM } from '../analytics/events';
23
24
  import { ActiveHeaderIdConsumer } from './active-header-id-provider';
@@ -165,7 +166,7 @@ var clearNextSiblingMarginTopStyle = css({
165
166
  });
166
167
  var Container = function Container(props) {
167
168
  return jsx("div", {
168
- css: [containerStyles, props['data-node-type'] === 'expand' && containerStylesDataNodeTypeExpand, props.expanded && containerStylesExpanded, props.focused && containerStylesFocused],
169
+ css: [containerStyles, props['data-node-type'] === 'expand' && !props.useStandardWidth && containerStylesDataNodeTypeExpand, props.expanded && containerStylesExpanded, props.focused && containerStylesFocused],
169
170
  "data-testid": props['data-testid'],
170
171
  "data-node-type": props['data-node-type'],
171
172
  "data-title": props['data-title'],
@@ -220,6 +221,7 @@ function Expand(_ref) {
220
221
  fireAnalyticsEvent = _ref.fireAnalyticsEvent,
221
222
  localId = _ref.localId,
222
223
  nestedHeaderIds = _ref.nestedHeaderIds,
224
+ rendererAppearance = _ref.rendererAppearance,
223
225
  rendererContentMode = _ref.rendererContentMode,
224
226
  node = _ref.node;
225
227
  var ancestorBody = useExpandBody();
@@ -386,6 +388,9 @@ function Expand(_ref) {
386
388
  "data-local-id": localId,
387
389
  expanded: expanded,
388
390
  focused: focused
391
+ // Comment surfaces (Jira description and comments) have no gutter for the expand to sit in.
392
+ ,
393
+ useStandardWidth: (fg('platform_editor_expand_standard_width_fix') || isExperimentEnabled('work_item_modernization')) && rendererAppearance === 'comment'
389
394
  }, nestedHeaderIds && nestedHeaderIds.length > 0 ? jsx(ActiveHeaderIdConsumer, {
390
395
  nestedHeaderIds: nestedHeaderIds,
391
396
  onNestedHeaderIdMatch: openBody
@@ -70,7 +70,7 @@ export var DEGRADED_SEVERITY_THRESHOLD = 3000;
70
70
  var TABLE_INFO_TIMEOUT = 10000;
71
71
  var RENDER_EVENT_SAMPLE_RATE = 0.1;
72
72
  var packageName = "@atlaskit/renderer";
73
- var packageVersion = "153.0.0";
73
+ var packageVersion = "153.0.1";
74
74
  var setAsQueryContainerStyles = css({
75
75
  containerName: 'ak-renderer-wrapper',
76
76
  containerType: 'inline-size'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/renderer",
3
- "version": "153.0.1",
3
+ "version": "153.0.2",
4
4
  "description": "Renderer component",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"