@sap/ux-specification 1.124.35 → 1.124.37

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 (232) hide show
  1. package/CHANGELOG.md +68 -0
  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 +278 -269
  14. package/dist/index-min.js.map +4 -4
  15. package/dist/schemas/v2/ListReportNewConfig.json +202 -7
  16. package/dist/schemas/v4/ApplicationV4.json +14 -0
  17. package/dist/schemas/v4/BuildingBlocksConfig.json +75 -4
  18. package/dist/specification/package.json +10 -10
  19. package/dist/specification/scripts/macros/corrections.d.ts +1 -0
  20. package/dist/specification/scripts/macros/corrections.d.ts.map +1 -1
  21. package/dist/specification/scripts/macros/corrections.js +126 -2
  22. package/dist/specification/scripts/macros/corrections.js.map +1 -1
  23. package/dist/specification/scripts/macros/schema.d.ts.map +1 -1
  24. package/dist/specification/scripts/macros/schema.js +36 -10
  25. package/dist/specification/scripts/macros/schema.js.map +1 -1
  26. package/dist/specification/scripts/schema/to-json-schema.js +1 -1
  27. package/dist/specification/scripts/schema/to-json-schema.js.map +1 -1
  28. package/dist/specification/src/api.d.ts.map +1 -1
  29. package/dist/specification/src/api.js +39 -3
  30. package/dist/specification/src/api.js.map +1 -1
  31. package/dist/specification/src/ftfs/ftfs.d.ts +8 -0
  32. package/dist/specification/src/ftfs/ftfs.d.ts.map +1 -1
  33. package/dist/specification/src/ftfs/ftfs.js +1 -0
  34. package/dist/specification/src/ftfs/ftfs.js.map +1 -1
  35. package/dist/specification/src/ftfs/index.d.ts +1 -1
  36. package/dist/specification/src/ftfs/index.d.ts.map +1 -1
  37. package/dist/specification/src/ftfs/index.js +2 -1
  38. package/dist/specification/src/ftfs/index.js.map +1 -1
  39. package/dist/specification/src/ftfs/parser/model/TreeModel.d.ts.map +1 -1
  40. package/dist/specification/src/ftfs/parser/model/TreeModel.js +3 -1
  41. package/dist/specification/src/ftfs/parser/model/TreeModel.js.map +1 -1
  42. package/dist/specification/src/i18n/i18n.d.ts.map +1 -1
  43. package/dist/specification/src/i18n/i18n.js +2 -1
  44. package/dist/specification/src/i18n/i18n.js.map +1 -1
  45. package/dist/specification/src/sync/common/decoration/Decorator.d.ts +91 -0
  46. package/dist/specification/src/sync/common/decoration/Decorator.d.ts.map +1 -0
  47. package/dist/specification/src/sync/common/decoration/Decorator.js +139 -0
  48. package/dist/specification/src/sync/common/decoration/Decorator.js.map +1 -0
  49. package/dist/specification/src/sync/common/decoration/condition-evaluator.d.ts +95 -0
  50. package/dist/specification/src/sync/common/decoration/condition-evaluator.d.ts.map +1 -0
  51. package/dist/specification/src/sync/common/decoration/condition-evaluator.js +210 -0
  52. package/dist/specification/src/sync/common/decoration/condition-evaluator.js.map +1 -0
  53. package/dist/specification/src/sync/common/decoration/decorator-paths.d.ts +5 -22
  54. package/dist/specification/src/sync/common/decoration/decorator-paths.d.ts.map +1 -1
  55. package/dist/specification/src/sync/common/decoration/decorator-paths.js.map +1 -1
  56. package/dist/specification/src/sync/common/decoration/decorators.d.ts +6 -48
  57. package/dist/specification/src/sync/common/decoration/decorators.d.ts.map +1 -1
  58. package/dist/specification/src/sync/common/decoration/decorators.js +26 -106
  59. package/dist/specification/src/sync/common/decoration/decorators.js.map +1 -1
  60. package/dist/specification/src/sync/common/decoration/index.d.ts +4 -0
  61. package/dist/specification/src/sync/common/decoration/index.d.ts.map +1 -1
  62. package/dist/specification/src/sync/common/decoration/index.js +4 -0
  63. package/dist/specification/src/sync/common/decoration/index.js.map +1 -1
  64. package/dist/specification/src/sync/common/decoration/interfaces.d.ts +38 -0
  65. package/dist/specification/src/sync/common/decoration/interfaces.d.ts.map +1 -0
  66. package/dist/specification/src/sync/common/decoration/interfaces.js +3 -0
  67. package/dist/specification/src/sync/common/decoration/interfaces.js.map +1 -0
  68. package/dist/specification/src/sync/common/decoration/steps/Enums.d.ts +18 -0
  69. package/dist/specification/src/sync/common/decoration/steps/Enums.d.ts.map +1 -0
  70. package/dist/specification/src/sync/common/decoration/steps/Enums.js +50 -0
  71. package/dist/specification/src/sync/common/decoration/steps/Enums.js.map +1 -0
  72. package/dist/specification/src/sync/common/decoration/steps/Hide.d.ts +18 -0
  73. package/dist/specification/src/sync/common/decoration/steps/Hide.d.ts.map +1 -0
  74. package/dist/specification/src/sync/common/decoration/steps/Hide.js +46 -0
  75. package/dist/specification/src/sync/common/decoration/steps/Hide.js.map +1 -0
  76. package/dist/specification/src/sync/common/decoration/steps/Message.d.ts +26 -0
  77. package/dist/specification/src/sync/common/decoration/steps/Message.d.ts.map +1 -0
  78. package/dist/specification/src/sync/common/decoration/steps/Message.js +77 -0
  79. package/dist/specification/src/sync/common/decoration/steps/Message.js.map +1 -0
  80. package/dist/specification/src/sync/common/decoration/steps/Readonly.d.ts +18 -0
  81. package/dist/specification/src/sync/common/decoration/steps/Readonly.d.ts.map +1 -0
  82. package/dist/specification/src/sync/common/decoration/steps/Readonly.js +43 -0
  83. package/dist/specification/src/sync/common/decoration/steps/Readonly.js.map +1 -0
  84. package/dist/specification/src/sync/common/decoration/steps/Validity.d.ts +18 -0
  85. package/dist/specification/src/sync/common/decoration/steps/Validity.d.ts.map +1 -0
  86. package/dist/specification/src/sync/common/decoration/steps/Validity.js +68 -0
  87. package/dist/specification/src/sync/common/decoration/steps/Validity.js.map +1 -0
  88. package/dist/specification/src/sync/common/decoration/steps/enum-utils.d.ts +19 -0
  89. package/dist/specification/src/sync/common/decoration/steps/enum-utils.d.ts.map +1 -0
  90. package/dist/specification/src/sync/common/decoration/steps/enum-utils.js +48 -0
  91. package/dist/specification/src/sync/common/decoration/steps/enum-utils.js.map +1 -0
  92. package/dist/specification/src/sync/common/decoration/steps/index.d.ts +6 -0
  93. package/dist/specification/src/sync/common/decoration/steps/index.d.ts.map +1 -0
  94. package/dist/specification/src/sync/common/decoration/steps/index.js +14 -0
  95. package/dist/specification/src/sync/common/decoration/steps/index.js.map +1 -0
  96. package/dist/specification/src/sync/common/i18n.json +22 -0
  97. package/dist/specification/src/sync/common/importProject.d.ts.map +1 -1
  98. package/dist/specification/src/sync/common/importProject.js +2 -0
  99. package/dist/specification/src/sync/common/importProject.js.map +1 -1
  100. package/dist/specification/src/sync/v2/export/controls/Fragment.d.ts +4 -5
  101. package/dist/specification/src/sync/v2/export/controls/Fragment.d.ts.map +1 -1
  102. package/dist/specification/src/sync/v2/export/controls/Fragment.js +29 -20
  103. package/dist/specification/src/sync/v2/export/controls/Fragment.js.map +1 -1
  104. package/dist/specification/src/sync/v2/export/export.d.ts.map +1 -1
  105. package/dist/specification/src/sync/v2/export/export.js +3 -2
  106. package/dist/specification/src/sync/v2/export/export.js.map +1 -1
  107. package/dist/specification/src/sync/v2/export/exportPage.d.ts.map +1 -1
  108. package/dist/specification/src/sync/v2/export/exportPage.js +48 -19
  109. package/dist/specification/src/sync/v2/export/exportPage.js.map +1 -1
  110. package/dist/specification/src/sync/v2/export/exportPageGeneric.d.ts +2 -0
  111. package/dist/specification/src/sync/v2/export/exportPageGeneric.d.ts.map +1 -1
  112. package/dist/specification/src/sync/v2/export/exportPageGeneric.js +17 -6
  113. package/dist/specification/src/sync/v2/export/exportPageGeneric.js.map +1 -1
  114. package/dist/specification/src/sync/v2/export/view-controller-generator.d.ts +54 -6
  115. package/dist/specification/src/sync/v2/export/view-controller-generator.d.ts.map +1 -1
  116. package/dist/specification/src/sync/v2/export/view-controller-generator.js +106 -12
  117. package/dist/specification/src/sync/v2/export/view-controller-generator.js.map +1 -1
  118. package/dist/specification/src/sync/v2/generate/analyticalListReport.js +7 -7
  119. package/dist/specification/src/sync/v2/generate/analyticalListReport.js.map +1 -1
  120. package/dist/specification/src/sync/v2/generate/objectPage.d.ts.map +1 -1
  121. package/dist/specification/src/sync/v2/generate/objectPage.js +56 -2
  122. package/dist/specification/src/sync/v2/generate/objectPage.js.map +1 -1
  123. package/dist/specification/src/sync/v2/generate/schemaAdaptation.js +2 -2
  124. package/dist/specification/src/sync/v2/generate/schemaAdaptation.js.map +1 -1
  125. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/FilterBar.js +4 -4
  126. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/MultiEdit.d.ts +12 -0
  127. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/MultiEdit.d.ts.map +1 -0
  128. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/MultiEdit.js +167 -0
  129. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/MultiEdit.js.map +1 -0
  130. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/MultiTable.js +3 -3
  131. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/MultiTable.js.map +1 -1
  132. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/Table.d.ts +59 -2
  133. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/Table.d.ts.map +1 -1
  134. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/Table.js +582 -7
  135. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/Table.js.map +1 -1
  136. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/index.d.ts +1 -0
  137. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/index.d.ts.map +1 -1
  138. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/index.js +1 -0
  139. package/dist/specification/src/sync/v2/genericSchemaHandling/controls/index.js.map +1 -1
  140. package/dist/specification/src/sync/v2/genericSchemaHandling/pages/pageAccess.d.ts.map +1 -1
  141. package/dist/specification/src/sync/v2/genericSchemaHandling/pages/pageAccess.js +29 -6
  142. package/dist/specification/src/sync/v2/genericSchemaHandling/pages/pageAccess.js.map +1 -1
  143. package/dist/specification/src/sync/v2/types.d.ts +2 -0
  144. package/dist/specification/src/sync/v2/types.d.ts.map +1 -1
  145. package/dist/specification/src/sync/v2/types.js.map +1 -1
  146. package/dist/specification/src/sync/v2/utils.d.ts +25 -0
  147. package/dist/specification/src/sync/v2/utils.d.ts.map +1 -1
  148. package/dist/specification/src/sync/v2/utils.js +28 -4
  149. package/dist/specification/src/sync/v2/utils.js.map +1 -1
  150. package/dist/specification/src/sync/v4/application.d.ts +12 -0
  151. package/dist/specification/src/sync/v4/application.d.ts.map +1 -1
  152. package/dist/specification/src/sync/v4/application.js +26 -1
  153. package/dist/specification/src/sync/v4/application.js.map +1 -1
  154. package/dist/specification/src/sync/v4/export/controls/ToolBarAction.d.ts +3 -1
  155. package/dist/specification/src/sync/v4/export/controls/ToolBarAction.d.ts.map +1 -1
  156. package/dist/specification/src/sync/v4/export/controls/ToolBarAction.js +10 -7
  157. package/dist/specification/src/sync/v4/export/controls/ToolBarAction.js.map +1 -1
  158. package/dist/specification/src/sync/v4/export/fpmCustomPage.d.ts +1 -0
  159. package/dist/specification/src/sync/v4/export/fpmCustomPage.d.ts.map +1 -1
  160. package/dist/specification/src/sync/v4/export/fpmCustomPage.js +212 -46
  161. package/dist/specification/src/sync/v4/export/fpmCustomPage.js.map +1 -1
  162. package/dist/specification/src/sync/v4/generate/app.d.ts +11 -0
  163. package/dist/specification/src/sync/v4/generate/app.d.ts.map +1 -0
  164. package/dist/specification/src/sync/v4/generate/app.js +31 -0
  165. package/dist/specification/src/sync/v4/generate/app.js.map +1 -0
  166. package/dist/specification/src/sync/v4/generate/fpm-custom-page/annotations.d.ts +13 -0
  167. package/dist/specification/src/sync/v4/generate/fpm-custom-page/annotations.d.ts.map +1 -1
  168. package/dist/specification/src/sync/v4/generate/fpm-custom-page/annotations.js +93 -13
  169. package/dist/specification/src/sync/v4/generate/fpm-custom-page/annotations.js.map +1 -1
  170. package/dist/specification/src/sync/v4/generate/fpm-custom-page/extensions.d.ts.map +1 -1
  171. package/dist/specification/src/sync/v4/generate/fpm-custom-page/extensions.js +4 -3
  172. package/dist/specification/src/sync/v4/generate/fpm-custom-page/extensions.js.map +1 -1
  173. package/dist/specification/src/sync/v4/generate/fpm-custom-page/generator.d.ts.map +1 -1
  174. package/dist/specification/src/sync/v4/generate/fpm-custom-page/generator.js +29 -27
  175. package/dist/specification/src/sync/v4/generate/fpm-custom-page/generator.js.map +1 -1
  176. package/dist/specification/src/sync/v4/generate/fpm-custom-page/utils.d.ts.map +1 -1
  177. package/dist/specification/src/sync/v4/generate/fpm-custom-page/utils.js +12 -3
  178. package/dist/specification/src/sync/v4/generate/fpm-custom-page/utils.js.map +1 -1
  179. package/dist/specification/src/sync/v4/generate/list-report/ListReportUtils.js.map +1 -1
  180. package/dist/specification/src/sync/v4/generate/objectPage.js +17 -23
  181. package/dist/specification/src/sync/v4/generate/objectPage.js.map +1 -1
  182. package/dist/specification/src/sync/v4/import/pages/fpmCustomPage.d.ts.map +1 -1
  183. package/dist/specification/src/sync/v4/import/pages/fpmCustomPage.js +20 -0
  184. package/dist/specification/src/sync/v4/import/pages/fpmCustomPage.js.map +1 -1
  185. package/dist/specification/src/sync/v4/sync-rules/App.d.ts +2 -4
  186. package/dist/specification/src/sync/v4/sync-rules/App.d.ts.map +1 -1
  187. package/dist/specification/src/sync/v4/sync-rules/App.js +2 -1
  188. package/dist/specification/src/sync/v4/sync-rules/App.js.map +1 -1
  189. package/dist/specification/src/sync/v4/sync-rules/AppSchema.d.ts +2 -1
  190. package/dist/specification/src/sync/v4/sync-rules/AppSchema.d.ts.map +1 -1
  191. package/dist/specification/src/sync/v4/sync-rules/AppSchema.js +3 -1
  192. package/dist/specification/src/sync/v4/sync-rules/AppSchema.js.map +1 -1
  193. package/dist/specification/src/sync/v4/sync-rules/DecoratorClass.d.ts +119 -127
  194. package/dist/specification/src/sync/v4/sync-rules/DecoratorClass.d.ts.map +1 -1
  195. package/dist/specification/src/sync/v4/sync-rules/DecoratorClass.js +172 -171
  196. package/dist/specification/src/sync/v4/sync-rules/DecoratorClass.js.map +1 -1
  197. package/dist/specification/src/sync/v4/sync-rules/Page.d.ts +7 -1
  198. package/dist/specification/src/sync/v4/sync-rules/Page.d.ts.map +1 -1
  199. package/dist/specification/src/sync/v4/sync-rules/Page.js.map +1 -1
  200. package/dist/specification/src/sync/v4/utils/macros.d.ts +19 -0
  201. package/dist/specification/src/sync/v4/utils/macros.d.ts.map +1 -1
  202. package/dist/specification/src/sync/v4/utils/macros.js +34 -0
  203. package/dist/specification/src/sync/v4/utils/macros.js.map +1 -1
  204. package/dist/specification/test/test-utils/utils.d.ts.map +1 -1
  205. package/dist/specification/test/test-utils/utils.js +4 -0
  206. package/dist/specification/test/test-utils/utils.js.map +1 -1
  207. package/dist/specification/test/unit/decorators/validity-test-utils.d.ts +2 -2
  208. package/dist/specification/test/unit/decorators/validity-test-utils.d.ts.map +1 -1
  209. package/dist/specification/test/unit/decorators/validity-test-utils.js +6 -6
  210. package/dist/specification/test/unit/decorators/validity-test-utils.js.map +1 -1
  211. package/dist/templates/AnalyticalTableColumnsExtension.xml +3 -3
  212. package/dist/templates/GridTableColumnsExtension.xml +3 -3
  213. package/dist/templates/ResponsiveTableColumnsExtension.xml +2 -2
  214. package/dist/templates/TreeTableColumnsExtension.xml +4 -4
  215. package/dist/templates/fragment.xml +3 -3
  216. package/dist/templates/view.xml +3 -3
  217. package/dist/types/src/apiTypes.d.ts +15 -5
  218. package/dist/types/src/apiTypes.d.ts.map +1 -1
  219. package/dist/types/src/apiTypes.js +1 -0
  220. package/dist/types/src/apiTypes.js.map +1 -1
  221. package/dist/types/src/common/types.d.ts +1 -0
  222. package/dist/types/src/common/types.d.ts.map +1 -1
  223. package/dist/types/src/common/types.js.map +1 -1
  224. package/dist/types/src/common/webapp/manifest/Manifest.d.ts +2 -1
  225. package/dist/types/src/common/webapp/manifest/Manifest.d.ts.map +1 -1
  226. package/dist/types/src/common/webapp/manifest/Manifest.js +1 -0
  227. package/dist/types/src/common/webapp/manifest/Manifest.js.map +1 -1
  228. package/dist/types/src/v4/application.d.ts +15 -0
  229. package/dist/types/src/v4/application.d.ts.map +1 -1
  230. package/dist/types/src/v4/application.js +10 -0
  231. package/dist/types/src/v4/application.js.map +1 -1
  232. package/package.json +11 -11
