bridgelist 1.0.8 → 1.1.1
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/dist/analyzers/array-analyzer.d.ts +14 -0
- package/dist/analyzers/array-analyzer.js +103 -0
- package/dist/analyzers/array-analyzer.js.map +1 -0
- package/dist/analyzers/ast-analyzer.js +11 -65
- package/dist/analyzers/ast-analyzer.js.map +1 -1
- package/dist/analyzers/method-analyzer.d.ts +3 -2
- package/dist/analyzers/method-analyzer.js +91 -89
- package/dist/analyzers/method-analyzer.js.map +1 -1
- package/dist/analyzers/property-access-analyzer.d.ts +3 -6
- package/dist/analyzers/property-access-analyzer.js +62 -58
- package/dist/analyzers/property-access-analyzer.js.map +1 -1
- package/dist/decorators/array-documentation.d.ts +2 -0
- package/dist/decorators/array-documentation.js +9 -0
- package/dist/decorators/array-documentation.js.map +1 -0
- package/dist/decorators/mapping-documentation.js.map +1 -1
- package/dist/generators/array-list-generator.d.ts +1 -0
- package/dist/generators/array-list-generator.js +143 -0
- package/dist/generators/array-list-generator.js.map +1 -0
- package/dist/generators/doc-generator-html.d.ts +1 -0
- package/dist/generators/doc-generator-html.js +375 -0
- package/dist/generators/doc-generator-html.js.map +1 -0
- package/dist/generators/doc-output-registry.d.ts +4 -0
- package/dist/generators/doc-output-registry.js +21 -0
- package/dist/generators/doc-output-registry.js.map +1 -0
- package/dist/generators/mapping-generator.d.ts +2 -0
- package/dist/generators/mapping-generator.js +167 -0
- package/dist/generators/mapping-generator.js.map +1 -0
- package/dist/index.d.ts +9 -3
- package/dist/index.js +18 -6
- package/dist/index.js.map +1 -1
- package/dist/types/index.d.ts +6 -0
- package/dist/utils/array-scanner.d.ts +7 -0
- package/dist/utils/array-scanner.js +53 -0
- package/dist/utils/array-scanner.js.map +1 -0
- package/dist/utils/find-all-ts-files.d.ts +1 -0
- package/dist/utils/find-all-ts-files.js +25 -0
- package/dist/utils/find-all-ts-files.js.map +1 -0
- package/dist/utils/find-decorated-methods.d.ts +16 -0
- package/dist/utils/find-decorated-methods.js +103 -0
- package/dist/utils/find-decorated-methods.js.map +1 -0
- package/dist/utils/mapping-scanner.d.ts +7 -0
- package/dist/utils/mapping-scanner.js +53 -0
- package/dist/utils/mapping-scanner.js.map +1 -0
- package/docs/documentation.html +574 -0
- package/docs/relevantPropertiesArray.html +266 -0
- package/package.json +6 -3
- package/docs/example-mapping.html +0 -1170
|
@@ -0,0 +1,266 @@
|
|
|
1
|
+
|
|
2
|
+
<!DOCTYPE html>
|
|
3
|
+
<html lang="de">
|
|
4
|
+
<head>
|
|
5
|
+
<title>bridgelist</title>
|
|
6
|
+
<style>
|
|
7
|
+
* {
|
|
8
|
+
margin: 0;
|
|
9
|
+
padding: 0;
|
|
10
|
+
box-sizing: border-box;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
body {
|
|
14
|
+
font-family: Roboto, Helvetica, sans-serif;
|
|
15
|
+
padding: 2rem;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
h1 {
|
|
19
|
+
margin-bottom: 2rem;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
h2 {
|
|
23
|
+
margin: 1.5rem 0 1rem 0;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
h3, p {
|
|
27
|
+
margin-bottom: 1rem;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.header {
|
|
31
|
+
position: fixed;
|
|
32
|
+
top: 0;
|
|
33
|
+
left: 0;
|
|
34
|
+
display: flex;
|
|
35
|
+
justify-content: space-between;
|
|
36
|
+
align-items: center;
|
|
37
|
+
height: 5rem;
|
|
38
|
+
padding: 1rem 2rem;
|
|
39
|
+
background-color: #c2e5da;
|
|
40
|
+
width: 100%;
|
|
41
|
+
z-index: 100;
|
|
42
|
+
}
|
|
43
|
+
.container {
|
|
44
|
+
margin-top: 7rem;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.doc-card {
|
|
48
|
+
width: 100%;
|
|
49
|
+
display: flex;
|
|
50
|
+
flex-direction: column;
|
|
51
|
+
align-items: flex-start;
|
|
52
|
+
border: 1px solid #ddd;
|
|
53
|
+
border-radius: 5px;
|
|
54
|
+
padding: 1rem;
|
|
55
|
+
margin: 1rem 0;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.show-hide {
|
|
59
|
+
cursor: pointer;
|
|
60
|
+
padding: 1rem;
|
|
61
|
+
width: 100%;
|
|
62
|
+
background-color: #7ac29d44;
|
|
63
|
+
display: flex;
|
|
64
|
+
justify-content: flex-start;
|
|
65
|
+
gap: 1rem;
|
|
66
|
+
align-items: center;
|
|
67
|
+
user-select: none;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.show-hide.array {
|
|
71
|
+
background-color: #f9dcbe44;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.collapse {
|
|
75
|
+
width: 24px;
|
|
76
|
+
height: 24px;
|
|
77
|
+
border: 1px solid #000;
|
|
78
|
+
border-radius: 50%;
|
|
79
|
+
display: flex;
|
|
80
|
+
justify-content: center;
|
|
81
|
+
align-items: center;
|
|
82
|
+
pointer-events: none;
|
|
83
|
+
}
|
|
84
|
+
.rotate {
|
|
85
|
+
transform: rotate(180deg);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.hidden {
|
|
89
|
+
display: none;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
input[type="text"] {
|
|
93
|
+
padding: 0.5rem;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.class-method {
|
|
97
|
+
width: 100%;
|
|
98
|
+
display: flex;
|
|
99
|
+
justify-content: space-between;
|
|
100
|
+
align-items: center;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.class-method-col {
|
|
104
|
+
width: 33%;
|
|
105
|
+
display: flex;
|
|
106
|
+
flex-direction: column;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.styled-text {
|
|
110
|
+
font-size: 1.2rem;
|
|
111
|
+
font-weight: lighter;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
table {
|
|
115
|
+
border-collapse: collapse;
|
|
116
|
+
width: 100%;
|
|
117
|
+
margin: 1rem 0;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
th, td {
|
|
121
|
+
border: 1px solid #ddd;
|
|
122
|
+
padding: 8px;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
th {
|
|
126
|
+
background-color: #f2f2f2;
|
|
127
|
+
text-align: left;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.arrow {
|
|
131
|
+
color: #666;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.constant-value {
|
|
135
|
+
background-color: #f9dcbe44;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
.transformed-value {
|
|
139
|
+
background-color: #dae6e366;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
ul.array-list {
|
|
143
|
+
list-style-type: none;
|
|
144
|
+
padding: 0;
|
|
145
|
+
width: 100%;
|
|
146
|
+
margin-top: 1rem;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
li.array-item {
|
|
150
|
+
padding: 0.75rem 1rem;
|
|
151
|
+
margin-bottom: 0.5rem;
|
|
152
|
+
border: 1px solid #ddd;
|
|
153
|
+
border-radius: 5px;
|
|
154
|
+
background-color: #f9f9f9;
|
|
155
|
+
width: 100%;
|
|
156
|
+
overflow-x: auto;
|
|
157
|
+
white-space: pre;
|
|
158
|
+
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
@media (max-width: 1024px) {
|
|
162
|
+
.last { display: none; }
|
|
163
|
+
}
|
|
164
|
+
</style>
|
|
165
|
+
</head>
|
|
166
|
+
<body>
|
|
167
|
+
<div class="header">
|
|
168
|
+
<h1 style="margin: 0; flex: 1">bridgelist</h1>
|
|
169
|
+
<input style="flex: 1;"
|
|
170
|
+
type="text"
|
|
171
|
+
id="searchInput"
|
|
172
|
+
name="search"
|
|
173
|
+
size="30"
|
|
174
|
+
placeholder="Search for title, method or class..." />
|
|
175
|
+
<div style="flex: 1"></div>
|
|
176
|
+
</div>
|
|
177
|
+
|
|
178
|
+
<div class="container">
|
|
179
|
+
<h2>Arrays</h2><div class="doc-card doc-entry">
|
|
180
|
+
<div class="class-method">
|
|
181
|
+
<div class="class-method-col">
|
|
182
|
+
<span class="styled-text">Class:</span><h3>SanivisionRestCustomerParser</h3>
|
|
183
|
+
</div>
|
|
184
|
+
<div class="class-method-col">
|
|
185
|
+
<span class="styled-text">Method:</span><h3>removeAllIrrelevantProperties</h3>
|
|
186
|
+
</div>
|
|
187
|
+
<div class="class-method-col last"></div>
|
|
188
|
+
</div><span class="styled-text">Title:</span><h3>Relevant Properties</h3>
|
|
189
|
+
<p>Properties, nach denen das Ergebnis gefiltert wird</p>
|
|
190
|
+
|
|
191
|
+
<div class="show-hide array">
|
|
192
|
+
<div class="collapse">
|
|
193
|
+
<svg width="800px" height="800px" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
194
|
+
<g id="Arrow / Caret_Down_MD">
|
|
195
|
+
<path id="Vector" d="M16 10L12 14L8 10" stroke="#000000" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
196
|
+
</g>
|
|
197
|
+
</svg>
|
|
198
|
+
</div>
|
|
199
|
+
<span>Array-Liste (<strong>54</strong>)</span>
|
|
200
|
+
</div>
|
|
201
|
+
|
|
202
|
+
<div class="array-list hidden">
|
|
203
|
+
<input style="flex: 1; margin-top: 1rem; margin-bottom: 1rem;"
|
|
204
|
+
type="text"
|
|
205
|
+
id="fieldSearch"
|
|
206
|
+
name="fieldSearch"
|
|
207
|
+
size="30"
|
|
208
|
+
placeholder="Search for field..." />
|
|
209
|
+
<ul>
|
|
210
|
+
<li class="array-item"><span class="item-index">[0] </span><span class="list-item">process.env.HUBSPOT_ID_FIELD ?? 'erp_id__kontakt_'</span></li><li class="array-item"><span class="item-index">[1] </span><span class="list-item">hubspot2x_auto_stammid</span></li><li class="array-item"><span class="item-index">[2] </span><span class="list-item">hubspot2x_auto_matchcode</span></li><li class="array-item"><span class="item-index">[3] </span><span class="list-item">firstname</span></li><li class="array-item"><span class="item-index">[4] </span><span class="list-item">lastname</span></li><li class="array-item"><span class="item-index">[5] </span><span class="list-item">hubspot2x_auto_name1</span></li><li class="array-item"><span class="item-index">[6] </span><span class="list-item">hubspot2x_auto_name2</span></li><li class="array-item"><span class="item-index">[7] </span><span class="list-item">hubspot2x_auto_name3</span></li><li class="array-item"><span class="item-index">[8] </span><span class="list-item">hubspot2x_auto_strasse</span></li><li class="array-item"><span class="item-index">[9] </span><span class="list-item">stra_e</span></li><li class="array-item"><span class="item-index">[10] </span><span class="list-item">zip</span></li><li class="array-item"><span class="item-index">[11] </span><span class="list-item">city</span></li><li class="array-item"><span class="item-index">[12] </span><span class="list-item">ort</span></li><li class="array-item"><span class="item-index">[13] </span><span class="list-item">hubspot2x_auto_plz</span></li><li class="array-item"><span class="item-index">[14] </span><span class="list-item">hubspot2x_auto_ort</span></li><li class="array-item"><span class="item-index">[15] </span><span class="list-item">homepage</span></li><li class="array-item"><span class="item-index">[16] </span><span class="list-item">hubspot2x_auto_homepage</span></li><li class="array-item"><span class="item-index">[17] </span><span class="list-item">geburtsdatum__kunde_</span></li><li class="array-item"><span class="item-index">[18] </span><span class="list-item">hubspot2x_auto_geburtsdatum</span></li><li class="array-item"><span class="item-index">[19] </span><span class="list-item">zuzahlungsbefreit_ab</span></li><li class="array-item"><span class="item-index">[20] </span><span class="list-item">zuzahlungsbefreit_bis_</span></li><li class="array-item"><span class="item-index">[21] </span><span class="list-item">zuzahlungsbefreiung_minderjaehrigen</span></li><li class="array-item"><span class="item-index">[22] </span><span class="list-item">zuzahlungsbefreiung_manuell</span></li><li class="array-item"><span class="item-index">[23] </span><span class="list-item">salutation</span></li><li class="array-item"><span class="item-index">[24] </span><span class="list-item">hubspot2x_auto_anrede</span></li><li class="array-item"><span class="item-index">[25] </span><span class="list-item">ik_nummer</span></li><li class="array-item"><span class="item-index">[26] </span><span class="list-item">datenschutzerklarung_liegt_vor</span></li><li class="array-item"><span class="item-index">[27] </span><span class="list-item">hubspot2x_auto_dserklaerungvorhanden</span></li><li class="array-item"><span class="item-index">[28] </span><span class="list-item">abweichende_rechnungsanschrift_</span></li><li class="array-item"><span class="item-index">[29] </span><span class="list-item">abweichende_lieferanschrift_</span></li><li class="array-item"><span class="item-index">[30] </span><span class="list-item">abw_lieferanschrift_erp_id</span></li><li class="array-item"><span class="item-index">[31] </span><span class="list-item">abw_rechnungsanschrift_erp_id</span></li><li class="array-item"><span class="item-index">[32] </span><span class="list-item">abw__lieferanschrift_vorname</span></li><li class="array-item"><span class="item-index">[33] </span><span class="list-item">abw__lieferanschrift_nachname</span></li><li class="array-item"><span class="item-index">[34] </span><span class="list-item">abw__lieferanschrift_stra_e__hausnummer</span></li><li class="array-item"><span class="item-index">[35] </span><span class="list-item">abw__lieferanschrift_postleitzahl</span></li><li class="array-item"><span class="item-index">[36] </span><span class="list-item">abw__lieferanschrift_ort</span></li><li class="array-item"><span class="item-index">[37] </span><span class="list-item">abw__rechnungsanschrift_vorname</span></li><li class="array-item"><span class="item-index">[38] </span><span class="list-item">abw__rechnungsanschrift_nachname</span></li><li class="array-item"><span class="item-index">[39] </span><span class="list-item">abw__rechnungsanschrift_stra_e__hausnummer</span></li><li class="array-item"><span class="item-index">[40] </span><span class="list-item">abw__rechnungsanschrift_postleitzahl</span></li><li class="array-item"><span class="item-index">[41] </span><span class="list-item">abw__rechnungsanschrift_ort</span></li><li class="array-item"><span class="item-index">[42] </span><span class="list-item">ansprechpartner_changed</span></li><li class="array-item"><span class="item-index">[43] </span><span class="list-item">ansprechpartner_erp_id</span></li><li class="array-item"><span class="item-index">[44] </span><span class="list-item">herkunft_der_daten__erp_</span></li><li class="array-item"><span class="item-index">[45] </span><span class="list-item">zustaendiger_aussendienst_name</span></li><li class="array-item"><span class="item-index">[46] </span><span class="list-item">zustaendiger_aussendienst</span></li><li class="array-item"><span class="item-index">[47] </span><span class="list-item">hubspot2x_auto_zustaendiger_aussendienst</span></li><li class="array-item"><span class="item-index">[48] </span><span class="list-item">vermittler_id</span></li><li class="array-item"><span class="item-index">[49] </span><span class="list-item">transfer_zum_erp</span></li><li class="array-item"><span class="item-index">[50] </span><span class="list-item">transfer_failed</span></li><li class="array-item"><span class="item-index">[51] </span><span class="list-item">erp_transfer_error_message</span></li><li class="array-item"><span class="item-index">[52] </span><span class="list-item">mail_acriba</span></li><li class="array-item"><span class="item-index">[53] </span><span class="list-item">datenschutz_einwilligung__ja_nein_</span></li>
|
|
211
|
+
</ul>
|
|
212
|
+
</div>
|
|
213
|
+
</div>
|
|
214
|
+
|
|
215
|
+
</div>
|
|
216
|
+
<script>
|
|
217
|
+
const search = document.getElementById('searchInput');
|
|
218
|
+
const fieldSearch = document.getElementById('fieldSearch');
|
|
219
|
+
const entries = document.querySelectorAll('.doc-entry');
|
|
220
|
+
const listItems = document.querySelectorAll('.array-item');
|
|
221
|
+
|
|
222
|
+
document.querySelectorAll('table.mapping-table tr').forEach(row => {
|
|
223
|
+
if (!row.cells || row.cells.length < 4) return;
|
|
224
|
+
const sourceField = row.cells[0].textContent || '';
|
|
225
|
+
const transformation = row.cells[3].textContent || '';
|
|
226
|
+
if (sourceField.includes('Constant value')) {
|
|
227
|
+
row.classList.add('constant-value');
|
|
228
|
+
} else if (transformation.includes('Transformed')) {
|
|
229
|
+
row.classList.add('transformed-value');
|
|
230
|
+
} else if (!sourceField.includes('Constant value') && !transformation.includes('Direct mapping')) {
|
|
231
|
+
row.classList.add('transformed-value');
|
|
232
|
+
}
|
|
233
|
+
});
|
|
234
|
+
|
|
235
|
+
search.addEventListener('input', (e) => {
|
|
236
|
+
const searchTerm = (e.target.value || '').toLowerCase();
|
|
237
|
+
entries.forEach(entry => {
|
|
238
|
+
let text = '';
|
|
239
|
+
entry.querySelectorAll('h3').forEach(h => text += (h.textContent || '').toLowerCase());
|
|
240
|
+
entry.style.display = text.includes(searchTerm) ? 'flex' : 'none';
|
|
241
|
+
});
|
|
242
|
+
});
|
|
243
|
+
|
|
244
|
+
if (fieldSearch) {
|
|
245
|
+
fieldSearch.addEventListener('input', (e) => {
|
|
246
|
+
const searchTerm = (e.target.value || '').toLowerCase();
|
|
247
|
+
listItems.forEach(item => {
|
|
248
|
+
const itemText = item.querySelector('.list-item')?.textContent.toLowerCase();
|
|
249
|
+
item.style.display = itemText.includes(searchTerm) ? '' : 'none';
|
|
250
|
+
});
|
|
251
|
+
});
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
document.querySelectorAll('.show-hide').forEach(button => {
|
|
255
|
+
button.addEventListener('click', () => {
|
|
256
|
+
const next = button.nextElementSibling;
|
|
257
|
+
const caret = button.querySelector('.collapse');
|
|
258
|
+
if (!next) return;
|
|
259
|
+
next.classList.toggle('hidden');
|
|
260
|
+
if (caret) caret.classList.toggle('rotate');
|
|
261
|
+
});
|
|
262
|
+
});
|
|
263
|
+
</script>
|
|
264
|
+
</body>
|
|
265
|
+
</html>
|
|
266
|
+
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bridgelist",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.1.1",
|
|
4
4
|
"description": "A TypeScript-based tool for automatically documenting field mappings between different API systems",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -31,8 +31,11 @@
|
|
|
31
31
|
},
|
|
32
32
|
"homepage": "https://biga.de",
|
|
33
33
|
"devDependencies": {
|
|
34
|
-
"typescript": "^5.9.2",
|
|
35
34
|
"@types/node": "^24.3.0",
|
|
36
|
-
"ts-node": "^10.9.2"
|
|
35
|
+
"ts-node": "^10.9.2",
|
|
36
|
+
"typescript": "^5.9.2"
|
|
37
|
+
},
|
|
38
|
+
"dependencies": {
|
|
39
|
+
"ts-morph": "^27.0.0"
|
|
37
40
|
}
|
|
38
41
|
}
|