@ama-sdk/client-angular 12.5.0-prerelease.8 → 13.0.0-next.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ama-sdk/client-angular",
3
- "version": "12.5.0-prerelease.8",
3
+ "version": "13.0.0-next.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -38,19 +38,21 @@
38
38
  "build:builders": "tsc -b tsconfig.builders.json --pretty && yarn generate-cjs-manifest"
39
39
  },
40
40
  "dependencies": {
41
- "@o3r/schematics": "^12.5.0-prerelease.8",
41
+ "@o3r/schematics": "^13.0.0-next.0",
42
42
  "@swc/helpers": "~0.5.0",
43
43
  "tslib": "^2.6.2",
44
+ "type-fest": "^4.30.1",
44
45
  "uuid": "^11.0.5"
45
46
  },
46
47
  "peerDependencies": {
47
- "@ama-sdk/core": "^12.5.0-prerelease.8",
48
+ "@ama-sdk/core": "^13.0.0-next.0",
48
49
  "@angular-devkit/schematics": "^19.0.0",
49
50
  "@angular/cli": "^19.0.0",
50
51
  "@angular/common": "^19.0.0",
51
- "@o3r/schematics": "^12.5.0-prerelease.8",
52
+ "@o3r/schematics": "^13.0.0-next.0",
52
53
  "@schematics/angular": "^19.0.0",
53
54
  "rxjs": "^7.8.1",
55
+ "type-fest": "^4.30.1",
54
56
  "typescript": "^5.5.4"
55
57
  },
56
58
  "peerDependenciesMeta": {
@@ -69,12 +71,15 @@
69
71
  "@schematics/angular": {
70
72
  "optional": true
71
73
  },
74
+ "type-fest": {
75
+ "optional": true
76
+ },
72
77
  "typescript": {
73
78
  "optional": true
74
79
  }
75
80
  },
