@po-ui/ng-sync 15.15.0 → 16.0.0-next.2

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.
Files changed (127) hide show
  1. package/README.md +3 -3
  2. package/{esm2020 → esm2022}/lib/index.mjs +14 -14
  3. package/{esm2020 → esm2022}/lib/models/index.mjs +5 -5
  4. package/{esm2020 → esm2022}/lib/models/po-data-message.model.mjs +56 -56
  5. package/esm2022/lib/models/po-data-transform.model.mjs +23 -0
  6. package/esm2022/lib/models/po-entity/po-entity.model.mjs +217 -0
  7. package/esm2022/lib/models/po-event-sourcing-error-response.model.mjs +21 -0
  8. package/esm2022/lib/models/po-network-status.model.mjs +45 -0
  9. package/{esm2020 → esm2022}/lib/models/po-network-type.enum.mjs +29 -29
  10. package/esm2022/lib/models/po-query-builder/po-query-builder.model.mjs +246 -0
  11. package/{esm2020 → esm2022}/lib/models/po-request-type.enum.mjs +15 -15
  12. package/{esm2020 → esm2022}/lib/po-sync.module.mjs +40 -40
  13. package/{esm2020 → esm2022}/lib/services/po-event-sourcing/enums/po-event-sourcing-operation.enum.mjs +16 -16
  14. package/{esm2020 → esm2022}/lib/services/po-event-sourcing/index.mjs +3 -3
  15. package/{esm2020 → esm2022}/lib/services/po-event-sourcing/interfaces/po-event-sourcing-item.interface.mjs +1 -1
  16. package/{esm2020 → esm2022}/lib/services/po-event-sourcing/interfaces/po-event-sourcing-summary-item.interface.mjs +1 -1
  17. package/esm2022/lib/services/po-event-sourcing/po-event-sourcing.service.mjs +379 -0
  18. package/{esm2020 → esm2022}/lib/services/po-http-client/interfaces/po-http-header-option.interface.mjs +10 -10
  19. package/{esm2020 → esm2022}/lib/services/po-http-client/interfaces/po-http-request-data.interface.mjs +1 -1
  20. package/{esm2020 → esm2022}/lib/services/po-http-client/interfaces/po-response-api.interface.mjs +1 -1
  21. package/esm2022/lib/services/po-http-client/po-http-client.service.mjs +149 -0
  22. package/{esm2020 → esm2022}/lib/services/po-http-client/po-http-request-type.enum.mjs +24 -24
  23. package/esm2022/lib/services/po-network/po-network.service.mjs +59 -0
  24. package/{esm2020 → esm2022}/lib/services/po-schema/index.mjs +3 -3
  25. package/esm2022/lib/services/po-schema/po-schema-definition/po-schema-definition.service.mjs +78 -0
  26. package/esm2022/lib/services/po-schema/po-schema-util/po-schema-util.model.mjs +124 -0
  27. package/esm2022/lib/services/po-schema/po-schema.service.mjs +176 -0
  28. package/{esm2020 → esm2022}/lib/services/po-sync/interfaces/po-sync-config.interface.mjs +1 -1
  29. package/{esm2020 → esm2022}/lib/services/po-sync/interfaces/po-sync-field-options.interface.mjs +1 -1
  30. package/{esm2020 → esm2022}/lib/services/po-sync/interfaces/po-sync-response.interface.mjs +1 -1
  31. package/{esm2020 → esm2022}/lib/services/po-sync/interfaces/po-sync-schema.interface.mjs +1 -1
  32. package/esm2022/lib/services/po-sync/po-sync.service.mjs +336 -0
  33. package/{esm2020 → esm2022}/lib/utils/utils.mjs +62 -62
  34. package/{esm2020 → esm2022}/po-ui-ng-sync.mjs +4 -4
  35. package/{esm2020 → esm2022}/public-api.mjs +1 -1
  36. package/{fesm2020 → fesm2022}/po-ui-ng-sync.mjs +2004 -1962
  37. package/{fesm2020 → fesm2022}/po-ui-ng-sync.mjs.map +1 -1
  38. package/index.d.ts +5 -5
  39. package/lib/index.d.ts +14 -14
  40. package/lib/models/index.d.ts +5 -5
  41. package/lib/models/po-data-message.model.d.ts +46 -46
  42. package/lib/models/po-data-transform.model.d.ts +52 -52
  43. package/lib/models/po-entity/po-entity.model.d.ts +122 -122
  44. package/lib/models/po-event-sourcing-error-response.model.d.ts +20 -20
  45. package/lib/models/po-network-status.model.d.ts +25 -25
  46. package/lib/models/po-network-type.enum.d.ts +28 -28
  47. package/lib/models/po-query-builder/po-query-builder.model.d.ts +126 -126
  48. package/lib/models/po-request-type.enum.d.ts +14 -14
  49. package/lib/po-sync.module.d.ts +11 -11
  50. package/lib/services/po-event-sourcing/enums/po-event-sourcing-operation.enum.d.ts +11 -11
  51. package/lib/services/po-event-sourcing/index.d.ts +3 -3
  52. package/lib/services/po-event-sourcing/interfaces/po-event-sourcing-item.interface.d.ts +26 -26
  53. package/lib/services/po-event-sourcing/interfaces/po-event-sourcing-summary-item.interface.d.ts +16 -16
  54. package/lib/services/po-event-sourcing/po-event-sourcing.service.d.ts +74 -74
  55. package/lib/services/po-http-client/interfaces/po-http-header-option.interface.d.ts +15 -15
  56. package/lib/services/po-http-client/interfaces/po-http-request-data.interface.d.ts +24 -24
  57. package/lib/services/po-http-client/interfaces/po-response-api.interface.d.ts +14 -14
  58. package/lib/services/po-http-client/po-http-client.service.d.ts +78 -78
  59. package/lib/services/po-http-client/po-http-request-type.enum.d.ts +23 -23
  60. package/lib/services/po-network/po-network.service.d.ts +35 -35
  61. package/lib/services/po-schema/index.d.ts +3 -3
  62. package/lib/services/po-schema/po-schema-definition/po-schema-definition.service.d.ts +51 -51
  63. package/lib/services/po-schema/po-schema-util/po-schema-util.model.d.ts +79 -79
  64. package/lib/services/po-schema/po-schema.service.d.ts +98 -98
  65. package/lib/services/po-sync/interfaces/po-sync-config.interface.d.ts +24 -24
  66. package/lib/services/po-sync/interfaces/po-sync-field-options.interface.d.ts +15 -15
  67. package/lib/services/po-sync/interfaces/po-sync-response.interface.d.ts +20 -20
  68. package/lib/services/po-sync/interfaces/po-sync-schema.interface.d.ts +37 -37
  69. package/lib/services/po-sync/po-sync.service.d.ts +162 -162
  70. package/lib/utils/utils.d.ts +36 -36
  71. package/package.json +10 -16
  72. package/po-ui-ng-sync-16.0.0-next.2.tgz +0 -0
  73. package/public-api.d.ts +1 -1
  74. package/schematics/migrations.json +1 -1
  75. package/schematics/ng-add/index.d.ts +7 -7
  76. package/schematics/ng-add/index.js +31 -31
  77. package/schematics/ng-add/index.spec.d.ts +1 -1
  78. package/schematics/ng-add/index.spec.js +60 -60
  79. package/schematics/ng-generate/schema/index.d.ts +4 -4
  80. package/schematics/ng-generate/schema/index.js +12 -12
  81. package/schematics/ng-generate/schema/index.spec.d.ts +1 -1
  82. package/schematics/ng-generate/schema/index.spec.js +44 -44
  83. package/schematics/ng-generate/schema/schema.d.ts +3 -3
  84. package/schematics/ng-generate/schema/schema.js +2 -2
  85. package/schematics/ng-update/v14/changes.d.ts +2 -2
  86. package/schematics/ng-update/v14/changes.js +13 -13
  87. package/schematics/ng-update/v14/index.d.ts +1 -1
  88. package/schematics/ng-update/v14/index.js +15 -15
  89. package/schematics/ng-update/v15/changes.d.ts +4 -4
  90. package/schematics/ng-update/v15/changes.js +15 -15
  91. package/schematics/ng-update/v15/index.d.ts +1 -1
  92. package/schematics/ng-update/v15/index.js +36 -36
  93. package/schematics/ng-update/v2/changes.d.ts +8 -8
  94. package/schematics/ng-update/v2/changes.js +20 -20
  95. package/schematics/ng-update/v2/index.d.ts +5 -5
  96. package/schematics/ng-update/v2/index.js +101 -101
  97. package/schematics/ng-update/v3/changes.d.ts +2 -2
  98. package/schematics/ng-update/v3/changes.js +14 -14
  99. package/schematics/ng-update/v3/index.d.ts +1 -1
  100. package/schematics/ng-update/v3/index.js +16 -16
  101. package/schematics/ng-update/v4/changes.d.ts +2 -2
  102. package/schematics/ng-update/v4/changes.js +14 -14
  103. package/schematics/ng-update/v4/index.d.ts +1 -1
  104. package/schematics/ng-update/v4/index.js +15 -15
  105. package/schematics/ng-update/v5/changes.d.ts +2 -2
  106. package/schematics/ng-update/v5/changes.js +13 -13
  107. package/schematics/ng-update/v5/index.d.ts +1 -1
  108. package/schematics/ng-update/v5/index.js +15 -15
  109. package/schematics/ng-update/v6/changes.d.ts +2 -2
  110. package/schematics/ng-update/v6/changes.js +13 -13
  111. package/schematics/ng-update/v6/index.d.ts +1 -1
  112. package/schematics/ng-update/v6/index.js +15 -15
  113. package/esm2020/lib/models/po-data-transform.model.mjs +0 -22
  114. package/esm2020/lib/models/po-entity/po-entity.model.mjs +0 -214
  115. package/esm2020/lib/models/po-event-sourcing-error-response.model.mjs +0 -17
  116. package/esm2020/lib/models/po-network-status.model.mjs +0 -44
  117. package/esm2020/lib/models/po-query-builder/po-query-builder.model.mjs +0 -238
  118. package/esm2020/lib/services/po-event-sourcing/po-event-sourcing.service.mjs +0 -372
  119. package/esm2020/lib/services/po-http-client/po-http-client.service.mjs +0 -148
  120. package/esm2020/lib/services/po-network/po-network.service.mjs +0 -56
  121. package/esm2020/lib/services/po-schema/po-schema-definition/po-schema-definition.service.mjs +0 -77
  122. package/esm2020/lib/services/po-schema/po-schema-util/po-schema-util.model.mjs +0 -124
  123. package/esm2020/lib/services/po-schema/po-schema.service.mjs +0 -174
  124. package/esm2020/lib/services/po-sync/po-sync.service.mjs +0 -325
  125. package/fesm2015/po-ui-ng-sync.mjs +0 -2113
  126. package/fesm2015/po-ui-ng-sync.mjs.map +0 -1
  127. package/po-ui-ng-sync-15.15.0.tgz +0 -0
