@@ -5,9 +5,9 @@ import type { BindingValue } from "types/util/react";
5
5
6
6
export interface FrameProps < T extends Instance = Frame > extends React . PropsWithChildren {
7
7
/** An optional helper that rounds the corners of the frame. */
8
- readonly CornerRadius ?: BindingValue < UDim > ;
8
+ CornerRadius ?: BindingValue < UDim > ;
9
9
/** The default properties of the component. */
10
- readonly Native ?: Partial < React . InstanceProps < T > > ;
10
+ Native ?: Partial < React . InstanceProps < T > > ;
11
11
}
12
12
13
13
/**
@@ -29,20 +29,22 @@ export interface FrameProps<T extends Instance = Frame> extends React.PropsWithC
29
29
*
30
30
* @see https://create.roblox.com/docs/reference/engine/classes/Frame
31
31
*/
32
- const Frame = forwardRef ( ( { CornerRadius, Native, children } : FrameProps , ref : Ref < Frame > ) => {
33
- const { AnchorPoint, Position } = Native ?? { } ;
32
+ const Frame = forwardRef (
33
+ ( { CornerRadius, Native, children } : Readonly < FrameProps > , ref : Ref < Frame > ) => {
34
+ const { AnchorPoint, Position } = Native ?? { } ;
34
35
35
- return (
36
- < frame
37
- ref = { ref }
38
- { ...Native }
39
- AnchorPoint = { AnchorPoint ?? new Vector2 ( 0.5 , 0.5 ) }
40
- Position = { Position ?? new UDim2 ( 0.5 , 0 , 0.5 , 0 ) }
41
- >
42
- { children }
43
- { CornerRadius ? < uicorner CornerRadius = { CornerRadius } /> : undefined }
44
- </ frame >
45
- ) ;
46
- } ) ;
36
+ return (
37
+ < frame
38
+ ref = { ref }
39
+ { ...Native }
40
+ AnchorPoint = { AnchorPoint ?? new Vector2 ( 0.5 , 0.5 ) }
41
+ Position = { Position ?? new UDim2 ( 0.5 , 0 , 0.5 , 0 ) }
42
+ >
43
+ { children }
44
+ { CornerRadius ? < uicorner CornerRadius = { CornerRadius } /> : undefined }
45
+ </ frame >
46
+ ) ;
47
+ } ,
48
+ ) ;
47
49
48
50
export default Frame ;
0 commit comments