css自定义复选框表单美化样式

所属分类: 网页特效-表单美化    2023-12-16 11:49:22

css自定义复选框表单美化样式 ie兼容6
反馈问题  查看演示  登录后下载 温馨提示
登录会员即可享受免费下载
 我要建站

css自定义复选框表单美化样式(共2个文件)

    • index.html

使用方法

.cd__main{
   display: block !important;
}

/* Base for label styling */
	[type="checkbox"]:not(:checked),
	[type="checkbox"]:checked {
		position: absolute;
		left: 0;
		opacity: 0.01;
	}
	[type="checkbox"]:not(:checked) + label,
	[type="checkbox"]:checked + label {
		position: relative;
		padding-left: 2.3em;
		font-size: 1.05em;
		line-height: 1.7;
		cursor: pointer;
	}

	/* checkbox aspect */
	[type="checkbox"]:not(:checked) + label:before,
	[type="checkbox"]:checked + label:before {
		content: '';
		position: absolute;
		left: 0;
		top: 0;
		width: 1.4em;
		height: 1.4em;
		border: 1px solid #aaa;
		background: #FFF;
		border-radius: .2em;
		box-shadow: inset 0 1px 3px rgba(0,0,0, .1), 0 0 0 rgba(203, 34, 237, .2);
		-webkit-transition: all .275s;
				transition: all .275s;
	}

	/* checked mark aspect */
	[type="checkbox"]:not(:checked) + label:after,
	[type="checkbox"]:checked + label:after {
		content: '✕';
		position: absolute;
		top: .525em;
		left: .18em;
		font-size: 1.375em;
		color: #CB22ED;
		line-height: 0;
		-webkit-transition: all .2s;
				transition: all .2s;
	}

	/* checked mark aspect changes */
	[type="checkbox"]:not(:checked) + label:after {
		opacity: 0;
		-webkit-transform: scale(0) rotate(45deg);
				transform: scale(0) rotate(45deg);
	}

	[type="checkbox"]:checked + label:after {
		opacity: 1;
		-webkit-transform: scale(1) rotate(0);
				transform: scale(1) rotate(0);
	}

	/* Disabled checkbox */
	[type="checkbox"]:disabled:not(:checked) + label:before,
	[type="checkbox"]:disabled:checked + label:before {
		box-shadow: none;
		border-color: #bbb;
		background-color: #e9e9e9;
	}

	[type="checkbox"]:disabled:checked + label:after {
		color: #777;
	}

	[type="checkbox"]:disabled + label {
		color: #aaa;
	}

	/* Accessibility */
	[type="checkbox"]:checked:focus + label:before,
	[type="checkbox"]:not(:checked):focus + label:before {
		box-shadow: inset 0 1px 3px rgba(0,0,0, .1), 0 0 0 6px rgba(203, 34, 237, .2);
	}




/*
 * Useless styles, just for demo design
 */
body {
  font-family: "Open Sans", "Segoe WP", "Segoe UI", Helvetica, Arial, sans-serif;
  text-align: center;
  color: #34495E;
    background: #FCFDFD;
}

a[href^="https://www.creativejuiz"] {
  color: #34495E;
  text-decoration: underline;
}

h1 {
  margin-top: 1em;
}

h2 {
  margin-top: 0;
  margin-bottom: 2em;
  color: #CB22ED;
  font-weight: normal;
}

form {
  width: 120px;
  margin: 0 auto 55px;
  text-align: left;
}

div p:first-child {
  font-weight: bold;
  font-size: 1.2em;
}

p { 
  color: #aaa;
}

p a {
  color: inherit;
}

p + p {
  margin-top: 3em;
}

form p {
  margin: 15px 0;
  color: #34495E;
}

a[href^="https://twitter.com"] {
  color: #1da1f2;
}

.btn.btn {
  display: inline-block;
  padding: 8px 24px;
  text-decoration: none;
  border-radius: 40px;
  background: #34495E;
  color: #F2F2F2;
  transition: all .4s;
}

.btn.btn:hover,
.btn.btn:focus {
  background: #000;
}

站长提示:
1. 平台上所有素材资源,需注册登录会员方能正常下载。
2. 会员用户积极反馈网站、素材资源BUG或错误问题,每次奖励20K币
3. PHP源码类素材,如需协助安装调试,或你有二次开发需求,可联系苦力吧客服。
4. 付费素材资源,需充值后方能下载,如有任何疑问可直接联系苦力吧客服
相关资源 / 表单美化

CSS创建的一个拱形切换开关特效代码

一个switch UI按钮,支持鼠标点击切换打开或关闭。单击时开关外观会发生变化。
  表单美化
 181  

jquery网页滚动条美化插件

一款水平垂直滚动条美化插件,可自定义滚动条宽度、颜色等,非常实用。
  表单美化
 189  

jquery下拉菜单select下拉框美化插件

一款select下拉菜单表单美化插件,带有两种加载方式:JS数组加载菜单、JSON字符串加载菜单。
  表单美化
 190  

jquery点击开关按钮可切换白天黑夜模式特效代码

一款网页背景点击切换特效,点击IOS风格的开关按钮,可切换白色背景或黑色背景。
  表单美化
 253  

评论数(0) 回复有机会获得K币 用户协议

^_^ 还没有人评论,快来抢个沙发!
😀
  • 😀
  • 😊
  • 😂
  • 😍
  • 😑
  • 😷
  • 😵
  • 😛
  • 😣
  • 😱
  • 😋
  • 😎
  • 😵
  • 😕
  • 😶
  • 😚
  • 😜
  • 😭
发表评论