Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PortalMEC-React
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PortalMEC
PortalMEC-React
Commits
698c5a1a
Commit
698c5a1a
authored
5 years ago
by
smr17
Browse files
Options
Downloads
Patches
Plain Diff
animações iniciais dos cards
parent
58c18253
No related branches found
No related tags found
1 merge request
!6
Insert headers
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/Components/CardsAnimation.css
+3
-4
3 additions, 4 deletions
src/Components/CardsAnimation.css
src/Components/CollectionCard.js
+15
-6
15 additions, 6 deletions
src/Components/CollectionCard.js
src/Components/ResourceCard.js
+2
-6
2 additions, 6 deletions
src/Components/ResourceCard.js
with
20 additions
and
16 deletions
src/Components/C
ollectionCard
.css
→
src/Components/C
ardsAnimation
.css
+
3
−
4
View file @
698c5a1a
.animation
{
position
:
absolute
;
display
:
flex
;
background-color
:
gray
;
opacity
:
0.6
;
background-color
:
inherit
;
width
:
0%
;
height
:
100%
;
padding-top
:
20px
;
transition
:
width
2s
;
visibility
:
hidden
;
transition-delay
:
1s
;
}
.animationOn
{
position
:
absolute
;
display
:
flex
;
background-color
:
gray
;
opacity
:
0.6
;
background-color
:
inherit
;
width
:
100%
;
height
:
100%
;
padding-top
:
20px
;
...
...
This diff is collapsed.
Click to expand it.
src/Components/CollectionCard.js
+
15
−
6
View file @
698c5a1a
import
React
,
{
Component
}
from
'
react
'
;
import
'
./CardsAnimation.css
'
;
import
{
Container
}
from
'
react-grid-system
'
;
import
Card
from
'
@material-ui/core/Card
'
;
import
CardContent
from
'
@material-ui/core/CardContent
'
;
...
...
@@ -32,16 +33,24 @@ class CollectionCard extends Component {
super
(
props
);
this
.
state
=
{
thumbnail
:
algumaCoisa
,
userStyle
:
"
animation
"
,
};
}
onHover
(){
this
.
setState
({
userStyle
:
"
animationOn
"
});
}
onIddle
(){
this
.
setState
({
userStyle
:
"
animation
"
})
}
render
(){
return
(
<
Card
>
<
Container
style
=
{{
padding
:
"
0px
"
}}
>
<
img
src
=
{
this
.
state
.
thumbnail
}
alt
=
"
thumbnail do recurso
"
/>
<
div
style
=
{
authorStyle
}
>
Autor
Autor
<
br
/>
authro
<
/div
>
<
div
style
=
{
pictureStyle
}
>
fotinha
<
/div
>
<
Card
onMouseOver
=
{
this
.
onHover
.
bind
(
this
)}
onMouseOut
=
{
this
.
onIddle
.
bind
(
this
)}
>
<
Container
style
=
{{
padding
:
"
0px
"
,
backgroundColor
:
"
#673ab7
"
}}
>
<
div
style
=
{
authorStyle
}
>
Autor
Autor
<
br
/>
authro
<
/div
>
<
div
style
=
{
pictureStyle
}
>
fotinha
<
/div
>
<
div
className
=
{
this
.
state
.
userStyle
}
>
aaaaaaaaaaa
<
/div
>
<
img
src
=
{
this
.
state
.
thumbnail
}
alt
=
"
thumbnail do recurso
"
/>
<
/Container
>
<
CardContent
style
=
{{
height
:
"
60%
"
,
textAlign
:
"
left
"
,
paddingBottom
:
"
0px
"
}}
>
<
/CardContent
>
...
...
This diff is collapsed.
Click to expand it.
src/Components/ResourceCard.js
+
2
−
6
View file @
698c5a1a
import
React
,
{
Component
}
from
'
react
'
;
import
'
./C
ollectionCard
.css
'
;
import
'
./C
ardsAnimation
.css
'
;
import
{
Container
}
from
'
react-grid-system
'
;
import
Card
from
'
@material-ui/core/Card
'
;
import
CardContent
from
'
@material-ui/core/CardContent
'
;
...
...
@@ -30,10 +30,6 @@ import Video from '@material-ui/icons/OndemandVideo';
const
types
=
[{
label
:
"
Animação
"
,
thumb
:
animacao
},
{
label
:
"
Apresentação
"
,
thumb
:
apresentacao
},
{
label
:
"
Aplicativo
"
,
thumb
:
aplicativo
},
{
label
:
"
Áudio
"
,
thumb
:
audio
},
{
label
:
"
Vazio
"
,
thumb
:
vazio
},
{
label
:
"
Imagem
"
,
thumb
:
imagem
},
{
label
:
"
Gráfico
"
,
thumb
:
grafico
},
{
label
:
"
Jogo
"
,
thumb
:
jogo
},
{
label
:
"
Livro
"
,
thumb
:
livro
},
{
label
:
"
Mapa
"
,
thumb
:
mapa
},
{
label
:
"
Outros
"
,
thumb
:
outros
},
{
label
:
"
Software
"
,
thumb
:
software
},
{
label
:
"
Texto
"
,
thumb
:
texto
},
{
label
:
"
Vídeo
"
,
thumb
:
video
}]
const
thumbStyle
=
{
};
class
ResourceCard
extends
Component
{
constructor
(
props
)
{
super
(
props
);
...
...
@@ -59,7 +55,7 @@ class ResourceCard extends Component {
this
.
renderType
(
this
.
props
.
type
)
return
(
<
Card
onMouseOver
=
{
this
.
onHover
.
bind
(
this
)}
onMouseOut
=
{
this
.
onIddle
.
bind
(
this
)}
>
<
Container
style
=
{{
padding
:
"
0px
"
}}
>
<
Container
style
=
{{
padding
:
"
0px
"
,
backgroundColor
:
"
#ff7f00
"
}}
>
<
div
className
=
{
this
.
state
.
userStyle
}
>
aaaaaaaaaaa
<
/div
>
<
img
src
=
{
this
.
state
.
thumbnail
}
alt
=
"
thumbnail do recurso
"
/>
<
/Container
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment