mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-19 02:56:23 +08:00
fix: add prefer-dom-node-append rule (#5108)
This commit is contained in:
@@ -231,7 +231,7 @@ const ImagePreviewModalImpl = (
|
||||
const a = document.createElement('a');
|
||||
a.href = downloadUrl;
|
||||
a.download = block.id ?? 'image';
|
||||
document.body.appendChild(a);
|
||||
document.body.append(a);
|
||||
a.click();
|
||||
document.body.removeChild(a);
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@ const Outline = () => {
|
||||
ref={useCallback((container: HTMLDivElement | null) => {
|
||||
if (container) {
|
||||
assertExists(tocPanelRef.current);
|
||||
container.appendChild(tocPanelRef.current);
|
||||
container.append(tocPanelRef.current);
|
||||
}
|
||||
}, [])}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user