mirror of
https://github.com/muerwre/orchidmap-front.git
synced 2025-05-04 15:36:40 +07:00
edit route icon proposal
This commit is contained in:
parent
bc98faa9f2
commit
4b96a1bc4f
3 changed files with 57 additions and 19 deletions
src/components
|
@ -138,6 +138,7 @@ class Component extends React.Component<Props> {
|
|||
{...route}
|
||||
key={route._id}
|
||||
openRoute={this.openRoute}
|
||||
tab={tab}
|
||||
/>
|
||||
))
|
||||
}
|
||||
|
|
|
@ -13,24 +13,29 @@ type Props = {
|
|||
};
|
||||
|
||||
export const RouteRow = ({
|
||||
title, distance, created_at, _id, editing, openRoute,
|
||||
title, distance, _id, openRoute, tab,
|
||||
}: Props) => (
|
||||
<div
|
||||
className="route-row"
|
||||
onClick={() => openRoute(_id)}
|
||||
>
|
||||
<div className="route-title">
|
||||
{title || _id}
|
||||
</div>
|
||||
<div className="route-description">
|
||||
<span>
|
||||
<Icon icon="icon-link-1" />
|
||||
{_id}
|
||||
</span>
|
||||
<span>
|
||||
<Icon icon="icon-cycle-1" />
|
||||
{(distance && `${distance} km`) || '0 km'}
|
||||
</span>
|
||||
<div className="route-row-wrapper">
|
||||
<div
|
||||
className="route-row"
|
||||
onClick={() => openRoute(_id)}
|
||||
>
|
||||
<div className="route-row-edit">
|
||||
<Icon icon="icon-edit-1" />
|
||||
</div>
|
||||
<div className="route-title">
|
||||
{title || _id}
|
||||
</div>
|
||||
<div className="route-description">
|
||||
<span>
|
||||
<Icon icon="icon-link-1" />
|
||||
{_id}
|
||||
</span>
|
||||
<span>
|
||||
<Icon icon="icon-cycle-1" />
|
||||
{(distance && `${distance} km`) || '0 km'}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue