@atlaskit/jql-editor 4.7.3 → 4.7.4

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,14 @@
1
1
  # @atlaskit/jql-editor
2
2
 
3
+ ## 4.7.4
4
+
5
+ ### Patch Changes
6
+
7
+ - [#141027](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/141027)
8
+ [`54b27406e5181`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/54b27406e5181) -
9
+ [ux] Update icons and buttons on jql
10
+ - Updated dependencies
11
+
3
12
  ## 4.7.3
4
13
 
5
14
  ### Patch Changes
@@ -6,5 +6,5 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.useJqlEditorAnalytics = void 0;
7
7
  var _jqlEditorCommon = require("@atlaskit/jql-editor-common");
8
8
  var useJqlEditorAnalytics = exports.useJqlEditorAnalytics = function useJqlEditorAnalytics(analyticsSource) {
9
- return (0, _jqlEditorCommon.useJqlPackageAnalytics)(analyticsSource, "@atlaskit/jql-editor", "4.7.3", _jqlEditorCommon.ANALYTICS_CHANNEL);
9
+ return (0, _jqlEditorCommon.useJqlPackageAnalytics)(analyticsSource, "@atlaskit/jql-editor", "4.7.4", _jqlEditorCommon.ANALYTICS_CHANNEL);
10
10
  };
@@ -7,8 +7,12 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.BaseExpandToggle = void 0;
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
  var _button = _interopRequireDefault(require("@atlaskit/button"));
10
+ var _new = require("@atlaskit/button/new");
11
+ var _growDiagonal = _interopRequireDefault(require("@atlaskit/icon/core/grow-diagonal"));
12
+ var _shrinkDiagonal = _interopRequireDefault(require("@atlaskit/icon/core/shrink-diagonal"));
10
13
  var _actualSize = _interopRequireDefault(require("@atlaskit/icon/glyph/media-services/actual-size"));
11
14
  var _fitToPage = _interopRequireDefault(require("@atlaskit/icon/glyph/media-services/fit-to-page"));
15
+ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
12
16
  var _colors = require("@atlaskit/theme/colors");
13
17
  var _styled = require("./styled");
14
18
  // Atlaskit doesn't provide a circle variation of the expand/collapse icons so we have to implement our own
@@ -40,7 +44,16 @@ var BaseExpandToggle = exports.BaseExpandToggle = function BaseExpandToggle(_ref
40
44
  } else {
41
45
  Icon = ExpandCircleIcon;
42
46
  }
43
- return /*#__PURE__*/_react.default.createElement(_styled.ExpandToggleContainer, null, /*#__PURE__*/_react.default.createElement(_button.default, {
47
+ return (0, _platformFeatureFlags.fg)('platform-component-visual-refresh') ? /*#__PURE__*/_react.default.createElement(_new.IconButton, {
48
+ appearance: 'subtle',
49
+ spacing: "compact",
50
+ "aria-expanded": expanded,
51
+ "aria-controls": editorId,
52
+ label: label,
53
+ isDisabled: isDisabled,
54
+ onClick: onClick,
55
+ icon: expanded ? _shrinkDiagonal.default : _growDiagonal.default
56
+ }) : /*#__PURE__*/_react.default.createElement(_styled.ExpandToggleContainer, null, /*#__PURE__*/_react.default.createElement(_button.default, {
44
57
  appearance: 'subtle',
45
58
  "aria-expanded": expanded,
46
59
  "aria-controls": editorId,
@@ -8,7 +8,10 @@ Object.defineProperty(exports, "__esModule", {
8
8
  exports.BaseSearch = void 0;
9
9
  var _react = _interopRequireWildcard(require("react"));
10
10
  var _button = require("@atlaskit/button");
11
- var _search = _interopRequireDefault(require("@atlaskit/icon/glyph/editor/search"));
11
+ var _new = require("@atlaskit/button/new");
12
+ var _search = _interopRequireDefault(require("@atlaskit/icon/core/search"));
13
+ var _search2 = _interopRequireDefault(require("@atlaskit/icon/glyph/editor/search"));
14
+ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
12
15
  function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
13
16
  function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
14
17
  var style = {
@@ -26,7 +29,17 @@ var BaseSearch = exports.BaseSearch = function BaseSearch(_ref) {
26
29
  e.preventDefault();
27
30
  }
28
31
  }, []);
29
- return /*#__PURE__*/_react.default.createElement(_button.LoadingButton, {
32
+ return (0, _platformFeatureFlags.fg)('platform-component-visual-refresh') ? /*#__PURE__*/_react.default.createElement(_new.IconButton, {
33
+ label: label,
34
+ isDisabled: isDisabled,
35
+ testId: "jql-editor-search",
36
+ appearance: 'primary',
37
+ spacing: "compact",
38
+ onClick: onSearch,
39
+ onKeyDown: preventRepeatClick,
40
+ isLoading: isSearching,
41
+ icon: _search.default
42
+ }) : /*#__PURE__*/_react.default.createElement(_button.LoadingButton, {
30
43
  "aria-label": label,
31
44
  isDisabled: isDisabled,
32
45
  testId: "jql-editor-search"
@@ -38,7 +51,7 @@ var BaseSearch = exports.BaseSearch = function BaseSearch(_ref) {
38
51
  onClick: onSearch,
39
52
  onKeyDown: preventRepeatClick,
40
53
  isLoading: isSearching,
41
- iconBefore: /*#__PURE__*/_react.default.createElement(_search.default, {
54
+ iconBefore: /*#__PURE__*/_react.default.createElement(_search2.default, {
42
55
  label: '',
43
56
  size: 'medium'
44
57
  })
@@ -5,9 +5,13 @@ Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
7
  exports.BaseSyntaxHelp = void 0;
8
+ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
8
9
  var _react = _interopRequireDefault(require("react"));
9
10
  var _button = _interopRequireDefault(require("@atlaskit/button"));
11
+ var _new = require("@atlaskit/button/new");
12
+ var _questionCircle = _interopRequireDefault(require("@atlaskit/icon/core/question-circle"));
10
13
  var _question = _interopRequireDefault(require("@atlaskit/icon/glyph/question"));
14
+ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
11
15
  var _colors = require("@atlaskit/theme/colors");
12
16
  var _styled = require("./styled");
13
17
  var BaseSyntaxHelp = exports.BaseSyntaxHelp = function BaseSyntaxHelp(_ref) {
@@ -15,7 +19,21 @@ var BaseSyntaxHelp = exports.BaseSyntaxHelp = function BaseSyntaxHelp(_ref) {
15
19
  isDisabled = _ref.isDisabled,
16
20
  label = _ref.label,
17
21
  onClick = _ref.onClick;
18
- return /*#__PURE__*/_react.default.createElement(_styled.SyntaxHelpContainer, null, /*#__PURE__*/_react.default.createElement(_button.default, {
22
+ return (0, _platformFeatureFlags.fg)('platform-component-visual-refresh') ? /*#__PURE__*/_react.default.createElement(_new.LinkIconButton, {
23
+ "aria-describedby": describedby,
24
+ label: label,
25
+ isDisabled: isDisabled,
26
+ appearance: "subtle",
27
+ spacing: "compact",
28
+ onClick: onClick,
29
+ target: "blank",
30
+ href: "https://confluence.atlassian.com/display/SERVICEDESKCLOUD/Advanced+searching",
31
+ icon: function icon(iconProps) {
32
+ return /*#__PURE__*/_react.default.createElement(_questionCircle.default, (0, _extends2.default)({}, iconProps, {
33
+ color: "var(--ds-icon-subtle, #626F86)"
34
+ }));
35
+ }
36
+ }) : /*#__PURE__*/_react.default.createElement(_styled.SyntaxHelpContainer, null, /*#__PURE__*/_react.default.createElement(_button.default, {
19
37
  "aria-describedby": describedby,
20
38
  "aria-label": label,
21
39
  isDisabled: isDisabled,
@@ -7,6 +7,7 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.default = exports.JQLEditorReadOnly = void 0;
8
8
  var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
9
9
  var _react = _interopRequireDefault(require("react"));
10
+ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
10
11
  var _primitives = require("@atlaskit/primitives");
11
12
  var _useEditorTheme = require("../../hooks/use-editor-theme");
12
13
  var _splitTextByNewLine = require("../../utils/split-text-by-new-line");
@@ -53,7 +54,8 @@ var JQLEditorLayout = function JQLEditorLayout(props) {
53
54
  onTransitionEnd: onEditorViewTransitionEnd
54
55
  }), /*#__PURE__*/_react.default.createElement(_styled.EditorControls, {
55
56
  isSearch: isSearch,
56
- isCompact: isCompact
57
+ isCompact: isCompact,
58
+ isVisualRefresh: (0, _platformFeatureFlags.fg)('platform-component-visual-refresh')
57
59
  }, EditorControlsContent)), /*#__PURE__*/_react.default.createElement(_styled.EditorFooter, null, EditorFooterContent));
58
60
  };
59
61
  /**
@@ -152,6 +152,8 @@ var EditorControls = exports.EditorControls = _styled.default.div(function (prop
152
152
  position: 'sticky',
153
153
  top: 0,
154
154
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
155
- height: "".concat(rowHeight + 2 * getEditorInputVerticalPadding(props.isCompact), "px")
155
+ height: "".concat(rowHeight + 2 * getEditorInputVerticalPadding(props.isCompact), "px"),
156
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
157
+ gap: props.isVisualRefresh ? "var(--ds-space-025, 2px)" : 'unset'
156
158
  };
157
159
  });
@@ -1,4 +1,4 @@
1
1
  import { ANALYTICS_CHANNEL, useJqlPackageAnalytics } from '@atlaskit/jql-editor-common';
2
2
  export const useJqlEditorAnalytics = analyticsSource => {
3
- return useJqlPackageAnalytics(analyticsSource, "@atlaskit/jql-editor", "4.7.3", ANALYTICS_CHANNEL);
3
+ return useJqlPackageAnalytics(analyticsSource, "@atlaskit/jql-editor", "4.7.4", ANALYTICS_CHANNEL);
4
4
  };
@@ -1,7 +1,11 @@
1
1
  import React from 'react';
2
2
  import Button from '@atlaskit/button';
3
+ import { IconButton } from '@atlaskit/button/new';
4
+ import GrowDiagonalIcon from '@atlaskit/icon/core/grow-diagonal';
5
+ import ShrinkDiagonalIcon from '@atlaskit/icon/core/shrink-diagonal';
3
6
  import MediaServicesActualSizeIcon from '@atlaskit/icon/glyph/media-services/actual-size';
4
7
  import MediaServicesFitToPageIcon from '@atlaskit/icon/glyph/media-services/fit-to-page';
8
+ import { fg } from '@atlaskit/platform-feature-flags';
5
9
  import { N50, N500 } from '@atlaskit/theme/colors';
6
10
  import { ExpandToggleContainer } from './styled';
7
11
 
@@ -33,7 +37,16 @@ export const BaseExpandToggle = ({
33
37
  } else {
34
38
  Icon = ExpandCircleIcon;
35
39
  }
36
- return /*#__PURE__*/React.createElement(ExpandToggleContainer, null, /*#__PURE__*/React.createElement(Button, {
40
+ return fg('platform-component-visual-refresh') ? /*#__PURE__*/React.createElement(IconButton, {
41
+ appearance: 'subtle',
42
+ spacing: "compact",
43
+ "aria-expanded": expanded,
44
+ "aria-controls": editorId,
45
+ label: label,
46
+ isDisabled: isDisabled,
47
+ onClick: onClick,
48
+ icon: expanded ? ShrinkDiagonalIcon : GrowDiagonalIcon
49
+ }) : /*#__PURE__*/React.createElement(ExpandToggleContainer, null, /*#__PURE__*/React.createElement(Button, {
37
50
  appearance: 'subtle',
38
51
  "aria-expanded": expanded,
39
52
  "aria-controls": editorId,
@@ -1,6 +1,9 @@
1
1
  import React, { useCallback } from 'react';
2
2
  import { LoadingButton } from '@atlaskit/button';
3
- import SearchIcon from '@atlaskit/icon/glyph/editor/search';
3
+ import { IconButton } from '@atlaskit/button/new';
4
+ import SearchIcon from '@atlaskit/icon/core/search';
5
+ import SearchIconOld from '@atlaskit/icon/glyph/editor/search';
6
+ import { fg } from '@atlaskit/platform-feature-flags';
4
7
  const style = {
5
8
  // Fixes an issue where loading button makes the editor flicker with a scrollbar
6
9
  overflow: 'hidden'
@@ -17,7 +20,17 @@ export const BaseSearch = ({
17
20
  e.preventDefault();
18
21
  }
19
22
  }, []);
20
- return /*#__PURE__*/React.createElement(LoadingButton, {
23
+ return fg('platform-component-visual-refresh') ? /*#__PURE__*/React.createElement(IconButton, {
24
+ label: label,
25
+ isDisabled: isDisabled,
26
+ testId: "jql-editor-search",
27
+ appearance: 'primary',
28
+ spacing: "compact",
29
+ onClick: onSearch,
30
+ onKeyDown: preventRepeatClick,
31
+ isLoading: isSearching,
32
+ icon: SearchIcon
33
+ }) : /*#__PURE__*/React.createElement(LoadingButton, {
21
34
  "aria-label": label,
22
35
  isDisabled: isDisabled,
23
36
  testId: "jql-editor-search"
@@ -29,7 +42,7 @@ export const BaseSearch = ({
29
42
  onClick: onSearch,
30
43
  onKeyDown: preventRepeatClick,
31
44
  isLoading: isSearching,
32
- iconBefore: /*#__PURE__*/React.createElement(SearchIcon, {
45
+ iconBefore: /*#__PURE__*/React.createElement(SearchIconOld, {
33
46
  label: '',
34
47
  size: 'medium'
35
48
  })
@@ -1,6 +1,10 @@
1
+ import _extends from "@babel/runtime/helpers/extends";
1
2
  import React from 'react';
2
3
  import Button from '@atlaskit/button';
4
+ import { LinkIconButton } from '@atlaskit/button/new';
5
+ import QuestionCircleIcon from '@atlaskit/icon/core/question-circle';
3
6
  import QuestionIcon from '@atlaskit/icon/glyph/question';
7
+ import { fg } from '@atlaskit/platform-feature-flags';
4
8
  import { N0 } from '@atlaskit/theme/colors';
5
9
  import { SyntaxHelpContainer } from './styled';
6
10
  export const BaseSyntaxHelp = ({
@@ -9,7 +13,19 @@ export const BaseSyntaxHelp = ({
9
13
  label,
10
14
  onClick
11
15
  }) => {
12
- return /*#__PURE__*/React.createElement(SyntaxHelpContainer, null, /*#__PURE__*/React.createElement(Button, {
16
+ return fg('platform-component-visual-refresh') ? /*#__PURE__*/React.createElement(LinkIconButton, {
17
+ "aria-describedby": describedby,
18
+ label: label,
19
+ isDisabled: isDisabled,
20
+ appearance: "subtle",
21
+ spacing: "compact",
22
+ onClick: onClick,
23
+ target: "blank",
24
+ href: "https://confluence.atlassian.com/display/SERVICEDESKCLOUD/Advanced+searching",
25
+ icon: iconProps => /*#__PURE__*/React.createElement(QuestionCircleIcon, _extends({}, iconProps, {
26
+ color: "var(--ds-icon-subtle, #626F86)"
27
+ }))
28
+ }) : /*#__PURE__*/React.createElement(SyntaxHelpContainer, null, /*#__PURE__*/React.createElement(Button, {
13
29
  "aria-describedby": describedby,
14
30
  "aria-label": label,
15
31
  isDisabled: isDisabled,
@@ -1,4 +1,5 @@
1
1
  import React from 'react';
2
+ import { fg } from '@atlaskit/platform-feature-flags';
2
3
  import { Box } from '@atlaskit/primitives';
3
4
  import { EditorThemeContext, useEditorTheme, useEditorThemeContext } from '../../hooks/use-editor-theme';
4
5
  import { splitTextByNewLine } from '../../utils/split-text-by-new-line';
@@ -48,7 +49,8 @@ const JQLEditorLayout = props => {
48
49
  onTransitionEnd: onEditorViewTransitionEnd
49
50
  }), /*#__PURE__*/React.createElement(EditorControls, {
50
51
  isSearch: isSearch,
51
- isCompact: isCompact
52
+ isCompact: isCompact,
53
+ isVisualRefresh: fg('platform-component-visual-refresh')
52
54
  }, EditorControlsContent)), /*#__PURE__*/React.createElement(EditorFooter, null, EditorFooterContent));
53
55
  };
54
56
  /**
@@ -250,5 +250,7 @@ export const EditorControls = styled.div(props => ({
250
250
  position: 'sticky',
251
251
  top: 0,
252
252
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
253
- height: `${rowHeight + 2 * getEditorInputVerticalPadding(props.isCompact)}px`
253
+ height: `${rowHeight + 2 * getEditorInputVerticalPadding(props.isCompact)}px`,
254
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
255
+ gap: props.isVisualRefresh ? "var(--ds-space-025, 2px)" : 'unset'
254
256
  }));
@@ -1,4 +1,4 @@
1
1
  import { ANALYTICS_CHANNEL, useJqlPackageAnalytics } from '@atlaskit/jql-editor-common';
2
2
  export var useJqlEditorAnalytics = function useJqlEditorAnalytics(analyticsSource) {
3
- return useJqlPackageAnalytics(analyticsSource, "@atlaskit/jql-editor", "4.7.3", ANALYTICS_CHANNEL);
3
+ return useJqlPackageAnalytics(analyticsSource, "@atlaskit/jql-editor", "4.7.4", ANALYTICS_CHANNEL);
4
4
  };
@@ -1,7 +1,11 @@
1
1
  import React from 'react';
2
2
  import Button from '@atlaskit/button';
3
+ import { IconButton } from '@atlaskit/button/new';
4
+ import GrowDiagonalIcon from '@atlaskit/icon/core/grow-diagonal';
5
+ import ShrinkDiagonalIcon from '@atlaskit/icon/core/shrink-diagonal';
3
6
  import MediaServicesActualSizeIcon from '@atlaskit/icon/glyph/media-services/actual-size';
4
7
  import MediaServicesFitToPageIcon from '@atlaskit/icon/glyph/media-services/fit-to-page';
8
+ import { fg } from '@atlaskit/platform-feature-flags';
5
9
  import { N50, N500 } from '@atlaskit/theme/colors';
6
10
  import { ExpandToggleContainer } from './styled';
7
11
 
@@ -34,7 +38,16 @@ export var BaseExpandToggle = function BaseExpandToggle(_ref3) {
34
38
  } else {
35
39
  Icon = ExpandCircleIcon;
36
40
  }
37
- return /*#__PURE__*/React.createElement(ExpandToggleContainer, null, /*#__PURE__*/React.createElement(Button, {
41
+ return fg('platform-component-visual-refresh') ? /*#__PURE__*/React.createElement(IconButton, {
42
+ appearance: 'subtle',
43
+ spacing: "compact",
44
+ "aria-expanded": expanded,
45
+ "aria-controls": editorId,
46
+ label: label,
47
+ isDisabled: isDisabled,
48
+ onClick: onClick,
49
+ icon: expanded ? ShrinkDiagonalIcon : GrowDiagonalIcon
50
+ }) : /*#__PURE__*/React.createElement(ExpandToggleContainer, null, /*#__PURE__*/React.createElement(Button, {
38
51
  appearance: 'subtle',
39
52
  "aria-expanded": expanded,
40
53
  "aria-controls": editorId,
@@ -1,6 +1,9 @@
1
1
  import React, { useCallback } from 'react';
2
2
  import { LoadingButton } from '@atlaskit/button';
3
- import SearchIcon from '@atlaskit/icon/glyph/editor/search';
3
+ import { IconButton } from '@atlaskit/button/new';
4
+ import SearchIcon from '@atlaskit/icon/core/search';
5
+ import SearchIconOld from '@atlaskit/icon/glyph/editor/search';
6
+ import { fg } from '@atlaskit/platform-feature-flags';
4
7
  var style = {
5
8
  // Fixes an issue where loading button makes the editor flicker with a scrollbar
6
9
  overflow: 'hidden'
@@ -16,7 +19,17 @@ export var BaseSearch = function BaseSearch(_ref) {
16
19
  e.preventDefault();
17
20
  }
18
21
  }, []);
19
- return /*#__PURE__*/React.createElement(LoadingButton, {
22
+ return fg('platform-component-visual-refresh') ? /*#__PURE__*/React.createElement(IconButton, {
23
+ label: label,
24
+ isDisabled: isDisabled,
25
+ testId: "jql-editor-search",
26
+ appearance: 'primary',
27
+ spacing: "compact",
28
+ onClick: onSearch,
29
+ onKeyDown: preventRepeatClick,
30
+ isLoading: isSearching,
31
+ icon: SearchIcon
32
+ }) : /*#__PURE__*/React.createElement(LoadingButton, {
20
33
  "aria-label": label,
21
34
  isDisabled: isDisabled,
22
35
  testId: "jql-editor-search"
@@ -28,7 +41,7 @@ export var BaseSearch = function BaseSearch(_ref) {
28
41
  onClick: onSearch,
29
42
  onKeyDown: preventRepeatClick,
30
43
  isLoading: isSearching,
31
- iconBefore: /*#__PURE__*/React.createElement(SearchIcon, {
44
+ iconBefore: /*#__PURE__*/React.createElement(SearchIconOld, {
32
45
  label: '',
33
46
  size: 'medium'
34
47
  })
@@ -1,6 +1,10 @@
1
+ import _extends from "@babel/runtime/helpers/extends";
1
2
  import React from 'react';
2
3
  import Button from '@atlaskit/button';
4
+ import { LinkIconButton } from '@atlaskit/button/new';
5
+ import QuestionCircleIcon from '@atlaskit/icon/core/question-circle';
3
6
  import QuestionIcon from '@atlaskit/icon/glyph/question';
7
+ import { fg } from '@atlaskit/platform-feature-flags';
4
8
  import { N0 } from '@atlaskit/theme/colors';
5
9
  import { SyntaxHelpContainer } from './styled';
6
10
  export var BaseSyntaxHelp = function BaseSyntaxHelp(_ref) {
@@ -8,7 +12,21 @@ export var BaseSyntaxHelp = function BaseSyntaxHelp(_ref) {
8
12
  isDisabled = _ref.isDisabled,
9
13
  label = _ref.label,
10
14
  onClick = _ref.onClick;
11
- return /*#__PURE__*/React.createElement(SyntaxHelpContainer, null, /*#__PURE__*/React.createElement(Button, {
15
+ return fg('platform-component-visual-refresh') ? /*#__PURE__*/React.createElement(LinkIconButton, {
16
+ "aria-describedby": describedby,
17
+ label: label,
18
+ isDisabled: isDisabled,
19
+ appearance: "subtle",
20
+ spacing: "compact",
21
+ onClick: onClick,
22
+ target: "blank",
23
+ href: "https://confluence.atlassian.com/display/SERVICEDESKCLOUD/Advanced+searching",
24
+ icon: function icon(iconProps) {
25
+ return /*#__PURE__*/React.createElement(QuestionCircleIcon, _extends({}, iconProps, {
26
+ color: "var(--ds-icon-subtle, #626F86)"
27
+ }));
28
+ }
29
+ }) : /*#__PURE__*/React.createElement(SyntaxHelpContainer, null, /*#__PURE__*/React.createElement(Button, {
12
30
  "aria-describedby": describedby,
13
31
  "aria-label": label,
14
32
  isDisabled: isDisabled,
@@ -1,6 +1,7 @@
1
1
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
2
2
  var _excluded = ["isSearch", "isCompact"];
3
3
  import React from 'react';
4
+ import { fg } from '@atlaskit/platform-feature-flags';
4
5
  import { Box } from '@atlaskit/primitives';
5
6
  import { EditorThemeContext, useEditorTheme, useEditorThemeContext } from '../../hooks/use-editor-theme';
6
7
  import { splitTextByNewLine } from '../../utils/split-text-by-new-line';
@@ -47,7 +48,8 @@ var JQLEditorLayout = function JQLEditorLayout(props) {
47
48
  onTransitionEnd: onEditorViewTransitionEnd
48
49
  }), /*#__PURE__*/React.createElement(EditorControls, {
49
50
  isSearch: isSearch,
50
- isCompact: isCompact
51
+ isCompact: isCompact,
52
+ isVisualRefresh: fg('platform-component-visual-refresh')
51
53
  }, EditorControlsContent)), /*#__PURE__*/React.createElement(EditorFooter, null, EditorFooterContent));
52
54
  };
53
55
  /**
@@ -148,6 +148,8 @@ export var EditorControls = styled.div(function (props) {
148
148
  position: 'sticky',
149
149
  top: 0,
150
150
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
151
- height: "".concat(rowHeight + 2 * getEditorInputVerticalPadding(props.isCompact), "px")
151
+ height: "".concat(rowHeight + 2 * getEditorInputVerticalPadding(props.isCompact), "px"),
152
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
153
+ gap: props.isVisualRefresh ? "var(--ds-space-025, 2px)" : 'unset'
152
154
  };
153
155
  });
@@ -60,5 +60,6 @@ export declare const EditorControls: import("@emotion/styled").StyledComponent<{
60
60
  } & {
61
61
  isSearch: boolean;
62
62
  isCompact: boolean;
63
+ isVisualRefresh?: boolean | undefined;
63
64
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
64
65
  export {};
@@ -60,5 +60,6 @@ export declare const EditorControls: import("@emotion/styled").StyledComponent<{
60
60
  } & {
61
61
  isSearch: boolean;
62
62
  isCompact: boolean;
63
+ isVisualRefresh?: boolean | undefined;
63
64
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
64
65
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/jql-editor",
3
- "version": "4.7.3",
3
+ "version": "4.7.4",
4
4
  "description": "This package allows consumers to render an advanced JQL editor component to enable autocomplete-assisted authoring and validation of JQL queries.",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -46,10 +46,11 @@
46
46
  "@atlaskit/jql-autocomplete": "^2.0.0",
47
47
  "@atlaskit/jql-editor-common": "^2.1.0",
48
48
  "@atlaskit/jql-parser": "^2.0.0",
49
+ "@atlaskit/platform-feature-flags": "^0.3.0",
49
50
  "@atlaskit/primitives": "^12.1.0",
50
51
  "@atlaskit/spinner": "^16.3.0",
51
52
  "@atlaskit/theme": "^13.0.0",
52
- "@atlaskit/tokens": "^1.59.0",
53
+ "@atlaskit/tokens": "^1.60.0",
53
54
  "@atlaskit/tooltip": "^18.7.0",
54
55
  "@babel/runtime": "^7.0.0",
55
56
  "@emotion/react": "^11.7.1",
@@ -121,5 +122,10 @@
121
122
  "util"
122
123
  ]
123
124
  }
125
+ },
126
+ "platform-feature-flags": {
127
+ "platform-component-visual-refresh": {
128
+ "type": "boolean"
129
+ }
124
130
  }
125
131
  }