참고 자료
https://mui.com/material-ui/customization/how-to-customize/
How to customize - Material UI
Learn how to customize Material UI components by taking advantage of different strategies for specific use cases.
mui.com
참고 코드
<Slider
defaultValue={30}
sx={{
width: 300,
color: 'success.main',
'& .MuiSlider-thumb': {
borderRadius: '1px',
},
}}
/>
import * as React from 'react';
import Slider from '@mui/material/Slider';
import { alpha, styled } from '@mui/material/styles';
const SuccessSlider = styled(Slider)(({ theme }) => ({
width: 300,
color: theme.palette.success.main,
'& .MuiSlider-thumb': {
'&:hover, &.Mui-focusVisible': {
boxShadow: `0px 0px 0px 8px ${alpha(theme.palette.success.main, 0.16)}`,
},
'&.Mui-active': {
boxShadow: `0px 0px 0px 14px ${alpha(theme.palette.success.main, 0.16)}`,
},
},
}));
export default function StyledCustomization() {
return <SuccessSlider defaultValue={30} />;
}
'프론트엔드 > React' 카테고리의 다른 글
[React] 로그인 검증 (0) | 2023.08.02 |
---|---|
[React] input 여러개의 이벤트 감지하기 (0) | 2023.08.02 |
[React] input 데이터들을 axios를 활용하여 POST 하는 방법 (0) | 2023.07.27 |
[React] 리액트 다운그레이드 / 패키지 다운그레이드 / 피어 종속성 / npm오류 / 패키지 설치 오류 / Mui 패키지 설치 오류 / Mui 오류 / npm ERR! code ERESOLVEnpm ERR! ERESOLVE could not resolve / C:\Users\이동규\Des.. (0) | 2023.07.20 |
[React] form 내부 데이터 받기 (0) | 2023.07.18 |