@atlaskit/editor-plugin-table 24.3.10 → 24.3.12
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,19 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-table
|
|
2
2
|
|
|
3
|
+
## 24.3.12
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`df00c17a7cb79`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/df00c17a7cb79) -
|
|
8
|
+
Improve nested table sizing inside fit-to-content tables and snapshot the rendered table layout
|
|
9
|
+
during auto-conversion so the persisted parent table width matches the page-load view.
|
|
10
|
+
|
|
11
|
+
## 24.3.11
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- Updated dependencies
|
|
16
|
+
|
|
3
17
|
## 24.3.10
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
|
@@ -142,6 +142,7 @@ var createPlugin = exports.createPlugin = function createPlugin(dispatchAnalytic
|
|
|
142
142
|
var domAtPos = editorView.domAtPos.bind(editorView);
|
|
143
143
|
editorViewRef = editorView;
|
|
144
144
|
var contentModeSizeTableId = null;
|
|
145
|
+
var hasMeasuredContentModeTables = false;
|
|
145
146
|
var focusListenerBinding = null;
|
|
146
147
|
if ((!(0, _platformFeatureFlags.fg)('platform_editor_table_auto_convert_fix') || !__livePage) && (pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$e = pluginInjectionApi.editorViewMode) === null || _pluginInjectionApi$e === void 0 || (_pluginInjectionApi$e = _pluginInjectionApi$e.sharedState.currentState()) === null || _pluginInjectionApi$e === void 0 ? void 0 : _pluginInjectionApi$e.mode) !== 'view' && (0, _isContentModeSupported.isContentModeSupported)({
|
|
147
148
|
allowColumnResizing: !!pluginConfig.allowColumnResizing,
|
|
@@ -151,6 +152,14 @@ var createPlugin = exports.createPlugin = function createPlugin(dispatchAnalytic
|
|
|
151
152
|
focusListenerBinding = (0, _bindEventListener.bind)(editorView.dom, {
|
|
152
153
|
type: 'focus',
|
|
153
154
|
listener: function listener() {
|
|
155
|
+
if ((0, _platformFeatureFlags.fg)('platform_editor_table_nested_renderer_fix')) {
|
|
156
|
+
if (hasMeasuredContentModeTables || contentModeSizeTableId) {
|
|
157
|
+
return;
|
|
158
|
+
}
|
|
159
|
+
hasMeasuredContentModeTables = true;
|
|
160
|
+
(0, _applyMeasuredWidthToAllTables.applyMeasuredWidthToAllTables)(editorView, pluginInjectionApi);
|
|
161
|
+
return;
|
|
162
|
+
}
|
|
154
163
|
if (contentModeSizeTableId) {
|
|
155
164
|
return;
|
|
156
165
|
}
|
|
@@ -127,6 +127,7 @@ export const createPlugin = (dispatchAnalyticsEvent, dispatch, portalProviderAPI
|
|
|
127
127
|
const domAtPos = editorView.domAtPos.bind(editorView);
|
|
128
128
|
editorViewRef = editorView;
|
|
129
129
|
let contentModeSizeTableId = null;
|
|
130
|
+
let hasMeasuredContentModeTables = false;
|
|
130
131
|
let focusListenerBinding = null;
|
|
131
132
|
if ((!fg('platform_editor_table_auto_convert_fix') || !__livePage) && (pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$e = pluginInjectionApi.editorViewMode) === null || _pluginInjectionApi$e === void 0 ? void 0 : (_pluginInjectionApi$e2 = _pluginInjectionApi$e.sharedState.currentState()) === null || _pluginInjectionApi$e2 === void 0 ? void 0 : _pluginInjectionApi$e2.mode) !== 'view' && isContentModeSupported({
|
|
132
133
|
allowColumnResizing: !!pluginConfig.allowColumnResizing,
|
|
@@ -136,6 +137,14 @@ export const createPlugin = (dispatchAnalyticsEvent, dispatch, portalProviderAPI
|
|
|
136
137
|
focusListenerBinding = bind(editorView.dom, {
|
|
137
138
|
type: 'focus',
|
|
138
139
|
listener: () => {
|
|
140
|
+
if (fg('platform_editor_table_nested_renderer_fix')) {
|
|
141
|
+
if (hasMeasuredContentModeTables || contentModeSizeTableId) {
|
|
142
|
+
return;
|
|
143
|
+
}
|
|
144
|
+
hasMeasuredContentModeTables = true;
|
|
145
|
+
applyMeasuredWidthToAllTables(editorView, pluginInjectionApi);
|
|
146
|
+
return;
|
|
147
|
+
}
|
|
139
148
|
if (contentModeSizeTableId) {
|
|
140
149
|
return;
|
|
141
150
|
}
|
|
@@ -135,6 +135,7 @@ export var createPlugin = function createPlugin(dispatchAnalyticsEvent, dispatch
|
|
|
135
135
|
var domAtPos = editorView.domAtPos.bind(editorView);
|
|
136
136
|
editorViewRef = editorView;
|
|
137
137
|
var contentModeSizeTableId = null;
|
|
138
|
+
var hasMeasuredContentModeTables = false;
|
|
138
139
|
var focusListenerBinding = null;
|
|
139
140
|
if ((!fg('platform_editor_table_auto_convert_fix') || !__livePage) && (pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$e = pluginInjectionApi.editorViewMode) === null || _pluginInjectionApi$e === void 0 || (_pluginInjectionApi$e = _pluginInjectionApi$e.sharedState.currentState()) === null || _pluginInjectionApi$e === void 0 ? void 0 : _pluginInjectionApi$e.mode) !== 'view' && isContentModeSupported({
|
|
140
141
|
allowColumnResizing: !!pluginConfig.allowColumnResizing,
|
|
@@ -144,6 +145,14 @@ export var createPlugin = function createPlugin(dispatchAnalyticsEvent, dispatch
|
|
|
144
145
|
focusListenerBinding = bind(editorView.dom, {
|
|
145
146
|
type: 'focus',
|
|
146
147
|
listener: function listener() {
|
|
148
|
+
if (fg('platform_editor_table_nested_renderer_fix')) {
|
|
149
|
+
if (hasMeasuredContentModeTables || contentModeSizeTableId) {
|
|
150
|
+
return;
|
|
151
|
+
}
|
|
152
|
+
hasMeasuredContentModeTables = true;
|
|
153
|
+
applyMeasuredWidthToAllTables(editorView, pluginInjectionApi);
|
|
154
|
+
return;
|
|
155
|
+
}
|
|
147
156
|
if (contentModeSizeTableId) {
|
|
148
157
|
return;
|
|
149
158
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-table",
|
|
3
|
-
"version": "24.3.
|
|
3
|
+
"version": "24.3.12",
|
|
4
4
|
"description": "Table plugin for the @atlaskit/editor",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"@atlaskit/editor-plugin-batch-attribute-updates": "^12.0.0",
|
|
30
30
|
"@atlaskit/editor-plugin-content-insertion": "^12.0.0",
|
|
31
31
|
"@atlaskit/editor-plugin-editor-viewmode": "^14.0.0",
|
|
32
|
-
"@atlaskit/editor-plugin-extension": "15.0.
|
|
32
|
+
"@atlaskit/editor-plugin-extension": "15.0.19",
|
|
33
33
|
"@atlaskit/editor-plugin-guideline": "^12.0.0",
|
|
34
34
|
"@atlaskit/editor-plugin-interaction": "^22.0.0",
|
|
35
35
|
"@atlaskit/editor-plugin-limited-mode": "^9.0.0",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"@atlaskit/pragmatic-drag-and-drop-auto-scroll": "^3.0.0",
|
|
53
53
|
"@atlaskit/pragmatic-drag-and-drop-hitbox": "^2.0.0",
|
|
54
54
|
"@atlaskit/primitives": "^20.3.0",
|
|
55
|
-
"@atlaskit/tmp-editor-statsig": "^120.
|
|
55
|
+
"@atlaskit/tmp-editor-statsig": "^120.1.0",
|
|
56
56
|
"@atlaskit/toggle": "^17.1.0",
|
|
57
57
|
"@atlaskit/tokens": "^15.3.0",
|
|
58
58
|
"@atlaskit/tooltip": "^23.1.0",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"uuid": "^3.1.0"
|
|
68
68
|
},
|
|
69
69
|
"peerDependencies": {
|
|
70
|
-
"@atlaskit/editor-common": "^116.
|
|
70
|
+
"@atlaskit/editor-common": "^116.21.0",
|
|
71
71
|
"react": "^18.2.0",
|
|
72
72
|
"react-dom": "^18.2.0",
|
|
73
73
|
"react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
|
|
@@ -160,6 +160,9 @@
|
|
|
160
160
|
"platform_editor_table_fixed_column_width_prop": {
|
|
161
161
|
"type": "boolean"
|
|
162
162
|
},
|
|
163
|
+
"platform_editor_table_nested_renderer_fix": {
|
|
164
|
+
"type": "boolean"
|
|
165
|
+
},
|
|
163
166
|
"platform_editor_enable_table_update_ref_atlas": {
|
|
164
167
|
"type": "boolean"
|
|
165
168
|
},
|