@types/react 16.14.32 → 16.14.34

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 v16.14/README.md CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for React (http://facebook.github.io/reac
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react/v16.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Tue, 13 Sep 2022 18:33:02 GMT
11
+ * Last updated: Thu, 27 Oct 2022 11:32:50 GMT
12
12
  * Dependencies: [@types/csstype](https://npmjs.com/package/@types/csstype), [@types/prop-types](https://npmjs.com/package/@types/prop-types), [@types/scheduler](https://npmjs.com/package/@types/scheduler)
13
13
  * Global values: `React`
14
14
 
react v16.14/index.d.ts CHANGED
@@ -1198,6 +1198,8 @@ declare namespace React {
1198
1198
  target: EventTarget & T;
1199
1199
  }
1200
1200
 
1201
+ export type ModifierKey = "Alt" | "AltGraph" | "CapsLock" | "Control" | "Fn" | "FnLock" | "Hyper" | "Meta" | "NumLock" | "ScrollLock" | "Shift" | "Super" | "Symbol" | "SymbolLock";
1202
+
1201
1203
  interface KeyboardEvent<T = Element> extends UIEvent<T, NativeKeyboardEvent> {
1202
1204
  altKey: boolean;
1203
1205
  /** @deprecated */
@@ -1206,7 +1208,7 @@ declare namespace React {
1206
1208
  /**
1207
1209
  * See [DOM Level 3 Events spec](https://www.w3.org/TR/uievents-key/#keys-modifier). for a list of valid (case-sensitive) arguments to this method.
1208
1210
  */
1209
- getModifierState(key: string): boolean;
1211
+ getModifierState(key: ModifierKey): boolean;
1210
1212
  /**
1211
1213
  * See the [DOM Level 3 Events spec](https://www.w3.org/TR/uievents-key/#named-key-attribute-values). for possible values
1212
1214
  */
@@ -1232,7 +1234,7 @@ declare namespace React {
1232
1234
  /**
1233
1235
  * See [DOM Level 3 Events spec](https://www.w3.org/TR/uievents-key/#keys-modifier). for a list of valid (case-sensitive) arguments to this method.
1234
1236
  */
1235
- getModifierState(key: string): boolean;
1237
+ getModifierState(key: ModifierKey): boolean;
1236
1238
  metaKey: boolean;
1237
1239
  movementX: number;
1238
1240
  movementY: number;
@@ -1251,7 +1253,7 @@ declare namespace React {
1251
1253
  /**
1252
1254
  * See [DOM Level 3 Events spec](https://www.w3.org/TR/uievents-key/#keys-modifier). for a list of valid (case-sensitive) arguments to this method.
1253
1255
  */
1254
- getModifierState(key: string): boolean;
1256
+ getModifierState(key: ModifierKey): boolean;
1255
1257
  metaKey: boolean;
1256
1258
  shiftKey: boolean;
1257
1259
  targetTouches: TouchList;
@@ -1825,6 +1827,7 @@ declare namespace React {
1825
1827
  hidden?: boolean | undefined;
1826
1828
  id?: string | undefined;
1827
1829
  lang?: string | undefined;
1830
+ nonce?: string | undefined;
1828
1831
  placeholder?: string | undefined;
1829
1832
  slot?: string | undefined;
1830
1833
  spellCheck?: Booleanish | undefined;
@@ -1945,7 +1948,6 @@ declare namespace React {
1945
1948
  multiple?: boolean | undefined;
1946
1949
  muted?: boolean | undefined;
1947
1950
  name?: string | undefined;
1948
- nonce?: string | undefined;
1949
1951
  noValidate?: boolean | undefined;
1950
1952
  open?: boolean | undefined;
1951
1953
  optimum?: number | undefined;
@@ -2357,7 +2359,6 @@ declare namespace React {
2357
2359
  defer?: boolean | undefined;
2358
2360
  integrity?: string | undefined;
2359
2361
  noModule?: boolean | undefined;
2360
- nonce?: string | undefined;
2361
2362
  referrerPolicy?: HTMLAttributeReferrerPolicy | undefined;
2362
2363
  src?: string | undefined;
2363
2364
  type?: string | undefined;
@@ -2388,7 +2389,6 @@ declare namespace React {
2388
2389
 
2389
2390
  interface StyleHTMLAttributes<T> extends HTMLAttributes<T> {
2390
2391
  media?: string | undefined;
2391
- nonce?: string | undefined;
2392
2392
  scoped?: boolean | undefined;
2393
2393
  type?: string | undefined;
2394
2394
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/react",
3
- "version": "16.14.32",
3
+ "version": "16.14.34",
4
4
  "description": "TypeScript definitions for React",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react",
6
6
  "license": "MIT",
@@ -146,7 +146,7 @@
146
146
  "@types/scheduler": "*",
147
147
  "csstype": "^3.0.2"
148
148
  },
149
- "typesPublisherContentHash": "a243f681112601061c05a031e79732a325df434f79ce12914089159ec26fe29d",
149
+ "typesPublisherContentHash": "9b4107e39b4ec9cba67f9bcf81165374820b003b786d2153be080b774a627ac0",
150
150
  "typeScriptVersion": "4.1",
151
151
  "exports": {
152
152
  ".": {