File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
redisinsight/ui/src/components/base/display/progress-bar Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 1
- import { theme , useTheme } from '@redis-ui/styles'
1
+ import { Theme , theme } from '@redis-ui/styles'
2
2
import { ReactNode } from 'react'
3
3
import styled , { css , keyframes } from 'styled-components'
4
4
@@ -39,10 +39,10 @@ export const getBarBackgroundColor = (
39
39
40
40
export interface MapProps extends LoaderBarProps {
41
41
$color ?: ColorType
42
+ theme : Theme
42
43
}
43
44
44
- export const useColorBackgroundStyles = ( { $color } : MapProps = { } ) => {
45
- const theme = useTheme ( )
45
+ export const getColorBackgroundStyles = ( { $color, theme } : MapProps ) => {
46
46
const colors = theme . semantic . color
47
47
48
48
const getColorValue = ( color ?: ColorType ) =>
@@ -76,7 +76,7 @@ export const LoaderContainer = styled.div<LoaderContainerProps>`
76
76
`
77
77
78
78
export const LoaderBar = styled . div < MapProps > `
79
- ${ useColorBackgroundStyles }
79
+ ${ ( { $color , theme } ) => getColorBackgroundStyles ( { $color , theme } ) } ;
80
80
81
81
position: absolute;
82
82
height: 100%;
You can’t perform that action at this time.
0 commit comments