mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-26 14:58:55 +08:00
refactor: code of copy
This commit is contained in:
@@ -70,12 +70,15 @@ const AffineBoard = ({
|
||||
set_app(app);
|
||||
},
|
||||
async onCopy(e, groupIds) {
|
||||
const [mimeType, data] = await getClipDataOfBlocksById(
|
||||
const clip = await getClipDataOfBlocksById(
|
||||
editor,
|
||||
groupIds
|
||||
);
|
||||
|
||||
e.clipboardData?.setData(mimeType, data);
|
||||
e.clipboardData?.setData(
|
||||
clip.getMimeType(),
|
||||
clip.getData()
|
||||
);
|
||||
},
|
||||
onChangePage(app, shapes, bindings, assets) {
|
||||
Promise.all(
|
||||
|
||||
Reference in New Issue
Block a user