自带背景提示效果的拖动条
代码语言:html
所属分类:表单美化
代码描述:自带背景提示效果的拖动条
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <style> * { margin: 0; padding: 0; box-sizing: border-box; } main { display: flex; flex-flow: column nowrap; justify-content: center; align-items: center; width: 100vw; height: 100vh; background: linear-gradient(to right, #ff5c5c, #ffa860, #e3dc44, #57b02a); } .fill-area { position: absolute; top: 0; left: 0; z-index: 0; width: 100vw; height: 100vh; background: #333838; box-shadow: inset 3px 3px 5px -1px #111; pointer-events: none; } label { position: static; z-index: 1; font: 8rem "Monoton", sans-serif; color: #ec7474; margin: -5rem 0 2rem; } label::after { content: "%"; } input[type=range] { position: static; z-index: 2; width: 50vw; height: 1rem; background: rgba(88,36,36,0.8); -webkit-appearance: none; -moz-appearance: none; appearance: none; border: none; outline: none; border-radius: 100vmax; box-shadow: inset 3px 3px 5px -1px #000; } input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; -moz-appearance: none; appearance: none; width: 4vw; height: 4vw; background: #eee; border-radius: 50%; cursor: pointer; box-shadow: 5px 5px 8px -1px #000; transition: box-shadow 0.3s ease-in-out; } input[type=range]:hover::-webkit-slider-thumb { backg.........完整代码请登录后点击上方下载按钮下载查看
网友评论0