DocSpace-buildtools/packages/components/scrollbar/styled-scrollbar.js

32 lines
737 B
JavaScript
Raw Normal View History

import { Scrollbars } from "react-custom-scrollbars";
import styled from "styled-components";
2021-02-25 21:19:45 +00:00
import Base from "../themes/base";
const StyledScrollbar = styled(Scrollbars)`
.nav-thumb-vertical {
background-color: ${(props) =>
props.color
? props.color
: props.theme.scrollbar.backgroundColorVertical};
2022-08-17 14:55:59 +00:00
z-index: 201;
:hover,
:active {
background-color: ${(props) =>
props.theme.scrollbar.hoverBackgroundColorVertical};
}
}
.nav-thumb-horizontal {
background-color: ${(props) =>
props.color
? props.color
: props.theme.scrollbar.backgroundColorHorizontal};
}
`;
StyledScrollbar.defaultProps = {
theme: Base,
};
export default StyledScrollbar;