diff --git a/pkg/interface/src/views/apps/links/components/LinkBlockItem.tsx b/pkg/interface/src/views/apps/links/components/LinkBlockItem.tsx index b490802832..108298a8d5 100644 --- a/pkg/interface/src/views/apps/links/components/LinkBlockItem.tsx +++ b/pkg/interface/src/views/apps/links/components/LinkBlockItem.tsx @@ -34,11 +34,12 @@ export interface LinkBlockItemProps { node: GraphNode; size?: CenterProps['height']; border?: CenterProps['border']; + objectFit?: string; summary?: boolean; } export function LinkBlockItem(props: LinkBlockItemProps & CenterProps) { - const { node, summary, size, m, border = 1, ...rest } = props; + const { node, summary, size, m, border = 1, objectFit, ...rest } = props; const { post, children } = node; const { contents, index, author } = post; @@ -90,7 +91,12 @@ export function LinkBlockItem(props: LinkBlockItemProps & CenterProps) { /> ) ) : isImage ? ( - + ) : isAudio ? ( ) : isOembed ? ( diff --git a/pkg/interface/src/views/apps/links/components/LinkDetail.tsx b/pkg/interface/src/views/apps/links/components/LinkDetail.tsx index 664af6caa5..6981de391d 100644 --- a/pkg/interface/src/views/apps/links/components/LinkDetail.tsx +++ b/pkg/interface/src/views/apps/links/components/LinkDetail.tsx @@ -27,7 +27,16 @@ export function LinkDetail(props: LinkDetailProps) { return ( /* @ts-ignore indio props?? */ - + (e: MouseEvent) { type ImageProps = PropFunc & { objectFit?: string; + stretch?: boolean; }; const Image = styled.img(system({ objectFit: true }), ...allSystemStyle); export function RemoteContentImageEmbed( props: ImageProps & RemoteContentEmbedProps ) { - const { url, ...rest } = props; + const { url, stretch, ...rest } = props; const [noCors, setNoCors] = useState(false); const { hovering, bind } = useHovering(); // maybe images aren't set up for CORS embeds @@ -59,7 +60,13 @@ export function RemoteContentImageEmbed( }, []); return ( - +