@@ -1,61 +1,61 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const testing_1 = require("@angular-devkit/schematics/testing");
5
- const path = require("path");
6
- const collectionPath = path.join(__dirname, '../collection.json');
7
- xdescribe('Schematic: ng-add', () => {
8
- const runner = new testing_1.SchematicTestRunner('schematics', collectionPath);
9
- const workspaceOptions = {
10
- name: 'workspace',
11
- newProjectRoot: 'projects',
12
- version: '6.0.0'
13
- };
14
- const componentOptions = {
15
- name: 'po'
16
- };
17
- let appTree;
18
- let infoOutput;
19
- beforeEach(() => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
20
- appTree = yield runner.runExternalSchematicAsync('@schematics/angular', 'workspace', workspaceOptions).toPromise();
21
- appTree = yield runner
22
- .runExternalSchematicAsync('@schematics/angular', 'application', componentOptions, appTree)
23
- .toPromise();
24
- infoOutput = [];
25
- runner.logger.subscribe(e => {
26
- if (e.level === 'info') {
27
- infoOutput.push(e.message);
28
- }
29
- });
30
- }));
31
- describe('Dependencies:', () => {
32
- it('should update package.json with @po-ui/ng-sync dependencies and run nodePackageInstall', () => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
33
- const tree = yield runner.runSchematicAsync('ng-add', componentOptions, appTree).toPromise();
34
- const packageJson = JSON.parse(getFileContent(tree, '/package.json'));
35
- const dependencies = packageJson.dependencies;
36
- expect(dependencies['@po-ui/ng-sync']).toBeDefined();
37
- expect(Object.keys(dependencies)).toEqual(Object.keys(dependencies).sort());
38
- expect(runner.tasks.some(task => task.name === 'node-package')).toBe(true);
39
- expect(infoOutput.length).toBe(1);
40
- }));
41
- });
42
- describe('Imports:', () => {
43
- it('should add the PoSyncModule and PoStorageModule to the project module', () => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
44
- const poSyncModuleName = 'PoSyncModule';
45
- const poStorageModuleName = 'PoStorageModule';
46
- const tree = yield runner.runSchematicAsync('ng-add', componentOptions, appTree).toPromise();
47
- const fileContent = getFileContent(tree, `projects/${componentOptions.name}/src/app/app.module.ts`);
48
- expect(fileContent).toContain(poSyncModuleName);
49
- expect(fileContent).toContain(poStorageModuleName);
50
- }));
51
- });
52
- });
53
- /** Gets the content of a specified file from a schematic tree. */
54
- function getFileContent(tree, filePath) {
55
- const contentBuffer = tree.read(filePath);
56
- if (!contentBuffer) {
57
- throw new Error(`Cannot read "${filePath}" because it does not exist.`);
58
- }
59
- return contentBuffer.toString();
60
- }
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const tslib_1 = require("tslib");
4
+ const testing_1 = require("@angular-devkit/schematics/testing");
5
+ const path = require("path");
6
+ const collectionPath = path.join(__dirname, '../collection.json');
7
+ xdescribe('Schematic: ng-add', () => {
8
+ const runner = new testing_1.SchematicTestRunner('schematics', collectionPath);
9
+ const workspaceOptions = {
10
+ name: 'workspace',
11
+ newProjectRoot: 'projects',
12
+ version: '6.0.0'
13
+ };
14
+ const componentOptions = {
15
+ name: 'po'
16
+ };
17
+ let appTree;
18
+ let infoOutput;
19
+ beforeEach(() => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
20
+ appTree = yield runner.runExternalSchematicAsync('@schematics/angular', 'workspace', workspaceOptions).toPromise();
21
+ appTree = yield runner
22
+ .runExternalSchematicAsync('@schematics/angular', 'application', componentOptions, appTree)
23
+ .toPromise();
24
+ infoOutput = [];
25
+ runner.logger.subscribe(e => {
26
+ if (e.level === 'info') {
27
+ infoOutput.push(e.message);
28
+ }
29
+ });
30
+ }));
31
+ describe('Dependencies:', () => {
32
+ it('should update package.json with @po-ui/ng-sync dependencies and run nodePackageInstall', () => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
33
+ const tree = yield runner.runSchematicAsync('ng-add', componentOptions, appTree).toPromise();
34
+ const packageJson = JSON.parse(getFileContent(tree, '/package.json'));
35
+ const dependencies = packageJson.dependencies;
36
+ expect(dependencies['@po-ui/ng-sync']).toBeDefined();
37
+ expect(Object.keys(dependencies)).toEqual(Object.keys(dependencies).sort());
38
+ expect(runner.tasks.some(task => task.name === 'node-package')).toBe(true);
39
+ expect(infoOutput.length).toBe(1);
40
+ }));
41
+ });
42
+ describe('Imports:', () => {
43
+ it('should add the PoSyncModule and PoStorageModule to the project module', () => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
44
+ const poSyncModuleName = 'PoSyncModule';
45
+ const poStorageModuleName = 'PoStorageModule';
46
+ const tree = yield runner.runSchematicAsync('ng-add', componentOptions, appTree).toPromise();
47
+ const fileContent = getFileContent(tree, `projects/${componentOptions.name}/src/app/app.module.ts`);
48
+ expect(fileContent).toContain(poSyncModuleName);
49
+ expect(fileContent).toContain(poStorageModuleName);
50
+ }));
51
+ });
52
+ });
53
+ /** Gets the content of a specified file from a schematic tree. */
54
+ function getFileContent(tree, filePath) {
55
+ const contentBuffer = tree.read(filePath);
56
+ if (!contentBuffer) {
57
+ throw new Error(`Cannot read "${filePath}" because it does not exist.`);
58
+ }
59
+ return contentBuffer.toString();
60
+ }
61
61
  //# sourceMappingURL=index.spec.js.map
