zheng 2 settimane fa
parent
commit
aa18cb1c03
7 ha cambiato i file con 101 aggiunte e 0 eliminazioni
  1. 28 0
      16.scss/index.css
  2. 28 0
      16.scss/index.html
  3. 1 0
      16.scss/index.min.css
  4. 29 0
      16.scss/index.scss
  5. 7 0
      16.scss/reset.css
  6. 1 0
      16.scss/reset.min.css
  7. 7 0
      16.scss/reset.scss

+ 28 - 0
16.scss/index.css

@@ -0,0 +1,28 @@
+@charset "UTF-8";
+* {
+  margin: 0;
+  padding: 0;
+  list-style: none;
+  text-decoration: none;
+  box-sizing: border-box;
+}
+
+/*
+    多行注释
+    .sass .scss
+    sass格式会省略花括号和分号 所以常用scss存储
+*/
+.box {
+  width: 200px;
+  height: 200px;
+  font-size: 30px;
+  border: 3px solid red;
+}
+
+h1 {
+  color: blue;
+}
+
+h2 {
+  color: blue;
+}

+ 28 - 0
16.scss/index.html

@@ -0,0 +1,28 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+    <meta charset="UTF-8">
+    <meta name="viewport" content="width=device-width, initial-scale=1.0">
+    <title>Document</title>
+    <link rel="stylesheet" href="./index.css">
+</head>
+<body>
+    <div class="box">
+        你好
+    </div>
+    <h1>111111</h1>
+    <h2>222222</h2>
+    <ul>
+        <li><a href="">你好</a></li>
+        <li><a href="">你好</a></li>
+        <li><a href="">你好</a></li>
+        <li><a href="">你好</a></li>
+        <li><a href="">你好</a></li>
+        <li><a href="">你好</a></li>
+        <li><a href="">你好</a></li>
+        <li><a href="">你好</a></li>
+        <li><a href="">你好</a></li>
+    </ul>
+    <script></script>
+</body>
+</html>

+ 1 - 0
16.scss/index.min.css

@@ -0,0 +1 @@
+*{margin:0;padding:0;list-style:none;text-decoration:none;box-sizing:border-box}.box{width:200px;height:200px;font-size:30px;border:3px solid red}h1{color:blue}h2{color:blue}

+ 29 - 0
16.scss/index.scss

@@ -0,0 +1,29 @@
+// @import url(reset.css);
+@import './reset.scss';
+$a: red !default;
+$b: 30;
+$d: purple;
+
+// $ 定义变量 用于存储信息 可以重复使用
+// 存储的类型:字符串 数字 颜色 布尔值 null...
+/*
+    多行注释
+    .sass .scss
+    sass格式会省略花括号和分号 所以常用scss存储
+*/
+.box {
+    width: 200px;
+    height: 200px;
+    font-size: $b + px;
+    border: 3px solid $a;
+}
+
+h1 {
+    $c:blue !global;
+    color: $c;
+}
+
+h2 {
+    // color: $a !important;
+    color: $c;
+}

+ 7 - 0
16.scss/reset.css

@@ -0,0 +1,7 @@
+* {
+  margin: 0;
+  padding: 0;
+  list-style: none;
+  text-decoration: none;
+  box-sizing: border-box;
+}

+ 1 - 0
16.scss/reset.min.css

@@ -0,0 +1 @@
+*{margin:0;padding:0;list-style:none;text-decoration:none;box-sizing:border-box}

+ 7 - 0
16.scss/reset.scss

@@ -0,0 +1,7 @@
+* {
+    margin: 0;
+    padding: 0;
+    list-style: none;
+    text-decoration: none;
+    box-sizing: border-box;
+}