fix(core): in page mode, AI replace selection did not correctly replace the selected text (#9179)
Fix issue [BS-1980](https://linear.app/affine-design/issue/BS-1980).
This commit is contained in:
@@ -105,6 +105,7 @@ export const replace = async (
|
|||||||
);
|
);
|
||||||
|
|
||||||
if (textSelection) {
|
if (textSelection) {
|
||||||
|
host.std.command.exec('deleteText', { textSelection });
|
||||||
const { snapshot, job } = await markdownToSnapshot(content, host);
|
const { snapshot, job } = await markdownToSnapshot(content, host);
|
||||||
await job.snapshotToSlice(
|
await job.snapshotToSlice(
|
||||||
snapshot,
|
snapshot,
|
||||||
|
|||||||
Reference in New Issue
Block a user