mirror of
https://github.com/muerwre/orchidmap-front.git
synced 2025-04-25 11:06:40 +07:00
dialogs: head
This commit is contained in:
parent
09658b8126
commit
3de025b0df
3 changed files with 40 additions and 15 deletions
|
@ -9,7 +9,7 @@ module.exports = async (req, res) => {
|
|||
path: 'routes',
|
||||
select: '_id title distance owner updated_at',
|
||||
options: {
|
||||
limit: 20,
|
||||
limit: 200,
|
||||
sort: { updated_at: -1 },
|
||||
}
|
||||
});
|
||||
|
|
|
@ -13,9 +13,16 @@ type Props = {
|
|||
};
|
||||
|
||||
const Component = ({ routes, editing, routes_sorted }: Props) => (
|
||||
<Scroll
|
||||
className="dialog-content"
|
||||
>
|
||||
<div className="dialog-content">
|
||||
<div className="dialog-head">
|
||||
<div className="dialog-head-title">
|
||||
Ваши маршруты
|
||||
</div>
|
||||
<div className="small gray">
|
||||
({routes_sorted.length} шт.)
|
||||
</div>
|
||||
</div>
|
||||
<Scroll className="dialog-shader">
|
||||
<div className="dialog-maplist">
|
||||
{
|
||||
routes_sorted.map(id => (
|
||||
|
@ -28,6 +35,7 @@ const Component = ({ routes, editing, routes_sorted }: Props) => (
|
|||
}
|
||||
</div>
|
||||
</Scroll>
|
||||
</div>
|
||||
);
|
||||
|
||||
const mapStateToProps = ({ user: { editing, user: { routes } } }) => ({
|
||||
|
|
|
@ -32,6 +32,11 @@
|
|||
border-radius: @panel_radius;
|
||||
box-shadow: @dialog_shadow;
|
||||
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.dialog-shader {
|
||||
&::before, &::after {
|
||||
content: ' ';
|
||||
height: 40px;
|
||||
|
@ -104,3 +109,15 @@
|
|||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
|
||||
.dialog-head {
|
||||
background: rgba(255, 255, 255, 0.1);
|
||||
padding: 10px;
|
||||
border-radius: @panel_radius @panel_radius 0 0;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.dialog-head-title {
|
||||
font-size: 20px;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue