chore: fix super table-related styling and deletion behaviors [skip e2e]
This commit is contained in:
@@ -82,6 +82,7 @@ const BlocksEditorTheme: EditorThemeClasses = {
|
|||||||
tableCellSortedIndicator: 'Lexical__tableCellSortedIndicator',
|
tableCellSortedIndicator: 'Lexical__tableCellSortedIndicator',
|
||||||
tableResizeRuler: 'Lexical__tableCellResizeRuler',
|
tableResizeRuler: 'Lexical__tableCellResizeRuler',
|
||||||
tableSelected: 'Lexical__tableSelected',
|
tableSelected: 'Lexical__tableSelected',
|
||||||
|
tableSelection: 'Lexical__tableSelection',
|
||||||
text: {
|
text: {
|
||||||
bold: 'Lexical__textBold',
|
bold: 'Lexical__textBold',
|
||||||
code: 'Lexical__textCode',
|
code: 'Lexical__textCode',
|
||||||
|
|||||||
@@ -116,6 +116,9 @@
|
|||||||
margin: 0.5rem 0;
|
margin: 0.5rem 0;
|
||||||
color: var(--sn-stylekit-contrast-foreground-color);
|
color: var(--sn-stylekit-contrast-foreground-color);
|
||||||
}
|
}
|
||||||
|
.Lexical__tableSelection *::selection {
|
||||||
|
background-color: transparent !important;
|
||||||
|
}
|
||||||
.Lexical__tableSelected {
|
.Lexical__tableSelected {
|
||||||
outline: 2px solid rgb(60, 132, 244);
|
outline: 2px solid rgb(60, 132, 244);
|
||||||
}
|
}
|
||||||
@@ -149,7 +152,7 @@
|
|||||||
top: 0;
|
top: 0;
|
||||||
}
|
}
|
||||||
.Lexical__tableCellHeader {
|
.Lexical__tableCellHeader {
|
||||||
background-color: var(--sn-stylekit-contrast-background-color) !important;
|
background-color: var(--sn-stylekit-contrast-background-color);
|
||||||
border-color: var(--sn-stylekit-contrast-border-color);
|
border-color: var(--sn-stylekit-contrast-border-color);
|
||||||
text-align: start;
|
text-align: start;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -64,6 +64,9 @@ export function RemoveBrokenTablesPlugin() {
|
|||||||
}
|
}
|
||||||
const hasNextSibling = !!node.getNextSibling()
|
const hasNextSibling = !!node.getNextSibling()
|
||||||
const hasPreviousSibling = !!node.getPreviousSibling()
|
const hasPreviousSibling = !!node.getPreviousSibling()
|
||||||
|
if (!node.getParent()) {
|
||||||
|
return
|
||||||
|
}
|
||||||
if (!hasNextSibling) {
|
if (!hasNextSibling) {
|
||||||
node.insertAfter($createParagraphNode())
|
node.insertAfter($createParagraphNode())
|
||||||
} else if (!hasPreviousSibling) {
|
} else if (!hasPreviousSibling) {
|
||||||
|
|||||||
Reference in New Issue
Block a user