@atlaskit/editor-plugin-table 18.1.5 → 18.1.6

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/editor-plugin-table
2
2
 
3
+ ## 18.1.6
4
+
5
+ ### Patch Changes
6
+
7
+ - [`d43c8a96e6740`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/d43c8a96e6740) -
8
+ Gate table ref update dispatch behind tableActive check to avoid unnecessary transactions firing
9
+ for every table on the page
10
+ - [`737087ff3afe7`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/737087ff3afe7) -
11
+ Cleanup experiment platform_editor_change_table_nesting_check
12
+ - Updated dependencies
13
+
3
14
  ## 18.1.5
4
15
 
5
16
  ### Patch Changes
@@ -751,7 +751,7 @@ var TableComponent = /*#__PURE__*/function (_React$Component) {
751
751
  }, {
752
752
  key: "dispatchTableRefUpdate",
753
753
  value: function dispatchTableRefUpdate() {
754
- if (this.table && this.table !== this.lastSetTableRef && this.props.view && (0, _expValEquals.expValEquals)('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && ((0, _expValEquals.expValEquals)('platform_editor_table_update_table_ref', 'isEnabled', true) || (0, _platformFeatureFlags.fg)('platform_editor_enable_table_update_ref_atlas'))) {
754
+ if (this.table && this.table !== this.lastSetTableRef && (!(0, _expValEquals.expValEquals)('platform_editor_table_ref_optimisation', 'isEnabled', true) || this.props.tableActive) && this.props.view && (0, _expValEquals.expValEquals)('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && ((0, _expValEquals.expValEquals)('platform_editor_table_update_table_ref', 'isEnabled', true) || (0, _platformFeatureFlags.fg)('platform_editor_enable_table_update_ref_atlas'))) {
755
755
  this.lastSetTableRef = this.table;
756
756
  (0, _commands.setTableRef)(this.table)(this.props.view.state, this.props.view.dispatch);
757
757
  }
@@ -934,7 +934,7 @@ var TableComponent = /*#__PURE__*/function (_React$Component) {
934
934
 
935
935
  // // Update tableRef in plugin state when table is properly mounted
936
936
  // // At this point, both table and wrapper are in DOM with correct parent-child relationship
937
- if (_this5.table && _this5.props.view && !(0, _expValEquals.expValEquals)('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && ((0, _expValEquals.expValEquals)('platform_editor_table_update_table_ref', 'isEnabled', true) || (0, _platformFeatureFlags.fg)('platform_editor_enable_table_update_ref_atlas'))) {
937
+ if (_this5.table && (!(0, _expValEquals.expValEquals)('platform_editor_table_ref_optimisation', 'isEnabled', true) || _this5.props.tableActive) && _this5.props.view && !(0, _expValEquals.expValEquals)('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && ((0, _expValEquals.expValEquals)('platform_editor_table_update_table_ref', 'isEnabled', true) || (0, _platformFeatureFlags.fg)('platform_editor_enable_table_update_ref_atlas'))) {
938
938
  (0, _commands.setTableRef)(_this5.table)(_this5.props.view.state, _this5.props.view.dispatch);
939
939
  }
940
940
  }
@@ -712,7 +712,7 @@ class TableComponent extends React.Component {
712
712
  this.dispatchTableRefUpdate();
713
713
  }
714
714
  dispatchTableRefUpdate() {
715
- if (this.table && this.table !== this.lastSetTableRef && this.props.view && expValEquals('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && (expValEquals('platform_editor_table_update_table_ref', 'isEnabled', true) || fg('platform_editor_enable_table_update_ref_atlas'))) {
715
+ if (this.table && this.table !== this.lastSetTableRef && (!expValEquals('platform_editor_table_ref_optimisation', 'isEnabled', true) || this.props.tableActive) && this.props.view && expValEquals('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && (expValEquals('platform_editor_table_update_table_ref', 'isEnabled', true) || fg('platform_editor_enable_table_update_ref_atlas'))) {
716
716
  this.lastSetTableRef = this.table;
717
717
  setTableRef(this.table)(this.props.view.state, this.props.view.dispatch);
718
718
  }
@@ -897,7 +897,7 @@ class TableComponent extends React.Component {
897
897
 
898
898
  // // Update tableRef in plugin state when table is properly mounted
899
899
  // // At this point, both table and wrapper are in DOM with correct parent-child relationship
900
- if (this.table && this.props.view && !expValEquals('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && (expValEquals('platform_editor_table_update_table_ref', 'isEnabled', true) || fg('platform_editor_enable_table_update_ref_atlas'))) {
900
+ if (this.table && (!expValEquals('platform_editor_table_ref_optimisation', 'isEnabled', true) || this.props.tableActive) && this.props.view && !expValEquals('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && (expValEquals('platform_editor_table_update_table_ref', 'isEnabled', true) || fg('platform_editor_enable_table_update_ref_atlas'))) {
901
901
  setTableRef(this.table)(this.props.view.state, this.props.view.dispatch);
902
902
  }
903
903
  }
@@ -745,7 +745,7 @@ var TableComponent = /*#__PURE__*/function (_React$Component) {
745
745
  }, {
746
746
  key: "dispatchTableRefUpdate",
747
747
  value: function dispatchTableRefUpdate() {
748
- if (this.table && this.table !== this.lastSetTableRef && this.props.view && expValEquals('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && (expValEquals('platform_editor_table_update_table_ref', 'isEnabled', true) || fg('platform_editor_enable_table_update_ref_atlas'))) {
748
+ if (this.table && this.table !== this.lastSetTableRef && (!expValEquals('platform_editor_table_ref_optimisation', 'isEnabled', true) || this.props.tableActive) && this.props.view && expValEquals('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && (expValEquals('platform_editor_table_update_table_ref', 'isEnabled', true) || fg('platform_editor_enable_table_update_ref_atlas'))) {
749
749
  this.lastSetTableRef = this.table;
750
750
  setTableRef(this.table)(this.props.view.state, this.props.view.dispatch);
751
751
  }
@@ -928,7 +928,7 @@ var TableComponent = /*#__PURE__*/function (_React$Component) {
928
928
 
929
929
  // // Update tableRef in plugin state when table is properly mounted
930
930
  // // At this point, both table and wrapper are in DOM with correct parent-child relationship
931
- if (_this5.table && _this5.props.view && !expValEquals('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && (expValEquals('platform_editor_table_update_table_ref', 'isEnabled', true) || fg('platform_editor_enable_table_update_ref_atlas'))) {
931
+ if (_this5.table && (!expValEquals('platform_editor_table_ref_optimisation', 'isEnabled', true) || _this5.props.tableActive) && _this5.props.view && !expValEquals('platform_editor_fix_editor_unhandled_type_errors', 'isEnabled', true) && (expValEquals('platform_editor_table_update_table_ref', 'isEnabled', true) || fg('platform_editor_enable_table_update_ref_atlas'))) {
932
932
  setTableRef(_this5.table)(_this5.props.view.state, _this5.props.view.dispatch);
933
933
  }
934
934
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-table",
3
- "version": "18.1.5",
3
+ "version": "18.1.6",
4
4
  "description": "Table plugin for the @atlaskit/editor",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -56,7 +56,7 @@
56
56
  "@atlaskit/pragmatic-drag-and-drop-auto-scroll": "^2.1.0",
57
57
  "@atlaskit/pragmatic-drag-and-drop-hitbox": "^1.1.0",
58
58
  "@atlaskit/primitives": "^18.0.0",
59
- "@atlaskit/tmp-editor-statsig": "^44.0.0",
59
+ "@atlaskit/tmp-editor-statsig": "^44.1.0",
60
60
  "@atlaskit/toggle": "^15.2.0",
61
61
  "@atlaskit/tokens": "^11.1.0",
62
62
  "@atlaskit/tooltip": "^21.0.0",
@@ -69,7 +69,7 @@
69
69
  "uuid": "^3.1.0"
70
70
  },
71
71
  "peerDependencies": {
72
- "@atlaskit/editor-common": "^112.7.0",
72
+ "@atlaskit/editor-common": "^112.8.0",
73
73
  "react": "^18.2.0",
74
74
  "react-dom": "^18.2.0",
75
75
  "react-intl-next": "npm:react-intl@^5.18.1"
@@ -135,9 +135,6 @@
135
135
  "platform_editor_table_height_analytics_event": {
136
136
  "type": "boolean"
137
137
  },
138
- "platform_editor_change_table_nesting_check": {
139
- "type": "boolean"
140
- },
141
138
  "platform_editor_table_sticky_header_patch_3": {
142
139
  "type": "boolean"
143
140
  },