import styled from 'styled-components'; import { Text, Favicon, Flex, BoxProps, Icon } from '../../../general'; const BookmarkRow = styled(Flex)` border-radius: 6px; padding: 4px 4px 4px 6px; justify-content: space-between; flex-direction: row; height: 1.875rem; // 30px in rem is 1.875rem align-items: center; text-align: left; `; export type BookmarkProps = { favicon?: string; url: string; title: string; member?: string; width?: number; onNavigate: (url: string) => void; onRemove?: (url: string) => void; } & BoxProps; export const Bookmark = ({ id, favicon, title, url, member = '', width = 270, onNavigate, }: BookmarkProps) => { const textWidth = member ? width - 10 - 110 : width - 10; // TODO handle moon names? or tooltip on hover with full name? return ( ) => { evt.stopPropagation(); onNavigate(url); }} > {favicon ? ( ) : ( )} {title} {member && ( {member} )} {/* ) => { evt.stopPropagation(); onRemove(props.url); }} > */} ); };