mirror of
https://github.com/Steffo99/festa.git
synced 2024-12-22 22:54:22 +00:00
Move toolbar depending on the screen width
This commit is contained in:
parent
0d8e7eee43
commit
b4ab31ca09
4 changed files with 27 additions and 3 deletions
|
@ -2,7 +2,7 @@ import {default as classNames} from "classnames"
|
||||||
import { ReactNode } from "react"
|
import { ReactNode } from "react"
|
||||||
|
|
||||||
type ToolBarProps = {
|
type ToolBarProps = {
|
||||||
vertical: "top" | "bottom",
|
vertical: "top" | "bottom" | "vadapt",
|
||||||
horizontal: "left" | "right",
|
horizontal: "left" | "right",
|
||||||
children: ReactNode,
|
children: ReactNode,
|
||||||
}
|
}
|
||||||
|
|
|
@ -75,7 +75,7 @@ export default function PageEventDetail({event}: PageEventDetailProps) {
|
||||||
<title key="title">{event.name} - {t("siteTitle")}</title>
|
<title key="title">{event.name} - {t("siteTitle")}</title>
|
||||||
</Head>
|
</Head>
|
||||||
<EditingContext.Provider value={editState}>
|
<EditingContext.Provider value={editState}>
|
||||||
<ToolBar vertical="bottom" horizontal="right">
|
<ToolBar vertical="vadapt" horizontal="right">
|
||||||
<ToolToggleEditing/>
|
<ToolToggleEditing/>
|
||||||
</ToolBar>
|
</ToolBar>
|
||||||
<ViewEvent
|
<ViewEvent
|
||||||
|
|
|
@ -24,3 +24,14 @@
|
||||||
right: 8px;
|
right: 8px;
|
||||||
flex-direction: row-reverse;
|
flex-direction: row-reverse;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.toolbar-vadapt {
|
||||||
|
top: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 800px) {
|
||||||
|
.toolbar-vadapt {
|
||||||
|
top: unset;
|
||||||
|
bottom: 8px;
|
||||||
|
}
|
||||||
|
}
|
|
@ -6,7 +6,7 @@
|
||||||
"x1 x2 de x3 x4"
|
"x1 x2 de x3 x4"
|
||||||
"x1 x2 dr x3 x4"
|
"x1 x2 dr x3 x4"
|
||||||
;
|
;
|
||||||
grid-template-columns: 3fr 1fr 800px 1fr 3fr;
|
grid-template-columns: 1fr 80px 640px 80px 1fr;
|
||||||
grid-template-rows: auto auto 1fr auto;
|
grid-template-rows: auto auto 1fr auto;
|
||||||
|
|
||||||
row-gap: 4px;
|
row-gap: 4px;
|
||||||
|
@ -14,6 +14,19 @@
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media (max-width: 800px) {
|
||||||
|
.view-event {
|
||||||
|
grid-template-areas:
|
||||||
|
"ti"
|
||||||
|
"po"
|
||||||
|
"de"
|
||||||
|
"dr"
|
||||||
|
;
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
grid-template-rows: auto auto 1fr auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.view-event-title {
|
.view-event-title {
|
||||||
grid-area: ti;
|
grid-area: ti;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
|
Loading…
Reference in a new issue