@sap/ux-specification 1.96.2 → 1.96.5

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 (449) hide show
  1. package/CHANGELOG.md +66 -3
  2. package/dist/documentation/runDocu-min.js +1 -1
  3. package/dist/documentation/styleDocu.css +7 -14
  4. package/dist/documentation/v2/v2-AnalyticalListPage.html +1 -1
  5. package/dist/documentation/v2/v2-ApplicationV2.html +1 -1
  6. package/dist/documentation/v2/v2-ListReport.html +1 -1
  7. package/dist/documentation/v2/v2-ObjectPage.html +1 -1
  8. package/dist/documentation/v2/v2-OverviewPage.html +1 -1
  9. package/dist/documentation/v4/v4-AnalyticalListPage.html +1 -1
  10. package/dist/documentation/v4/v4-ApplicationV4.html +1 -1
  11. package/dist/documentation/v4/v4-ListReport.html +1 -1
  12. package/dist/documentation/v4/v4-ObjectPage.html +1 -1
  13. package/dist/index-min.js +1 -1
  14. package/dist/index-min.js.LICENSE.txt +0 -71
  15. package/dist/schemas/v2/AnalyticalListPageConfig.json +175 -15
  16. package/dist/schemas/v2/ApplicationV2.json +31 -0
  17. package/dist/schemas/v2/ListReportConfig.json +187 -15
  18. package/dist/schemas/v2/ObjectPageConfig.json +127 -33
  19. package/dist/schemas/v2/OverviewPageConfig.json +57 -16
  20. package/dist/schemas/v4/AnalyticalListPageConfig.json +122 -76
  21. package/dist/schemas/v4/ListReportConfig.json +122 -76
  22. package/dist/schemas/v4/ObjectPageConfig.json +144 -64
  23. package/dist/specification/v2/index-min.js +1 -1
  24. package/dist/specification/v4/index-min.js +1 -1
  25. package/dist/src/apiTypes.d.ts +5 -2
  26. package/dist/src/specification/v2/ApplicationV2.d.ts +21 -0
  27. package/dist/src/specification/v2/controls/Action.d.ts +19 -2
  28. package/dist/src/specification/v2/controls/FilterBar.d.ts +70 -22
  29. package/dist/src/specification/v2/controls/Footer.d.ts +20 -0
  30. package/dist/src/specification/v2/controls/ObjectPageTable.d.ts +4 -0
  31. package/dist/src/specification/v2/controls/Table.d.ts +12 -1
  32. package/dist/src/specification/v2/controls/ToolBar.d.ts +1 -8
  33. package/dist/src/specification/v2/controls/index.d.ts +1 -2
  34. package/dist/src/specification/v2/pages/AnalyticalListPageConfig.d.ts +2 -1
  35. package/dist/src/specification/v2/pages/ListReportConfig.d.ts +2 -1
  36. package/dist/src/specification/v2/pages/OverviewPageConfig.d.ts +36 -2
  37. package/dist/src/specification/v4/controls/ObjectPageFooter.d.ts +2 -2
  38. package/dist/src/specification/v4/controls/ObjectPageSection.d.ts +7 -7
  39. package/dist/src/specification/v4/controls/ObjectPageTable.d.ts +21 -6
  40. package/dist/src/specification/v4/controls/Table.d.ts +1 -6
  41. package/dist/src/specification/v4/webapp/manifest/ManifestSettings.d.ts +59 -10
  42. package/dist/src/sync/common/decoration/control.d.ts +11 -1
  43. package/dist/src/sync/common/generate/objectPage.d.ts +9 -0
  44. package/dist/src/sync/common/generate/utils.d.ts +30 -1
  45. package/dist/src/sync/common/import/utils.d.ts +8 -1
  46. package/dist/src/sync/common/types.d.ts +30 -16
  47. package/dist/src/sync/common/utils.d.ts +4 -3
  48. package/dist/src/sync/v2/application.d.ts +3 -1
  49. package/dist/src/sync/v2/export/controls/Action.d.ts +15 -0
  50. package/dist/src/sync/v2/export/controls/FilterBar.d.ts +18 -6
  51. package/dist/src/sync/v2/export/controls/Fragment.d.ts +1 -1
  52. package/dist/src/sync/v2/export/controls/ObjectPageFooterAction.d.ts +2 -2
  53. package/dist/src/sync/v2/export/controls/ObjectPageSectionsV2.d.ts +2 -2
  54. package/dist/src/sync/v2/export/controls/ObjectPageTable.d.ts +1 -0
  55. package/dist/src/sync/v2/export/controls/Table.d.ts +1 -0
  56. package/dist/src/sync/v2/export/controls/TableColumn.d.ts +18 -2
  57. package/dist/src/sync/v2/export/pages/AnalyticalListPage.d.ts +2 -1
  58. package/dist/src/sync/v2/export/pages/ListReport.d.ts +2 -1
  59. package/dist/src/sync/v2/export/pages/OverviewPage.d.ts +2 -1
  60. package/dist/src/sync/v2/export/view-controller-generator.d.ts +16 -21
  61. package/dist/src/sync/v2/generate/objectPage.d.ts +1 -5
  62. package/dist/src/sync/v2/generate/utils.d.ts +22 -11
  63. package/dist/src/sync/v2/import/common/index.d.ts +22 -4
  64. package/dist/src/sync/v2/import/pages/listReport.d.ts +0 -5
  65. package/dist/src/sync/v2/import/utils.d.ts +4 -6
  66. package/dist/src/sync/v2/types.d.ts +8 -1
  67. package/dist/src/sync/v4/export/controls/ObjectPageTableColumn.d.ts +13 -4
  68. package/dist/src/sync/v4/export/controls/TableColumn.d.ts +10 -2
  69. package/dist/src/sync/v4/export/controls/ToolBar.d.ts +5 -1
  70. package/dist/src/sync/v4/export/exportCustomColumn.d.ts +13 -0
  71. package/dist/src/sync/v4/export/pages/AnalyticalListPage.d.ts +2 -2
  72. package/dist/src/sync/v4/export/pages/ListReport.d.ts +2 -2
  73. package/dist/src/sync/v4/export/pages/ObjectPage.d.ts +2 -2
  74. package/dist/src/sync/v4/export/types.d.ts +3 -0
  75. package/dist/src/sync/v4/generate/generate.d.ts +4 -2
  76. package/dist/src/sync/v4/generate/listReport.d.ts +7 -6
  77. package/dist/src/sync/v4/import/pages/analyticalListPage.d.ts +2 -2
  78. package/dist/src/sync/v4/import/pages/listReport.d.ts +3 -3
  79. package/dist/src/sync/v4/import/pages/objectPage.d.ts +2 -2
  80. package/dist/src/sync/v4/utils/utils.d.ts +32 -1
  81. package/dist/test/unit/utils.test.d.ts +1 -1
  82. package/package.json +19 -17
  83. package/dist/scripts/extractDocu.js +0 -488
  84. package/dist/scripts/extractDocu.js.map +0 -1
  85. package/dist/scripts/runDocu.js +0 -577
  86. package/dist/scripts/runDocu.js.map +0 -1
  87. package/dist/scripts/spec.js +0 -114
  88. package/dist/scripts/spec.js.map +0 -1
  89. package/dist/scripts/to-json-schema.js +0 -130
  90. package/dist/scripts/to-json-schema.js.map +0 -1
  91. package/dist/src/api.js +0 -184
  92. package/dist/src/api.js.map +0 -1
  93. package/dist/src/apiTypes.js +0 -17
  94. package/dist/src/apiTypes.js.map +0 -1
  95. package/dist/src/extensionLogger.js +0 -39
  96. package/dist/src/extensionLogger.js.map +0 -1
  97. package/dist/src/i18n/i18n.js +0 -25
  98. package/dist/src/i18n/i18n.js.map +0 -1
  99. package/dist/src/index.js +0 -13
  100. package/dist/src/index.js.map +0 -1
  101. package/dist/src/project.js +0 -143
  102. package/dist/src/project.js.map +0 -1
  103. package/dist/src/specification/common/Application.js +0 -3
  104. package/dist/src/specification/common/Application.js.map +0 -1
  105. package/dist/src/specification/common/i18n.json +0 -1
  106. package/dist/src/specification/common/index.js +0 -10
  107. package/dist/src/specification/common/index.js.map +0 -1
  108. package/dist/src/specification/common/page.js +0 -33
  109. package/dist/src/specification/common/page.js.map +0 -1
  110. package/dist/src/specification/common/types.js +0 -20
  111. package/dist/src/specification/common/types.js.map +0 -1
  112. package/dist/src/specification/common/webapp/manifest/Manifest.js +0 -17
  113. package/dist/src/specification/common/webapp/manifest/Manifest.js.map +0 -1
  114. package/dist/src/specification/common/webapp/manifest/index.js +0 -8
  115. package/dist/src/specification/common/webapp/manifest/index.js.map +0 -1
  116. package/dist/src/specification/common/webapp/manifest/sapOvp.js +0 -9
  117. package/dist/src/specification/common/webapp/manifest/sapOvp.js.map +0 -1
  118. package/dist/src/specification/common/webapp/manifest/sapUi5.js +0 -14
  119. package/dist/src/specification/common/webapp/manifest/sapUi5.js.map +0 -1
  120. package/dist/src/specification/schemaAccess.js +0 -65
  121. package/dist/src/specification/schemaAccess.js.map +0 -1
  122. package/dist/src/specification/v2/ApplicationV2.js +0 -9
  123. package/dist/src/specification/v2/ApplicationV2.js.map +0 -1
  124. package/dist/src/specification/v2/controls/Action.js +0 -3
  125. package/dist/src/specification/v2/controls/Action.js.map +0 -1
  126. package/dist/src/specification/v2/controls/AnalyticalListPageChart.js +0 -36
  127. package/dist/src/specification/v2/controls/AnalyticalListPageChart.js.map +0 -1
  128. package/dist/src/specification/v2/controls/AnalyticalListPageKPI.js +0 -3
  129. package/dist/src/specification/v2/controls/AnalyticalListPageKPI.js.map +0 -1
  130. package/dist/src/specification/v2/controls/Card.js +0 -72
  131. package/dist/src/specification/v2/controls/Card.js.map +0 -1
  132. package/dist/src/specification/v2/controls/Facets.js +0 -3
  133. package/dist/src/specification/v2/controls/Facets.js.map +0 -1
  134. package/dist/src/specification/v2/controls/Field.js +0 -3
  135. package/dist/src/specification/v2/controls/Field.js.map +0 -1
  136. package/dist/src/specification/v2/controls/FilterBar.js +0 -54
  137. package/dist/src/specification/v2/controls/FilterBar.js.map +0 -1
  138. package/dist/src/specification/v2/controls/ObjectPageChart.js +0 -3
  139. package/dist/src/specification/v2/controls/ObjectPageChart.js.map +0 -1
  140. package/dist/src/specification/v2/controls/ObjectPageFooter.d.ts +0 -11
  141. package/dist/src/specification/v2/controls/ObjectPageFooter.js +0 -3
  142. package/dist/src/specification/v2/controls/ObjectPageFooter.js.map +0 -1
  143. package/dist/src/specification/v2/controls/ObjectPageFooterAction.d.ts +0 -28
  144. package/dist/src/specification/v2/controls/ObjectPageFooterAction.js +0 -3
  145. package/dist/src/specification/v2/controls/ObjectPageFooterAction.js.map +0 -1
  146. package/dist/src/specification/v2/controls/ObjectPageForm.js +0 -3
  147. package/dist/src/specification/v2/controls/ObjectPageForm.js.map +0 -1
  148. package/dist/src/specification/v2/controls/ObjectPageHeader.js +0 -3
  149. package/dist/src/specification/v2/controls/ObjectPageHeader.js.map +0 -1
  150. package/dist/src/specification/v2/controls/ObjectPageLayout.js +0 -3
  151. package/dist/src/specification/v2/controls/ObjectPageLayout.js.map +0 -1
  152. package/dist/src/specification/v2/controls/ObjectPageSection.js +0 -13
  153. package/dist/src/specification/v2/controls/ObjectPageSection.js.map +0 -1
  154. package/dist/src/specification/v2/controls/ObjectPageTable.js +0 -7
  155. package/dist/src/specification/v2/controls/ObjectPageTable.js.map +0 -1
  156. package/dist/src/specification/v2/controls/ObjectPageToolBar.js +0 -3
  157. package/dist/src/specification/v2/controls/ObjectPageToolBar.js.map +0 -1
  158. package/dist/src/specification/v2/controls/Table.js +0 -42
  159. package/dist/src/specification/v2/controls/Table.js.map +0 -1
  160. package/dist/src/specification/v2/controls/ToolBar.js +0 -3
  161. package/dist/src/specification/v2/controls/ToolBar.js.map +0 -1
  162. package/dist/src/specification/v2/controls/index.js +0 -12
  163. package/dist/src/specification/v2/controls/index.js.map +0 -1
  164. package/dist/src/specification/v2/index.js +0 -10
  165. package/dist/src/specification/v2/index.js.map +0 -1
  166. package/dist/src/specification/v2/page.js +0 -3
  167. package/dist/src/specification/v2/page.js.map +0 -1
  168. package/dist/src/specification/v2/pages/AnalyticalListPageConfig.js +0 -3
  169. package/dist/src/specification/v2/pages/AnalyticalListPageConfig.js.map +0 -1
  170. package/dist/src/specification/v2/pages/ListReportConfig.js +0 -3
  171. package/dist/src/specification/v2/pages/ListReportConfig.js.map +0 -1
  172. package/dist/src/specification/v2/pages/ObjectPageConfig.js +0 -3
  173. package/dist/src/specification/v2/pages/ObjectPageConfig.js.map +0 -1
  174. package/dist/src/specification/v2/pages/OverviewPageConfig.js +0 -8
  175. package/dist/src/specification/v2/pages/OverviewPageConfig.js.map +0 -1
  176. package/dist/src/specification/v2/pages/index.js +0 -7
  177. package/dist/src/specification/v2/pages/index.js.map +0 -1
  178. package/dist/src/specification/v2/webapp/index.js +0 -7
  179. package/dist/src/specification/v2/webapp/index.js.map +0 -1
  180. package/dist/src/specification/v2/webapp/manifest/index.js +0 -8
  181. package/dist/src/specification/v2/webapp/manifest/index.js.map +0 -1
  182. package/dist/src/specification/v2/webapp/manifest/sapUi.js +0 -3
  183. package/dist/src/specification/v2/webapp/manifest/sapUi.js.map +0 -1
  184. package/dist/src/specification/v2/webapp/manifest/sapUi5.js +0 -10
  185. package/dist/src/specification/v2/webapp/manifest/sapUi5.js.map +0 -1
  186. package/dist/src/specification/v2/webapp/manifest/sapUiPageV2.js +0 -7
  187. package/dist/src/specification/v2/webapp/manifest/sapUiPageV2.js.map +0 -1
  188. package/dist/src/specification/v4/ApplicationV4.js +0 -3
  189. package/dist/src/specification/v4/ApplicationV4.js.map +0 -1
  190. package/dist/src/specification/v4/controls/FilterBar.js +0 -3
  191. package/dist/src/specification/v4/controls/FilterBar.js.map +0 -1
  192. package/dist/src/specification/v4/controls/ObjectPageFooter.js +0 -3
  193. package/dist/src/specification/v4/controls/ObjectPageFooter.js.map +0 -1
  194. package/dist/src/specification/v4/controls/ObjectPageHeader.js +0 -3
  195. package/dist/src/specification/v4/controls/ObjectPageHeader.js.map +0 -1
  196. package/dist/src/specification/v4/controls/ObjectPageHeaderSection.js +0 -7
  197. package/dist/src/specification/v4/controls/ObjectPageHeaderSection.js.map +0 -1
  198. package/dist/src/specification/v4/controls/ObjectPageLayout.js +0 -8
  199. package/dist/src/specification/v4/controls/ObjectPageLayout.js.map +0 -1
  200. package/dist/src/specification/v4/controls/ObjectPageSection.js +0 -12
  201. package/dist/src/specification/v4/controls/ObjectPageSection.js.map +0 -1
  202. package/dist/src/specification/v4/controls/ObjectPageTable.js +0 -3
  203. package/dist/src/specification/v4/controls/ObjectPageTable.js.map +0 -1
  204. package/dist/src/specification/v4/controls/ObjectPageToolBar.js +0 -3
  205. package/dist/src/specification/v4/controls/ObjectPageToolBar.js.map +0 -1
  206. package/dist/src/specification/v4/controls/Table.js +0 -30
  207. package/dist/src/specification/v4/controls/Table.js.map +0 -1
  208. package/dist/src/specification/v4/controls/ToolBar.js +0 -8
  209. package/dist/src/specification/v4/controls/ToolBar.js.map +0 -1
  210. package/dist/src/specification/v4/controls/index.js +0 -11
  211. package/dist/src/specification/v4/controls/index.js.map +0 -1
  212. package/dist/src/specification/v4/index.js +0 -9
  213. package/dist/src/specification/v4/index.js.map +0 -1
  214. package/dist/src/specification/v4/page.js +0 -3
  215. package/dist/src/specification/v4/page.js.map +0 -1
  216. package/dist/src/specification/v4/pages/AnalyticalListPageConfig.js +0 -3
  217. package/dist/src/specification/v4/pages/AnalyticalListPageConfig.js.map +0 -1
  218. package/dist/src/specification/v4/pages/ListReportConfig.js +0 -9
  219. package/dist/src/specification/v4/pages/ListReportConfig.js.map +0 -1
  220. package/dist/src/specification/v4/pages/ObjectPageConfig.js +0 -8
  221. package/dist/src/specification/v4/pages/ObjectPageConfig.js.map +0 -1
  222. package/dist/src/specification/v4/pages/index.js +0 -8
  223. package/dist/src/specification/v4/pages/index.js.map +0 -1
  224. package/dist/src/specification/v4/webapp/index.js +0 -7
  225. package/dist/src/specification/v4/webapp/index.js.map +0 -1
  226. package/dist/src/specification/v4/webapp/manifest/ManifestSettings.js +0 -16
  227. package/dist/src/specification/v4/webapp/manifest/ManifestSettings.js.map +0 -1
  228. package/dist/src/specification/v4/webapp/manifest/index.js +0 -10
  229. package/dist/src/specification/v4/webapp/manifest/index.js.map +0 -1
  230. package/dist/src/specification/v4/webapp/manifest/sapUi5.js +0 -11
  231. package/dist/src/specification/v4/webapp/manifest/sapUi5.js.map +0 -1
  232. package/dist/src/specification/v4/webapp/manifest/sapUiPageV4.js +0 -14
  233. package/dist/src/specification/v4/webapp/manifest/sapUiPageV4.js.map +0 -1
  234. package/dist/src/sync/common/appProvider.js +0 -57
  235. package/dist/src/sync/common/appProvider.js.map +0 -1
  236. package/dist/src/sync/common/decoration/control.js +0 -180
  237. package/dist/src/sync/common/decoration/control.js.map +0 -1
  238. package/dist/src/sync/common/decoration/decorators.js +0 -43
  239. package/dist/src/sync/common/decoration/decorators.js.map +0 -1
  240. package/dist/src/sync/common/decoration/factory.js +0 -50
  241. package/dist/src/sync/common/decoration/factory.js.map +0 -1
  242. package/dist/src/sync/common/decoration/flex.js +0 -8
  243. package/dist/src/sync/common/decoration/flex.js.map +0 -1
  244. package/dist/src/sync/common/decoration/index.js +0 -9
  245. package/dist/src/sync/common/decoration/index.js.map +0 -1
  246. package/dist/src/sync/common/flexUtils.js +0 -95
  247. package/dist/src/sync/common/flexUtils.js.map +0 -1
  248. package/dist/src/sync/common/generate/index.js +0 -8
  249. package/dist/src/sync/common/generate/index.js.map +0 -1
  250. package/dist/src/sync/common/generate/objectPage.js +0 -336
  251. package/dist/src/sync/common/generate/objectPage.js.map +0 -1
  252. package/dist/src/sync/common/generate/utils.js +0 -205
  253. package/dist/src/sync/common/generate/utils.js.map +0 -1
  254. package/dist/src/sync/common/i18n.json +0 -21
  255. package/dist/src/sync/common/import/utils.js +0 -75
  256. package/dist/src/sync/common/import/utils.js.map +0 -1
  257. package/dist/src/sync/common/importProject.js +0 -351
  258. package/dist/src/sync/common/importProject.js.map +0 -1
  259. package/dist/src/sync/common/index.js +0 -15
  260. package/dist/src/sync/common/index.js.map +0 -1
  261. package/dist/src/sync/common/types.js +0 -82
  262. package/dist/src/sync/common/types.js.map +0 -1
  263. package/dist/src/sync/common/utils.js +0 -1056
  264. package/dist/src/sync/common/utils.js.map +0 -1
  265. package/dist/src/sync/i18n.js +0 -15
  266. package/dist/src/sync/i18n.js.map +0 -1
  267. package/dist/src/sync/v2/application.js +0 -170
  268. package/dist/src/sync/v2/application.js.map +0 -1
  269. package/dist/src/sync/v2/export/controls/Action.js +0 -74
  270. package/dist/src/sync/v2/export/controls/Action.js.map +0 -1
  271. package/dist/src/sync/v2/export/controls/AnalyticalListPageChart.js +0 -72
  272. package/dist/src/sync/v2/export/controls/AnalyticalListPageChart.js.map +0 -1
  273. package/dist/src/sync/v2/export/controls/AnalyticalListPageKPI.js +0 -56
  274. package/dist/src/sync/v2/export/controls/AnalyticalListPageKPI.js.map +0 -1
  275. package/dist/src/sync/v2/export/controls/Card.js +0 -655
  276. package/dist/src/sync/v2/export/controls/Card.js.map +0 -1
  277. package/dist/src/sync/v2/export/controls/Field.js +0 -32
  278. package/dist/src/sync/v2/export/controls/Field.js.map +0 -1
  279. package/dist/src/sync/v2/export/controls/FilterBar.js +0 -245
  280. package/dist/src/sync/v2/export/controls/FilterBar.js.map +0 -1
  281. package/dist/src/sync/v2/export/controls/FormAction.js +0 -95
  282. package/dist/src/sync/v2/export/controls/FormAction.js.map +0 -1
  283. package/dist/src/sync/v2/export/controls/Fragment.js +0 -401
  284. package/dist/src/sync/v2/export/controls/Fragment.js.map +0 -1
  285. package/dist/src/sync/v2/export/controls/ObjectPageChart.js +0 -37
  286. package/dist/src/sync/v2/export/controls/ObjectPageChart.js.map +0 -1
  287. package/dist/src/sync/v2/export/controls/ObjectPageCustomSection.js +0 -110
  288. package/dist/src/sync/v2/export/controls/ObjectPageCustomSection.js.map +0 -1
  289. package/dist/src/sync/v2/export/controls/ObjectPageFooterAction.js +0 -62
  290. package/dist/src/sync/v2/export/controls/ObjectPageFooterAction.js.map +0 -1
  291. package/dist/src/sync/v2/export/controls/ObjectPageHeader.js +0 -60
  292. package/dist/src/sync/v2/export/controls/ObjectPageHeader.js.map +0 -1
  293. package/dist/src/sync/v2/export/controls/ObjectPageHeaderAction.js +0 -62
  294. package/dist/src/sync/v2/export/controls/ObjectPageHeaderAction.js.map +0 -1
  295. package/dist/src/sync/v2/export/controls/ObjectPageLayout.js +0 -59
  296. package/dist/src/sync/v2/export/controls/ObjectPageLayout.js.map +0 -1
  297. package/dist/src/sync/v2/export/controls/ObjectPageSectionsV2.js +0 -144
  298. package/dist/src/sync/v2/export/controls/ObjectPageSectionsV2.js.map +0 -1
  299. package/dist/src/sync/v2/export/controls/ObjectPageTable.js +0 -323
  300. package/dist/src/sync/v2/export/controls/ObjectPageTable.js.map +0 -1
  301. package/dist/src/sync/v2/export/controls/ObjectPageToolBarAction.js +0 -59
  302. package/dist/src/sync/v2/export/controls/ObjectPageToolBarAction.js.map +0 -1
  303. package/dist/src/sync/v2/export/controls/Table.js +0 -667
  304. package/dist/src/sync/v2/export/controls/Table.js.map +0 -1
  305. package/dist/src/sync/v2/export/controls/TableColumn.js +0 -41
  306. package/dist/src/sync/v2/export/controls/TableColumn.js.map +0 -1
  307. package/dist/src/sync/v2/export/controls/ToolBar.js +0 -6
  308. package/dist/src/sync/v2/export/controls/ToolBar.js.map +0 -1
  309. package/dist/src/sync/v2/export/controls/index.js +0 -26
  310. package/dist/src/sync/v2/export/controls/index.js.map +0 -1
  311. package/dist/src/sync/v2/export/export.js +0 -592
  312. package/dist/src/sync/v2/export/export.js.map +0 -1
  313. package/dist/src/sync/v2/export/exportPage.js +0 -312
  314. package/dist/src/sync/v2/export/exportPage.js.map +0 -1
  315. package/dist/src/sync/v2/export/factory.js +0 -59
  316. package/dist/src/sync/v2/export/factory.js.map +0 -1
  317. package/dist/src/sync/v2/export/manifest.js +0 -117
  318. package/dist/src/sync/v2/export/manifest.js.map +0 -1
  319. package/dist/src/sync/v2/export/pages/AnalyticalListPage.js +0 -41
  320. package/dist/src/sync/v2/export/pages/AnalyticalListPage.js.map +0 -1
  321. package/dist/src/sync/v2/export/pages/ListReport.js +0 -38
  322. package/dist/src/sync/v2/export/pages/ListReport.js.map +0 -1
  323. package/dist/src/sync/v2/export/pages/ObjectPage.js +0 -100
  324. package/dist/src/sync/v2/export/pages/ObjectPage.js.map +0 -1
  325. package/dist/src/sync/v2/export/pages/OverviewPage.js +0 -178
  326. package/dist/src/sync/v2/export/pages/OverviewPage.js.map +0 -1
  327. package/dist/src/sync/v2/export/pages/index.js +0 -10
  328. package/dist/src/sync/v2/export/pages/index.js.map +0 -1
  329. package/dist/src/sync/v2/export/view-controller-generator.js +0 -157
  330. package/dist/src/sync/v2/export/view-controller-generator.js.map +0 -1
  331. package/dist/src/sync/v2/generate/analyticalListReport.js +0 -87
  332. package/dist/src/sync/v2/generate/analyticalListReport.js.map +0 -1
  333. package/dist/src/sync/v2/generate/generate.js +0 -96
  334. package/dist/src/sync/v2/generate/generate.js.map +0 -1
  335. package/dist/src/sync/v2/generate/index.js +0 -14
  336. package/dist/src/sync/v2/generate/index.js.map +0 -1
  337. package/dist/src/sync/v2/generate/listReport.js +0 -113
  338. package/dist/src/sync/v2/generate/listReport.js.map +0 -1
  339. package/dist/src/sync/v2/generate/objectPage.js +0 -556
  340. package/dist/src/sync/v2/generate/objectPage.js.map +0 -1
  341. package/dist/src/sync/v2/generate/overviewPage.js +0 -73
  342. package/dist/src/sync/v2/generate/overviewPage.js.map +0 -1
  343. package/dist/src/sync/v2/generate/utils.js +0 -347
  344. package/dist/src/sync/v2/generate/utils.js.map +0 -1
  345. package/dist/src/sync/v2/import/app/appProvider.js +0 -122
  346. package/dist/src/sync/v2/import/app/appProvider.js.map +0 -1
  347. package/dist/src/sync/v2/import/app/ovpProvider.js +0 -33
  348. package/dist/src/sync/v2/import/app/ovpProvider.js.map +0 -1
  349. package/dist/src/sync/v2/import/common/index.js +0 -213
  350. package/dist/src/sync/v2/import/common/index.js.map +0 -1
  351. package/dist/src/sync/v2/import/controls/table.js +0 -31
  352. package/dist/src/sync/v2/import/controls/table.js.map +0 -1
  353. package/dist/src/sync/v2/import/getPageType.js +0 -1
  354. package/dist/src/sync/v2/import/getPageType.js.map +0 -1
  355. package/dist/src/sync/v2/import/index.js +0 -11
  356. package/dist/src/sync/v2/import/index.js.map +0 -1
  357. package/dist/src/sync/v2/import/pages/analyticalListPage.js +0 -104
  358. package/dist/src/sync/v2/import/pages/analyticalListPage.js.map +0 -1
  359. package/dist/src/sync/v2/import/pages/listReport.js +0 -234
  360. package/dist/src/sync/v2/import/pages/listReport.js.map +0 -1
  361. package/dist/src/sync/v2/import/pages/objectPage.js +0 -620
  362. package/dist/src/sync/v2/import/pages/objectPage.js.map +0 -1
  363. package/dist/src/sync/v2/import/pages/overviewPage.js +0 -113
  364. package/dist/src/sync/v2/import/pages/overviewPage.js.map +0 -1
  365. package/dist/src/sync/v2/import/utils.js +0 -103
  366. package/dist/src/sync/v2/import/utils.js.map +0 -1
  367. package/dist/src/sync/v2/types.js +0 -26
  368. package/dist/src/sync/v2/types.js.map +0 -1
  369. package/dist/src/sync/v4/application.js +0 -80
  370. package/dist/src/sync/v4/application.js.map +0 -1
  371. package/dist/src/sync/v4/export/controls/FilterBar.js +0 -6
  372. package/dist/src/sync/v4/export/controls/FilterBar.js.map +0 -1
  373. package/dist/src/sync/v4/export/controls/ObjectPageCustomSection.js +0 -136
  374. package/dist/src/sync/v4/export/controls/ObjectPageCustomSection.js.map +0 -1
  375. package/dist/src/sync/v4/export/controls/ObjectPageHeader.js +0 -55
  376. package/dist/src/sync/v4/export/controls/ObjectPageHeader.js.map +0 -1
  377. package/dist/src/sync/v4/export/controls/ObjectPageHeaderSection.js +0 -65
  378. package/dist/src/sync/v4/export/controls/ObjectPageHeaderSection.js.map +0 -1
  379. package/dist/src/sync/v4/export/controls/ObjectPageLayout.js +0 -24
  380. package/dist/src/sync/v4/export/controls/ObjectPageLayout.js.map +0 -1
  381. package/dist/src/sync/v4/export/controls/ObjectPageTable.js +0 -245
  382. package/dist/src/sync/v4/export/controls/ObjectPageTable.js.map +0 -1
  383. package/dist/src/sync/v4/export/controls/ObjectPageTableColumn.js +0 -87
  384. package/dist/src/sync/v4/export/controls/ObjectPageTableColumn.js.map +0 -1
  385. package/dist/src/sync/v4/export/controls/ObjectPageToolBarAction.js +0 -21
  386. package/dist/src/sync/v4/export/controls/ObjectPageToolBarAction.js.map +0 -1
  387. package/dist/src/sync/v4/export/controls/Table.js +0 -318
  388. package/dist/src/sync/v4/export/controls/Table.js.map +0 -1
  389. package/dist/src/sync/v4/export/controls/TableColumn.js +0 -97
  390. package/dist/src/sync/v4/export/controls/TableColumn.js.map +0 -1
  391. package/dist/src/sync/v4/export/controls/ToolBar.js +0 -6
  392. package/dist/src/sync/v4/export/controls/ToolBar.js.map +0 -1
  393. package/dist/src/sync/v4/export/controls/ToolBarAction.js +0 -21
  394. package/dist/src/sync/v4/export/controls/ToolBarAction.js.map +0 -1
  395. package/dist/src/sync/v4/export/controls/index.js +0 -18
  396. package/dist/src/sync/v4/export/controls/index.js.map +0 -1
  397. package/dist/src/sync/v4/export/export.js +0 -418
  398. package/dist/src/sync/v4/export/export.js.map +0 -1
  399. package/dist/src/sync/v4/export/factory.js +0 -44
  400. package/dist/src/sync/v4/export/factory.js.map +0 -1
  401. package/dist/src/sync/v4/export/flexibleColumnLayout.js +0 -114
  402. package/dist/src/sync/v4/export/flexibleColumnLayout.js.map +0 -1
  403. package/dist/src/sync/v4/export/manifest.js +0 -208
  404. package/dist/src/sync/v4/export/manifest.js.map +0 -1
  405. package/dist/src/sync/v4/export/pages/AnalyticalListPage.js +0 -38
  406. package/dist/src/sync/v4/export/pages/AnalyticalListPage.js.map +0 -1
  407. package/dist/src/sync/v4/export/pages/ListReport.js +0 -33
  408. package/dist/src/sync/v4/export/pages/ListReport.js.map +0 -1
  409. package/dist/src/sync/v4/export/pages/ObjectPage.js +0 -39
  410. package/dist/src/sync/v4/export/pages/ObjectPage.js.map +0 -1
  411. package/dist/src/sync/v4/export/pages/index.js +0 -9
  412. package/dist/src/sync/v4/export/pages/index.js.map +0 -1
  413. package/dist/src/sync/v4/export/types.js +0 -3
  414. package/dist/src/sync/v4/export/types.js.map +0 -1
  415. package/dist/src/sync/v4/export/utils.js +0 -26
  416. package/dist/src/sync/v4/export/utils.js.map +0 -1
  417. package/dist/src/sync/v4/generate/generate.js +0 -47
  418. package/dist/src/sync/v4/generate/generate.js.map +0 -1
  419. package/dist/src/sync/v4/generate/index.js +0 -10
  420. package/dist/src/sync/v4/generate/index.js.map +0 -1
  421. package/dist/src/sync/v4/generate/listReport.js +0 -96
  422. package/dist/src/sync/v4/generate/listReport.js.map +0 -1
  423. package/dist/src/sync/v4/generate/objectPage.js +0 -395
  424. package/dist/src/sync/v4/generate/objectPage.js.map +0 -1
  425. package/dist/src/sync/v4/import/app/appProvider.js +0 -313
  426. package/dist/src/sync/v4/import/app/appProvider.js.map +0 -1
  427. package/dist/src/sync/v4/import/fragment.js +0 -130
  428. package/dist/src/sync/v4/import/fragment.js.map +0 -1
  429. package/dist/src/sync/v4/import/index.js +0 -9
  430. package/dist/src/sync/v4/import/index.js.map +0 -1
  431. package/dist/src/sync/v4/import/pages/analyticalListPage.js +0 -61
  432. package/dist/src/sync/v4/import/pages/analyticalListPage.js.map +0 -1
  433. package/dist/src/sync/v4/import/pages/listReport.js +0 -124
  434. package/dist/src/sync/v4/import/pages/listReport.js.map +0 -1
  435. package/dist/src/sync/v4/import/pages/objectPage.js +0 -231
  436. package/dist/src/sync/v4/import/pages/objectPage.js.map +0 -1
  437. package/dist/src/sync/v4/import/utils.js +0 -33
  438. package/dist/src/sync/v4/import/utils.js.map +0 -1
  439. package/dist/src/sync/v4/types.js +0 -3
  440. package/dist/src/sync/v4/types.js.map +0 -1
  441. package/dist/src/sync/v4/utils/StableIdHelper.js +0 -153
  442. package/dist/src/sync/v4/utils/StableIdHelper.js.map +0 -1
  443. package/dist/src/sync/v4/utils/utils.js +0 -94
  444. package/dist/src/sync/v4/utils/utils.js.map +0 -1
  445. package/dist/src/v2.js +0 -8
  446. package/dist/src/v2.js.map +0 -1
  447. package/dist/src/v4.js +0 -8
  448. package/dist/src/v4.js.map +0 -1
  449. package/dist/test/test-utils/metadataParser.d.ts +0 -19
