We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 42c1bc0 commit ad58820Copy full SHA for ad58820
packages/@react-spectrum/label/src/Field.tsx
@@ -47,7 +47,10 @@ function Field(props: SpectrumFieldProps, ref: RefObject<HTMLElement>) {
47
);
48
49
children = React.cloneElement(children, mergeProps(children.props, {
50
- style: {width: '100%'}
+ className: classNames(
51
+ labelStyles,
52
+ 'spectrum-Field-field'
53
+ )
54
}));
55
56
return (
@@ -65,13 +68,7 @@ function Field(props: SpectrumFieldProps, ref: RefObject<HTMLElement>) {
65
68
elementType={elementType}>
66
69
{label}
67
70
</Label>
- <div
- className={classNames(
- labelStyles,
71
- 'spectrum-Field-field'
72
- )}>
73
- {children}
74
- </div>
+ {children}
75
</div>
76
77
}
0 commit comments