mirror of
https://github.com/facebook/docusaurus.git
synced 2025-06-03 19:32:35 +02:00
refactor: prepare types for React 19 (#10746)
This commit is contained in:
parent
e9f0641620
commit
f9825af43e
296 changed files with 1105 additions and 915 deletions
|
@ -7,7 +7,7 @@
|
|||
|
||||
/* eslint-disable global-require */
|
||||
|
||||
import React, {type ComponentProps} from 'react';
|
||||
import React, {type ComponentProps, type ReactNode} from 'react';
|
||||
import {
|
||||
CarouselProvider,
|
||||
Slider,
|
||||
|
@ -48,7 +48,7 @@ export default function ShowcaseCarousel({
|
|||
}: {
|
||||
sites: Site[];
|
||||
aspectRatio: number;
|
||||
}): JSX.Element {
|
||||
}): ReactNode {
|
||||
return (
|
||||
<CarouselProvider
|
||||
naturalSlideWidth={1}
|
||||
|
@ -72,7 +72,7 @@ export default function ShowcaseCarousel({
|
|||
);
|
||||
}
|
||||
|
||||
export function ShowcaseCarouselV1(): JSX.Element {
|
||||
export function ShowcaseCarouselV1(): ReactNode {
|
||||
return (
|
||||
<ShowcaseCarousel
|
||||
aspectRatio={1072 / 584}
|
||||
|
@ -107,7 +107,7 @@ export function ShowcaseCarouselV1(): JSX.Element {
|
|||
);
|
||||
}
|
||||
|
||||
export function ShowcaseCarouselV2(): JSX.Element {
|
||||
export function ShowcaseCarouselV2(): ReactNode {
|
||||
return (
|
||||
<ShowcaseCarousel
|
||||
aspectRatio={2148 / 1194}
|
||||
|
@ -172,7 +172,7 @@ export function ShowcaseCarouselV2(): JSX.Element {
|
|||
);
|
||||
}
|
||||
|
||||
export function ShowcaseCarouselV2Theming(): JSX.Element {
|
||||
export function ShowcaseCarouselV2Theming(): ReactNode {
|
||||
return (
|
||||
<ShowcaseCarousel
|
||||
aspectRatio={2148 / 1194}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue