// @flow import * as React from 'react'; import { Icon } from '$components/panels/Icon'; import { MapListDialog } from "$components/dialogs/MapListDialog"; import { Tooltip } from "$components/panels/Tooltip"; import { ReactElement } from "react"; import classnames from 'classnames'; interface Props { _id: string, tab: string, title: string, distance: number, is_public: boolean, openRoute: typeof MapListDialog.openRoute, startEditing: typeof MapListDialog.startEditing, stopEditing: typeof MapListDialog.stopEditing, showMenu: typeof MapListDialog.showMenu, hideMenu: typeof MapListDialog.hideMenu, showDropCard: typeof MapListDialog.showDropCard, } export const RouteRowView = ({ title, distance, _id, openRoute, tab, startEditing, showMenu, showDropCard, hideMenu, }: Props): ReactElement => (
openRoute(_id)} >
{(title || _id)}
{_id} {(distance && `${distance} km`) || '0 km'}
{ tab === 'mine' &&
Удалить
Редактировать
}
);