react-native-ios-widget 0.0.12-beta.1 → 0.0.12

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 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACxC,OAAO,UAAU,MAAM,cAAc,CAAC;AAEtC,MAAM,cAAc,GAAG,CAAC,GAAG,EAAE;IAC3B,IAAI,QAAQ,CAAC,EAAE,KAAK,KAAK,EAAE;QACzB,OAAO,QAAQ,CAAC,QAAQ,CAAC,OAAO,EAAE,EAAE,CAAC,IAAI,EAAE,CAAC;KAC7C;IAED,OAAO,KAAK,CAAC;AACf,CAAC,CAAC,EAAE,CAAC;AAEL,MAAM,CAAC,MAAM,kBAAkB,GAAG,KAAK,IAAI,EAAE;IAC3C,IAAI,CAAC,cAAc,IAAI,CAAC,UAAU,EAAE;QAClC,OAAO;KACR;IAED,MAAM,UAAU,CAAC,kBAAkB,EAAE,CAAC;AACxC,CAAC,CAAC","sourcesContent":["import { Platform } from \"react-native\";\nimport ExpoWidget from \"./ExpoModule\";\n\nconst supportWidgets = (() => {\n if (Platform.OS === \"ios\") {\n return parseInt(Platform.Version, 10) >= 14;\n }\n\n return false;\n})();\n\nexport const reloadAllTimelines = async () => {\n if (!supportWidgets || !ExpoWidget) {\n return;\n }\n\n await ExpoWidget.reloadAllTimelines();\n};\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACxC,OAAO,UAAU,MAAM,cAAc,CAAC;AAEtC,MAAM,cAAc,GAAG,CAAC,GAAG,EAAE;IAC3B,IAAI,QAAQ,CAAC,EAAE,KAAK,KAAK,EAAE,CAAC;QAC1B,OAAO,QAAQ,CAAC,QAAQ,CAAC,OAAO,EAAE,EAAE,CAAC,IAAI,EAAE,CAAC;IAC9C,CAAC;IAED,OAAO,KAAK,CAAC;AACf,CAAC,CAAC,EAAE,CAAC;AAEL,MAAM,CAAC,MAAM,kBAAkB,GAAG,KAAK,IAAI,EAAE;IAC3C,IAAI,CAAC,cAAc,IAAI,CAAC,UAAU,EAAE,CAAC;QACnC,OAAO;IACT,CAAC;IAED,MAAM,UAAU,CAAC,kBAAkB,EAAE,CAAC;AACxC,CAAC,CAAC","sourcesContent":["import { Platform } from \"react-native\";\nimport ExpoWidget from \"./ExpoModule\";\n\nconst supportWidgets = (() => {\n if (Platform.OS === \"ios\") {\n return parseInt(Platform.Version, 10) >= 14;\n }\n\n return false;\n})();\n\nexport const reloadAllTimelines = async () => {\n if (!supportWidgets || !ExpoWidget) {\n return;\n }\n\n await ExpoWidget.reloadAllTimelines();\n};\n"]}
@@ -0,0 +1 @@
1
+ {"root":["../src/expomodule.ts","../src/index.ts"],"version":"5.9.3"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-ios-widget",
3
- "version": "0.0.12-beta.1",
3
+ "version": "0.0.12",
4
4
  "description": "Expo config plugin to add widgets to a React Native app",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -22,7 +22,7 @@
22
22
  "license": "MIT",
23
23
  "homepage": "https://github.com/adrianso/react-native-ios-widget",
24
24
  "dependencies": {
25
- "@expo/config-plugins": "~10.1.2"
25
+ "@expo/config-plugins": "~54.0.4"
26
26
  },
27
27
  "devDependencies": {
28
28
  "@types/jest": "^29.5.2",
@@ -35,7 +35,7 @@
35
35
  "jest": "^29.6.1",
36
36
  "react": "18.2.0",
37
37
  "react-native": "0.72.3",
38
- "typescript": "5.1.3"
38
+ "typescript": "5.9.3"
39
39
  },
40
40
  "peerDependencies": {
41
41
  "expo": "*",
@@ -1,5 +1,5 @@
1
1
  import { ExportedConfig, InfoPlist } from "expo/config-plugins";
2
2
  export declare const getWidgetExtensionEntitlements: (iosConfig: ExportedConfig["ios"], { groupIdentifier, }: {
3
- groupIdentifier?: string | undefined;
3
+ groupIdentifier?: string;
4
4
  }) => InfoPlist;
5
5
  export declare const addApplicationGroupsEntitlement: (entitlements: InfoPlist, groupIdentifier?: string) => InfoPlist;
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
15
15
  }) : function(o, v) {
16
16
  o["default"] = v;
17
17
  });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
25
35
  Object.defineProperty(exports, "__esModule", { value: true });
26
36
  exports.getWidgetFiles = void 0;
27
37
  const fs = __importStar(require("fs"));
@@ -0,0 +1 @@
1
+ {"root":["../src/index.ts","../src/types.ts","../src/withconfig.ts","../src/withpodfile.ts","../src/withwidgetextensionentitlements.ts","../src/withxcode.ts","../src/lib/getwidgetextensionentitlements.ts","../src/lib/getwidgetfiles.ts","../src/xcode/addbuildphases.ts","../src/xcode/addpbxgroup.ts","../src/xcode/addproductfile.ts","../src/xcode/addtargetdependency.ts","../src/xcode/addtopbxnativetargetsection.ts","../src/xcode/addtopbxprojectsection.ts","../src/xcode/addxcconfigurationlist.ts"],"version":"5.9.3"}
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
15
15
  }) : function(o, v) {
16
16
  o["default"] = v;
17
17
  });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
