Proyectos de Subversion LeadersLinked - SPA

Rev

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

Rev 3444 Rev 3445
Línea 1... Línea 1...
1
import React, { useState, useEffect, useCallback, memo } from 'react';
1
import React, { useState, useEffect, useCallback } from 'react';
2
import { Link, useLocation } from 'react-router-dom';
2
import { Link, useLocation } from 'react-router-dom';
3
import { useDispatch, useSelector } from 'react-redux';
3
import { useDispatch, useSelector } from 'react-redux';
4
import { Box, Button, Typography } from '@mui/material';
4
import { Box, Button, Typography } from '@mui/material';
Línea 5... Línea 5...
5
 
5
 
Línea 82... Línea 82...
82
 
82
 
83
  return (
83
  return (
84
    <Widget>
84
    <Widget>
Línea 85... Línea -...
85
      <Cover cover={cover} size={coverSize} url={coverUrl} />
-
 
86
 
-
 
87
      <Box sx={{ alignItems: 'center', mt: '-40px' }}>
-
 
88
        <Avatar src={avatar} size={avatarSize} url={avatarUrl} />
-
 
89
      </Box>
85
      <Cover cover={cover} size={coverSize} url={coverUrl} />
-
 
86
 
-
 
87
      <Widget.Body>
-
 
88
        <Box sx={{ alignItems: 'center', mt: -40 }}>
-
 
89
          <Avatar
-
 
90
            src={avatar}
-
 
91
            alt={name}
-
 
92
            size={avatarSize}
-
 
93
            uploadUrl={avatarUrl}
-
 
94
            badgeStyles={{ mt: -75 }}
-
 
95
            styles={{ width: 150, height: 150 }}
90
 
96
          />
91
      <Widget.Body>
97
        </Box>
92
        <Typography variant='h2'>{name}</Typography>
98
        <Typography variant='h2'>{name}</Typography>
93
        <Typography>{parse(description)}</Typography>
-
 
94
        <Typography>{address}</Typography>
99
        <Typography>{parse(description)}</Typography>
95
        <Typography variant='overline'> - </Typography>
100
        <Typography>{address}</Typography>
96
        <Typography variant='overline'>{labels.personal_info}</Typography>
101
        <Typography variant='overline'>{labels.personal_info}</Typography>
97
        <Row>
102
        <Row>
98
          {totalConnections && (
103
          {totalConnections && (
Línea 144... Línea 149...
144
      />
149
      />
145
    </Widget>
150
    </Widget>
146
  );
151
  );
147
};
152
};
Línea 148... Línea 153...
148
 
153
 
149
export default memo(ProfileCard, (prevProps, nextProps) => {
-
 
150
  return (
-
 
151
    prevProps.cover === nextProps.cover &&
-
 
152
    prevProps.avatar === nextProps.avatar &&
-
 
153
    prevProps.name === nextProps.name &&
-
 
154
    prevProps.description === nextProps.description &&
-
 
155
    prevProps.address === nextProps.address &&
-
 
156
    prevProps.coverUrl === nextProps.coverUrl &&
-
 
157
    prevProps.avatarUrl === nextProps.avatarUrl &&
-
 
158
    prevProps.coverSize === nextProps.coverSize &&
-
 
159
    prevProps.avatarSize === nextProps.avatarSize &&
-
 
160
    prevProps.requestConnection === nextProps.requestConnection &&
-
 
161
    prevProps.linkRequest === nextProps.linkRequest &&
-
 
162
    prevProps.linkCancel === nextProps.linkCancel &&
-
 
163
    prevProps.linkInmail === nextProps.linkInmail &&
-
 
164
    prevProps.following === nextProps.following &&
-
 
165
    prevProps.totalConnections === nextProps.totalConnections &&
-
 
166
    prevProps.facebook === nextProps.facebook &&
-
 
167
    prevProps.twitter === nextProps.twitter &&
-
 
168
    prevProps.instagram === nextProps.instagram
-
 
169
  );
-