@@ -1,4 +1,4 @@
1
- import { Rule } from '@angular-devkit/schematics';
2
- import { Schema as FileOptions } from './schema';
3
- /** Scaffolds a new sync schema file */
4
- export default function (options: FileOptions): Rule;
1
+ import { Rule } from '@angular-devkit/schematics';
2
+ import { Schema as FileOptions } from './schema';
3
+ /** Scaffolds a new sync schema file */
4
+ export default function (options: FileOptions): Rule;
@@ -1,13 +1,13 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const schematics_1 = require("@angular-devkit/schematics");
4
- const build_file_1 = require("@po-ui/ng-schematics/build-file");
5
- /** Scaffolds a new sync schema file */
6
- function default_1(options) {
7
- return (0, schematics_1.chain)([createSyncSchema(options)]);
8
- }
9
- exports.default = default_1;
10
- function createSyncSchema(options) {
11
- return (0, build_file_1.buildFile)(options);
12
- }
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const schematics_1 = require("@angular-devkit/schematics");
4
+ const build_file_1 = require("@po-ui/ng-schematics/build-file");
5
+ /** Scaffolds a new sync schema file */
6
+ function default_1(options) {
7
+ return (0, schematics_1.chain)([createSyncSchema(options)]);
8
+ }
9
+ exports.default = default_1;
10
+ function createSyncSchema(options) {
11
+ return (0, build_file_1.buildFile)(options);
12
+ }
13
13
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1,45 +1,45 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const testing_1 = require("@angular-devkit/schematics/testing");
5
- const path = require("path");
6
- const collectionPath = path.join(__dirname, '../../collection.json');
7
- xdescribe('schema:', () => {
8
- const runner = new testing_1.SchematicTestRunner('schematics', collectionPath);
9
- const workspaceOptions = {
10
- name: 'workspace',
11
- newProjectRoot: 'projects',
12
- version: '6.0.0'
13
- };
14
- const componentOptions = {
15
- name: 'po'
16
- };
17
- let appTree;
18
- beforeEach(() => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
19
- appTree = yield runner.runExternalSchematicAsync('@schematics/angular', 'workspace', workspaceOptions).toPromise();
20
- appTree = yield runner
21
- .runExternalSchematicAsync('@schematics/angular', 'application', componentOptions, appTree)
22
- .toPromise();
23
- }));
24
- it('should create sync schema', () => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
25
- const schemaName = 'supply';
26
- const tree = yield runner
27
- .runSchematicAsync('schema', Object.assign(Object.assign({}, componentOptions), { name: schemaName }), appTree)
28
- .toPromise();
29
- const files = tree.files;
30
- const fullFilePath = `/projects/${componentOptions.name}/src/app/${schemaName}/${schemaName}.constants.ts`;
31
- const schemaContent = getFileContent(tree, `/projects/${componentOptions.name}/src/app/${schemaName}/${schemaName}.constants.ts`);
32
- expect(files).toContain(fullFilePath);
33
- expect(schemaContent).toMatch(new RegExp(`name: '${schemaName}'`));
34
- expect(schemaContent).toMatch(new RegExp(`export const ${schemaName}Schema: PoSyncSchema`));
35
- }));
36
- /** Gets the content of a specified file from a schematic tree. */
37
- function getFileContent(tree, filePath) {
38
- const contentBuffer = tree.read(filePath);
39
- if (!contentBuffer) {
40
- throw new Error(`Cannot read "${filePath}" because it does not exist.`);
41
- }
42
- return contentBuffer.toString();
43
- }
44
- });
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const tslib_1 = require("tslib");
4
+ const testing_1 = require("@angular-devkit/schematics/testing");
5
+ const path = require("path");
6
+ const collectionPath = path.join(__dirname, '../../collection.json');
7
+ xdescribe('schema:', () => {
8
+ const runner = new testing_1.SchematicTestRunner('schematics', collectionPath);
9
+ const workspaceOptions = {
10
+ name: 'workspace',
11
+ newProjectRoot: 'projects',
12
+ version: '6.0.0'
13
+ };
14
+ const componentOptions = {
15
+ name: 'po'
16
+ };
17
+ let appTree;
18
+ beforeEach(() => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
19
+ appTree = yield runner.runExternalSchematicAsync('@schematics/angular', 'workspace', workspaceOptions).toPromise();
20
+ appTree = yield runner
21
+ .runExternalSchematicAsync('@schematics/angular', 'application', componentOptions, appTree)
22
+ .toPromise();
23
+ }));
24
+ it('should create sync schema', () => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
25
+ const schemaName = 'supply';
26
+ const tree = yield runner
27
+ .runSchematicAsync('schema', Object.assign(Object.assign({}, componentOptions), { name: schemaName }), appTree)
28
+ .toPromise();
29
+ const files = tree.files;
30
+ const fullFilePath = `/projects/${componentOptions.name}/src/app/${schemaName}/${schemaName}.constants.ts`;
31
+ const schemaContent = getFileContent(tree, `/projects/${componentOptions.name}/src/app/${schemaName}/${schemaName}.constants.ts`);
32
+ expect(files).toContain(fullFilePath);
33
+ expect(schemaContent).toMatch(new RegExp(`name: '${schemaName}'`));
34
+ expect(schemaContent).toMatch(new RegExp(`export const ${schemaName}Schema: PoSyncSchema`));
35
+ }));
36
+ /** Gets the content of a specified file from a schematic tree. */
37
+ function getFileContent(tree, filePath) {
38
+ const contentBuffer = tree.read(filePath);
39
+ if (!contentBuffer) {
40
+ throw new Error(`Cannot read "${filePath}" because it does not exist.`);
41
+ }
42
+ return contentBuffer.toString();
43
+ }
44
+ });
45
45
  //# sourceMappingURL=index.spec.js.map
