@atlaskit/editor-core 198.1.1 → 198.2.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 +12 -0
- package/dist/cjs/ui/ChromeCollapsed/index.js +2 -1
- package/dist/cjs/ui/CollapsedEditor/index.js +2 -1
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/ui/ChromeCollapsed/index.js +2 -1
- package/dist/es2019/ui/CollapsedEditor/index.js +2 -1
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/ui/ChromeCollapsed/index.js +2 -1
- package/dist/esm/ui/CollapsedEditor/index.js +2 -1
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/ui/ChromeCollapsed/index.d.ts +1 -0
- package/dist/types/ui/CollapsedEditor/index.d.ts +1 -0
- package/dist/types-ts4.5/ui/ChromeCollapsed/index.d.ts +1 -0
- package/dist/types-ts4.5/ui/CollapsedEditor/index.d.ts +1 -0
- package/docs/1-legacy-editor.tsx +5 -0
- package/package.json +10 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atlaskit/editor-core
|
|
2
2
|
|
|
3
|
+
## 198.2.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#146905](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/146905)
|
|
8
|
+
[`fde71f816ee10`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/fde71f816ee10) -
|
|
9
|
+
Add AssistiveLabel for CollapsedEditor(passing label down to chrome collapse) to improve a11y
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- Updated dependencies
|
|
14
|
+
|
|
3
15
|
## 198.1.1
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
|
@@ -65,7 +65,8 @@ var ChromeCollapsed = /*#__PURE__*/function (_PureComponent) {
|
|
|
65
65
|
css: _styles.inputStyle,
|
|
66
66
|
ref: this.handleInputRef,
|
|
67
67
|
onFocus: this.focusHandler,
|
|
68
|
-
placeholder: placeholder
|
|
68
|
+
placeholder: placeholder,
|
|
69
|
+
"aria-label": this.props.label
|
|
69
70
|
});
|
|
70
71
|
}
|
|
71
72
|
}]);
|
|
@@ -53,7 +53,8 @@ var CollapsedEditor = exports.default = /*#__PURE__*/function (_React$Component)
|
|
|
53
53
|
if (!this.props.isExpanded) {
|
|
54
54
|
return /*#__PURE__*/_react.default.createElement(_IntlProviderIfMissingWrapper.IntlProviderIfMissingWrapper, null, /*#__PURE__*/_react.default.createElement(_ChromeCollapsed.default, {
|
|
55
55
|
onFocus: this.props.onFocus,
|
|
56
|
-
text: this.props.placeholder
|
|
56
|
+
text: this.props.placeholder,
|
|
57
|
+
label: this.props.assistiveLabel
|
|
57
58
|
}));
|
|
58
59
|
}
|
|
59
60
|
|
|
@@ -25,7 +25,8 @@ export default class CollapsedEditor extends React.Component {
|
|
|
25
25
|
if (!this.props.isExpanded) {
|
|
26
26
|
return /*#__PURE__*/React.createElement(IntlProviderIfMissingWrapper, null, /*#__PURE__*/React.createElement(ChromeCollapsed, {
|
|
27
27
|
onFocus: this.props.onFocus,
|
|
28
|
-
text: this.props.placeholder
|
|
28
|
+
text: this.props.placeholder,
|
|
29
|
+
label: this.props.assistiveLabel
|
|
29
30
|
}));
|
|
30
31
|
}
|
|
31
32
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export const name = "@atlaskit/editor-core";
|
|
2
|
-
export const version = "198.
|
|
2
|
+
export const version = "198.2.0";
|
|
@@ -46,7 +46,8 @@ var CollapsedEditor = /*#__PURE__*/function (_React$Component) {
|
|
|
46
46
|
if (!this.props.isExpanded) {
|
|
47
47
|
return /*#__PURE__*/React.createElement(IntlProviderIfMissingWrapper, null, /*#__PURE__*/React.createElement(ChromeCollapsed, {
|
|
48
48
|
onFocus: this.props.onFocus,
|
|
49
|
-
text: this.props.placeholder
|
|
49
|
+
text: this.props.placeholder,
|
|
50
|
+
label: this.props.assistiveLabel
|
|
50
51
|
}));
|
|
51
52
|
}
|
|
52
53
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export var name = "@atlaskit/editor-core";
|
|
2
|
-
export var version = "198.
|
|
2
|
+
export var version = "198.2.0";
|
|
@@ -7,6 +7,7 @@ import type { WrappedComponentProps } from 'react-intl-next';
|
|
|
7
7
|
export interface Props {
|
|
8
8
|
text?: string;
|
|
9
9
|
onFocus?: (e: React.FocusEvent<HTMLInputElement>) => void;
|
|
10
|
+
label?: string;
|
|
10
11
|
}
|
|
11
12
|
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
|
|
12
13
|
WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
|
|
@@ -7,6 +7,7 @@ import type { WrappedComponentProps } from 'react-intl-next';
|
|
|
7
7
|
export interface Props {
|
|
8
8
|
text?: string;
|
|
9
9
|
onFocus?: (e: React.FocusEvent<HTMLInputElement>) => void;
|
|
10
|
+
label?: string;
|
|
10
11
|
}
|
|
11
12
|
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
|
|
12
13
|
WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
|
package/docs/1-legacy-editor.tsx
CHANGED
|
@@ -74,6 +74,7 @@ ${code`
|
|
|
74
74
|
placeholder="What would you like to say?"
|
|
75
75
|
isExpanded={this.state.isExpanded}
|
|
76
76
|
onFocus={this.expandEditor}
|
|
77
|
+
assistiveLabel="What would you like to say?"
|
|
77
78
|
>
|
|
78
79
|
<Editor
|
|
79
80
|
appearance="comment"
|
|
@@ -90,6 +91,10 @@ ${code`
|
|
|
90
91
|
|
|
91
92
|
EditorContext allows you, in conjunction with WithEditorActions, to manipulate the editor from anywhere inside the EditorContext. In the example below, notice that no reference is kept to the editor instance.
|
|
92
93
|
|
|
94
|
+
## New assistiveLabel prop(optional)
|
|
95
|
+
|
|
96
|
+
assistiveLabel prop allosws you to set an aria-label for ChromeCollapsed to improve a11y
|
|
97
|
+
|
|
93
98
|
${code`
|
|
94
99
|
import { EditorContext, WithEditorActions } from '@atlaskit/editor-core';
|
|
95
100
|
import { CollapsibleEditor } from 'previous-example';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-core",
|
|
3
|
-
"version": "198.
|
|
3
|
+
"version": "198.2.0",
|
|
4
4
|
"description": "A package contains Atlassian editor core functionality",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -43,9 +43,9 @@
|
|
|
43
43
|
"@atlaskit/analytics-next": "^10.1.0",
|
|
44
44
|
"@atlaskit/analytics-next-stable-react-context": "1.0.1",
|
|
45
45
|
"@atlaskit/button": "^20.2.0",
|
|
46
|
-
"@atlaskit/editor-common": "^
|
|
46
|
+
"@atlaskit/editor-common": "^92.0.0",
|
|
47
47
|
"@atlaskit/editor-json-transformer": "^8.18.0",
|
|
48
|
-
"@atlaskit/editor-plugin-quick-insert": "1.4.
|
|
48
|
+
"@atlaskit/editor-plugin-quick-insert": "1.4.4",
|
|
49
49
|
"@atlaskit/editor-plugins": "^5.5.0",
|
|
50
50
|
"@atlaskit/editor-prosemirror": "6.0.0",
|
|
51
51
|
"@atlaskit/editor-shared-styles": "^3.0.0",
|
|
@@ -79,14 +79,14 @@
|
|
|
79
79
|
"react-intl-next": "npm:react-intl@^5.18.1"
|
|
80
80
|
},
|
|
81
81
|
"devDependencies": {
|
|
82
|
-
"@af/editor-examples-helpers": "0.3.
|
|
82
|
+
"@af/editor-examples-helpers": "0.3.16",
|
|
83
83
|
"@af/editor-libra": "*",
|
|
84
84
|
"@af/visual-regression": "*",
|
|
85
85
|
"@atlaskit/adf-utils": "^19.8.0",
|
|
86
86
|
"@atlaskit/analytics-listeners": "^8.11.0",
|
|
87
|
-
"@atlaskit/collab-provider": "9.42.
|
|
88
|
-
"@atlaskit/editor-plugin-annotation": "1.19.
|
|
89
|
-
"@atlaskit/editor-plugin-card": "^3.
|
|
87
|
+
"@atlaskit/collab-provider": "9.42.1",
|
|
88
|
+
"@atlaskit/editor-plugin-annotation": "1.19.10",
|
|
89
|
+
"@atlaskit/editor-plugin-card": "^3.4.0",
|
|
90
90
|
"@atlaskit/editor-plugin-list": "^3.8.0",
|
|
91
91
|
"@atlaskit/editor-plugin-paste": "^1.12.0",
|
|
92
92
|
"@atlaskit/editor-test-helpers": "*",
|
|
@@ -97,15 +97,15 @@
|
|
|
97
97
|
"@atlaskit/media-test-helpers": "^34.4.0",
|
|
98
98
|
"@atlaskit/modal-dialog": "^12.17.0",
|
|
99
99
|
"@atlaskit/primitives": "^12.2.0",
|
|
100
|
-
"@atlaskit/renderer": "^
|
|
101
|
-
"@atlaskit/smart-card": "^
|
|
100
|
+
"@atlaskit/renderer": "^111.0.0",
|
|
101
|
+
"@atlaskit/smart-card": "^29.0.0",
|
|
102
102
|
"@atlaskit/synchrony-test-helpers": "^2.5.0",
|
|
103
103
|
"@atlaskit/toggle": "^13.4.0",
|
|
104
104
|
"@atlaskit/util-data-test": "^17.9.0",
|
|
105
105
|
"@atlaskit/visual-regression": "*",
|
|
106
106
|
"@atlassian/adf-schema-json": "^1.22.0",
|
|
107
107
|
"@atlassian/feature-flags-test-utils": "*",
|
|
108
|
-
"@atlassian/search-provider": "2.4.
|
|
108
|
+
"@atlassian/search-provider": "2.4.141",
|
|
109
109
|
"@emotion/jest": "^11.8.0",
|
|
110
110
|
"@storybook/addon-knobs": "^5.3.18",
|
|
111
111
|
"@testing-library/react": "^12.1.5",
|