Skip to content

Commit 77df7d2

Browse files
authored
fix(docs): fix SVG attribute casing to remove React warnings (#10297)
### Description <table> <tr> <td> <img width="1512" alt="Screenshot 2025-04-06 at 14 59 33" src="https://github.com/user-attachments/assets/544f47b3-6488-4b57-9077-3921735a7f06" /> </td> <td> <img width="1512" alt="Screenshot 2025-04-06 at 14 59 46" src="https://github.com/user-attachments/assets/ebee4f0c-2246-4f9d-8c17-638ad463c66d" /> </td> </tr> <tr> <td align="center"> `turborepo-wordmark.tsx` </td> <td align="center"> `magnifying-glass.tsx` </td> </tr> </table> This PR fixes React warnings caused by incorrectly cased SVG attribute names in `turborepo-wordmark.tsx` and `magnifying-glass.tsx`. The root cause is the use of non-camelCase attribute names in SVG elements, which is not compliant with React's expected syntax. To resolve this, the affected SVG attributes have been updated to use camelCase, eliminating the warnings during `next dev`. ### Testing Instructions Clone the PR and run the project with `next dev`, or review the updated code to verify that the SVG attribute casing issues have been resolved.
1 parent e4f9b1e commit 77df7d2

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

docs/site/components/icons/magnifying-glass.tsx

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ export const MagnifyingGlass = ({ className }: { className?: string }) => {
33
<svg
44
className={className}
55
height="16"
6-
stroke-linejoin="round"
6+
strokeLinejoin="round"
77
viewBox="0 0 16 16"
88
width="16"
99
>
1010
<path
11-
fill-rule="evenodd"
12-
clip-rule="evenodd"
11+
fillRule="evenodd"
12+
clipRule="evenodd"
1313
d="M1.5 6.5C1.5 3.73858 3.73858 1.5 6.5 1.5C9.26142 1.5 11.5 3.73858 11.5 6.5C11.5 9.26142 9.26142 11.5 6.5 11.5C3.73858 11.5 1.5 9.26142 1.5 6.5ZM6.5 0C2.91015 0 0 2.91015 0 6.5C0 10.0899 2.91015 13 6.5 13C8.02469 13 9.42677 12.475 10.5353 11.596L13.9697 15.0303L14.5 15.5607L15.5607 14.5L15.0303 13.9697L11.596 10.5353C12.475 9.42677 13 8.02469 13 6.5C13 2.91015 10.0899 0 6.5 0Z"
1414
fill="currentColor"
1515
></path>

docs/site/components/icons/turborepo-wordmark.tsx

+8-8
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ export const TurborepoWordmarkDark = ({
5252
fill="white"
5353
/>
5454
<path
55-
fill-rule="evenodd"
56-
clip-rule="evenodd"
55+
fillRule="evenodd"
56+
clipRule="evenodd"
5757
d="M40.2115 14.744V7.125C56.7719 8.0104 69.9275 21.7208 69.9275 38.5016C69.9275 55.2824 56.7719 68.989 40.2115 69.8782V62.2592C52.5539 61.3776 62.3275 51.0644 62.3275 38.5016C62.3275 25.9388 52.5539 15.6256 40.2115 14.744ZM20.5048 54.0815C17.233 50.3043 15.124 45.4935 14.7478 40.2115H7.125C7.5202 47.6025 10.4766 54.3095 15.1088 59.4737L20.501 54.0815H20.5048ZM36.7916 69.8782V62.2592C31.5058 61.883 26.695 59.7778 22.9178 56.5022L17.5256 61.8944C22.6936 66.5304 29.4006 69.483 36.7878 69.8782H36.7916Z"
5858
fill="url(#paint0_linear_2028_477)"
5959
/>
@@ -66,8 +66,8 @@ export const TurborepoWordmarkDark = ({
6666
y2="42.4236"
6767
gradientUnits="userSpaceOnUse"
6868
>
69-
<stop stop-color="#0096FF" />
70-
<stop offset="1" stop-color="#FF1E56" />
69+
<stop stopColor="#0096FF" />
70+
<stop offset="1" stopColor="#FF1E56" />
7171
</linearGradient>
7272
</defs>
7373
</svg>
@@ -128,8 +128,8 @@ export const TurborepoWordmarkLight = ({
128128
fill="black"
129129
/>
130130
<path
131-
fill-rule="evenodd"
132-
clip-rule="evenodd"
131+
fillRule="evenodd"
132+
clipRule="evenodd"
133133
d="M40.2115 14.744V7.125C56.7719 8.0104 69.9275 21.7208 69.9275 38.5016C69.9275 55.2824 56.7719 68.989 40.2115 69.8782V62.2592C52.5539 61.3776 62.3275 51.0644 62.3275 38.5016C62.3275 25.9388 52.5539 15.6256 40.2115 14.744ZM20.5048 54.0815C17.233 50.3043 15.124 45.4935 14.7478 40.2115H7.125C7.5202 47.6025 10.4766 54.3095 15.1088 59.4737L20.501 54.0815H20.5048ZM36.7916 69.8782V62.2592C31.5058 61.883 26.695 59.7778 22.9178 56.5022L17.5256 61.8944C22.6936 66.5304 29.4006 69.483 36.7878 69.8782H36.7916Z"
134134
fill="url(#paint0_linear_2028_252)"
135135
/>
@@ -142,8 +142,8 @@ export const TurborepoWordmarkLight = ({
142142
y2="42.4236"
143143
gradientUnits="userSpaceOnUse"
144144
>
145-
<stop stop-color="#0096FF" />
146-
<stop offset="1" stop-color="#FF1E56" />
145+
<stop stopColor="#0096FF" />
146+
<stop offset="1" stopColor="#FF1E56" />
147147
</linearGradient>
148148
</defs>
149149
</svg>

0 commit comments

Comments
 (0)