@forge/manifest 4.3.1-next.0 → 4.4.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.
- package/CHANGELOG.md +12 -0
- package/out/text/errors.d.ts +4 -0
- package/out/text/errors.d.ts.map +1 -1
- package/out/text/errors.js +4 -0
- package/out/types/module-types.d.ts +2 -1
- package/out/types/module-types.d.ts.map +1 -1
- package/out/types/module-types.js +1 -0
- package/out/validators/modules-validator.d.ts.map +1 -1
- package/out/validators/modules-validator.js +5 -13
- package/out/validators/modules-validators/jira/validate-full-admin-page.d.ts +4 -0
- package/out/validators/modules-validators/jira/validate-full-admin-page.d.ts.map +1 -0
- package/out/validators/modules-validators/jira/validate-full-admin-page.js +43 -0
- package/out/validators/modules-validators/jira/validate-subpages-in-module.d.ts +4 -0
- package/out/validators/modules-validators/jira/validate-subpages-in-module.d.ts.map +1 -0
- package/out/validators/modules-validators/jira/validate-subpages-in-module.js +17 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @forge/manifest
|
|
2
2
|
|
|
3
|
+
## 4.4.0-next.2
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- dfc74ba: [HYP-15] Add new validation rules for jira:adminPage module for new optional properties useAsGetStarted and useAsConfig, update existing validation rule to allow jira:adminPage module have multiple entries
|
|
8
|
+
|
|
9
|
+
## 4.3.1-next.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- f93ae31: Added automation:i18n module
|
|
14
|
+
|
|
3
15
|
## 4.3.1-next.0
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/out/text/errors.d.ts
CHANGED
|
@@ -27,6 +27,9 @@ export declare const errors: {
|
|
|
27
27
|
wrongFunctionReference: (module: string, functionKey: string) => string;
|
|
28
28
|
wrongResourceReference: (module: string, resourceKey: string) => string;
|
|
29
29
|
singleEntryOfTheModule: (moduleType: string) => string;
|
|
30
|
+
singleEntryOfModuleWithoutConfigureAndStartedParams: (moduleType: string) => string;
|
|
31
|
+
singleEntryOfModuleWithConfigureParam: (moduleType: string) => string;
|
|
32
|
+
singleEntryOfModuleWithGetStartedParam: (moduleType: string) => string;
|
|
30
33
|
displayConditions: {
|
|
31
34
|
overcomplicated: (moduleKey: string) => string;
|
|
32
35
|
invalid: (moduleKey: string) => string;
|
|
@@ -64,6 +67,7 @@ export declare const errors: {
|
|
|
64
67
|
searchAlias: (aliases: string[]) => string;
|
|
65
68
|
};
|
|
66
69
|
subPages: {
|
|
70
|
+
invalidPagesAndSectionsForConfigurePages: (key: string) => string;
|
|
67
71
|
subPagesWithUIKit: (key: string) => string;
|
|
68
72
|
invalidPagesAndSections: (key: string) => string;
|
|
69
73
|
};
|
package/out/text/errors.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../src/text/errors.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,MAAM;8BACS,MAAM,KAAG,MAAM;2BACpB,MAAM;yBAEN,MAAM,GAAG,SAAS,QAAQ,MAAM,EAAE,UAAU,MAAM,GAAG,SAAS,KAAG,MAAM;;uBAO3E,MAAM,EAAE,EAAE,GAAG,SAAS,KAAG,MAAM;4BAI1B,MAAM,EAAE,KAAG,MAAM;mCACV,MAAM,SAAS,MAAM,0CAA4B,MAAM;mDAIvC,MAAM,KAAG,MAAM;;;qCAI7B,MAAM,SAAS,MAAM,KAAG,MAAM;4CAEvB,MAAM,SAAS,MAAM,KAAG,MAAM;wCAElC,MAAM,SAAS,MAAM,EAAE,KAAG,MAAM;;;uCAMjC,MAAM,KAAG,MAAM;oCACpB,MAAM;iCAEP,MAAM,KAAG,MAAM;4CACJ,MAAM,KAAG,MAAM;;;gCAG3B,MAAM,KAAG,MAAM;6BACpB,MAAM;+BACJ,MAAM;iCACF,MAAM,KAAG,MAAM;yC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B;IACrC,SAAS,4BAA4B;IACrC,UAAU,wBAAwB;IAClC,GAAG,8BAA8B;CAClC"}
|
package/out/text/errors.js
CHANGED
|
@@ -39,6 +39,9 @@ exports.errors = {
|
|
|
39
39
|
wrongFunctionReference: (module, functionKey) => `${module} references undefined function module with key '${functionKey}'`,
|
|
40
40
|
wrongResourceReference: (module, resourceKey) => `missing resource key '${resourceKey}' is being referenced by ${module} module`,
|
|
41
41
|
singleEntryOfTheModule: (moduleType) => `Only a single entry of the ${moduleType} module can be defined in the manifest`,
|
|
42
|
+
singleEntryOfModuleWithoutConfigureAndStartedParams: (moduleType) => `The ${moduleType} module can only have a single entry that doesn’t include either useAsConfig or useAsGetStarted properties.`,
|
|
43
|
+
singleEntryOfModuleWithConfigureParam: (moduleType) => `The ${moduleType} module can only have a single entry that includes the useAsConfig property.`,
|
|
44
|
+
singleEntryOfModuleWithGetStartedParam: (moduleType) => `The ${moduleType} module can only have a single entry that includes the useAsGetStarted property.`,
|
|
42
45
|
displayConditions: {
|
|
43
46
|
overcomplicated: (moduleKey) => `Nesting of display conditions of the "${moduleKey}" module exceeds 10 levels.`,
|
|
44
47
|
invalid: (moduleKey) => `Display conditions of the "${moduleKey}" module are invalid.`,
|
|
@@ -76,6 +79,7 @@ exports.errors = {
|
|
|
76
79
|
searchAlias: (aliases) => `Search alias should be always unique per field. Found duplicates: ${aliases.join(', ')}.`
|
|
77
80
|
},
|
|
78
81
|
subPages: {
|
|
82
|
+
invalidPagesAndSectionsForConfigurePages: (key) => `You can’t use either pages or sections in the ${key} entry that includes either useAsConfig or useAsGetStarted properties.`,
|
|
79
83
|
subPagesWithUIKit: (key) => `Subpages in UI kit are not supported. Use Custom UI in the '${key}' module instead.`,
|
|
80
84
|
invalidPagesAndSections: (key) => `'pages' cannot be used with 'sections' in the module '${key}'.`
|
|
81
85
|
},
|
|
@@ -108,7 +108,8 @@ export declare enum AllModuleTypes {
|
|
|
108
108
|
AutomationForConfluenceBranch = "automation:branch",
|
|
109
109
|
AutomationForConfluenceCondition = "automation:condition",
|
|
110
110
|
AutomationForConfluenceAttributeResolver = "automation:attributeResolver",
|
|
111
|
-
AutomationForConfluenceTemplate = "automation:template"
|
|
111
|
+
AutomationForConfluenceTemplate = "automation:template",
|
|
112
|
+
AutomationForConfluenceI18n = "automation:i18n"
|
|
112
113
|
}
|
|
113
114
|
export declare const SUPPORTED_MODULES: AllModuleTypes[];
|
|
114
115
|
export declare const SUPPORTED_PRODUCTS_ONLY: string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"module-types.d.ts","sourceRoot":"","sources":["../../src/types/module-types.ts"],"names":[],"mappings":"AAAA,oBAAY,cAAc;IACxB,YAAY,kBAAkB;IAC9B,WAAW,iBAAiB;IAC5B,cAAc,oBAAoB;IAClC,YAAY,kBAAkB;IAC9B,oBAAoB,0BAA0B;IAC9C,QAAQ,cAAc;IACtB,uBAAuB,6BAA6B;IACpD,2BAA2B,iCAAiC;IAC5D,qBAAqB,2BAA2B;IAChD,uBAAuB,6BAA6B;IACpD,wBAAwB,8BAA8B;IACtD,oBAAoB,0BAA0B;IAC9C,sBAAsB,4BAA4B;IAClD,mBAAmB,yBAAyB;IAC5C,uBAAuB,6BAA6B;IACpD,kBAAkB,wBAAwB;IAC1C,qBAAqB,2BAA2B;IAChD,qBAAqB,2BAA2B;IAChD,wBAAwB,8BAA8B;IACtD,eAAe,qBAAqB;IACpC,mBAAmB,yBAAyB;IAC5C,eAAe,qBAAqB;IACpC,iBAAiB,uBAAuB;IACxC,mBAAmB,yBAAyB;IAC5C,eAAe,qBAAqB;IACpC,cAAc,oBAAoB;IAClC,aAAa,mBAAmB;IAChC,eAAe,qBAAqB;IACpC,uBAAuB,6BAA6B;IACpD,cAAc,oBAAoB;IAClC,mBAAmB,yBAAyB;IAC5C,6BAA6B,mCAAmC;IAChE,6BAA6B,mCAAmC;IAChE,oBAAoB,0BAA0B;IAC9C,qBAAqB,2BAA2B;IAEhD,gBAAgB,sBAAsB;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mCAAmC;IAC/D,yBAAyB,gCAAgC;IACzD,wBAAwB,+BAA+B;IACvD,kBAAkB,yBAAyB;IAC3C,gCAAgC,uCAAuC;IACvE,qCAAqC,4CAA4C;IACjF,8BAA8B,qCAAqC;IACnE,+BAA+B,sCAAsC;IACrE,sCAAsC,6CAA6C;IACnF,4BAA4B,mCAAmC;IAC/D,6BAA6B,oCAAoC;IACjE,yBAAyB,gCAAgC;IACzD,2BAA2B,kCAAkC;IAC7D,iCAAiC,wCAAwC;IACzE,sBAAsB,6BAA6B;IACnD,iCAAiC,wCAAwC;IACzE,oCAAoC,2CAA2C;IAC/E,iCAAiC,wCAAwC;IACzE,0BAA0B,iCAAiC;IAC3D,oBAAoB,2BAA2B;IAC/C,sBAAsB,6BAA6B;IACnD,mBAAmB,0BAA0B;IAC7C,0BAA0B,iCAAiC;IAC3D,8BAA8B,uBAAuB;IACrD,6BAA6B,sBAAsB;IACnD,6BAA6B,sBAAsB;IACnD,gCAAgC,yBAAyB;IACzD,wCAAwC,iCAAiC;IACzE,+BAA+B,wBAAwB;IACvD,2BAA2B,oBAAoB;CAChD;AAED,eAAO,MAAM,iBAAiB,kBAAgC,CAAC;AAE/D,eAAO,MAAM,uBAAuB,UAAwE,CAAC"}
|
|
@@ -113,6 +113,7 @@ var AllModuleTypes;
|
|
|
113
113
|
AllModuleTypes["AutomationForConfluenceCondition"] = "automation:condition";
|
|
114
114
|
AllModuleTypes["AutomationForConfluenceAttributeResolver"] = "automation:attributeResolver";
|
|
115
115
|
AllModuleTypes["AutomationForConfluenceTemplate"] = "automation:template";
|
|
116
|
+
AllModuleTypes["AutomationForConfluenceI18n"] = "automation:i18n";
|
|
116
117
|
})(AllModuleTypes = exports.AllModuleTypes || (exports.AllModuleTypes = {}));
|
|
117
118
|
exports.SUPPORTED_MODULES = Object.values(AllModuleTypes);
|
|
118
119
|
exports.SUPPORTED_PRODUCTS_ONLY = [...new Set(exports.SUPPORTED_MODULES.map((module) => module.split(':')[0]))];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"modules-validator.d.ts","sourceRoot":"","sources":["../../src/validators/modules-validator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,cAAc,EAAE,wBAAwB,EAAsC,MAAM,UAAU,CAAC;AAGxH,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"modules-validator.d.ts","sourceRoot":"","sources":["../../src/validators/modules-validator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,cAAc,EAAE,wBAAwB,EAAsC,MAAM,UAAU,CAAC;AAGxH,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAQ3D,qBAAa,gBACX,YAAW,kBAAkB,CAAC,cAAc,CAAC,cAAc,CAAC,GAAG,SAAS,EAAE,cAAc,CAAC;IACzF,OAAO,CAAC,oBAAoB,CAA0C;IAEhE,QAAQ,CACZ,QAAQ,EAAE,cAAc,CAAC,cAAc,CAAC,GAAG,SAAS,GACnD,OAAO,CAAC,wBAAwB,CAAC,cAAc,CAAC,CAAC;CA0NrD"}
|
|
@@ -8,6 +8,8 @@ const fs_1 = require("fs");
|
|
|
8
8
|
const path_1 = require("path");
|
|
9
9
|
const ui_modifications_1 = require("./modules-validators/jira/ui-modifications");
|
|
10
10
|
const confluence_1 = require("./modules-validators/confluence");
|
|
11
|
+
const validate_full_admin_page_1 = require("./modules-validators/jira/validate-full-admin-page");
|
|
12
|
+
const validate_subpages_in_module_1 = require("./modules-validators/jira/validate-subpages-in-module");
|
|
11
13
|
class ModulesValidator {
|
|
12
14
|
constructor() {
|
|
13
15
|
this.functionHandlerRegex = /^([a-zA-Z0-9-_]+)\.([a-zA-Z0-9-_]+)$/;
|
|
@@ -93,24 +95,14 @@ class ModulesValidator {
|
|
|
93
95
|
}
|
|
94
96
|
});
|
|
95
97
|
validationErrors.push(...ui_modifications_1.validateUiModificationsModule(modules, yamlContentByLine));
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
types_1.AllModuleTypes.JiraProjectPage,
|
|
99
|
-
types_1.AllModuleTypes.JiraProjectSettingsPage,
|
|
100
|
-
types_1.AllModuleTypes.JiraGlobalPage
|
|
101
|
-
].forEach((moduleType) => {
|
|
98
|
+
validationErrors.push(...validate_full_admin_page_1.validateFullAdminPage(modules, yamlContentByLine));
|
|
99
|
+
[types_1.AllModuleTypes.JiraProjectPage, types_1.AllModuleTypes.JiraProjectSettingsPage, types_1.AllModuleTypes.JiraGlobalPage].forEach((moduleType) => {
|
|
102
100
|
const moduleArray = modules[moduleType];
|
|
103
101
|
if (moduleArray && moduleArray.length > 1) {
|
|
104
102
|
validationErrors.push(Object.assign({ message: text_1.errors.modules.singleEntryOfTheModule(moduleType), reference: text_1.References.Modules, level: 'error' }, utils_1.findPosition(moduleArray[1].key, yamlContentByLine)));
|
|
105
103
|
}
|
|
106
104
|
if (moduleArray && moduleArray.length === 1) {
|
|
107
|
-
|
|
108
|
-
if (module && (module.pages || module.sections) && module.function) {
|
|
109
|
-
validationErrors.push(Object.assign({ message: text_1.errors.modules.subPages.subPagesWithUIKit(module.key), reference: text_1.References.Modules, level: 'error' }, utils_1.findPosition(module.key, yamlContentByLine)));
|
|
110
|
-
}
|
|
111
|
-
if (module && module.pages && module.sections) {
|
|
112
|
-
validationErrors.push(Object.assign({ message: text_1.errors.modules.subPages.invalidPagesAndSections(module.key), reference: text_1.References.Modules, level: 'error' }, utils_1.findPosition(module.key, yamlContentByLine)));
|
|
113
|
-
}
|
|
105
|
+
validationErrors.push(...validate_subpages_in_module_1.validateSubpagesInModule(modules, moduleType, yamlContentByLine));
|
|
114
106
|
}
|
|
115
107
|
});
|
|
116
108
|
[types_1.AllModuleTypes.JiraCustomField, types_1.AllModuleTypes.JiraCustomFieldType].forEach((moduleType) => {
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { ValidationError } from '../../../types';
|
|
2
|
+
import { Modules } from '../../../schema/manifest';
|
|
3
|
+
export declare const validateFullAdminPage: (modules: Modules, yamlContentByLine?: string[] | undefined) => ValidationError[];
|
|
4
|
+
//# sourceMappingURL=validate-full-admin-page.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validate-full-admin-page.d.ts","sourceRoot":"","sources":["../../../../src/validators/modules-validators/jira/validate-full-admin-page.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,eAAe,EAAE,MAAM,gBAAgB,CAAC;AACjE,OAAO,EAAE,OAAO,EAAE,MAAM,0BAA0B,CAAC;AA+CnD,eAAO,MAAM,qBAAqB,YAAa,OAAO,+CAAiC,eAAe,EA4CrG,CAAC"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.validateFullAdminPage = void 0;
|
|
4
|
+
const types_1 = require("../../../types");
|
|
5
|
+
const text_1 = require("../../../text");
|
|
6
|
+
const utils_1 = require("../../../utils");
|
|
7
|
+
const validate_subpages_in_module_1 = require("./validate-subpages-in-module");
|
|
8
|
+
const jiraAdminPageType = types_1.AllModuleTypes.JiraAdminPage;
|
|
9
|
+
const validateSeparateAdminPageModule = (pageType, modules, currentModule, multiplePagesError, yamlContentByLine) => {
|
|
10
|
+
const validationErrors = [];
|
|
11
|
+
if ((currentModule === null || currentModule === void 0 ? void 0 : currentModule.length) > 1) {
|
|
12
|
+
validationErrors.push(Object.assign({ message: multiplePagesError, reference: text_1.References.Modules, level: 'error' }, utils_1.findPosition(currentModule[1].key, yamlContentByLine)));
|
|
13
|
+
}
|
|
14
|
+
if ((currentModule === null || currentModule === void 0 ? void 0 : currentModule.length) === 1) {
|
|
15
|
+
if (pageType === 'admin') {
|
|
16
|
+
const adminModules = Object.assign(Object.assign({}, modules), { [jiraAdminPageType]: currentModule });
|
|
17
|
+
validationErrors.push(...validate_subpages_in_module_1.validateSubpagesInModule(adminModules, jiraAdminPageType, yamlContentByLine));
|
|
18
|
+
}
|
|
19
|
+
if (['get-started', 'config'].includes(pageType)) {
|
|
20
|
+
const { pages, sections, key } = currentModule[0];
|
|
21
|
+
if (pages || sections)
|
|
22
|
+
validationErrors.push(Object.assign({ message: text_1.errors.modules.subPages.invalidPagesAndSectionsForConfigurePages(jiraAdminPageType), reference: text_1.References.Modules, level: 'error' }, utils_1.findPosition(key, yamlContentByLine)));
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
return validationErrors;
|
|
26
|
+
};
|
|
27
|
+
exports.validateFullAdminPage = (modules, yamlContentByLine) => {
|
|
28
|
+
const validationErrors = [];
|
|
29
|
+
const moduleArray = modules[jiraAdminPageType];
|
|
30
|
+
const adminPageModules = moduleArray === null || moduleArray === void 0 ? void 0 : moduleArray.filter((module) => !(module === null || module === void 0 ? void 0 : module.useAsGetStarted) && !(module === null || module === void 0 ? void 0 : module.useAsConfig));
|
|
31
|
+
const getStartedModules = moduleArray === null || moduleArray === void 0 ? void 0 : moduleArray.filter((module) => module === null || module === void 0 ? void 0 : module.useAsGetStarted);
|
|
32
|
+
const configModules = moduleArray === null || moduleArray === void 0 ? void 0 : moduleArray.filter((module) => module === null || module === void 0 ? void 0 : module.useAsConfig);
|
|
33
|
+
if (adminPageModules === null || adminPageModules === void 0 ? void 0 : adminPageModules.length) {
|
|
34
|
+
validationErrors.push(...validateSeparateAdminPageModule('admin', modules, adminPageModules, text_1.errors.modules.singleEntryOfModuleWithoutConfigureAndStartedParams(jiraAdminPageType), yamlContentByLine));
|
|
35
|
+
}
|
|
36
|
+
if (getStartedModules === null || getStartedModules === void 0 ? void 0 : getStartedModules.length) {
|
|
37
|
+
validationErrors.push(...validateSeparateAdminPageModule('get-started', modules, getStartedModules, text_1.errors.modules.singleEntryOfModuleWithGetStartedParam(jiraAdminPageType), yamlContentByLine));
|
|
38
|
+
}
|
|
39
|
+
if (configModules === null || configModules === void 0 ? void 0 : configModules.length) {
|
|
40
|
+
validationErrors.push(...validateSeparateAdminPageModule('config', modules, configModules, text_1.errors.modules.singleEntryOfModuleWithConfigureParam(jiraAdminPageType), yamlContentByLine));
|
|
41
|
+
}
|
|
42
|
+
return validationErrors;
|
|
43
|
+
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { ValidationError } from '../../../types';
|
|
2
|
+
import { Modules } from '../../../schema/manifest';
|
|
3
|
+
export declare const validateSubpagesInModule: (modules: Modules, moduleType: string, yamlContentByLine?: string[] | undefined) => ValidationError[];
|
|
4
|
+
//# sourceMappingURL=validate-subpages-in-module.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validate-subpages-in-module.d.ts","sourceRoot":"","sources":["../../../../src/validators/modules-validators/jira/validate-subpages-in-module.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAGjD,OAAO,EAAE,OAAO,EAAE,MAAM,0BAA0B,CAAC;AAEnD,eAAO,MAAM,wBAAwB,YAC1B,OAAO,cACJ,MAAM,+CAEjB,eAAe,EA0BjB,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.validateSubpagesInModule = void 0;
|
|
4
|
+
const text_1 = require("../../../text");
|
|
5
|
+
const utils_1 = require("../../../utils");
|
|
6
|
+
exports.validateSubpagesInModule = (modules, moduleType, yamlContentByLine) => {
|
|
7
|
+
const validationErrors = [];
|
|
8
|
+
const moduleArray = modules[moduleType];
|
|
9
|
+
const module = moduleArray[0];
|
|
10
|
+
if (module && (module.pages || module.sections) && module.function) {
|
|
11
|
+
validationErrors.push(Object.assign({ message: text_1.errors.modules.subPages.subPagesWithUIKit(module.key), reference: text_1.References.Modules, level: 'error' }, utils_1.findPosition(module.key, yamlContentByLine)));
|
|
12
|
+
}
|
|
13
|
+
if (module && module.pages && module.sections) {
|
|
14
|
+
validationErrors.push(Object.assign({ message: text_1.errors.modules.subPages.invalidPagesAndSections(module.key), reference: text_1.References.Modules, level: 'error' }, utils_1.findPosition(module.key, yamlContentByLine)));
|
|
15
|
+
}
|
|
16
|
+
return validationErrors;
|
|
17
|
+
};
|