@@ -1,4 +1,4 @@
1
- import { ObjectPageConfig } from '../../../../specification/v4/';
1
+ import { ObjectPageConfig as ObjectPageConfigV4 } from '../../../../specification/v4/';
2
2
  import { ImportObjectPageV4Parameters } from '../../../../apiTypes';
3
3
  /**
4
4
  * External API: Create configuration (file content) for a V4 object page
@@ -7,4 +7,4 @@ import { ImportObjectPageV4Parameters } from '../../../../apiTypes';
7
7
  *
8
8
  * @returns {ObjectPageConfig} config - the object page configuration
9
9
  */
10
- export declare function createObjectPageConfigV4(importParameters: ImportObjectPageV4Parameters): ObjectPageConfig | undefined;
10
+ export declare function createObjectPageConfigV4(importParameters: ImportObjectPageV4Parameters): ObjectPageConfigV4 | undefined;
@@ -1,4 +1,17 @@
1
1
  import { AnnotationTerm, ConverterOutput, EntityType, LineItem, DataFieldForActionAbstractTypes } from '@sap-ux/vocabularies-types';
2
+ import { EntitySet } from '@sap-ux/annotation-converter';
3
+ import { ExtensionLogger } from '../../..';
4
+ import { DefinitionName, SapUiAppPageV4 } from '../../../v4';
5
+ /**
6
+ * Common function for enhancing the LineItems definiton of app schema by custom columns
7
+ * @param appSchema - app-specific JSON schema
8
+ * @param v4Page - actual page in the manifest
9
+ * @param logger - logger for error messages
10
+ * @param customColumnDefinitionName - custom column definition name
11
+ * @param sectionId - identifier of the current object page section in schema
12
+ * @param sectionIdInManfest - identifier of the current object page section in manifest
13
+ */
14
+ export declare function addCustomColumnDefinition(appSchema: object, v4Page: SapUiAppPageV4, logger: ExtensionLogger, customColumnDefinitionName?: string, sectionId?: string, sectionIdInManfest?: string): void;
2
15
  /**
3
16
  * Processes a LineItem record of type DataFieldForCation during app schema generation
4
17
  * @param appSchema - the app specific schema that shall get enhanced
@@ -19,5 +32,23 @@ export declare function handleActionRecord(appSchema: object, entityType: Entity
19
32
  * @param actionDefinitionName - indicates the prefix for the definition, dpending on the page type
20
33
  * @param lineItemId - optional: in case of OP the paramter must be passed to distinguish the OP tables;
21
34
  * in case of LR or ALP no ID is passed, 'LineItems' is taken then.
35
+ * @param customColumnRef - schema reference to custom column definition.
36
+ */
37
+ export declare function addLineItemsType(appSchema: object, lineItemAnnotation: AnnotationTerm<LineItem>, entityType: EntityType, oDataServiceAVT: ConverterOutput, columnDefinitionName?: string, customColumnDefinitionName?: string, lineItemId?: string): void;
38
+ /**
39
+ * Adds an enum or value help to position > anchor of custom column
40
+ * @param appSchema - app specific JSON schema
41
+ * @param lineItemId - ID of the current line item in schema
42
+ * @param v4Page - current page in manifest
43
+ * @param positionName - ID of the definition of custom column position in schema
44
+ */
45
+ export declare function addFragmentEnumForAnchor(appSchema: object, lineItemId: string, v4Page: SapUiAppPageV4, positionName?: DefinitionName, sectionIdInManifest?: string): void;
46
+ /**
47
+ * Find the relevant V4 page under the routing targets of manifest,json
48
+ * @param pages - list of all pages in manifest
49
+ * @param pageName - search criterion: page name
50
+ * @param entitySet - search criterion: entty set
51
+ * @param logger - logger for messages
52
+ * @returns the page definition in manifest (if found)
22
53
  */
