@wordpress/keycodes 4.31.1-next.f56bd8138.0 → 4.32.1-next.47f435fc9.0

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.
@@ -1 +1,7 @@
1
- {"version":3,"names":["isAppleOS","_window","window","platform","navigator","indexOf","includes"],"sources":["@wordpress/keycodes/src/platform.ts"],"sourcesContent":["/**\n * Return true if platform is MacOS.\n *\n * @param _window window object by default; used for DI testing.\n *\n * @return True if MacOS; false otherwise.\n */\nexport function isAppleOS( _window?: Window ): boolean {\n\tif ( ! _window ) {\n\t\tif ( typeof window === 'undefined' ) {\n\t\t\treturn false;\n\t\t}\n\n\t\t_window = window;\n\t}\n\n\tconst { platform } = _window.navigator;\n\n\treturn (\n\t\tplatform.indexOf( 'Mac' ) !== -1 ||\n\t\t[ 'iPad', 'iPhone' ].includes( platform )\n\t);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,SAASA,CAAEC,OAAgB,EAAY;EACtD,IAAK,CAAEA,OAAO,EAAG;IAChB,IAAK,OAAOC,MAAM,KAAK,WAAW,EAAG;MACpC,OAAO,KAAK;IACb;IAEAD,OAAO,GAAGC,MAAM;EACjB;EAEA,MAAM;IAAEC;EAAS,CAAC,GAAGF,OAAO,CAACG,SAAS;EAEtC,OACCD,QAAQ,CAACE,OAAO,CAAE,KAAM,CAAC,KAAK,CAAC,CAAC,IAChC,CAAE,MAAM,EAAE,QAAQ,CAAE,CAACC,QAAQ,CAAEH,QAAS,CAAC;AAE3C","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/platform.ts"],
4
+ "sourcesContent": ["/**\n * Return true if platform is MacOS.\n *\n * @param _window window object by default; used for DI testing.\n *\n * @return True if MacOS; false otherwise.\n */\nexport function isAppleOS( _window?: Window ): boolean {\n\tif ( ! _window ) {\n\t\tif ( typeof window === 'undefined' ) {\n\t\t\treturn false;\n\t\t}\n\n\t\t_window = window;\n\t}\n\n\tconst { platform } = _window.navigator;\n\n\treturn (\n\t\tplatform.indexOf( 'Mac' ) !== -1 ||\n\t\t[ 'iPad', 'iPhone' ].includes( platform )\n\t);\n}\n"],
5
+ "mappings": "AAOO,SAAS,UAAW,SAA4B;AACtD,MAAK,CAAE,SAAU;AAChB,QAAK,OAAO,WAAW,aAAc;AACpC,aAAO;AAAA,IACR;AAEA,cAAU;AAAA,EACX;AAEA,QAAM,EAAE,SAAS,IAAI,QAAQ;AAE7B,SACC,SAAS,QAAS,KAAM,MAAM,MAC9B,CAAE,QAAQ,QAAS,EAAE,SAAU,QAAS;AAE1C;",
6
+ "names": []
7
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wordpress/keycodes",
3
- "version": "4.31.1-next.f56bd8138.0",
3
+ "version": "4.32.1-next.47f435fc9.0",
4
4
  "description": "Keycodes utilities for WordPress. Used to check for keyboard events across browsers/operating systems.",
5
5
  "author": "The WordPress Contributors",
6
6
  "license": "GPL-2.0-or-later",
@@ -24,16 +24,23 @@
24
24
  },
25
25
  "main": "build/index.js",
26
26
  "module": "build-module/index.js",
27
+ "exports": {
28
+ ".": {
29
+ "types": "./build-types/index.d.ts",
30
+ "import": "./build-module/index.js",
31
+ "require": "./build/index.js"
32
+ },
33
+ "./package.json": "./package.json"
34
+ },
27
35
  "react-native": "src/index",
28
36
  "wpScript": true,
29
37
  "types": "build-types",
30
38
  "sideEffects": false,
31
39
  "dependencies": {
32
- "@babel/runtime": "7.25.7",
33
- "@wordpress/i18n": "^6.4.1-next.f56bd8138.0"
40
+ "@wordpress/i18n": "^6.5.1-next.47f435fc9.0"
34
41
  },
35
42
  "publishConfig": {
36
43
  "access": "public"
37
44
  },
38
- "gitHead": "ea4a281fd857f48338877590de8c8eb9b9a8cef4"
45
+ "gitHead": "9720f22c138771d2ed1a0522725c3cdf1c242953"
39
46
  }
@@ -1,20 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.isAppleOS = isAppleOS;
7
- var _reactNative = require("react-native");
8
- /**
9
- * External dependencies
10
- */
11
-
12
- /**
13
- * Return true if platform is iOS.
14
- *
15
- * @return {boolean} True if iOS; false otherwise.
16
- */
17
- function isAppleOS() {
18
- return _reactNative.Platform.OS === 'ios';
19
- }
20
- //# sourceMappingURL=platform.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_reactNative","require","isAppleOS","Platform","OS"],"sources":["@wordpress/keycodes/src/platform.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { Platform } from 'react-native';\n\n/**\n * Return true if platform is iOS.\n *\n * @return {boolean} True if iOS; false otherwise.\n */\nexport function isAppleOS() {\n\treturn Platform.OS === 'ios';\n}\n"],"mappings":";;;;;;AAGA,IAAAA,YAAA,GAAAC,OAAA;AAHA;AACA;AACA;;AAGA;AACA;AACA;AACA;AACA;AACO,SAASC,SAASA,CAAA,EAAG;EAC3B,OAAOC,qBAAQ,CAACC,EAAE,KAAK,KAAK;AAC7B","ignoreList":[]}
@@ -1,14 +0,0 @@
1
- /**
2
- * External dependencies
3
- */
4
- import { Platform } from 'react-native';
5
-
6
- /**
7
- * Return true if platform is iOS.
8
- *
9
- * @return {boolean} True if iOS; false otherwise.
10
- */
11
- export function isAppleOS() {
12
- return Platform.OS === 'ios';
13
- }
14
- //# sourceMappingURL=platform.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["Platform","isAppleOS","OS"],"sources":["@wordpress/keycodes/src/platform.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { Platform } from 'react-native';\n\n/**\n * Return true if platform is iOS.\n *\n * @return {boolean} True if iOS; false otherwise.\n */\nexport function isAppleOS() {\n\treturn Platform.OS === 'ios';\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,QAAQ,QAAQ,cAAc;;AAEvC;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,SAASA,CAAA,EAAG;EAC3B,OAAOD,QAAQ,CAACE,EAAE,KAAK,KAAK;AAC7B","ignoreList":[]}