@ihk-gfi/lux-components-update 11.3.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/LICENSE +198 -0
- package/README.md +55 -0
- package/package.json +54 -0
- package/src/add-lux-components/files/app/app-routing.module.ts +19 -0
- package/src/add-lux-components/files/app/app.component.html +27 -0
- package/src/add-lux-components/files/app/app.component.spec.ts +19 -0
- package/src/add-lux-components/files/app/app.component.ts +13 -0
- package/src/add-lux-components/files/app/app.module.ts +56 -0
- package/src/add-lux-components/files/app/error/error.component.html +10 -0
- package/src/add-lux-components/files/app/error/error.component.scss +3 -0
- package/src/add-lux-components/files/app/error/error.component.spec.ts +49 -0
- package/src/add-lux-components/files/app/error/error.component.ts +17 -0
- package/src/add-lux-components/files/app/home/home.component.html +7 -0
- package/src/add-lux-components/files/app/home/home.component.scss +0 -0
- package/src/add-lux-components/files/app/home/home.component.ts +13 -0
- package/src/add-lux-components/files/app/profil/profil.component.html +1 -0
- package/src/add-lux-components/files/app/profil/profil.component.scss +0 -0
- package/src/add-lux-components/files/app/profil/profil.component.spec.ts +24 -0
- package/src/add-lux-components/files/app/profil/profil.component.ts +11 -0
- package/src/add-lux-components/files/environments/environment.prod.ts +4 -0
- package/src/add-lux-components/files/environments/environment.ts +17 -0
- package/src/add-lux-components/files/locale/messages.en.xlf +948 -0
- package/src/add-lux-components/files/locale/messages.xlf +822 -0
- package/src/add-lux-components/files/scripts/.browserslistrc +17 -0
- package/src/add-lux-components/files/src/polyfills.ts +68 -0
- package/src/add-lux-components/index.d.ts +10 -0
- package/src/add-lux-components/index.js +143 -0
- package/src/add-lux-components/index.js.map +1 -0
- package/src/add-lux-components/index.ts +183 -0
- package/src/add-lux-components/index_spec.d.ts +1 -0
- package/src/add-lux-components/index_spec.js +51 -0
- package/src/add-lux-components/index_spec.js.map +1 -0
- package/src/add-lux-components/index_spec.ts +55 -0
- package/src/add-lux-components/schema.json +23 -0
- package/src/collection.json +55 -0
- package/src/migrate-to-eslint/files/.eslintrc.json +68 -0
- package/src/migrate-to-eslint/files/.prettierrc +25 -0
- package/src/migrate-to-eslint/index.d.ts +6 -0
- package/src/migrate-to-eslint/index.js +149 -0
- package/src/migrate-to-eslint/index.js.map +1 -0
- package/src/migrate-to-eslint/index.ts +181 -0
- package/src/migrate-to-eslint/index_spec.d.ts +1 -0
- package/src/migrate-to-eslint/index_spec.js +129 -0
- package/src/migrate-to-eslint/index_spec.js.map +1 -0
- package/src/migrate-to-eslint/index_spec.ts +152 -0
- package/src/migrate-to-eslint/schema.json +23 -0
- package/src/migrate-to-webcomponent/index.d.ts +10 -0
- package/src/migrate-to-webcomponent/index.js +278 -0
- package/src/migrate-to-webcomponent/index.js.map +1 -0
- package/src/migrate-to-webcomponent/index.ts +331 -0
- package/src/migrate-to-webcomponent/index_spec.d.ts +1 -0
- package/src/migrate-to-webcomponent/index_spec.js +580 -0
- package/src/migrate-to-webcomponent/index_spec.js.map +1 -0
- package/src/migrate-to-webcomponent/index_spec.ts +703 -0
- package/src/migrate-to-webcomponent/schema.json +23 -0
- package/src/update/files/locale/messages.en.xlf +940 -0
- package/src/update/files/locale/messages.xlf +815 -0
- package/src/update/files/scripts/move-de-files.js +15 -0
- package/src/update/index.d.ts +23 -0
- package/src/update/index.js +635 -0
- package/src/update/index.js.map +1 -0
- package/src/update/index.ts +712 -0
- package/src/update/index_spec.d.ts +1 -0
- package/src/update/index_spec.js +990 -0
- package/src/update/index_spec.js.map +1 -0
- package/src/update/index_spec.ts +1145 -0
- package/src/update/schema.json +23 -0
- package/src/update-dependencies/index.d.ts +5 -0
- package/src/update-dependencies/index.js +113 -0
- package/src/update-dependencies/index.js.map +1 -0
- package/src/update-dependencies/index.ts +114 -0
- package/src/update-dependencies/schema.json +23 -0
- package/src/update110001/index.d.ts +2 -0
- package/src/update110001/index.js +42 -0
- package/src/update110001/index.js.map +1 -0
- package/src/update110001/index.ts +40 -0
- package/src/update110001/index_spec.d.ts +1 -0
- package/src/update110001/index_spec.js +67 -0
- package/src/update110001/index_spec.js.map +1 -0
- package/src/update110001/index_spec.ts +72 -0
- package/src/update110001/schema.json +23 -0
- package/src/update110100/index.d.ts +2 -0
- package/src/update110100/index.js +27 -0
- package/src/update110100/index.js.map +1 -0
- package/src/update110100/index.ts +24 -0
- package/src/update110100/index_spec.d.ts +1 -0
- package/src/update110100/index_spec.js +69 -0
- package/src/update110100/index_spec.js.map +1 -0
- package/src/update110100/index_spec.ts +73 -0
- package/src/update110100/schema.json +23 -0
- package/src/update110101/index.d.ts +2 -0
- package/src/update110101/index.js +24 -0
- package/src/update110101/index.js.map +1 -0
- package/src/update110101/index.ts +21 -0
- package/src/update110101/index_spec.d.ts +1 -0
- package/src/update110101/index_spec.js +65 -0
- package/src/update110101/index_spec.js.map +1 -0
- package/src/update110101/index_spec.ts +69 -0
- package/src/update110101/schema.json +23 -0
- package/src/update110200/index.d.ts +2 -0
- package/src/update110200/index.js +24 -0
- package/src/update110200/index.js.map +1 -0
- package/src/update110200/index.ts +21 -0
- package/src/update110200/index_spec.d.ts +1 -0
- package/src/update110200/index_spec.js +65 -0
- package/src/update110200/index_spec.js.map +1 -0
- package/src/update110200/index_spec.ts +69 -0
- package/src/update110200/schema.json +23 -0
- package/src/update110300/index.d.ts +2 -0
- package/src/update110300/index.js +133 -0
- package/src/update110300/index.js.map +1 -0
- package/src/update110300/index.ts +148 -0
- package/src/update110300/index_spec.d.ts +1 -0
- package/src/update110300/index_spec.js +121 -0
- package/src/update110300/index_spec.js.map +1 -0
- package/src/update110300/index_spec.ts +139 -0
- package/src/update110300/schema.json +23 -0
- package/src/utility/dependencies.d.ts +39 -0
- package/src/utility/dependencies.js +96 -0
- package/src/utility/dependencies.js.map +1 -0
- package/src/utility/dependencies.ts +116 -0
- package/src/utility/files.d.ts +60 -0
- package/src/utility/files.js +299 -0
- package/src/utility/files.js.map +1 -0
- package/src/utility/files.ts +355 -0
- package/src/utility/html.d.ts +49 -0
- package/src/utility/html.js +183 -0
- package/src/utility/html.js.map +1 -0
- package/src/utility/html.ts +212 -0
- package/src/utility/json.d.ts +34 -0
- package/src/utility/json.js +70 -0
- package/src/utility/json.js.map +1 -0
- package/src/utility/json.ts +70 -0
- package/src/utility/logging.d.ts +32 -0
- package/src/utility/logging.js +82 -0
- package/src/utility/logging.js.map +1 -0
- package/src/utility/logging.ts +80 -0
- package/src/utility/test.d.ts +10 -0
- package/src/utility/test.js +24 -0
- package/src/utility/test.js.map +1 -0
- package/src/utility/test.ts +24 -0
- package/src/utility/typescript.d.ts +22 -0
- package/src/utility/typescript.js +521 -0
- package/src/utility/typescript.js.map +1 -0
- package/src/utility/typescript.ts +598 -0
- package/src/utility/typescript_spec.d.ts +1 -0
- package/src/utility/typescript_spec.js +1006 -0
- package/src/utility/typescript_spec.js.map +1 -0
- package/src/utility/typescript_spec.ts +1267 -0
- package/src/utility/util.d.ts +33 -0
- package/src/utility/util.js +139 -0
- package/src/utility/util.js.map +1 -0
- package/src/utility/util.ts +140 -0
- package/src/utility/validation.d.ts +11 -0
- package/src/utility/validation.js +44 -0
- package/src/utility/validation.js.map +1 -0
- package/src/utility/validation.ts +49 -0
- package/tsconfig.json +37 -0
|
@@ -0,0 +1,521 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.addConstructorContent = exports.addClassProperty = exports.addConstructorParameter = exports.addMethod = exports.addParameter = exports.getMethod = exports.getConstructor = exports.getSyntaxListOfClass = exports.findChild = exports.showTree = exports.getNextSiblings = exports.getNextSibling = exports.getPrevSibling = exports.getSiblings = exports.removeProvider = exports.removeImport = exports.addImport = exports.removeInterface = exports.addInterface = exports.getSourceNodes = void 0;
|
|
4
|
+
const schematics_1 = require("@angular-devkit/schematics");
|
|
5
|
+
const ts = require("typescript");
|
|
6
|
+
const logging_1 = require("./logging");
|
|
7
|
+
function getSourceNodes(sourceFile) {
|
|
8
|
+
const nodes = [sourceFile];
|
|
9
|
+
const result = [];
|
|
10
|
+
while (nodes.length > 0) {
|
|
11
|
+
const node = nodes.shift();
|
|
12
|
+
if (node) {
|
|
13
|
+
result.push(node);
|
|
14
|
+
if (node.getChildCount(sourceFile) >= 0) {
|
|
15
|
+
nodes.unshift(...node.getChildren());
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
return result;
|
|
20
|
+
}
|
|
21
|
+
exports.getSourceNodes = getSourceNodes;
|
|
22
|
+
function addInterface(tree, filePath, interfaceName, logMessage = true) {
|
|
23
|
+
const content = tree.read(filePath).toString();
|
|
24
|
+
const fileName = filePath.substring(filePath.lastIndexOf('/') + 1, filePath.length);
|
|
25
|
+
const sourceFile = ts.createSourceFile(`${fileName}`, content, ts.ScriptTarget.Latest, true);
|
|
26
|
+
const nodes = getSourceNodes(sourceFile);
|
|
27
|
+
const classNode = nodes.find((n) => n.kind === ts.SyntaxKind.ClassDeclaration);
|
|
28
|
+
if (classNode) {
|
|
29
|
+
const implementsNode = findChild(classNode, ts.SyntaxKind.FirstFutureReservedWord, 'implements');
|
|
30
|
+
const extendsNode = findChild(classNode, ts.SyntaxKind.ExtendsKeyword, 'extends');
|
|
31
|
+
if (implementsNode) {
|
|
32
|
+
const syntaxListNode = findChild(implementsNode.parent, ts.SyntaxKind.SyntaxList);
|
|
33
|
+
if (syntaxListNode) {
|
|
34
|
+
const lastChild = syntaxListNode.getChildren()[syntaxListNode.getChildren().length - 1];
|
|
35
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
36
|
+
updateRecorder.insertLeft(lastChild.end, `, ${interfaceName}`);
|
|
37
|
+
tree.commitUpdate(updateRecorder);
|
|
38
|
+
if (logMessage) {
|
|
39
|
+
logging_1.logInfo(`Interface ${interfaceName} hinzugefügt.`);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
else {
|
|
44
|
+
if (extendsNode) {
|
|
45
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
46
|
+
updateRecorder.insertLeft(extendsNode.parent.end, ` implements ${interfaceName}`);
|
|
47
|
+
tree.commitUpdate(updateRecorder);
|
|
48
|
+
if (logMessage) {
|
|
49
|
+
logging_1.logInfo(`Interface ${interfaceName} hinzugefügt.`);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
else {
|
|
53
|
+
const classKeywordNode = findChild(classNode, ts.SyntaxKind.ClassKeyword);
|
|
54
|
+
if (!classKeywordNode) {
|
|
55
|
+
throw new schematics_1.SchematicsException(`Die Klasse ${filePath} hat kein ClassKeyword.`);
|
|
56
|
+
}
|
|
57
|
+
const classIdentifierNode = getNextSibling(classKeywordNode);
|
|
58
|
+
if (!classIdentifierNode) {
|
|
59
|
+
throw new schematics_1.SchematicsException(`Die Klasse ${filePath} hat keinen Namen.`);
|
|
60
|
+
}
|
|
61
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
62
|
+
updateRecorder.insertLeft(classIdentifierNode.end, ` implements ${interfaceName}`);
|
|
63
|
+
tree.commitUpdate(updateRecorder);
|
|
64
|
+
if (logMessage) {
|
|
65
|
+
logging_1.logInfo(`Interface ${interfaceName} hinzugefügt.`);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
exports.addInterface = addInterface;
|
|
72
|
+
function removeInterface(tree, filePath, interfaceName, logMessage = true) {
|
|
73
|
+
const content = tree.read(filePath).toString();
|
|
74
|
+
const fileName = filePath.substring(filePath.lastIndexOf('/') + 1, filePath.length);
|
|
75
|
+
const sourceFile = ts.createSourceFile(`${fileName}`, content, ts.ScriptTarget.Latest, true);
|
|
76
|
+
const nodes = getSourceNodes(sourceFile);
|
|
77
|
+
const classNode = nodes.find((n) => n.kind === ts.SyntaxKind.ClassDeclaration);
|
|
78
|
+
if (classNode) {
|
|
79
|
+
const syntaxListClassNodes = classNode.getChildren().filter((n) => n.kind === ts.SyntaxKind.SyntaxList);
|
|
80
|
+
if (syntaxListClassNodes) {
|
|
81
|
+
syntaxListClassNodes.forEach((syntaxListNode) => {
|
|
82
|
+
const heritageClauseNodes = syntaxListNode.getChildren().filter((n) => n.kind === ts.SyntaxKind.HeritageClause);
|
|
83
|
+
if (heritageClauseNodes) {
|
|
84
|
+
heritageClauseNodes.forEach((heritageClauseNode) => {
|
|
85
|
+
const wordNode = heritageClauseNode
|
|
86
|
+
.getChildren()
|
|
87
|
+
.find((n) => n.kind === ts.SyntaxKind.FirstFutureReservedWord);
|
|
88
|
+
if (wordNode && wordNode.getText() === 'implements') {
|
|
89
|
+
const interfaceSyntaxNode = heritageClauseNode
|
|
90
|
+
.getChildren()
|
|
91
|
+
.find((n) => n.kind === ts.SyntaxKind.SyntaxList);
|
|
92
|
+
if (interfaceSyntaxNode) {
|
|
93
|
+
const interfaceChildren = interfaceSyntaxNode.getChildren();
|
|
94
|
+
if (interfaceChildren) {
|
|
95
|
+
if (interfaceChildren.length === 1) {
|
|
96
|
+
if (interfaceChildren[0].getText() === interfaceName) {
|
|
97
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
98
|
+
updateRecorder.remove(heritageClauseNode.pos, heritageClauseNode.getChildren()[heritageClauseNode.getChildren().length - 1].end -
|
|
99
|
+
heritageClauseNode.pos);
|
|
100
|
+
tree.commitUpdate(updateRecorder);
|
|
101
|
+
if (logMessage) {
|
|
102
|
+
logging_1.logInfo(`Interface ${interfaceName} entfernt.`);
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
else {
|
|
107
|
+
for (let i = 0; i < interfaceChildren.length; i++) {
|
|
108
|
+
if (interfaceChildren[i].getText() === interfaceName) {
|
|
109
|
+
const prevSibling = getPrevSibling(interfaceChildren[i], ts.SyntaxKind.SyntaxList);
|
|
110
|
+
const nextSibling = getNextSibling(interfaceChildren[i], ts.SyntaxKind.SyntaxList);
|
|
111
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
112
|
+
if (nextSibling) {
|
|
113
|
+
updateRecorder.remove(interfaceChildren[i].pos, nextSibling.end - interfaceChildren[i].pos);
|
|
114
|
+
}
|
|
115
|
+
else {
|
|
116
|
+
if (prevSibling) {
|
|
117
|
+
updateRecorder.remove(prevSibling.pos, interfaceChildren[i].end - prevSibling.pos);
|
|
118
|
+
}
|
|
119
|
+
else {
|
|
120
|
+
updateRecorder.remove(interfaceChildren[i].pos, interfaceChildren[i].end - interfaceChildren[i].pos);
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
tree.commitUpdate(updateRecorder);
|
|
124
|
+
if (logMessage) {
|
|
125
|
+
logging_1.logInfo(`Interface ${interfaceName} entfernt.`);
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
});
|
|
134
|
+
}
|
|
135
|
+
});
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
exports.removeInterface = removeInterface;
|
|
140
|
+
function addImport(tree, filePath, packageName, importName, logMessage = true) {
|
|
141
|
+
const content = tree.read(filePath).toString();
|
|
142
|
+
const fileName = filePath.substring(filePath.lastIndexOf('/') + 1, filePath.length);
|
|
143
|
+
const sourceFile = ts.createSourceFile(`${fileName}`, content, ts.ScriptTarget.Latest, true);
|
|
144
|
+
const nodes = getSourceNodes(sourceFile);
|
|
145
|
+
const importNodes = nodes.filter((n) => n.kind === ts.SyntaxKind.ImportDeclaration);
|
|
146
|
+
let importNode = undefined;
|
|
147
|
+
if (importNodes) {
|
|
148
|
+
importNodes.forEach((node) => {
|
|
149
|
+
const importDeclarationChildren = node.getChildren();
|
|
150
|
+
if (importDeclarationChildren) {
|
|
151
|
+
const importNameNode = importDeclarationChildren.find((n) => n.kind === ts.SyntaxKind.StringLiteral &&
|
|
152
|
+
(n.getText() === `'${packageName}'` || n.getText() === `"${packageName}"`));
|
|
153
|
+
if (importNameNode) {
|
|
154
|
+
importNode = node;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
});
|
|
158
|
+
}
|
|
159
|
+
if (importNode) {
|
|
160
|
+
const importClauseNode = importNode.getChildren().find((n) => n.kind === ts.SyntaxKind.ImportClause);
|
|
161
|
+
if (importClauseNode) {
|
|
162
|
+
const namedImportsNode = importClauseNode.getChildren().find((n) => n.kind === ts.SyntaxKind.NamedImports);
|
|
163
|
+
if (!namedImportsNode) {
|
|
164
|
+
throw new schematics_1.SchematicsException(`In der Datei ${filePath} gibt es keine NamedImports.`);
|
|
165
|
+
}
|
|
166
|
+
const syntaxListNode = namedImportsNode.getChildren().find((n) => n.kind === ts.SyntaxKind.SyntaxList);
|
|
167
|
+
if (!syntaxListNode) {
|
|
168
|
+
throw new schematics_1.SchematicsException(`In der Datei ${filePath} gibt es keine SyntaxList für den Import.`);
|
|
169
|
+
}
|
|
170
|
+
const importChildren = syntaxListNode.getChildren();
|
|
171
|
+
const foundNode = importName ? findChild(syntaxListNode, ts.SyntaxKind.Identifier, importName) : undefined;
|
|
172
|
+
if (!foundNode) {
|
|
173
|
+
const lastChildNode = importChildren[syntaxListNode.getChildren().length - 1];
|
|
174
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
175
|
+
updateRecorder.insertLeft(lastChildNode.end, ', ' + importName);
|
|
176
|
+
tree.commitUpdate(updateRecorder);
|
|
177
|
+
if (logMessage) {
|
|
178
|
+
logging_1.logInfo(`Import ${importName} hinzugefügt.`);
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
else {
|
|
184
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
185
|
+
if (importName) {
|
|
186
|
+
updateRecorder.insertLeft(0, `import { ${importName} } from '${packageName}';\n`);
|
|
187
|
+
}
|
|
188
|
+
else {
|
|
189
|
+
updateRecorder.insertLeft(0, `import '${packageName}';\n`);
|
|
190
|
+
}
|
|
191
|
+
tree.commitUpdate(updateRecorder);
|
|
192
|
+
if (logMessage) {
|
|
193
|
+
logging_1.logInfo(`Import ${importName} hinzugefügt.`);
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
exports.addImport = addImport;
|
|
198
|
+
function removeImport(tree, filePath, packageName, importName, logMessage = true) {
|
|
199
|
+
const content = tree.read(filePath).toString();
|
|
200
|
+
const fileName = filePath.substring(filePath.lastIndexOf('/') + 1, filePath.length);
|
|
201
|
+
const sourceFile = ts.createSourceFile(`${fileName}`, content, ts.ScriptTarget.Latest, true);
|
|
202
|
+
const nodes = getSourceNodes(sourceFile);
|
|
203
|
+
const importNodes = nodes.filter((n) => n.kind === ts.SyntaxKind.ImportDeclaration);
|
|
204
|
+
if (importNodes) {
|
|
205
|
+
importNodes.forEach((importNode) => {
|
|
206
|
+
const importDeclarationChildren = importNode.getChildren();
|
|
207
|
+
if (!importDeclarationChildren) {
|
|
208
|
+
throw new schematics_1.SchematicsException(`In der Datei ${filePath} gibt es keine ImportDeclaration.`);
|
|
209
|
+
}
|
|
210
|
+
const importNameNode = importDeclarationChildren.find((n) => n.kind === ts.SyntaxKind.StringLiteral && (n.getText() === `'${packageName}'` || n.getText() === `"${packageName}"`));
|
|
211
|
+
if (importNameNode) {
|
|
212
|
+
if (importName) {
|
|
213
|
+
const importClauseNode = importNode.getChildren().find((n) => n.kind === ts.SyntaxKind.ImportClause);
|
|
214
|
+
if (!importClauseNode) {
|
|
215
|
+
throw new schematics_1.SchematicsException(`In der Datei ${filePath} gibt es keine ImportClause.`);
|
|
216
|
+
}
|
|
217
|
+
const namedImportsNode = importClauseNode.getChildren().find((n) => n.kind === ts.SyntaxKind.NamedImports);
|
|
218
|
+
if (!namedImportsNode) {
|
|
219
|
+
throw new schematics_1.SchematicsException(`In der Datei ${filePath} gibt es keine NamedImports.`);
|
|
220
|
+
}
|
|
221
|
+
const syntaxListNode = namedImportsNode.getChildren().find((n) => n.kind === ts.SyntaxKind.SyntaxList);
|
|
222
|
+
if (!syntaxListNode) {
|
|
223
|
+
throw new schematics_1.SchematicsException(`In der Datei ${filePath} gibt es keine SyntaxList.`);
|
|
224
|
+
}
|
|
225
|
+
const importChildren = syntaxListNode.getChildren();
|
|
226
|
+
if (importChildren) {
|
|
227
|
+
if (importChildren.length === 1) {
|
|
228
|
+
if (importChildren[0].getText() === importName) {
|
|
229
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
230
|
+
updateRecorder.remove(importNode.pos, importNode.getChildren()[importNode.getChildren().length - 1].end - importNode.pos);
|
|
231
|
+
tree.commitUpdate(updateRecorder);
|
|
232
|
+
if (logMessage) {
|
|
233
|
+
logging_1.logInfo(`Import ${importName} entfernt.`);
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
else {
|
|
238
|
+
for (let i = 0; i < importChildren.length; i++) {
|
|
239
|
+
if (importChildren[i].getText() === importName) {
|
|
240
|
+
const prevSibling = getPrevSibling(importChildren[i], ts.SyntaxKind.SyntaxList);
|
|
241
|
+
const nextSibling = getNextSibling(importChildren[i], ts.SyntaxKind.SyntaxList);
|
|
242
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
243
|
+
if (nextSibling) {
|
|
244
|
+
updateRecorder.remove(importChildren[i].pos, nextSibling.end - importChildren[i].pos);
|
|
245
|
+
}
|
|
246
|
+
else {
|
|
247
|
+
if (prevSibling) {
|
|
248
|
+
updateRecorder.remove(prevSibling.pos, importChildren[i].end - prevSibling.pos);
|
|
249
|
+
}
|
|
250
|
+
else {
|
|
251
|
+
updateRecorder.remove(importChildren[i].pos, importChildren[i].end - importChildren[i].pos);
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
tree.commitUpdate(updateRecorder);
|
|
255
|
+
if (logMessage) {
|
|
256
|
+
logging_1.logInfo(`Import ${importName} entfernt.`);
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
else {
|
|
264
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
265
|
+
updateRecorder.remove(importNode.pos, importNode.end - importNode.pos);
|
|
266
|
+
tree.commitUpdate(updateRecorder);
|
|
267
|
+
if (logMessage) {
|
|
268
|
+
logging_1.logInfo(`Import ${importName} entfernt.`);
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
});
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
exports.removeImport = removeImport;
|
|
276
|
+
function removeProvider(tree, filePath, providerName, logMessage = true) {
|
|
277
|
+
const content = tree.read(filePath).toString();
|
|
278
|
+
const fileName = filePath.substring(filePath.lastIndexOf('/') + 1, filePath.length);
|
|
279
|
+
const sourceFile = ts.createSourceFile(`${fileName}`, content, ts.ScriptTarget.Latest, true);
|
|
280
|
+
const nodes = getSourceNodes(sourceFile);
|
|
281
|
+
const providerIdentifierNode = nodes.find((n) => n.kind === ts.SyntaxKind.Identifier && n.getText() === 'providers');
|
|
282
|
+
if (providerIdentifierNode) {
|
|
283
|
+
const siblings = providerIdentifierNode.parent.getChildren();
|
|
284
|
+
if (siblings) {
|
|
285
|
+
const providerArrayNode = siblings.find((n) => n.kind === ts.SyntaxKind.ArrayLiteralExpression);
|
|
286
|
+
if (providerArrayNode) {
|
|
287
|
+
const providerNode = providerArrayNode.getChildren().find((n) => n.kind === ts.SyntaxKind.SyntaxList);
|
|
288
|
+
if (providerNode) {
|
|
289
|
+
const providerChildren = providerNode.getChildren();
|
|
290
|
+
if (providerChildren) {
|
|
291
|
+
for (let i = 0; i < providerChildren.length; i++) {
|
|
292
|
+
if (providerChildren[i].getText().indexOf(providerName) >= 0) {
|
|
293
|
+
const prevSibling = getPrevSibling(providerChildren[i], ts.SyntaxKind.SyntaxList);
|
|
294
|
+
const nextSibling = getNextSibling(providerChildren[i], ts.SyntaxKind.SyntaxList);
|
|
295
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
296
|
+
if (nextSibling) {
|
|
297
|
+
updateRecorder.remove(providerChildren[i].pos, nextSibling.end - providerChildren[i].pos);
|
|
298
|
+
}
|
|
299
|
+
else {
|
|
300
|
+
if (prevSibling) {
|
|
301
|
+
updateRecorder.remove(prevSibling.pos, providerChildren[i].end - prevSibling.pos);
|
|
302
|
+
}
|
|
303
|
+
else {
|
|
304
|
+
updateRecorder.remove(providerChildren[i].pos, providerChildren[i].end - providerChildren[i].pos);
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
tree.commitUpdate(updateRecorder);
|
|
308
|
+
if (logMessage) {
|
|
309
|
+
logging_1.logInfo(`Provider ${providerName} entfernt.`);
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
}
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
exports.removeProvider = removeProvider;
|
|
320
|
+
function getSiblings(node, childKind) {
|
|
321
|
+
let result = [];
|
|
322
|
+
if (node && node.parent.getChildren()) {
|
|
323
|
+
if (childKind) {
|
|
324
|
+
const childNode = node.parent.getChildren().find((child) => child.kind === childKind);
|
|
325
|
+
if (!childNode) {
|
|
326
|
+
throw new schematics_1.SchematicsException(`Es konnte kein Knoten vom Typ ${childKind} gefunden werden.`);
|
|
327
|
+
}
|
|
328
|
+
result = childNode.getChildren();
|
|
329
|
+
}
|
|
330
|
+
else {
|
|
331
|
+
result = node.parent.getChildren();
|
|
332
|
+
}
|
|
333
|
+
}
|
|
334
|
+
return result;
|
|
335
|
+
}
|
|
336
|
+
exports.getSiblings = getSiblings;
|
|
337
|
+
function getPrevSibling(node, childKind) {
|
|
338
|
+
let result = null;
|
|
339
|
+
if (node) {
|
|
340
|
+
let siblings = getSiblings(node, childKind);
|
|
341
|
+
if (siblings) {
|
|
342
|
+
const index = siblings.indexOf(node);
|
|
343
|
+
if (index > 0) {
|
|
344
|
+
result = siblings[index - 1];
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
}
|
|
348
|
+
return result;
|
|
349
|
+
}
|
|
350
|
+
exports.getPrevSibling = getPrevSibling;
|
|
351
|
+
function getNextSibling(node, childKind) {
|
|
352
|
+
let result = null;
|
|
353
|
+
if (node) {
|
|
354
|
+
let siblings = getSiblings(node, childKind);
|
|
355
|
+
if (siblings) {
|
|
356
|
+
const index = siblings.indexOf(node);
|
|
357
|
+
if (index >= 0 && index < siblings.length - 1) {
|
|
358
|
+
result = siblings[index + 1];
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
return result;
|
|
363
|
+
}
|
|
364
|
+
exports.getNextSibling = getNextSibling;
|
|
365
|
+
function getNextSiblings(node) {
|
|
366
|
+
let result = [];
|
|
367
|
+
if (node) {
|
|
368
|
+
let siblings = getSiblings(node);
|
|
369
|
+
if (siblings) {
|
|
370
|
+
const index = siblings.indexOf(node);
|
|
371
|
+
if (index >= 0 && index < siblings.length - 1) {
|
|
372
|
+
result = siblings.slice(index + 1, siblings.length - 1);
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
}
|
|
376
|
+
return result;
|
|
377
|
+
}
|
|
378
|
+
exports.getNextSiblings = getNextSiblings;
|
|
379
|
+
function showTree(node, indent = ' ') {
|
|
380
|
+
console.log(indent + ts.SyntaxKind[node.kind]);
|
|
381
|
+
if (node.getChildCount() === 0) {
|
|
382
|
+
console.log(indent + ' Text: ' + node.getText());
|
|
383
|
+
}
|
|
384
|
+
for (let child of node.getChildren()) {
|
|
385
|
+
showTree(child, indent + ' ');
|
|
386
|
+
}
|
|
387
|
+
}
|
|
388
|
+
exports.showTree = showTree;
|
|
389
|
+
function findChild(node, kind, text, depth = 100) {
|
|
390
|
+
if (node.kind === kind && (!text || node.getText() === text)) {
|
|
391
|
+
return node;
|
|
392
|
+
}
|
|
393
|
+
else {
|
|
394
|
+
for (let child of node.getChildren()) {
|
|
395
|
+
const found = findChild(child, kind, text);
|
|
396
|
+
if (found) {
|
|
397
|
+
return found;
|
|
398
|
+
}
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
return undefined;
|
|
402
|
+
}
|
|
403
|
+
exports.findChild = findChild;
|
|
404
|
+
function getSyntaxListOfClass(tree, filePath) {
|
|
405
|
+
const content = tree.read(filePath).toString();
|
|
406
|
+
const fileName = filePath.substring(filePath.lastIndexOf('/') + 1, filePath.length);
|
|
407
|
+
const sourceFile = ts.createSourceFile(`${fileName}`, content, ts.ScriptTarget.Latest, true);
|
|
408
|
+
const nodes = getSourceNodes(sourceFile);
|
|
409
|
+
const classNode = nodes.find((n) => n.kind === ts.SyntaxKind.ClassKeyword);
|
|
410
|
+
if (!classNode) {
|
|
411
|
+
throw new schematics_1.SchematicsException(`Die Klasse in der Datei ${fileName} hat kein ClassKeyword.`);
|
|
412
|
+
}
|
|
413
|
+
const firstPunctuationNode = getNextSiblings(classNode).find(n => n.kind === ts.SyntaxKind.FirstPunctuation);
|
|
414
|
+
if (!firstPunctuationNode) {
|
|
415
|
+
throw new schematics_1.SchematicsException(`Die Klasse in der Datei ${fileName} hat keine FirstPunctuation.`);
|
|
416
|
+
}
|
|
417
|
+
const syntaxListNode = getNextSibling(firstPunctuationNode);
|
|
418
|
+
if (!syntaxListNode) {
|
|
419
|
+
throw new schematics_1.SchematicsException(`Die Klasse in der Datei ${fileName} hat keine SyntaxList.`);
|
|
420
|
+
}
|
|
421
|
+
return syntaxListNode;
|
|
422
|
+
}
|
|
423
|
+
exports.getSyntaxListOfClass = getSyntaxListOfClass;
|
|
424
|
+
function getConstructor(tree, filePath) {
|
|
425
|
+
return findChild(getSyntaxListOfClass(tree, filePath), ts.SyntaxKind.Constructor);
|
|
426
|
+
}
|
|
427
|
+
exports.getConstructor = getConstructor;
|
|
428
|
+
function getMethod(tree, filePath, methodeName) {
|
|
429
|
+
return findChild(getSyntaxListOfClass(tree, filePath), ts.SyntaxKind.MethodDeclaration, methodeName);
|
|
430
|
+
}
|
|
431
|
+
exports.getMethod = getMethod;
|
|
432
|
+
function addParameter(tree, filePath, syntaxListNode, service) {
|
|
433
|
+
const parameterNodes = syntaxListNode.getChildren();
|
|
434
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
435
|
+
if (parameterNodes.length == 0) {
|
|
436
|
+
// Constructor ohne Parameter
|
|
437
|
+
updateRecorder.insertLeft(syntaxListNode.pos, service);
|
|
438
|
+
}
|
|
439
|
+
else if (parameterNodes.length > 0) {
|
|
440
|
+
// Constructor mit Parameter
|
|
441
|
+
updateRecorder.insertLeft(parameterNodes[parameterNodes.length - 1].end, ', ' + service);
|
|
442
|
+
}
|
|
443
|
+
tree.commitUpdate(updateRecorder);
|
|
444
|
+
}
|
|
445
|
+
exports.addParameter = addParameter;
|
|
446
|
+
function addMethod(tree, filePath, syntaxListNode, method) {
|
|
447
|
+
const syntaxList = getSyntaxListOfClass(tree, filePath);
|
|
448
|
+
const methodNodes = syntaxList.getChildren().filter(n => n.kind === ts.SyntaxKind.MethodDeclaration);
|
|
449
|
+
let startNode = syntaxList;
|
|
450
|
+
if (methodNodes && methodNodes.length > 0) {
|
|
451
|
+
startNode = methodNodes[methodNodes.length - 1];
|
|
452
|
+
}
|
|
453
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
454
|
+
updateRecorder.insertLeft(startNode.end, '\n' + method);
|
|
455
|
+
tree.commitUpdate(updateRecorder);
|
|
456
|
+
}
|
|
457
|
+
exports.addMethod = addMethod;
|
|
458
|
+
function addConstructorParameter(tree, filePath, service) {
|
|
459
|
+
const constructorNode = getConstructor(tree, filePath);
|
|
460
|
+
if (constructorNode) {
|
|
461
|
+
addParameter(tree, filePath, findChild(constructorNode, ts.SyntaxKind.SyntaxList), service);
|
|
462
|
+
logging_1.logInfo(`Im Konstruktor den Parameter "${service}" hinzugefügt.`);
|
|
463
|
+
}
|
|
464
|
+
else {
|
|
465
|
+
const syntaxListNode = getSyntaxListOfClass(tree, filePath);
|
|
466
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
467
|
+
updateRecorder.insertLeft(syntaxListNode.pos, `\n constructor(${service}) {}`);
|
|
468
|
+
tree.commitUpdate(updateRecorder);
|
|
469
|
+
logging_1.logInfo(`constructor(${service}) {} hinzugefügt.`);
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
exports.addConstructorParameter = addConstructorParameter;
|
|
473
|
+
function addClassProperty(tree, filePath, property) {
|
|
474
|
+
const syntaxListNode = getSyntaxListOfClass(tree, filePath);
|
|
475
|
+
if (!syntaxListNode) {
|
|
476
|
+
throw new schematics_1.SchematicsException(`Die Klasse in der Datei ${filePath} hat keine Syntaxlist.`);
|
|
477
|
+
}
|
|
478
|
+
const startNode = syntaxListNode.getChildren() && syntaxListNode.getChildren().length > 0
|
|
479
|
+
? syntaxListNode.getChildren()[0]
|
|
480
|
+
: syntaxListNode;
|
|
481
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
482
|
+
updateRecorder.insertLeft(startNode.pos, '\n\n ' + property + '\n');
|
|
483
|
+
tree.commitUpdate(updateRecorder);
|
|
484
|
+
logging_1.logInfo(`Die Property "${property}" wurde hinzugefügt.`);
|
|
485
|
+
}
|
|
486
|
+
exports.addClassProperty = addClassProperty;
|
|
487
|
+
function addConstructorContent(tree, filePath, content, append) {
|
|
488
|
+
const constructorNode = getConstructor(tree, filePath);
|
|
489
|
+
if (constructorNode) {
|
|
490
|
+
const blockNode = constructorNode.getChildren().find(n => n.kind === ts.SyntaxKind.Block);
|
|
491
|
+
if (!blockNode) {
|
|
492
|
+
throw new schematics_1.SchematicsException(`Der Konstruktor in der Klasse ${filePath} hat keinen Block.`);
|
|
493
|
+
}
|
|
494
|
+
const firstPunctuationNode = blockNode.getChildren().find(n => n.kind === ts.SyntaxKind.FirstPunctuation);
|
|
495
|
+
if (!firstPunctuationNode) {
|
|
496
|
+
throw new schematics_1.SchematicsException(`Der Konstruktor in der Klasse ${filePath} hat keine FirstPunctuation.`);
|
|
497
|
+
}
|
|
498
|
+
const syntaxListNode = getNextSibling(firstPunctuationNode);
|
|
499
|
+
if (syntaxListNode && syntaxListNode.getChildren().length > 0) {
|
|
500
|
+
const start = append ? syntaxListNode.getChildren()[syntaxListNode.getChildren().length - 1].end : syntaxListNode.getChildren()[0].pos;
|
|
501
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
502
|
+
updateRecorder.insertLeft(start, '\n ' + content);
|
|
503
|
+
tree.commitUpdate(updateRecorder);
|
|
504
|
+
}
|
|
505
|
+
else {
|
|
506
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
507
|
+
updateRecorder.insertLeft(firstPunctuationNode.end, '\n ' + content + '\n ');
|
|
508
|
+
tree.commitUpdate(updateRecorder);
|
|
509
|
+
}
|
|
510
|
+
logging_1.logInfo(`Inhalt ${append ? 'am Ende' : 'am Anfang'} des Konstruktors hinzugefügt.`);
|
|
511
|
+
}
|
|
512
|
+
else {
|
|
513
|
+
const syntaxListNode = getSyntaxListOfClass(tree, filePath);
|
|
514
|
+
const updateRecorder = tree.beginUpdate(filePath);
|
|
515
|
+
updateRecorder.insertLeft(syntaxListNode.pos, '\n\n' + ' constructor() {\n' + ' router.initialNavigation();\n' + ' }');
|
|
516
|
+
tree.commitUpdate(updateRecorder);
|
|
517
|
+
logging_1.logInfo(`Konstruktor mit Inhalt hinzugefügt.`);
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
exports.addConstructorContent = addConstructorContent;
|
|
521
|
+
//# sourceMappingURL=typescript.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"typescript.js","sourceRoot":"","sources":["typescript.ts"],"names":[],"mappings":";;;AAAA,2DAAuE;AACvE,iCAAiC;AACjC,uCAAoC;AAEpC,SAAgB,cAAc,CAAC,UAAyB;IACtD,MAAM,KAAK,GAAc,CAAC,UAAU,CAAC,CAAC;IACtC,MAAM,MAAM,GAAc,EAAE,CAAC;IAE7B,OAAO,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE;QACvB,MAAM,IAAI,GAAG,KAAK,CAAC,KAAK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