Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Amparo
Amparo-frontend
Commits
f9f0742a
Commit
f9f0742a
authored
1 year ago
by
Lucas Silveira Wolschick
Browse files
Options
Download
Email Patches
Plain Diff
modelando cardMedicamento
parent
9e7e805b
main
IntegracaoExames
LoadingAtualizado
LoadingComponent
US/19-medicamento-editar
US18/agendaDeMedicamentosTela
US32/telaPendentes
ajuste/visualizarPerfil
component-ModalPerfilPaciente
component-cardMedicamentos
component-filtroBuscaMedico
component-filtroPesquisaMedicamento
deleteExame
dev
feat/config-deploy-aws
fix-DevErrosImports
hotfix/addMedicamentoAgenda
hotfix/nomePaciente
hotfix/visualizar-paciente
integracao-medico-remedios
integracao/US04-VisualizarPerfil
integracao/add-medicamentos
integracao/adicinar-exames
origin/component-modalAddMedicamentoAgenda
splashScreen
telas-exames
testeUS32
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/components/CardMedicamentos/cardMedicamentos.tsx
+32
-20
src/components/CardMedicamentos/cardMedicamentos.tsx
with
32 additions
and
20 deletions
+32
-20
src/components/CardMedicamentos/cardMedicamentos.tsx
View file @
f9f0742a
import
React
from
'
react
'
;
import
Button
from
'
@mui/material/Button
'
;
import
CheckCircleOutlineIcon
from
'
@mui/icons-material/CheckCircleOutline
'
;
import
BookOutlinedIcon
from
'
@mui/icons-material/BookOutlined
'
;
import
DateRangeRoundedIcon
from
'
@mui/icons-material/DateRangeRounded
'
;
import
SvgIcon
,
{
SvgIconProps
}
from
'
@mui/material/SvgIcon
'
;
import
Box
from
'
@mui/material/Box
'
;
interface
CustomCardMedicamentos
{
label
:
string
;
icon
?:
boolean
;
onClick
:
()
=>
void
;
iconType
?:
'
icon1
'
|
'
icon2
'
;
onClick
:
()
=>
void
;
}
export
const
CardMedicamentos
:
React
.
FC
<
CustomCardMedicamentos
>
=
({
label
,
icon
,
onClick
,
},
props
:
SvgIconProps
)
=>
{
export
const
CardMedicamentos
:
React
.
FC
<
CustomCardMedicamentos
>
=
({
icon
Type
,
onClick
,
},
props
:
SvgIconProps
)
=>
{
const
buttonStyle
:
React
.
CSSProperties
=
{
backgroundColor
:
"
#E76553
"
,
...
...
@@ -26,23 +25,36 @@ export const CardMedicamentos: React.FC<CustomCardMedicamentos> = ({ label, icon
width
:
"
316px
"
,
textTransform
:
'
none
'
,
};
if
(
!
icon
){
return
(
<
Button
style
=
{
buttonStyle
}
onClick
=
{
onClick
}
variant
=
'contained'
>
{
label
}
</
Button
>
);
if
(
!
iconType
||
iconType
===
'
icon1
'
){
const
rotatedIconStyle
:
React
.
CSSProperties
=
{
transform
:
'
rotate(13deg) scaleY(1.1)
'
,
fontSize
:
150
,
marginRight
:
'
-30px
'
,
marginTop
:
'
10px
'
,
};
return
(
<
Button
style
=
{
buttonStyle
}
onClick
=
{
onClick
}
variant
=
"contained"
endIcon
=
{
<
Box
>
<
BookOutlinedIcon
sx
=
{
rotatedIconStyle
}
/>
</
Box
>
}
>
{
'
Minha Lista
'
}
</
Button
>
);
}
else
{
else
if
(
iconType
===
'
icon2
'
)
{
const
rotatedIconStyle
:
React
.
CSSProperties
=
{
transform
:
'
rotate(13deg) scaleY(1.1)
'
,
fontSize
:
150
,
marginRight
:
'
-50px
'
,
marginRight
:
'
-10px
'
,
marginTop
:
'
10px
'
,
};
return
(
...
...
@@ -52,11 +64,11 @@ export const CardMedicamentos: React.FC<CustomCardMedicamentos> = ({ label, icon
variant
=
"contained"
endIcon
=
{
<
Box
>
<
BookOutlin
edIcon
sx
=
{
rotatedIconStyle
}
/>
<
DateRangeRound
edIcon
sx
=
{
rotatedIconStyle
}
/>
</
Box
>
}
>
{
label
}
{
'
Agenda de Remédios
'
}
</
Button
>
);
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help