zoukankan      html  css  js  c++  java
  • 作业4

    .wrapper {
      display: grid;/* 使wrapper为网格容器 */
      grid-template-columns: repeat(3, 1fr);/* 画出3个轨道大小为1fr */
      grid-gap: 10px;/* 设置网格线大小为10px */
      grid-auto-rows: minmax(100px, auto);/* 自动划分行大小 最小100px */
    }
    .one {
      grid-column: 1 / 3;/* 竖排距离从第1到第3个轨道 */
      grid-row: 1;/* 横排距离占第1个轨道 */
    }
    .two { 
      grid-column: 2 / 4;/* 竖排距离从第2到第4个轨道 */
      grid-row: 1 / 3;/* 横排距离从第1到第3个轨道 */
    }
    .three {
      grid-column: 1;/* 竖排距离占第1个轨道 */
      grid-row: 2 / 5;/* 横排距离从第2到第5个轨道 */
    }
    .four {
      grid-column: 3;/* 竖排距离占第3个轨道 */
      grid-row: 3;/* 横排距离占第3个轨道 */
    }
    .five {
      grid-column: 2;/* 竖排距离占第2个轨道 */
      grid-row: 4;/* 横排距离占第4个轨道 */
    }
    .six {
      grid-column: 3; /* 竖排距离占第3个轨道 */
      grid-row: 4;/* 横排距离占第4个轨道 */
    }
    

      

    html部分
    <!DOCTYPE html>
    <html lang="en">
    <head>
    	<meta charset="UTF-8">
    	<title>box</title>
    	<link rel="stylesheet" href="three.css">
    </head>
    <body>
     <div class="wrapper">
       <div class="one">One</div>
       <div class="two">Two</div>
       <div class="three">Three</div>
       <div class="four">Four</div>
       <div class="five">Five</div>
       <div class="six">Six</div>
     </div>
    
    </html>
    

      

  • 相关阅读:
    第九篇 正则表达式
    第八篇、递归、装饰器
    第四篇、函数和递归
    第二篇、HTML
    nginx rewrite标签配置以及用户认证配置
    nginx location
    nginx日志配置,以及日志轮询
    nginx别名配置,状态配置,include优化
    第一篇 先用socket模拟web服务器
    第二十八篇、自定义线程池
  • 原文地址:https://www.cnblogs.com/cmymm/p/9746434.html
Copyright © 2011-2022 走看看