<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Price Slider</title>
    <link rel="stylesheet" href="style.css">
</head>
<body>
    <h1>Price Slider</h1>
    <div>
        <span id="rangeValue">0</span>
        <Input type="range" name "" value="0" min="0" max="1000" onChange="rangeSlide(this.value)" 
onmousemove="rangeSlide(this.value)"></Input>
    </div>
    <script src="index.js"></script>
</body>
</html>
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300&display=swap'); * { margin: 0; padding: 0; font-family: "Poppins", sans-serif; } body { display: flex; justify-content: center; align-items: center; min-height: 100vh; background: #0d064c; background: linear-gradient(117deg,#0d064c 0,#740887 100%); } h1{ color: white; margin-bottom: 200px; font-size:4rem; } div { position: absolute; } #rangeValue { position: relative; display: block; text-align: center; font-size: 6em; color: #999; font-weight: 400; } .range { width: 400px; height: 15px; background: #111; outline: none; border-radius: 15px; overflow: hidden; box-shadow: inset 0 0 5px rgba(0, 0, 0, 1); } .range::-webkit-slider-thumb { width: 15px; height: 15px; border-radius: 50%; background: #00fd0a; cursor: pointer; border: 4px solid #333; box-shadow: -407px 0 0 400px #00fd0a; }
function rangeSlide(value) { document.getElementById("rangeValue").innerHTML = value; }

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.