File tree 3 files changed +11
-6
lines changed
www/src/content/docs/guides
3 files changed +11
-6
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ " astro-icon " : patch
3
+ ---
4
+
5
+ Added better typings for height, width and size to accept non-number values (i.e. 2 rem)
Original file line number Diff line number Diff line change @@ -11,9 +11,9 @@ interface Props extends HTMLAttributes<"svg"> {
11
11
name: Icon ;
12
12
" is:inline" ? : boolean ;
13
13
title? : string ;
14
- size? : number ;
15
- width? : number ;
16
- height? : number ;
14
+ size? : number | string ;
15
+ width? : number | string ;
16
+ height? : number | string ;
17
17
}
18
18
19
19
class AstroIconError extends Error {
Original file line number Diff line number Diff line change @@ -31,9 +31,9 @@ interface Props extends HTMLAttributes<"svg"> {
31
31
/** Shorthand for including a <title>{props.title}</title> element in the SVG */
32
32
title? : string ;
33
33
/** Shorthand for setting width and height */
34
- size? : number ;
35
- width? : number ;
36
- height? : number ;
34
+ size? : number | string ;
35
+ width? : number | string ;
36
+ height? : number | string ;
37
37
}
38
38
```
39
39
You can’t perform that action at this time.
0 commit comments