Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

Rev 6459 | Rev 6461 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 6459 Rev 6460
Línea 15... Línea 15...
15
const RadioButton = styled.div`
15
const RadioButton = styled.div`
16
  display: flex;
16
  display: flex;
17
  align-items: center;
17
  align-items: center;
18
  gap: 0.5rem;
18
  gap: 0.5rem;
19
  padding: 0.5rem 1rem;
19
  padding: 0.5rem 1rem;
20
  margin-bottom: 0.5rem;
-
 
21
  border: 2px solid var(--border-primary);
20
  border: 2px solid var(--border-primary);
22
  border-radius: 50px;
21
  border-radius: 50px;
23
  cursor: pointer;
22
  cursor: pointer;
24
  transition: all 200ms ease;
23
  transition: all 200ms ease;
25
  position: relative;
24
  position: relative;
Línea 32... Línea 31...
32
  label {
31
  label {
33
    color: var(--font-color);
32
    color: var(--font-color);
34
    font-weight: 500;
33
    font-weight: 500;
35
  }
34
  }
Línea -... Línea 35...
-
 
35
 
-
 
36
  &:not(:last-child) {
-
 
37
    margin-bottom: 0.5rem;
-
 
38
  }
36
 
39
 
37
  &::before {
40
  &::before {
38
    content: '';
41
    content: '';
39
    position: absolute;
42
    position: absolute;
40
    left: 0;
43
    left: 0;
Línea 65... Línea 68...
65
        text-shadow: none;
68
        text-shadow: none;
66
      }
69
      }
67
    `}
70
    `}
68
`
71
`
Línea -... Línea 72...
-
 
72
 
-
 
73
const VoteTag = styled.span`
-
 
74
  position: absolute;
-
 
75
  bottom: 1rem;
-
 
76
  right: 1rem;
-
 
77
  color: var(--font-color);
-
 
78
`
69
 
79
 
70
const SurveyForm = ({
80
const SurveyForm = ({
71
  question,
81
  question,
72
  answers = [],
82
  answers = [],
73
  votes,
83
  votes,
Línea 98... Línea 108...
98
          addNotification({ style: 'danger', msg: `Error: ${data}` })
108
          addNotification({ style: 'danger', msg: `Error: ${data}` })
99
          setIsActive(true)
109
          setIsActive(true)
100
        }
110
        }
Línea 101... Línea 111...
101
 
111
 
-
 
112
        updateFeed({ feed: data, uuid: data.feed_uuid })
102
        updateFeed({ feed: data, uuid: data.feed_uuid })
113
        addNotification({ style: 'success', msg: 'Voto emitido con exito' })
103
      })
114
      })
104
      .catch((err) => {
115
      .catch((err) => {
105
        addNotification({ style: 'danger', msg: `Error: ${err}` })
116
        addNotification({ style: 'danger', msg: `Error: ${err}` })
106
        setIsActive(true)
117
        setIsActive(true)
Línea 209... Línea 220...
209
              )}
220
              )}
210
            </RadioButton>
221
            </RadioButton>
211
          )
222
          )
212
      )}
223
      )}
213
      <span>Tiempo restante: {remainingTime}</span>
224
      <span>Tiempo restante: {remainingTime}</span>
-
 
225
      {!isActive && <VoteTag>Tu voto ya fue emitido</VoteTag>}
214
    </form>
226
    </form>
215
  )
227
  )
216
}
228
}
Línea 217... Línea 229...
217
 
229