|
@@ -1,4 +1,4 @@
|
1
|
|
-import React, { useMemo, useRef } from 'react'
|
|
1
|
+import React, { useMemo } from 'react'
|
2
|
2
|
|
3
|
3
|
import { Service } from '../../Utils/HTTP'
|
4
|
4
|
import useAuth from '../../Auth/useAuth.js';
|
|
@@ -33,7 +33,7 @@ var scroll = Scroll.animateScroll;
|
33
|
33
|
}, [token]);
|
34
|
34
|
|
35
|
35
|
const handleAddQuestion = () => {
|
36
|
|
- let op = { smooth: true, duration: 200, delay :1, offset :900}
|
|
36
|
+ let op = { smooth: true, duration: 200, delay :1, offset :20}
|
37
|
37
|
scroll.scrollToBottom(op);
|
38
|
38
|
let currentAnswer = totalRespondidas[totalRespondidas.length - 1];
|
39
|
39
|
const nextHiddenItem = totalPreguntas.filter(({id}) => id !== currentAnswer.id );
|
|
@@ -43,14 +43,10 @@ var scroll = Scroll.animateScroll;
|
43
|
43
|
setRespondidas([...totalRespondidas,temp]);
|
44
|
44
|
}
|
45
|
45
|
};
|
46
|
|
-
|
47
|
|
-
|
48
|
|
-var scroll = Scroll.animateScroll;
|
49
|
|
-
|
50
|
46
|
|
51
|
47
|
return (
|
52
|
48
|
|
53
|
|
- <div className="content-section">
|
|
49
|
+ <div className="content-section question">
|
54
|
50
|
<div className="main">
|
55
|
51
|
<Box sx={{ mt: 1 }}>
|
56
|
52
|
<List >
|
|
@@ -65,13 +61,15 @@ var scroll = Scroll.animateScroll;
|
65
|
61
|
</List>
|
66
|
62
|
</Box>
|
67
|
63
|
|
68
|
|
- <Button
|
69
|
|
- variant="contained"
|
70
|
|
- disabled={totalRespondidas.length >= totalPreguntas.length}
|
71
|
|
- onClick={handleAddQuestion}
|
72
|
|
- >
|
73
|
|
- Add Question
|
74
|
|
- </Button>
|
|
64
|
+ <div class="question_btn">
|
|
65
|
+ <Button
|
|
66
|
+ variant="contained"
|
|
67
|
+ disabled={totalRespondidas.length >= totalPreguntas.length}
|
|
68
|
+ onClick={handleAddQuestion}
|
|
69
|
+ >
|
|
70
|
+ Siguiente Pregunta
|
|
71
|
+ </Button>
|
|
72
|
+ </div>
|
75
|
73
|
|
76
|
74
|
</div>
|
77
|
75
|
</div>
|