Proyectos de Subversion LeadersLinked - SPA

Rev

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

Rev 1650 Rev 1870
Línea 1... Línea 1...
1
import React from 'react'
1
import React from 'react'
2
import Feed from '../dashboard/linkedin/feed-template/Feed'
-
 
3
import Modal from 'components/UI/modal/Modal'
2
import { styled } from '@mui/material'
Línea -... Línea 3...
-
 
3
 
-
 
4
import Modal from '../UI/modal/Modal'
-
 
5
import Feed, { renderContent } from '../dashboard/linkedin/feed-template/Feed'
-
 
6
import WidgetWrapper from '../widgets/WidgetLayout'
-
 
7
 
-
 
8
const StyledBody = styled(WidgetWrapper.Body)`
-
 
9
  & > p,
-
 
10
  & > a {
-
 
11
    padding: 0 1rem;
-
 
12
  }
-
 
13
  & > img {
-
 
14
    width: 100%;
-
 
15
    max-height: 60vh;
-
 
16
    object-fit: contain;
-
 
17
  }
-
 
18
  & > video {
-
 
19
    width: 100%;
-
 
20
    overflow: hidden;
-
 
21
    object-fit: scale-down;
-
 
22
    background-color: black;
-
 
23
    display: block;
-
 
24
    max-height: 80vh;
-
 
25
  }
-
 
26
`
4
 
27
 
5
const FeedModal = ({ show, onClose, feed }) => {
28
const FeedModal = ({ show = false, onClose = () => {}, feed = {} }) => {
6
  const {
29
  const {
7
    owner_file_image,
30
    owner_file_image,
8
    owner_file_video,
31
    owner_file_video,
9
    owner_file_image_preview,
32
    owner_file_image_preview,
-
 
33
    owner_file_document,
10
    owner_file_document,
34
    shared_content_type,
11
    owner_description,
35
    owner_description,
12
    shared_name,
36
    shared_name,
13
    shared_image,
37
    shared_image,
14
    shared_time_elapse,
38
    shared_time_elapse,
Línea 34... Línea 58...
34
        name={owner_name}
58
        name={owner_name}
35
        timeElapsed={owner_time_elapse}
59
        timeElapsed={owner_time_elapse}
36
        viewUrl={owner_url}
60
        viewUrl={owner_url}
37
        feedUnique={feed_unique}
61
        feedUnique={feed_unique}
38
      />
62
      />
39
 
-
 
-
 
63
      <StyledBody>
40
      <Feed.Content
64
        {renderContent({
41
        description={owner_description}
65
          description: owner_description,
42
        image={owner_file_image}
66
          image: owner_file_image,
43
        imagePreview={owner_file_image_preview}
67
          document: owner_file_document,
44
        video={owner_file_video}
68
          video: owner_file_video,
45
        document={owner_file_document}
69
          imagePreview: owner_file_image_preview,
-
 
70
          type: shared_name ? 'shared' : feed_content_type,
46
        sharedItem={{
71
          voteUrl: feed_vote_url,
47
          name: shared_name,
72
          sharedName: shared_name,
48
          image: shared_image,
73
          sharedImage: shared_image,
49
          time_elapse: shared_time_elapse,
74
          sharedTimeElapse: shared_time_elapse,
50
          description: shared_description,
75
          sharedDescription: shared_description,
51
          file_video: shared_file_video,
76
          sharedFileVideo: shared_file_video,
52
          file_image_preview: shared_file_image_preview,
77
          sharedFileImagePreview: shared_file_image_preview,
53
          file_image: shared_file_image,
78
          sharedFileImage: shared_file_image,
54
          file_document: shared_file_document,
79
          sharedFileDocument: shared_file_document,
-
 
80
          sharedContentType: shared_content_type,
55
          shared_url
81
          sharedUrl: shared_url
56
        }}
82
        })}
57
        type={feed_content_type}
-
 
58
        voteUrl={feed_vote_url}
-
 
59
      />
83
      </StyledBody>
60
    </Modal>
84
    </Modal>
61
  )
85
  )
62
}
86
}
Línea 63... Línea 87...
63
 
87