Notice
Recent Posts
Recent Comments
Link
์ผ | ์ | ํ | ์ | ๋ชฉ | ๊ธ | ํ |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- ํ๋ก ํธ์๋
- negative margin
- CSS
- ์ฝ์ฝ์ํก ํด๋ก ์ฝ๋ฉ
- ์ฝ๋ฉ๋ ํ
- canvas js
- HTML
- tanstack-query
- HTML ํ์ผ๊ตฌ์กฐ
- JAVA Script
- next.js
- tailwindcss
- canvas
- ์น ๋ธ๋ผ์ฐ์ ๊ตฌ์กฐ
- typescript
- react
- ์ฝ๋ฉ์ผ๊ธฐ
- ์น ๋ธ๋ผ์ฐ์ ๋ ๋๋ง
- queryprovider
- javascript
- clone coding
- ๋ฐ๋๋ผ JS๋ก ํฌ๋กฌ ์ฑ ๋ง๋ค๊ธฐ
- ๋ฐ๋๋ผ JS๋ก ๊ทธ๋ฆผํ ๋ง๋ค๊ธฐ
- ์ํ์ฝ๋ฉ
- ๋ ธ๋ง๋์ฝ๋
- canvas image
- ๋ ธ๋ง๋ ์ฝ๋
- jest
- axios-mock-adapte
- JS
Archives
- Today
- Total
Coding Archive
range slider css ๋ณ๊ฒฝํ๊ธฐ ๋ณธ๋ฌธ
range slider css ๋ณ๊ฒฝํ๊ธฐ
input ํ๊ทธ์ type์์ฑ ์ค range์ css๋ฅผ ๋ณ๊ฒฝํด๋ณด์์ต๋๋ค.
๋จผ์ html์์ ๊ฐ์ฅ ๊ธฐ๋ณธ์ ์ธ ํํ๋ฅผ ๋ง๋ค์์ ๋๋ ์ด๋ฐ ํํ์ range slider๊ฐ ๋ง๋ค์ด์ง๋๋ค.
1
|
<input type=”range”>
|
cs |
html์์ ๊ธฐ๋ณธ์ ์ธ ์์ฑ๋ค์ ์กฐ์ ๊ฐ๋ฅํฉ๋๋ค. (์ต๋๊ฐ, ์ต์๊ฐ, ๊ธฐ๋ณธ๊ฐ, ์กฐ์ ๊ฐ ๋ฑ)
1
2
3
4
5
6
7
8
|
<input
type="range"
min="1"
max="10"
value="5"
step="1"
/>
<!--์ต์๊ฐ 1, ์ต๋๊ฐ 10, ๊ธฐ๋ณธ๊ฐ 5, ์กฐ์ ๊ฐ 1-->
|
cs |
๊ทธ ํ css์์ ์ํ๋ ๋ชจ์๋๋ก ๋ง๋ค์ด ์ค๋๋ค.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
/** slider **/
input[type=range] {
-webkit-appearance: none;
background-color: #e0e0e0;
opacity: 0.8;
border-radius: 7.5px;
width: 30%;
height: 15px;
box-shadow: var(--box-shadow);
}
/** slider handle **/
input[type=range]::-webkit-slider-thumb {
-webkit-appearance: none;
border-radius: 7.5px;
width: 15%;
height: 15px;
background-color: var(--gray-color);
box-shadow: var(--box-shadow);
cursor: pointer;
}
|
cs |

์ฌ๊ธฐ์ ์ฃผ์ํ ์ ์ ๊ธฐ๋ณธ css style์ ์์ ์ฃผ๊ธฐ ์ํด -webkit-appearance: none; ๋๋ appearance: none; ์ ๋จผ์ ์ ์ธํด์ผ ํ๋ ๊ฒ์ ๋๋ค.
'๐ป Programming > HTML & CSS' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
[ HTML & CSS ] ๋ ์ด์์์ ํต์ฌ, flexbox (0) | 2023.03.29 |
---|---|
[ HTML & CSS ] ๋ ์ด์์์ ํต์ฌ, margin (negative margin) (0) | 2023.03.18 |
[ HTML & CSS ] CSS background ์์ฑ์ ์ฌ์ฉํด ์ด๋ฏธ์ง ๋ฃ๊ธฐ (0) | 2023.03.07 |
[ HTML ๊ธฐ์ด ] HTML / CSS ํ์ผ ๊ตฌ์กฐ ๋ฐ ํ์ผ ๊ฒฝ๋ก (0) | 2023.03.02 |
Comments