-
Notifications
You must be signed in to change notification settings - Fork 237
Expand file tree
/
Copy pathcard.js
More file actions
79 lines (75 loc) · 2.71 KB
/
card.js
File metadata and controls
79 lines (75 loc) · 2.71 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
import React from 'react';
import '../css/dash_style.css';
class Card extends React.Component {
render() {
return(
<div style={{display: 'inline-block'}}>
<div className="card" style={{
background: '#fff',
height: 290,
width: 240,
borderRadius: 20,
display: 'inline-block',
margin: 20,
boxShadow: '0 2px 6px rgba(112,112,112,0.2)'
}}>
<img style={{marginTop: '4.5em'}} src="static/img/thumb.png" height="60%;" />
</div>
<div className="overlay">
<br />
<div className="social" style={{marginTop: '5em'}}>
<div style={{
margin: 10,
display: 'inline-block',
color: '#fff',
fontFamily: '"Proxima Nova",sans-serif',
width: 10,
height: 10,
border: '3px solid #fff',
padding: 20,
borderRadius: '50%'
}}>
<a href={"/load?id=" + this.props.ModelID} style={{textDecoration: 'none', color: '#fff'}}>
<p style={{marginTop: '-8px', marginLeft: '-6px'}}>
<span className="glyphicon glyphicon-pencil" aria-hidden="true"></span>
</p>
</a>
</div>
<div style={{margin: 10,
display: 'inline-block',
color: '#fff',
fontFamily: '"Proxima Nova",sans-serif',
width: 10,
height: 10,
border: '3px solid #fff',
padding: 20,
borderRadius: '50%'
}}>
<a onClick={
() => this.props.ModelFunction(this.props.ModelID)
} style={{
textDecoration: 'none',
color: '#fff',
cursor: 'pointer'
}}>
<p style={{
marginTop: '-8px',
marginLeft: '-7px'
}}>
<span className="glyphicon glyphicon-trash" aria-hidden="true"></span>
</p>
</a>
</div>
</div>
</div>
<h3 style={{marginTop: '-12em'}}>{this.props.ModelName}</h3>
</div>
);
}
}
Card.propTypes = {
ModelName: React.PropTypes.string,
ModelID: React.PropTypes.number,
ModelFunction: React.PropTypes.func
};
export default Card;