a tool for shared writing and social publishing
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

hide image toolbar buttons before image added

+4
+4
components/Toolbar/ImageToolbar.tsx
··· 10 10 let { rep } = useReplicache(); 11 11 let focusedBlock = useUIState((s) => s.focusedEntity)?.entityID || null; 12 12 let isFullBleed = useEntity(focusedBlock, "image/full-bleed")?.data.value; 13 + let hasSrc = useEntity(focusedBlock, "block/image")?.data; 14 + if (!hasSrc) return null; 13 15 14 16 return ( 15 17 <ToolbarButton ··· 42 44 43 45 let setAltEditorOpen = useUIState((s) => s.setOpenPopover); 44 46 let altEditorOpen = useUIState((s) => s.openPopover === focusedBlock); 47 + let hasSrc = useEntity(focusedBlock, "block/image")?.data; 48 + if (!hasSrc) return null; 45 49 46 50 return ( 47 51 <ToolbarButton