import PropTypes from 'prop-types'; import { h, Component, createRef } from 'preact'; import { listingPropTypes } from './listingPropTypes'; import { Button, Dropdown } from '@crayons'; import { locale } from '@utilities/locale'; const Icon = () => ( ); export class DropdownMenu extends Component { componentRef = createRef(); static propTypes = { isOwner: PropTypes.bool.isRequired, listing: listingPropTypes.isRequired, }; render() { const { listing, isOwner, isModal } = this.props; const { id, category, slug } = listing; const editUrl = `/listings/${id}/edit`; const reportUrl = `/report-abuse?url=https://dev.to/listings/${category}/${slug}`; return (