25
35
  Object.defineProperty(exports, "__esModule", { value: true });
26
36
  exports.withPodfile = void 0;
27
37
  const generateCode_1 = require("@expo/config-plugins/build/utils/generateCode");
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
15
15
  }) : function(o, v) {
16
16
  o["default"] = v;
17
17
  });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
25
35
  var __importDefault = (this && this.__importDefault) || function (mod) {
26
36
  return (mod && mod.__esModule) ? mod : { "default": mod };
27
37
  };
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
15
15
  }) : function(o, v) {
16
16
  o["default"] = v;
17
17
  });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
25
35
  Object.defineProperty(exports, "__esModule", { value: true });
26
36
  exports.withXcode = void 0;
27
37
  const config_plugins_1 = require("expo/config-plugins");
@@ -15,15 +15,25 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
15
15
  }) : function(o, v) {
16
16
  o["default"] = v;
17
17
  });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
25
35
  Object.defineProperty(exports, "__esModule", { value: true });
26
- exports.addBuildPhases = void 0;
36
+ exports.addBuildPhases = addBuildPhases;
27
37
  const util = __importStar(require("util"));
28
38
  function addBuildPhases(xcodeProject, { targetUuid, groupName, productFile, widgetFiles, }) {
29
39
  const buildPath = `""`;
@@ -45,4 +55,3 @@ function addBuildPhases(xcodeProject, { targetUuid, groupName, productFile, widg
45
55
  // Resources build phase
46
56
  xcodeProject.addBuildPhase([...assetDirectories, ...fontFiles], "PBXResourcesBuildPhase", groupName, targetUuid, folderType, buildPath);
47
57
  }
48
- exports.addBuildPhases = addBuildPhases;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addPbxGroup = void 0;
3
+ exports.addPbxGroup = addPbxGroup;
4
4
  function addPbxGroup(xcodeProject, { targetName, widgetFiles, }) {
5
5
  const { swiftFiles, assetDirectories, entitlementFiles, plistFiles, fontFiles, } = widgetFiles;
6
6
  // Add PBX group
@@ -22,4 +22,3 @@ function addPbxGroup(xcodeProject, { targetName, widgetFiles, }) {
22
22
  });
23
23
  }
24
24
  }
25
- exports.addPbxGroup = addPbxGroup;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addProductFile = void 0;
3
+ exports.addProductFile = addProductFile;
4
4
  function addProductFile(xcodeProject, { targetName, groupName }) {
5
5
  const options = {
6
6
  basename: `${targetName}.appex`,
@@ -19,4 +19,3 @@ function addProductFile(xcodeProject, { targetName, groupName }) {
19
19
  const productFile = xcodeProject.addProductFile(targetName, options);
20
20
  return productFile;
21
21
  }
22
- exports.addProductFile = addProductFile;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addTargetDependency = void 0;
3
+ exports.addTargetDependency = addTargetDependency;
4
4
  function addTargetDependency(xcodeProject, target) {
5
5
  if (!xcodeProject.hash.project.objects["PBXTargetDependency"]) {
6
6
  xcodeProject.hash.project.objects["PBXTargetDependency"] = {};
@@ -12,4 +12,3 @@ function addTargetDependency(xcodeProject, target) {
12
12
  target.uuid,
13
13
  ]);
14
14
  }
15
- exports.addTargetDependency = addTargetDependency;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addToPbxNativeTargetSection = void 0;
3
+ exports.addToPbxNativeTargetSection = addToPbxNativeTargetSection;
4
4
  function addToPbxNativeTargetSection(xcodeProject, { targetName, targetUuid, productFile, xCConfigurationList, }) {
5
5
  const target = {
6
6
  uuid: targetUuid,
@@ -27,4 +27,3 @@ function addToPbxNativeTargetSection(xcodeProject, { targetName, targetUuid, pro
27
27
  ); */
28
28
  return target;
29
29
  }
30
- exports.addToPbxNativeTargetSection = addToPbxNativeTargetSection;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addToPbxProjectSection = void 0;
3
+ exports.addToPbxProjectSection = addToPbxProjectSection;
4
4
  function addToPbxProjectSection(xcodeProject, target) {
5
5
  xcodeProject.addToPbxProjectSection(target);
6
6
  // Add target attributes to project section
@@ -12,4 +12,3 @@ function addToPbxProjectSection(xcodeProject, target) {
12
12
  LastSwiftMigration: 1250,
13
13
  };
14
14
  }
15
- exports.addToPbxProjectSection = addToPbxProjectSection;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.addXCConfigurationList = void 0;
3
+ exports.addXCConfigurationList = addXCConfigurationList;
4
4
  function addXCConfigurationList(xcodeProject, { targetName, currentProjectVersion, bundleIdentifier, deploymentTarget, marketingVersion, }) {
5
5
  const commonBuildSettings = {
6
6
  /* ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
@@ -59,4 +59,3 @@ function addXCConfigurationList(xcodeProject, { targetName, currentProjectVersio
59
59
  const xCConfigurationList = xcodeProject.addXCConfigurationList(buildConfigurationsList, "Release", `Build configuration list for PBXNativeTarget "${targetName}"`);
60
60
  return xCConfigurationList;
61
61
  }
62
- exports.addXCConfigurationList = addXCConfigurationList;