0基础学web----小鲜项目搭建(拓展)

01-CSS精灵-作用

02-CSS精灵-使用

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .one{
            width: 20px;
            height: 25px;
            background-color: black;
            background-image: url(./images/taobao.png);
            background-position: -2px 0px;

        }
        .two{
            margin-top: 20px;
            width: 24px;
            height: 20px;
            background-color:blue;
            background-image: url(./images/taobao.png);
            background-position: 0px -90px;

            
        }
    </style>
</head>
<body>
    <div class="one"></div>
    <div class="two"></div>
</body>
</html>

03-背景图缩放

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box{
            width: 300px;
            height: 400px;
            background-color: blue;
            background-image: url(./images/1.jpg);
            background-repeat: no-repeat;
            /* background-size: 宽300px 高400px; */

            background-size: 300px 400px;

            /* background-size: 100%; */

            /*图片等比例拉满*/
            background-size: contain;

            /*图片把盒子拉满,不留空格*/
            /* background-size: cover; */

        }
    </style>
</head>
<body>
    <div class="box"></div>
</body>
</html>


background-size: contain;  /*图片等比例拉满*/


 background-size: cover;   /*图片把盒子拉满,不留空格*/

 

04-盒子阴影


text-shadow: 水平 垂直 模糊度 颜色;     /*文字阴影*/

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
         .text{
             text-shadow: 3px 6px 2px red;
         }
    </style>
</head>
<body>
    
    <div class="text"><h1>多喝热水啊</h1></div>
</body>
</html>


box-shadow: 水平 垂直 模糊度 颜色;     /*盒子阴影*/

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box{
            width: 300px;
            height: 300px;
            background-color: blue;

            /* box-shadow: 水平20px 垂直30px 模糊度5px 颜色red;*/
            box-shadow: 20px 30px 5px red;
        }
    </style>
</head>
<body>
    <div class="box"></div>
</body>
</html>

05-过度

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box{
            width: 200px;
            height: 200px;
            background-color: red;
            /*all所有属性进行过度*/
            transition: all  3s;
        }
        .box:hover{
            width: 600px;
            background-color: paleturquoise;
        }
    </style>
</head>
<body>
    <div class="box"></div>
</body>
</html>

鼠标悬停前

 鼠标悬停后

06-骨架标签

 

07-SEO

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
    <title>京东(JD.COM)-正品低价、品质保障、配送及时、轻松购物!</title>
    <meta name="description" content="京东JD.COM-专业的综合网上购物商城,为您提供正品低价的购物选择、优质便捷的服务体验。商品来自全球数十万品牌商家,囊括家电、手机、电脑、服装、居家、母婴、美妆、个护、食品、生鲜等丰富品类,满足各种购物需求。">
    <meta name="keywords" content="网上购物,网上商城,家电,手机,电脑,服装,居家,母婴,美妆,个护,食品,生鲜,京东">
</head>
<body>
    
</body>
</html>

08-favicon-标题图标

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>小鲜项目搭建</title>
    <link rel="shortcut icon" href="favicon.ico" type="image/x-icon">
</head>
<body>
    
</body>
</html>

  

获取文章流量推荐曝光度随便胡说八道两句

vue3.0带来了什么

1.性能的提升

  • 打包大小减少41%
  • 初次渲染快55%,更新渲染块133%
  • 内存减少54%
  • ........

2.源码的升级

  • 使用Proxy代替defineProperty实现响应式
  • 重写虚拟DOM的实现和Tree-Sharking
  • ......

3.拥抱TypeScript

  • vue3.0更好的支持TypeScript

4.新的特性

Composition API(组合api)

。 setup配置

。ref与reactive

。watch与watchEffect

。 provide和inject

。 .......

新的内置组件

。 Fragment

。Teleport

。Suspense

其他改变

。新的生命周期钩子

。data选项应始终被声明为一个函数

。移除keyCode支持作为v-on的修饰符

想要视频教学?

请点击下方链接吧!

黑马程序员web前端开发入门教程,前端零基础html5+css3+前端项目视频教程_哔哩哔哩_bilibili

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

情绪员Tim

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值