@sap/ux-specification 1.139.1 → 1.139.2

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 (294) hide show
  1. package/CHANGELOG.md +39 -1
  2. package/dist/documentation/v2/v2-AnalyticalListPage.html +2 -2
  3. package/dist/documentation/v2/v2-ApplicationV2.html +2 -2
  4. package/dist/documentation/v2/v2-ListReport.html +2 -2
  5. package/dist/documentation/v2/v2-ListReportNew.html +2 -2
  6. package/dist/documentation/v2/v2-ObjectPage.html +2 -2
  7. package/dist/documentation/v2/v2-OverviewPage.html +2 -2
  8. package/dist/documentation/v4/v4-ApplicationV4.html +2 -2
  9. package/dist/documentation/v4/v4-BuildingBlocks.html +2 -2
  10. package/dist/documentation/v4/v4-FreestylePage.html +2 -2
  11. package/dist/documentation/v4/v4-ListReport.html +2 -2
  12. package/dist/documentation/v4/v4-ObjectPage.html +2 -2
  13. package/dist/index-min.js +249 -246
  14. package/dist/index-min.js.map +4 -4
  15. package/dist/schemas/v2/ListReportNewConfig.json +79 -0
  16. package/dist/schemas/v4/ListReportConfig.json +0 -41
  17. package/dist/specification/package.json +9 -8
  18. package/dist/specification/scripts/schema/to-json-schema.d.ts.map +1 -1
  19. package/dist/specification/scripts/schema/to-json-schema.js +2 -1
  20. package/dist/specification/scripts/schema/to-json-schema.js.map +1 -1
  21. package/dist/specification/src/api.js +2 -2
  22. package/dist/specification/src/ftfs/ftfs.d.ts +1 -1
  23. package/dist/specification/src/ftfs/ftfs.d.ts.map +1 -1
  24. package/dist/specification/src/ftfs/ftfs.js +38 -5
  25. package/dist/specification/src/ftfs/ftfs.js.map +1 -1
  26. package/dist/specification/src/ftfs/parser/annotations.d.ts +9 -0
  27. package/dist/specification/src/ftfs/parser/annotations.d.ts.map +1 -0
  28. package/dist/specification/src/ftfs/parser/annotations.js +13 -0
  29. package/dist/specification/src/ftfs/parser/annotations.js.map +1 -0
  30. package/dist/specification/src/ftfs/parser/index.d.ts +15 -0
  31. package/dist/specification/src/ftfs/parser/index.d.ts.map +1 -0
  32. package/dist/specification/src/ftfs/parser/index.js +35 -0
  33. package/dist/specification/src/ftfs/parser/index.js.map +1 -0
  34. package/dist/specification/src/ftfs/parser/model/AggregationValidator.d.ts +65 -0
  35. package/dist/specification/src/ftfs/parser/model/AggregationValidator.d.ts.map +1 -0
  36. package/dist/specification/src/ftfs/parser/model/AggregationValidator.js +209 -0
  37. package/dist/specification/src/ftfs/parser/model/AggregationValidator.js.map +1 -0
  38. package/dist/specification/src/ftfs/parser/model/ArrayAggregation.d.ts +49 -0
  39. package/dist/specification/src/ftfs/parser/model/ArrayAggregation.d.ts.map +1 -0
  40. package/dist/specification/src/ftfs/parser/model/ArrayAggregation.js +122 -0
  41. package/dist/specification/src/ftfs/parser/model/ArrayAggregation.js.map +1 -0
  42. package/dist/specification/src/ftfs/parser/model/NodeProperty.d.ts +38 -0
  43. package/dist/specification/src/ftfs/parser/model/NodeProperty.d.ts.map +1 -0
  44. package/dist/specification/src/ftfs/parser/model/NodeProperty.js +25 -0
  45. package/dist/specification/src/ftfs/parser/model/NodeProperty.js.map +1 -0
  46. package/dist/specification/src/ftfs/parser/model/ObjectAggregation.d.ts +339 -0
  47. package/dist/specification/src/ftfs/parser/model/ObjectAggregation.d.ts.map +1 -0
  48. package/dist/specification/src/ftfs/parser/model/ObjectAggregation.js +682 -0
  49. package/dist/specification/src/ftfs/parser/model/ObjectAggregation.js.map +1 -0
  50. package/dist/specification/src/ftfs/parser/model/RootAggregation.d.ts +24 -0
  51. package/dist/specification/src/ftfs/parser/model/RootAggregation.d.ts.map +1 -0
  52. package/dist/specification/src/ftfs/parser/model/RootAggregation.js +57 -0
  53. package/dist/specification/src/ftfs/parser/model/RootAggregation.js.map +1 -0
  54. package/dist/specification/src/ftfs/parser/model/TreeModel.d.ts +224 -0
  55. package/dist/specification/src/ftfs/parser/model/TreeModel.d.ts.map +1 -0
  56. package/dist/specification/src/ftfs/parser/model/TreeModel.js +947 -0
  57. package/dist/specification/src/ftfs/parser/model/TreeModel.js.map +1 -0
  58. package/dist/specification/src/ftfs/parser/model/actions/ActionAggregation.d.ts +34 -0
  59. package/dist/specification/src/ftfs/parser/model/actions/ActionAggregation.d.ts.map +1 -0
  60. package/dist/specification/src/ftfs/parser/model/actions/ActionAggregation.js +94 -0
  61. package/dist/specification/src/ftfs/parser/model/actions/ActionAggregation.js.map +1 -0
  62. package/dist/specification/src/ftfs/parser/model/actions/ActionsAggregation.d.ts +67 -0
  63. package/dist/specification/src/ftfs/parser/model/actions/ActionsAggregation.d.ts.map +1 -0
  64. package/dist/specification/src/ftfs/parser/model/actions/ActionsAggregation.js +113 -0
  65. package/dist/specification/src/ftfs/parser/model/actions/ActionsAggregation.js.map +1 -0
  66. package/dist/specification/src/ftfs/parser/model/actions/index.d.ts +3 -0
  67. package/dist/specification/src/ftfs/parser/model/actions/index.d.ts.map +1 -0
  68. package/dist/specification/src/ftfs/parser/model/actions/index.js +19 -0
  69. package/dist/specification/src/ftfs/parser/model/actions/index.js.map +1 -0
  70. package/dist/specification/src/ftfs/parser/model/additionalObjects/AdditionalObjectAggregation.d.ts +17 -0
  71. package/dist/specification/src/ftfs/parser/model/additionalObjects/AdditionalObjectAggregation.d.ts.map +1 -0
  72. package/dist/specification/src/ftfs/parser/model/additionalObjects/AdditionalObjectAggregation.js +29 -0
  73. package/dist/specification/src/ftfs/parser/model/additionalObjects/AdditionalObjectAggregation.js.map +1 -0
  74. package/dist/specification/src/ftfs/parser/model/additionalObjects/AdditionalObjectsAggregation.d.ts +46 -0
  75. package/dist/specification/src/ftfs/parser/model/additionalObjects/AdditionalObjectsAggregation.d.ts.map +1 -0
  76. package/dist/specification/src/ftfs/parser/model/additionalObjects/AdditionalObjectsAggregation.js +66 -0
  77. package/dist/specification/src/ftfs/parser/model/additionalObjects/AdditionalObjectsAggregation.js.map +1 -0
  78. package/dist/specification/src/ftfs/parser/model/additionalObjects/index.d.ts +3 -0
  79. package/dist/specification/src/ftfs/parser/model/additionalObjects/index.d.ts.map +1 -0
  80. package/dist/specification/src/ftfs/parser/model/additionalObjects/index.js +19 -0
  81. package/dist/specification/src/ftfs/parser/model/additionalObjects/index.js.map +1 -0
  82. package/dist/specification/src/ftfs/parser/model/chart/ChartAggregation.d.ts +21 -0
  83. package/dist/specification/src/ftfs/parser/model/chart/ChartAggregation.d.ts.map +1 -0
  84. package/dist/specification/src/ftfs/parser/model/chart/ChartAggregation.js +30 -0
  85. package/dist/specification/src/ftfs/parser/model/chart/ChartAggregation.js.map +1 -0
  86. package/dist/specification/src/ftfs/parser/model/chart/index.d.ts +2 -0
  87. package/dist/specification/src/ftfs/parser/model/chart/index.d.ts.map +1 -0
  88. package/dist/specification/src/ftfs/parser/model/chart/index.js +18 -0
  89. package/dist/specification/src/ftfs/parser/model/chart/index.js.map +1 -0
  90. package/dist/specification/src/ftfs/parser/model/fields/ConnectedFieldsAggregation.d.ts +9 -0
  91. package/dist/specification/src/ftfs/parser/model/fields/ConnectedFieldsAggregation.d.ts.map +1 -0
  92. package/dist/specification/src/ftfs/parser/model/fields/ConnectedFieldsAggregation.js +16 -0
  93. package/dist/specification/src/ftfs/parser/model/fields/ConnectedFieldsAggregation.js.map +1 -0
  94. package/dist/specification/src/ftfs/parser/model/fields/FieldAggregation.d.ts +25 -0
  95. package/dist/specification/src/ftfs/parser/model/fields/FieldAggregation.d.ts.map +1 -0
  96. package/dist/specification/src/ftfs/parser/model/fields/FieldAggregation.js +45 -0
  97. package/dist/specification/src/ftfs/parser/model/fields/FieldAggregation.js.map +1 -0
  98. package/dist/specification/src/ftfs/parser/model/fields/FieldsAggregation.d.ts +22 -0
  99. package/dist/specification/src/ftfs/parser/model/fields/FieldsAggregation.d.ts.map +1 -0
  100. package/dist/specification/src/ftfs/parser/model/fields/FieldsAggregation.js +37 -0
  101. package/dist/specification/src/ftfs/parser/model/fields/FieldsAggregation.js.map +1 -0
  102. package/dist/specification/src/ftfs/parser/model/fields/index.d.ts +4 -0
  103. package/dist/specification/src/ftfs/parser/model/fields/index.d.ts.map +1 -0
  104. package/dist/specification/src/ftfs/parser/model/fields/index.js +20 -0
  105. package/dist/specification/src/ftfs/parser/model/fields/index.js.map +1 -0
  106. package/dist/specification/src/ftfs/parser/model/filter-fields/FilterFieldAggregation.d.ts +39 -0
  107. package/dist/specification/src/ftfs/parser/model/filter-fields/FilterFieldAggregation.d.ts.map +1 -0
  108. package/dist/specification/src/ftfs/parser/model/filter-fields/FilterFieldAggregation.js +97 -0
  109. package/dist/specification/src/ftfs/parser/model/filter-fields/FilterFieldAggregation.js.map +1 -0
  110. package/dist/specification/src/ftfs/parser/model/filter-fields/FilterFieldsAggregation.d.ts +36 -0
  111. package/dist/specification/src/ftfs/parser/model/filter-fields/FilterFieldsAggregation.d.ts.map +1 -0
  112. package/dist/specification/src/ftfs/parser/model/filter-fields/FilterFieldsAggregation.js +59 -0
  113. package/dist/specification/src/ftfs/parser/model/filter-fields/FilterFieldsAggregation.js.map +1 -0
  114. package/dist/specification/src/ftfs/parser/model/filter-fields/index.d.ts +3 -0
  115. package/dist/specification/src/ftfs/parser/model/filter-fields/index.d.ts.map +1 -0
  116. package/dist/specification/src/ftfs/parser/model/filter-fields/index.js +19 -0
  117. package/dist/specification/src/ftfs/parser/model/filter-fields/index.js.map +1 -0
  118. package/dist/specification/src/ftfs/parser/model/index.d.ts +19 -0
  119. package/dist/specification/src/ftfs/parser/model/index.d.ts.map +1 -0
  120. package/dist/specification/src/ftfs/parser/model/index.js +35 -0
  121. package/dist/specification/src/ftfs/parser/model/index.js.map +1 -0
  122. package/dist/specification/src/ftfs/parser/model/macros/MacrosRoot.d.ts +29 -0
  123. package/dist/specification/src/ftfs/parser/model/macros/MacrosRoot.d.ts.map +1 -0
  124. package/dist/specification/src/ftfs/parser/model/macros/MacrosRoot.js +50 -0
  125. package/dist/specification/src/ftfs/parser/model/macros/MacrosRoot.js.map +1 -0
  126. package/dist/specification/src/ftfs/parser/model/macros/index.d.ts +2 -0
  127. package/dist/specification/src/ftfs/parser/model/macros/index.d.ts.map +1 -0
  128. package/dist/specification/src/ftfs/parser/model/macros/index.js +18 -0
  129. package/dist/specification/src/ftfs/parser/model/macros/index.js.map +1 -0
  130. package/dist/specification/src/ftfs/parser/model/sections/HeaderSectionsAggregation.d.ts +31 -0
  131. package/dist/specification/src/ftfs/parser/model/sections/HeaderSectionsAggregation.d.ts.map +1 -0
  132. package/dist/specification/src/ftfs/parser/model/sections/HeaderSectionsAggregation.js +82 -0
  133. package/dist/specification/src/ftfs/parser/model/sections/HeaderSectionsAggregation.js.map +1 -0
  134. package/dist/specification/src/ftfs/parser/model/sections/SectionAggregation.d.ts +78 -0
  135. package/dist/specification/src/ftfs/parser/model/sections/SectionAggregation.d.ts.map +1 -0
  136. package/dist/specification/src/ftfs/parser/model/sections/SectionAggregation.js +126 -0
  137. package/dist/specification/src/ftfs/parser/model/sections/SectionAggregation.js.map +1 -0
  138. package/dist/specification/src/ftfs/parser/model/sections/SectionsAggregation.d.ts +135 -0
  139. package/dist/specification/src/ftfs/parser/model/sections/SectionsAggregation.d.ts.map +1 -0
  140. package/dist/specification/src/ftfs/parser/model/sections/SectionsAggregation.js +402 -0
  141. package/dist/specification/src/ftfs/parser/model/sections/SectionsAggregation.js.map +1 -0
  142. package/dist/specification/src/ftfs/parser/model/sections/SectionsObjectAggregation.d.ts +50 -0
  143. package/dist/specification/src/ftfs/parser/model/sections/SectionsObjectAggregation.d.ts.map +1 -0
  144. package/dist/specification/src/ftfs/parser/model/sections/SectionsObjectAggregation.js +120 -0
  145. package/dist/specification/src/ftfs/parser/model/sections/SectionsObjectAggregation.js.map +1 -0
  146. package/dist/specification/src/ftfs/parser/model/sections/SubSectionsAggregation.d.ts +39 -0
  147. package/dist/specification/src/ftfs/parser/model/sections/SubSectionsAggregation.d.ts.map +1 -0
  148. package/dist/specification/src/ftfs/parser/model/sections/SubSectionsAggregation.js +70 -0
  149. package/dist/specification/src/ftfs/parser/model/sections/SubSectionsAggregation.js.map +1 -0
  150. package/dist/specification/src/ftfs/parser/model/sections/index.d.ts +6 -0
  151. package/dist/specification/src/ftfs/parser/model/sections/index.d.ts.map +1 -0
  152. package/dist/specification/src/ftfs/parser/model/sections/index.js +22 -0
  153. package/dist/specification/src/ftfs/parser/model/sections/index.js.map +1 -0
  154. package/dist/specification/src/ftfs/parser/model/table/ColumnAggregation.d.ts +89 -0
  155. package/dist/specification/src/ftfs/parser/model/table/ColumnAggregation.d.ts.map +1 -0
  156. package/dist/specification/src/ftfs/parser/model/table/ColumnAggregation.js +175 -0
  157. package/dist/specification/src/ftfs/parser/model/table/ColumnAggregation.js.map +1 -0
  158. package/dist/specification/src/ftfs/parser/model/table/ColumnsAggregation.d.ts +113 -0
  159. package/dist/specification/src/ftfs/parser/model/table/ColumnsAggregation.d.ts.map +1 -0
  160. package/dist/specification/src/ftfs/parser/model/table/ColumnsAggregation.js +290 -0
  161. package/dist/specification/src/ftfs/parser/model/table/ColumnsAggregation.js.map +1 -0
  162. package/dist/specification/src/ftfs/parser/model/table/TableAggregation.d.ts +13 -0
  163. package/dist/specification/src/ftfs/parser/model/table/TableAggregation.d.ts.map +1 -0
  164. package/dist/specification/src/ftfs/parser/model/table/TableAggregation.js +21 -0
  165. package/dist/specification/src/ftfs/parser/model/table/TableAggregation.js.map +1 -0
  166. package/dist/specification/src/ftfs/parser/model/table/ToolbarAggregation.d.ts +15 -0
  167. package/dist/specification/src/ftfs/parser/model/table/ToolbarAggregation.d.ts.map +1 -0
  168. package/dist/specification/src/ftfs/parser/model/table/ToolbarAggregation.js +22 -0
  169. package/dist/specification/src/ftfs/parser/model/table/ToolbarAggregation.js.map +1 -0
  170. package/dist/specification/src/ftfs/parser/model/table/index.d.ts +5 -0
  171. package/dist/specification/src/ftfs/parser/model/table/index.d.ts.map +1 -0
  172. package/dist/specification/src/ftfs/parser/model/table/index.js +21 -0
  173. package/dist/specification/src/ftfs/parser/model/table/index.js.map +1 -0
  174. package/dist/specification/src/ftfs/parser/model/table/utils.d.ts +12 -0
  175. package/dist/specification/src/ftfs/parser/model/table/utils.d.ts.map +1 -0
  176. package/dist/specification/src/ftfs/parser/model/table/utils.js +44 -0
  177. package/dist/specification/src/ftfs/parser/model/table/utils.js.map +1 -0
  178. package/dist/specification/src/ftfs/parser/model/types/annotations.d.ts +63 -0
  179. package/dist/specification/src/ftfs/parser/model/types/annotations.d.ts.map +1 -0
  180. package/dist/specification/src/ftfs/parser/model/types/annotations.js +29 -0
  181. package/dist/specification/src/ftfs/parser/model/types/annotations.js.map +1 -0
  182. package/dist/specification/src/ftfs/parser/model/types/common.d.ts +13 -0
  183. package/dist/specification/src/ftfs/parser/model/types/common.d.ts.map +1 -0
  184. package/dist/specification/src/ftfs/parser/model/types/common.js +3 -0
  185. package/dist/specification/src/ftfs/parser/model/types/common.js.map +1 -0
  186. package/dist/specification/src/ftfs/parser/model/types/index.d.ts +219 -0
  187. package/dist/specification/src/ftfs/parser/model/types/index.d.ts.map +1 -0
  188. package/dist/specification/src/ftfs/parser/model/types/index.js +156 -0
  189. package/dist/specification/src/ftfs/parser/model/types/index.js.map +1 -0
  190. package/dist/specification/src/ftfs/parser/model/utils/annotations.d.ts +38 -0
  191. package/dist/specification/src/ftfs/parser/model/utils/annotations.d.ts.map +1 -0
  192. package/dist/specification/src/ftfs/parser/model/utils/annotations.js +120 -0
  193. package/dist/specification/src/ftfs/parser/model/utils/annotations.js.map +1 -0
  194. package/dist/specification/src/ftfs/parser/model/utils/i18n.d.ts +33 -0
  195. package/dist/specification/src/ftfs/parser/model/utils/i18n.d.ts.map +1 -0
  196. package/dist/specification/src/ftfs/parser/model/utils/i18n.js +69 -0
  197. package/dist/specification/src/ftfs/parser/model/utils/i18n.js.map +1 -0
  198. package/dist/specification/src/ftfs/parser/model/utils/index.d.ts +6 -0
  199. package/dist/specification/src/ftfs/parser/model/utils/index.d.ts.map +1 -0
  200. package/dist/specification/src/ftfs/parser/model/utils/index.js +22 -0
  201. package/dist/specification/src/ftfs/parser/model/utils/index.js.map +1 -0
  202. package/dist/specification/src/ftfs/parser/model/utils/object.d.ts +25 -0
  203. package/dist/specification/src/ftfs/parser/model/utils/object.d.ts.map +1 -0
  204. package/dist/specification/src/ftfs/parser/model/utils/object.js +68 -0
  205. package/dist/specification/src/ftfs/parser/model/utils/object.js.map +1 -0
  206. package/dist/specification/src/ftfs/parser/model/utils/sort.d.ts +31 -0
  207. package/dist/specification/src/ftfs/parser/model/utils/sort.d.ts.map +1 -0
  208. package/dist/specification/src/ftfs/parser/model/utils/sort.js +18 -0
  209. package/dist/specification/src/ftfs/parser/model/utils/sort.js.map +1 -0
  210. package/dist/specification/src/ftfs/parser/model/utils/utils.d.ts +95 -0
  211. package/dist/specification/src/ftfs/parser/model/utils/utils.d.ts.map +1 -0
  212. package/dist/specification/src/ftfs/parser/model/utils/utils.js +267 -0
  213. package/dist/specification/src/ftfs/parser/model/utils/utils.js.map +1 -0
  214. package/dist/specification/src/ftfs/parser/model/views/ViewAggregation.d.ts +62 -0
  215. package/dist/specification/src/ftfs/parser/model/views/ViewAggregation.d.ts.map +1 -0
  216. package/dist/specification/src/ftfs/parser/model/views/ViewAggregation.js +111 -0
  217. package/dist/specification/src/ftfs/parser/model/views/ViewAggregation.js.map +1 -0
  218. package/dist/specification/src/ftfs/parser/model/views/ViewsAggregation.d.ts +54 -0
  219. package/dist/specification/src/ftfs/parser/model/views/ViewsAggregation.d.ts.map +1 -0
  220. package/dist/specification/src/ftfs/parser/model/views/ViewsAggregation.js +144 -0
  221. package/dist/specification/src/ftfs/parser/model/views/ViewsAggregation.js.map +1 -0
  222. package/dist/specification/src/ftfs/parser/model/views/index.d.ts +3 -0
  223. package/dist/specification/src/ftfs/parser/model/views/index.d.ts.map +1 -0
  224. package/dist/specification/src/ftfs/parser/model/views/index.js +19 -0
  225. package/dist/specification/src/ftfs/parser/model/views/index.js.map +1 -0
  226. package/dist/specification/src/ftfs/parser/model/visual-filters/VisualFilterAggregation.d.ts +11 -0
  227. package/dist/specification/src/ftfs/parser/model/visual-filters/VisualFilterAggregation.d.ts.map +1 -0
  228. package/dist/specification/src/ftfs/parser/model/visual-filters/VisualFilterAggregation.js +18 -0
  229. package/dist/specification/src/ftfs/parser/model/visual-filters/VisualFilterAggregation.js.map +1 -0
  230. package/dist/specification/src/ftfs/parser/model/visual-filters/VisualFiltersAggregation.d.ts +11 -0
  231. package/dist/specification/src/ftfs/parser/model/visual-filters/VisualFiltersAggregation.d.ts.map +1 -0
  232. package/dist/specification/src/ftfs/parser/model/visual-filters/VisualFiltersAggregation.js +18 -0
  233. package/dist/specification/src/ftfs/parser/model/visual-filters/VisualFiltersAggregation.js.map +1 -0
  234. package/dist/specification/src/ftfs/parser/model/visual-filters/index.d.ts +3 -0
  235. package/dist/specification/src/ftfs/parser/model/visual-filters/index.d.ts.map +1 -0
  236. package/dist/specification/src/ftfs/parser/model/visual-filters/index.js +19 -0
  237. package/dist/specification/src/ftfs/parser/model/visual-filters/index.js.map +1 -0
  238. package/dist/specification/src/sync/common/i18n.json +5 -4
  239. package/dist/specification/src/sync/v2/generate/listReport.d.ts.map +1 -1
  240. package/dist/specification/src/sync/v2/generate/listReport.js +1 -92
  241. package/dist/specification/src/sync/v2/generate/listReport.js.map +1 -1
  242. package/dist/specification/src/sync/v2/generate/schemaAdaptation.d.ts.map +1 -1
  243. package/dist/specification/src/sync/v2/generate/schemaAdaptation.js +2 -17
  244. package/dist/specification/src/sync/v2/generate/schemaAdaptation.js.map +1 -1
  245. package/dist/specification/src/sync/v2/generate/stableIdUtils.d.ts +40 -0
  246. package/dist/specification/src/sync/v2/generate/stableIdUtils.d.ts.map +1 -0
  247. package/dist/specification/src/sync/v2/generate/stableIdUtils.js +179 -0
  248. package/dist/specification/src/sync/v2/generate/stableIdUtils.js.map +1 -0
  249. package/dist/specification/src/sync/v2/generate/utils.d.ts +63 -3
  250. package/dist/specification/src/sync/v2/generate/utils.d.ts.map +1 -1
  251. package/dist/specification/src/sync/v2/generate/utils.js +191 -7
  252. package/dist/specification/src/sync/v2/generate/utils.js.map +1 -1
  253. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/Action.d.ts +59 -0
  254. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/Action.d.ts.map +1 -1
  255. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/Action.js +193 -4
  256. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/Action.js.map +1 -1
  257. package/dist/specification/src/sync/v2/genericSchemaHandling/pages/ListReportNew.d.ts +8 -0
  258. package/dist/specification/src/sync/v2/genericSchemaHandling/pages/ListReportNew.d.ts.map +1 -1
  259. package/dist/specification/src/sync/v2/genericSchemaHandling/pages/ListReportNew.js +52 -7
  260. package/dist/specification/src/sync/v2/genericSchemaHandling/pages/ListReportNew.js.map +1 -1
  261. package/dist/specification/src/sync/v4/export/manifest.js +1 -1
  262. package/dist/specification/src/sync/v4/export/manifest.js.map +1 -1
  263. package/dist/specification/src/sync/v4/import/app/appProvider.d.ts.map +1 -1
  264. package/dist/specification/src/sync/v4/import/app/appProvider.js +3 -0
  265. package/dist/specification/src/sync/v4/import/app/appProvider.js.map +1 -1
  266. package/dist/specification/src/sync/v4/import/pages/listReport.d.ts.map +1 -1
  267. package/dist/specification/src/sync/v4/import/pages/listReport.js +3 -1
  268. package/dist/specification/src/sync/v4/import/pages/listReport.js.map +1 -1
  269. package/dist/types/src/apiTypes.d.ts +22 -0
  270. package/dist/types/src/apiTypes.d.ts.map +1 -1
  271. package/dist/types/src/apiTypes.js.map +1 -1
  272. package/dist/types/src/index.d.ts +1 -0
  273. package/dist/types/src/index.d.ts.map +1 -1
  274. package/dist/types/src/index.js +2 -1
  275. package/dist/types/src/index.js.map +1 -1
  276. package/dist/types/src/parser/application.d.ts +22 -0
  277. package/dist/types/src/parser/application.d.ts.map +1 -0
  278. package/dist/types/src/parser/application.js +3 -0
  279. package/dist/types/src/parser/application.js.map +1 -0
  280. package/dist/types/src/parser/index.d.ts +3 -0
  281. package/dist/types/src/parser/index.d.ts.map +1 -0
  282. package/dist/types/src/parser/index.js +18 -0
  283. package/dist/types/src/parser/index.js.map +1 -0
  284. package/dist/types/src/parser/model.d.ts +17 -0
  285. package/dist/types/src/parser/model.d.ts.map +1 -0
  286. package/dist/types/src/parser/model.js +3 -0
  287. package/dist/types/src/parser/model.js.map +1 -0
  288. package/dist/types/src/v4/controls/Table.d.ts +0 -5
  289. package/dist/types/src/v4/controls/Table.d.ts.map +1 -1
  290. package/package.json +9 -8
  291. package/dist/specification/src/ftfs/annotations.d.ts +0 -12
  292. package/dist/specification/src/ftfs/annotations.d.ts.map +0 -1
  293. package/dist/specification/src/ftfs/annotations.js +0 -50
  294. package/dist/specification/src/ftfs/annotations.js.map +0 -1
