fix: remoteImageSrc to come from resolved source (#5867)

This commit is contained in:
M. Palanikannan 2024-10-18 14:21:07 +05:30 committed by GitHub
parent 81550ab5ef
commit 2982cd47a9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -59,7 +59,7 @@ export const CustomImageBlock: React.FC<CustomImageBlockProps> = (props) => {
src: remoteImageSrc, src: remoteImageSrc,
setEditorContainer, setEditorContainer,
} = props; } = props;
const { src: remoteImageSrc, width: nodeWidth, height: nodeHeight, aspectRatio: nodeAspectRatio } = node.attrs; const { width: nodeWidth, height: nodeHeight, aspectRatio: nodeAspectRatio } = node.attrs;
// states // states
const [size, setSize] = useState<Size>({ const [size, setSize] = useState<Size>({
width: ensurePixelString(nodeWidth, "35%"), width: ensurePixelString(nodeWidth, "35%"),