prosemirror-tables
Advanced tools
Comparing version 0.7.3 to 0.7.4
{ | ||
"name": "prosemirror-tables", | ||
"version": "0.7.3", | ||
"version": "0.7.4", | ||
"description": "ProseMirror's rowspan/colspan tables component", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -297,3 +297,3 @@ // This file defines a number of table-related commands. | ||
attrs.push(colwidth ? setAttr(baseAttrs, "colwidth", colwidth && colwidth[i] ? [colwidth[i]] : null) : baseAttrs) | ||
let lastCell, cellType = tableNodeTypes(state.schema).cell | ||
let lastCell, cellType = tableNodeTypes(state.schema)[cellNode.type.spec.tableRole]; | ||
for (let row = 0; row < rect.bottom; row++) { | ||
@@ -300,0 +300,0 @@ if (row >= rect.top) { |
@@ -16,4 +16,6 @@ // Various helper function for working with tables | ||
export function cellWrapping($pos) { | ||
for (var d = $pos.depth - 1; d > 0; d--) | ||
if ($pos.node(d).type.spec.tableRole == "cell") return $pos.node(d) | ||
for (let d = $pos.depth - 1; d > 0; d--) { | ||
const role = $pos.node(d).type.spec.tableRole; | ||
if (role === "cell" || role === 'header_cell') return $pos.node(d) | ||
} | ||
return null | ||
@@ -20,0 +22,0 @@ } |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
1011888
19004
0