CSS 彩虹按钮效果

复制代码
<template>
	<view class="content">
	  <button class="btn">彩虹按钮</button>
	</view>
</template>

<script>

</script>

<style>
	body{
		background-color: #000;
	}
	.content {
		margin-top: 300px;
	
	}

	
	.btn {
	  width: 170px;
	  height: 60px;
	  font-size: 18px;
	  background: #fff;
	  border: none;
	  border-radius: 50px;
	  color: #000;
	  outline: none;
	  cursor: pointer;
	  transition: all 0.4s;
	  align-items: center;
	  display: flex;
	  justify-content: center;
	}
	
	.btn:hover {
	  box-shadow: inset 0 0 0 4px #ef476f, 
	              inset 0 0 0 8px #ffd166, 
	              inset 0 0 0 12px #06d6a0,
	              inset 0 0 0 16px #118ab2;
	  background: #073b4c;
	  color: #fff;
	}
</style>
相关推荐
RopenYuan40 分钟前
FastAPI -API Router的应用
前端·网络·python
走粥1 小时前
clsx和twMerge解决CSS类名冲突问题
前端·css
Purgatory0012 小时前
layui select重新渲染
前端·layui
weixin199701080162 小时前
《中国供应商商品详情页前端性能优化实战》
前端·性能优化
九皇叔叔3 小时前
003-SpringSecurity-Demo 统一响应类
java·javascript·spring·springsecurity
赵孝正4 小时前
学习的本质是一个工程闭环:从模仿到内化的四阶段方法论(附风电实战案例)
前端·数据库·学习
低代码布道师4 小时前
纯代码实战:MBA培训管理系统 (十四) ——用户管理(批量选择与批量删除)
javascript·nextjs
Hello--_--World5 小时前
JavaScript运行机制、v8原理、js事件循环
开发语言·javascript·ecmascript