@ui5/webcomponents-tools 0.0.0-8db0ce01a → 0.0.0-8e1845415

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (95) hide show
  1. package/CHANGELOG.md +342 -0
  2. package/README.md +5 -6
  3. package/assets-meta.js +7 -1
  4. package/bin/dev.js +1 -5
  5. package/components-package/eslint.js +28 -0
  6. package/components-package/nps.js +83 -54
  7. package/components-package/postcss.components.js +13 -13
  8. package/components-package/postcss.themes.js +19 -16
  9. package/components-package/vite.config.js +12 -0
  10. package/components-package/wdio.js +78 -29
  11. package/components-package/wdio.sync.js +360 -0
  12. package/icons-collection/nps.js +46 -15
  13. package/lib/copy-and-watch/index.js +24 -1
  14. package/lib/copy-list/index.js +28 -0
  15. package/lib/create-icons/index.js +124 -58
  16. package/lib/create-illustrations/index.js +161 -0
  17. package/lib/create-new-component/index.js +108 -103
  18. package/lib/create-new-component/jsFileContentTemplate.js +77 -0
  19. package/lib/create-new-component/tsFileContentTemplate.js +84 -0
  20. package/lib/dev-server/dev-server.js +66 -0
  21. package/lib/dev-server/virtual-index-html-plugin.js +53 -0
  22. package/lib/esm-abs-to-rel/index.js +58 -0
  23. package/lib/generate-custom-elements-manifest/index.js +327 -0
  24. package/lib/generate-js-imports/illustrations.js +72 -0
  25. package/lib/generate-json-imports/i18n.js +38 -31
  26. package/lib/generate-json-imports/themes.js +31 -24
  27. package/lib/hbs2lit/src/compiler.js +20 -3
  28. package/lib/hbs2lit/src/includesReplacer.js +5 -5
  29. package/lib/hbs2lit/src/litVisitor2.js +77 -14
  30. package/lib/hbs2lit/src/svgProcessor.js +3 -3
  31. package/lib/hbs2ui5/RenderTemplates/LitRenderer.js +4 -11
  32. package/lib/hbs2ui5/index.js +37 -21
  33. package/lib/i18n/defaults.js +65 -57
  34. package/lib/i18n/toJSON.js +12 -11
  35. package/lib/jsdoc/configTypescript.json +29 -0
  36. package/lib/jsdoc/plugin.js +41 -0
  37. package/lib/jsdoc/preprocess.js +146 -0
  38. package/lib/jsdoc/template/publish.js +21 -2
  39. package/lib/postcss-combine-duplicated-selectors/index.js +178 -0
  40. package/lib/postcss-css-to-esm/index.js +53 -8
  41. package/lib/postcss-css-to-json/index.js +18 -2
  42. package/lib/postcss-p/postcss-p.mjs +14 -0
  43. package/lib/replace-global-core/index.js +25 -0
  44. package/lib/scoping/get-all-tags.js +1 -8
  45. package/lib/scoping/lint-src.js +1 -1
  46. package/lib/scoping/missing-dependencies.js +65 -0
  47. package/lib/scoping/report-tags-usage.js +28 -0
  48. package/lib/scoping/scope-test-pages.js +1 -1
  49. package/lib/test-runner/test-runner.js +63 -0
  50. package/package.json +28 -41
  51. package/bin/init-ui5-package.js +0 -3
  52. package/components-package/rollup.js +0 -195
  53. package/lib/documentation/index.js +0 -165
  54. package/lib/documentation/templates/api-component-since.js +0 -3
  55. package/lib/documentation/templates/api-css-variables-section.js +0 -24
  56. package/lib/documentation/templates/api-events-section.js +0 -35
  57. package/lib/documentation/templates/api-methods-section.js +0 -26
  58. package/lib/documentation/templates/api-properties-section.js +0 -40
  59. package/lib/documentation/templates/api-slots-section.js +0 -28
  60. package/lib/documentation/templates/template.js +0 -38
  61. package/lib/hash/config.js +0 -10
  62. package/lib/hash/generate.js +0 -19
  63. package/lib/hash/upToDate.js +0 -31
  64. package/lib/init-package/index.js +0 -123
  65. package/lib/init-package/resources/.eslintignore +0 -3
  66. package/lib/init-package/resources/bundle.es5.js +0 -25
  67. package/lib/init-package/resources/bundle.esm.js +0 -31
  68. package/lib/init-package/resources/config/.eslintrc.js +0 -1
  69. package/lib/init-package/resources/config/postcss.components/postcss.config.js +0 -1
  70. package/lib/init-package/resources/config/postcss.themes/postcss.config.js +0 -1
  71. package/lib/init-package/resources/config/rollup.config.js +0 -1
  72. package/lib/init-package/resources/config/wdio.conf.js +0 -1
  73. package/lib/init-package/resources/package-scripts.js +0 -11
  74. package/lib/init-package/resources/src/Assets.js +0 -5
  75. package/lib/init-package/resources/src/MyFirstComponent.hbs +0 -1
  76. package/lib/init-package/resources/src/MyFirstComponent.js +0 -56
  77. package/lib/init-package/resources/src/i18n/messagebundle.properties +0 -2
  78. package/lib/init-package/resources/src/i18n/messagebundle_de.properties +0 -1
  79. package/lib/init-package/resources/src/i18n/messagebundle_en.properties +0 -1
  80. package/lib/init-package/resources/src/i18n/messagebundle_es.properties +0 -1
  81. package/lib/init-package/resources/src/i18n/messagebundle_fr.properties +0 -1
  82. package/lib/init-package/resources/src/themes/MyFirstComponent.css +0 -11
  83. package/lib/init-package/resources/src/themes/sap_belize/parameters-bundle.css +0 -3
  84. package/lib/init-package/resources/src/themes/sap_belize_hcb/parameters-bundle.css +0 -3
  85. package/lib/init-package/resources/src/themes/sap_belize_hcw/parameters-bundle.css +0 -3
  86. package/lib/init-package/resources/src/themes/sap_fiori_3/parameters-bundle.css +0 -3
  87. package/lib/init-package/resources/src/themes/sap_fiori_3_dark/parameters-bundle.css +0 -3
  88. package/lib/init-package/resources/src/themes/sap_fiori_3_hcb/parameters-bundle.css +0 -3
  89. package/lib/init-package/resources/src/themes/sap_fiori_3_hcw/parameters-bundle.css +0 -3
  90. package/lib/init-package/resources/test/pages/index.html +0 -56
  91. package/lib/init-package/resources/test/specs/Demo.spec.js +0 -12
  92. package/lib/polyfill-placeholder/index.js +0 -5
  93. package/lib/serve/index.js +0 -46
  94. package/lib/serve/serve.json +0 -3
  95. package/package-lock.json +0 -48
