css实现胶囊checkbox开关按钮效果代码

代码语言:html

所属分类:表单美化

代码描述:css实现胶囊checkbox开关按钮效果代码

代码标签: checkbox 开关 按钮 效果

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


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

<head>

  <meta charset="UTF-8">
  

  <meta name="viewport" content="width=device-width, initial-scale=1">
  
  
  
<style>
/*
 * <input type=checkbox class=switch>
 * License: MIT
 */
input[role=switch] {
	appearance: none;
	-webkit-appearance: none;
	position: relative;
	display: inline-block;
	width: 2.4em;
	height: 1.4em;
	margin: -.2em 0;
	box-sizing: content-box;
	padding: 0;
	.........完整代码请登录后点击上方下载按钮下载查看

网友评论0