CSS3 文本效果:
<div>
<div>
<h1>7</h1>
</div>
<div>
<p>January 7, 2017</p>
</div>
</div>
div.card {
width: 250px;
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
text-align: center;
}
div.header {
background-color: #4CAF50;
color: white;
padding: 10px;
font-size: 40px;
}
div.container {
padding: 10px;
}
<div>
<img src="rock600x400.jpg" alt="Norway">
<div>
<p>Hardanger, Norway</p>
</div>
</div>
div.polaroid {
width: 250px;
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
text-align: center;
}
div.container {
padding: 10px;
}
css3 过渡:
div
{
width:100px;
height:100px;
background:red;
transition:width 2s;
-webkit-transition:width 2s; /* Safari */
}
div:hover
{
width:300px;
}
<div>
<div>css3</div>
<div>过渡</div>
</div>
.box {
width: 100px;
height: 60px;
background: #BCEE68;
color:white;
font-weight:bold;
-webkit-transition: width 1s, height 1s,font-size 1s, color 1s,-webkit-transform 1s; /* For Safari 3.1 to 6.0 */
transition: width 1s, height 1s, color 1s,font-size 1s, transform 1s;
}
.box:hover {
width: 150px;
height: 90px;
background:#9B30FF;
-webkit-transform: rotate(360deg); /* Chrome, Safari, Opera */
transform: rotate(360deg);
font-size:20px;
}
.describe{
text-align:center;
}