@types/react 18.3.17 → 18.3.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
react v18.3/README.md CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for react (https://react.dev/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react/v18.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Mon, 16 Dec 2024 12:44:17 GMT
11
+ * Last updated: Fri, 20 Dec 2024 01:29:27 GMT
12
12
  * Dependencies: [@types/prop-types](https://npmjs.com/package/@types/prop-types), [csstype](https://npmjs.com/package/csstype)
13
13
 
14
14
  # Credits
react v18.3/index.d.ts CHANGED
@@ -382,37 +382,44 @@ declare namespace React {
382
382
  // Factories
383
383
  // ----------------------------------------------------------------------
384
384
 
385
+ /** @deprecated */
385
386
  type Factory<P> = (props?: Attributes & P, ...children: ReactNode[]) => ReactElement<P>;
386
387
 
387
- /**
388
- * @deprecated Please use `FunctionComponentFactory`
389
- */
388
+ /** @deprecated */
390
389
  type SFCFactory<P> = FunctionComponentFactory<P>;
391
390
 
391
+ /** @deprecated */
392
392
  type FunctionComponentFactory<P> = (
393
393
  props?: Attributes & P,
394
394
  ...children: ReactNode[]
395
395
  ) => FunctionComponentElement<P>;
396
396
 
397
+ /** @deprecated */
397
398
  type ComponentFactory<P, T extends Component<P, ComponentState>> = (
398
399
  props?: ClassAttributes<T> & P,
399
400
  ...children: ReactNode[]
400
401
  ) => CElement<P, T>;
401
402
 
403
+ /** @deprecated */
402
404
  type CFactory<P, T extends Component<P, ComponentState>> = ComponentFactory<P, T>;
405
+ /** @deprecated */
403
406
  type ClassicFactory<P> = CFactory<P, ClassicComponent<P, ComponentState>>;
404
407
 
408
+ /** @deprecated */
405
409
  type DOMFactory<P extends DOMAttributes<T>, T extends Element> = (
406
410
  props?: ClassAttributes<T> & P | null,
407
411
  ...children: ReactNode[]
408
412
  ) => DOMElement<P, T>;
409
413
 
414
+ /** @deprecated */
410
415
  interface HTMLFactory<T extends HTMLElement> extends DetailedHTMLFactory<AllHTMLAttributes<T>, T> {}
411
416
 
417
+ /** @deprecated */
412
418
  interface DetailedHTMLFactory<P extends HTMLAttributes<T>, T extends HTMLElement> extends DOMFactory<P, T> {
413
419
  (props?: ClassAttributes<T> & P | null, ...children: ReactNode[]): DetailedReactHTMLElement<P, T>;
414
420
  }
415
421
 
422
+ /** @deprecated */
416
423
  interface SVGFactory extends DOMFactory<SVGAttributes<SVGElement>, SVGElement> {
417
424
  (
418
425
  props?: ClassAttributes<SVGElement> & SVGAttributes<SVGElement> | null,
@@ -3951,6 +3958,7 @@ declare namespace React {
3951
3958
  // React.DOM
3952
3959
  // ----------------------------------------------------------------------
3953
3960
 
3961
+ /* deprecated */
3954
3962
  interface ReactHTML {
3955
3963
  a: DetailedHTMLFactory<AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>;
3956
3964
  abbr: DetailedHTMLFactory<HTMLAttributes<HTMLElement>, HTMLElement>;
@@ -4072,6 +4080,7 @@ declare namespace React {
4072
4080
  webview: DetailedHTMLFactory<WebViewHTMLAttributes<HTMLWebViewElement>, HTMLWebViewElement>;
4073
4081
  }
4074
4082
 
4083
+ /* deprecated */
4075
4084
  interface ReactSVG {
4076
4085
  animate: SVGFactory;
4077
4086
  circle: SVGFactory;
@@ -4130,6 +4139,7 @@ declare namespace React {
4130
4139
  view: SVGFactory;
4131
4140
  }
4132
4141
 
4142
+ /* deprecated */
4133
4143
  interface ReactDOM extends ReactHTML, ReactSVG {}
4134
4144
 
4135
4145
  //
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/react",
3
- "version": "18.3.17",
3
+ "version": "18.3.18",
4
4
  "description": "TypeScript definitions for react",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react",
6
6
  "license": "MIT",
@@ -201,6 +201,6 @@
201
201
  "csstype": "^3.0.2"
202
202
  },
203
203
  "peerDependencies": {},
204
- "typesPublisherContentHash": "f8c1650d1099e4f098246067ac4105b0fa376c5cb8197c08daab74d4dc2defbd",
204
+ "typesPublisherContentHash": "81d02733b891f7777cc155d7075ba09f503c623f0782022d40d2c0d7f36a2185",
205
205
  "typeScriptVersion": "5.0"
206
206
  }
@@ -382,37 +382,44 @@ declare namespace React {
382
382
  // Factories
383
383
  // ----------------------------------------------------------------------
384
384
 
385
+ /** @deprecated */
385
386
  type Factory<P> = (props?: Attributes & P, ...children: ReactNode[]) => ReactElement<P>;
386
387
 
387
- /**
388
- * @deprecated Please use `FunctionComponentFactory`
389
- */
388
+ /** @deprecated */
390
389
  type SFCFactory<P> = FunctionComponentFactory<P>;
391
390
 
391
+ /** @deprecated */
392
392
  type FunctionComponentFactory<P> = (
393
393
  props?: Attributes & P,
394
394
  ...children: ReactNode[]
395
395
  ) => FunctionComponentElement<P>;
396
396
 
397
+ /** @deprecated */
397
398
  type ComponentFactory<P, T extends Component<P, ComponentState>> = (
398
399
  props?: ClassAttributes<T> & P,
399
400
  ...children: ReactNode[]
400
401
  ) => CElement<P, T>;
401
402
 
403
+ /** @deprecated */
402
404
  type CFactory<P, T extends Component<P, ComponentState>> = ComponentFactory<P, T>;
405
+ /** @deprecated */
403
406
  type ClassicFactory<P> = CFactory<P, ClassicComponent<P, ComponentState>>;
404
407
 
408
+ /** @deprecated */
405
409
  type DOMFactory<P extends DOMAttributes<T>, T extends Element> = (
406
410
  props?: ClassAttributes<T> & P | null,
407
411
  ...children: ReactNode[]
408
412
  ) => DOMElement<P, T>;
409
413
 
414
+ /** @deprecated */
410
415
  interface HTMLFactory<T extends HTMLElement> extends DetailedHTMLFactory<AllHTMLAttributes<T>, T> {}
411
416
 
417
+ /** @deprecated */
412
418
  interface DetailedHTMLFactory<P extends HTMLAttributes<T>, T extends HTMLElement> extends DOMFactory<P, T> {
413
419
  (props?: ClassAttributes<T> & P | null, ...children: ReactNode[]): DetailedReactHTMLElement<P, T>;
414
420
  }
415
421
 
422
+ /** @deprecated */
416
423
  interface SVGFactory extends DOMFactory<SVGAttributes<SVGElement>, SVGElement> {
417
424
  (
418
425
  props?: ClassAttributes<SVGElement> & SVGAttributes<SVGElement> | null,
@@ -3952,6 +3959,7 @@ declare namespace React {
3952
3959
  // React.DOM
3953
3960
  // ----------------------------------------------------------------------
3954
3961
 
3962
+ /* deprecated */
3955
3963
  interface ReactHTML {
3956
3964
  a: DetailedHTMLFactory<AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>;
3957
3965
  abbr: DetailedHTMLFactory<HTMLAttributes<HTMLElement>, HTMLElement>;
@@ -4073,6 +4081,7 @@ declare namespace React {
4073
4081
  webview: DetailedHTMLFactory<WebViewHTMLAttributes<HTMLWebViewElement>, HTMLWebViewElement>;
4074
4082
  }
4075
4083
 
4084
+ /* deprecated */
4076
4085
  interface ReactSVG {
4077
4086
  animate: SVGFactory;
4078
4087
  circle: SVGFactory;
@@ -4131,6 +4140,7 @@ declare namespace React {
4131
4140
  view: SVGFactory;
4132
4141
  }
4133
4142
 
4143
+ /* deprecated */
4134
4144
  interface ReactDOM extends ReactHTML, ReactSVG {}
4135
4145
 
4136
4146
  //