@@ -10,13 +10,13 @@ const i18next_1 = __importDefault(require("i18next"));
10
10
  const jsonpath_plus_1 = require("jsonpath-plus");
11
11
  const utils_1 = require("./utils");
12
12
  /**
13
- * Adds a message to a schema element.
14
- * Inlined to avoid circular dependency issues.
13
+ * Appends a message to a schema element's message array.
14
+ * Inlined here to avoid circular dependency issues.
15
15
  *
16
- * @param element - The schema element to add the message to
17
- * @param message - The message parameters
18
- * @param message.text - The message text
19
- * @param message.deletable - Whether the message is deletable (default: false)
16
+ * @param element - The schema element that will receive the message
17
+ * @param message - The message content and options
18
+ * @param message.text - The translated message text to display
19
+ * @param message.deletable - Whether the user can dismiss the message (default: false)
20
20
  */
21
21
  function addMessageToSchema(element, { text, deletable = false }) {
22
22
  if (!element[ux_specification_types_1.SchemaTag.messages]) {
@@ -26,9 +26,9 @@ function addMessageToSchema(element, { text, deletable = false }) {
26
26
  }
27
27
  class BaseConstruct {
28
28
  /**
29
- * Constructor for BaseConstruct.
29
+ * Creates the base construct with access to the app schema, app/page configuration, and logger.
30
30
  *
31
- * @param settings - General settings including appSchema, app, page, and logger
31
+ * @param settings - Shared context (appSchema, app, page, logger) passed to all decorator classes
32
32
  */
33
33
  constructor(settings) {
34
34
  const { app, appSchema, page, logger } = settings || {};
@@ -59,9 +59,9 @@ class BaseConstruct {
59
59
  });
60
60
  }
61
61
  /**
62
- * Gets the general settings.
62
+ * Returns the shared context (appSchema, app, page, logger) for use by subclasses or callers.
63
63
  *
64
- * @returns The general settings object
64
+ * @returns The current settings object
65
65
  */
66
66
  getSettings() {
67
67
  return {
@@ -75,9 +75,9 @@ class BaseConstruct {
75
75
  exports.BaseConstruct = BaseConstruct;
76
76
  class BaseClass extends BaseConstruct {
77
77
  /**
78
- * Creates an instance of BaseClass.
78
+ * Looks up the matching schema definition by class name and stores it as the base.
79
79
  *
80
- * @param settings - General settings including appSchema, app, page, and logger
80
+ * @param settings - Shared context (appSchema, app, page, logger) passed to all decorator classes
81
81
  */
82
82
  constructor(settings) {
83
83
  super(settings);
@@ -91,36 +91,36 @@ class BaseClass extends BaseConstruct {
91
91
  });
92
92
  }
93
93
  /**
94
- * Gets the class name.
94
+ * Returns the class name used to look up the matching schema definition.
95
95
  *
96
- * @returns The name of the class
96
+ * @returns The constructor name of this class
97
97
  */
98
98
  getClassName() {
99
99
  return this.constructor.name;
100
100
  }
101
101
  /**
102
- * Gets the base name.
102
+ * Returns the name stored at construction time for the schema definition lookup.
103
103
  *
104
- * @returns The base name
104
+ * @returns The base definition name
105
105
  */
106
106
  getBaseName() {
107
107
  return this.base.name;
108
108
  }
109
109
  /**
110
- * Gets the base definition.
110
+ * Returns the schema definition that decorators are applied to.
111
111
  *
112
- * @returns The base definition
112
+ * @returns The JSON schema definition for this class
113
113
  */
114
114
  getBase() {
115
115
  return this.base.definition;
116
116
  }
117
117
  /**
118
- * Creates an annotation path for schema based on entity type, term, and qualifier.
118
+ * Builds an annotation path like `/<EntityType>/@<Term>#<Qualifier>` and stores it on the schema definition.
119
119
  *
120
- * @param entityTypeName - Entity type name.
121
- * @param term - Annotation term.
122
- * @param qualifier - Annotation qualifier (optional).
123
- * @returns Annotation path based on received params
120
+ * @param entityTypeName - The OData entity type name (e.g. "SalesOrderItem")
121
+ * @param term - The annotation term (e.g. "com.sap.vocabularies.UI.v1.LineItem")
122
+ * @param qualifier - Optional qualifier to disambiguate multiple annotations of the same term
123
+ * @returns The built annotation path, or undefined if entityTypeName is empty
124
124
  */
125
125
  createAnnotationPath(entityTypeName, term, qualifier) {
126
126
  if (!entityTypeName) {
@@ -137,9 +137,9 @@ class BaseClass extends BaseConstruct {
137
137
  exports.BaseClass = BaseClass;
138
138
  class Decorator extends BaseClass {
139
139
  /**
140
- * Creates an instance of Decorator.
140
+ * Sets up the decorator context as non-enumerable so it stays hidden from serialization.
141
141
  *
142
- * @param settings - General settings including appSchema, app, page, and logger
142
+ * @param settings - Shared context (appSchema, app, page, logger) passed to all decorator classes
143
143
  */
144
144
  constructor(settings) {
145
145
  super(settings);
@@ -152,17 +152,11 @@ class Decorator extends BaseClass {
152
152
  });
153
153
  }
154
154
  /**
155
- * Initializes the decorator by applying all decorators to the schema definition.
155
+ * Builds the decorator context from app, page, and custom values, then applies all
156
+ * decorators (enums, message, hide, readonly) to the schema definition.
156
157
  *
157
- * The decorator context is structured as:
158
- * - `app`: The App configuration (from `this.app.config`, includes manifest)
159
- * - `page`: The Page configuration (from `this.page.config`)
160
- * - `custom`: Custom context provided by the caller.
161
- *
162
- * @param customContext - Optional custom context for decorator conditions.
163
- * Use this for runtime-specific conditions like table state, section state, etc.
164
- * @param definition - Optional custom definition to apply decorators to.
165
- * If provided, decorators are applied to this definition instead of the one from appSchema.
158
+ * @param customContext - Specific values (e.g. table state, section state) used for condition evaluation
159
+ * @param definition - Override the schema definition to decorate (defaults to getBase())
166
160
  * @example
167
161
  * ```typescript
168
162
  * // Basic initialization (app and page auto-injected)
@@ -179,21 +173,22 @@ class Decorator extends BaseClass {
179
173
  */
180
174
  init(customContext, definition) {
181
175
  this.decoratorContext = {
182
- app: this.app?.config,
183
- page: this.page?.config,
184
- custom: customContext
176
+ app: this.app,
177
+ page: this.page,
178
+ custom: customContext,
179
+ schema: this.appSchema
185
180
  };
186
181
  // @ToDo activate for actual use of minUI5Version.
187
182
  // const minUi5Version = this.app?.getMinUI5Version();
188
183
  this.applyDecorators(undefined, undefined, definition);
189
184
  }
190
185
  /**
191
- * Gets property value from the decorator context using a property path.
192
- *
193
- * The path must include an explicit source prefix ('app', 'page', or 'custom').
186
+ * Resolves a dotted property path (e.g. `page.isALP`, `custom.items[0].name`) against
187
+ * the decorator context using JSONPath. The path must start with a known source prefix
188
+ * (`app`, `page`, or `custom`).
194
189
  *
195
- * @param propertyPath - The property path with explicit source prefix - supports full jsonpath syntax
196
- * @returns Object containing the final key and its value, or undefined if not found
190
+ * @param propertyPath - Dotted path with source prefix, supports full JSONPath syntax
191
+ * @returns The resolved `{ key, value }` pair, or undefined if the path does not resolve
197
192
  * @example
198
193
  * ```typescript
199
194
  * // With decoratorContext = {
@@ -239,14 +234,11 @@ class Decorator extends BaseClass {
239
234
  }
240
235
  }
241
236
  /**
242
- * Evaluates a single dependency condition.
243
- *
244
- * @param condition - The single condition to evaluate
245
- * @param condition.path - The property path to check
246
- * @param condition.dependsOn - Optional custom condition function
247
- * @param condition.expectedValue - Optional expected value for equality check
248
- * @param condition.negate - Optional flag to invert the condition result
249
- * @returns Object containing whether condition passed and the dependency value
237
+ * Evaluates one condition: resolves the path, applies the check (custom function,
238
+ * equality, or truthy), and optionally negates the result (for `not()` conditions).
239
+ *
240
+ * @param condition - A single condition with path, expected value, and optional negate flag
241
+ * @returns Whether the condition passed along with the resolved value and key
250
242
  */
251
243
  evaluateSingleCondition(condition) {
252
244
  // Handle special __always__ path (from @hide(true))
@@ -276,16 +268,17 @@ class Decorator extends BaseClass {
276
268
  return { passed, value, key };
277
269
  }
278
270
  /**
279
- * Helper method to add a message to the schema property based on value condition.
280
- *
281
- * @param condition - DecoratorMetadata or EnumValueCondition object containing condition details
282
- * @param syncRuleProviderInstance - The instance of the sync rule provider
283
- * @param definition - The schema property definition
284
- * @param i18nProperties - i18n properties for message translation
285
- * @param i18nProperties.propertyName - The property name for the message
286
- * @param i18nProperties.context - The context for the message
271
+ * Translates and attaches a message to a schema property.
272
+ * Supports both the new `MessageConfig` format (from `msg()` helper) and the legacy `DependsOnMessage` format.
273
+ *
274
+ * @param condition - The decorator metadata or enum value condition containing the message definition
275
+ * @param decoratedClass - The decorated class instance, used for legacy function-based message text
276
+ * @param definition - The schema property definition to attach the message to
277
+ * @param i18nProperties - Context for i18n translation (propertyName, evaluation context)
278
+ * @param i18nProperties.propertyName - The property name used as i18n parameter
279
+ * @param i18nProperties.context - The evaluation context string used as i18n parameter
287
280
  */
288
- addConditionalMessage(condition, syncRuleProviderInstance, definition, i18nProperties) {
281
+ addConditionalMessage(condition, decoratedClass, definition, i18nProperties) {
289
282
  // Handle new MessageConfig format (from msg() helper)
290
283
  const metadata = condition;
291
284
  if (metadata.messageConfig && (0, decoration_1.isMessageConfig)(metadata.messageConfig)) {
@@ -301,7 +294,7 @@ class Decorator extends BaseClass {
301
294
  }
302
295
  let messageText;
303
296
  if (typeof condition.message.text === 'function') {
304
- messageText = condition.message.text(syncRuleProviderInstance);
297
+ messageText = condition.message.text(decoratedClass);
305
298
  }
306
299
  else if (typeof condition.message.text === 'string') {
307
300
  messageText = condition.message.text;
@@ -316,10 +309,10 @@ class Decorator extends BaseClass {
316
309
  addMessageToSchema(definition, { text: messageText, deletable: condition.message.deletable });
317
310
  }
318
311
  /**
319
- * Resolves PathNode values in message params to their actual values from the decorator context.
312
+ * Resolves any `PathNode` values in message params to their actual values from the decorator context.
320
313
  *
321
- * @param params - The message params potentially containing PathNode values
322
- * @returns The params with PathNode values resolved to actual values
314
+ * @param params - Message parameters that may contain PathNode references
315
+ * @returns A new params object with PathNode values replaced by their resolved context values
323
316
  */
324
317
  resolveMessageParams(params) {
325
318
  if (!params) {
@@ -339,10 +332,11 @@ class Decorator extends BaseClass {
339
332
  return resolved;
340
333
  }
341
334
  /**
342
- * Gets the context message from evaluation results.
335
+ * Builds a human-readable context string from the evaluation results that did not pass.
336
+ * Used for diagnostic messages showing which conditions were unmet.
343
337
  *
344
- * @param results - The evaluation results
345
- * @returns The context message string
338
+ * @param results - The condition evaluation results to summarize
339
+ * @returns A comma-separated string of `key: value` pairs for failed conditions
346
340
  */
347
341
  getContextForMessage(results) {
348
342
  return results
@@ -351,10 +345,10 @@ class Decorator extends BaseClass {
351
345
  .join(', ');
352
346
  }
353
347
  /**
354
- * Evaluates an AND condition item which can be either a single condition or a nested OR group.
348
+ * Evaluates one item inside an AND group either a single condition or a nested OR group.
355
349
  *
356
- * @param conditionItem - The condition item to evaluate
357
- * @returns Object containing whether condition passed and evaluation details
350
+ * @param conditionItem - A single condition or a nested `{ __orConditions }` group
351
+ * @returns Whether the item passed and the detailed evaluation results
358
352
  */
359
353
  evaluateAndConditionItem(conditionItem) {
360
354
  // Check if this is a nested OR group
@@ -367,11 +361,11 @@ class Decorator extends BaseClass {
367
361
  return { passed: result.passed, results: [result] };
368
362
  }
369
363
  /**
370
- * Evaluates OR conditions (at least one condition must match).
371
- * Supports both single conditions and nested AND groups.
364
+ * Evaluates OR conditions — passes when at least one item (single condition or nested AND group) matches.
365
+ * Short-circuits on the first passing item.
372
366
  *
373
- * @param orConditions - Array of condition items (single conditions or AND groups)
374
- * @returns Object containing whether any condition passed and evaluation details
367
+ * @param orConditions - Array of conditions or nested AND groups to evaluate
368
+ * @returns Whether any condition passed and the collected evaluation results
375
369
  */
376
370
  evaluateOrConditions(orConditions) {
377
371
  const allResults = [];
@@ -408,11 +402,11 @@ class Decorator extends BaseClass {
408
402
  return { passed: false, results: allResults };
409
403
  }
410
404
  /**
411
- * Evaluates AND conditions (all conditions must match).
412
- * Supports both single conditions and nested OR groups.
405
+ * Evaluates AND conditions — passes only when every item (single condition or nested OR group) matches.
406
+ * Continues even after a failure to collect all results for diagnostic context.
413
407
  *
414
- * @param andConditions - Array of condition items (single conditions or OR groups)
415
- * @returns Object containing whether all conditions passed and evaluation details
408
+ * @param andConditions - Array of conditions or nested OR groups that must all pass
409
+ * @returns Whether all conditions passed and the collected evaluation results
416
410
  */
417
411
  evaluateAndConditions(andConditions) {
418
412
  const allResults = [];
@@ -428,10 +422,11 @@ class Decorator extends BaseClass {
428
422
  return { passed: allPassed, results: allResults };
429
423
  }
430
424
  /**
431
- * Evaluates condition metadata and returns whether the condition is met and the context.
425
+ * Entry point for condition evaluation. Dispatches to OR, AND, or single evaluation
426
+ * depending on the shape of the condition metadata.
432
427
  *
433
- * @param conditionInfo - The condition metadata
434
- * @returns Object with passed (boolean) and context (string)
428
+ * @param conditionInfo - The decorator condition metadata (single, AND, or OR)
429
+ * @returns Whether the condition passed and a diagnostic context string
435
430
  */
436
431
  evaluateCondition(conditionInfo) {
437
432
  let passed = false;
@@ -458,12 +453,12 @@ class Decorator extends BaseClass {
458
453
  return { passed, context };
459
454
  }
460
455
  /**
461
- * Iterates over schema properties and yields property info for decorator processing.
462
- * Centralizes the guard clause and property iteration logic.
456
+ * Yields each property from a schema definition for decorator processing.
457
+ * Returns early if the definition has no properties or the target is falsy.
463
458
  *
464
- * @param schemaDefinition - The schema definition to process
465
- * @param target - The target object (used for guard clause validation)
466
- * @yields Property name and definition for each property in the schema
459
+ * @param schemaDefinition - The schema definition whose properties to iterate
460
+ * @param target - Guard object iteration is skipped if falsy
461
+ * @yields Property name and its definition for each property in the schema
467
462
  */
468
463
  *iterateProperties(schemaDefinition, target) {
469
464
  if (!schemaDefinition?.properties || !target) {
@@ -475,42 +470,45 @@ class Decorator extends BaseClass {
475
470
  }
476
471
  }
477
472
  /**
478
- * Applies the hide decorator to the schema definition.
479
- * Hides properties when their condition evaluates to true, but only if
480
- * the message decorator did not add any messages to the property.
473
+ * Hides properties whose `@hide` conditions pass.
474
+ * Multiple `@hide` decorators use OR semantics any passing condition hides the property.
475
+ * Skipped when the `@message` decorator already added messages to the property.
481
476
  *
482
- * @param schemaDefinition - The schema definition to apply the decorator to
483
- * @param syncRuleProviderInstance - The sync rule provider instance
477
+ * @param schemaDefinition - The schema definition to process
478
+ * @param decoratedClass - The decorated class instance carrying `@hide` metadata
484
479
  */
485
- applyHideDecorator(schemaDefinition, syncRuleProviderInstance) {
486
- for (const { propertyName, property } of this.iterateProperties(schemaDefinition, syncRuleProviderInstance)) {
487
- const hideInfo = (0, decoration_1.getHideMetadata)(syncRuleProviderInstance, propertyName);
488
- if (hideInfo) {
489
- const { passed } = this.evaluateCondition(hideInfo);
490
- // Hide when condition IS met (passed=true means hide)
480
+ applyHideDecorator(schemaDefinition, decoratedClass) {
481
+ for (const { propertyName, property } of this.iterateProperties(schemaDefinition, decoratedClass)) {
482
+ const hideConditions = Reflect.getMetadata(decoration_1.metadataKeys.hide, decoratedClass, propertyName);
483
+ if (hideConditions) {
484
+ // Hide when ANY condition IS met (OR semantics across multiple @hide decorators)
491
485
  // But only if no messages were added by the message decorator
492
486
  const hasMessages = Array.isArray(property[ux_specification_types_1.SchemaTag.messages]) && property[ux_specification_types_1.SchemaTag.messages].length > 0;
493
- if (passed && !hasMessages) {
494
- property[ux_specification_types_1.SchemaTag.hidden] = true;
487
+ for (const condition of hideConditions) {
488
+ const { passed } = this.evaluateCondition(condition);
489
+ if (passed && !hasMessages) {
490
+ property[ux_specification_types_1.SchemaTag.hidden] = true;
491
+ break;
492
+ }
495
493
  }
496
494
  }
497
495
  }
498
496
  }
499
497
  /**
500
- * Applies the message decorator to the schema definition.
501
- * Shows messages when their condition evaluates to true.
498
+ * Shows messages on properties whose `@message` conditions pass.
499
+ * Must run before `applyHideDecorator` so hide can detect existing messages.
502
500
  *
503
- * @param schemaDefinition - The schema definition to apply the decorator to
504
- * @param syncRuleProviderInstance - The sync rule provider instance
501
+ * @param schemaDefinition - The schema definition to process
502
+ * @param decoratedClass - The decorated class instance carrying `@message` metadata
505
503
  */
506
- applyMessageDecorator(schemaDefinition, syncRuleProviderInstance) {
507
- for (const { propertyName, property } of this.iterateProperties(schemaDefinition, syncRuleProviderInstance)) {
508
- const messageInfoList = (0, decoration_1.getMessageMetadata)(syncRuleProviderInstance, propertyName);
509
- if (messageInfoList) {
510
- for (const messageInfo of messageInfoList) {
511
- const { passed, context } = this.evaluateCondition(messageInfo);
512
- if (passed && (messageInfo.message || messageInfo.messageConfig)) {
513
- this.addConditionalMessage(messageInfo, syncRuleProviderInstance, property, {
504
+ applyMessageDecorator(schemaDefinition, decoratedClass) {
505
+ for (const { propertyName, property } of this.iterateProperties(schemaDefinition, decoratedClass)) {
506
+ const messageConditions = Reflect.getMetadata(decoration_1.metadataKeys.message, decoratedClass, propertyName);
507
+ if (messageConditions) {
508
+ for (const condition of messageConditions) {
509
+ const { passed, context } = this.evaluateCondition(condition);
510
+ if (passed && (condition.message || condition.messageConfig)) {
511
+ this.addConditionalMessage(condition, decoratedClass, property, {
514
512
  propertyName,
515
513
  context
516
514
  });
@@ -520,45 +518,48 @@ class Decorator extends BaseClass {
520
518
  }
521
519
  }
522
520
  /**
523
- * Applies the readonly decorator to the schema definition.
524
- * Marks properties as readonly when their condition evaluates to true.
521
+ * Marks properties as read-only whose `@readonly` conditions pass.
522
+ * Multiple `@readonly` decorators use OR semantics — any passing condition makes the property read-only.
525
523
  *
526
- * @param schemaDefinition - The schema definition to apply the decorator to
527
- * @param syncRuleProviderInstance - The sync rule provider instance
524
+ * @param schemaDefinition - The schema definition to process
525
+ * @param decoratedClass - The decorated class instance carrying `@readonly` metadata
528
526
  */
529
- applyReadonlyDecorator(schemaDefinition, syncRuleProviderInstance) {
530
- for (const { propertyName, property } of this.iterateProperties(schemaDefinition, syncRuleProviderInstance)) {
531
- const readonlyInfo = (0, decoration_1.getReadonlyMetadata)(syncRuleProviderInstance, propertyName);
532
- if (readonlyInfo) {
533
- const { passed } = this.evaluateCondition(readonlyInfo);
534
- if (passed) {
535
- property.readOnly = true;
527
+ applyReadonlyDecorator(schemaDefinition, decoratedClass) {
528
+ for (const { propertyName, property } of this.iterateProperties(schemaDefinition, decoratedClass)) {
529
+ const readonlyConditions = Reflect.getMetadata(decoration_1.metadataKeys.readonly, decoratedClass, propertyName);
530
+ if (readonlyConditions) {
531
+ // Readonly when ANY condition IS met (OR semantics across multiple @readonly decorators)
532
+ for (const condition of readonlyConditions) {
533
+ const { passed } = this.evaluateCondition(condition);
534
+ if (passed) {
535
+ property.readOnly = true;
536
+ break;
537
+ }
536
538
  }
537
539
  }
538
540
  }
539
541
  }
540
542
  /**
541
- * Applies the enums decorator to the schema definition.
542
- * Restricts enum values when their condition evaluates to true.
543
- * If multiple @enums decorators exist on the same property, the first matching condition wins.
543
+ * Restricts enum values on properties whose `@enums` conditions pass.
544
+ * When multiple `@enums` decorators exist on the same property, the first matching condition wins.
544
545
  *
545
- * @param schemaDefinition - The schema definition to apply the decorator to
546
- * @param syncRuleProviderInstance - The sync rule provider instance
546
+ * @param schemaDefinition - The schema definition to process
547
+ * @param decoratedClass - The decorated class instance carrying `@enums` metadata
547
548
  */
548
- applyEnumsDecorator(schemaDefinition, syncRuleProviderInstance) {
549
- for (const { propertyName, property } of this.iterateProperties(schemaDefinition, syncRuleProviderInstance)) {
550
- const enumsMetadataList = (0, decoration_1.getEnumsMetadata)(syncRuleProviderInstance, propertyName);
551
- if (!enumsMetadataList?.length) {
549
+ applyEnumsDecorator(schemaDefinition, decoratedClass) {
550
+ for (const { propertyName, property } of this.iterateProperties(schemaDefinition, decoratedClass)) {
551
+ const enumsConditions = Reflect.getMetadata(decoration_1.metadataKeys.enums, decoratedClass, propertyName);
552
+ if (!enumsConditions?.length) {
552
553
  continue;
553
554
  }
554
555
  // Find first matching condition (first match wins)
555
- for (const enumsMetadata of enumsMetadataList) {
556
- const { passed } = this.evaluateCondition(enumsMetadata);
556
+ for (const condition of enumsConditions) {
557
+ const { passed } = this.evaluateCondition(condition);
557
558
  if (passed) {
558
559
  const currentEnumValues = this.resolveEnumFromProperty(property);
559
560
  if (currentEnumValues) {
560
561
  // Filter to only allowed values that exist in original enum
561
- const filteredValues = enumsMetadata.allowedValues.filter((v) => currentEnumValues.includes(v));
562
+ const filteredValues = condition.allowedValues.filter((v) => currentEnumValues.includes(v));
562
563
  this.applyFilteredEnumToProperty(property, filteredValues);
563
564
  }
564
565
  break; // First match wins, stop processing
@@ -567,11 +568,11 @@ class Decorator extends BaseClass {
567
568
  }
568
569
  }
569
570
  /**
570
- * Gets the validity metadata for a property.
571
+ * Reads the `@validity` metadata stored on a property of the decorated class.
571
572
  *
572
- * @param target - The target object
573
- * @param propertyName - The property name
574
- * @returns The validity metadata or undefined
573
+ * @param target - The decorated class instance
574
+ * @param propertyName - The property to read validity metadata from
575
+ * @returns The validity constraints (since, enum restrictions), or undefined if none
575
576
  */
576
577
  getValidityMetadata(target, propertyName) {
577
578
  let validityInfo;
@@ -581,11 +582,10 @@ class Decorator extends BaseClass {
581
582
  return validityInfo;
582
583
  }
583
584
  /**
584
- * Resolves an enum array from a property definition.
585
- * Handles both inline enums and $ref to enum definitions.
585
+ * Returns the enum values from a property definition, resolving `$ref` to a shared enum definition if needed.
586
586
  *
587
- * @param property - The property definition
588
- * @returns The enum array or undefined if not found
587
+ * @param property - The schema property definition (may have inline `enum` or a `$ref`)
588
+ * @returns The enum values array, or undefined if the property is not an enum
589
589
  */
590
590
  resolveEnumFromProperty(property) {
591
591
  // Check for inline enum
@@ -604,12 +604,11 @@ class Decorator extends BaseClass {
604
604
  return undefined;
605
605
  }
606
606
  /**
607
- * Applies filtered enum values to a property.
608
- * For $ref properties, inlines the filtered enum, copies the type from the referenced definition, and removes the $ref.
609
- * For inline enum properties, updates the enum directly.
607
+ * Writes filtered enum values to a property definition.
608
+ * For `$ref` properties, inlines the enum, copies the type, and removes the `$ref`.
610
609
  *
611
- * @param property - The property definition to update
612
- * @param filteredEnum - The filtered enum values
610
+ * @param property - The schema property definition to update
611
+ * @param filteredEnum - The allowed enum values after filtering
613
612
  */
614
613
  applyFilteredEnumToProperty(property, filteredEnum) {
615
614
  if (property.$ref) {
@@ -631,19 +630,19 @@ class Decorator extends BaseClass {
631
630
  }
632
631
  }
633
632
  /**
634
- * Applies the validity decorator to the schema definition based on the sync rule provider instance and minimum UI5 version.
633
+ * Hides properties and filters enum values that require a UI5 version higher than the app's minimum.
635
634
  *
636
- * @param schemaDefinition The schema definition to apply the validity decorator to
637
- * @param syncRuleProviderInstance The instance of the sync rule provider
638
- * @param minUI5Version The minimum UI5 version to consider for validity checks
635
+ * @param schemaDefinition - The schema definition to process
636
+ * @param decoratedClass - The decorated class instance carrying `@validity` metadata
637
+ * @param minUI5Version - The app's minimum UI5 version to check against
639
638
  */
640
- applyValidityDecorator(schemaDefinition, syncRuleProviderInstance, minUI5Version) {
641
- if (!schemaDefinition?.properties || !syncRuleProviderInstance || !minUI5Version) {
639
+ applyValidityDecorator(schemaDefinition, decoratedClass, minUI5Version) {
640
+ if (!schemaDefinition?.properties || !decoratedClass || !minUI5Version) {
642
641
  return;
643
642
  }
644
643
  for (const propertyName in schemaDefinition.properties) {
645
644
  const property = schemaDefinition.properties[propertyName];
646
- const validityInfo = this.getValidityMetadata(syncRuleProviderInstance, propertyName);
645
+ const validityInfo = this.getValidityMetadata(decoratedClass, propertyName);
647
646
  // Check if property has a 'since' requirement that exceeds the app's minUI5Version
648
647
  if (validityInfo?.since && !(0, utils_1.compareUI5Versions)(minUI5Version, validityInfo.since)) {
649
648
  property[ux_specification_types_1.SchemaTag.hidden] = true;
@@ -664,7 +663,7 @@ class Decorator extends BaseClass {
664
663
  if (condition.since && minUI5Version) {
665
664
  if (!(0, utils_1.compareUI5Versions)(minUI5Version, condition.since)) {
666
665
  if (condition.message) {
667
- this.addConditionalMessage(condition, syncRuleProviderInstance, property, {
666
+ this.addConditionalMessage(condition, decoratedClass, property, {
668
667
  propertyName: enumValueStr
669
668
  });
670
669
  }
@@ -673,9 +672,9 @@ class Decorator extends BaseClass {
673
672
  }
674
673
  // Check property dependency using dependsOn function
675
674
  if (condition.dependsOn) {
676
- if (!condition.dependsOn(syncRuleProviderInstance)) {
675
+ if (!condition.dependsOn(decoratedClass)) {
677
676
  if (condition.message) {
678
- this.addConditionalMessage(condition, syncRuleProviderInstance, property, {
677
+ this.addConditionalMessage(condition, decoratedClass, property, {
679
678
  propertyName: enumValueStr
680
679
  });
681
680
  }
@@ -693,11 +692,11 @@ class Decorator extends BaseClass {
693
692
  }
694
693
  }
695
694
  /**
696
- * Applies the isViewNode decorator to the schema definition based on the target and property name.
695
+ * Marks the schema definition as a view node if the `@isViewNode` decorator is present on the target.
697
696
  *
698
- * @param schemaDefinition The schema definition to apply the isViewNode decorator to
699
- * @param target The target object or function
700
- * @param propertyName The property name (optional)
697
+ * @param schemaDefinition - The schema definition to tag
698
+ * @param target - The class constructor or prototype carrying the decorator
699
+ * @param propertyName - Optional property name for property-level decorators
701
700
  */
702
701
  applyIsViewNodeDecorator(schemaDefinition, target, propertyName) {
703
702
  const isViewNode = Reflect.getMetadata(decoration_1.metadataKeys.isViewNode, target, propertyName);
@@ -707,11 +706,11 @@ class Decorator extends BaseClass {
707
706
  }
708
707
  }
709
708
  /**
710
- * Applies the description decorator to the schema definition.
709
+ * Sets the schema `description` field from the `@description` decorator if present on the target.
711
710
  *
712
- * @param schemaDefinition - The schema definition to apply the decorator to
713
- * @param target - The target object or function
714
- * @param propertyName - The property name (optional)
711
+ * @param schemaDefinition - The schema definition to update
712
+ * @param target - The class constructor or prototype carrying the decorator
713
+ * @param propertyName - Optional property name for property-level decorators
715
714
  */
716
715
  applyDescriptionDecorator(schemaDefinition, target, propertyName) {
717
716
  const description = Reflect.getMetadata(decoration_1.metadataKeys.description, target, propertyName);
@@ -720,12 +719,14 @@ class Decorator extends BaseClass {
720
719
  }
721
720
  }
722
721
  /**
723
- * Applies all decorators to the schema definition.
724
- *
725
- * @param minUi5Version - The minimum UI5 version (optional)
726
- * @param propertyName - The property name (optional)
727
- * @param customDefinition - Optional custom definition to apply decorators to (overrides getBase())
728
- * @returns Object containing the definition
722
+ * Applies all decorators to the schema in the correct order:
723
+ * description → isViewNode → validity → enums → message → hide → readonly.
724
+ * Message runs before hide so that hide can skip properties that already have messages.
725
+ *
726
+ * @param minUi5Version - The app's minimum UI5 version for validity checks
727
+ * @param propertyName - Optional property name when decorating a single property
728
+ * @param customDefinition - Override the schema definition (defaults to `getBase()`)
729
+ * @returns The decorated schema definition
729
730
  */
730
731
  applyDecorators(minUi5Version, propertyName, customDefinition) {
731
732
  const definition = customDefinition ?? this.getBase();