div+css实现方块checkbox开关彩虹动画效果代码

代码语言:html

所属分类:布局界面

代码描述:div+css实现方块checkbox开关彩虹动画效果代码

代码标签: div css 方块 checkbox 开关 彩虹 动画

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html lang="en" >

<head>
  <meta charset="UTF-8">

<style>
body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin: 0;
  min-height: 100vh;
  font-size: 4rem;
  background: #000;
  gap: 0.5em;
}

@property --x1 { syntax: '<percentage>'; initial-value: 3%; inherits: false; }
@property --x2 { syntax: '<percentage>'; initial-value: 3%; inherits: false; }
@property --x3 { syntax: '<percentage>'; initial-value: 3%; inherits: false; }
@property --x4 { syntax: '<percentage>'; initial-value: 3%; inherits: false; }
@property --x5 { syntax: '<percentage>'; initial-value: 3%; inherits: false; }
@property --x6 { syntax: '<percentage>'; initial-value: 3%; inherits: false; }
@property --x7 { syntax: '<percentage>'; initial-value: 3%; inherits: false; }
@property --x8 { syntax: '<percentage>'; initial-value: 3%; inherits: false; }
@property --x9 { syntax: '<percentage>'; initial-value: 3%; inherits: false; }

.toggle {
  appearance: none;
  position: relative;
  f.........完整代码请登录后点击上方下载按钮下载查看

网友评论0