chore: migrate to jsx element (#43707)

This commit is contained in:
RobertoMSousa
2021-10-04 14:46:34 +01:00
committed by GitHub
parent 2ba536d559
commit f5de80dc4f
8 changed files with 218 additions and 232 deletions

View File

@ -1,9 +1,8 @@
import React from 'react';
function AlibabaLogo(
const AlibabaLogo = (
props: JSX.IntrinsicAttributes & React.SVGProps<SVGSVGElement>
): React.ReactNode {
return (
): JSX.Element => (
<svg
id='alibaba-logo'
version='1.1'
@ -49,8 +48,7 @@ function AlibabaLogo(
</g>
</g>
</svg>
);
}
);
AlibabaLogo.displayName = 'AlibabaLogo';
export default AlibabaLogo;

View File

@ -1,9 +1,8 @@
import React from 'react';
function SpotifyLogo(
const SpotifyLogo = (
props: JSX.IntrinsicAttributes & React.SVGProps<SVGSVGElement>
): React.ReactNode {
return (
): JSX.Element => (
<svg
id='amazon-logo'
viewBox='93.907 250 1350 472'
@ -63,8 +62,7 @@ function SpotifyLogo(
/>
</g>
</svg>
);
}
);
SpotifyLogo.displayName = 'SpotifyLogo';

View File

@ -1,9 +1,8 @@
import React from 'react';
function AppleLogo(
const AppleLogo = (
props: JSX.IntrinsicAttributes & React.SVGProps<SVGSVGElement>
): React.ReactNode {
return (
): JSX.Element => (
<svg
id='apple-logo'
viewBox='450 0 500 650'
@ -17,8 +16,7 @@ function AppleLogo(
<path d=' M 784.1 91.348 C 804.071 67.159 817.553 33.524 813.839 0 C 785.07 1.155 750.249 19.179 729.592 43.368 C 711.099 64.746 694.877 98.991 699.273 131.833 C 731.358 134.32 764.125 115.501 784.1 91.348' />
</g>
</svg>
);
}
);
AppleLogo.displayName = 'AppleLogo';

View File

@ -1,8 +1,8 @@
import React from 'react';
function AsSeenInText(
const AsSeenInText = (
props: JSX.IntrinsicAttributes & React.SVGProps<SVGSVGElement>
): React.ReactNode {
): JSX.Element => {
const fill = props.fill === 'dark' ? 'var(--gray-75)' : 'var(--gray-15)';
return (
<svg
@ -116,7 +116,7 @@ function AsSeenInText(
/>
</svg>
);
}
};
AsSeenInText.displayName = 'AsSeenInText';

View File

@ -1,9 +1,8 @@
import React from 'react';
function GoogleLogo(
const GoogleLogo = (
props: JSX.IntrinsicAttributes & React.SVGProps<SVGSVGElement>
): React.ReactNode {
return (
): JSX.Element => (
<svg
id='google-logo'
viewBox='1635 200 1185 600'
@ -21,8 +20,7 @@ function GoogleLogo(
<path d=' M 1788.824 506.351 L 1788.824 464.911 L 1928.468 464.911 C 1929.833 472.134 1930.538 480.677 1930.538 489.925 C 1930.538 521.016 1922.039 559.461 1894.647 586.852 C 1868.004 614.596 1833.963 629.393 1788.868 629.393 C 1705.284 629.393 1635 561.31 1635 477.726 C 1635 394.143 1705.284 326.06 1788.868 326.06 C 1835.108 326.06 1868.048 344.204 1892.798 367.852 L 1863.556 397.093 C 1845.809 380.447 1821.765 367.5 1788.824 367.5 C 1727.788 367.5 1680.051 416.69 1680.051 477.726 C 1680.051 538.763 1727.788 587.953 1788.824 587.953 C 1828.414 587.953 1850.962 572.055 1865.406 557.611 C 1877.12 545.897 1884.827 529.163 1887.865 506.307 L 1788.824 506.351 Z ' />
</g>
</svg>
);
}
);
GoogleLogo.displayName = 'GoogleLogo';

View File

@ -1,9 +1,8 @@
import React from 'react';
function MicrosoftLogo(
const MicrosoftLogo = (
props: JSX.IntrinsicAttributes & React.SVGProps<SVGSVGElement>
): React.ReactNode {
return (
): JSX.Element => (
<svg
id='microsoft-logo'
viewBox='939.813 1185 1400 472'
@ -20,8 +19,7 @@ function MicrosoftLogo(
<path d=' M 1095.68 1430.867 L 1236.813 1430.867 L 1236.813 1572 L 1095.68 1572 L 1095.68 1430.867 Z ' />
</g>
</svg>
);
}
);
MicrosoftLogo.displayName = 'MicrosoftLogo';

File diff suppressed because one or more lines are too long

View File

@ -1,9 +1,8 @@
import React from 'react';
function TencentLogo(
const TencentLogo = (
props: JSX.IntrinsicAttributes & React.SVGProps<SVGSVGElement>
): React.ReactNode {
return (
): JSX.Element => (
<svg
height='75'
id='tencent-logo'
@ -41,8 +40,7 @@ function TencentLogo(
</g>
</g>
</svg>
);
}
);
TencentLogo.displayName = 'TencentLogo';
export default TencentLogo;