@@ -1,3 +1,3 @@
1
- import { Schema as ComponentSchema } from '@po-ui/ng-schematics/build-component';
2
- export interface Schema extends ComponentSchema {
3
- }
1
+ import { Schema as ComponentSchema } from '@po-ui/ng-schematics/build-component';
2
+ export interface Schema extends ComponentSchema {
3
+ }
@@ -1,3 +1,3 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  //# sourceMappingURL=schema.js.map
@@ -1,2 +1,2 @@
1
- import { UpdateDependencies } from '@po-ui/ng-schematics/package-config';
2
- export declare const updateDepedenciesVersion: UpdateDependencies;
1
+ import { UpdateDependencies } from '@po-ui/ng-schematics/package-config';
2
+ export declare const updateDepedenciesVersion: UpdateDependencies;
@@ -1,14 +1,14 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.updateDepedenciesVersion = void 0;
4
- exports.updateDepedenciesVersion = {
5
- dependencies: [
6
- '@po-ui/ng-components',
7
- '@po-ui/ng-code-editor',
8
- '@po-ui/ng-templates',
9
- '@po-ui/ng-storage',
10
- '@po-ui/ng-sync',
11
- '@po-ui/style'
12
- ]
13
- };
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.updateDepedenciesVersion = void 0;
4
+ exports.updateDepedenciesVersion = {
5
+ dependencies: [
6
+ '@po-ui/ng-components',
7
+ '@po-ui/ng-code-editor',
8
+ '@po-ui/ng-templates',
9
+ '@po-ui/ng-storage',
10
+ '@po-ui/ng-sync',
11
+ '@po-ui/style'
12
+ ]
13
+ };
14
14
  //# sourceMappingURL=changes.js.map
