Skip to content

Commit 267df36

Browse files
fix(PDYE-1136): boton iphone y flecha (#691)
Co-authored-by: Javiera Munita <javiera.munita@eclass.cl>
1 parent 7923f09 commit 267df36

File tree

3 files changed

+41
-42
lines changed

3 files changed

+41
-42
lines changed

src/organisms/Calendar/Dropdown/CalendarDropdown/CalendarDropdownContainer.tsx

+20
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,26 @@ export const CalendarDropdownContainer = ({
7373
<Box
7474
zIndex={4}
7575
className={`calendarDropdown ${hasNew && !onlyToCalendar ? 'hasNew' : ''}`}
76+
width="30px"
77+
height="30px"
7678
m={m}
7779
position="relative"
7880
sx={{
81+
// Pseudo-elemento para la flecha
82+
'&::after': {
83+
content: '""',
84+
position: 'absolute',
85+
width: '0',
86+
height: '0',
87+
borderColor: `transparent transparent ${vars('colors-neutral-davysGrey') ?? '#5C5C5C'}
88+
transparent`,
89+
borderStyle: 'solid',
90+
borderWidth: '0 11px 10px 11px',
91+
top: isMobile ? '30px' : '30px',
92+
right: isMobile ? '3px' : '15px',
93+
display: isMenuOpen && !isMobile ? 'block' : 'none',
94+
transform: isMobile ? 'none' : 'translateX(50%)',
95+
},
7996
// Se genera pseudo elemento que actúa como ícono de notificación
8097
'&.hasNew::before': {
8198
background: vars('colors-secondary-pumpkin') ?? '#FF7A14',
@@ -99,10 +116,13 @@ export const CalendarDropdownContainer = ({
99116
'.chakra-menu__menu-list': {
100117
padding: '0',
101118
position: 'absolute',
119+
left: isMobile ? 'auto' : '-30px',
120+
top: isMobile ? '-6px !important' : 'auto',
102121
width: isMobile ? '100vw' : '500px',
103122
maxHeight: isMobile ? 'calc(100vh - 62px)' : 'auto',
104123
overflowY: isMobile ? 'auto' : 'hidden',
105124
background: 'white',
125+
border: 'none',
106126
borderRadius: isMobile ? '0' : '10px',
107127
boxShadow: isMobile ? 'none' : 'rgba(47, 47, 47, 0.2) -1px 6px 40px 0px',
108128
animation: 'none !important',

src/organisms/Calendar/Dropdown/CalendarDropdown/Components/GoToCalendar.tsx

+5-11
Original file line numberDiff line numberDiff line change
@@ -24,27 +24,21 @@ export const GoToCalendar = ({
2424
background={vars('colors-main-blueGrey') ?? '#60798E'}
2525
border="1px solid transparent"
2626
borderRadius="100%"
27-
height="30px!important"
28-
width="30px!important"
27+
height="30px !important"
28+
width="30px !important"
29+
padding="0 !important"
30+
margin="0 !important"
2931
position="relative"
3032
_hover={{
3133
bg: 'rgba(96, 121, 142, 0.8)',
3234
}}
3335
sx={{
3436
'>span': {
37+
display: 'grid',
3538
alignContent: 'center',
3639
h: '16px!important',
3740
justifyItems: 'center',
3841
lineHeight: '0',
39-
m: '0!important',
40-
p: '0!important',
41-
w: '16px!important',
42-
svg: {
43-
h: '16px!important',
44-
m: '0!important',
45-
p: '0!important',
46-
w: '16px!important',
47-
},
4842
},
4943
}}
5044
>

src/organisms/Calendar/Dropdown/CalendarDropdown/Components/Header.tsx

+16-31
Original file line numberDiff line numberDiff line change
@@ -3,36 +3,21 @@ import { vars } from '@theme'
33

44
export const Header = ({ text, isMobile }: { text?: string; isMobile: boolean }): JSX.Element => {
55
return (
6-
<>
7-
<Box
8-
as="header"
9-
bg={vars('colors-neutral-davysGrey') ?? '#5C5C5C'}
10-
borderRadius={isMobile ? 'none' : '10px 10px 0 0'}
11-
color={vars('colors-neutral-white') ?? '#FFFFFF'}
12-
fontSize="14px"
13-
fontWeight="500"
14-
lineHeight="normal"
15-
padding="16px"
16-
position="absolute"
17-
width={isMobile ? '100vw' : '100%'}
18-
top={0}
19-
zIndex="1"
20-
>
21-
{text ?? 'Próximas fechas importantes de tus cursos'}
22-
</Box>
23-
<Box
24-
className="arrow"
25-
aria-hidden
26-
borderBottom={`12px solid ${vars('colors-neutral-davysGrey') ?? '#5C5C5C'}`}
27-
borderLeft="14px solid transparent"
28-
borderRight="14px solid transparent"
29-
display={isMobile ? 'none' : 'block'}
30-
height="0"
31-
position="fixed"
32-
right={isMobile ? '71px' : '-437px'}
33-
top={isMobile ? '54px' : '-9px'}
34-
width="0"
35-
/>
36-
</>
6+
<Box
7+
as="header"
8+
bg={vars('colors-neutral-davysGrey') ?? '#5C5C5C'}
9+
borderRadius={isMobile ? 'none' : '10px 10px 0 0'}
10+
color={vars('colors-neutral-white') ?? '#FFFFFF'}
11+
fontSize="14px"
12+
fontWeight="500"
13+
lineHeight="normal"
14+
padding="16px"
15+
position="absolute"
16+
width={isMobile ? '100vw' : '100%'}
17+
top={0}
18+
zIndex="1"
19+
>
20+
{text ?? 'Próximas fechas importantes de tus cursos'}
21+
</Box>
3722
)
3823
}

0 commit comments

Comments
 (0)