@fundamental-ngx/core 0.57.0-rc.0 → 0.57.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +67 -67
- package/schematics/add-theming/index.js +0 -21
- package/schematics/add-theming/index.js.map +1 -1
- package/schematics/collection.json +0 -5
- package/schematics/migrate-to-fdb-splitter/add-btp-package.d.ts +0 -5
- package/schematics/migrate-to-fdb-splitter/add-btp-package.js +0 -24
- package/schematics/migrate-to-fdb-splitter/add-btp-package.js.map +0 -1
- package/schematics/migrate-to-fdb-splitter/get-file-dependencies.d.ts +0 -6
- package/schematics/migrate-to-fdb-splitter/get-file-dependencies.js +0 -35
- package/schematics/migrate-to-fdb-splitter/get-file-dependencies.js.map +0 -1
- package/schematics/migrate-to-fdb-splitter/index.d.ts +0 -7
- package/schematics/migrate-to-fdb-splitter/index.js +0 -14
- package/schematics/migrate-to-fdb-splitter/index.js.map +0 -1
- package/schematics/migrate-to-fdb-splitter/replace-fd-with-btp.d.ts +0 -7
- package/schematics/migrate-to-fdb-splitter/replace-fd-with-btp.js +0 -130
- package/schematics/migrate-to-fdb-splitter/replace-fd-with-btp.js.map +0 -1
- package/schematics/migrate-to-fdb-splitter/replacements.d.ts +0 -1
- package/schematics/migrate-to-fdb-splitter/replacements.js +0 -17
- package/schematics/migrate-to-fdb-splitter/replacements.js.map +0 -1
- package/schematics/migrate-to-fdb-splitter/schema.d.ts +0 -3
- package/schematics/migrate-to-fdb-splitter/schema.js +0 -3
- package/schematics/migrate-to-fdb-splitter/schema.js.map +0 -1
- package/schematics/migrate-to-fdb-splitter/schema.json +0 -16
- package/schematics/migrations/migration-0-37/index.d.ts +0 -2
- package/schematics/migrations/migration-0-37/index.js +0 -126
- package/schematics/migrations/migration-0-37/index.js.map +0 -1
- package/schematics/migrations/migration-0-39/index.d.ts +0 -2
- package/schematics/migrations/migration-0-39/index.js +0 -59
- package/schematics/migrations/migration-0-39/index.js.map +0 -1
- package/schematics/migrations.json +0 -14
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fundamental-ngx/core",
|
|
3
|
-
"version": "0.57.0
|
|
3
|
+
"version": "0.57.0",
|
|
4
4
|
"schematics": "./schematics/collection.json",
|
|
5
5
|
"ng-update": {
|
|
6
6
|
"migrations": "./schematics/migrations.json"
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"@angular/forms": "^20.0.0",
|
|
24
24
|
"@angular/platform-browser": "^20.0.0",
|
|
25
25
|
"@angular/router": "^20.0.0",
|
|
26
|
-
"@fundamental-ngx/cdk": "0.57.0
|
|
27
|
-
"@fundamental-ngx/i18n": "0.57.0
|
|
26
|
+
"@fundamental-ngx/cdk": "0.57.0",
|
|
27
|
+
"@fundamental-ngx/i18n": "0.57.0",
|
|
28
28
|
"@sap-theming/theming-base-content": "^11.30.0",
|
|
29
29
|
"fundamental-styles": "0.40.1",
|
|
30
30
|
"rxjs": "^7.8.0"
|
|
@@ -71,14 +71,14 @@
|
|
|
71
71
|
"types": "./bar/index.d.ts",
|
|
72
72
|
"default": "./fesm2022/fundamental-ngx-core-bar.mjs"
|
|
73
73
|
},
|
|
74
|
-
"./breadcrumb": {
|
|
75
|
-
"types": "./breadcrumb/index.d.ts",
|
|
76
|
-
"default": "./fesm2022/fundamental-ngx-core-breadcrumb.mjs"
|
|
77
|
-
},
|
|
78
74
|
"./busy-indicator": {
|
|
79
75
|
"types": "./busy-indicator/index.d.ts",
|
|
80
76
|
"default": "./fesm2022/fundamental-ngx-core-busy-indicator.mjs"
|
|
81
77
|
},
|
|
78
|
+
"./breadcrumb": {
|
|
79
|
+
"types": "./breadcrumb/index.d.ts",
|
|
80
|
+
"default": "./fesm2022/fundamental-ngx-core-breadcrumb.mjs"
|
|
81
|
+
},
|
|
82
82
|
"./button": {
|
|
83
83
|
"types": "./button/index.d.ts",
|
|
84
84
|
"default": "./fesm2022/fundamental-ngx-core-button.mjs"
|
|
@@ -91,14 +91,14 @@
|
|
|
91
91
|
"types": "./card/index.d.ts",
|
|
92
92
|
"default": "./fesm2022/fundamental-ngx-core-card.mjs"
|
|
93
93
|
},
|
|
94
|
-
"./carousel": {
|
|
95
|
-
"types": "./carousel/index.d.ts",
|
|
96
|
-
"default": "./fesm2022/fundamental-ngx-core-carousel.mjs"
|
|
97
|
-
},
|
|
98
94
|
"./checkbox": {
|
|
99
95
|
"types": "./checkbox/index.d.ts",
|
|
100
96
|
"default": "./fesm2022/fundamental-ngx-core-checkbox.mjs"
|
|
101
97
|
},
|
|
98
|
+
"./carousel": {
|
|
99
|
+
"types": "./carousel/index.d.ts",
|
|
100
|
+
"default": "./fesm2022/fundamental-ngx-core-carousel.mjs"
|
|
101
|
+
},
|
|
102
102
|
"./combobox": {
|
|
103
103
|
"types": "./combobox/index.d.ts",
|
|
104
104
|
"default": "./fesm2022/fundamental-ngx-core-combobox.mjs"
|
|
@@ -131,34 +131,42 @@
|
|
|
131
131
|
"types": "./dynamic-side-content/index.d.ts",
|
|
132
132
|
"default": "./fesm2022/fundamental-ngx-core-dynamic-side-content.mjs"
|
|
133
133
|
},
|
|
134
|
-
"./
|
|
135
|
-
"types": "./
|
|
136
|
-
"default": "./fesm2022/fundamental-ngx-core-
|
|
134
|
+
"./feed-list-item": {
|
|
135
|
+
"types": "./feed-list-item/index.d.ts",
|
|
136
|
+
"default": "./fesm2022/fundamental-ngx-core-feed-list-item.mjs"
|
|
137
137
|
},
|
|
138
138
|
"./feed-input": {
|
|
139
139
|
"types": "./feed-input/index.d.ts",
|
|
140
140
|
"default": "./fesm2022/fundamental-ngx-core-feed-input.mjs"
|
|
141
141
|
},
|
|
142
|
+
"./facets": {
|
|
143
|
+
"types": "./facets/index.d.ts",
|
|
144
|
+
"default": "./fesm2022/fundamental-ngx-core-facets.mjs"
|
|
145
|
+
},
|
|
142
146
|
"./file-uploader": {
|
|
143
147
|
"types": "./file-uploader/index.d.ts",
|
|
144
148
|
"default": "./fesm2022/fundamental-ngx-core-file-uploader.mjs"
|
|
145
149
|
},
|
|
146
|
-
"./fixed-card-layout": {
|
|
147
|
-
"types": "./fixed-card-layout/index.d.ts",
|
|
148
|
-
"default": "./fesm2022/fundamental-ngx-core-fixed-card-layout.mjs"
|
|
149
|
-
},
|
|
150
150
|
"./flexible-column-layout": {
|
|
151
151
|
"types": "./flexible-column-layout/index.d.ts",
|
|
152
152
|
"default": "./fesm2022/fundamental-ngx-core-flexible-column-layout.mjs"
|
|
153
153
|
},
|
|
154
|
-
"./
|
|
155
|
-
"types": "./
|
|
156
|
-
"default": "./fesm2022/fundamental-ngx-core-
|
|
154
|
+
"./fixed-card-layout": {
|
|
155
|
+
"types": "./fixed-card-layout/index.d.ts",
|
|
156
|
+
"default": "./fesm2022/fundamental-ngx-core-fixed-card-layout.mjs"
|
|
157
157
|
},
|
|
158
158
|
"./formatted-text": {
|
|
159
159
|
"types": "./formatted-text/index.d.ts",
|
|
160
160
|
"default": "./fesm2022/fundamental-ngx-core-formatted-text.mjs"
|
|
161
161
|
},
|
|
162
|
+
"./generic-tag": {
|
|
163
|
+
"types": "./generic-tag/index.d.ts",
|
|
164
|
+
"default": "./fesm2022/fundamental-ngx-core-generic-tag.mjs"
|
|
165
|
+
},
|
|
166
|
+
"./form": {
|
|
167
|
+
"types": "./form/index.d.ts",
|
|
168
|
+
"default": "./fesm2022/fundamental-ngx-core-form.mjs"
|
|
169
|
+
},
|
|
162
170
|
"./grid-list": {
|
|
163
171
|
"types": "./grid-list/index.d.ts",
|
|
164
172
|
"default": "./fesm2022/fundamental-ngx-core-grid-list.mjs"
|
|
@@ -171,14 +179,6 @@
|
|
|
171
179
|
"types": "./illustrated-message/index.d.ts",
|
|
172
180
|
"default": "./fesm2022/fundamental-ngx-core-illustrated-message.mjs"
|
|
173
181
|
},
|
|
174
|
-
"./generic-tag": {
|
|
175
|
-
"types": "./generic-tag/index.d.ts",
|
|
176
|
-
"default": "./fesm2022/fundamental-ngx-core-generic-tag.mjs"
|
|
177
|
-
},
|
|
178
|
-
"./feed-list-item": {
|
|
179
|
-
"types": "./feed-list-item/index.d.ts",
|
|
180
|
-
"default": "./fesm2022/fundamental-ngx-core-feed-list-item.mjs"
|
|
181
|
-
},
|
|
182
182
|
"./infinite-scroll": {
|
|
183
183
|
"types": "./infinite-scroll/index.d.ts",
|
|
184
184
|
"default": "./fesm2022/fundamental-ngx-core-infinite-scroll.mjs"
|
|
@@ -191,26 +191,30 @@
|
|
|
191
191
|
"types": "./inline-help/index.d.ts",
|
|
192
192
|
"default": "./fesm2022/fundamental-ngx-core-inline-help.mjs"
|
|
193
193
|
},
|
|
194
|
+
"./layout-grid": {
|
|
195
|
+
"types": "./layout-grid/index.d.ts",
|
|
196
|
+
"default": "./fesm2022/fundamental-ngx-core-layout-grid.mjs"
|
|
197
|
+
},
|
|
194
198
|
"./input-group": {
|
|
195
199
|
"types": "./input-group/index.d.ts",
|
|
196
200
|
"default": "./fesm2022/fundamental-ngx-core-input-group.mjs"
|
|
197
201
|
},
|
|
198
|
-
"./layout-panel": {
|
|
199
|
-
"types": "./layout-panel/index.d.ts",
|
|
200
|
-
"default": "./fesm2022/fundamental-ngx-core-layout-panel.mjs"
|
|
201
|
-
},
|
|
202
202
|
"./link": {
|
|
203
203
|
"types": "./link/index.d.ts",
|
|
204
204
|
"default": "./fesm2022/fundamental-ngx-core-link.mjs"
|
|
205
205
|
},
|
|
206
|
-
"./layout-
|
|
207
|
-
"types": "./layout-
|
|
208
|
-
"default": "./fesm2022/fundamental-ngx-core-layout-
|
|
206
|
+
"./layout-panel": {
|
|
207
|
+
"types": "./layout-panel/index.d.ts",
|
|
208
|
+
"default": "./fesm2022/fundamental-ngx-core-layout-panel.mjs"
|
|
209
209
|
},
|
|
210
210
|
"./list": {
|
|
211
211
|
"types": "./list/index.d.ts",
|
|
212
212
|
"default": "./fesm2022/fundamental-ngx-core-list.mjs"
|
|
213
213
|
},
|
|
214
|
+
"./message-page": {
|
|
215
|
+
"types": "./message-page/index.d.ts",
|
|
216
|
+
"default": "./fesm2022/fundamental-ngx-core-message-page.mjs"
|
|
217
|
+
},
|
|
214
218
|
"./menu": {
|
|
215
219
|
"types": "./menu/index.d.ts",
|
|
216
220
|
"default": "./fesm2022/fundamental-ngx-core-menu.mjs"
|
|
@@ -219,10 +223,6 @@
|
|
|
219
223
|
"types": "./message-box/index.d.ts",
|
|
220
224
|
"default": "./fesm2022/fundamental-ngx-core-message-box.mjs"
|
|
221
225
|
},
|
|
222
|
-
"./message-page": {
|
|
223
|
-
"types": "./message-page/index.d.ts",
|
|
224
|
-
"default": "./fesm2022/fundamental-ngx-core-message-page.mjs"
|
|
225
|
-
},
|
|
226
226
|
"./message-strip": {
|
|
227
227
|
"types": "./message-strip/index.d.ts",
|
|
228
228
|
"default": "./fesm2022/fundamental-ngx-core-message-strip.mjs"
|
|
@@ -243,30 +243,30 @@
|
|
|
243
243
|
"types": "./multi-combobox/index.d.ts",
|
|
244
244
|
"default": "./fesm2022/fundamental-ngx-core-multi-combobox.mjs"
|
|
245
245
|
},
|
|
246
|
-
"./multi-input": {
|
|
247
|
-
"types": "./multi-input/index.d.ts",
|
|
248
|
-
"default": "./fesm2022/fundamental-ngx-core-multi-input.mjs"
|
|
249
|
-
},
|
|
250
246
|
"./nested-list": {
|
|
251
247
|
"types": "./nested-list/index.d.ts",
|
|
252
248
|
"default": "./fesm2022/fundamental-ngx-core-nested-list.mjs"
|
|
253
249
|
},
|
|
254
|
-
"./
|
|
255
|
-
"types": "./
|
|
256
|
-
"default": "./fesm2022/fundamental-ngx-core-
|
|
250
|
+
"./multi-input": {
|
|
251
|
+
"types": "./multi-input/index.d.ts",
|
|
252
|
+
"default": "./fesm2022/fundamental-ngx-core-multi-input.mjs"
|
|
257
253
|
},
|
|
258
254
|
"./object-attribute": {
|
|
259
255
|
"types": "./object-attribute/index.d.ts",
|
|
260
256
|
"default": "./fesm2022/fundamental-ngx-core-object-attribute.mjs"
|
|
261
257
|
},
|
|
262
|
-
"./
|
|
263
|
-
"types": "./
|
|
264
|
-
"default": "./fesm2022/fundamental-ngx-core-
|
|
258
|
+
"./notification": {
|
|
259
|
+
"types": "./notification/index.d.ts",
|
|
260
|
+
"default": "./fesm2022/fundamental-ngx-core-notification.mjs"
|
|
265
261
|
},
|
|
266
262
|
"./object-marker": {
|
|
267
263
|
"types": "./object-marker/index.d.ts",
|
|
268
264
|
"default": "./fesm2022/fundamental-ngx-core-object-marker.mjs"
|
|
269
265
|
},
|
|
266
|
+
"./object-identifier": {
|
|
267
|
+
"types": "./object-identifier/index.d.ts",
|
|
268
|
+
"default": "./fesm2022/fundamental-ngx-core-object-identifier.mjs"
|
|
269
|
+
},
|
|
270
270
|
"./object-number": {
|
|
271
271
|
"types": "./object-number/index.d.ts",
|
|
272
272
|
"default": "./fesm2022/fundamental-ngx-core-object-number.mjs"
|
|
@@ -283,6 +283,10 @@
|
|
|
283
283
|
"types": "./pagination/index.d.ts",
|
|
284
284
|
"default": "./fesm2022/fundamental-ngx-core-pagination.mjs"
|
|
285
285
|
},
|
|
286
|
+
"./panel": {
|
|
287
|
+
"types": "./panel/index.d.ts",
|
|
288
|
+
"default": "./fesm2022/fundamental-ngx-core-panel.mjs"
|
|
289
|
+
},
|
|
286
290
|
"./popover": {
|
|
287
291
|
"types": "./popover/index.d.ts",
|
|
288
292
|
"default": "./fesm2022/fundamental-ngx-core-popover.mjs"
|
|
@@ -295,10 +299,6 @@
|
|
|
295
299
|
"types": "./progress-indicator/index.d.ts",
|
|
296
300
|
"default": "./fesm2022/fundamental-ngx-core-progress-indicator.mjs"
|
|
297
301
|
},
|
|
298
|
-
"./panel": {
|
|
299
|
-
"types": "./panel/index.d.ts",
|
|
300
|
-
"default": "./fesm2022/fundamental-ngx-core-panel.mjs"
|
|
301
|
-
},
|
|
302
302
|
"./quick-view": {
|
|
303
303
|
"types": "./quick-view/index.d.ts",
|
|
304
304
|
"default": "./fesm2022/fundamental-ngx-core-quick-view.mjs"
|
|
@@ -307,10 +307,6 @@
|
|
|
307
307
|
"types": "./radio/index.d.ts",
|
|
308
308
|
"default": "./fesm2022/fundamental-ngx-core-radio.mjs"
|
|
309
309
|
},
|
|
310
|
-
"./rating-indicator": {
|
|
311
|
-
"types": "./rating-indicator/index.d.ts",
|
|
312
|
-
"default": "./fesm2022/fundamental-ngx-core-rating-indicator.mjs"
|
|
313
|
-
},
|
|
314
310
|
"./resizable-card-layout": {
|
|
315
311
|
"types": "./resizable-card-layout/index.d.ts",
|
|
316
312
|
"default": "./fesm2022/fundamental-ngx-core-resizable-card-layout.mjs"
|
|
@@ -403,13 +399,17 @@
|
|
|
403
399
|
"types": "./time-picker/index.d.ts",
|
|
404
400
|
"default": "./fesm2022/fundamental-ngx-core-time-picker.mjs"
|
|
405
401
|
},
|
|
402
|
+
"./title": {
|
|
403
|
+
"types": "./title/index.d.ts",
|
|
404
|
+
"default": "./fesm2022/fundamental-ngx-core-title.mjs"
|
|
405
|
+
},
|
|
406
406
|
"./timeline": {
|
|
407
407
|
"types": "./timeline/index.d.ts",
|
|
408
408
|
"default": "./fesm2022/fundamental-ngx-core-timeline.mjs"
|
|
409
409
|
},
|
|
410
|
-
"./
|
|
411
|
-
"types": "./
|
|
412
|
-
"default": "./fesm2022/fundamental-ngx-core-
|
|
410
|
+
"./rating-indicator": {
|
|
411
|
+
"types": "./rating-indicator/index.d.ts",
|
|
412
|
+
"default": "./fesm2022/fundamental-ngx-core-rating-indicator.mjs"
|
|
413
413
|
},
|
|
414
414
|
"./token": {
|
|
415
415
|
"types": "./token/index.d.ts",
|
|
@@ -423,17 +423,17 @@
|
|
|
423
423
|
"types": "./tree/index.d.ts",
|
|
424
424
|
"default": "./fesm2022/fundamental-ngx-core-tree.mjs"
|
|
425
425
|
},
|
|
426
|
-
"./
|
|
427
|
-
"types": "./
|
|
428
|
-
"default": "./fesm2022/fundamental-ngx-core-
|
|
426
|
+
"./upload-collection": {
|
|
427
|
+
"types": "./upload-collection/index.d.ts",
|
|
428
|
+
"default": "./fesm2022/fundamental-ngx-core-upload-collection.mjs"
|
|
429
429
|
},
|
|
430
430
|
"./utils": {
|
|
431
431
|
"types": "./utils/index.d.ts",
|
|
432
432
|
"default": "./fesm2022/fundamental-ngx-core-utils.mjs"
|
|
433
433
|
},
|
|
434
|
-
"./
|
|
435
|
-
"types": "./
|
|
436
|
-
"default": "./fesm2022/fundamental-ngx-core-
|
|
434
|
+
"./user-menu": {
|
|
435
|
+
"types": "./user-menu/index.d.ts",
|
|
436
|
+
"default": "./fesm2022/fundamental-ngx-core-user-menu.mjs"
|
|
437
437
|
},
|
|
438
438
|
"./vertical-navigation": {
|
|
439
439
|
"types": "./vertical-navigation/index.d.ts",
|
|
@@ -25,7 +25,6 @@ function addTheming(options) {
|
|
|
25
25
|
if (options.theme === 'custom') {
|
|
26
26
|
return;
|
|
27
27
|
}
|
|
28
|
-
const workspace = yield (0, workspace_1.getWorkspaceDefinition)(tree);
|
|
29
28
|
context.logger.info(`⚠️ Currently, we don't automatically remove the deprecated Themes approach. If you have it applied you have to remove it by yourself.
|
|
30
29
|
[Instructions: https://sap.github.io/fundamental-ngx/#/core/theming]`);
|
|
31
30
|
const buildTarget = yield (0, workspace_1.getProjectBuildTarget)(tree, options.project);
|
|
@@ -57,26 +56,6 @@ Try to replace theme in application manually, or use ThemingService to manage mu
|
|
|
57
56
|
return;
|
|
58
57
|
}
|
|
59
58
|
}
|
|
60
|
-
const iconFonts = ['sap_fiori_3_fonts', 'sap_horizon_fonts'];
|
|
61
|
-
let stylesUpdated = false;
|
|
62
|
-
iconFonts.forEach((font) => {
|
|
63
|
-
if (!styles.find((jsonStyle) => typeof jsonStyle === 'object' && jsonStyle.bundleName === `${font}`)) {
|
|
64
|
-
stylesUpdated = true;
|
|
65
|
-
styles.push({
|
|
66
|
-
input: `./node_modules/fundamental-styles/dist/fonts/${font}.css`,
|
|
67
|
-
inject: false,
|
|
68
|
-
bundleName: font
|
|
69
|
-
});
|
|
70
|
-
}
|
|
71
|
-
});
|
|
72
|
-
if (stylesUpdated) {
|
|
73
|
-
targetOptions.outputHashing = 'all';
|
|
74
|
-
yield (0, workspace_1.updateWorkspaceDefinition)(tree, workspace);
|
|
75
|
-
context.logger.info(`✅️ Added theming icon font styles to angular.json and set outputHashing to 'all'`);
|
|
76
|
-
}
|
|
77
|
-
else {
|
|
78
|
-
context.logger.info(`✅️ Found duplicate theming icon font styles in angular.json. Skipping.`);
|
|
79
|
-
}
|
|
80
59
|
try {
|
|
81
60
|
return (0, schematics_1.chain)([
|
|
82
61
|
() => __awaiter(this, void 0, void 0, function* () {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/core/schematics/add-theming/index.ts"],"names":[],"mappings":";;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/core/schematics/add-theming/index.ts"],"names":[],"mappings":";;;;;;;;;;;AAkBA,gCAqHC;AAtID,2DAAyD;AACzD,wDAKiC;AACjC,yDAA8D;AAE9D,gFAA2E;AAC3E,kEAA+D;AAC/D,kDAAiF;AAEjF;;;GAGG;AACH,SAAgB,UAAU,CAAC,OAAe;IACtC,OAAO,CAAO,IAAI,EAAE,OAAO,EAAE,EAAE;QAC3B,IAAI,OAAO,CAAC,KAAK,KAAK,QAAQ,EAAE,CAAC;YAC7B,OAAO;QACX,CAAC;QAED,OAAO,CAAC,MAAM,CAAC,IAAI,CACf;qEACyD,CAC5D,CAAC;QACF,MAAM,WAAW,GAAG,MAAM,IAAA,iCAAqB,EAAC,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC;QACvE,MAAM,aAAa,GAAG,WAAW,CAAC,OAAO,CAAC;QAC1C,IAAI,CAAC,aAAa,EAAE,CAAC;YACjB,OAAO,CAAC,MAAM,CAAC,IAAI,CACf,mHAAmH,OAAO,CAAC,OAAO,EAAE,CACvI,CAAC;YACF,OAAO;QACX,CAAC;QACD,MAAM,MAAM,GAAG,aAAa,CAAC,MA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EAAE,OAAO,CAAC,OAAO,CAAC,CACpD,CAAC;gCACF,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,sDAAsD,CAAC,CAAC;4BAChF,CAAC;wBACL,CAAC;oBACL,CAAC;gBACL,CAAC,CAAA;gBACD,GAAS,EAAE;oBACP,IAAI,CAAC,CAAC,MAAM,IAAA,iDAAsB,EAAC,IAAI,EAAE,OAAO,CAAC,OAAO,EAAE,oBAAoB,CAAC,CAAC,EAAE,CAAC;wBAC/E,OAAO,IAAA,kBAAK,EAAC;4BACT,IAAA,yBAAe,EACX,OAAO,CAAC,OAAO,EACf,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,CACnB,IAAI,CAAA,GAAG,QAAQ,CAAC,oBAAoB,EAAE,+BAA+B,CAAC,IAAI,CACjF;4BACD,GAAG,EAAE,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,yDAAyD,CAAC;yBACvF,CAAC,CAAC;oBACP,CAAC;oBACD,OAAO,CAAC,MAAM,CAAC,IAAI,CACf,8EAA8E,CACjF,CAAC;gBACN,CAAC,CAAA;aACJ,CAAC,CAAC;QACP,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACT,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YACxB,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC;qEACqC,CAAC,CAAC;QAC/D,CAAC;IACL,CAAC,CAAA,CAAC;AACN,CAAC"}
|
|
@@ -35,11 +35,6 @@
|
|
|
35
35
|
"factory": "./add-animations/index#addAnimations",
|
|
36
36
|
"schema": "./add-animations/schema.json",
|
|
37
37
|
"private": true
|
|
38
|
-
},
|
|
39
|
-
"migrate-to-fdb-splitter": {
|
|
40
|
-
"description": "Migrates fd-splitter to fdb-splitter",
|
|
41
|
-
"factory": "./migrate-to-fdb-splitter/index#migrateToFdbSplitter",
|
|
42
|
-
"schema": "./migrate-to-fdb-splitter/schema.json"
|
|
43
38
|
}
|
|
44
39
|
}
|
|
45
40
|
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.addBtpPackage = addBtpPackage;
|
|
4
|
-
const schematics_1 = require("@angular-devkit/schematics");
|
|
5
|
-
const tasks_1 = require("@angular-devkit/schematics/tasks");
|
|
6
|
-
const dependencies_1 = require("@schematics/angular/utility/dependencies");
|
|
7
|
-
/**
|
|
8
|
-
* Adds the @fundamental-ngx/btp package to the package.json
|
|
9
|
-
*/
|
|
10
|
-
function addBtpPackage() {
|
|
11
|
-
return (tree, ctx) => {
|
|
12
|
-
const btpVersion = (0, dependencies_1.getPackageJsonDependency)(tree, '@fundamental-ngx/btp');
|
|
13
|
-
if (btpVersion) {
|
|
14
|
-
return tree;
|
|
15
|
-
}
|
|
16
|
-
const coreVersion = (0, dependencies_1.getPackageJsonDependency)(tree, '@fundamental-ngx/core');
|
|
17
|
-
if (!coreVersion) {
|
|
18
|
-
throw new schematics_1.SchematicsException('Could not find @fundamental-ngx/core in package.json');
|
|
19
|
-
}
|
|
20
|
-
(0, dependencies_1.addPackageJsonDependency)(tree, Object.assign(Object.assign({}, coreVersion), { name: '@fundamental-ngx/btp' }));
|
|
21
|
-
ctx.addTask(new tasks_1.NodePackageInstallTask());
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
//# sourceMappingURL=add-btp-package.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"add-btp-package.js","sourceRoot":"","sources":["../../../../../libs/core/schematics/migrate-to-fdb-splitter/add-btp-package.ts"],"names":[],"mappings":";;AAOA,sCAaC;AApBD,2DAA+F;AAC/F,4DAA0E;AAC1E,2EAA8G;AAE9G;;GAEG;AACH,SAAgB,aAAa;IACzB,OAAO,CAAC,IAAU,EAAE,GAAqB,EAAE,EAAE;QACzC,MAAM,UAAU,GAAG,IAAA,uCAAwB,EAAC,IAAI,EAAE,sBAAsB,CAAC,CAAC;QAC1E,IAAI,UAAU,EAAE,CAAC;YACb,OAAO,IAAI,CAAC;QAChB,CAAC;QACD,MAAM,WAAW,GAAG,IAAA,uCAAwB,EAAC,IAAI,EAAE,uBAAuB,CAAC,CAAC;QAC5E,IAAI,CAAC,WAAW,EAAE,CAAC;YACf,MAAM,IAAI,gCAAmB,CAAC,sDAAsD,CAAC,CAAC;QAC1F,CAAC;QACD,IAAA,uCAAwB,EAAC,IAAI,kCAAO,WAAW,KAAE,IAAI,EAAE,sBAAsB,IAAG,CAAC;QACjF,GAAG,CAAC,OAAO,CAAC,IAAI,8BAAsB,EAAE,CAAC,CAAC;IAC9C,CAAC,CAAC;AACN,CAAC"}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.getFileDependencies = getFileDependencies;
|
|
13
|
-
const child_process_1 = require("child_process");
|
|
14
|
-
/**
|
|
15
|
-
* Returns the list of files that the given file depends on.
|
|
16
|
-
* @param file
|
|
17
|
-
* @param tsConfigPath
|
|
18
|
-
*/
|
|
19
|
-
function getFileDependencies(file, tsConfigPath) {
|
|
20
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const { toList: files } = yield Promise.resolve().then(() => require('dependency-tree'));
|
|
22
|
-
const tsConfig = JSON.parse((0, child_process_1.execSync)(`tsc -p ${tsConfigPath} --showConfig`).toString());
|
|
23
|
-
return files({
|
|
24
|
-
filename: file,
|
|
25
|
-
tsConfig: {
|
|
26
|
-
compilerOptions: {
|
|
27
|
-
paths: tsConfig.compilerOptions.paths
|
|
28
|
-
}
|
|
29
|
-
},
|
|
30
|
-
filter: (path) => path.indexOf('node_modules') === -1,
|
|
31
|
-
directory: process.cwd()
|
|
32
|
-
});
|
|
33
|
-
});
|
|
34
|
-
}
|
|
35
|
-
//# sourceMappingURL=get-file-dependencies.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"get-file-dependencies.js","sourceRoot":"","sources":["../../../../../libs/core/schematics/migrate-to-fdb-splitter/get-file-dependencies.ts"],"names":[],"mappings":";;;;;;;;;;;AAOA,kDAaC;AApBD,iDAAyC;AAEzC;;;;GAIG;AACH,SAAsB,mBAAmB,CAAC,IAAY,EAAE,YAAoB;;QACxE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,2CAAa,iBAAiB,EAAC,CAAC;QAC1D,MAAM,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,IAAA,wBAAQ,EAAC,UAAU,YAAY,eAAe,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;QACxF,OAAO,KAAK,CAAC;YACT,QAAQ,EAAE,IAAI;YACd,QAAQ,EAAE;gBACN,eAAe,EAAE;oBACb,KAAK,EAAE,QAAQ,CAAC,eAAe,CAAC,KAAK;iBACxC;aACJ;YACD,MAAM,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;YACrD,SAAS,EAAE,OAAO,CAAC,GAAG,EAAE;SAC3B,CAAC,CAAC;IACP,CAAC;CAAA"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { Rule } from '@angular-devkit/schematics';
|
|
2
|
-
import { MigrateToFdpSplitterSchema } from './schema';
|
|
3
|
-
/**
|
|
4
|
-
* Migrates the project to the new splitter component.
|
|
5
|
-
* @param options
|
|
6
|
-
*/
|
|
7
|
-
export declare function migrateToFdbSplitter(options: MigrateToFdpSplitterSchema): Rule;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.migrateToFdbSplitter = migrateToFdbSplitter;
|
|
4
|
-
const schematics_1 = require("@angular-devkit/schematics");
|
|
5
|
-
const add_btp_package_1 = require("./add-btp-package");
|
|
6
|
-
const replace_fd_with_btp_1 = require("./replace-fd-with-btp");
|
|
7
|
-
/**
|
|
8
|
-
* Migrates the project to the new splitter component.
|
|
9
|
-
* @param options
|
|
10
|
-
*/
|
|
11
|
-
function migrateToFdbSplitter(options) {
|
|
12
|
-
return (0, schematics_1.chain)([(0, add_btp_package_1.addBtpPackage)(), (0, replace_fd_with_btp_1.replaceFdWithBtp)(options)]);
|
|
13
|
-
}
|
|
14
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/core/schematics/migrate-to-fdb-splitter/index.ts"],"names":[],"mappings":";;AASA,oDAEC;AAXD,2DAAyD;AACzD,uDAAkD;AAClD,+DAAyD;AAGzD;;;GAGG;AACH,SAAgB,oBAAoB,CAAC,OAAmC;IACpE,OAAO,IAAA,kBAAK,EAAC,CAAC,IAAA,+BAAa,GAAE,EAAE,IAAA,sCAAgB,EAAC,OAAO,CAAC,CAAC,CAAC,CAAC;AAC/D,CAAC"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { Rule } from '@angular-devkit/schematics';
|
|
2
|
-
import { MigrateToFdpSplitterSchema } from './schema';
|
|
3
|
-
/**
|
|
4
|
-
* Migrates the project to the new splitter component.
|
|
5
|
-
* @param options
|
|
6
|
-
*/
|
|
7
|
-
export declare function replaceFdWithBtp({ project: projectName }: MigrateToFdpSplitterSchema): Rule;
|
|
@@ -1,130 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.replaceFdWithBtp = replaceFdWithBtp;
|
|
13
|
-
const schematics_1 = require("@angular-devkit/schematics");
|
|
14
|
-
const schematics_2 = require("@angular/cdk/schematics");
|
|
15
|
-
const path_1 = require("path");
|
|
16
|
-
const one_time_packages_1 = require("../utils/one-time-packages");
|
|
17
|
-
const workspace_1 = require("../utils/workspace");
|
|
18
|
-
const get_file_dependencies_1 = require("./get-file-dependencies");
|
|
19
|
-
const replacements_1 = require("./replacements");
|
|
20
|
-
const exportedElements = new Set([
|
|
21
|
-
'SplitterPaginationComponent',
|
|
22
|
-
'SplitterPaneContainerComponent',
|
|
23
|
-
'NoDefaultPanePipe',
|
|
24
|
-
'transformPaneTypeInput',
|
|
25
|
-
'PaneType',
|
|
26
|
-
'PaneTypeInput',
|
|
27
|
-
'SplitterResizerComponent',
|
|
28
|
-
'SplitterSplitPaneComponent',
|
|
29
|
-
'SplitterComponent',
|
|
30
|
-
'SplitterModule',
|
|
31
|
-
'SplitterPaneResizeEvent',
|
|
32
|
-
'SplitterPaneContainerOrientation',
|
|
33
|
-
'SplitterPaneContainerOrientationType'
|
|
34
|
-
]);
|
|
35
|
-
const replaceRegex = (content) => {
|
|
36
|
-
for (const [regex, replacement] of replacements_1.regexReplacements.entries()) {
|
|
37
|
-
content = content.replace(regex, replacement);
|
|
38
|
-
}
|
|
39
|
-
return content;
|
|
40
|
-
};
|
|
41
|
-
/**
|
|
42
|
-
* Migrates the project to the new splitter component.
|
|
43
|
-
* @param options
|
|
44
|
-
*/
|
|
45
|
-
function replaceFdWithBtp({ project: projectName }) {
|
|
46
|
-
const [install, uninstall] = (0, one_time_packages_1.oneTimePackages)(['@swc/core', 'dependency-tree']);
|
|
47
|
-
return (0, schematics_1.chain)([
|
|
48
|
-
install,
|
|
49
|
-
(tree) => __awaiter(this, void 0, void 0, function* () {
|
|
50
|
-
const { parseSync, printSync } = yield Promise.resolve().then(() => require('@swc/core'));
|
|
51
|
-
const project = yield (0, workspace_1.getProjectDefinition)(tree, projectName);
|
|
52
|
-
const mainFile = (0, schematics_2.getProjectMainFile)(project);
|
|
53
|
-
const projectBuildTargetName = yield (0, workspace_1.getProjectBuildTargetName)(tree, projectName);
|
|
54
|
-
const tsConfigPath = (0, schematics_2.getTargetTsconfigPath)(project, projectBuildTargetName);
|
|
55
|
-
const tsFilesList = (yield (0, get_file_dependencies_1.getFileDependencies)(mainFile, tsConfigPath)).map((p) => p.replace(process.cwd(), '.'));
|
|
56
|
-
tsFilesList.forEach((filePath) => {
|
|
57
|
-
const originalContent = tree.readText(filePath);
|
|
58
|
-
let newContent = replaceRegex(originalContent);
|
|
59
|
-
const parsed = parseSync(newContent, {
|
|
60
|
-
syntax: 'typescript',
|
|
61
|
-
decorators: true
|
|
62
|
-
});
|
|
63
|
-
let replaced = false;
|
|
64
|
-
parsed.body.forEach((node, index) => {
|
|
65
|
-
var _a;
|
|
66
|
-
if (node.type === 'ImportDeclaration' && node.source.value === '@fundamental-ngx/core') {
|
|
67
|
-
const specifiers = node.specifiers.filter((specifier) => specifier.type === 'ImportSpecifier' && exportedElements.has(specifier.local.value));
|
|
68
|
-
if (specifiers.length) {
|
|
69
|
-
const newImport = Object.assign({}, node);
|
|
70
|
-
newImport.specifiers = specifiers;
|
|
71
|
-
newImport.source = {
|
|
72
|
-
type: 'StringLiteral',
|
|
73
|
-
value: '@fundamental-ngx/btp/splitter',
|
|
74
|
-
span: node.source.span
|
|
75
|
-
};
|
|
76
|
-
node.specifiers = node.specifiers.filter((s) => !specifiers.includes(s));
|
|
77
|
-
parsed.body.splice(index, node.specifiers.length === 0 ? 1 : 0, newImport);
|
|
78
|
-
replaced = true;
|
|
79
|
-
}
|
|
80
|
-
return;
|
|
81
|
-
}
|
|
82
|
-
const classDeclaration = (() => {
|
|
83
|
-
if (node.type === 'ClassDeclaration') {
|
|
84
|
-
return node;
|
|
85
|
-
}
|
|
86
|
-
if (node.type === 'ExportDeclaration' && node.declaration.type === 'ClassDeclaration') {
|
|
87
|
-
return node.declaration;
|
|
88
|
-
}
|
|
89
|
-
return undefined;
|
|
90
|
-
})();
|
|
91
|
-
if (classDeclaration) {
|
|
92
|
-
const componentDecorator = (_a = classDeclaration.decorators) === null || _a === void 0 ? void 0 : _a.find((decorator) => decorator.expression.type === 'CallExpression' &&
|
|
93
|
-
decorator.expression.callee.type === 'Identifier' &&
|
|
94
|
-
decorator.expression.callee.value === 'Component');
|
|
95
|
-
if (componentDecorator) {
|
|
96
|
-
const objectExpression = componentDecorator.expression.type === 'CallExpression'
|
|
97
|
-
? componentDecorator.expression.arguments[0]
|
|
98
|
-
: undefined;
|
|
99
|
-
if ((objectExpression === null || objectExpression === void 0 ? void 0 : objectExpression.expression.type) === 'ObjectExpression') {
|
|
100
|
-
const templateUrlProperty = objectExpression === null || objectExpression === void 0 ? void 0 : objectExpression.expression.properties.find((prop) => prop.type === 'KeyValueProperty' &&
|
|
101
|
-
prop.key.type === 'Identifier' &&
|
|
102
|
-
prop.key.value === 'templateUrl');
|
|
103
|
-
const templateUrlPropertyValue = (templateUrlProperty === null || templateUrlProperty === void 0 ? void 0 : templateUrlProperty.type) === 'KeyValueProperty' &&
|
|
104
|
-
(templateUrlProperty === null || templateUrlProperty === void 0 ? void 0 : templateUrlProperty.value.type) === 'StringLiteral'
|
|
105
|
-
? templateUrlProperty.value.value
|
|
106
|
-
: undefined;
|
|
107
|
-
if (templateUrlPropertyValue) {
|
|
108
|
-
const pathToFile = (0, path_1.resolve)((0, path_1.dirname)(filePath), templateUrlPropertyValue).replace(process.cwd(), '.');
|
|
109
|
-
const originalFile = tree.readText(pathToFile);
|
|
110
|
-
const newFile = replaceRegex(originalFile);
|
|
111
|
-
if (originalFile !== newFile) {
|
|
112
|
-
tree.overwrite(pathToFile, newFile);
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
});
|
|
119
|
-
if (replaced) {
|
|
120
|
-
newContent = printSync(parsed).code;
|
|
121
|
-
}
|
|
122
|
-
if (newContent !== originalContent) {
|
|
123
|
-
tree.overwrite(filePath, newContent);
|
|
124
|
-
}
|
|
125
|
-
});
|
|
126
|
-
}),
|
|
127
|
-
uninstall
|
|
128
|
-
]);
|
|
129
|
-
}
|
|
130
|
-
//# sourceMappingURL=replace-fd-with-btp.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"replace-fd-with-btp.js","sourceRoot":"","sources":["../../../../../libs/core/schematics/migrate-to-fdb-splitter/replace-fd-with-btp.ts"],"names":[],"mappings":";;;;;;;;;;;AAoCA,4CAqGC;AAzID,2DAA+D;AAC/D,wDAAoF;AACpF,+BAAwC;AACxC,kEAA6D;AAC7D,kDAAqF;AACrF,mEAA8D;AAC9D,iDAAmD;AAGnD,MAAM,gBAAgB,GAAG,IAAI,GAAG,CAAC;IAC7B,6BAA6B;IAC7B,gCAAgC;IAChC,mBAAmB;IACnB,wBAAwB;IACxB,UAAU;IACV,eAAe;IACf,0BAA0B;IAC1B,4BAA4B;IAC5B,mBAAmB;IACnB,gBAAgB;IAChB,yBAAyB;IACzB,kC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"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const regexReplacements: Map<RegExp, string>;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.regexReplacements = void 0;
|
|
4
|
-
exports.regexReplacements = new Map([
|
|
5
|
-
[/@fundamental-ngx\/core\/splitter/g, '@fundamental-ngx/btp/splitter'],
|
|
6
|
-
[/<fd-splitter /g, '<fdb-splitter '],
|
|
7
|
-
[/<\/fd-splitter>/g, '</fdb-splitter>'],
|
|
8
|
-
[/<fd-splitter-split-pane /g, '<fdb-splitter-split-pane '],
|
|
9
|
-
[/<\/fd-splitter-split-pane>/g, '</fdb-splitter-split-pane>'],
|
|
10
|
-
[/<fd-splitter-resizer /g, '<fdb-splitter-resizer '],
|
|
11
|
-
[/<\/fd-splitter-resizer>/g, '</fdb-splitter-resizer>'],
|
|
12
|
-
[/<fd-splitter-pane-container /g, '<fdb-splitter-pane-container '],
|
|
13
|
-
[/<\/fd-splitter-pane-container>/g, '</fdb-splitter-pane-container>'],
|
|
14
|
-
[/<fd-splitter-pagination /g, '<fdb-splitter-pagination '],
|
|
15
|
-
[/<\/fd-splitter-pagination>/g, '</fdb-splitter-pagination>']
|
|
16
|
-
]);
|
|
17
|
-
//# sourceMappingURL=replacements.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"replacements.js","sourceRoot":"","sources":["../../../../../libs/core/schematics/migrate-to-fdb-splitter/replacements.ts"],"names":[],"mappings":";;;AAAa,QAAA,iBAAiB,GAAG,IAAI,GAAG,CAAiB;IACrD,CAAC,mCAAmC,EAAE,+BAA+B,CAAC;IAEtE,CAAC,gBAAgB,EAAE,gBAAgB,CAAC;IACpC,CAAC,kBAAkB,EAAE,iBAAiB,CAAC;IAEvC,CAAC,2BAA2B,EAAE,2BAA2B,CAAC;IAC1D,CAAC,6BAA6B,EAAE,4BAA4B,CAAC;IAE7D,CAAC,wBAAwB,EAAE,wBAAwB,CAAC;IACpD,CAAC,0BAA0B,EAAE,yBAAyB,CAAC;IAEvD,CAAC,+BAA+B,EAAE,+BAA+B,CAAC;IAClE,CAAC,iCAAiC,EAAE,gCAAgC,CAAC;IAErE,CAAC,2BAA2B,EAAE,2BAA2B,CAAC;IAC1D,CAAC,6BAA6B,EAAE,4BAA4B,CAAC;CAChE,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../../../libs/core/schematics/migrate-to-fdb-splitter/schema.ts"],"names":[],"mappings":""}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "http://json-schema.org/schema",
|
|
3
|
-
"$id": "fundamental-ngx-add-theming",
|
|
4
|
-
"title": "Fundamental Library for Angular add-theming schematic",
|
|
5
|
-
"type": "object",
|
|
6
|
-
"properties": {
|
|
7
|
-
"project": {
|
|
8
|
-
"type": "string",
|
|
9
|
-
"description": "The name of the project.",
|
|
10
|
-
"$default": {
|
|
11
|
-
"$source": "projectName"
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
},
|
|
15
|
-
"required": ["project"]
|
|
16
|
-
}
|
|
@@ -1,126 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.default = default_1;
|
|
13
|
-
const core_1 = require("@angular-devkit/core");
|
|
14
|
-
const schematics_1 = require("@angular-devkit/schematics");
|
|
15
|
-
const workspace_1 = require("@schematics/angular/utility/workspace");
|
|
16
|
-
const file_utils_1 = require("../../utils/file-utils");
|
|
17
|
-
function default_1() {
|
|
18
|
-
return (0, schematics_1.chain)([removeStylesFromConfig(), removeIconFonts(), removeFontStyles(), noticeAddSchematics()]);
|
|
19
|
-
}
|
|
20
|
-
function removeStylesFromConfig() {
|
|
21
|
-
return (_, context) => __awaiter(this, void 0, void 0, function* () {
|
|
22
|
-
return (0, workspace_1.updateWorkspace)((workspace) => {
|
|
23
|
-
workspace.projects.forEach((project) => {
|
|
24
|
-
project.targets.forEach((target) => {
|
|
25
|
-
var _a, _b;
|
|
26
|
-
const styles = (_a = target.options) === null || _a === void 0 ? void 0 : _a.styles;
|
|
27
|
-
if (!((_b = target.options) === null || _b === void 0 ? void 0 : _b.styles) || !styles || !(0, core_1.isJsonArray)(styles)) {
|
|
28
|
-
return;
|
|
29
|
-
}
|
|
30
|
-
const themes = [
|
|
31
|
-
'sap_horizon',
|
|
32
|
-
'sap_horizon_dark',
|
|
33
|
-
'sap_horizon_hcb',
|
|
34
|
-
'sap_horizon_hcw',
|
|
35
|
-
'sap_fiori_3',
|
|
36
|
-
'sap_fiori_3_dark',
|
|
37
|
-
'sap_fiori_3_hcb',
|
|
38
|
-
'sap_fiori_3_hcw',
|
|
39
|
-
'sap_fiori_3_light_dark'
|
|
40
|
-
];
|
|
41
|
-
const stylesToRemove = [
|
|
42
|
-
'node_modules/fundamental-styles/dist/icon.css',
|
|
43
|
-
'./node_modules/@sap-theming/theming-base-content/content/Base/baseLib/sap_fiori_3/css_variables.css',
|
|
44
|
-
'./node_modules/fundamental-styles/dist/theming/sap_fiori_3.css',
|
|
45
|
-
...themes.map((theme) => `./node_modules/@sap-theming/theming-base-content/content/Base/baseLib/${theme}/css_variables.css`),
|
|
46
|
-
...themes.map((theme) => `./node_modules/fundamental-styles/dist/theming/${theme}.css`)
|
|
47
|
-
];
|
|
48
|
-
stylesToRemove.forEach((styleToRemove) => {
|
|
49
|
-
const indexInStylesArray = styles.findIndex((configStyle) => typeof configStyle === 'string' && configStyle === styleToRemove);
|
|
50
|
-
if (indexInStylesArray > -1) {
|
|
51
|
-
styles.splice(indexInStylesArray, 1);
|
|
52
|
-
context.logger.info(`✅️ Removed '${styleToRemove}' style from angular.json`);
|
|
53
|
-
}
|
|
54
|
-
});
|
|
55
|
-
target.options.styles = styles;
|
|
56
|
-
});
|
|
57
|
-
});
|
|
58
|
-
});
|
|
59
|
-
});
|
|
60
|
-
}
|
|
61
|
-
function removeIconFonts() {
|
|
62
|
-
return (tree, context) => (0, workspace_1.updateWorkspace)((workspace) => {
|
|
63
|
-
workspace.projects.forEach((project) => {
|
|
64
|
-
project.targets.forEach((target) => {
|
|
65
|
-
var _a, _b;
|
|
66
|
-
const styles = (_a = target.options) === null || _a === void 0 ? void 0 : _a.styles;
|
|
67
|
-
if (!((_b = target.options) === null || _b === void 0 ? void 0 : _b.styles) || !styles || !(0, core_1.isJsonArray)(styles)) {
|
|
68
|
-
return;
|
|
69
|
-
}
|
|
70
|
-
const iconFonts = ['sap_fiori_3_fonts', 'sap_horizon_fonts'];
|
|
71
|
-
iconFonts.forEach((fontFile) => {
|
|
72
|
-
// Remove file
|
|
73
|
-
const fontFileWithPath = `${project.sourceRoot}/theming/${fontFile}.css`;
|
|
74
|
-
if (tree.exists(fontFileWithPath)) {
|
|
75
|
-
tree.delete(fontFileWithPath);
|
|
76
|
-
context.logger.info(`✅️ Removed ${fontFile}.css file.`);
|
|
77
|
-
}
|
|
78
|
-
// Remove from config
|
|
79
|
-
const indexInStylesArray = styles.findIndex((style) => (0, core_1.isJsonObject)(style) && (style === null || style === void 0 ? void 0 : style.bundleName) === `${fontFile}`);
|
|
80
|
-
if (indexInStylesArray > -1) {
|
|
81
|
-
styles.splice(indexInStylesArray, 1);
|
|
82
|
-
context.logger.info(`✅️ Removed '${fontFile}' style from angular.json`);
|
|
83
|
-
}
|
|
84
|
-
});
|
|
85
|
-
target.options.styles = styles;
|
|
86
|
-
});
|
|
87
|
-
});
|
|
88
|
-
});
|
|
89
|
-
}
|
|
90
|
-
function removeFontStyles() {
|
|
91
|
-
return (tree, context) => {
|
|
92
|
-
const styleSheets = (0, file_utils_1.findStylesheetFiles)(tree);
|
|
93
|
-
if (styleSheets.length > 0) {
|
|
94
|
-
const FONT_FACE_REGEX = /(@font-face)[\w\s]?{[s\S\W\w]+?(?=\s}\s)?\s?}[\n\s]*/gi;
|
|
95
|
-
styleSheets.forEach((styleSheet) => {
|
|
96
|
-
const buffer = tree.read(styleSheet);
|
|
97
|
-
if (!buffer) {
|
|
98
|
-
return;
|
|
99
|
-
}
|
|
100
|
-
let contents = buffer.toString();
|
|
101
|
-
if (FONT_FACE_REGEX.test(contents)) {
|
|
102
|
-
const matches = contents
|
|
103
|
-
.match(FONT_FACE_REGEX)
|
|
104
|
-
.filter((m) => { var _a; return (_a = m.match(/~@sap-theming.*\.woff/)) === null || _a === void 0 ? void 0 : _a.length; });
|
|
105
|
-
if (matches.length === 0) {
|
|
106
|
-
return;
|
|
107
|
-
}
|
|
108
|
-
matches.forEach((match) => {
|
|
109
|
-
contents = contents.replace(match, '');
|
|
110
|
-
});
|
|
111
|
-
tree.overwrite(styleSheet, contents);
|
|
112
|
-
context.logger.info(`✅️ Removed font styles from stylesheets.`);
|
|
113
|
-
}
|
|
114
|
-
});
|
|
115
|
-
}
|
|
116
|
-
context.logger.info(`⚠️ Notice: If you have imported font styles from @sap-theming, please remove it, since now it is controlled by fundamental-ngx`);
|
|
117
|
-
return tree;
|
|
118
|
-
};
|
|
119
|
-
}
|
|
120
|
-
function noticeAddSchematics() {
|
|
121
|
-
return (_, context) => {
|
|
122
|
-
// Unfortunately we cannot run it on our own because ng-update doesn't respect schema so there is no way to get options and pass them further
|
|
123
|
-
context.logger.info(`ℹ️ Now you have to run ng-add schematics once again to set up things in the right way.`);
|
|
124
|
-
};
|
|
125
|
-
}
|
|
126
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../libs/core/schematics/migrations/migration-0-37/index.ts"],"names":[],"mappings":";;;;;;;;;;;AAMA,4BAEC;AARD,+CAAiE;AACjE,2DAAiF;AACjF,qEAAwE;AAExE,uDAA6D;AAE7D;IACI,OAAO,IAAA,kBAAK,EAAC,CAAC,sBAAsB,EAAE,EAAE,eAAe,EAAE,EAAE,gBAAgB,EAAE,EAAE,mBAAmB,EAAE,CAAC,CAAC,CAAC;AAC3G,CAAC;AAED,SAAS,sBAAsB;IAC3B,OAAO,CAAO,CAAO,EAAE,OAAyB,EAAE,EAAE;QAChD,OAAA,IAAA,2BAAe,EAAC,CAAC,SAAS,EAAE,EAAE;YAC1B,SAAS,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;gBACnC,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,EAAE;;oBAC/B,MAAM,MAAM,GAAG,MAAA,MAAM,CAAC,OAAO,0CAAE,MAAM,CAAC;oBAEtC,IAAI,CAAC,CAAA,MAAA,MAAM,CAAC,OAAO,0CAAE,MAAM,CAAA,IAAI,CAAC,MAAM,IAAI,CAAC,IAAA,kBAAW,EAAC,MAAM,CAAC,EAAE,CAAC;wBAC7D,OAAO;oBACX,CAAC;oBAED,MAAM,MAAM,GAAG;wBACX,aAAa;wBACb,kBAAkB;wBAClB,iBAAiB;wBACjB,iBAAiB;wBACjB,aAAa;wBACb,kBAAkB;wBAClB,iBAAiB;wBACjB,iBAAiB;wBACjB,wBAAwB;qBAC3B,CAAC;oBAEF,MAAM,cAAc,GAAG;wBACnB,+CAA+C;wBAC/C,qGAAqG;wBACrG,gEAAgE;wBAChE,GAAG,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}
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.default = mySchematic;
|
|
4
|
-
const replacements = [
|
|
5
|
-
[['fdAutoComplete', 'fd-auto-complete'], 'fdkAutoComplete'],
|
|
6
|
-
[['fnClicked'], 'fdkClicked'],
|
|
7
|
-
[['fnDisabled'], 'fdkDisabled'],
|
|
8
|
-
[['fd-focus-key-manager-item', 'fdFocusKeyManagerItem'], 'fdkFocusKeyManagerItem'],
|
|
9
|
-
[['fd-focus-key-manager-list', 'fdFocusKeyManagerList'], 'fdkFocusKeyManagerList'],
|
|
10
|
-
[['fnFocusableItem'], 'fdkFocusableItem'],
|
|
11
|
-
[['fnFocusableList'], 'fdkFocusableList'],
|
|
12
|
-
[['fdIgnoreClickOnSelection', 'fd-ignore-click-on-selection'], 'fdkIgnoreClickOnSelection'],
|
|
13
|
-
[['fdInitialFocus', 'fd-initial-focus'], 'fdkInitialFocus'],
|
|
14
|
-
[['fdLineClamp', 'fd-lineclamp'], 'fdLineClamp'],
|
|
15
|
-
[['fdOnlyDigits', 'fd-only-digits'], 'fdkOnlyDigits'],
|
|
16
|
-
[['fdOverflowListItem', 'fd-overflow-list-item'], 'fdkOverflowListItem'],
|
|
17
|
-
[['fdOverflowList', 'fd-overflow-list'], 'fdkOverflowList'],
|
|
18
|
-
[['fnReadonly'], 'fdkReadonly'],
|
|
19
|
-
[['fdRepeat', 'fd-repeat'], 'fdkRepeat'],
|
|
20
|
-
[['fdResizeHandle', 'fd-resize-handle'], 'fdkResizeHandle'],
|
|
21
|
-
[['fdResize', 'fd-resize'], 'fdkResize'],
|
|
22
|
-
[['fdTemplate', 'fd-template'], 'fdkTemplate'],
|
|
23
|
-
[['fdTruncate', 'fd-truncate'], 'fdkTruncate']
|
|
24
|
-
];
|
|
25
|
-
function mySchematic() {
|
|
26
|
-
return (tree, context) => {
|
|
27
|
-
const files = getFilesWithExtension(tree, '/', 'html');
|
|
28
|
-
files.forEach((file) => {
|
|
29
|
-
var _a;
|
|
30
|
-
let fileContents = (_a = tree.read(file)) === null || _a === void 0 ? void 0 : _a.toString();
|
|
31
|
-
if (!fileContents) {
|
|
32
|
-
return;
|
|
33
|
-
}
|
|
34
|
-
replacements.forEach((replacement) => {
|
|
35
|
-
const deprecated = replacement[0];
|
|
36
|
-
const actual = replacement[1];
|
|
37
|
-
deprecated.forEach((selector) => {
|
|
38
|
-
if (!fileContents.includes(selector)) {
|
|
39
|
-
return;
|
|
40
|
-
}
|
|
41
|
-
fileContents = fileContents.split(selector).join(actual);
|
|
42
|
-
context.logger.info(`✅️ Replaced old ${selector} directive selector with current ${actual}`);
|
|
43
|
-
});
|
|
44
|
-
});
|
|
45
|
-
tree.overwrite(file, fileContents);
|
|
46
|
-
});
|
|
47
|
-
};
|
|
48
|
-
}
|
|
49
|
-
function getFilesWithExtension(tree, path, extension) {
|
|
50
|
-
const files = [];
|
|
51
|
-
const rootDir = tree.getDir(path);
|
|
52
|
-
const test = rootDir.subfiles.filter((file) => file.endsWith(`.${extension}`)).map((file) => `${path}${file}`);
|
|
53
|
-
files.push(...test);
|
|
54
|
-
rootDir.subdirs.forEach((dir) => {
|
|
55
|
-
files.push(...getFilesWithExtension(tree, `${path}${dir}/`, extension));
|
|
56
|
-
});
|
|
57
|
-
return files;
|
|
58
|
-
}
|
|
59
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../libs/core/schematics/migrations/migration-0-39/index.ts"],"names":[],"mappings":";;AAwBA,8BA6BC;AAnDD,MAAM,YAAY,GAAG;IACjB,CAAC,CAAC,gBAAgB,EAAE,kBAAkB,CAAC,EAAE,iBAAiB,CAAC;IAC3D,CAAC,CAAC,WAAW,CAAC,EAAE,YAAY,CAAC;IAC7B,CAAC,CAAC,YAAY,CAAC,EAAE,aAAa,CAAC;IAC/B,CAAC,CA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CAAC;IACpB,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,EAAE,EAAE;QAC5B,KAAK,CAAC,IAAI,CAAC,GAAG,qBAAqB,CAAC,IAAI,EAAE,GAAG,IAAI,GAAG,GAAG,GAAG,EAAE,SAAS,CAAC,CAAC,CAAC;IAC5E,CAAC,CAAC,CAAC;IAEH,OAAO,KAAK,CAAC;AACjB,CAAC"}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"schematics": {
|
|
3
|
-
"migration-0-37": {
|
|
4
|
-
"version": "0.37",
|
|
5
|
-
"description": "Removes icon font files, font styles, styles from config and notifies about necessity of running add schematics again.",
|
|
6
|
-
"factory": "./migrations/migration-0-37/index"
|
|
7
|
-
},
|
|
8
|
-
"migration-0-39": {
|
|
9
|
-
"version": "0.39",
|
|
10
|
-
"description": "Replaces old directive selector from core's package with new one from cdk package",
|
|
11
|
-
"factory": "./migrations/migration-0-39/index"
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
}
|