@@ -1 +1 @@
1
- export default function (): import("@angular-devkit/schematics").Rule;
1
+ export default function (): import("@angular-devkit/schematics").Rule;
@@ -1,16 +1,16 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const schematics_1 = require("@angular-devkit/schematics");
4
- const tasks_1 = require("@angular-devkit/schematics/tasks");
5
- const package_config_1 = require("@po-ui/ng-schematics/package-config");
6
- const changes_1 = require("./changes");
7
- function default_1() {
8
- return (0, schematics_1.chain)([(0, package_config_1.updatePackageJson)('15.15.0', changes_1.updateDepedenciesVersion), postUpdate()]);
9
- }
10
- exports.default = default_1;
11
- function postUpdate() {
12
- return (_, context) => {
13
- context.addTask(new tasks_1.NodePackageInstallTask());
14
- };
15
- }
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const schematics_1 = require("@angular-devkit/schematics");
4
+ const tasks_1 = require("@angular-devkit/schematics/tasks");
5
+ const package_config_1 = require("@po-ui/ng-schematics/package-config");
6
+ const changes_1 = require("./changes");
7
+ function default_1() {
8
+ return (0, schematics_1.chain)([(0, package_config_1.updatePackageJson)('16.0.0-next.2', changes_1.updateDepedenciesVersion), postUpdate()]);
9
+ }
10
+ exports.default = default_1;
11
+ function postUpdate() {
12
+ return (_, context) => {
13
+ context.addTask(new tasks_1.NodePackageInstallTask());
14
+ };
15
+ }
16
16
  //# sourceMappingURL=index.js.map