23
- export declare function addLineItemsType(appSchema: object, lineItemAnnotation: AnnotationTerm<LineItem>, entityType: EntityType, oDataServiceAVT: ConverterOutput, columnDefinitionName: string, lineItemId?: string): void;
54
+ export declare function findPageV4(pages: SapUiAppPageV4[], pageName: string, entitySet: EntitySet, logger: ExtensionLogger): SapUiAppPageV4 | undefined;
@@ -1 +1 @@
1
- export {};
1
+ export declare function readAndPushFlexChange(flexChanges: string[], action: string, projectPath: string[], fakeFlexChange?: boolean): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sap/ux-specification",
3
- "version": "1.96.2",
3
+ "version": "1.96.5",
4
4
  "displayName": "SAP Fiori tools - Specification",
5
5
  "description": "SAP Fiori tools - Specification",
6
6
  "files": [
@@ -18,38 +18,40 @@
18
18
  },
19
19
  "scripts": {
20
20
  "clean": "rimraf ./dist ./schemas",
21
- "build": "yarn run clean && tsc --project ./tsconfig.build.json && yarn run create-json-schemas && yarn copy-json-schemas && webpack --color --config webpack.prod.js && yarn copy-templates && yarn run generate-html-prod && rimraf ../schemas",
21
+ "build": "yarn run clean && tsc --project ./tsconfig.build.json && yarn run create-json-schemas && yarn copy-json-schemas && webpack --color --config webpack.prod.js && yarn copy-templates && yarn run generate-html-prod",
22
22
  "build:dev": "yarn run clean && tsc --project ./tsconfig.build.json && yarn run create-json-schemas && yarn copy-json-schemas && webpack --color --config webpack.prod.js && yarn copy-templates",
23
- "watch": "yarn run clean && tsc --project ./tsconfig.build.json && yarn run create-json-schemas && yarn copy-json-schemas && yarn copy-templates && webpack --color --config webpack.dev.js",
23
+ "watch": "yarn run clean && tsc --project ./tsconfig.build.json && yarn run create-json-schemas && yarn copy-json-schemas && webpack --color --config webpack.dev.js && yarn copy-templates",
24
24
  "watch-docu": "yarn run generate-html-dev",
25
- "create-json-schemas": "node dist/scripts/to-json-schema.js",
26
- "copy-json-schemas": "cpy schemas/** dist --parents",
25
+ "create-json-schemas": "ts-node ./scripts/to-json-schema.ts ",
26
+ "copy-json-schemas": "cpy ./schemas/** dist --parents",
27
27
  "copy-templates": "cpy src/sync/v2/export/templates/** dist/templates",
28
- "test": "jest --colors && node ../../scripts/scov.js reports/test/unit/coverage/lcov.info",
28
+ "test": "jest && node ../../scripts/scov.js reports/test/unit/coverage/lcov.info",
29
+ "test:ci": "jest --ci --forceExit --detectOpenHandles && node ../../scripts/scov.js reports/test/unit/coverage/lcov.info",
29
30
  "update-snapshots": "jest --updateSnapshot",
30
31
  "lint": "eslint . --ext .ts",
31
32
  "lint:summary": "eslint . --ext .ts -f summary",
32
33
  "lint:fix": "eslint . --report-unused-disable-directives --ext .ts --fix",
33
34
  "lint:report": "eslint . --report-unused-disable-directives --ext .ts -f multiple",
34
35
  "lint:report:jslint": "eslint . --report-unused-disable-directives --ext .ts -o reports/lint/eslint.jslint.xml -f jslint-xml",
35
- "docuV2": "node dist/scripts/extractDocu.js --version=v2 format=excel",
36
- "docuV4": "node dist/scripts/extractDocu.js --version=v4 format=excel",
37
- "iXiaSoftV2": "node dist/scripts/extractDocu.js --version=v2 --format=iXiaSoft",
38
- "iXiaSoftV4": "node dist/scripts/extractDocu.js --version=v4 --format=iXiaSoft",
39
- "htmlV2": "node dist/scripts/extractDocu.js --version=v2 --format=html",
40
- "htmlV4": "node dist/scripts/extractDocu.js --version=v4 --format=html",
36
+ "docuV2": "ts-node ./scripts/extractDocu.ts --version=v2 format=excel",
37
+ "docuV4": "ts-node ./scripts/extractDocu.ts --version=v4 format=excel",
38
+ "iXiaSoftV2": "ts-node ./scripts/extractDocu.ts --version=v2 --format=iXiaSoft",
39
+ "iXiaSoftV4": "ts-node ./scripts/extractDocu.ts --version=v4 --format=iXiaSoft",
40
+ "htmlV2": "ts-node ./scripts/extractDocu.ts --version=v2 --format=html",
41
+ "htmlV4": "ts-node ./scripts/extractDocu.ts --version=v4 --format=html",
41
42
  "generate-html-prod": "yarn run htmlV2 && yarn run htmlV4 && webpack --color --config webpack.docu.prod.js ",
42
43
  "generate-html-dev": "yarn run htmlV2 && yarn run htmlV4 && webpack --color --config webpack.docu.dev.js"
43
44
  },
