Merge branch 'dev' into 'main'

отображается статус карточки установки квиза, копируется полная ссылка

See merge request frontend/squiz!79
This commit is contained in:
Nastya 2023-12-17 23:36:07 +00:00
commit 658c957877

@ -69,9 +69,11 @@ export default function InstallQuiz() {
const CopyLink = () => { const CopyLink = () => {
let text = document.getElementById("inputLink"); let one = document.getElementById("inputLinkone").value;
text.select(); let text = document.getElementById("inputLink").value;
document.execCommand("copy"); // text.select();
navigator.clipboard.writeText(one+text)
// document.execCommand("copy");
} }
return ( return (
@ -190,7 +192,7 @@ export default function InstallQuiz() {
<FormControl fullWidth variant="standard" sx={{ p: 0 }}> <FormControl fullWidth variant="standard" sx={{ p: 0 }}>
<TextField <TextField
disabled disabled
id="outlined-disabled" id={"inputLinkone"}
value="https://pena.com/" value="https://pena.com/"
sx={{ sx={{
"& .css-1d3z3hw-MuiOutlinedInput-notchedOutline": { "& .css-1d3z3hw-MuiOutlinedInput-notchedOutline": {
@ -244,7 +246,7 @@ export default function InstallQuiz() {
> >
<ButtonSocial /> <ButtonSocial />
<Typography sx={{ color: "#FC712F" }}>Не опубликован</Typography> <Typography sx={{ color: "#FC712F" }}>{quiz?.status === "start" ? "Опубликован" : "Не опубликован"}</Typography>
</Box> </Box>
</Paper> </Paper>
</Box> </Box>