@@ -1,4 +1,4 @@
1
- import { UpdateDependencies } from '@po-ui/ng-schematics/package-config';
2
- export declare const updateDepedenciesVersion: UpdateDependencies;
3
- export declare const httpClientModuleName = "HttpClientModule";
4
- export declare const httpClientModuleSourcePath = "@angular/common/http";
1
+ import { UpdateDependencies } from '@po-ui/ng-schematics/package-config';
2
+ export declare const updateDepedenciesVersion: UpdateDependencies;
3
+ export declare const httpClientModuleName = "HttpClientModule";
4
+ export declare const httpClientModuleSourcePath = "@angular/common/http";
@@ -1,16 +1,16 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.httpClientModuleSourcePath = exports.httpClientModuleName = exports.updateDepedenciesVersion = void 0;
4
- exports.updateDepedenciesVersion = {
5
- dependencies: [
6
- '@po-ui/ng-components',
7
- '@po-ui/ng-code-editor',
8
- '@po-ui/ng-templates',
9
- '@po-ui/ng-storage',
10
- '@po-ui/ng-sync',
11
- '@po-ui/style'
12
- ]
13
- };
14
- exports.httpClientModuleName = 'HttpClientModule';
15
- exports.httpClientModuleSourcePath = '@angular/common/http';
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.httpClientModuleSourcePath = exports.httpClientModuleName = exports.updateDepedenciesVersion = void 0;
4
+ exports.updateDepedenciesVersion = {
5
+ dependencies: [
6
+ '@po-ui/ng-components',
7
+ '@po-ui/ng-code-editor',
8
+ '@po-ui/ng-templates',
9
+ '@po-ui/ng-storage',
10
+ '@po-ui/ng-sync',
11
+ '@po-ui/style'
12
+ ]
13
+ };
14
+ exports.httpClientModuleName = 'HttpClientModule';
15
+ exports.httpClientModuleSourcePath = '@angular/common/http';
16
16
  //# sourceMappingURL=changes.js.map