76
81
  "devDependencies": {
77
- "@ama-sdk/core": "^12.5.0-prerelease.8",
82
+ "@ama-sdk/core": "^13.0.0-next.0",
78
83
  "@angular-devkit/core": "~19.2.0",
79
84
  "@angular-devkit/schematics": "~19.2.0",
80
85
  "@angular/common": "~19.2.0",
@@ -82,9 +87,9 @@
82
87
  "@eslint-community/eslint-plugin-eslint-comments": "^4.4.0",
83
88
  "@nx/eslint-plugin": "~20.8.0",
84
89
  "@nx/jest": "~20.8.0",
85
- "@o3r/build-helpers": "^12.5.0-prerelease.8",
86
- "@o3r/eslint-plugin": "^12.5.0-prerelease.8",
87
- "@o3r/test-helpers": "^12.5.0-prerelease.8",
90
+ "@o3r/build-helpers": "^13.0.0-next.0",
91
+ "@o3r/eslint-plugin": "^13.0.0-next.0",
92
+ "@o3r/test-helpers": "^13.0.0-next.0",
88
93
  "@schematics/angular": "~19.2.0",
89
94
  "@stylistic/eslint-plugin": "~3.1.0",
90
95
  "@stylistic/eslint-plugin-ts": "~3.1.0",
@@ -101,7 +106,7 @@
101
106
  "eslint-import-resolver-typescript": "~3.10.0",
102
107
  "eslint-plugin-import": "~2.31.0",
103
108
  "eslint-plugin-import-newlines": "~1.4.0",
104
- "eslint-plugin-jest": "~28.13.0",
109
+ "eslint-plugin-jest": "~28.14.0",
105
110
  "eslint-plugin-jsdoc": "~50.8.0",
106
111
  "eslint-plugin-prefer-arrow": "~1.2.3",
107
112
  "eslint-plugin-unicorn": "~56.0.0",
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":"AACA,OAAO,EAGL,IAAI,EACL,MAAM,4BAA4B,CAAC;AAkBpC,OAAO,KAAK,EACV,qBAAqB,EACtB,MAAM,UAAU,CAAC;AAmDlB;;;GAGG;AACH,eAAO,MAAM,KAAK,GAAI,SAAS,qBAAqB,SAA2C,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":"AACA,OAAO,EAGL,IAAI,EACL,MAAM,4BAA4B,CAAC;AAkBpC,OAAO,KAAK,EACV,qBAAqB,EACtB,MAAM,UAAU,CAAC;AAiElB;;;GAGG;AACH,eAAO,MAAM,KAAK,GAAI,SAAS,qBAAqB,SAA2C,CAAC"}
@@ -4,8 +4,16 @@ exports.ngAdd = void 0;
4
4
  const path = require("node:path");
5
5
  const schematics_1 = require("@angular-devkit/schematics");
6
6
  const schematics_2 = require("@o3r/schematics");
7
- const dependencies_1 = require("@schematics/angular/utility/dependencies");
8
7
  const import_map_1 = require("./migration/import-map");
8
+ /**
9
+ * List of external dependencies to be added to the project as peer dependencies
10
+ */
11
+ const dependenciesToInstall = [
12
+ 'rxjs'
13
+ ];
14
+ /**
15
+ * List of external dependencies to be added to the project as dev dependencies
16
+ */
9
17
  const devDependenciesToInstall = [];
10
18
  /**
11
19
  * Add SDk Angular Client to an Otter Project
@@ -26,22 +34,25 @@ function ngAddFn(options) {
26
34
  };
27
35
  return acc;
28
36
  }, (0, schematics_2.getPackageInstallConfig)(packageJsonPath, tree, options.projectName, false, !!options.exactO3rVersion));
29
- Object.entries((0, schematics_2.getExternalDependenciesVersionRange)(devDependenciesToInstall, packageJsonPath, context.logger))
30
- .forEach(([dep, range]) => {
31
- dependencies[dep] = {
32
- inManifest: [{
33
- range,
34
- types: [dependencies_1.NodeDependencyType.Dev]
35
- }]
36
- };
37
- });
37
+ const projectDirectory = workspaceProject?.root || '.';
38
+ const projectPackageJson = tree.readJson(path.posix.join(projectDirectory, 'package.json'));
39
+ const externalDependenciesInfo = (0, schematics_2.getExternalDependenciesInfo)({
40
+ devDependenciesToInstall,
41
+ dependenciesToInstall,
42
+ projectType: workspaceProject?.projectType,
43
+ o3rPackageJsonPath: packageJsonPath,
44
+ projectPackageJson
45
+ }, context.logger);
38
46
  return (0, schematics_1.chain)([
39
47
  // optional custom action dedicated to this module
40
48
  options.skipLinter ? (0, schematics_1.noop)() : (0, schematics_2.applyEsLintFix)(),
41
49
  // add the missing Otter modules in the current project
42
50
  (0, schematics_2.setupDependencies)({
43
51
  projectName: options.projectName,
44
- dependencies,
52
+ dependencies: {
53
+ ...dependencies,
54
+ ...externalDependenciesInfo
55
+ },
45
56
  ngAddToRun: depsInfo.o3rPeerDeps
46
57
  }),
47
58
  (0, schematics_2.updateImports)(import_map_1.mapMigrationFromCoreImports)
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../schematics/ng-add/index.ts"],"names":[],"mappings":";;;AAAA,kCAAkC;AAClC,2DAIoC;AACpC,gDAUyB;AAIzB,uDAEgC;AAKhC;;GAEG;AACH,MAAM,qBAAqB,GAAG;IAC5B,MAAM;CACP,CAAC;AAEF;;GAEG;AACH,MAAM,wBAAwB,GAAa,EAC1C,CAAC;AAEF;;;GAGG;AACH,SAAS,OAAO,CAAC,OAA8B;IAC7C,OAAO,CAAC,IAAI,EAAE,OAAO,EAAE,EAAE;QACvB,MAAM,gBAAgB,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,IAAA,+BAAkB,EAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;QACnH,MAAM,eAAe,GAAG,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,cAAc,CAAC,CAAC;QAC5E,MAAM,QAAQ,GAAG,IAAA,2BAAc,EAAC,eAAe,CAAC,CAAC;QAEjD,MAAM,YAAY,GAAG,QAAQ,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;YAC5D,GAAG,CAAC,GAAG,CAAC,GAAG;gBACT,UAAU,EAAE,CAAC;wBACX,KAAK,EAAE,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,GAAG,QAAQ,CAAC,cAAc,EAAE;wBACxE,KAAK,EAAE,IAAA,2CAA8B,EAAC,gBAAgB,CAAC;qBACxD,CAAC;gBACF,YAAY,EAAE,EAAE,eAAe,EAAE,OAAO,CAAC,eAAe,EAAE;aAC3D,CAAC;YACF,OAAO,GAAG,CAAC;QACb,CAAC,EAA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B,UAAU,EAAE,yBAAyB;CACtC,CAAC;AAEW,QAAA,2BAA2B,GAAG;IACzC,eAAe,EAAE;QACf,6BAA6B;QAC7B,iCAAiC;QACjC,kBAAkB;QAClB,sBAAsB;QACtB,gCAAgC;KACjC,CAAC,MAAM,CAAC,CAAC,GAAG,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC,EAAE,cAAc,EAAE,CAAC,EAAE,EAA2C,CAAC;CAC3G,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../schematics/ng-add/schema.ts"],"names":[],"mappings":""}