Flex 学习
Flex案例一:

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题</title>
<style type="text/css">
body,h1,h2,h3,h4,h5,h6,dl,dt,dd,ul,ol,li,th,td,p,blockquote,pre,form,fieldset,legend,input,button,textarea,hr{
margin:0;
padding:0;
}
body{
display: flex;
background: -webkit-linear-gradient(top,#222,#333);
background: linear-gradient(top,#222,#333);
justify-content:center;
align-items:center;
align-content:center;
flex-wrap:wrap;
position:relative;
}
[class$="box"]{
background-color: #e7e7e7;
width: 104px;
height: 104px;
/*padding:4px;
margin:16px;*/
object-fit:contain;
border-radius: 10%;
box-shadow: inset 0 5px white,inset 0 -5px #bbb,inset 5px 0 #d7d7d7,inset -5px 0 #d7d7d7;
display: flex; position: absolute;
top:0;
left: 0;
/*top: 40%;
left: 40%;*/
}
[class="item"]{
display: block;
width:24px;
height: 24px;
border-radius: 50%;
margin:4px;
background-color: #333;
box-shadow: inset 0 3px #111,inset 0 -3px #555;
}
.first-box{
justify-content:center;
align-items:center;
align-content:center;
}
.second-box{
justify-content:space-between;
}
.second-box .item:nth-of-type(2){
-webkit-align-self:flex-end;
}
.third-box{ }
.third-box .item:nth-of-type(2){
align-self:center;
}
.third-box .item:nth-of-type(3){
align-self:flex-end;
}
.sixth-box,
.four-box{
justify-content:space-between;
justify-wrap:wrap;
}
.sixth-box .column,
.four-box .column{
display: flex;
flex-direction:column;
justify-content:space-between;
}
.fifth-box{
justify-content:space-between;
}
.fifth-box .column{
display: flex;
flex-direction:column;
justify-content:space-between;
}
.fifth-box .column:nth-of-type(2){
justify-content:center;
align-items:center;
} .tbox{
width: 104px;
height: 104px; background-color: transparent;
border:none;
box-shadow: none;
transform-style:preserve-3d;
display: flex;
justify-content:center;
align-items:center;
align-content:center;
flex-wrap:wrap;
position:relative;
-webkit-animation:iphone 4s linear infinite; transform:rotateZ(30deg);
}
.tbox:hover{
-webkit-animation-play-state:paused;
}
.sixth-box{
/*transform:rotate(30deg);*/
transform-origin:right bottom;
transform:rotateZ(30deg);
}
.fifth-box{
margin-left: 25px;
margin-top: 7px;
transform-origin:right 50%;
transform:translateZ(-105px) rotateY(90deg) rotateX(-29deg);
}
.four-box{
margin-left: 40px;
margin-top: -45px;
/*margin-top: -36px;*/
transform-origin:left 50%;
transform:translateZ(-105px) rotateY(-90deg) rotateX(30deg);
}
.third-box{
margin-left: 40px;
margin-top:-45px;
/*margin-left: 240px;*/
transform-origin:left 50%;
transform:translateZ(-105px) rotateZ(30deg);
}
.second-box{
margin-left: 7px;
margin-top:80px;
/*margin-top: 128px;*/
transform-origin: 50% top;
transform:translateZ(-105px) rotateX(90deg) rotateY(30deg);
}
.first-box{
margin-left:58px;
margin-top:-116px;
/*margin-top: -96px;*/
transform-origin: 50% bottom;
transform:translateZ(-105px) rotateX(-90deg) rotateY(-30deg);
} @-webkit-keyframes iphone{
from{
transform:rotateY(0deg);
}
to{
transform:rotateY(360deg);
}
}
</style>
</head>
<body>
<div class="tbox">
<div class="first-box">
<span class="item"></span>
</div>
<div class="second-box">
<span class="item"></span>
<span class="item"></span>
</div>
<div class="third-box">
<span class="item"></span>
<span class="item"></span>
<span class="item"></span>
</div>
<div class="four-box">
<div class="column">
<span class="item"></span>
<span class="item"></span>
</div>
<div class="column">
<span class="item"></span>
<span class="item"></span>
</div>
</div>
<div class="fifth-box">
<div class="column">
<span class="item"></span>
<span class="item"></span>
</div>
<div class="column">
<span class="item"></span>
</div>
<div class="column">
<span class="item"></span>
<span class="item"></span>
</div>
</div>
<div class="sixth-box">
<div class="column">
<span class="item"></span>
<span class="item"></span>
<span class="item"></span>
</div>
<div class="column">
<span class="item"></span>
<span class="item"></span>
<span class="item"></span>
</div>
</div>
</div> </body>
</html>
Flex 学习的更多相关文章
- 【转】【Flex】FLEX 学习网站分享
[转:http://hi.baidu.com/tanghecaiyu/item/d662fbd7f5fbe02c38f6f764 ] FLEX 学习网站分享 http://blog.minidx.co ...
- flex学习小结
接触到flex一个多月了,今天做一个学习小结.如果有知识错误或者意见不同的地方.欢迎交流指教. 画外音:先说一下,我是怎么接触到flex布局的.对于正在学习的童鞋们,我建议大家没事可以逛逛网站,看看人 ...
- CSS3伸缩布局Flex学习笔记
如果需要使用伸缩布局首先得把display:flex;对于兼容还得加前缀display:-webkit-display:flex;等其他浏览器前缀,但我本机Chrome测试已经不需要加前缀了,其实这些 ...
- flex学习
今天看视频学习的时候,发现css有一个 flex 的属性,非常的好用,为了让自己能够熟记,特意来分享一下flex的用法. 首先,采用Flex布局的元素,称为Flex容器(flex co ...
- 【Flex学习】Flex4学习网站
http://blog.minidx.com/category/flex 来自为知笔记(Wiz)
- Flex学习总结
Flex SDK Flex框架类库.Flex编译环境.调式器.MXML.ActionScript编程语言以及其它工具组成,Flash Builder是其开发环境, Flash Player的工作模 ...
- Flex学习第一天(两个数相加)
<?xml version="1.0" encoding="utf-8"?><s:Application xmlns:fx="htt ...
- Flex学习教程网站地址
http://www.985school.com/flex/complex_controls.html
- flex学习网站地址
http://hacker47.iteye.com/blog/213887 http://www.cuplayer.com/player/PlayerCode/Flex/ http://bbs.9ri ...
- flex学习, 尝试布局一个计算器
<!DOCTYPE html> <html> <head> <title>flex</title> </head> <st ...
随机推荐
- DevExpress WPF入门指南:DXWindow应用
[DevExpress v17.2 版本更新公开课]点击免费报名 DevExpress WPF Window control有一点非常棒,就是可以和其他视觉主题保持统一性.DXWindow class ...
- JQuery, Silverlight 公用WCF
WCF web.config配置: <?xml version="1.0"?> <configuration> <system.web> < ...
- STL标准库-Move对容器效率的影响
技术在于交流.沟通,本文为博主原创文章转载请注明出处并保持作品的完整性 C++11新增move()语法(我暂时交错右值引用),在前面我有一篇文章叫 C++11_右值引用 简单的介绍了右值引用类的实现, ...
- 【设计模式】 模式PK:工厂模式VS建造者模式
1.概述 工厂方法模式注重的是整体对象的创建方法,而建造者模式注重的是部件构建的过程,旨在通过一步一步地精确构造创建出一个复杂的对象.我们举个简单例子来说明两者的差异,如要制造一个超人,如果使用工厂方 ...
- php 函数2
- https页面证书验证、加密过程简介
1.服务器向CA机构获取证书(假设这个证书伪造不了),当浏览器首次请求服务器的时候,服务器返回证书给浏览器.(证书包含:公钥+申请者与颁发者的相关信息+签名) 2.浏览器得到证书后,开始验证证书的相关 ...
- 第三篇 makefile的伪目标
我们来思考一下makefile中的目标究竟是什么?实际上,在默认情况下: 1.make将makefile的目标认为是一个文件: 2.make解释器比较目标文件和依赖文件的新旧关系,决定是否 ...
- mysql 常用linux命令
★ 数据导出命令 D:\Program Files\MySQL\MySQL Server 5.6.39\bin 导出: mysqldump -u root -p cela_sub > D:/d ...
- Microsoft - Get Course Order
// "static void main" must be defined in a public class. public class Main { public static ...
- es 中的 Set 和 Map
Set 函数可以接受一个数组(或者具有 iterable 接口的其他数据结构)作为参数,用来初始化.