@@ -1 +1 @@
1
- export default function (): import("@angular-devkit/schematics").Rule;
1
+ export default function (): import("@angular-devkit/schematics").Rule;
@@ -1,37 +1,37 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const schematics_1 = require("@angular-devkit/schematics");
4
- const tasks_1 = require("@angular-devkit/schematics/tasks");
5
- const ng_ast_utils_1 = require("@schematics/angular/utility/ng-ast-utils");
6
- const project_1 = require("@po-ui/ng-schematics/project");
7
- const module_1 = require("@po-ui/ng-schematics/module");
8
- const package_config_1 = require("@po-ui/ng-schematics/package-config");
9
- const changes_1 = require("./changes");
10
- function default_1() {
11
- return (0, schematics_1.chain)([(0, package_config_1.updatePackageJson)('15.15.0', changes_1.updateDepedenciesVersion), createUpgradeRule(), postUpdate()]);
12
- }
13
- exports.default = default_1;
14
- function postUpdate() {
15
- return (_, context) => {
16
- context.addTask(new tasks_1.NodePackageInstallTask());
17
- };
18
- }
19
- function createUpgradeRule() {
20
- return (tree, context) => {
21
- var _a;
22
- const logger = context.logger;
23
- const workspace = (_a = (0, project_1.getWorkspaceConfigGracefully)(tree)) !== null && _a !== void 0 ? _a : {};
24
- if (workspace === null) {
25
- logger.error('Não foi possível encontrar o arquivo de configuração de workspace.');
26
- return;
27
- }
28
- const projectNames = Object.keys(workspace.projects);
29
- for (const projectName of projectNames) {
30
- const project = workspace.projects[projectName];
31
- const appModulePath = (0, ng_ast_utils_1.getAppModulePath)(tree, (0, project_1.getProjectMainFile)(project));
32
- //adiciona httpClientModule no app
33
- (0, module_1.addModuleImportToModule)(tree, appModulePath, changes_1.httpClientModuleName, changes_1.httpClientModuleSourcePath);
34
- }
35
- };
36
- }
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const schematics_1 = require("@angular-devkit/schematics");
4
+ const tasks_1 = require("@angular-devkit/schematics/tasks");
5
+ const ng_ast_utils_1 = require("@schematics/angular/utility/ng-ast-utils");
6
+ const project_1 = require("@po-ui/ng-schematics/project");
7
+ const module_1 = require("@po-ui/ng-schematics/module");
8
+ const package_config_1 = require("@po-ui/ng-schematics/package-config");
9
+ const changes_1 = require("./changes");
10
+ function default_1() {
11
+ return (0, schematics_1.chain)([(0, package_config_1.updatePackageJson)('16.0.0-next.2', changes_1.updateDepedenciesVersion), createUpgradeRule(), postUpdate()]);
12
+ }
13
+ exports.default = default_1;
14
+ function postUpdate() {
15
+ return (_, context) => {
16
+ context.addTask(new tasks_1.NodePackageInstallTask());
17
+ };
18
+ }
19
+ function createUpgradeRule() {
20
+ return (tree, context) => {
21
+ var _a;
22
+ const logger = context.logger;
23
+ const workspace = (_a = (0, project_1.getWorkspaceConfigGracefully)(tree)) !== null && _a !== void 0 ? _a : {};
24
+ if (workspace === null) {
25
+ logger.error('Não foi possível encontrar o arquivo de configuração de workspace.');
26
+ return;
27
+ }
28
+ const projectNames = Object.keys(workspace.projects);
29
+ for (const projectName of projectNames) {
30
+ const project = workspace.projects[projectName];
31
+ const appModulePath = (0, ng_ast_utils_1.getAppModulePath)(tree, (0, project_1.getProjectMainFile)(project));
32
+ //adiciona httpClientModule no app
33
+ (0, module_1.addModuleImportToModule)(tree, appModulePath, changes_1.httpClientModuleName, changes_1.httpClientModuleSourcePath);
34
+ }
35
+ };
36
+ }
37
37
  //# sourceMappingURL=index.js.map