@@ -0,0 +1,267 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.updateAnchorSchema = exports.oneOfToDropdownOptions = exports.formatAnchorDescriptionText = exports.validateMacrosExtension = exports.validateExtension = exports.ensureLastNodeIsUndeletable = exports.getTechnicalIdFromPath = exports.getAppI18nBundle = void 0;
7
+ exports.addValidationMessages = addValidationMessages;
8
+ exports.startCase = startCase;
9
+ const i18next_1 = __importDefault(require("i18next"));
10
+ const types_1 = require("../types");
11
+ const i18n_1 = require("./i18n");
12
+ /**
13
+ * Method returns application specific i18n bundle data.
14
+ *
15
+ * @returns i18n bundle data.
16
+ */
17
+ const getAppI18nBundle = () => {
18
+ return {
19
+ bundles: {
20
+ annotation: {},
21
+ app: {},
22
+ service: {},
23
+ ui5: {}
24
+ }
25
+ };
26
+ };
27
+ exports.getAppI18nBundle = getAppI18nBundle;
28
+ const getTechnicalIdFromPath = (path, firstOnly = false) => {
29
+ const key = path[path.length - 1];
30
+ if (key) {
31
+ let id = key.toString();
32
+ const separator = id.includes(':::') ? ':::' : '::';
33
+ const parts = key.toString().split(separator);
34
+ id = parts[0];
35
+ if (!firstOnly && parts.length > 1) {
36
+ // remove first entry
37
+ parts.splice(0, 1);
38
+ id = parts.join('/');
39
+ }
40
+ if (id) {
41
+ return id;
42
+ }
43
+ }
44
+ };
45
+ exports.getTechnicalIdFromPath = getTechnicalIdFromPath;
46
+ /**
47
+ * Method disables deletion of last annotation node if there is any custom nodes.
48
+ * There can be cases when custom nodes referenced to last annotation node and by deleting last annotation node, we can not provide correct order.
49
+ *
50
+ * @param aggregation Container aggregation.
51
+ * @param text I18n key for disabled deletion explanation.
52
+ */
53
+ const ensureLastNodeIsUndeletable = (aggregation, text) => {
54
+ // Find if there is very last node
55
+ // Should be undefined if there is two annotation nodes
56
+ let lastNativeNode;
57
+ let nativeNodes = 0;
58
+ let customNodeExists = false;
59
+ for (const key in aggregation.aggregations) {
60
+ if (!aggregation.aggregations[key].custom) {
61
+ lastNativeNode = nativeNodes > 0 ? undefined : aggregation.aggregations[key];
62
+ nativeNodes++;
63
+ }
64
+ else {
65
+ customNodeExists = true;
66
+ }
67
+ }
68
+ // Check if signle and last annotation node exists with actions
69
+ if (!customNodeExists || !lastNativeNode?.actions) {
70
+ return;
71
+ }
72
+ // Find deletion action
73
+ const index = lastNativeNode.actions.findIndex((action) => action === types_1.AggregationActions.Delete ||
74
+ (typeof action === 'object' && action.type === types_1.AggregationActions.Delete));
75
+ if (index !== -1) {
76
+ let deleteAction = lastNativeNode.actions[index];
77
+ if (typeof deleteAction !== 'object') {
78
+ // Simple string - make object which allow to disable action
79
+ deleteAction = {
80
+ type: deleteAction
81
+ };
82
+ }
83
+ // Disable actiondeletion
84
+ deleteAction.disabled = true;
85
+ deleteAction.title = i18next_1.default.t(text);
86
+ lastNativeNode.actions[index] = deleteAction;
87
+ }
88
+ };
89
+ exports.ensureLastNodeIsUndeletable = ensureLastNodeIsUndeletable;
90
+ /**
91
+ * Function validates extension using validation parameter by setting warning message to aggregation.
92
+ *
93
+ * @param aggregation aggregation for which to set warning message.
94
+ * @param isValid validation result.
95
+ * @param description description to show in case extension is invalid.
96
+ * @param property name of the property
97
+ */
98
+ const validateExtension = (aggregation, isValid, description, property) => {
99
+ if (!isValid) {
100
+ aggregation.state = types_1.ValidationState.Invalid;
101
+ aggregation.messages = [
102
+ {
103
+ text: description,
104
+ type: types_1.PropertyMessageType.Warning
105
+ }
106
+ ];
107
+ aggregation.inactive = true;
108
+ if (property && aggregation.properties[property]) {
109
+ addValidationMessages(aggregation.properties[property], [{ text: description }]);
110
+ }
111
+ }
112
+ };
113
+ exports.validateExtension = validateExtension;
114
+ /**
115
+ * Function validates macros extension key by checking aggregation value of it.
116
+ *
117
+ * @param aggregation aggregation for which to set warning message.
118
+ * @param value value of custom extension aggregation.
119
+ */
120
+ const validateMacrosExtension = (aggregation, value = aggregation.value) => {
121
+ const extensionValue = value && typeof value === 'object' ? value : {};
122
+ const isKeyDefined = 'key' in extensionValue && !!extensionValue.key;
123
+ // validate custom extension key
124
+ (0, exports.validateExtension)(aggregation, isKeyDefined, i18next_1.default.t('PAGE_EDITOR_CUSTOM_EXTENSION_NO_KEY'), 'key');
125
+ };
126
+ exports.validateMacrosExtension = validateMacrosExtension;
127
+ /**
128
+ * Method which formats and returns display/description text for anchor selection option.
129
+ * Method resolves i18n translation for text if translation exists.
130
+ *
131
+ * @param i18nKey I18n entry for option.
132
+ * @param aggregation Object aggregation.
133
+ * @param text Anchor label without i18n resolution.
134
+ * @param id Anchor ID.
135
+ * @returns Formatted text for related anchor option.
136
+ */
137
+ const formatAnchorDescriptionText = (i18nKey, aggregation, text, id) => {
138
+ const appI18n = (0, exports.getAppI18nBundle)();
139
+ const i18nBundle = (0, i18n_1.getRelevantI18nBundle)(aggregation, appI18n.bundles, appI18n.projectType);
140
+ const label = (0, i18n_1.resolveI18nValue)(text, i18nBundle) || text;
141
+ return id
142
+ ? i18next_1.default.t(i18nKey, {
143
+ id,
144
+ label
145
+ })
146
+ : label;
147
+ };
148
+ exports.formatAnchorDescriptionText = formatAnchorDescriptionText;
149
+ /**
150
+ * Method which receives 'oneOf' entries from schema and converts to dropdown option entries.
151
+ *
152
+ * @param i18nKey I18n entry for option.
153
+ * @param aggregation Object aggregation.
154
+ * @param oneOf One of entries from schema.
155
+ * @returns Options for dropdown.
156
+ */
157
+ const oneOfToDropdownOptions = (i18nKey, aggregation, oneOf = []) => {
158
+ return oneOf
159
+ .filter((entry) => !entry.hidden)
160
+ .map((option, index) => {
161
+ const text = option.description || option.const || index.toString();
162
+ return {
163
+ key: option.const || index.toString(),
164
+ text: (0, exports.formatAnchorDescriptionText)(i18nKey, aggregation, text, option.const)
165
+ };
166
+ });
167
+ };
168
+ exports.oneOfToDropdownOptions = oneOfToDropdownOptions;
169
+ /**
170
+ * Method returns updated schema for anchor property.
171
+ * Method hides enum entry which is associated with passed aggregation to avoid anchoring extension to itself.
172
+ *
173
+ * @param aggregation Aggregation object.
174
+ * @param originalSchema Schema of anchor property.
175
+ * @returns Modified schema.
176
+ */
177
+ const updateAnchorSchema = (aggregation, originalSchema) => {
178
+ const anchor = aggregation.name === 'position' ? aggregation.parent?.name : aggregation.name;
179
+ if (originalSchema.enum) {
180
+ // Copy to avoid sharing same reference across other custom columns
181
+ const schema = { ...originalSchema, enum: [...originalSchema.enum] };
182
+ // Handle enum
183
+ const index = schema.enum.findIndex((entry) => entry === anchor);
184
+ if (index !== -1) {
185
+ schema.enum.splice(index, 1);
186
+ }
187
+ return schema;
188
+ }
189
+ else if (originalSchema.oneOf) {
190
+ const appI18n = (0, exports.getAppI18nBundle)();
191
+ // Copy to avoid sharing same reference across other custom columns
192
+ const schema = { ...originalSchema, oneOf: [...originalSchema.oneOf] };
193
+ // Handle oneOf
194
+ for (let i = 0; i < schema.oneOf.length; i++) {
195
+ const entry = schema.oneOf[i];
196
+ entry.bundle = (0, i18n_1.getI18nBundleName)(entry.custom, true, !!entry.annotationNodeId, appI18n.projectType);
197
+ // Hide anchors which refers to itself
198
+ if (entry.const === anchor) {
199
+ schema.oneOf[i] = {
200
+ ...entry,
201
+ hidden: true
202
+ };
203
+ }
204
+ }
205
+ return schema;
206
+ }
207
+ return originalSchema;
208
+ };
209
+ exports.updateAnchorSchema = updateAnchorSchema;
210
+ /**
211
+ * Method adds validation message to property or node instance.
212
+ *
213
+ * @param instance Property or node instance.
214
+ * @param instance.messages Messages of instance.
215
+ * @param messages Array of validation messages.
216
+ */
217
+ function addValidationMessages(instance, messages) {
218
+ instance.messages ??= [];
219
+ instance.messages.push(...messages);
220
+ }
221
+ /**
222
+ * Converts a string into "Start Case" format.
223
+ *
224
+ * - Splits words on underscores (`_`), hyphens (`-`), and spaces.
225
+ * - Detects camelCase boundaries (`fooBar` → `Foo Bar`).
226
+ * - Capitalizes the first character of each word.
227
+ * - Preserves acronyms (`FCL`, `WORLD`) when they appear in uppercase.
228
+ *
229
+ * @param text - The input string to convert.
230
+ * @returns The formatted string in start case.
231
+ */
232
+ function startCase(text) {
233
+ let result = '';
234
+ let capitalizeNext = true;
235
+ for (let i = 0; i < text.length; i++) {
236
+ const char = text[i];
237
+ // Treat separators as spaces
238
+ if (char === '_' || char === '-' || char === ' ') {
239
+ if (!result.endsWith(' ')) {
240
+ result += ' ';
241
+ }
242
+ capitalizeNext = true;
243
+ continue;
244
+ }
245
+ const prev = text[i - 1];
246
+ const next = text[i + 1];
247
+ // Insert space before camelCase or acronym boundaries
248
+ if (i > 0 &&
249
+ // lower → UPPER (camelCase)
250
+ ((prev >= 'a' && prev <= 'z' && char >= 'A' && char <= 'Z') ||
251
+ // acronym → next word (like FCLTo)
252
+ (prev >= 'A' && prev <= 'Z' && char >= 'A' && char <= 'Z' && next && next >= 'a' && next <= 'z'))) {
253
+ result += ' ';
254
+ capitalizeNext = true;
255
+ }
256
+ // Apply capitalization inline
257
+ if (capitalizeNext) {
258
+ result += char.toUpperCase();
259
+ capitalizeNext = false;
260
+ }
261
+ else {
262
+ result += char;
263
+ }
264
+ }
265
+ return result.trim();
266
+ }
267
+ //# sourceMappingURL=utils.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"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,CAAC,IAAI,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,CAAC;gBACvD,mCAAmC;gBACnC,CAAC,IAAI,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,IAAI,IAAI,IAAI,IAAI,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,CAAC,CAAC,EACvG,CAAC;YACC,MAAM,IAAI,GAAG,CAAC;YACd,cAAc,GAAG,IAAI,CAAC;QAC1B,CAAC;QAED,8BAA8B;QAC9B,IAAI,cAAc,EAAE,CAAC;YACjB,MAAM,IAAI,IAAI,CAAC,WAAW,EAAE,CAAC;YAC7B,cAAc,GAAG,KAAK,CAAC;QAC3B,CAAC;aAAM,CAAC;YACJ,MAAM,IAAI,IAAI,CAAC;QACnB,CAAC;IACL,CAAC;IAED,OAAO,MAAM,CAAC,IAAI,EAAE,CAAC;AACzB,CAAC"}
@@ -0,0 +1,62 @@
1
+ import type { JSONSchema4 } from 'json-schema';
2
+ import { ObjectAggregation } from '../ObjectAggregation';
3
+ import type { PageEditAggregationData } from '../ObjectAggregation';
4
+ import { AggregationActions, SortingOptions } from '../types';
5
+ import type { PageData, PageAnnotations } from '../types';
6
+ import type { PageConfig, PageType, Parser } from '@sap/ux-specification-types';
7
+ /**
8
+ * Represents an aggregation for view objects.
9
+ */
10
+ export declare class ViewAggregation extends ObjectAggregation {
11
+ private title?;
12
+ actions: AggregationActions[];
13
+ sortableItem: SortingOptions | undefined;
14
+ sortableCollection: string | undefined;
15
+ /**
16
+ * Creates an instance of `ViewAggregation`.
17
+ *
18
+ * @param data Optional aggregation data object used to initialize properties.
19
+ * @param schema Optional JSON schema fragment associated with this aggregation.
20
+ */
21
+ constructor(data?: PageEditAggregationData, schema?: JSONSchema4);
22
+ /**
23
+ * Method returns display name of aggregation without applying i18n translation.
24
+ * Overwritten for column handling.
25
+ *
26
+ * @returns Display name of aggregation.
27
+ */
28
+ protected getRawDisplayName(): string;
29
+ /**
30
+ * Public method to mark view as custom action.
31
+ */
32
+ markAsCustomView(): void;
33
+ /**
34
+ * Overwritten method for data update of list report view.
35
+ *
36
+ * @param data Data which should be used for value population.
37
+ * @param page Page config data.
38
+ * @param pageType Page type.
39
+ * @param path Aggregation path.
40
+ * @param annotations Annotations data.
41
+ */
42
+ updatePropertiesValues(data: PageData, page: PageConfig, pageType: PageType, path: Parser.PropertyPath, annotations: PageAnnotations | undefined): void;
43
+ /**
44
+ * Method returns true if view aggregation is table view.
45
+ *
46
+ * @returns True if view is table view.
47
+ */
48
+ private isTableView;
49
+ /**
50
+ * Method returns true if view aggregation is chart view.
51
+ *
52
+ * @returns True if view is chart view.
53
+ */
54
+ private isChartView;
55
+ /**
56
+ * Method returns true if aggregation is annotation view.
57
+ *
58
+ * @returns True if view is annotation view.
59
+ */
60
+ isAnnotationView(): boolean;
61
+ }
62
+ //# sourceMappingURL=ViewAggregation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ViewAggregation.d.ts","sourceRoot":"","sources":["../../../../../../../src/ftfs/parser/model/views/ViewAggregation.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,cAAc,EAA2C,MAAM,UAAU,CAAC;AACvG,OAAO,KAAK,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAC1D,OAAO,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AAEhF;;GAEG;AACH,qBAAa,eAAgB,SAAQ,iBAAiB;IAClD,OAAO,CAAC,KAAK,CAAC,CAAS;IAChB,OAAO,EAAE,kBAAkB,EAAE,CAAM;IACnC,YAAY,EAAE,cAAc,GAAG,SAAS,CAA0B;IAClE,kBAAkB,EAAE,MAAM,GAAG,SAAS,CAAW;IAExD;;;;;OAKG;gBACS,IAAI,CAAC,EAAE,uBAAuB,EAAE,MAAM,CAAC,EAAE,WAAW;IAQhE;;;;;OAKG;IACH,SAAS,CAAC,iBAAiB,IAAI,MAAM;IAIrC;;OAEG;IACI,gBAAgB,IAAI,IAAI;IAW/B;;;;;;;;OAQG;IACI,sBAAsB,CACzB,IAAI,EAAE,QAAQ,EACd,IAAI,EAAE,UAAU,EAChB,QAAQ,EAAE,QAAQ,EAClB,IAAI,EAAE,MAAM,CAAC,YAAY,EACzB,WAAW,EAAE,eAAe,GAAG,SAAS,GACzC,IAAI;IAsBP;;;;OAIG;IACH,OAAO,CAAC,WAAW;IAInB;;;;OAIG;IACH,OAAO,CAAC,WAAW;IAInB;;;;OAIG;IACI,gBAAgB,IAAI,OAAO;CAMrC"}
@@ -0,0 +1,111 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.ViewAggregation = void 0;
7
+ const i18next_1 = __importDefault(require("i18next"));
8
+ const ObjectAggregation_1 = require("../ObjectAggregation");
9
+ const types_1 = require("../types");
10
+ /**
11
+ * Represents an aggregation for view objects.
12
+ */
13
+ class ViewAggregation extends ObjectAggregation_1.ObjectAggregation {
14
+ /**
15
+ * Creates an instance of `ViewAggregation`.
16
+ *
17
+ * @param data Optional aggregation data object used to initialize properties.
18
+ * @param schema Optional JSON schema fragment associated with this aggregation.
19
+ */
20
+ constructor(data, schema) {
21
+ super(data, schema);
22
+ this.actions = [];
23
+ this.sortableItem = types_1.SortingOptions.Enabled;
24
+ this.sortableCollection = 'views';
25
+ if (schema?.key && !schema.annotationPath && !schema.properties?.['annotationPath']) {
26
+ // Custom view - generate annotation path, because it is not provided by schema
27
+ schema.annotationPath = `${types_1.CUSTOM_VIEW_PREFIX}${schema.key})`;
28
+ }
29
+ }
30
+ /**
31
+ * Method returns display name of aggregation without applying i18n translation.
32
+ * Overwritten for column handling.
33
+ *
34
+ * @returns Display name of aggregation.
35
+ */
36
+ getRawDisplayName() {
37
+ return this.title || super.getRawDisplayName();
38
+ }
39
+ /**
40
+ * Public method to mark view as custom action.
41
+ */
42
+ markAsCustomView() {
43
+ this.custom = true;
44
+ this.actions = [types_1.AggregationActions.Delete, types_1.AggregationActions.OpenSource];
45
+ this.sortableItem = types_1.SortingOptions.Enabled;
46
+ this.additionalText = i18next_1.default.t('PAGE_EDITOR_OUTLINE_NODE_DESC_CUSTOM_VIEW');
47
+ this.i18nKey = this.parent?.i18nKey;
48
+ if (this.properties.label?.value) {
49
+ this.title = this.properties.label.value;
50
+ }
51
+ }
52
+ /**
53
+ * Overwritten method for data update of list report view.
54
+ *
55
+ * @param data Data which should be used for value population.
56
+ * @param page Page config data.
57
+ * @param pageType Page type.
58
+ * @param path Aggregation path.
59
+ * @param annotations Annotations data.
60
+ */
61
+ updatePropertiesValues(data, page, pageType, path, annotations) {
62
+ super.updatePropertiesValues(data, page, pageType, path, annotations);
63
+ // Update icon
64
+ if (this.isTableView()) {
65
+ this.icon = 'Table';
66
+ }
67
+ else if (this.isChartView()) {
68
+ this.icon = 'Chart';
69
+ }
70
+ else {
71
+ this.icon = 'Sections';
72
+ }
73
+ // validate annotation path property
74
+ if (this.isAnnotationView() && !this.schema?.['annotationPath'] && this.properties['annotationPath']) {
75
+ // set warning for annotation path property
76
+ this.properties['annotationPath'].messages = [
77
+ {
78
+ type: types_1.PropertyMessageType.Warning,
79
+ text: i18next_1.default.t('PAGE_EDITOR_PROPERTIES_VIEW_NO_ANNOTATION_PATH')
80
+ }
81
+ ];
82
+ }
83
+ }
84
+ /**
85
+ * Method returns true if view aggregation is table view.
86
+ *
87
+ * @returns True if view is table view.
88
+ */
89
+ isTableView() {
90
+ return 'columns' in this.aggregations;
91
+ }
92
+ /**
93
+ * Method returns true if view aggregation is chart view.
94
+ *
95
+ * @returns True if view is chart view.
96
+ */
97
+ isChartView() {
98
+ return !('columns' in this.aggregations) && 'toolBar' in this.aggregations;
99
+ }
100
+ /**
101
+ * Method returns true if aggregation is annotation view.
102
+ *
103
+ * @returns True if view is annotation view.
104
+ */
105
+ isAnnotationView() {
106
+ return ((!this.custom && 'annotationPath' in this.properties) ||
107
+ (!this.custom && this.schema?.annotationPath && !this.schema?.annotationPath.startsWith(types_1.CUSTOM_VIEW_PREFIX)));
108
+ }
109
+ }
110
+ exports.ViewAggregation = ViewAggregation;
111
+ //# sourceMappingURL=ViewAggregation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ViewAggregation.js","sourceRoot":"","sources":["../../../../../../../src/ftfs/parser/model/views/ViewAggregation.ts"],"names":[],"mappings":";;;;;;AAAA,sDAA8B;AAE9B,4DAAyD;AAEzD,oCAAuG;AAIvG;;GAEG;AACH,MAAa,eAAgB,SAAQ,qCAAiB;IAMlD;;;;;OAKG;IACH,YAAY,IAA8B,EAAE,MAAoB;QAC5D,KAAK,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC;QAXjB,YAAO,GAAyB,EAAE,CAAC;QACnC,iBAAY,GAA+B,sBAAc,CAAC,OAAO,CAAC;QAClE,uBAAkB,GAAuB,OAAO,CAAC;QAUpD,IAAI,MAAM,EAAE,GAAG,IAAI,CAAC,MAAM,CAAC,cAAc,IAAI,CAAC,MAAM,CAAC,UAAU,EAAE,CAAC,gBAAgB,CAAC,EAAE,CAAC;YAClF,+EAA+E;YAC/E,MAAM,CAAC,cAAc,GAAG,GAAG,0BAAkB,GAAG,MAAM,CAAC,GAAG,GAAG,CAAC;QAClE,CAAC;IACL,CAAC;IAED;;;;;OAKG;IACO,iBAAiB;QACvB,OAAO,IAAI,CAAC,KAAK,IAAI,KAAK,CAAC,iBAAiB,EAAE,CAAC;IACnD,CAAC;IAED;;OA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C,QAAQ,GAAG;gBACzC;oBACI,IAAI,EAAE,2BAAmB,CAAC,OAAO;oBACjC,IAAI,EAAE,iBAAO,CAAC,CAAC,CAAC,gDAAgD,CAAC;iBACpE;aACJ,CAAC;QACN,CAAC;IACL,CAAC;IAED;;;;OAIG;IACK,WAAW;QACf,OAAO,SAAS,IAAI,IAAI,CAAC,YAAY,CAAC;IAC1C,CAAC;IAED;;;;OAIG;IACK,WAAW;QACf,OAAO,CAAC,CAAC,SAAS,IAAI,IAAI,CAAC,YAAY,CAAC,IAAI,SAAS,IAAI,IAAI,CAAC,YAAY,CAAC;IAC/E,CAAC;IAED;;;;OAIG;IACI,gBAAgB;QACnB,OAAO,CACH,CAAC,CAAC,IAAI,CAAC,MAAM,IAAI,gBAAgB,IAAI,IAAI,CAAC,UAAU,CAAC;YACrD,CAAC,CAAC,IAAI,CAAC,MAAM,IAAI,IAAI,CAAC,MAAM,EAAE,cAAc,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,cAAc,CAAC,UAAU,CAAC,0BAAkB,CAAC,CAAC,CAC/G,CAAC;IACN,CAAC;CACJ;AA9GD,0CA8GC"}
@@ -0,0 +1,54 @@
1
+ import { ObjectAggregation } from '../ObjectAggregation';
2
+ import type { PageData, PageAnnotations } from '../types';
3
+ import { AggregationCreationForm } from '../types';
4
+ import { ViewAggregation } from './ViewAggregation';
5
+ import type { PageConfig, PageType, Parser } from '@sap/ux-specification-types';
6
+ /**
7
+ * Represents an aggregation for views objects.
8
+ */
9
+ export declare class ViewsAggregation extends ObjectAggregation {
10
+ sortableList: boolean;
11
+ childClass: typeof ViewAggregation;
12
+ allowedAnnotationCreationForms: AggregationCreationForm[];
13
+ sortableCollection: string | undefined;
14
+ sortableConfigOnly: boolean;
15
+ i18nKey: string;
16
+ /**
17
+ * Refreshes internal data based on latest annotation node data.
18
+ *
19
+ * @param annotations Page annotations.
20
+ */
21
+ updateAnnotationData(annotations: PageAnnotations | undefined): void;
22
+ /**
23
+ * Overwritten method for data update of list report views container node.
24
+ *
25
+ * @param data Data which should be used for value population.
26
+ * @param page Page config data.
27
+ * @param pageType Page type.
28
+ * @param path Aggregation path.
29
+ * @param annotations Annotations data.
30
+ */
31
+ updatePropertiesValues(data: PageData, page: PageConfig, pageType: PageType, path: Parser.PropertyPath, annotations: PageAnnotations | undefined): void;
32
+ /**
33
+ * Determines the delete action configuration for a given view aggregation.
34
+ *
35
+ * @param viewAggregation - The view aggregation to evaluate.
36
+ * @param annotations - The current page annotations context.
37
+ * @returns The delete action configuration for the view.
38
+ */
39
+ private getViewDeleteAction;
40
+ /**
41
+ * Enables/Disables the chart form based on the annotations.
42
+ *
43
+ * @param forms Array of creation forms
44
+ * @param annotations Page annotations
45
+ */
46
+ private toggleChartForm;
47
+ /**
48
+ * Method returns count of annotations views.
49
+ *
50
+ * @returns Count of annotations views.
51
+ */
52
+ private getAnnotationViewCount;
53
+ }
54
+ //# sourceMappingURL=ViewsAggregation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ViewsAggregation.d.ts","sourceRoot":"","sources":["../../../../../../../src/ftfs/parser/model/views/ViewsAggregation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,KAAK,EAAmD,QAAQ,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAC3G,OAAO,EAAgE,uBAAuB,EAAE,MAAM,UAAU,CAAC;AACjH,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAGpD,OAAO,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AAEhF;;GAEG;AACH,qBAAa,gBAAiB,SAAQ,iBAAiB;IACnD,YAAY,UAAQ;IACpB,UAAU,yBAAmB;IAC7B,8BAA8B,4BAI5B;IACF,kBAAkB,EAAE,MAAM,GAAG,SAAS,CAAW;IACjD,kBAAkB,UAAQ;IAE1B,OAAO,SAAW;IAElB;;;;OAIG;IACI,oBAAoB,CAAC,WAAW,EAAE,eAAe,GAAG,SAAS,GAAG,IAAI;IAc3E;;;;;;;;OAQG;IACI,sBAAsB,CACzB,IAAI,EAAE,QAAQ,EACd,IAAI,EAAE,UAAU,EAChB,QAAQ,EAAE,QAAQ,EAClB,IAAI,EAAE,MAAM,CAAC,YAAY,EACzB,WAAW,EAAE,eAAe,GAAG,SAAS,GACzC,IAAI;IA+BP;;;;;;OAMG;IACH,OAAO,CAAC,mBAAmB;IAsB3B;;;;;OAKG;IACH,OAAO,CAAC,eAAe;IAevB;;;;OAIG;IACH,OAAO,CAAC,sBAAsB;CAUjC"}
@@ -0,0 +1,144 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.ViewsAggregation = void 0;
7
+ const ObjectAggregation_1 = require("../ObjectAggregation");
8
+ const types_1 = require("../types");
9
+ const ViewAggregation_1 = require("./ViewAggregation");
10
+ const i18next_1 = __importDefault(require("i18next"));
11
+ const utils_1 = require("../utils");
12
+ /**
13
+ * Represents an aggregation for views objects.
14
+ */
15
+ class ViewsAggregation extends ObjectAggregation_1.ObjectAggregation {
16
+ constructor() {
17
+ super(...arguments);
18
+ this.sortableList = true;
19
+ this.childClass = ViewAggregation_1.ViewAggregation;
20
+ this.allowedAnnotationCreationForms = [
21
+ types_1.AggregationCreationForm.TableView,
22
+ types_1.AggregationCreationForm.AnalyticalChartView,
23
+ types_1.AggregationCreationForm.CustomViewV4
24
+ ];
25
+ this.sortableCollection = 'views';
26
+ this.sortableConfigOnly = true;
27
+ // i18n key
28
+ this.i18nKey = 'VIEWS';
29
+ }
30
+ /**
31
+ * Refreshes internal data based on latest annotation node data.
32
+ *
33
+ * @param annotations Page annotations.
34
+ */
35
+ updateAnnotationData(annotations) {
36
+ super.updateAnnotationData(annotations);
37
+ if (annotations) {
38
+ this.toggleChartForm(this.annotationCreationForms, annotations);
39
+ for (const view in this.aggregations) {
40
+ const viewAggregation = this.aggregations[view];
41
+ const deleteAction = this.getViewDeleteAction(viewAggregation, annotations);
42
+ const actions = viewAggregation.actions || [];
43
+ actions.push(deleteAction);
44
+ viewAggregation.actions = actions;
45
+ }
46
+ }
47
+ }
48
+ /**
49
+ * Overwritten method for data update of list report views container node.
50
+ *
51
+ * @param data Data which should be used for value population.
52
+ * @param page Page config data.
53
+ * @param pageType Page type.
54
+ * @param path Aggregation path.
55
+ * @param annotations Annotations data.
56
+ */
57
+ updatePropertiesValues(data, page, pageType, path, annotations) {
58
+ super.updatePropertiesValues(data, page, pageType, path, annotations);
59
+ this.formSchema = this.additionalProperties?.aggregations['views'];
60
+ // Custom creation form - check schema if supported
61
+ if (this.formSchema?.properties?.template) {
62
+ this.schemaCreationForms = [
63
+ {
64
+ name: types_1.AggregationCreationForm.CustomViewV4,
65
+ kind: types_1.SCHEMA_CREATION_FORM,
66
+ title: 'PAGE_EDITOR_OUTLINE_ADD_CUSTOM_VIEW_TITLE',
67
+ disabled: false
68
+ }
69
+ ];
70
+ }
71
+ const views = data || {};
72
+ if (Object.keys(views).length !== 0) {
73
+ for (const id in views) {
74
+ const viewAggregation = this.aggregations[id];
75
+ if (viewAggregation?.schema &&
76
+ !viewAggregation?.schema.properties?.['annotationPath'] &&
77
+ (!viewAggregation.schema.annotationPath ||
78
+ viewAggregation.schema.annotationPath.startsWith(types_1.CUSTOM_VIEW_PREFIX))) {
79
+ viewAggregation.markAsCustomView();
80
+ }
81
+ }
82
+ }
83
+ }
84
+ /**
85
+ * Determines the delete action configuration for a given view aggregation.
86
+ *
87
+ * @param viewAggregation - The view aggregation to evaluate.
88
+ * @param annotations - The current page annotations context.
89
+ * @returns The delete action configuration for the view.
90
+ */
91
+ getViewDeleteAction(viewAggregation, annotations) {
92
+ const id = viewAggregation.annotationNodeId;
93
+ let disableViewDeletion = true;
94
+ const annotationViewsCount = this.getAnnotationViewCount();
95
+ if (id) {
96
+ disableViewDeletion = (0, utils_1.isArrayEqual)(annotations.dialogsContext?.suppressTableViewDeletionNodeId || [], id);
97
+ }
98
+ else if (annotationViewsCount > 1 || (annotationViewsCount === 1 && viewAggregation.custom)) {
99
+ // Allow annotation view deletion if there are at least two annotation views, else deletion only available for custom views
100
+ disableViewDeletion = false;
101
+ }
102
+ return {
103
+ type: types_1.AggregationActions.Delete,
104
+ disabled: disableViewDeletion,
105
+ title: i18next_1.default.t(disableViewDeletion ? 'TABLE_VIEW_DELETE_DISABLED_TOOLTIP' : 'PAGE_EDITOR_OUTLINE_DELETE_TOOLTIP')
106
+ };
107
+ }
108
+ /**
109
+ * Enables/Disables the chart form based on the annotations.
110
+ *
111
+ * @param forms Array of creation forms
112
+ * @param annotations Page annotations
113
+ */
114
+ toggleChartForm(forms, annotations) {
115
+ const chartForm = forms.find((form) => form.name === types_1.AggregationCreationForm.AnalyticalChartView);
116
+ if (chartForm && annotations.dialogsContext?.analyticalChartSupport) {
117
+ if (!annotations.dialogsContext.analyticalChartSupport.addToMultiViewEnabled) {
118
+ chartForm.disabled = true;
119
+ chartForm.disabledTitle = annotations.dialogsContext.analyticalChartSupport.addToMultiViewTooltip;
120
+ }
121
+ else {
122
+ chartForm.disabled = false;
123
+ delete chartForm.disabledTitle;
124
+ }
125
+ }
126
+ }
127
+ /**
128
+ * Method returns count of annotations views.
129
+ *
130
+ * @returns Count of annotations views.
131
+ */
132
+ getAnnotationViewCount() {
133
+ let count = 0;
134
+ for (const view in this.aggregations) {
135
+ const aggregation = this.aggregations[view];
136
+ if (aggregation instanceof ViewAggregation_1.ViewAggregation && aggregation.isAnnotationView()) {
137
+ count++;
138
+ }
139
+ }
140
+ return count;
141
+ }
142
+ }
143
+ exports.ViewsAggregation = ViewsAggregation;
144
+ //# sourceMappingURL=ViewsAggregation.js.map