package/CHANGELOG.md CHANGED
@@ -3,6 +3,348 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [1.12.0-rc.0](https://github.com/SAP/ui5-webcomponents/compare/v1.11.0...v1.12.0-rc.0) (2023-03-09)
7
+
8
+
9
+ ### Features
10
+
11
+ * enhance create-ui5-element command to create component in TS ([#6609](https://github.com/SAP/ui5-webcomponents/issues/6609)) ([d870065](https://github.com/SAP/ui5-webcomponents/commit/d8700650a4e5991862e2076cc2c93482011c4c90))
12
+
13
+
14
+
15
+
16
+
17
+ # [1.11.0](https://github.com/SAP/ui5-webcomponents/compare/v1.11.0-rc.4...v1.11.0) (2023-03-06)
18
+
19
+ **Note:** Version bump only for package @ui5/webcomponents-tools
20
+
21
+
22
+
23
+
24
+
25
+ # [1.11.0-rc.4](https://github.com/SAP/ui5-webcomponents/compare/v1.11.0-rc.3...v1.11.0-rc.4) (2023-03-02)
26
+
27
+ **Note:** Version bump only for package @ui5/webcomponents-tools
28
+
29
+
30
+
31
+
32
+
33
+ # [1.11.0-rc.3](https://github.com/SAP/ui5-webcomponents/compare/v1.11.0-rc.2...v1.11.0-rc.3) (2023-02-23)
34
+
35
+
36
+ ### Features
37
+
38
+ * **playground:** next playground with storybook ([#5831](https://github.com/SAP/ui5-webcomponents/issues/5831)) ([79274c8](https://github.com/SAP/ui5-webcomponents/commit/79274c8e442cf5854a7fe6327f25aaed04312103)), closes [#5898](https://github.com/SAP/ui5-webcomponents/issues/5898)
39
+
40
+
41
+
42
+
43
+
44
+ # [1.11.0-rc.2](https://github.com/SAP/ui5-webcomponents/compare/v1.11.0-rc.1...v1.11.0-rc.2) (2023-02-16)
45
+
46
+ **Note:** Version bump only for package @ui5/webcomponents-tools
47
+
48
+
49
+
50
+
51
+
52
+ # [1.11.0-rc.1](https://github.com/SAP/ui5-webcomponents/compare/v1.11.0-rc.0...v1.11.0-rc.1) (2023-02-09)
53
+
54
+ **Note:** Version bump only for package @ui5/webcomponents-tools
55
+
56
+
57
+
58
+
59
+
60
+ # [1.11.0-rc.0](https://github.com/SAP/ui5-webcomponents/compare/v1.10.4-rc.0...v1.11.0-rc.0) (2023-02-02)
61
+
62
+ **Note:** Version bump only for package @ui5/webcomponents-tools
63
+
64
+
65
+
66
+
67
+
68
+ ## [1.10.4-rc.0](https://github.com/SAP/ui5-webcomponents/compare/v1.10.3...v1.10.4-rc.0) (2023-01-26)
69
+
70
+ **Note:** Version bump only for package @ui5/webcomponents-tools
71
+
72
+
73
+
74
+
75
+
76
+ ## [1.10.3](https://github.com/SAP/ui5-webcomponents/compare/v1.10.2...v1.10.3) (2023-01-25)
77
+
78
+ **Note:** Version bump only for package @ui5/webcomponents-tools
79
+
80
+
81
+
82
+
83
+
84
+ ## [1.10.2](https://github.com/SAP/ui5-webcomponents/compare/v1.10.1...v1.10.2) (2023-01-25)
85
+
86
+ **Note:** Version bump only for package ui5-webcomponents
87
+
88
+ ## [1.10.1](https://github.com/SAP/ui5-webcomponents/compare/v0.0.0-7b49a7ff1...v1.10.1) (2023-01-24)
89
+
90
+ **Note:** Version bump only for package @ui5/webcomponents-tools
91
+
92
+
93
+
94
+
95
+
96
+ # [1.10.0](https://github.com/SAP/ui5-webcomponents/compare/v1.9.3...v1.10.0) (2023-01-20)
97
+
98
+
99
+ ### Bug Fixes
100
+
101
+ * **infra:** set Content-Type header on testsuite ([#6108](https://github.com/SAP/ui5-webcomponents/issues/6108)) ([fae3f91](https://github.com/SAP/ui5-webcomponents/commit/fae3f91975ab1dad7135bea2227f61986eff403f))
102
+
103
+
104
+ ### Features
105
+
106
+ * enable TS in main, fiori ([#6064](https://github.com/SAP/ui5-webcomponents/issues/6064)) ([0b56130](https://github.com/SAP/ui5-webcomponents/commit/0b561307b93b8af465dc5bee67650069ee138f7f))
107
+ * migrate illustrated-message component to TS, small refactor ([#6195](https://github.com/SAP/ui5-webcomponents/issues/6195)) ([046c779](https://github.com/SAP/ui5-webcomponents/commit/046c779f654648172619dd720c0d90342ec78fb9))
108
+ * support decorators for custom elements metadata ([#6072](https://github.com/SAP/ui5-webcomponents/issues/6072)) ([fc9ee6e](https://github.com/SAP/ui5-webcomponents/commit/fc9ee6e2af10b4315fde072a50ab37efa180c809))
109
+ * **ui5-button, ui5-date-picker, ui5-calendar:** migrate to TS ([#6173](https://github.com/SAP/ui5-webcomponents/issues/6173)) ([7232ca0](https://github.com/SAP/ui5-webcomponents/commit/7232ca08f286c5dde10080373fb62247f1acf7b7)), closes [#6080](https://github.com/SAP/ui5-webcomponents/issues/6080)
110
+ * use Typescript for the `base` package ([#5982](https://github.com/SAP/ui5-webcomponents/issues/5982)) ([bd184d8](https://github.com/SAP/ui5-webcomponents/commit/bd184d81a4218328bc7bf04baf2bc1f69a361679))
111
+
112
+
113
+
114
+
115
+
116
+ ## [1.9.3](https://github.com/SAP/ui5-webcomponents/compare/v1.9.2...v1.9.3) (2022-12-16)
117
+
118
+ **Note:** Version bump only for package @ui5/webcomponents-tools
119
+
120
+
121
+
122
+
123
+
124
+ ## [1.9.1](https://github.com/SAP/ui5-webcomponents/compare/v1.9.0...v1.9.1) (2022-11-10)
125
+
126
+
127
+ ### Bug Fixes
128
+
129
+ * **framework:** fix paths for generating illustration imports in nps ([#5997](https://github.com/SAP/ui5-webcomponents/issues/5997)) ([e932f7d](https://github.com/SAP/ui5-webcomponents/commit/e932f7d069ebf10f73219bff7154558b7b0d849e))
130
+
131
+
132
+
133
+
134
+
135
+ # [1.9.0](https://github.com/SAP/ui5-webcomponents/compare/v1.8.0...v1.9.0) (2022-10-31)
136
+
137
+
138
+ ### Bug Fixes
139
+
140
+ * **framework:** fix contexts management in hbs-2-lit compiler ([#5958](https://github.com/SAP/ui5-webcomponents/issues/5958)) ([94d1619](https://github.com/SAP/ui5-webcomponents/commit/94d16199ed7dc79b21d99a0637533e93af54c90a)), closes [#4701](https://github.com/SAP/ui5-webcomponents/issues/4701)
141
+
142
+
143
+ ### Features
144
+
145
+ * **framework:** fetch illustrations on demand ([#5927](https://github.com/SAP/ui5-webcomponents/issues/5927)) ([f8e1033](https://github.com/SAP/ui5-webcomponents/commit/f8e1033643626261dcad8a38f65c325ba9aff99f))
146
+ * **framework:** generate custom elements manifest ([#5964](https://github.com/SAP/ui5-webcomponents/issues/5964)) ([0d62770](https://github.com/SAP/ui5-webcomponents/commit/0d62770cace54fd9aef73d9632dd06d8a83680e9))
147
+
148
+
149
+
150
+
151
+
152
+ # [1.8.0](https://github.com/SAP/ui5-webcomponents/compare/v1.7.1...v1.8.0) (2022-10-03)
153
+
154
+
155
+ ### Features
156
+
157
+ * **icons:** create type-definitions for icon imports ([#5753](https://github.com/SAP/ui5-webcomponents/issues/5753)) ([2de4a04](https://github.com/SAP/ui5-webcomponents/commit/2de4a045f56e2f166d3e846ff11e6f9d76e98009)), closes [#5747](https://github.com/SAP/ui5-webcomponents/issues/5747) [#5335](https://github.com/SAP/ui5-webcomponents/issues/5335)
158
+ * **main:** add support for custom SVG icons ([#5865](https://github.com/SAP/ui5-webcomponents/issues/5865)) ([d8b7200](https://github.com/SAP/ui5-webcomponents/commit/d8b7200f30c16d94b7f15ddbdf9808d8efbaa38c))
159
+
160
+
161
+
162
+
163
+
164
+ ## [1.7.1](https://github.com/SAP/ui5-webcomponents/compare/v1.7.0...v1.7.1) (2022-09-08)
165
+
166
+ **Note:** Version bump only for package @ui5/webcomponents-tools
167
+
168
+
169
+
170
+
171
+
172
+ # [1.7.0](https://github.com/SAP/ui5-webcomponents/compare/v1.6.0...v1.7.0) (2022-09-02)
173
+
174
+ **Note:** Version bump only for package @ui5/webcomponents-tools
175
+
176
+
177
+
178
+
179
+
180
+ # [1.6.0](https://github.com/SAP/ui5-webcomponents/compare/v1.5.0...v1.6.0) (2022-07-25)
181
+
182
+
183
+ ### Bug Fixes
184
+
185
+ * **MultoComboBox:** fix component scoping ([#5553](https://github.com/SAP/ui5-webcomponents/issues/5553)) ([9c26e8e](https://github.com/SAP/ui5-webcomponents/commit/9c26e8e)), closes [#5521](https://github.com/SAP/ui5-webcomponents/issues/5521)
186
+
187
+
188
+
189
+
190
+
191
+ # [1.5.0](https://github.com/SAP/ui5-webcomponents/compare/v1.4.0...v1.5.0) (2022-07-03)
192
+
193
+ **Note:** Version bump only for package @ui5/webcomponents-tools
194
+
195
+
196
+
197
+
198
+
199
+ # [1.4.0](https://github.com/SAP/ui5-webcomponents/compare/v1.3.1...v1.4.0) (2022-05-25)
200
+
201
+
202
+ ### Features
203
+
204
+ **Note:** Version bump only for package @ui5/webcomponents-icons-tnt
205
+
206
+
207
+
208
+
209
+
210
+ ## [1.3.1](https://github.com/SAP/ui5-webcomponents/compare/v1.3.0...v1.3.1) (2022-04-27)
211
+
212
+ **Note:** Version bump only for package @ui5/webcomponents-tools
213
+
214
+
215
+
216
+
217
+
218
+ # [1.3.0](https://github.com/SAP/ui5-webcomponents/compare/v1.2.4...v1.3.0) (2022-04-19)
219
+
220
+
221
+ ### Bug Fixes
222
+
223
+ * **localization:** fix js error if "sh" locale set ([#4905](https://github.com/SAP/ui5-webcomponents/issues/4905)) ([979bca2](https://github.com/SAP/ui5-webcomponents/commit/979bca2)), closes [#4904](https://github.com/SAP/ui5-webcomponents/issues/4904)
224
+
225
+
226
+
227
+
228
+
229
+ ## [1.2.4](https://github.com/SAP/ui5-webcomponents/compare/v1.2.3...v1.2.4) (2022-03-30)
230
+
231
+ **Note:** Version bump only for package @ui5/webcomponents-tools
232
+
233
+
234
+
235
+
236
+
237
+ ## [1.2.3](https://github.com/SAP/ui5-webcomponents/compare/v1.2.2...v1.2.3) (2022-03-23)
238
+
239
+ **Note:** Version bump only for package @ui5/webcomponents-tools
240
+
241
+
242
+
243
+
244
+
245
+ ## [1.2.2](https://github.com/SAP/ui5-webcomponents/compare/v1.2.1...v1.2.2) (2022-03-22)
246
+
247
+
248
+ **Note:** Version bump only for package @ui5/webcomponents-tools
249
+
250
+
251
+
252
+
253
+
254
+ ## [1.2.1](https://github.com/SAP/ui5-webcomponents/compare/v1.2.0...v1.2.1) (2022-03-02)
255
+
256
+ **Note:** Version bump only for package @ui5/webcomponents-tools
257
+
258
+
259
+
260
+
261
+
262
+ # [1.2.0](https://github.com/SAP/ui5-webcomponents/compare/v1.1.2...v1.2.0) (2022-02-28)
263
+
264
+
265
+ ### Bug Fixes
266
+
267
+ * correct scoping issues with several components ([#4820](https://github.com/SAP/ui5-webcomponents/issues/4820)) ([621dc20](https://github.com/SAP/ui5-webcomponents/commit/621dc20))
268
+ * display methods in child components API ([#4792](https://github.com/SAP/ui5-webcomponents/issues/4792)) ([1929d08](https://github.com/SAP/ui5-webcomponents/commit/1929d08))
269
+
270
+
271
+ ### Features
272
+
273
+ * **jsdoc:** remove attr name for Object props ([#4680](https://github.com/SAP/ui5-webcomponents/issues/4680)) ([1741bd6](https://github.com/SAP/ui5-webcomponents/commit/1741bd6)), closes [#4674](https://github.com/SAP/ui5-webcomponents/issues/4674)
274
+
275
+
276
+
277
+
278
+
279
+ ## [1.1.2](https://github.com/SAP/ui5-webcomponents/compare/v1.1.1...v1.1.2) (2022-01-26)
280
+
281
+ **Note:** Version bump only for package @ui5/webcomponents-tools
282
+
283
+
284
+
285
+
286
+
287
+ ## [1.1.1](https://github.com/SAP/ui5-webcomponents/compare/v1.1.0...v1.1.1) (2022-01-24)
288
+
289
+ **Note:** Version bump only for package @ui5/webcomponents-tools
290
+
291
+
292
+
293
+
294
+
295
+ # [1.1.0](https://github.com/SAP/ui5-webcomponents/compare/v1.0.2...v1.1.0) (2022-01-21)
296
+
297
+
298
+ **Note:** Version bump only for package @ui5/webcomponents-tools
299
+
300
+
301
+
302
+
303
+
304
+ ## [1.0.2](https://github.com/SAP/ui5-webcomponents/compare/v1.0.1...v1.0.2) (2021-11-29)
305
+
306
+ **Note:** Version bump only for package @ui5/webcomponents-tools
307
+
308
+
309
+
310
+
311
+
312
+ ## [1.0.1](https://github.com/SAP/ui5-webcomponents/compare/v1.0.0...v1.0.1) (2021-11-10)
313
+
314
+ **Note:** Version bump only for package @ui5/webcomponents-tools
315
+
316
+
317
+
318
+
319
+
320
+ # [1.0.0](https://github.com/SAP/ui5-webcomponents/compare/v1.0.0-rc.16...v1.0.0) (2021-11-10)
321
+
322
+
323
+ **Note:** Version bump only for package @ui5/webcomponents-tools
324
+
325
+
326
+ # [1.0.0-rc.16](https://github.com/SAP/ui5-webcomponents/compare/v1.0.0-rc.15...v1.0.0-rc.16) (2021-11-09)
327
+
328
+
329
+
330
+ ### Features
331
+
332
+ * **tools:** create an npm init script ([#4090](https://github.com/SAP/ui5-webcomponents/issues/4090)) ([5608e04](https://github.com/SAP/ui5-webcomponents/commit/5608e04))
333
+
334
+
335
+
336
+ # [1.0.0-rc.15](https://github.com/SAP/ui5-webcomponents/compare/v1.0.0-rc.14...v1.0.0-rc.15) (2021-07-23)
337
+
338
+
339
+ ### Bug Fixes
340
+
341
+ * **tools:** fix build error on MacOS 11 from rollup-plugin-terser ([#3347](https://github.com/SAP/ui5-webcomponents/issues/3347)) ([59892c4](https://github.com/SAP/ui5-webcomponents/commit/59892c4)), closes [#2515](https://github.com/SAP/ui5-webcomponents/issues/2515)
342
+
343
+
344
+
345
+
346
+
347
+
6
348
  # [1.0.0-rc.14](https://github.com/SAP/ui5-webcomponents/compare/v1.0.0-rc.13...v1.0.0-rc.14) (2021-04-01)
7
349
 
8
350
 
package/README.md CHANGED
@@ -1,24 +1,23 @@
1
- ![UI5 icon](https://raw.githubusercontent.com/SAP/ui5-webcomponents/master/docs/images/UI5_logo_wide.png)
1
+ ![UI5 icon](https://raw.githubusercontent.com/SAP/ui5-webcomponents/main/docs/images/UI5_logo_wide.png)
2
2
 
3
3
  # UI5 Web Components - Tools
4
4
 
5
- [![Travis CI Build Status](https://travis-ci.org/SAP/ui5-webcomponents.svg?branch=master)](https://travis-ci.org/SAP/ui5-webcomponents)
6
5
  [![npm Package Version](https://badge.fury.io/js/%40ui5%2Fwebcomponents.svg)](https://www.npmjs.com/package/@ui5/webcomponents)
7
6
 
8
7
  Provides libraries, configuration files and build artifacts,
9
8
  used by other UI5 Web Components packages, such as `main` and `fiori`.
10
9
 
11
10
  ## Resources
12
- - [UI5 Web Components - README.md](https://github.com/SAP/ui5-webcomponents/blob/master/README.md)
11
+ - [UI5 Web Components - README.md](https://github.com/SAP/ui5-webcomponents/blob/main/README.md)
13
12
  - [UI5 Web Components - Home Page](https://sap.github.io/ui5-webcomponents)
14
13
  - [UI5 Web Components - Playground and API Reference](https://sap.github.io/ui5-webcomponents/playground/)
15
14
 
16
15
  ## Support
17
- We welcome all comments, suggestions, questions, and bug reports. Please follow our [Support Guidelines](https://github.com/SAP/ui5-webcomponents/blob/master/SUPPORT.md#-content) on how to report an issue, or chat with us in the `#webcomponents` channel of the [OpenUI5 Community Slack](https://join-ui5-slack.herokuapp.com/).
16
+ We welcome all comments, suggestions, questions, and bug reports. Please follow our [Support Guidelines](https://github.com/SAP/ui5-webcomponents/blob/main/SUPPORT.md#-content) on how to report an issue, or chat with us in the `#webcomponents` channel of the [OpenUI5 Community Slack](https://join-ui5-slack.herokuapp.com/).
18
17
 
19
18
  ## Contribute
20
- Please check our [Contribution Guidelines](https://github.com/SAP/ui5-webcomponents/blob/master/CONTRIBUTING.md).
19
+ Please check our [Contribution Guidelines](https://github.com/SAP/ui5-webcomponents/blob/main/docs/6-contributing/02-conventions-and-guidelines.md).
21
20
 
22
21
  ## License
23
22
  Copyright (c) 2019 SAP SE or an SAP affiliate company. All rights reserved.
24
- This file is licensed under the Apache Software License, Version 2.0 except as noted otherwise in the [LICENSE](https://github.com/SAP/ui5-webcomponents/blob/master/LICENSE.txt) file.
23
+ This file is licensed under the Apache Software License, Version 2.0 except as noted otherwise in the [LICENSE](https://github.com/SAP/ui5-webcomponents/blob/main/LICENSE.txt) file.
package/assets-meta.js CHANGED
@@ -8,7 +8,12 @@ const assetsMeta = {
8
8
  "sap_belize_hcb",
9
9
  "sap_belize_hcw",
10
10
  "sap_fiori_3_hcb",
11
- "sap_fiori_3_hcw"
11
+ "sap_fiori_3_hcw",
12
+ "sap_horizon",
13
+ "sap_horizon_dark",
14
+ "sap_horizon_hcb",
15
+ "sap_horizon_hcw",
16
+ "sap_horizon_exp"
12
17
  ]
13
18
  },
14
19
  "languages": {
@@ -131,6 +136,7 @@ const assetsMeta = {
131
136
  "sk",
132
137
  "sl",
133
138
  "sr",
139
+ "sr_Latn",
134
140
  "sv",
135
141
  "th",
136
142
  "tr",
package/bin/dev.js CHANGED
@@ -10,11 +10,7 @@ if (command === "watch") {
10
10
  command = `watch.${argument}`;
11
11
  }
12
12
  } else if (command === "test") {
13
- if (argument === "--no-server") { // yarn test --no-server
14
- command = `test.run`;
15
- } else if (argument) { // yarn test test/specs/Button.spec.js
16
- command = `test.spec --spec ${argument}`;
17
- }
13
+ command = `test ${process.argv.slice(3).join(" ")}`;
18
14
  }
19
15
 
20
16
  child_process.execSync(`npx nps "${command}"`, {stdio: 'inherit'});
@@ -5,6 +5,34 @@ module.exports = {
5
5
  },
6
6
  "root": true,
7
7
  "extends": "airbnb-base",
8
+ overrides: [{
9
+ files: ["*.ts"],
10
+ parser: "@typescript-eslint/parser",
11
+ plugins: ["@typescript-eslint"],
12
+ extends: [
13
+ "plugin:@typescript-eslint/recommended",
14
+ "plugin:@typescript-eslint/recommended-requiring-type-checking"
15
+ ],
16
+ parserOptions: {
17
+ "project": ["./tsconfig.json", "./packages/*/tsconfig.json"],
18
+ },
19
+ /**
20
+ * Typescript Rules
21
+ */
22
+ rules: {
23
+ "no-shadow": "off",
24
+ "@typescript-eslint/no-shadow": ["error"],
25
+ "@typescript-eslint/no-unsafe-member-access": "off",
26
+ "@typescript-eslint/no-floating-promises": "off",
27
+ "@typescript-eslint/no-explicit-any": "off",
28
+ "@typescript-eslint/no-unsafe-assignment": "off",
29
+ "@typescript-eslint/ban-ts-comment": "off",
30
+ "@typescript-eslint/no-unsafe-call": "off",
31
+ "@typescript-eslint/no-non-null-assertion": "off",
32
+ "@typescript-eslint/no-empty-function": "off",
33
+ "lines-between-class-members": "off",
34
+ }
35
+ }],
8
36
  "parserOptions": {
9
37
  "ecmaVersion": 2018,
10
38
  "sourceType": "module"
@@ -1,35 +1,70 @@
1
1
  const path = require("path");
2
2
  const fs = require("fs");
3
-
3
+ const resolve = require("resolve");
4
4
  const LIB = path.join(__dirname, `../lib/`);
5
- const polyfillDir = path.dirname(require.resolve("@webcomponents/webcomponentsjs"));
6
- const polyfillPath = path.join(polyfillDir, "{*.js,*.map,*.md,bundles/**/*.*}");
7
- const packageName = JSON.parse(fs.readFileSync("./package.json")).name;
5
+ const preprocessJSDocScript = resolve.sync("@ui5/webcomponents-tools/lib/jsdoc/preprocess.js");
8
6
 
9
7
  const getScripts = (options) => {
10
8
 
11
- const port = options.port || 8080; // preferred port
12
- const portStep = options.portStep || 1; // step to check for available ports, if preferred port is already used
9
+ // The script creates all JS modules (dist/illustrations/{illustrationName}.js) out of the existing SVGs
10
+ const illustrationsData = options.illustrationsData || [];
11
+ const illustrations = illustrationsData.map(illustration => `node "${LIB}/create-illustrations/index.js" ${illustration.path} ${illustration.defaultText} ${illustration.illustrationsPrefix} ${illustration.set} ${illustration.destinationPath}`);
12
+ const createIllustrationsJSImportsScript = illustrations.join(" && ");
13
+
14
+ // The script creates the "dist/generated/js-imports/Illustration.js" file that registers loaders (dynamic JS imports) for each illustration
15
+ const illustrationDestinationPaths = illustrationsData.map(illustrations => illustrations.destinationPath);
16
+ const createIllustrationsLoadersScript = options.fioriPackage ? `node ${LIB}/generate-js-imports/illustrations.js ${illustrationDestinationPaths[0]} ${illustrationDestinationPaths[1]} dist/generated/js-imports` : "";
17
+ const tsOption = options.typescript;
18
+ const tsCommand = tsOption ? "tsc" : "";
19
+ const tsWatchCommand = tsOption ? "tsc --watch" : "";
20
+ const tsCrossEnv = tsOption ? "cross-env UI5_TS=true" : "";
21
+ const copySrcGenerated = tsOption ? "" : "copy.srcGenerated";
22
+
23
+ let viteConfig;
24
+ if (fs.existsSync("config/vite.config.js")) {
25
+ // old project setup where config file is in separate folder
26
+ viteConfig = "-c config/vite.config.js";
27
+ } else if (fs.existsSync("vite.config.js")) {
28
+ // preferred way of custom configuration in root project folder
29
+ viteConfig = "";
30
+ } else {
31
+ // no custom configuration - use default from tools project
32
+ viteConfig = `-c "${require.resolve("@ui5/webcomponents-tools/components-package/vite.config.js")}"`;
33
+ }
34
+
35
+ let eslintConfig;
36
+ if (fs.existsSync("config/.eslintrc.js")) {
37
+ // old project setup where config file is in separate folder
38
+ eslintConfig = "--config config/.eslintrc.js";
39
+ } else if (fs.existsSync(".eslintrc.js")) {
40
+ // preferred way of custom configuration in root project folder
41
+ eslintConfig = "";
42
+ } else {
43
+ // no custom configuration - use default from tools project
44
+ eslintConfig = `--config "${require.resolve("@ui5/webcomponents-tools/components-package/eslint.js")}"`;
45
+ }
13
46
 
14
47
  const scripts = {
15
- clean: "rimraf dist && rimraf .port",
16
- lint: "eslint . --config config/.eslintrc.js",
17
- lintfix: "eslint . --config config/.eslintrc.js --fix",
48
+ clean: 'rimraf jsdoc-dist && rimraf src/generated && rimraf dist && rimraf .port && nps "scope.testPages.clean"',
49
+ lint: `eslint . ${eslintConfig}`,
50
+ lintfix: `eslint . ${eslintConfig} --fix`,
18
51
  prepare: {
19
- default: "nps clean build.templates build.styles build.i18n build.jsonImports copy build.samples",
20
- es5: "nps clean build.templates build.styles build.i18n build.jsonImports copy.es5 build.samples"
52
+ default: `${tsCrossEnv} nps clean prepare.all typescript generateAPI`,
53
+ all: 'concurrently "nps build.templates" "nps build.i18n" "nps prepare.styleRelated" "nps copy" "nps build.illustrations"',
54
+ styleRelated: "nps build.styles build.jsonImports build.jsImports",
21
55
  },
56
+ typescript: tsCommand,
22
57
  build: {
23
- default: "nps lint prepare.es5 build.bundle",
58
+ default: "nps prepare lint build.bundle",
24
59
  templates: `mkdirp dist/generated/templates && node "${LIB}/hbs2ui5/index.js" -d src/ -o dist/generated/templates`,
25
60
  styles: {
26
- default: "nps build.styles.themes build.styles.components",
27
- themes: "postcss src/**/parameters-bundle.css --config config/postcss.themes --base src --dir dist/css/",
61
+ default: `nps build.styles.themes build.styles.components ${copySrcGenerated}`,
62
+ themes: `node "${LIB}/postcss-p/postcss-p.mjs"`,
28
63
  components: "postcss src/themes/*.css --config config/postcss.components --base src --dir dist/css/", // When updating this, also update the new files script
29
64
  },
30
65
  i18n: {
31
66
  default: "nps build.i18n.defaultsjs build.i18n.json",
32
- defaultsjs: `node "${LIB}/i18n/defaults.js" src/i18n dist/generated/i18n`,
67
+ defaultsjs: `node "${LIB}/i18n/defaults.js" src/i18n src/generated/i18n`,
33
68
  json: `node "${LIB}/i18n/toJSON.js" src/i18n dist/generated/assets/i18n`,
34
69
  },
35
70
  jsonImports: {
@@ -37,32 +72,26 @@ const getScripts = (options) => {
37
72
  themes: `node "${LIB}/generate-json-imports/themes.js" dist/generated/assets/themes dist/generated/json-imports`,
38
73
  i18n: `node "${LIB}/generate-json-imports/i18n.js" dist/generated/assets/i18n dist/generated/json-imports`,
39
74
  },
40
- bundle: "rollup --config config/rollup.config.js --environment ES5_BUILD",
41
- samples: {
42
- default: "nps build.samples.api build.samples.docs",
43
- api: `jsdoc -c "${LIB}/jsdoc/config.json"`,
44
- docs: `node "${LIB}/documentation/index.js" dist/api.json`,
45
- }
75
+ jsImports: {
76
+ default: "mkdirp dist/generated/js-imports && nps build.jsImports.illustrationsLoaders",
77
+ illustrationsLoaders: createIllustrationsLoadersScript,
78
+ },
79
+ bundle: `vite build ${viteConfig}`,
80
+ illustrations: createIllustrationsJSImportsScript,
46
81
  },
47
82
  copy: {
48
- default: "nps copy.src copy.props copy.test copy.webcomponents-polyfill-placeholder",
49
- es5: "nps copy.src copy.props copy.test copy.webcomponents-polyfill",
83
+ default: "nps copy.src copy.props",
50
84
  src: `node "${LIB}/copy-and-watch/index.js" --silent "src/**/*.js" dist/`,
85
+ srcGenerated: `node "${LIB}/copy-and-watch/index.js" --silent "src/generated/**/*.js" dist/generated/`,
51
86
  props: `node "${LIB}/copy-and-watch/index.js" --silent "src/**/*.properties" dist/`,
52
- test: `node "${LIB}/copy-and-watch/index.js" --silent "test/**/*.*" dist/test-resources`,
53
- "webcomponents-polyfill": `node "${LIB}/copy-and-watch/index.js" --silent "${polyfillPath}" dist/webcomponentsjs/`,
54
- "webcomponents-polyfill-placeholder": `node ${LIB}/polyfill-placeholder/index.js`
55
87
  },
56
88
  watch: {
57
- default: 'concurrently "nps watch.templates" "nps watch.samples" "nps watch.test" "nps watch.src" "nps watch.bundle" "nps watch.styles" "nps watch.i18n"',
58
- es5: 'concurrently "nps watch.templates" "nps watch.samples" "nps watch.test" "nps watch.src" "nps watch.bundle.es5" "nps watch.styles" "nps watch.i18n"',
89
+ default: `${tsCrossEnv} concurrently "nps watch.templates" "nps watch.api" "nps watch.src" "nps watch.typescript" "nps watch.styles" "nps watch.i18n" "nps watch.props"`,
90
+ devServer: 'concurrently "nps watch.default" "nps watch.bundle"',
59
91
  src: 'nps "copy.src --watch --safe --skip-initial-copy"',
92
+ typescript: tsWatchCommand,
60
93
  props: 'nps "copy.props --watch --safe --skip-initial-copy"',
61
- test: 'nps "copy.test --watch --safe --skip-initial-copy"',
62
- bundle: {
63
- default: 'rollup --config config/rollup.config.js -w --environment DEV,DEPLOY_PUBLIC_PATH:/resources/',
64
- es5: 'rollup --config config/rollup.config.js -w --environment ES5_BUILD,DEV,DEPLOY_PUBLIC_PATH:/resources/'
65
- },
94
+ bundle: `node ${LIB}/dev-server/dev-server.js ${viteConfig}`,
66
95
  styles: {
67
96
  default: 'concurrently "nps watch.styles.themes" "nps watch.styles.components"',
68
97
  themes: 'nps "build.styles.themes -w"',
@@ -73,35 +102,35 @@ const getScripts = (options) => {
73
102
  },
74
103
  },
75
104
  templates: 'chokidar "src/**/*.hbs" -c "nps build.templates"',
76
- samples: 'chokidar "test/**/*.sample.html" -c "nps build.samples"',
105
+ api: 'chokidar "test/**/*.sample.html" -c "nps generateAPI"',
77
106
  i18n: 'chokidar "src/i18n/messagebundle.properties" -c "nps build.i18n.defaultsjs"'
78
107
  },
79
- dev: {
80
- default: 'concurrently "nps serve" "nps watch"',
81
- es5: 'concurrently "nps serve" "nps watch.es5"'
82
- },
83
- start: "nps prepare dev",
84
- serve: `node "${LIB}/serve/index.js" --dir="dist/" --port=${port} --portStep=${portStep} --packageName="${packageName}"`,
85
- test: {
86
- // --success first - report the exit code of the test run (first command to finish), as serve is always terminated and has a non-0 exit code
87
- default: 'concurrently "nps serve" "nps test.run" --kill-others --success first',
88
- run: "cross-env WDIO_LOG_LEVEL=error wdio config/wdio.conf.js",
89
- spec: "wdio run config/wdio.conf.js",
90
- },
91
- startWithScope: "nps scope.prepare scope.dev",
108
+ start: "nps prepare watch.devServer",
109
+ test: `node "${LIB}/test-runner/test-runner.js"`,
110
+ "test-suite-1": `node "${LIB}/test-runner/test-runner.js" --suite suite1`,
111
+ "test-suite-2": `node "${LIB}/test-runner/test-runner.js" --suite suite2`,
112
+ startWithScope: "nps scope.prepare scope.watchWithBundle",
92
113
  scope: {
93
114
  prepare: "nps scope.lint prepare scope.testPages",
94
115
  lint: `node "${LIB}/scoping/lint-src.js"`,
95
116
  testPages: {
96
117
  default: "nps scope.testPages.clean scope.testPages.copy scope.testPages.replace",
97
- clean: "rimraf dist/test-resources/pages/scoped",
98
- copy: `node "${LIB}/copy-and-watch/index.js" --silent "dist/test-resources/pages/**/*" dist/test-resources/scoped`,
99
- replace: `node "${LIB}/scoping/scope-test-pages.js" dist/test-resources/scoped demo`,
118
+ clean: "rimraf test/pages/scoped",
119
+ copy: `node "${LIB}/copy-and-watch/index.js" --silent "test/pages/**/*" test/pages/scoped`,
120
+ replace: `node "${LIB}/scoping/scope-test-pages.js" test/pages/scoped demo`,
100
121
  },
101
- dev: 'concurrently "nps serve" "nps scope.watch"',
102
- watch: 'concurrently "nps watch.templates" "nps watch.samples" "nps watch.test" "nps watch.src" "nps watch.props" "nps scope.bundle" "nps watch.styles"',
103
- bundle: 'rollup --config config/rollup.config.js -w --environment ES5_BUILD,DEV,SCOPE'
104
- }
122
+ watchWithBundle: 'concurrently "nps scope.watch" "nps scope.bundle" ',
123
+ watch: 'concurrently "nps watch.templates" "nps watch.api" "nps watch.src" "nps watch.props" "nps watch.styles"',
124
+ bundle: `node ${LIB}/dev-server/dev-server.js ${viteConfig}`,
125
+ },
126
+ generateAPI: {
127
+ default: "nps generateAPI.prepare generateAPI.preprocess generateAPI.jsdoc generateAPI.cleanup generateAPI.prepareManifest",
128
+ prepare: `node "${LIB}/copy-and-watch/index.js" --silent "dist/**/*.js" jsdoc-dist/`,
129
+ prepareManifest: `node "${LIB}/generate-custom-elements-manifest/index.js" dist dist`,
130
+ preprocess: `node "${preprocessJSDocScript}" jsdoc-dist/ src`,
131
+ jsdoc: `jsdoc -c "${LIB}/jsdoc/configTypescript.json"`,
132
+ cleanup: "rimraf jsdoc-dist/"
133
+ },
105
134
  };
106
135
 
107
136
  return scripts;