feat: render placeholder in edgeless mode (#11387)

Complete [BS-2997](https://linear.app/affine-design/issue/BS-2997/在白板上渲染-inserted-frame-group-时提供占位)
This commit is contained in:
doouding
2025-04-02 06:59:25 +00:00
parent ef76c83184
commit 36b1ca4327
5 changed files with 290 additions and 26 deletions

View File

@@ -71,25 +71,6 @@ describe('basic', () => {
).instanceOf(Element);
});
test('surface-ref should be rendered as empty surface-ref-block-edgeless component page mode', async () => {
const surfaceRefId = doc.addBlock(
'affine:surface-ref',
{
reference: frameId,
},
noteAId
);
await wait();
const refBlock = document.querySelector(
`affine-edgeless-surface-ref[data-block-id="${surfaceRefId}"]`
)! as HTMLElement;
expect(refBlock).instanceOf(Element);
expect(refBlock.innerText).toBe('');
});
test('content in frame should be rendered in the correct order', async () => {
const surfaceRefId = doc.addBlock(
'affine:surface-ref',