2022-11-25 18:52:46 +00:00
|
|
|
|
import { Typography, Box, useTheme, InputBase, useMediaQuery, IconButton, FormControl, InputAdornment } from "@mui/material";
|
2022-11-23 11:46:04 +00:00
|
|
|
|
import { useState } from "react";
|
|
|
|
|
import CustomButton from "../../components/CustomButton";
|
|
|
|
|
import SectionWrapper from "../../components/SectionWrapper";
|
|
|
|
|
import Message from "./Message";
|
2022-11-25 18:52:46 +00:00
|
|
|
|
import ArrowBackIcon from "@mui/icons-material/ArrowBack";
|
2022-12-09 12:27:32 +00:00
|
|
|
|
import SendIcon from "../../components/icons/SendIcon";
|
2022-12-04 12:41:10 +00:00
|
|
|
|
import ComplexNavText from "../../components/ComplexNavText";
|
2022-11-23 11:46:04 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
export default function Support() {
|
|
|
|
|
const theme = useTheme();
|
2022-11-25 18:52:46 +00:00
|
|
|
|
const upMd = useMediaQuery(theme.breakpoints.up("md"));
|
2022-11-23 11:46:04 +00:00
|
|
|
|
const [messageText, setMessageText] = useState<string>("");
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
<SectionWrapper
|
|
|
|
|
maxWidth="lg"
|
|
|
|
|
sx={{
|
2022-11-25 18:52:46 +00:00
|
|
|
|
pt: upMd ? "25px" : "20px",
|
|
|
|
|
pb: upMd ? "70px" : "18px",
|
|
|
|
|
height: "100%",
|
|
|
|
|
display: "flex",
|
|
|
|
|
flexDirection: "column",
|
|
|
|
|
}}
|
|
|
|
|
outerContainerSx={{
|
|
|
|
|
height: upMd ? undefined : "calc(100vh - 51px)",
|
2022-11-23 11:46:04 +00:00
|
|
|
|
}}
|
|
|
|
|
>
|
2022-11-25 18:52:46 +00:00
|
|
|
|
{upMd &&
|
2022-12-04 12:41:10 +00:00
|
|
|
|
<ComplexNavText text1="Все тарифыsss — " text2="Запрос в службу техподдержки" />
|
2022-11-25 18:52:46 +00:00
|
|
|
|
}
|
2022-11-23 11:46:04 +00:00
|
|
|
|
<Box
|
|
|
|
|
sx={{
|
2022-12-04 12:41:10 +00:00
|
|
|
|
mt: "20px",
|
2022-11-25 18:52:46 +00:00
|
|
|
|
mb: "40px",
|
2022-11-23 11:46:04 +00:00
|
|
|
|
display: "flex",
|
2022-11-25 18:52:46 +00:00
|
|
|
|
gap: "10px",
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
{!upMd &&
|
|
|
|
|
<IconButton sx={{ p: 0, height: "28px", width: "28px", color: "black" }}>
|
|
|
|
|
<ArrowBackIcon />
|
|
|
|
|
</IconButton>
|
|
|
|
|
}
|
|
|
|
|
<Typography variant="h4">Запрос в службу техподдержки</Typography>
|
|
|
|
|
</Box>
|
|
|
|
|
<Box
|
|
|
|
|
sx={{
|
|
|
|
|
backgroundColor: upMd ? "white" : undefined,
|
|
|
|
|
display: "flex",
|
|
|
|
|
flexGrow: 1,
|
|
|
|
|
maxHeight: upMd ? "443px" : undefined,
|
2022-11-23 11:46:04 +00:00
|
|
|
|
borderRadius: "12px",
|
2022-11-25 18:52:46 +00:00
|
|
|
|
p: upMd ? "20px" : undefined,
|
2022-11-23 11:46:04 +00:00
|
|
|
|
gap: "40px",
|
2022-11-25 18:52:46 +00:00
|
|
|
|
boxShadow: upMd ?
|
|
|
|
|
`0px 100px 309px rgba(210, 208, 225, 0.24),
|
|
|
|
|
0px 41.7776px 129.093px rgba(210, 208, 225, 0.172525),
|
|
|
|
|
0px 22.3363px 69.0192px rgba(210, 208, 225, 0.143066),
|
|
|
|
|
0px 12.5216px 38.6916px rgba(210, 208, 225, 0.12),
|
|
|
|
|
0px 6.6501px 20.5488px rgba(210, 208, 225, 0.0969343),
|
|
|
|
|
0px 2.76726px 8.55082px rgba(210, 208, 225, 0.0674749)`
|
|
|
|
|
:
|
|
|
|
|
undefined,
|
2022-11-23 11:46:04 +00:00
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
<Box
|
|
|
|
|
sx={{
|
|
|
|
|
display: "flex",
|
|
|
|
|
alignItems: "start",
|
|
|
|
|
flexDirection: "column",
|
|
|
|
|
flexGrow: 1,
|
|
|
|
|
}}
|
|
|
|
|
>
|
2022-11-25 18:52:46 +00:00
|
|
|
|
<Typography variant={upMd ? "h5" : "body2"} mb={"4px"}>Заголовок</Typography>
|
2022-11-23 11:46:04 +00:00
|
|
|
|
<Typography sx={{
|
|
|
|
|
fontWeight: 400,
|
|
|
|
|
fontSize: "14px",
|
|
|
|
|
lineHeight: "17px",
|
2022-11-24 19:22:30 +00:00
|
|
|
|
color: theme.palette.grey2.main,
|
2022-11-25 18:52:46 +00:00
|
|
|
|
mb: upMd ? "9px" : "20px",
|
2022-11-23 11:46:04 +00:00
|
|
|
|
}}>Создан: 15.09.22 08:39</Typography>
|
|
|
|
|
<Box
|
|
|
|
|
sx={{
|
|
|
|
|
backgroundColor: "#ECECF3",
|
2022-11-24 19:22:30 +00:00
|
|
|
|
border: `1px solid ${theme.palette.grey2.main}`,
|
2022-11-23 11:46:04 +00:00
|
|
|
|
borderRadius: "10px",
|
|
|
|
|
overflow: "hidden",
|
|
|
|
|
width: "100%",
|
|
|
|
|
minHeight: "345px",
|
|
|
|
|
display: "flex",
|
2022-11-25 18:52:46 +00:00
|
|
|
|
flexGrow: 1,
|
2022-11-23 11:46:04 +00:00
|
|
|
|
flexDirection: "column",
|
|
|
|
|
|
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
<Box
|
|
|
|
|
sx={{
|
|
|
|
|
flexGrow: 1,
|
|
|
|
|
width: "100%",
|
2022-11-24 19:22:30 +00:00
|
|
|
|
borderBottom: `1px solid ${theme.palette.grey2.main}`,
|
2022-11-25 18:52:46 +00:00
|
|
|
|
px: upMd ? "20px" : "5px",
|
|
|
|
|
py: upMd ? "20px" : "13px",
|
2022-11-23 11:46:04 +00:00
|
|
|
|
display: "flex",
|
|
|
|
|
flexDirection: "column",
|
2022-11-25 18:52:46 +00:00
|
|
|
|
gap: upMd ? "20px" : "16px",
|
2022-11-23 11:46:04 +00:00
|
|
|
|
overflow: "auto",
|
2022-11-25 18:52:46 +00:00
|
|
|
|
height: "200px",
|
2022-11-23 11:46:04 +00:00
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
<Message
|
|
|
|
|
text="Текст-заполнитель — это текст, который имеет "
|
|
|
|
|
time="16:40"
|
|
|
|
|
isSelf={false}
|
|
|
|
|
/>
|
|
|
|
|
<Message
|
|
|
|
|
text="Текст-заполнитель — это текст, который имеет "
|
|
|
|
|
time="16:40"
|
|
|
|
|
isSelf={true}
|
|
|
|
|
/>
|
|
|
|
|
<Message
|
|
|
|
|
text="Текст-заполнитель — это текст"
|
|
|
|
|
time="16:40"
|
|
|
|
|
isSelf={false}
|
|
|
|
|
/>
|
|
|
|
|
</Box>
|
2022-11-25 18:52:46 +00:00
|
|
|
|
<FormControl>
|
|
|
|
|
<InputBase
|
|
|
|
|
value={messageText}
|
|
|
|
|
fullWidth
|
|
|
|
|
placeholder="Текст обращения"
|
|
|
|
|
id="message"
|
|
|
|
|
multiline
|
|
|
|
|
sx={{
|
|
|
|
|
width: "100%",
|
|
|
|
|
p: 0,
|
|
|
|
|
}}
|
|
|
|
|
inputProps={{
|
|
|
|
|
sx: {
|
|
|
|
|
fontWeight: 400,
|
|
|
|
|
fontSize: "16px",
|
|
|
|
|
lineHeight: "19px",
|
|
|
|
|
pt: upMd ? "13px" : "28px",
|
|
|
|
|
pb: upMd ? "13px" : "24px",
|
|
|
|
|
px: "19px",
|
|
|
|
|
maxHeight: "calc(19px * 5)",
|
|
|
|
|
}
|
|
|
|
|
}}
|
|
|
|
|
onChange={e => setMessageText(e.target.value)}
|
|
|
|
|
endAdornment={!upMd &&
|
|
|
|
|
<InputAdornment position="end">
|
|
|
|
|
<IconButton
|
|
|
|
|
sx={{
|
|
|
|
|
height: "45px",
|
|
|
|
|
width: "45px",
|
|
|
|
|
mr: "13px",
|
2022-11-26 09:36:24 +00:00
|
|
|
|
p: 0,
|
2022-11-25 18:52:46 +00:00
|
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
<SendIcon />
|
|
|
|
|
</IconButton>
|
|
|
|
|
</InputAdornment>
|
2022-11-23 11:46:04 +00:00
|
|
|
|
}
|
2022-11-25 18:52:46 +00:00
|
|
|
|
/>
|
|
|
|
|
</FormControl>
|
2022-11-23 11:46:04 +00:00
|
|
|
|
</Box>
|
|
|
|
|
</Box>
|
2022-11-25 18:52:46 +00:00
|
|
|
|
{upMd &&
|
|
|
|
|
<Box sx={{ alignSelf: "end" }}>
|
|
|
|
|
<CustomButton
|
|
|
|
|
variant="contained"
|
|
|
|
|
sx={{
|
|
|
|
|
backgroundColor: theme.palette.brightPurple.main,
|
|
|
|
|
}}
|
|
|
|
|
>Отправить</CustomButton>
|
|
|
|
|
</Box>
|
|
|
|
|
}
|
2022-11-23 11:46:04 +00:00
|
|
|
|
</Box>
|
2022-11-25 18:52:46 +00:00
|
|
|
|
</SectionWrapper >
|
2022-11-23 11:46:04 +00:00
|
|
|
|
);
|
|
|
|
|
}
|