@atlaskit/editor-plugin-paste 31.0.2 → 31.0.3
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,13 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-paste
|
|
2
2
|
|
|
3
|
+
## 31.0.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`4cdaf1f75d6ad`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4cdaf1f75d6ad) -
|
|
8
|
+
Use const for stable local bindings
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
3
11
|
## 31.0.2
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -126,14 +126,13 @@ var fillIncompleteRowWithEmptyCells = function fillIncompleteRowWithEmptyCells(d
|
|
|
126
126
|
* headers exist.
|
|
127
127
|
*/
|
|
128
128
|
var tryReconstructTableRows = exports.tryReconstructTableRows = function tryReconstructTableRows(doc) {
|
|
129
|
-
// Ignored via go/ees005
|
|
130
|
-
// eslint-disable-next-line prefer-const
|
|
131
129
|
var _getTableElementsInfo = getTableElementsInfo(doc),
|
|
132
|
-
|
|
130
|
+
initialCellCount = _getTableElementsInfo.cellCount,
|
|
133
131
|
thCount = _getTableElementsInfo.thCount,
|
|
134
132
|
mergedCellCount = _getTableElementsInfo.mergedCellCount,
|
|
135
133
|
hasThAfterTd = _getTableElementsInfo.hasThAfterTd,
|
|
136
134
|
hasIncompleteRow = _getTableElementsInfo.hasIncompleteRow;
|
|
135
|
+
var cellCount = initialCellCount;
|
|
137
136
|
if (mergedCellCount || hasThAfterTd) {
|
|
138
137
|
// bail out to avoid handling more complex table structures
|
|
139
138
|
return doc.body.innerHTML;
|
|
@@ -108,15 +108,14 @@ const fillIncompleteRowWithEmptyCells = (doc, thCount, cellCount) => {
|
|
|
108
108
|
* headers exist.
|
|
109
109
|
*/
|
|
110
110
|
export const tryReconstructTableRows = doc => {
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
let {
|
|
114
|
-
cellCount,
|
|
111
|
+
const {
|
|
112
|
+
cellCount: initialCellCount,
|
|
115
113
|
thCount,
|
|
116
114
|
mergedCellCount,
|
|
117
115
|
hasThAfterTd,
|
|
118
116
|
hasIncompleteRow
|
|
119
117
|
} = getTableElementsInfo(doc);
|
|
118
|
+
let cellCount = initialCellCount;
|
|
120
119
|
if (mergedCellCount || hasThAfterTd) {
|
|
121
120
|
// bail out to avoid handling more complex table structures
|
|
122
121
|
return doc.body.innerHTML;
|
|
@@ -119,14 +119,13 @@ var fillIncompleteRowWithEmptyCells = function fillIncompleteRowWithEmptyCells(d
|
|
|
119
119
|
* headers exist.
|
|
120
120
|
*/
|
|
121
121
|
export var tryReconstructTableRows = function tryReconstructTableRows(doc) {
|
|
122
|
-
// Ignored via go/ees005
|
|
123
|
-
// eslint-disable-next-line prefer-const
|
|
124
122
|
var _getTableElementsInfo = getTableElementsInfo(doc),
|
|
125
|
-
|
|
123
|
+
initialCellCount = _getTableElementsInfo.cellCount,
|
|
126
124
|
thCount = _getTableElementsInfo.thCount,
|
|
127
125
|
mergedCellCount = _getTableElementsInfo.mergedCellCount,
|
|
128
126
|
hasThAfterTd = _getTableElementsInfo.hasThAfterTd,
|
|
129
127
|
hasIncompleteRow = _getTableElementsInfo.hasIncompleteRow;
|
|
128
|
+
var cellCount = initialCellCount;
|
|
130
129
|
if (mergedCellCount || hasThAfterTd) {
|
|
131
130
|
// bail out to avoid handling more complex table structures
|
|
132
131
|
return doc.body.innerHTML;
|