Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

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

Rev 4190 Rev 4191
Línea 1... Línea -...
1
import axios from 'axios'
-
 
2
import React, { useEffect, useState } from 'react'
1
import React, { useEffect, useState } from 'react'
-
 
2
import axios from '../../utils/axios'
-
 
3
import parse from 'html-react-parser'
3
import { useDispatch } from 'react-redux'
4
import { useDispatch } from 'react-redux'
4
import { addNotification } from '../../redux/notification/notification.actions'
5
import { addNotification } from '../../redux/notification/notification.actions'
Línea 5... Línea 6...
5
 
6
 
Línea 31... Línea 32...
31
    return (
32
    return (
32
        <div className='peopleYouMayKnow'>
33
        <div className='peopleYouMayKnow'>
33
            <div className="sd-title d-flex align-items-center justify-content-between">
34
            <div className="sd-title d-flex align-items-center justify-content-between">
34
                <h3>Proximos eventos</h3>
35
                <h3>Proximos eventos</h3>
35
            </div>
36
            </div>
36
            <div className="w-100 d-flex flex-column">
37
            <div className="w-100 d-flex flex-column" style={{ gap: '.5rem' }}>
37
                {events.length
38
                {events.length
38
                    ? events.map((event) =>
39
                    ? events.map((event) =>
39
                        <div key={event.id} style={{ background: event.backgroundColor }}>
40
                        <div className='rounded' key={event.id} style={{ background: event.backgroundColor }}>
40
                            <div className="d-flex align-items-center flex-column" style={{ gap: '.5rem' }}>
41
                            <div className="d-flex align-items-center flex-column" style={{ gap: '.5rem' }}>
41
                                <h4 className='break-ellipsis'>{event.title}</h4>
42
                                <h4 className='break-ellipsis'>{event.title}</h4>
42
                                <span>{new Date(event.start).toLocaleString()}</span>
43
                                <span>{new Date(event.start).toLocaleString()}</span>
43
                                <span>{new Date(event.end).toLocaleString()}</span>
44
                                <span>{new Date(event.end).toLocaleString()}</span>
44
                            </div>
45
                            </div>
Línea 47... Línea 48...
47
                                    className="btn btn-primary"
48
                                    className="btn btn-primary"
48
                                    href={event.url}
49
                                    href={event.url}
49
                                >
50
                                >
50
                                    Ingresar
51
                                    Ingresar
51
                                </a>
52
                                </a>
52
                                {event.agenda}
53
                                {parse(event.agenda)}
53
                            </div>
54
                            </div>
54
                        </div>
55
                        </div>
55
                    )
56
                    )
56
                    : <div className="view-more">No hay eventos</div>
57
                    : <div className="view-more">No hay eventos</div>
57
                }
58
                }