@@ -1,8 +1,8 @@
1
- import { ReplaceChanges } from '@po-ui/ng-schematics/replace';
2
- export declare const dependeciesChanges: {
3
- '@portinari/portinari-sync': string;
4
- '@portinari/portinari-storage': string;
5
- };
6
- export declare const replaceChanges: Array<ReplaceChanges>;
7
- export declare const regexPackages: RegExp;
8
- export declare const tsLintChanges: Array<ReplaceChanges>;
1
+ import { ReplaceChanges } from '@po-ui/ng-schematics/replace';
2
+ export declare const dependeciesChanges: {
3
+ '@portinari/portinari-sync': string;
4
+ '@portinari/portinari-storage': string;
5
+ };
6
+ export declare const replaceChanges: Array<ReplaceChanges>;
7
+ export declare const regexPackages: RegExp;
8
+ export declare const tsLintChanges: Array<ReplaceChanges>;
@@ -1,21 +1,21 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.tsLintChanges = exports.regexPackages = exports.replaceChanges = exports.dependeciesChanges = void 0;
4
- exports.dependeciesChanges = {
5
- '@portinari/portinari-sync': '@po-ui/ng-sync',
6
- '@portinari/portinari-storage': '@po-ui/ng-storage'
7
- };
8
- exports.replaceChanges = [
9
- {
10
- replace: 'portinari_sync_date',
11
- replaceWith: 'po_sync_date'
12
- }
13
- ];
14
- exports.regexPackages = new RegExp('@portinari/portinari-((storage)|(sync))', 'g');
15
- exports.tsLintChanges = [
16
- {
17
- replace: '@portinari/tslint',
18
- replaceWith: '@po-ui/ng-tslint'
19
- }
20
- ];
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.tsLintChanges = exports.regexPackages = exports.replaceChanges = exports.dependeciesChanges = void 0;
4
+ exports.dependeciesChanges = {
5
+ '@portinari/portinari-sync': '@po-ui/ng-sync',
6
+ '@portinari/portinari-storage': '@po-ui/ng-storage'
7
+ };
8
+ exports.replaceChanges = [
9
+ {
10
+ replace: 'portinari_sync_date',
11
+ replaceWith: 'po_sync_date'
12
+ }
13
+ ];
14
+ exports.regexPackages = new RegExp('@portinari/portinari-((storage)|(sync))', 'g');
15
+ exports.tsLintChanges = [
16
+ {
17
+ replace: '@portinari/tslint',
18
+ replaceWith: '@po-ui/ng-tslint'
19
+ }
20
+ ];
21
21
  //# sourceMappingURL=changes.js.map
@@ -1,5 +1,5 @@
1
- import { Tree } from '@angular-devkit/schematics';
2
- export declare function updateToV2(): import("@angular-devkit/schematics").Rule;
3
- export declare function updatePackageJson(version: string, dependenciesMap: {
4
- [key: string]: string;
5
- }): (tree: Tree) => Tree;
1
+ import { Tree } from '@angular-devkit/schematics';
2
+ export declare function updateToV2(): import("@angular-devkit/schematics").Rule;
3
+ export declare function updatePackageJson(version: string, dependenciesMap: {
4
+ [key: string]: string;
5
+ }): (tree: Tree) => Tree;