• <noscript id="ggggg"><dd id="ggggg"></dd></noscript>
    <small id="ggggg"></small> <sup id="ggggg"></sup>
    <noscript id="ggggg"><dd id="ggggg"></dd></noscript>
    <tfoot id="ggggg"></tfoot>
  • <nav id="ggggg"><cite id="ggggg"></cite></nav>
    <nav id="ggggg"></nav>
    成人黃色A片免费看三更小说,精品人妻av区波多野结衣,亚洲第一极品精品无码,欧美综合区自拍亚洲综合,久久99青青精品免费观看,中文字幕在线中字日韩 ,亚洲国产精品18久久久久久,黄色在线免费观看

    Flex布局-骰子demo

    2018-4-20    seo達人

    如果您想訂閱本博客內容,每天自動發到您的郵箱中, 請點這里

    最近學習了Flex布局,

    以下是阮一峰老師關于Flex的博客  。在此感謝他讓我get一項新技能!

    Flex語法篇:http://www.ruanyifeng.com/blog/2015/07/flex-grammar.html

    Flex實戰篇:http://www.ruanyifeng.com/blog/2015/07/flex-examples.html

    1、色子數:1

    思路:讓圓點(即子元素)在橫軸上居中在豎軸上居中,分別用justify-content和align-items

    實現代碼:

    <!DOCTYPE html>
    <html>
    <head lang="en">
        <meta charset="UTF-8">
        <title></title>
        <style> *{  margin:0;  padding:0;  }  body{  background:#000;  }  .main {  width: 200px;  height: 200px;  background: #fff;  border-radius: 20px;  margin: 100px auto;  padding: 25px;  -webkit-box-sizing: border-box;  -moz-box-sizing: border-box;  box-sizing: border-box;  display: flex;  justify-content: center;  align-items:center;  }  .main >div{  width:40px;  height:40px;  background:#000;  border-radius:40px;  }  </style>
    </head>
    <body>
    <div class="main">
        <div class="item"></div>
    </div>
    </body>
    </html>
    2、色子數:2

    思路:豎列布局且在主軸方向采用justify-content的兩端對齊布局,這樣兩個圓點會在左邊呈現,然后采用align-items讓其居中

    實現代碼:

    <!DOCTYPE html>
    <html>
    <head lang="en">
        <meta charset="UTF-8">
        <title></title>
        <style> *{  margin:0;  padding:0;  }  body{  background:#000;  }  .main {  width: 200px;  height: 200px;  background: #fff;  border-radius: 20px;  margin: 100px auto;  padding: 25px;  -webkit-box-sizing: border-box;  -moz-box-sizing: border-box;  box-sizing: border-box;  display: flex;  flex-direction: column;  justify-content: space-between;  align-items:center;  }  .main >div{  width:40px;  height:40px;  background:#000;  border-radius:40px;  }  </style>
    </head>
    <body>
    <div class="main">
        <div class="item"></div>
        <div class="item"></div>
    </div>
    </body>
    </html>
    3、色子數:3

    思路:用到align-self屬性讓第二個和第三個圓點有自己的屬性設置,分別在縱軸方向上居中和低端對齊

    實現代碼:

    <!DOCTYPE html>
    <html>
    <head lang="en">
        <meta charset="UTF-8">
        <title></title>
        <style> *{  margin:0;  padding:0;  }  body{  background:#000;  }  .main {  width: 180px;  height: 180px;  background: #fff;  border-radius: 20px;  margin: 100px auto;  padding: 25px;  -webkit-box-sizing: border-box;  -moz-box-sizing: border-box;  box-sizing: border-box;  display: flex;  }  .main >div{  width:40px;  height:40px;  background:#000;  border-radius:40px;  }  .item:nth-child(2){  align-self:center;  }  .item:nth-child(3){  align-self:flex-end;  }  </style>
    </head>
    <body>
    <div class="main">
        <div class="item"></div>
        <div class="item"></div>
        <div class="item"></div>
    </div>
    </body>
    </html>
    4、色子數:4

    思路:先豎著放兩行圓點,每行圓點里橫著放兩個圓點,所以最外層父元素設置align,里面的父元素設置justify-content

    實現代碼:

    <!DOCTYPE html>
    <html>
    <head lang="en">
        <meta charset="UTF-8">
        <title></title>
        <style> *{  margin:0;  padding:0;  }  body{  background:#000;  }  .main {  width: 180px;  height: 180px;  background: #fff;  border-radius: 20px;  margin: 100px auto;  padding: 25px;  -webkit-box-sizing: border-box;  -moz-box-sizing: border-box;  box-sizing: border-box;  display: flex;  flex-wrap:wrap;  align-content:space-between;  }  .column >div{  width:40px;  height:40px;  background:#000;  border-radius:40px;  }  .column{  flex-basis:100%;  display:flex;  justify-content: space-between;  }  </style>
    </head>
    <body>
    <div class="main">
        <div class="column">
            <div class="item"></div>
            <div class="item"></div>
        </div>
        <div class="column">
            <div class="item"></div>
            <div class="item"></div>
        </div>
    </div>
    </body>
    </html>
    5、色子數:5

    實現代碼:

    <!DOCTYPE html>
    <html>
    <head lang="en">
        <meta charset="UTF-8">
        <title></title>
        <style> *{  margin:0;  padding:0;  }  body{  background:#000;  }  .main {  width: 180px;  height: 180px;  background: #fff;  border-radius: 20px;  margin: 100px auto;  padding: 25px;  -webkit-box-sizing: border-box;  -moz-box-sizing: border-box;  box-sizing: border-box;  display: flex;  flex-wrap:wrap;  align-content:space-between;  }  .column > div{  width:40px;  height:40px;  background:#000;  border-radius:40px;  }  .column{  flex-basis:100%;  display:flex;  justify-content: space-between;  }  .column:nth-child(2){  justify-content: center;  }  </style>
    </head>
    <body>
    <div class="main">
        <div class="column">
            <div class="item"></div>
            <div class="item"></div>
        </div>
        <div class="column">
        <div class="item"></div>
        </div>
        <div class="column">
            <div class="item"></div>
            <div class="item"></div>
        </div>
    </div>
    </body>
    </html>
    6、色子數:6

    思路:跟四點的一樣,先豎放三行在每行橫放兩個圓點

    實現代碼:

    <!DOCTYPE html>
    <html>
    <head lang="en">
        <meta charset="UTF-8">
        <title></title>
        <style> *{  margin:0;  padding:0;  }  body{  background:#000;  }  .main {  width: 180px;  height: 180px;  background: #fff;  border-radius: 20px;  margin: 100px auto;  padding: 15px;  -webkit-box-sizing: border-box;  -moz-box-sizing: border-box;  box-sizing: border-box;  display: flex;  align-content:space-between;  flex-wrap:wrap;  }  .column > div{  width:40px;  height:40px;  background:#000;  border-radius:40px;  }  .column{  flex-basis:100%;  display:flex;  justify-content: space-between;  }  </style>
    </head>
    <body>
    <div class="main">
        <div class="column">
            <div class="item"></div>
            <div class="item"></div>
        </div>
        <div class="column">
            <div class="item"></div>
            <div class="item"></div>
        </div>
        <div class="column">
            <div class="item"></div>
            <div class="item"></div>
        </div>
    
    </div>
    </body>
    </html>

    藍藍設計m.lzhte.cn )是一家專注而深入的界面設計公司,為期望卓越的國內外企業提供卓越的UI界面設計、BS界面設計 、 cs界面設計 、 ipad界面設計 、 包裝設計 、 圖標定制 、 用戶體驗 、交互設計、 網站建設 平面設計服務

    日歷

    鏈接

    個人資料

    藍藍設計的小編 http://m.lzhte.cn

    存檔

    主站蜘蛛池模板: 日韩高清亚洲日韩精品一区二区| 色综合久久精品中文字幕首页| 中文字幕午夜福利片午夜福利片97| 国产亚洲国产精品二区| 日韩亚洲欧洲在线com91tv| 综合欧美小说另类图| 97人妻免费公开在线视频| 欧美一区二区精品久久久| 亚洲国产AV一区二区三区| 九九精品国产兔费观看久久| 久久久久亚洲AV片无码下载蜜桃| 国产精品麻豆中文字幕| 在线看国产丝袜精品| 久久精品人人做人人综合试看| 久久66久6这里只有精品7| 在线视频三级| 在线a视频网站| 福利导航网址| 高安市| 精品久久久无码中字| 久久99精品日韩人妻| av无码电影一区二区三区| 国产精品久久久久久久久久| 国产成 人 综合 亚洲专区| 中文字幕av久久激情| 五月婷婷丁香六月| 欧美亚洲色欲色一欲WWW| 国产亚洲精品第一综合| 日韩激情无码av一区二区| 国产成人一区二区三区视频免费| 99精品视频免费热播在线观看| 亚洲人妻系列中文字幕| 国产奶头好大揉着好爽视频| 国内一区二区三区av| 日本中文一二区有码在线| 国产无套专区精品一区| 久久午夜夜伦鲁鲁片不卡| 99久久精品国产综合婷婷| 成人网址大全| 91破解版在线亚洲| 中文无码乱人伦中文视频播放|