div+Css布局实现checkbox播放与停止播放滑动切换按钮代码
代码语言:html
所属分类:布局界面
代码描述:div+Css布局实现checkbox播放与停止播放滑动切换按钮代码
代码标签: div Css 布局 checkbox 播放 停止 播放 滑动 切换 按钮
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width,initial-scale=1.0,maximum=1.0,minimum=1.0,user-scalable=0" /> <style> .toggle-cont { margin: 100px auto; width: 100px; height: 50px; border-radius: 9999px; } .toggle-cont .toggle-input { display: none; } .toggle-cont .toggle-label { cursor: pointer; position: relative; display: inline-block; padding: 6px; width: 100%; height: 100%; background: #272727; border-radius: 9999px; box-sizing: content-box; box-shadow: 0px 0px 16px -8px #fefefe; } .toggle-cont .toggle-label .cont-label-play { position: relative; width: 50px; aspect-ratio: 1 / 1; background: #5e5e5e; border-radius: 9999px; transition: all 0.5s cubic-bezier(1, 0, 0, 1); } .toggle-cont .toggle-input:checked + .toggle-label .cont-label-play { background: #f43f5e; transform.........完整代码请登录后点击上方下载按钮下载查看
网友评论0