44
45
  "publisher": "SAPSE",
45
46
  "license": "SEE LICENSE IN LICENSE",
47
+ "dependencies": {
48
+ "@sap-ux/fe-fpm-writer": "0.4.0"
49
+ },
46
50
  "devDependencies": {
47
51
  "@sap-ux/annotation-converter": "0.3.39",
48
52
  "@sap-ux/edmx-parser": "0.3.39",
49
- "@sap-ux/fe-fpm-writer": "0.3.0",
50
53
  "@sap-ux/vocabularies-types": "0.3.39",
51
- "@sap/edm-converters": "1.0.40",
52
- "@sapui5/ts-types": "1.90.9",
54
+ "@sapui5/ts-types": "1.96.4",
53
55
  "@types/d3": "7.1.0",
54
56
  "@types/jest": "26.0.23",
55
57
  "@types/jquery": "3.5.6",
@@ -59,6 +61,7 @@
59
61
  "@typescript-eslint/parser": "4.14.1",
60
62
  "@ui5/flexibility-utils": "0.1.3",
61
63
  "ajv": "6.12.6",
64
+ "copy-webpack-plugin": "9.1.0",
62
65
  "cpy-cli": "3.1.1",
63
66
  "d3": "7.1.1",
64
67
  "deepmerge": "4.2.2",
@@ -70,7 +73,6 @@
70
73
  "http-server": "13.0.1",
71
74
  "i18next": "20.3.1",
72
75
  "jest": "26.6.3",
73
- "jest-file-snapshot": "0.5.0",
74
76
  "jest-sonar-reporter": "2.0.0",
75
77
  "jquery": "3.6.0",
76
78
  "lodash.unset": "4.5.2",
@@ -83,7 +85,7 @@
83
85
  "source-map-loader": "1.0.0",
84
86
  "terser-webpack-plugin": "4.2.3",
85
87
  "ts-jest": "26.5.6",
86
- "ts-json-schema-generator": "0.93.0",
88
+ "ts-json-schema-generator": "0.96.0",
87
89
  "ts-loader": "9.1.2",
88
90
  "ts-node": "9.1.1",
89
91
  "typescript": "3.8.3",
@@ -1,488 +0,0 @@
1
- "use strict";
2
- var __importStar = (this && this.__importStar) || function (mod) {
3
- if (mod && mod.__esModule) return mod;
4
- var result = {};
5
- if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
6
- result["default"] = mod;
7
- return result;
8
- };
9
- Object.defineProperty(exports, "__esModule", { value: true });
10
- /**
11
- * This script extracts all existing documentation (i.e. descriptions) from the generic schemas of a certain OData version (V2 or V4).
12
- * All descriptions are collected in an Excel sheet that you afterwards can find under dist/documentation: it is named Specificationv2.xslx or Specificationv4.xslx, depending on the chosen version.
13
- * You can find one worksheet for each generic schema file.
14
- *
15
- * The script expects that you supply an argument --version with either v2 or v4.
16
- * You can also start it from one of the debugger scripts named in launch.json: "Extract V2 documentation" or "Extract V4 documentation".
17
- */
18
- const page_1 = require("../src/specification/common/page");
19
- const path_1 = require("path");
20
- const fs = __importStar(require("fs"));
21
- const excel = __importStar(require("excel4node"));
22
- /**
23
- * Handles reference ($ref) within the schema, finds the corresponding definition
24
- * @param schema - Object representing the whole generic schema
25
- * @param reference - Content for the $ref property
26
- * @param output - Array of descriptions with assigned hierarchy elements, all separated by ';' (csv like)
27
- * @param definition - The current hierarchy element (list of path parts separated by ';')
28
- * @param description - The description of the current hierarchy element
29
- * @param additionalMetadata - Additional information about the current hierarchy element, separated by ';'
30
- */
31
- function dereference(schema, reference, output, definition, description, additionalMetadata) {
32
- const currentDefinition = reference.split('#/definitions/')[1];
33
- try {
34
- parseSchema(schema, schema['definitions'][currentDefinition], output, definition, description, additionalMetadata);
35
- }
36
- catch (error) {
37
- console.log(error);
38
- }
39
- }
40
- /**
41
- * Handles one property of a sub-schema
42
- * @param schema - Object representing the whole generic schema
43
- * @param subSchema - Object representing the current sub-structure of the schema
44
- * @param property - Name of the property within the subSchema
45
- * @param output - Array of descriptions with assigned hierarchy elements, all separated by ';' (csv like)
46
- * @param definition - The current hierarchy element (list of path parts separated by ';')
47
- */
48
- function processElement(schema, subSchema, property, output, definition) {
49
- function addMetadata() {
50
- if (additionalMetadata) {
51
- output.push(definition + ';' + `TYPE_${element['type']}` + additionalMetadata + ';' + element['description']);
52
- }
53
- else {
54
- output.push(definition + ';' + `TYPE_${element['type']}` + ';' + element['description']);
55
- }
56
- }
57
- if (['$schema', 'id', 'pages', 'home', 'custom', '1', '2', '3', '4', '5', '6', '7', '8', '9'].includes(property)) {
58
- return;
59
- }
60
- const element = subSchema[property];
61
- const property2write = property === '^[0-9]+$' ? 'Instance (key = number)' : property;
62
- definition = definition ? definition + ';' + property2write : property2write;
63
- if (property === 'columns') {
64
- definition = definition + ';columnId';
65
- }
66
- if (property === 'sections') {
67
- definition = definition + ';sectionId';
68
- }
69
- if (property === 'cards') {
70
- definition = definition + ';cardKey';
71
- }
72
- let additionalMetadata;
73
- if (element['artifactType']) {
74
- additionalMetadata = `;ARTIFACT_${element['artifactType']}`;
75
- }
76
- if (element['controlType']) {
77
- additionalMetadata += `;CONTROL_${element['controlType']}`;
78
- }
79
- if (element['description']) {
80
- if (element['$ref']) {
81
- dereference(schema, element['$ref'], output, definition, element['description'], additionalMetadata);
82
- return;
83
- }
84
- else if (element['anyOf']) {
85
- handleAnyOf(schema, element['anyOf'], output, definition, element['description'], element, additionalMetadata);
86
- return;
87
- }
88
- if (element['type'] && element['items']) {
89
- const reference = element['items']['$ref'] || (element['items'][0] && element['items'][0]['$ref']);
90
- if (reference) {
91
- dereference(schema, reference, output, definition, element['description'], additionalMetadata);
92
- }
93
- else {
94
- addMetadata();
95
- }
96
- return;
97
- }
98
- addMetadata();
99
- }
100
- // Temporary as Description is not maintained for some properties - description should be added
101
- if (!element['description'] && element['type']) {
102
- if (additionalMetadata) {
103
- output.push(definition + ';' + `TYPE_${element['type']}` + additionalMetadata);
104
- }
105
- else {
106
- output.push(definition + ';' + `TYPE_${element['type']}`);
107
- }
108
- }
109
- if (element['$ref']) {
110
- dereference(schema, element['$ref'], output, definition);
111
- }
112
- else {
113
- parseSchema(schema, element, output, definition);
114
- }
115
- }
116
- /**
117
- * Special handling of anyOf elements of a JSON schema
118
- * @param schema - Object representing the whole generic schema
119
- * @param anyOfSchema - Object representing the current sub-structure of the schema
120
- * @param output - Array of descriptions with assigned hierarchy elements, all separated by ';' (csv like)
121
- * @param definition - The current hierarchy element (list of path parts separated by ';')
122
- * @param description - The description of the current hierarchy element
123
- * @param element - Object representing the sub-structure of the current hierarchy element
124
- * @param additionalMetadata - Additional information about the current hierarchy element, separated by ';' (e.g. artifactType)
125
- */
126
- function handleAnyOf(schema, anyOfSchema, output, definition, description, element, additionalMetadata) {
127
- for (let index = 0; index < anyOfSchema.length; index++) {
128
- const anyOfSchemaElement = anyOfSchema[index];
129
- if ((element === null || element === void 0 ? void 0 : element['pattern']) && anyOfSchemaElement['type'] === 'string') {
130
- return;
131
- }
132
- if (Object.keys(anyOfSchemaElement)[0] === '$ref') {
133
- dereference(schema, anyOfSchemaElement['$ref'], output, definition, description, additionalMetadata);
134
- }
135
- else {
136
- parseSchema(schema, anyOfSchemaElement, output, definition, description, additionalMetadata);
137
- }
138
- }
139
- }
140
- /**
141
- * Parses a sub-structure of the schema
142
- * @param schema - Object representing the whole generic schema
143
- * @param subSchema - Object representing the current sub-structure of the schema
144
- * @param output - Array of descriptions with assigned hierarchy elements, all separated by ';' (csv like)
145
- * @param definition - The current hierarchy element (list of path parts separated by ';')
146
- * @param description - The description of the current hierarchy element
147
- * @param additionalMetadata - Additional information about the current hierarchy element, separated by ';' (e.g. artifactType)
148
- */
149
- function parseSchema(schema, subSchema, output, definition, description, additionalMetadata) {
150
- if (Object.keys(subSchema) && Object.keys(subSchema)[0] === 'anyOf') {
151
- handleAnyOf(schema, subSchema['anyOf'], output, definition);
152
- return;
153
- }
154
- for (const property in subSchema['properties']) {
155
- if (property === '$ref') {
156
- dereference(schema, subSchema['properties']['$ref'], output, definition);
157
- }
158
- else if (property === 'anyOf') {
159
- handleAnyOf(schema, subSchema['properties']['anyOf'], output, definition);
160
- }
161
- else {
162
- processElement(schema, subSchema['properties'], property, output, definition);
163
- }
164
- }
165
- for (const property in subSchema['patternProperties']) {
166
- if (property === '$ref') {
167
- dereference(schema, subSchema['patternProperties']['$ref'], output, definition);
168
- }
169
- else if (property === 'anyOf') {
170
- handleAnyOf(schema, subSchema['patternProperties']['anyOf'], output, definition);
171
- }
172
- else {
173
- processElement(schema, subSchema['patternProperties'], property, output, definition);
174
- }
175
- }
176
- for (const property in subSchema['additionalProperties']) {
177
- if (property === '$ref') {
178
- dereference(schema, subSchema['additionalProperties']['$ref'], output, definition);
179
- }
180
- else if (property === 'anyOf') {
181
- handleAnyOf(schema, subSchema['additionalProperties']['anyOf'], output, definition);
182
- }
183
- else {
184
- processElement(schema, subSchema['additionalProperties'], property, output, definition);
185
- }
186
- }
187
- if (subSchema['enum'] && description) {
188
- if (additionalMetadata) {
189
- output.push(definition + ';' + `TYPE_${[subSchema['enum'].join('|')]}` + additionalMetadata + ';' + description);
190
- }
191
- else {
192
- output.push(definition + ';' + `TYPE_${[subSchema['enum'].join('|')]}` + ';' + description);
193
- }
194
- }
195
- else if (subSchema['type'] && description) {
196
- if (additionalMetadata) {
197
- output.push(definition + ';' + `TYPE_${subSchema['type']}` + additionalMetadata + ';' + description);
198
- }
199
- else {
200
- output.push(definition + ';' + `TYPE_${subSchema['type']}` + ';' + description);
201
- }
202
- }
203
- }
204
- /**
205
- * Fills an excel4node workbook based on csv like information
206
- * @param workbook - Excel workbook (excel4node format)
207
- * @param output - Array of descriptions with assigned hierarchy elements, all separated by ';' (csv like)
208
- * @param file - file name of the original schema
209
- */
210
- function writeToExcel(workbook, output, file) {
211
- //filter output to remove duplicated lines due to different table types (anyOf)
212
- output = output.filter((e, i, a) => a.indexOf(e) === i);
213
- const sheetName = file.split('.')[0];
214
- const worksheet = workbook.addWorksheet(sheetName);
215
- worksheet.headerFooter = { evenHeader: output[0] };
216
- // Create a reusable style
217
- const style = workbook.createStyle({
218
- font: {
219
- //color: '#800000',
220
- size: 12
221
- },
222
- numberFormat: '$#,##0.00; ($#,##0.00); -'
223
- });
224
- for (let rowIndex = 1; rowIndex < output.length; rowIndex++) {
225
- const element = output[rowIndex];
226
- const cellArray = element.split(';');
227
- for (let cellIndex = 0; cellIndex < cellArray.length; cellIndex++) {
228
- const cell = cellArray[cellIndex];
229
- worksheet
230
- .cell(rowIndex, cellIndex + 1)
231
- .string(cell)
232
- .style(style);
233
- }
234
- }
235
- }
236
- function generateIxiaSoftFormat(output, file, version) {
237
- //filter output to remove duplicated lines due to different table types (anyOf)
238
- output = output.filter((e, i, a) => a.indexOf(e) === i);
239
- let iXiaFormat = `<simpletable frame="all" relcolwidth="1* 1*" id="simpletable_uqj_klr_jlb">
240
- <sthead>
241
- <stentry> Settings </stentry>
242
- <stentry> Description </stentry>
243
- </sthead>
244
- `;
245
- const fileName = file.split('.')[0];
246
- for (let rowIndex = 1; rowIndex < output.length; rowIndex++) {
247
- const element = output[rowIndex];
248
- const cellArray = element.split(';');
249
- let setting = '{';
250
- iXiaFormat = iXiaFormat + `\t<strow>\n`;
251
- for (let cellIndex = 0; cellIndex < cellArray.length - 1; cellIndex++) {
252
- let cell = cellArray[cellIndex];
253
- if (['0', '1'].includes(cell)) {
254
- cell = 'variantKey' + cell;
255
- }
256
- if (cellArray[cellIndex + 1].includes('TYPE')) {
257
- setting = setting + `"${cell}": ${cellArray[cellIndex + 1].split('_')[1]}`;
258
- let noOfOpeningBraces = setting.match(/{/g).length;
259
- while (noOfOpeningBraces > 0) {
260
- setting = setting + '}';
261
- noOfOpeningBraces--;
262
- }
263
- iXiaFormat = iXiaFormat + `\t\t<stentry> ${setting} </stentry>\n`;
264
- }
265
- else {
266
- setting = setting + `"${cell}": {`;
267
- }
268
- }
269
- // add description to the table
270
- iXiaFormat = iXiaFormat + `\t\t<stentry> ${cellArray[cellArray.length - 1]} </stentry>\n\t</strow>\n`;
271
- }
272
- iXiaFormat = iXiaFormat + `</simpletable>`;
273
- const outDir = path_1.join('dist', 'documentation');
274
- if (!fs.existsSync(outDir)) {
275
- fs.mkdirSync(outDir);
276
- }
277
- const outFile = path_1.join(outDir, 'Specification' + version + fileName + '.txt');
278
- fs.writeFile(outFile, iXiaFormat, (err) => {
279
- if (err)
280
- throw err;
281
- console.log(`${outFile} was succesfully saved!`);
282
- });
283
- }
284
- function createNestedJSON(output, floorPlan, odataVersion, specVersion) {
285
- let root;
286
- const tree = {
287
- name: floorPlan,
288
- description: 'SAP Fiori elements ' + odataVersion + '<br>Specification Version: ' + specVersion,
289
- type: 'schema',
290
- children: []
291
- };
292
- function find(string) {
293
- if (string.includes('ARTIFACT_')) {
294
- return 'artifact';
295
- }
296
- else if (string.includes('CONTROL_')) {
297
- return 'control';
298
- }
299
- else {
300
- return 'description';
301
- }
302
- }
303
- function addKeyValue(element, index, elementsArray) {
304
- if (element.includes('TYPE_')) {
305
- root.type = element.split('_')[1];
306
- for (let i = index + 1; i < elementsArray.length; i++) {
307
- const match = find(elementsArray[i]);
308
- switch (match) {
309
- case 'artifact':
310
- root.artifact = elementsArray[i].split('_')[1];
311
- break;
312
- case 'control':
313
- root.control = elementsArray[i].split('_')[1];
314
- break;
315
- default:
316
- root.description = elementsArray[i];
317
- }
318
- }
319
- return false;
320
- }
321
- else {
322
- for (let i = 0; i < root.children.length; i++) {
323
- if (element === root.children[i].name) {
324
- root = root.children[i];
325
- return true;
326
- }
327
- }
328
- root.children.push({
329
- name: element,
330
- children: []
331
- });
332
- root = root.children[root.children.length - 1];
333
- return true;
334
- }
335
- }
336
- output.forEach((line) => {
337
- const elements = line.split(';');
338
- root = tree;
339
- elements.every(addKeyValue);
340
- });
341
- return tree;
342
- }
343
- function createSVGIcon(floorPlan) {
344
- let svgFormat = `<svg id="floorPlan-icon" width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
345
- <g><path fill-rule="evenodd" clip-rule="evenodd" fill="#C5C5C5"`;
346
- const svgPathALP = `d="M9 13V14H6V13H9ZM5 13V14H2V13H5ZM13 13V14H10V13H13ZM9 11V12H6V11H9ZM5 11V12H2V11H5ZM13 11V12H10V11H13ZM5 9V10H2V9H5ZM9 9V10H6V9H9ZM13 9V10H10V9H13ZM3.986 1.998V6.024H1.965V1.998H3.986ZM6.99 4.01V6.01H4.99V4.01H6.99ZM10.008 3.019V6.01H8.008V3.019H10.008ZM13.005 1.998V6.011H11.005V1.998H13.005ZM1 14.988H14.988V7.995H1V14.988ZM1.001 6.994H14.989V1H1.001V6.994ZM1.00169 0C0.449309 0 0 0.448336 0 1.00075V14.9992C0 15.5517 0.449309 16 1.00169 16H14.9993C15.5517 16 16 15.5517 16 14.9992V1.00075C16 0.448336 15.5517 0 14.9993 0H1.00169Z"`;
347
- const svgPathLR = `d="M5 3.0028H2V2.0048H5V3.0028ZM6.0044 3.0028H9.0044V2.0048H6.0044V3.0028ZM10.0014 3.0028H13.0014V2.0048H10.0014V3.0028ZM1 14.993L0.997 4.995H14.988V14.988L1 14.993ZM14.988 0.995V3.994H0.996L0.995 1L14.988 0.995ZM14 7H10V6H14V7ZM11 9.0028H14V8.0048H11V9.0028ZM14 11H10V10H14V11ZM14 13.0028H11V12.0048H14V13.0028ZM6 12.999H9V12.001H6V12.999ZM9 10.999H6V10.001H9V10.999ZM6 8.999H9V8.001H6V8.999ZM9 6.999H6V6.001H9V6.999ZM2 12.999H5V12.001H2V12.999ZM5 11.0028H2V10.0048H5V11.0028ZM2 9.0028H5V8.0048H2V9.0028ZM5 6.999H2V6.001H5V6.999ZM14.993 0H0.995C0.446 0 0 0.446 0 0.995V14.993C0 15.542 0.446 15.988 0.995 15.988H14.993C15.542 15.988 15.988 15.542 15.988 14.993V0.995C15.988 0.446 15.542 0 14.993 0Z"`;
348
- const svgPathOP = `d="M9 13V14H6V13H9ZM9 11V12H6V11H9ZM13 9V10H10V9H13ZM9 9V10H6V9H9ZM5 9V10H2V9H5ZM14.989 7.996L14.988 14.989H1L1.001 7.996H14.989ZM3.998 2C5.1 2 5.996 2.896 5.996 3.998C5.996 5.1 5.1 5.996 3.998 5.996C2.896 5.996 2 5.1 2 3.998C2 2.896 2.896 2 3.998 2ZM14 4.0046V5.0046H8V4.0046H14ZM3.998 3C3.447 3 3 3.447 3 3.998C3 4.549 3.447 4.996 3.998 4.996C4.549 4.996 4.996 4.549 4.996 3.998C4.996 3.447 4.549 3 3.998 3ZM12.002 2V3H8V2H12.002ZM14.989 1.001V6.995H1.001V1L14.989 1.001ZM14.989 0H1.001C0.449 0 0 0.449 0 1.001V14.989C0 15.541 0.449 15.989 1.001 15.989H14.989C15.541 15.989 15.989 15.541 15.989 14.989V1.001C15.989 0.488429 15.6027 0.0646684 15.1056 0.00674636L14.989 0Z"`;
349
- const svgPathOVP = `d="M14.988 15.488V14.988H14.989L14.988 15.488ZM14.988 14.988H1V1H14.988V14.988ZM14.988 0H1C0.448 0 0 0.448 0 1V14.988C0 15.54 0.448 15.988 1 15.988H14.988C15.54 15.988 15.988 15.54 15.988 14.988V1C15.988 0.448 15.54 0 14.988 0ZM2.9917 7.037H7.0147V3.014H2.9917V7.037ZM7.5147 2.013H2.4907C2.2147 2.013 1.9907 2.237 1.9907 2.513V7.537C1.9907 7.813 2.2147 8.037 2.4907 8.037H7.5147C7.7907 8.037 8.0147 7.813 8.0147 7.537V2.513C8.0147 2.237 7.7907 2.013 7.5147 2.013ZM7.0147 13.014H2.9917V10.034H7.0147V13.014ZM2.4907 9.034H7.5147C7.7907 9.034 8.0147 9.258 8.0147 9.534V13.514C8.0147 13.791 7.7907 14.014 7.5147 14.014H2.4907C2.2147 14.014 1.9907 13.791 1.9907 13.514V9.534C1.9907 9.258 2.2147 9.034 2.4907 9.034ZM9.9847 9.034H13.0217V3.013H9.9847V9.034ZM13.5217 2.013H9.4847C9.2087 2.013 8.9847 2.237 8.9847 2.513V9.534C8.9847 9.81 9.2087 10.034 9.4847 10.034H13.5217C13.7987 10.034 14.0217 9.81 14.0217 9.534V2.513C14.0217 2.237 13.7987 2.013 13.5217 2.013ZM13.0217 13.006H9.9847V12.021H13.0217V13.006ZM9.4847 11.02H13.5217C13.7987 11.02 14.0217 11.244 14.0217 11.52V13.506C14.0217 13.782 13.7987 14.006 13.5217 14.006H9.4847C9.2087 14.006 8.9847 13.782 8.9847 13.506V11.52C8.9847 11.244 9.2087 11.02 9.4847 11.02Z"`;
350
- const name = floorPlan.toLowerCase();
351
- if (name.includes('analytical'))
352
- svgFormat += svgPathALP;
353
- else if (name.includes('listreport'))
354
- svgFormat += svgPathLR;
355
- else if (name.includes('objectpage'))
356
- svgFormat += svgPathOP;
357
- else if (name.includes('overviewpage'))
358
- svgFormat += svgPathOVP;
359
- else
360
- return undefined;
361
- svgFormat += `/></g></svg>`;
362
- return svgFormat;
363
- }
364
- function generateHTMLFormat(output, file, odataVersion) {
365
- //filter output to remove duplicated lines due to different table types (anyOf)
366
- output = output.filter((e, i, a) => a.indexOf(e) === i);
367
- const nameFloorPlan = file.split('.')[0].replace(/Config/g, '');
368
- const packageJson = JSON.parse(fs.readFileSync(path_1.join(__dirname, '/../../package.json'), 'utf8'));
369
- const specVersion = packageJson.version;
370
- output.shift();
371
- const svgIcon = createSVGIcon(nameFloorPlan);
372
- const treeData = createNestedJSON(output, nameFloorPlan, odataVersion, specVersion);
373
- const templateFilePath = path_1.join(__dirname, '/../../scripts/templateDocu.html');
374
- let template;
375
- try {
376
- template = fs.readFileSync(templateFilePath, 'utf8');
377
- }
378
- catch (e) {
379
- console.log(`Error: ${e.message}`);
380
- }
381
- template = template.replace(`'insertDataHere'`, JSON.stringify(treeData));
382
- if (svgIcon !== undefined) {
383
- template = template.replace(`floorPlanIcon`, 'floorPlanIcon = `' + svgIcon + '`');
384
- }
385
- let outDir;
386
- if (odataVersion === 'v2') {
387
- outDir = path_1.join('dist', 'documentation', 'v2');
388
- }
389
- else {
390
- outDir = path_1.join('dist', 'documentation', 'v4');
391
- }
392
- if (!fs.existsSync(outDir)) {
393
- fs.mkdirSync(outDir, { recursive: true });
394
- }
395
- const outFile = path_1.join(outDir, odataVersion + '-' + nameFloorPlan + '.html');
396
- fs.writeFile(outFile, template, (err) => {
397
- if (err)
398
- throw err;
399
- console.log(`${outFile} was successfully saved!`);
400
- });
401
- }
402
- function copyFileToFolder() {
403
- const file = 'styleDocu.css';
404
- const src = path_1.join(__dirname + '/../../scripts/' + file);
405
- const dest = path_1.join('dist', 'documentation', file);
406
- if (!fs.existsSync(dest)) {
407
- fs.copyFile(src, dest, (err) => {
408
- if (err)
409
- throw err;
410
- if (!err) {
411
- console.log(file + ' has been copied!');
412
- }
413
- });
414
- }
415
- }
416
- /**
417
- * Writes an Excel workbook to a file in the dist/documentation folder.
418
- * @param workbook - Excel workbook (excel4node format)
419
- * @param version - OData version
420
- */
421
- function writeToFile(workbook, version) {
422
- const outDir = path_1.join('dist', 'documentation');
423
- if (!fs.existsSync(outDir)) {
424
- fs.mkdirSync(outDir);
425
- }
426
- const outFile = path_1.join(outDir, 'Specification' + version + '.xlsx');
427
- workbook.write(outFile);
428
- }
429
- /********************** Main ***************************/
430
- function generateDocmentation() {
431
- const myArgs = process.argv.slice(2);
432
- let version;
433
- let format;
434
- myArgs.forEach((arg) => {
435
- const value = arg.split('=')[1];
436
- if (arg.includes('version')) {
437
- version = value;
438
- }
439
- else if (arg.includes('format')) {
440
- format = value;
441
- }
442
- });
443
- let directoryPath = '';
444
- switch (version) {
445
- case page_1.FioriElementsVersion.v2:
446
- directoryPath = path_1.join('schemas', 'v2');
447
- break;
448
- case page_1.FioriElementsVersion.v4:
449
- directoryPath = path_1.join('schemas', 'v4');
450
- break;
451
- default:
452
- console.log('Invalid version ' + version + '; processing stopped.');
453
- break;
454
- }
455
- if (directoryPath.length > 0) {
456
- const workbook = new excel.Workbook();
457
- fs.readdir(directoryPath, function (err, files) {
458
- if (err) {
459
- return console.log(err);
460
- }
461
- files.forEach((file) => {
462
- const filePath = path_1.join(directoryPath, file);
463
- const output = [filePath];
464
- const data = fs.readFileSync(filePath, 'utf8');
465
- const schema = JSON.parse(data);
466
- parseSchema(schema, schema, output);
467
- //console.log(output);
468
- if (format === 'excel') {
469
- writeToExcel(workbook, output, file);
470
- }
471
- if (format === 'iXiaSoft') {
472
- generateIxiaSoftFormat(output, file, version);
473
- }
474
- if (format === 'html') {
475
- generateHTMLFormat(output, file, version);
476
- }
477
- });
478
- if (format === 'excel') {
479
- writeToFile(workbook, version);
480
- }
481
- if (format === 'html') {
482
- copyFileToFolder();
483
- }
484
- });
485
- }
486
- }
487
- generateDocmentation();
488
- //# sourceMappingURL=extractDocu.js.map