fix(richtext-lexical): Blocks: z-index issue, e.g. select field dropdown in blocks hidden behind blocks below, or slash menu inside nested editor hidden behind blocks below

This commit is contained in:
Alessio Gravili
2023-11-12 22:28:05 +01:00
parent 615702b858
commit 09f17f4450
3 changed files with 2 additions and 2 deletions

View File

@@ -15,7 +15,6 @@
& > * {
transition: transform 0.2s ease-in-out;
// will-change: transform; // breaks cursor rendering for empty paragraph blocks in safari, and creates other issues
position: relative; // makes sure that z-index properties work - for example for the Blocks feature
}
}

View File

@@ -113,6 +113,7 @@ export const SubBlockBlock: Block = {
},
],
},
SelectFieldBlock,
],
},
],

View File

@@ -300,7 +300,7 @@ describe('lexical', () => {
const textNode1: SerializedTextNode = paragraphNodeInBlockNodeRichText.children[0]
const boldNode: SerializedTextNode = paragraphNodeInBlockNodeRichText.children[1]
expect(textNode1.text).toBe('Some text below ')
expect(textNode1.text).toBe('Some text below r')
expect(textNode1.format).toBe(0)
expect(boldNode.text).toBe('elationship node 1')