File tree Expand file tree Collapse file tree 3 files changed +11
-7
lines changed
form/required-fields-indicator Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Original file line number Diff line number Diff line change 1
1
import React from "react" ;
2
2
import styled from "styled-components" ;
3
- import { MarginProps } from "styled-system" ;
4
- import Box from "../../box " ;
3
+ import { margin , MarginProps } from "styled-system" ;
4
+ import BaseTheme from "../../../style/themes/base " ;
5
5
import StyledTypography from "../../typography/typography.style" ;
6
6
7
7
export interface RequiredIndicatorProps extends MarginProps {
8
8
children : React . ReactNode ;
9
9
}
10
10
11
- const StyledIndicatorContainer = styled ( Box ) `
11
+ const StyledIndicatorContainer = styled . div `
12
+ ${ margin }
13
+
12
14
${ StyledTypography } {
13
15
color: var(--colorsUtilityYin090);
14
16
}
@@ -20,6 +22,10 @@ const StyledIndicatorContainer = styled(Box)`
20
22
}
21
23
` ;
22
24
25
+ StyledIndicatorContainer . defaultProps = {
26
+ theme : BaseTheme ,
27
+ } ;
28
+
23
29
export default ( { children, ...rest } : RequiredIndicatorProps ) => (
24
30
< StyledIndicatorContainer { ...rest } > { children } </ StyledIndicatorContainer >
25
31
) ;
Original file line number Diff line number Diff line change 1
1
import React from "react" ;
2
2
import styled from "styled-components" ;
3
3
import { PaddingProps , FlexboxProps } from "styled-system" ;
4
- import Box from "../box" ;
5
4
import NavigationBar from "../navigation-bar" ;
6
5
import { TagProps } from "../../__internal__/utils/helpers/tags" ;
7
6
@@ -15,7 +14,7 @@ export interface GlobalHeaderProps
15
14
logo ?: React . ReactNode ;
16
15
}
17
16
18
- const StyledLogo = styled ( Box ) `
17
+ const StyledLogo = styled . div `
19
18
display: flex;
20
19
align-items: center;
21
20
margin-left: var(--spacing200);
Original file line number Diff line number Diff line change 1
1
import styled , { css } from "styled-components" ;
2
2
3
3
import { margin , MarginProps } from "styled-system" ;
4
- import Box from "../box" ;
5
4
import addFocusStyling from "../../style/utils/add-focus-styling" ;
6
5
7
6
type StyledTextEditorWrapperProps = MarginProps ;
@@ -20,7 +19,7 @@ interface StyledEditorToolbarWrapperProps {
20
19
hasWarningOrError ?: boolean ;
21
20
}
22
21
23
- export const StyledTextEditor = styled ( Box ) `
22
+ export const StyledTextEditor = styled . div `
24
23
position : relative;
25
24
` ;
26
25
You can’t perform that action at this time.
0 commit comments