@atlaskit/link-picker 1.49.0 → 1.49.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 +18 -0
- package/dist/cjs/ui/error-boundary/error-boundary-fallback/index.compiled.css +1 -0
- package/dist/cjs/ui/error-boundary/error-boundary-fallback/index.js +2 -1
- package/dist/cjs/ui/link-picker/index.js +8 -6
- package/dist/cjs/ui/link-picker/old/index.js +4 -4
- package/dist/cjs/ui/link-picker/search-results/link-search-list/index.compiled.css +1 -0
- package/dist/cjs/ui/link-picker/search-results/link-search-list/index.js +4 -2
- package/dist/cjs/ui/link-picker/text-input/index.compiled.css +3 -2
- package/dist/cjs/ui/link-picker/text-input/index.js +3 -2
- package/dist/cjs/ui/main.js +1 -1
- package/dist/cjs/ui/old/main.js +1 -1
- package/dist/es2019/ui/error-boundary/error-boundary-fallback/index.compiled.css +1 -0
- package/dist/es2019/ui/error-boundary/error-boundary-fallback/index.js +2 -1
- package/dist/es2019/ui/link-picker/index.js +7 -5
- package/dist/es2019/ui/link-picker/old/index.js +3 -3
- package/dist/es2019/ui/link-picker/search-results/link-search-list/index.compiled.css +1 -0
- package/dist/es2019/ui/link-picker/search-results/link-search-list/index.js +4 -2
- package/dist/es2019/ui/link-picker/text-input/index.compiled.css +3 -2
- package/dist/es2019/ui/link-picker/text-input/index.js +3 -2
- package/dist/es2019/ui/main.js +1 -1
- package/dist/es2019/ui/old/main.js +1 -1
- package/dist/esm/ui/error-boundary/error-boundary-fallback/index.compiled.css +1 -0
- package/dist/esm/ui/error-boundary/error-boundary-fallback/index.js +2 -1
- package/dist/esm/ui/link-picker/index.js +8 -6
- package/dist/esm/ui/link-picker/old/index.js +4 -4
- package/dist/esm/ui/link-picker/search-results/link-search-list/index.compiled.css +1 -0
- package/dist/esm/ui/link-picker/search-results/link-search-list/index.js +4 -2
- package/dist/esm/ui/link-picker/text-input/index.compiled.css +3 -2
- package/dist/esm/ui/link-picker/text-input/index.js +3 -2
- package/dist/esm/ui/main.js +1 -1
- package/dist/esm/ui/old/main.js +1 -1
- package/dist/types/common/types.d.ts +2 -6
- package/dist/types-ts4.5/common/types.d.ts +2 -6
- package/package.json +5 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @atlaskit/link-picker
|
|
2
2
|
|
|
3
|
+
## 1.49.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#114253](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/114253)
|
|
8
|
+
[`8d063440a1a02`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8d063440a1a02) -
|
|
9
|
+
Remove the UNSAFE from the UNSAFE_moveSubmitButton prop on the link picker now that it is a
|
|
10
|
+
permanent prop
|
|
11
|
+
|
|
12
|
+
## 1.49.1
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- [#113363](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/113363)
|
|
17
|
+
[`fcdf96ac9b384`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/fcdf96ac9b384) -
|
|
18
|
+
[ux] EDM-11647 Link Picker design token update
|
|
19
|
+
- Updated dependencies
|
|
20
|
+
|
|
3
21
|
## 1.49.0
|
|
4
22
|
|
|
5
23
|
### Minor Changes
|
|
@@ -19,6 +19,7 @@ var _old = require("./old");
|
|
|
19
19
|
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); }
|
|
20
20
|
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; }
|
|
21
21
|
var errorBoundaryFallbackStyles = null;
|
|
22
|
+
var oldErrorBoundaryFallbackStyles = null;
|
|
22
23
|
var messages = (0, _reactIntlNext.defineMessages)({
|
|
23
24
|
heading: {
|
|
24
25
|
defaultMessage: 'Something went wrong!',
|
|
@@ -38,7 +39,7 @@ var ErrorBoundaryFallbackNew = exports.ErrorBoundaryFallbackNew = function Error
|
|
|
38
39
|
return /*#__PURE__*/React.createElement(_minHeightContainer.MinHeightContainer, {
|
|
39
40
|
minHeight: _constants.LINK_PICKER_MIN_HEIGHT_IN_PX_FALLBACK,
|
|
40
41
|
"data-testid": "link-picker-root-error-boundary-ui",
|
|
41
|
-
className: (0, _runtime.ax)(["_vwz44jg8"])
|
|
42
|
+
className: (0, _runtime.ax)([(0, _platformFeatureFlags.fg)('platform-linking-visual-refresh-v1') ? "_11c816g6" : "_vwz44jg8"])
|
|
42
43
|
}, /*#__PURE__*/React.createElement(_emptyState.EmptyState, {
|
|
43
44
|
header: header,
|
|
44
45
|
renderImage: function renderImage() {
|
|
@@ -44,7 +44,9 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
44
44
|
var styles = {
|
|
45
45
|
fullWidthSubmitButton: "_19pkpxbi _1e0c1txw _2lx21bp4"
|
|
46
46
|
};
|
|
47
|
-
var
|
|
47
|
+
var baseRootContainerStyles = null;
|
|
48
|
+
// To be removed when platform-linking-visual-refresh-v1 is removed
|
|
49
|
+
var oldRootContainerStyles = null;
|
|
48
50
|
var formFooterMargin = null;
|
|
49
51
|
var testIds = exports.testIds = _objectSpread(_objectSpread(_objectSpread({
|
|
50
52
|
linkPickerRoot: 'link-picker-root',
|
|
@@ -101,8 +103,8 @@ var LinkPickerNew = exports.LinkPickerNew = (0, _analytics.withLinkPickerAnalyti
|
|
|
101
103
|
isSubmitting = _ref$isSubmitting === void 0 ? false : _ref$isSubmitting,
|
|
102
104
|
_ref$adaptiveHeight = _ref.adaptiveHeight,
|
|
103
105
|
adaptiveHeight = _ref$adaptiveHeight === void 0 ? false : _ref$adaptiveHeight,
|
|
104
|
-
_ref$
|
|
105
|
-
|
|
106
|
+
_ref$moveSubmitButton = _ref.moveSubmitButton,
|
|
107
|
+
moveSubmitButton = _ref$moveSubmitButton === void 0 ? false : _ref$moveSubmitButton;
|
|
106
108
|
var _useAnalyticsEvents = (0, _analyticsNext.useAnalyticsEvents)(),
|
|
107
109
|
createAnalyticsEvent = _useAnalyticsEvents.createAnalyticsEvent;
|
|
108
110
|
var _useReducer = (0, _react.useReducer)(reducer, _objectSpread(_objectSpread({}, initState), {}, {
|
|
@@ -335,7 +337,7 @@ var LinkPickerNew = exports.LinkPickerNew = (0, _analytics.withLinkPickerAnalyti
|
|
|
335
337
|
"data-testid": testIds.linkPicker,
|
|
336
338
|
// Use onSubmitCapture instead of onSubmit so that any possible parent form isn't submitted
|
|
337
339
|
onSubmitCapture: handleSubmit,
|
|
338
|
-
className: (0, _runtime.ax)(["_19bv164s _u5f31pah _ca0q1k79 _n3td1t3k _vchhusvi
|
|
340
|
+
className: (0, _runtime.ax)(["_19bv164s _u5f31pah _ca0q1k79 _n3td1t3k _vchhusvi _1e0ctcjq", !(0, _platformFeatureFlags.fg)('platform-linking-visual-refresh-v1') && "_vwz44jg8"])
|
|
339
341
|
}, /*#__PURE__*/React.createElement(_trackMount.TrackMount, null), isActivePlugin && /*#__PURE__*/React.createElement(_react.Fragment, null, screenReaderText && /*#__PURE__*/React.createElement(_announcer.Announcer, {
|
|
340
342
|
ariaLive: "assertive",
|
|
341
343
|
text: screenReaderText,
|
|
@@ -370,7 +372,7 @@ var LinkPickerNew = exports.LinkPickerNew = (0, _analytics.withLinkPickerAnalyti
|
|
|
370
372
|
readOnly: isSubmitting,
|
|
371
373
|
onClear: handleClear,
|
|
372
374
|
onChange: handleChangeText
|
|
373
|
-
}),
|
|
375
|
+
}), moveSubmitButton && /*#__PURE__*/React.createElement(_compiled.Box, {
|
|
374
376
|
xcss: styles.fullWidthSubmitButton
|
|
375
377
|
}, /*#__PURE__*/React.createElement(_linkPickerSubmitButton.LinkPickerSubmitButton, {
|
|
376
378
|
isEditing: isEditing,
|
|
@@ -416,7 +418,7 @@ var LinkPickerNew = exports.LinkPickerNew = (0, _analytics.withLinkPickerAnalyti
|
|
|
416
418
|
action: pluginAction,
|
|
417
419
|
customSubmitButtonLabel: customSubmitButtonLabel,
|
|
418
420
|
submitMessageId: submitMessageId,
|
|
419
|
-
hideSubmitButton:
|
|
421
|
+
hideSubmitButton: moveSubmitButton,
|
|
420
422
|
className: (0, _runtime.ax)([(!queryState || !(plugins !== null && plugins !== void 0 && plugins.length)) && "_19pkpxbi"])
|
|
421
423
|
}));
|
|
422
424
|
}));
|
|
@@ -111,8 +111,8 @@ var LinkPickerOld = exports.LinkPickerOld = (0, _analytics.withLinkPickerAnalyti
|
|
|
111
111
|
isSubmitting = _ref$isSubmitting === void 0 ? false : _ref$isSubmitting,
|
|
112
112
|
_ref$adaptiveHeight = _ref.adaptiveHeight,
|
|
113
113
|
adaptiveHeight = _ref$adaptiveHeight === void 0 ? false : _ref$adaptiveHeight,
|
|
114
|
-
_ref$
|
|
115
|
-
|
|
114
|
+
_ref$moveSubmitButton = _ref.moveSubmitButton,
|
|
115
|
+
moveSubmitButton = _ref$moveSubmitButton === void 0 ? false : _ref$moveSubmitButton;
|
|
116
116
|
var _useAnalyticsEvents = (0, _analyticsNext.useAnalyticsEvents)(),
|
|
117
117
|
createAnalyticsEvent = _useAnalyticsEvents.createAnalyticsEvent;
|
|
118
118
|
var _useReducer = (0, _react.useReducer)(reducer, _objectSpread(_objectSpread({}, initState), {}, {
|
|
@@ -381,7 +381,7 @@ var LinkPickerOld = exports.LinkPickerOld = (0, _analytics.withLinkPickerAnalyti
|
|
|
381
381
|
readOnly: isSubmitting,
|
|
382
382
|
onClear: handleClear,
|
|
383
383
|
onChange: handleChangeText
|
|
384
|
-
}),
|
|
384
|
+
}), moveSubmitButton && (0, _react2.jsx)(_primitives.Box, {
|
|
385
385
|
xcss: FullWidthSubmitButtonStyles
|
|
386
386
|
}, (0, _react2.jsx)(_linkPickerSubmitButton.LinkPickerSubmitButton, {
|
|
387
387
|
isEditing: isEditing,
|
|
@@ -430,6 +430,6 @@ var LinkPickerOld = exports.LinkPickerOld = (0, _analytics.withLinkPickerAnalyti
|
|
|
430
430
|
css: !queryState || !(plugins !== null && plugins !== void 0 && plugins.length) ? formFooterMargin : undefined,
|
|
431
431
|
customSubmitButtonLabel: customSubmitButtonLabel,
|
|
432
432
|
submitMessageId: submitMessageId,
|
|
433
|
-
hideSubmitButton:
|
|
433
|
+
hideSubmitButton: moveSubmitButton
|
|
434
434
|
}));
|
|
435
435
|
}));
|
|
@@ -35,7 +35,9 @@ var styles = {
|
|
|
35
35
|
var listContainerStyles = null;
|
|
36
36
|
var spinnerContainerStyles = null;
|
|
37
37
|
var listStyles = null;
|
|
38
|
-
var
|
|
38
|
+
var baseListTitleStyles = null;
|
|
39
|
+
var oldListTitleStyles = null;
|
|
40
|
+
var newListTitleStyles = null;
|
|
39
41
|
var messages = exports.messages = (0, _reactIntlNext.defineMessages)({
|
|
40
42
|
titleRecentlyViewed: {
|
|
41
43
|
id: 'fabric.linkPicker.listTitle.recentlyViewed',
|
|
@@ -133,7 +135,7 @@ var LinkSearchListNew = exports.LinkSearchListNew = /*#__PURE__*/(0, _react.forw
|
|
|
133
135
|
itemsContent = /*#__PURE__*/React.createElement(_react.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
134
136
|
id: testIds.resultListTitle,
|
|
135
137
|
"data-testid": testIds.resultListTitle,
|
|
136
|
-
className: (0, _runtime.ax)(["_11c81vlj _k48pmoej
|
|
138
|
+
className: (0, _runtime.ax)(["_11c81vlj _k48pmoej _otyr1b66", (0, _platformFeatureFlags.fg)('platform-linking-visual-refresh-v1') ? "_syaz1gjq" : "_syaz131l"])
|
|
137
139
|
}, /*#__PURE__*/React.createElement(_reactIntlNext.FormattedMessage, linkListTitle)), /*#__PURE__*/React.createElement(_visuallyHidden.default, {
|
|
138
140
|
id: "fabric.smartcard.linkpicker.suggested.results"
|
|
139
141
|
}, hasSearchTerm && /*#__PURE__*/React.createElement(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, messages.searchLinkResults, {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
._19itglyw{border:none}
|
|
1
|
+
._11c816g6{font:var(--ds-font-heading-xxsmall,normal 600 9pt/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,system-ui,"Helvetica Neue",sans-serif)}
|
|
2
|
+
._19itglyw{border:none}
|
|
3
|
+
._19bvze3t{padding-left:var(--ds-space-0,0)}
|
|
3
4
|
._2hwx1b66{margin-right:var(--ds-space-050,4px)}
|
|
4
5
|
._7yjtidpf >div{margin-top:0}
|
|
5
6
|
._bfhksm61{background-color:var(--ds-background-neutral-subtle,#00000000)}
|
|
@@ -33,7 +33,8 @@ var styles = {
|
|
|
33
33
|
* Overriding text input margin top which design system provides as a default spacer
|
|
34
34
|
* but it gets in the way of our layout
|
|
35
35
|
*/
|
|
36
|
-
var
|
|
36
|
+
var baseFieldStyles = null;
|
|
37
|
+
var newFieldStyles = null;
|
|
37
38
|
var testIds = exports.testIds = {
|
|
38
39
|
urlError: 'link-error',
|
|
39
40
|
clearUrlButton: 'clear-text'
|
|
@@ -94,7 +95,7 @@ var TextInputNew = exports.TextInputNew = function TextInputNew(_ref) {
|
|
|
94
95
|
spacing: "spacious"
|
|
95
96
|
})));
|
|
96
97
|
return /*#__PURE__*/React.createElement("div", {
|
|
97
|
-
className: (0, _runtime.ax)(["_7yjtidpf _onzypxbi"])
|
|
98
|
+
className: (0, _runtime.ax)(["_7yjtidpf _onzypxbi", (0, _platformFeatureFlags.fg)('platform-linking-visual-refresh-v1') && "_11c816g6"])
|
|
98
99
|
}, /*#__PURE__*/React.createElement(_form.Field, {
|
|
99
100
|
label: label,
|
|
100
101
|
name: name
|
package/dist/cjs/ui/main.js
CHANGED
|
@@ -28,7 +28,7 @@ var testIds = exports.testIds = {
|
|
|
28
28
|
};
|
|
29
29
|
var PACKAGE_DATA = exports.PACKAGE_DATA = {
|
|
30
30
|
packageName: "@atlaskit/link-picker" || '',
|
|
31
|
-
packageVersion: "1.49.
|
|
31
|
+
packageVersion: "1.49.2" || '',
|
|
32
32
|
componentName: _constants.COMPONENT_NAME,
|
|
33
33
|
source: _constants.COMPONENT_NAME
|
|
34
34
|
};
|
package/dist/cjs/ui/old/main.js
CHANGED
|
@@ -33,7 +33,7 @@ var testIds = exports.testIds = {
|
|
|
33
33
|
};
|
|
34
34
|
var PACKAGE_DATA = exports.PACKAGE_DATA = {
|
|
35
35
|
packageName: "@atlaskit/link-picker" || '',
|
|
36
|
-
packageVersion: "1.49.
|
|
36
|
+
packageVersion: "1.49.2" || '',
|
|
37
37
|
componentName: _constants.COMPONENT_NAME,
|
|
38
38
|
source: _constants.COMPONENT_NAME
|
|
39
39
|
};
|
|
@@ -10,6 +10,7 @@ import { EmptyState } from '../../../common/ui/empty-state';
|
|
|
10
10
|
import { MinHeightContainer } from '../../../common/ui/min-height-container';
|
|
11
11
|
import { ErrorBoundaryFallbackOld } from './old';
|
|
12
12
|
const errorBoundaryFallbackStyles = null;
|
|
13
|
+
const oldErrorBoundaryFallbackStyles = null;
|
|
13
14
|
const messages = defineMessages({
|
|
14
15
|
heading: {
|
|
15
16
|
defaultMessage: 'Something went wrong!',
|
|
@@ -29,7 +30,7 @@ export const ErrorBoundaryFallbackNew = () => {
|
|
|
29
30
|
return /*#__PURE__*/React.createElement(MinHeightContainer, {
|
|
30
31
|
minHeight: LINK_PICKER_MIN_HEIGHT_IN_PX_FALLBACK,
|
|
31
32
|
"data-testid": "link-picker-root-error-boundary-ui",
|
|
32
|
-
className: ax(["_vwz44jg8"])
|
|
33
|
+
className: ax([fg('platform-linking-visual-refresh-v1') ? "_11c816g6" : "_vwz44jg8"])
|
|
33
34
|
}, /*#__PURE__*/React.createElement(EmptyState, {
|
|
34
35
|
header: header,
|
|
35
36
|
renderImage: () => /*#__PURE__*/React.createElement(GenericErrorSVG, null),
|
|
@@ -30,7 +30,9 @@ import { getDataSource, getScreenReaderText } from './utils';
|
|
|
30
30
|
const styles = {
|
|
31
31
|
fullWidthSubmitButton: "_19pkpxbi _1e0c1txw _2lx21bp4"
|
|
32
32
|
};
|
|
33
|
-
const
|
|
33
|
+
const baseRootContainerStyles = null;
|
|
34
|
+
// To be removed when platform-linking-visual-refresh-v1 is removed
|
|
35
|
+
const oldRootContainerStyles = null;
|
|
34
36
|
const formFooterMargin = null;
|
|
35
37
|
export const testIds = {
|
|
36
38
|
linkPickerRoot: 'link-picker-root',
|
|
@@ -92,7 +94,7 @@ export const LinkPickerNew = withLinkPickerAnalyticsContext( /*#__PURE__*/memo((
|
|
|
92
94
|
customMessages,
|
|
93
95
|
isSubmitting = false,
|
|
94
96
|
adaptiveHeight = false,
|
|
95
|
-
|
|
97
|
+
moveSubmitButton = false
|
|
96
98
|
}) => {
|
|
97
99
|
const {
|
|
98
100
|
createAnalyticsEvent
|
|
@@ -329,7 +331,7 @@ export const LinkPickerNew = withLinkPickerAnalyticsContext( /*#__PURE__*/memo((
|
|
|
329
331
|
"data-testid": testIds.linkPicker,
|
|
330
332
|
// Use onSubmitCapture instead of onSubmit so that any possible parent form isn't submitted
|
|
331
333
|
onSubmitCapture: handleSubmit,
|
|
332
|
-
className: ax(["_19bv164s _u5f31pah _ca0q1k79 _n3td1t3k _vchhusvi
|
|
334
|
+
className: ax(["_19bv164s _u5f31pah _ca0q1k79 _n3td1t3k _vchhusvi _1e0ctcjq", !fg('platform-linking-visual-refresh-v1') && "_vwz44jg8"])
|
|
333
335
|
}, /*#__PURE__*/React.createElement(TrackMount, null), isActivePlugin && /*#__PURE__*/React.createElement(Fragment, null, screenReaderText && /*#__PURE__*/React.createElement(Announcer, {
|
|
334
336
|
ariaLive: "assertive",
|
|
335
337
|
text: screenReaderText,
|
|
@@ -364,7 +366,7 @@ export const LinkPickerNew = withLinkPickerAnalyticsContext( /*#__PURE__*/memo((
|
|
|
364
366
|
readOnly: isSubmitting,
|
|
365
367
|
onClear: handleClear,
|
|
366
368
|
onChange: handleChangeText
|
|
367
|
-
}),
|
|
369
|
+
}), moveSubmitButton && /*#__PURE__*/React.createElement(Box, {
|
|
368
370
|
xcss: styles.fullWidthSubmitButton
|
|
369
371
|
}, /*#__PURE__*/React.createElement(LinkPickerSubmitButton, {
|
|
370
372
|
isEditing: isEditing,
|
|
@@ -410,7 +412,7 @@ export const LinkPickerNew = withLinkPickerAnalyticsContext( /*#__PURE__*/memo((
|
|
|
410
412
|
action: pluginAction,
|
|
411
413
|
customSubmitButtonLabel: customSubmitButtonLabel,
|
|
412
414
|
submitMessageId: submitMessageId,
|
|
413
|
-
hideSubmitButton:
|
|
415
|
+
hideSubmitButton: moveSubmitButton,
|
|
414
416
|
className: ax([(!queryState || !(plugins !== null && plugins !== void 0 && plugins.length)) && "_19pkpxbi"])
|
|
415
417
|
}));
|
|
416
418
|
}));
|
|
@@ -109,7 +109,7 @@ export const LinkPickerOld = withLinkPickerAnalyticsContext( /*#__PURE__*/memo((
|
|
|
109
109
|
customMessages,
|
|
110
110
|
isSubmitting = false,
|
|
111
111
|
adaptiveHeight = false,
|
|
112
|
-
|
|
112
|
+
moveSubmitButton = false
|
|
113
113
|
}) => {
|
|
114
114
|
const {
|
|
115
115
|
createAnalyticsEvent
|
|
@@ -382,7 +382,7 @@ export const LinkPickerOld = withLinkPickerAnalyticsContext( /*#__PURE__*/memo((
|
|
|
382
382
|
readOnly: isSubmitting,
|
|
383
383
|
onClear: handleClear,
|
|
384
384
|
onChange: handleChangeText
|
|
385
|
-
}),
|
|
385
|
+
}), moveSubmitButton && jsx(Box, {
|
|
386
386
|
xcss: FullWidthSubmitButtonStyles
|
|
387
387
|
}, jsx(LinkPickerSubmitButton, {
|
|
388
388
|
isEditing: isEditing,
|
|
@@ -431,6 +431,6 @@ export const LinkPickerOld = withLinkPickerAnalyticsContext( /*#__PURE__*/memo((
|
|
|
431
431
|
css: !queryState || !(plugins !== null && plugins !== void 0 && plugins.length) ? formFooterMargin : undefined,
|
|
432
432
|
customSubmitButtonLabel: customSubmitButtonLabel,
|
|
433
433
|
submitMessageId: submitMessageId,
|
|
434
|
-
hideSubmitButton:
|
|
434
|
+
hideSubmitButton: moveSubmitButton
|
|
435
435
|
}));
|
|
436
436
|
}));
|
|
@@ -20,7 +20,9 @@ const styles = {
|
|
|
20
20
|
const listContainerStyles = null;
|
|
21
21
|
const spinnerContainerStyles = null;
|
|
22
22
|
const listStyles = null;
|
|
23
|
-
const
|
|
23
|
+
const baseListTitleStyles = null;
|
|
24
|
+
const oldListTitleStyles = null;
|
|
25
|
+
const newListTitleStyles = null;
|
|
24
26
|
export const messages = defineMessages({
|
|
25
27
|
titleRecentlyViewed: {
|
|
26
28
|
id: 'fabric.linkPicker.listTitle.recentlyViewed',
|
|
@@ -121,7 +123,7 @@ export const LinkSearchListNew = /*#__PURE__*/forwardRef(({
|
|
|
121
123
|
itemsContent = /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
122
124
|
id: testIds.resultListTitle,
|
|
123
125
|
"data-testid": testIds.resultListTitle,
|
|
124
|
-
className: ax(["_11c81vlj _k48pmoej
|
|
126
|
+
className: ax(["_11c81vlj _k48pmoej _otyr1b66", fg('platform-linking-visual-refresh-v1') ? "_syaz1gjq" : "_syaz131l"])
|
|
125
127
|
}, /*#__PURE__*/React.createElement(FormattedMessage, linkListTitle)), /*#__PURE__*/React.createElement(VisuallyHidden, {
|
|
126
128
|
id: "fabric.smartcard.linkpicker.suggested.results"
|
|
127
129
|
}, hasSearchTerm && /*#__PURE__*/React.createElement(FormattedMessage, _extends({}, messages.searchLinkResults, {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
._19itglyw{border:none}
|
|
1
|
+
._11c816g6{font:var(--ds-font-heading-xxsmall,normal 600 9pt/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,system-ui,"Helvetica Neue",sans-serif)}
|
|
2
|
+
._19itglyw{border:none}
|
|
3
|
+
._19bvze3t{padding-left:var(--ds-space-0,0)}
|
|
3
4
|
._2hwx1b66{margin-right:var(--ds-space-050,4px)}
|
|
4
5
|
._7yjtidpf >div{margin-top:0}
|
|
5
6
|
._bfhksm61{background-color:var(--ds-background-neutral-subtle,#00000000)}
|
|
@@ -21,7 +21,8 @@ const styles = {
|
|
|
21
21
|
* Overriding text input margin top which design system provides as a default spacer
|
|
22
22
|
* but it gets in the way of our layout
|
|
23
23
|
*/
|
|
24
|
-
const
|
|
24
|
+
const baseFieldStyles = null;
|
|
25
|
+
const newFieldStyles = null;
|
|
25
26
|
export const testIds = {
|
|
26
27
|
urlError: 'link-error',
|
|
27
28
|
clearUrlButton: 'clear-text'
|
|
@@ -83,7 +84,7 @@ export const TextInputNew = ({
|
|
|
83
84
|
spacing: "spacious"
|
|
84
85
|
})));
|
|
85
86
|
return /*#__PURE__*/React.createElement("div", {
|
|
86
|
-
className: ax(["_7yjtidpf _onzypxbi"])
|
|
87
|
+
className: ax(["_7yjtidpf _onzypxbi", fg('platform-linking-visual-refresh-v1') && "_11c816g6"])
|
|
87
88
|
}, /*#__PURE__*/React.createElement(Field, {
|
|
88
89
|
label: label,
|
|
89
90
|
name: name
|
package/dist/es2019/ui/main.js
CHANGED
|
@@ -10,6 +10,7 @@ import { EmptyState } from '../../../common/ui/empty-state';
|
|
|
10
10
|
import { MinHeightContainer } from '../../../common/ui/min-height-container';
|
|
11
11
|
import { ErrorBoundaryFallbackOld } from './old';
|
|
12
12
|
var errorBoundaryFallbackStyles = null;
|
|
13
|
+
var oldErrorBoundaryFallbackStyles = null;
|
|
13
14
|
var messages = defineMessages({
|
|
14
15
|
heading: {
|
|
15
16
|
defaultMessage: 'Something went wrong!',
|
|
@@ -29,7 +30,7 @@ export var ErrorBoundaryFallbackNew = function ErrorBoundaryFallbackNew() {
|
|
|
29
30
|
return /*#__PURE__*/React.createElement(MinHeightContainer, {
|
|
30
31
|
minHeight: LINK_PICKER_MIN_HEIGHT_IN_PX_FALLBACK,
|
|
31
32
|
"data-testid": "link-picker-root-error-boundary-ui",
|
|
32
|
-
className: ax(["_vwz44jg8"])
|
|
33
|
+
className: ax([fg('platform-linking-visual-refresh-v1') ? "_11c816g6" : "_vwz44jg8"])
|
|
33
34
|
}, /*#__PURE__*/React.createElement(EmptyState, {
|
|
34
35
|
header: header,
|
|
35
36
|
renderImage: function renderImage() {
|
|
@@ -34,7 +34,9 @@ import { getDataSource, getScreenReaderText } from './utils';
|
|
|
34
34
|
var styles = {
|
|
35
35
|
fullWidthSubmitButton: "_19pkpxbi _1e0c1txw _2lx21bp4"
|
|
36
36
|
};
|
|
37
|
-
var
|
|
37
|
+
var baseRootContainerStyles = null;
|
|
38
|
+
// To be removed when platform-linking-visual-refresh-v1 is removed
|
|
39
|
+
var oldRootContainerStyles = null;
|
|
38
40
|
var formFooterMargin = null;
|
|
39
41
|
export var testIds = _objectSpread(_objectSpread(_objectSpread({
|
|
40
42
|
linkPickerRoot: 'link-picker-root',
|
|
@@ -91,8 +93,8 @@ export var LinkPickerNew = withLinkPickerAnalyticsContext( /*#__PURE__*/memo(fun
|
|
|
91
93
|
isSubmitting = _ref$isSubmitting === void 0 ? false : _ref$isSubmitting,
|
|
92
94
|
_ref$adaptiveHeight = _ref.adaptiveHeight,
|
|
93
95
|
adaptiveHeight = _ref$adaptiveHeight === void 0 ? false : _ref$adaptiveHeight,
|
|
94
|
-
_ref$
|
|
95
|
-
|
|
96
|
+
_ref$moveSubmitButton = _ref.moveSubmitButton,
|
|
97
|
+
moveSubmitButton = _ref$moveSubmitButton === void 0 ? false : _ref$moveSubmitButton;
|
|
96
98
|
var _useAnalyticsEvents = useAnalyticsEvents(),
|
|
97
99
|
createAnalyticsEvent = _useAnalyticsEvents.createAnalyticsEvent;
|
|
98
100
|
var _useReducer = useReducer(reducer, _objectSpread(_objectSpread({}, initState), {}, {
|
|
@@ -325,7 +327,7 @@ export var LinkPickerNew = withLinkPickerAnalyticsContext( /*#__PURE__*/memo(fun
|
|
|
325
327
|
"data-testid": testIds.linkPicker,
|
|
326
328
|
// Use onSubmitCapture instead of onSubmit so that any possible parent form isn't submitted
|
|
327
329
|
onSubmitCapture: handleSubmit,
|
|
328
|
-
className: ax(["_19bv164s _u5f31pah _ca0q1k79 _n3td1t3k _vchhusvi
|
|
330
|
+
className: ax(["_19bv164s _u5f31pah _ca0q1k79 _n3td1t3k _vchhusvi _1e0ctcjq", !fg('platform-linking-visual-refresh-v1') && "_vwz44jg8"])
|
|
329
331
|
}, /*#__PURE__*/React.createElement(TrackMount, null), isActivePlugin && /*#__PURE__*/React.createElement(Fragment, null, screenReaderText && /*#__PURE__*/React.createElement(Announcer, {
|
|
330
332
|
ariaLive: "assertive",
|
|
331
333
|
text: screenReaderText,
|
|
@@ -360,7 +362,7 @@ export var LinkPickerNew = withLinkPickerAnalyticsContext( /*#__PURE__*/memo(fun
|
|
|
360
362
|
readOnly: isSubmitting,
|
|
361
363
|
onClear: handleClear,
|
|
362
364
|
onChange: handleChangeText
|
|
363
|
-
}),
|
|
365
|
+
}), moveSubmitButton && /*#__PURE__*/React.createElement(Box, {
|
|
364
366
|
xcss: styles.fullWidthSubmitButton
|
|
365
367
|
}, /*#__PURE__*/React.createElement(LinkPickerSubmitButton, {
|
|
366
368
|
isEditing: isEditing,
|
|
@@ -406,7 +408,7 @@ export var LinkPickerNew = withLinkPickerAnalyticsContext( /*#__PURE__*/memo(fun
|
|
|
406
408
|
action: pluginAction,
|
|
407
409
|
customSubmitButtonLabel: customSubmitButtonLabel,
|
|
408
410
|
submitMessageId: submitMessageId,
|
|
409
|
-
hideSubmitButton:
|
|
411
|
+
hideSubmitButton: moveSubmitButton,
|
|
410
412
|
className: ax([(!queryState || !(plugins !== null && plugins !== void 0 && plugins.length)) && "_19pkpxbi"])
|
|
411
413
|
}));
|
|
412
414
|
}));
|
|
@@ -108,8 +108,8 @@ export var LinkPickerOld = withLinkPickerAnalyticsContext( /*#__PURE__*/memo(fun
|
|
|
108
108
|
isSubmitting = _ref$isSubmitting === void 0 ? false : _ref$isSubmitting,
|
|
109
109
|
_ref$adaptiveHeight = _ref.adaptiveHeight,
|
|
110
110
|
adaptiveHeight = _ref$adaptiveHeight === void 0 ? false : _ref$adaptiveHeight,
|
|
111
|
-
_ref$
|
|
112
|
-
|
|
111
|
+
_ref$moveSubmitButton = _ref.moveSubmitButton,
|
|
112
|
+
moveSubmitButton = _ref$moveSubmitButton === void 0 ? false : _ref$moveSubmitButton;
|
|
113
113
|
var _useAnalyticsEvents = useAnalyticsEvents(),
|
|
114
114
|
createAnalyticsEvent = _useAnalyticsEvents.createAnalyticsEvent;
|
|
115
115
|
var _useReducer = useReducer(reducer, _objectSpread(_objectSpread({}, initState), {}, {
|
|
@@ -378,7 +378,7 @@ export var LinkPickerOld = withLinkPickerAnalyticsContext( /*#__PURE__*/memo(fun
|
|
|
378
378
|
readOnly: isSubmitting,
|
|
379
379
|
onClear: handleClear,
|
|
380
380
|
onChange: handleChangeText
|
|
381
|
-
}),
|
|
381
|
+
}), moveSubmitButton && jsx(Box, {
|
|
382
382
|
xcss: FullWidthSubmitButtonStyles
|
|
383
383
|
}, jsx(LinkPickerSubmitButton, {
|
|
384
384
|
isEditing: isEditing,
|
|
@@ -427,6 +427,6 @@ export var LinkPickerOld = withLinkPickerAnalyticsContext( /*#__PURE__*/memo(fun
|
|
|
427
427
|
css: !queryState || !(plugins !== null && plugins !== void 0 && plugins.length) ? formFooterMargin : undefined,
|
|
428
428
|
customSubmitButtonLabel: customSubmitButtonLabel,
|
|
429
429
|
submitMessageId: submitMessageId,
|
|
430
|
-
hideSubmitButton:
|
|
430
|
+
hideSubmitButton: moveSubmitButton
|
|
431
431
|
}));
|
|
432
432
|
}));
|
|
@@ -25,7 +25,9 @@ var styles = {
|
|
|
25
25
|
var listContainerStyles = null;
|
|
26
26
|
var spinnerContainerStyles = null;
|
|
27
27
|
var listStyles = null;
|
|
28
|
-
var
|
|
28
|
+
var baseListTitleStyles = null;
|
|
29
|
+
var oldListTitleStyles = null;
|
|
30
|
+
var newListTitleStyles = null;
|
|
29
31
|
export var messages = defineMessages({
|
|
30
32
|
titleRecentlyViewed: {
|
|
31
33
|
id: 'fabric.linkPicker.listTitle.recentlyViewed',
|
|
@@ -123,7 +125,7 @@ export var LinkSearchListNew = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
123
125
|
itemsContent = /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
124
126
|
id: testIds.resultListTitle,
|
|
125
127
|
"data-testid": testIds.resultListTitle,
|
|
126
|
-
className: ax(["_11c81vlj _k48pmoej
|
|
128
|
+
className: ax(["_11c81vlj _k48pmoej _otyr1b66", fg('platform-linking-visual-refresh-v1') ? "_syaz1gjq" : "_syaz131l"])
|
|
127
129
|
}, /*#__PURE__*/React.createElement(FormattedMessage, linkListTitle)), /*#__PURE__*/React.createElement(VisuallyHidden, {
|
|
128
130
|
id: "fabric.smartcard.linkpicker.suggested.results"
|
|
129
131
|
}, hasSearchTerm && /*#__PURE__*/React.createElement(FormattedMessage, _extends({}, messages.searchLinkResults, {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
._19itglyw{border:none}
|
|
1
|
+
._11c816g6{font:var(--ds-font-heading-xxsmall,normal 600 9pt/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,system-ui,"Helvetica Neue",sans-serif)}
|
|
2
|
+
._19itglyw{border:none}
|
|
3
|
+
._19bvze3t{padding-left:var(--ds-space-0,0)}
|
|
3
4
|
._2hwx1b66{margin-right:var(--ds-space-050,4px)}
|
|
4
5
|
._7yjtidpf >div{margin-top:0}
|
|
5
6
|
._bfhksm61{background-color:var(--ds-background-neutral-subtle,#00000000)}
|
|
@@ -23,7 +23,8 @@ var styles = {
|
|
|
23
23
|
* Overriding text input margin top which design system provides as a default spacer
|
|
24
24
|
* but it gets in the way of our layout
|
|
25
25
|
*/
|
|
26
|
-
var
|
|
26
|
+
var baseFieldStyles = null;
|
|
27
|
+
var newFieldStyles = null;
|
|
27
28
|
export var testIds = {
|
|
28
29
|
urlError: 'link-error',
|
|
29
30
|
clearUrlButton: 'clear-text'
|
|
@@ -84,7 +85,7 @@ export var TextInputNew = function TextInputNew(_ref) {
|
|
|
84
85
|
spacing: "spacious"
|
|
85
86
|
})));
|
|
86
87
|
return /*#__PURE__*/React.createElement("div", {
|
|
87
|
-
className: ax(["_7yjtidpf _onzypxbi"])
|
|
88
|
+
className: ax(["_7yjtidpf _onzypxbi", fg('platform-linking-visual-refresh-v1') && "_11c816g6"])
|
|
88
89
|
}, /*#__PURE__*/React.createElement(Field, {
|
|
89
90
|
label: label,
|
|
90
91
|
name: name
|
package/dist/esm/ui/main.js
CHANGED
package/dist/esm/ui/old/main.js
CHANGED
|
@@ -149,12 +149,8 @@ export interface LinkPickerProps {
|
|
|
149
149
|
featureFlags?: Record<string, unknown>;
|
|
150
150
|
/** Controls showing a "submission in-progres" UX */
|
|
151
151
|
isSubmitting?: boolean;
|
|
152
|
-
/**
|
|
153
|
-
|
|
154
|
-
* This prop controls where the submit button appears. When true the submit button will move below the input field and be full width
|
|
155
|
-
* @internal
|
|
156
|
-
* */
|
|
157
|
-
UNSAFE_moveSubmitButton?: boolean;
|
|
152
|
+
/** This prop controls where the submit button appears. When true the submit button will move below the input field and be full width */
|
|
153
|
+
moveSubmitButton?: boolean;
|
|
158
154
|
}
|
|
159
155
|
type CustomLinkPickerMessages = {
|
|
160
156
|
/** Label for the link input field */
|
|
@@ -152,12 +152,8 @@ export interface LinkPickerProps {
|
|
|
152
152
|
featureFlags?: Record<string, unknown>;
|
|
153
153
|
/** Controls showing a "submission in-progres" UX */
|
|
154
154
|
isSubmitting?: boolean;
|
|
155
|
-
/**
|
|
156
|
-
|
|
157
|
-
* This prop controls where the submit button appears. When true the submit button will move below the input field and be full width
|
|
158
|
-
* @internal
|
|
159
|
-
* */
|
|
160
|
-
UNSAFE_moveSubmitButton?: boolean;
|
|
155
|
+
/** This prop controls where the submit button appears. When true the submit button will move below the input field and be full width */
|
|
156
|
+
moveSubmitButton?: boolean;
|
|
161
157
|
}
|
|
162
158
|
type CustomLinkPickerMessages = {
|
|
163
159
|
/** Label for the link input field */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/link-picker",
|
|
3
|
-
"version": "1.49.
|
|
3
|
+
"version": "1.49.2",
|
|
4
4
|
"description": "Standalone link picker",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"publishConfig": {
|
|
@@ -39,6 +39,9 @@
|
|
|
39
39
|
"platform-feature-flags": {
|
|
40
40
|
"platform_bandicoots-link-picker-css": {
|
|
41
41
|
"type": "boolean"
|
|
42
|
+
},
|
|
43
|
+
"platform-linking-visual-refresh-v1": {
|
|
44
|
+
"type": "boolean"
|
|
42
45
|
}
|
|
43
46
|
},
|
|
44
47
|
"scripts": {
|
|
@@ -52,7 +55,7 @@
|
|
|
52
55
|
"@atlaskit/form": "^11.1.0",
|
|
53
56
|
"@atlaskit/frontend-utilities": "^2.9.0",
|
|
54
57
|
"@atlaskit/heading": "^4.1.0",
|
|
55
|
-
"@atlaskit/icon": "^23.
|
|
58
|
+
"@atlaskit/icon": "^23.9.0",
|
|
56
59
|
"@atlaskit/intl-messages-provider": "^1.1.0",
|
|
57
60
|
"@atlaskit/linking-common": "^6.3.0",
|
|
58
61
|
"@atlaskit/onboarding": "^12.3.0",
|