当前位置:网站首页>02.折叠隐藏文字
02.折叠隐藏文字
2022-08-11 04:50:00 【拂晓等明月】
02.折叠隐藏文字
今日份打卡!经验值+1
进度002
今天的有点简单

代码:
<!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>
<style>
*{
margin: 0;
padding: 0;
}
body{
background-color: aquamarine;
width: 100%;
/* 整个视口的高度,加上flex使其子元素垂直居中 */
height: 100vh;
display: flex;
}
.box{
/* width: 260px; */
height: 70px;
border-radius: 25px;
background-color: brown;
margin: auto;
position: relative;
}
.my-span{
font-size: 34px;
line-height: 70px;
/* span是行内元素,要变 */
display: inline-block;
}
.yin{
/* 透明度 */
opacity: 0;
width: 0;
transition: all 1s;
}
.yi{
margin-left: 10px;
}
.box:hover .yin{
opacity: 1;
width: 40px;
}
.mont{
margin-top: 30px;
float: left;
width: 10px;
height: 10px;
border-radius: 5px;
background-color: black;
}
.mone{
float: right;
margin-top: 30px;
width: 10px;
height: 10px;
border-radius: 5px;
background-color: black;
}
.box:hover .mont{
opacity: 1;
width: 0px;
height: 0;
}
.box:hover .mone{
opacity: 1;
width: 0px;
height: 0;
}
</style>
</head>
<body>
<div class="box">
<span class="mont"></span>
<span class="my-span yin yi">深</span>
<span class="my-span yin">山</span>
<span class="my-span yin">寻</span>
<span class="my-span yin">折</span>
<span class="my-span yin">桂</span>
<span class="mone"></span>
</div>
</body>
</html>边栏推荐
- 【服务器安装Redis】Centos7离线安装redis
- 标识密码技术在 IMS 网络中的应用
- Redis: Solve the problem of modifying the same key with distributed high concurrency
- AVH 动手实践 (二) | 在 Arm 虚拟硬件上部署 PP-OCR 模型
- 「转」“搜索”的原理,架构,实现,实践,面试不用再怕了
- [Note] Is the value of BatchSize the bigger the better?
- -Fill in color-
- 洛谷P4032 火锅盛宴
- 交换机和路由器技术-32-命名ACL
- "125 Palindrome Verification" of the 10th day string series of LeetCode brushing questions
猜你喜欢

应用层协议——DNS

梅克尔工作室--OpenEuler培训笔记(1)

2021年网络规划设计师下午案例题

To break the bottleneck of transactional work, the gentleman signs the electronic contract to release the "source power" of HR!

洛谷P2150 寿司晚宴

leetcode 9. 回文数

0基础转行软件测试,自学3个月,浅拿12k*13薪offer

北湖区燕泉街道开展“戴头盔·保安全”送头盔活动

Object Creation and Display Transformation

分层架构&SOA架构
随机推荐
The priority queue
"239 Sliding Window Maximum Value" on the 16th day of LeetCode brushing
【FPGA教程案例50】控制案例2——基于FPGA的PD控制器verilog实现
洛谷P2245 星际导航
洛谷P2150 寿司晚宴
【服务器安装mysql】centos7下使用mysql离线安装包安装mysql5.7
如何进行AI业务诊断,快速识别降本提效增长点?
洛谷P5139 z小f的函数
form表单提交数据库中文变成问号
【深度学习】基于卷积神经网络的天气识别训练
1815. 得到新鲜甜甜圈的最多组数 状态压缩
The principle, architecture, implementation, practice of "transfer" and "search", no need to be afraid of interviews
优先级队列
交换机和路由器技术-36-端口镜像
自研能力再获认可,腾讯云数据库入选 Forrester Translytical 报告
Word2021 中的图片保存后就变模糊了
如何阅读论文
Research on a Consensus Mechanism-Based Anti-Runaway Scheme for Digital Trunking Terminals
Switch---Spanning Tree---Three-layer Architecture Summary
校园兼职平台项目反思