@sap/ux-specification 1.108.54 → 1.108.56
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +44 -1
- package/dist/documentation/runDocu-min.js +1 -1
- package/dist/documentation/runDocu-min.js.map +2 -2
- package/dist/documentation/v2/v2-AnalyticalListPage.html +2 -2
- package/dist/documentation/v2/v2-ApplicationV2.html +2 -2
- package/dist/documentation/v2/v2-ListReport.html +2 -2
- package/dist/documentation/v2/v2-ObjectPage.html +2 -2
- package/dist/documentation/v2/v2-OverviewPage.html +2 -2
- package/dist/documentation/v4/v4-ApplicationV4.html +2 -2
- package/dist/documentation/v4/v4-BuildingBlocks.html +2 -2
- package/dist/documentation/v4/v4-FreestylePage.html +2 -2
- package/dist/documentation/v4/v4-ListReport.html +2 -2
- package/dist/documentation/v4/v4-ObjectPage.html +2 -2
- package/dist/index-min.js +83 -83
- package/dist/index-min.js.map +4 -4
- package/dist/schemas/v2/ApplicationV2.json +2 -1
- package/dist/schemas/v4/ApplicationV4.json +6 -1
- package/dist/specification/package.json +6 -6
- package/dist/specification/scripts/documentation/components/TreeDiagram.d.ts +21 -0
- package/dist/specification/scripts/documentation/components/TreeDiagram.d.ts.map +1 -1
- package/dist/specification/scripts/documentation/components/TreeDiagram.js +21 -0
- package/dist/specification/scripts/documentation/components/TreeDiagram.js.map +1 -1
- package/dist/specification/scripts/documentation/components/filter.d.ts +7 -0
- package/dist/specification/scripts/documentation/components/filter.d.ts.map +1 -1
- package/dist/specification/scripts/documentation/components/filter.js +30 -0
- package/dist/specification/scripts/documentation/components/filter.js.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/TreeUI.d.ts +70 -0
- package/dist/specification/scripts/documentation/components/ui/TreeUI.d.ts.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/TreeUI.js +70 -3
- package/dist/specification/scripts/documentation/components/ui/TreeUI.js.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/keyboardNavigation.d.ts +17 -0
- package/dist/specification/scripts/documentation/components/ui/keyboardNavigation.d.ts.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/keyboardNavigation.js +23 -0
- package/dist/specification/scripts/documentation/components/ui/keyboardNavigation.js.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/search.d.ts +12 -0
- package/dist/specification/scripts/documentation/components/ui/search.d.ts.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/search.js +78 -8
- package/dist/specification/scripts/documentation/components/ui/search.js.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/toggle.d.ts +21 -0
- package/dist/specification/scripts/documentation/components/ui/toggle.d.ts.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/toggle.js +23 -6
- package/dist/specification/scripts/documentation/components/ui/toggle.js.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/tooltip.d.ts +24 -0
- package/dist/specification/scripts/documentation/components/ui/tooltip.d.ts.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/tooltip.js +24 -3
- package/dist/specification/scripts/documentation/components/ui/tooltip.js.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/utils.d.ts +36 -0
- package/dist/specification/scripts/documentation/components/ui/utils.d.ts.map +1 -1
- package/dist/specification/scripts/documentation/components/ui/utils.js +36 -4
- package/dist/specification/scripts/documentation/components/ui/utils.js.map +1 -1
- package/dist/specification/scripts/extractDocu.js +51 -7
- package/dist/specification/scripts/extractDocu.js.map +1 -1
- package/dist/specification/scripts/macros/api.d.ts +4 -1
- package/dist/specification/scripts/macros/api.d.ts.map +1 -1
- package/dist/specification/scripts/macros/api.js +9 -1
- package/dist/specification/scripts/macros/api.js.map +1 -1
- package/dist/specification/scripts/macros/cmd.d.ts +1 -0
- package/dist/specification/scripts/macros/cmd.d.ts.map +1 -1
- package/dist/specification/scripts/macros/cmd.js +1 -0
- package/dist/specification/scripts/macros/cmd.js.map +1 -1
- package/dist/specification/scripts/macros/corrections.d.ts +1 -0
- package/dist/specification/scripts/macros/corrections.d.ts.map +1 -1
- package/dist/specification/scripts/macros/corrections.js +5 -0
- package/dist/specification/scripts/macros/corrections.js.map +1 -1
- package/dist/specification/scripts/macros/i18n.d.ts +1 -0
- package/dist/specification/scripts/macros/i18n.d.ts.map +1 -1
- package/dist/specification/scripts/macros/i18n.js +1 -0
- package/dist/specification/scripts/macros/i18n.js.map +1 -1
- package/dist/specification/scripts/macros/schema.d.ts +1 -0
- package/dist/specification/scripts/macros/schema.d.ts.map +1 -1
- package/dist/specification/scripts/macros/schema.js +18 -5
- package/dist/specification/scripts/macros/schema.js.map +1 -1
- package/dist/specification/scripts/schema/to-json-schema.d.ts +9 -5
- package/dist/specification/scripts/schema/to-json-schema.d.ts.map +1 -1
- package/dist/specification/scripts/schema/to-json-schema.js +32 -5
- package/dist/specification/scripts/schema/to-json-schema.js.map +1 -1
- package/dist/specification/scripts/spec.js +19 -9
- package/dist/specification/scripts/spec.js.map +1 -1
- package/dist/specification/src/api.d.ts +20 -12
- package/dist/specification/src/api.d.ts.map +1 -1
- package/dist/specification/src/api.js +22 -14
- package/dist/specification/src/api.js.map +1 -1
- package/dist/specification/src/extensionLogger.d.ts +3 -2
- package/dist/specification/src/extensionLogger.d.ts.map +1 -1
- package/dist/specification/src/extensionLogger.js +3 -2
- package/dist/specification/src/extensionLogger.js.map +1 -1
- package/dist/specification/src/i18n/i18n.d.ts +5 -0
- package/dist/specification/src/i18n/i18n.d.ts.map +1 -1
- package/dist/specification/src/i18n/i18n.js +5 -0
- package/dist/specification/src/i18n/i18n.js.map +1 -1
- package/dist/specification/src/project.d.ts +3 -1
- package/dist/specification/src/project.d.ts.map +1 -1
- package/dist/specification/src/project.js +3 -1
- package/dist/specification/src/project.js.map +1 -1
- package/dist/specification/src/specification/schemaAccess.d.ts +6 -2
- package/dist/specification/src/specification/schemaAccess.d.ts.map +1 -1
- package/dist/specification/src/specification/schemaAccess.js +10 -4
- package/dist/specification/src/specification/schemaAccess.js.map +1 -1
- package/dist/specification/src/sync/common/appProvider.d.ts +17 -6
- package/dist/specification/src/sync/common/appProvider.d.ts.map +1 -1
- package/dist/specification/src/sync/common/appProvider.js +33 -17
- package/dist/specification/src/sync/common/appProvider.js.map +1 -1
- package/dist/specification/src/sync/common/decoration/control.d.ts +26 -10
- package/dist/specification/src/sync/common/decoration/control.d.ts.map +1 -1
- package/dist/specification/src/sync/common/decoration/control.js +32 -13
- package/dist/specification/src/sync/common/decoration/control.js.map +1 -1
- package/dist/specification/src/sync/common/decoration/decorators.d.ts +14 -0
- package/dist/specification/src/sync/common/decoration/decorators.d.ts.map +1 -1
- package/dist/specification/src/sync/common/decoration/decorators.js +14 -0
- package/dist/specification/src/sync/common/decoration/decorators.js.map +1 -1
- package/dist/specification/src/sync/common/decoration/factory.d.ts +12 -3
- package/dist/specification/src/sync/common/decoration/factory.d.ts.map +1 -1
- package/dist/specification/src/sync/common/decoration/factory.js +6 -3
- package/dist/specification/src/sync/common/decoration/factory.js.map +1 -1
- package/dist/specification/src/sync/common/decoration/flex.d.ts +7 -0
- package/dist/specification/src/sync/common/decoration/flex.d.ts.map +1 -1
- package/dist/specification/src/sync/common/decoration/flex.js +7 -0
- package/dist/specification/src/sync/common/decoration/flex.js.map +1 -1
- package/dist/specification/src/sync/common/distTagEvaluator.d.ts +6 -3
- package/dist/specification/src/sync/common/distTagEvaluator.d.ts.map +1 -1
- package/dist/specification/src/sync/common/distTagEvaluator.js +6 -3
- package/dist/specification/src/sync/common/distTagEvaluator.js.map +1 -1
- package/dist/specification/src/sync/common/flexUtils.d.ts +11 -10
- package/dist/specification/src/sync/common/flexUtils.d.ts.map +1 -1
- package/dist/specification/src/sync/common/flexUtils.js +11 -10
- package/dist/specification/src/sync/common/flexUtils.js.map +1 -1
- package/dist/specification/src/sync/common/generate/objectPage.d.ts +27 -18
- package/dist/specification/src/sync/common/generate/objectPage.d.ts.map +1 -1
- package/dist/specification/src/sync/common/generate/objectPage.js +54 -33
- package/dist/specification/src/sync/common/generate/objectPage.js.map +1 -1
- package/dist/specification/src/sync/common/generate/utils.d.ts +65 -37
- package/dist/specification/src/sync/common/generate/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/common/generate/utils.js +67 -37
- package/dist/specification/src/sync/common/generate/utils.js.map +1 -1
- package/dist/specification/src/sync/common/import/utils.d.ts +9 -3
- package/dist/specification/src/sync/common/import/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/common/import/utils.js +9 -3
- package/dist/specification/src/sync/common/import/utils.js.map +1 -1
- package/dist/specification/src/sync/common/importProject.d.ts +17 -6
- package/dist/specification/src/sync/common/importProject.d.ts.map +1 -1
- package/dist/specification/src/sync/common/importProject.js +60 -30
- package/dist/specification/src/sync/common/importProject.js.map +1 -1
- package/dist/specification/src/sync/common/utils.d.ts +129 -53
- package/dist/specification/src/sync/common/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/common/utils.js +239 -89
- package/dist/specification/src/sync/common/utils.js.map +1 -1
- package/dist/specification/src/sync/i18n.d.ts +5 -0
- package/dist/specification/src/sync/i18n.d.ts.map +1 -1
- package/dist/specification/src/sync/i18n.js +5 -0
- package/dist/specification/src/sync/i18n.js.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/Action.d.ts +3 -3
- package/dist/specification/src/sync/v2/export/controls/Action.js +15 -15
- package/dist/specification/src/sync/v2/export/controls/Card.d.ts +14 -0
- package/dist/specification/src/sync/v2/export/controls/Card.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/Card.js +20 -0
- package/dist/specification/src/sync/v2/export/controls/Card.js.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/Field.js +5 -5
- package/dist/specification/src/sync/v2/export/controls/FilterBar.d.ts +13 -0
- package/dist/specification/src/sync/v2/export/controls/FilterBar.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/FilterBar.js +21 -0
- package/dist/specification/src/sync/v2/export/controls/FilterBar.js.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/FormAction.js +4 -4
- package/dist/specification/src/sync/v2/export/controls/Fragment.d.ts +10 -5
- package/dist/specification/src/sync/v2/export/controls/Fragment.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/Fragment.js +62 -25
- package/dist/specification/src/sync/v2/export/controls/Fragment.js.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/ObjectPageFooterAction.js +6 -6
- package/dist/specification/src/sync/v2/export/controls/ObjectPageHeaderAction.js +6 -6
- package/dist/specification/src/sync/v2/export/controls/ObjectPageHeaderSection.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/ObjectPageHeaderSection.js +20 -16
- package/dist/specification/src/sync/v2/export/controls/ObjectPageHeaderSection.js.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/ObjectPageSection.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/ObjectPageSection.js.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/ObjectPageToolBarAction.js +6 -6
- package/dist/specification/src/sync/v2/export/controls/Table.d.ts +24 -0
- package/dist/specification/src/sync/v2/export/controls/Table.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/Table.js +48 -3
- package/dist/specification/src/sync/v2/export/controls/Table.js.map +1 -1
- package/dist/specification/src/sync/v2/export/controls/TableColumn.js +10 -10
- package/dist/specification/src/sync/v2/export/export.d.ts +7 -3
- package/dist/specification/src/sync/v2/export/export.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/export.js +133 -44
- package/dist/specification/src/sync/v2/export/export.js.map +1 -1
- package/dist/specification/src/sync/v2/export/exportPage.d.ts +18 -10
- package/dist/specification/src/sync/v2/export/exportPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/exportPage.js +34 -20
- package/dist/specification/src/sync/v2/export/exportPage.js.map +1 -1
- package/dist/specification/src/sync/v2/export/exportPageGeneric.d.ts +6 -3
- package/dist/specification/src/sync/v2/export/exportPageGeneric.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/exportPageGeneric.js +27 -17
- package/dist/specification/src/sync/v2/export/exportPageGeneric.js.map +1 -1
- package/dist/specification/src/sync/v2/export/manifest.d.ts +5 -2
- package/dist/specification/src/sync/v2/export/manifest.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/manifest.js +30 -6
- package/dist/specification/src/sync/v2/export/manifest.js.map +1 -1
- package/dist/specification/src/sync/v2/export/pages/OverviewPage.d.ts +21 -0
- package/dist/specification/src/sync/v2/export/pages/OverviewPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/pages/OverviewPage.js +36 -2
- package/dist/specification/src/sync/v2/export/pages/OverviewPage.js.map +1 -1
- package/dist/specification/src/sync/v2/export/view-controller-generator.d.ts +25 -15
- package/dist/specification/src/sync/v2/export/view-controller-generator.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/export/view-controller-generator.js +27 -16
- package/dist/specification/src/sync/v2/export/view-controller-generator.js.map +1 -1
- package/dist/specification/src/sync/v2/generate/analyticalListReport.d.ts +2 -0
- package/dist/specification/src/sync/v2/generate/analyticalListReport.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/generate/analyticalListReport.js +8 -1
- package/dist/specification/src/sync/v2/generate/analyticalListReport.js.map +1 -1
- package/dist/specification/src/sync/v2/generate/generate.d.ts +5 -9
- package/dist/specification/src/sync/v2/generate/generate.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/generate/generate.js +9 -12
- package/dist/specification/src/sync/v2/generate/generate.js.map +1 -1
- package/dist/specification/src/sync/v2/generate/listReport.d.ts +4 -2
- package/dist/specification/src/sync/v2/generate/listReport.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/generate/listReport.js +26 -8
- package/dist/specification/src/sync/v2/generate/listReport.js.map +1 -1
- package/dist/specification/src/sync/v2/generate/manifestPropertyUtils.d.ts +118 -0
- package/dist/specification/src/sync/v2/generate/manifestPropertyUtils.d.ts.map +1 -0
- package/dist/specification/src/sync/v2/generate/manifestPropertyUtils.js +151 -0
- package/dist/specification/src/sync/v2/generate/manifestPropertyUtils.js.map +1 -0
- package/dist/specification/src/sync/v2/generate/objectPage.d.ts +2 -2
- package/dist/specification/src/sync/v2/generate/objectPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/generate/objectPage.js +75 -43
- package/dist/specification/src/sync/v2/generate/objectPage.js.map +1 -1
- package/dist/specification/src/sync/v2/generate/overviewPage.d.ts +2 -2
- package/dist/specification/src/sync/v2/generate/overviewPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/generate/overviewPage.js +2 -2
- package/dist/specification/src/sync/v2/generate/overviewPage.js.map +1 -1
- package/dist/specification/src/sync/v2/generate/schemaAdaptation.d.ts +1 -1
- package/dist/specification/src/sync/v2/generate/schemaAdaptation.js +8 -8
- package/dist/specification/src/sync/v2/generate/schemaAdaptation.js.map +1 -1
- package/dist/specification/src/sync/v2/generate/utils.d.ts +47 -36
- package/dist/specification/src/sync/v2/generate/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/generate/utils.js +92 -71
- package/dist/specification/src/sync/v2/generate/utils.js.map +1 -1
- package/dist/specification/src/sync/v2/import/app/appProvider.d.ts +7 -0
- package/dist/specification/src/sync/v2/import/app/appProvider.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/app/appProvider.js +20 -4
- package/dist/specification/src/sync/v2/import/app/appProvider.js.map +1 -1
- package/dist/specification/src/sync/v2/import/app/ovpProvider.d.ts +4 -0
- package/dist/specification/src/sync/v2/import/app/ovpProvider.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/app/ovpProvider.js +4 -0
- package/dist/specification/src/sync/v2/import/app/ovpProvider.js.map +1 -1
- package/dist/specification/src/sync/v2/import/common/index.d.ts +28 -15
- package/dist/specification/src/sync/v2/import/common/index.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/common/index.js +91 -35
- package/dist/specification/src/sync/v2/import/common/index.js.map +1 -1
- package/dist/specification/src/sync/v2/import/controls/table.d.ts +6 -2
- package/dist/specification/src/sync/v2/import/controls/table.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/controls/table.js +6 -2
- package/dist/specification/src/sync/v2/import/controls/table.js.map +1 -1
- package/dist/specification/src/sync/v2/import/importPage.d.ts +3 -2
- package/dist/specification/src/sync/v2/import/importPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/importPage.js +4 -5
- package/dist/specification/src/sync/v2/import/importPage.js.map +1 -1
- package/dist/specification/src/sync/v2/import/pages/analyticalListPage.d.ts +3 -3
- package/dist/specification/src/sync/v2/import/pages/analyticalListPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/pages/analyticalListPage.js +9 -10
- package/dist/specification/src/sync/v2/import/pages/analyticalListPage.js.map +1 -1
- package/dist/specification/src/sync/v2/import/pages/listReport.d.ts +8 -7
- package/dist/specification/src/sync/v2/import/pages/listReport.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/pages/listReport.js +28 -24
- package/dist/specification/src/sync/v2/import/pages/listReport.js.map +1 -1
- package/dist/specification/src/sync/v2/import/pages/objectPage.d.ts +3 -3
- package/dist/specification/src/sync/v2/import/pages/objectPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/pages/objectPage.js +107 -76
- package/dist/specification/src/sync/v2/import/pages/objectPage.js.map +1 -1
- package/dist/specification/src/sync/v2/import/pages/overviewPage.d.ts +2 -1
- package/dist/specification/src/sync/v2/import/pages/overviewPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/pages/overviewPage.js +27 -12
- package/dist/specification/src/sync/v2/import/pages/overviewPage.js.map +1 -1
- package/dist/specification/src/sync/v2/import/utils.d.ts +18 -9
- package/dist/specification/src/sync/v2/import/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/import/utils.js +27 -15
- package/dist/specification/src/sync/v2/import/utils.js.map +1 -1
- package/dist/specification/src/sync/v2/utils.d.ts +26 -1
- package/dist/specification/src/sync/v2/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/v2/utils.js +47 -1
- package/dist/specification/src/sync/v2/utils.js.map +1 -1
- package/dist/specification/src/sync/v4/application.d.ts +7 -5
- package/dist/specification/src/sync/v4/application.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/application.js +7 -5
- package/dist/specification/src/sync/v4/application.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/FilterBar.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/FilterBar.js +8 -0
- package/dist/specification/src/sync/v4/export/controls/FilterBar.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ObjectPageFooter.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ObjectPageFooter.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ObjectPageTableColumn.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ObjectPageTableColumn.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/Table.d.ts +14 -9
- package/dist/specification/src/sync/v4/export/controls/Table.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/Table.js +44 -17
- package/dist/specification/src/sync/v4/export/controls/Table.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/TableColumn.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/TableColumn.js.map +1 -1
- package/dist/specification/src/sync/v4/export/export.d.ts +6 -4
- package/dist/specification/src/sync/v4/export/export.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/export.js +136 -58
- package/dist/specification/src/sync/v4/export/export.js.map +1 -1
- package/dist/specification/src/sync/v4/export/exportCustomColumn.d.ts +6 -4
- package/dist/specification/src/sync/v4/export/exportCustomColumn.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/exportCustomColumn.js +6 -4
- package/dist/specification/src/sync/v4/export/exportCustomColumn.js.map +1 -1
- package/dist/specification/src/sync/v4/export/flexibleColumnLayout.d.ts +3 -2
- package/dist/specification/src/sync/v4/export/flexibleColumnLayout.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/flexibleColumnLayout.js +13 -9
- package/dist/specification/src/sync/v4/export/flexibleColumnLayout.js.map +1 -1
- package/dist/specification/src/sync/v4/export/fpmCustomPage.d.ts +6 -4
- package/dist/specification/src/sync/v4/export/fpmCustomPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/fpmCustomPage.js +9 -4
- package/dist/specification/src/sync/v4/export/fpmCustomPage.js.map +1 -1
- package/dist/specification/src/sync/v4/export/manifest.d.ts +6 -2
- package/dist/specification/src/sync/v4/export/manifest.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/manifest.js +46 -17
- package/dist/specification/src/sync/v4/export/manifest.js.map +1 -1
- package/dist/specification/src/sync/v4/export/pages/ListReport.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/pages/ListReport.js +4 -3
- package/dist/specification/src/sync/v4/export/pages/ListReport.js.map +1 -1
- package/dist/specification/src/sync/v4/export/utils.d.ts +6 -4
- package/dist/specification/src/sync/v4/export/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/utils.js +6 -4
- package/dist/specification/src/sync/v4/export/utils.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/annotations.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/annotations.js +4 -0
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/annotations.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/extensions.d.ts +5 -3
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/extensions.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/extensions.js +14 -5
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/extensions.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/generator.d.ts +1 -0
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/generator.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/generator.js +18 -0
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/generator.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/pageExtensions.d.ts +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/pageExtensions.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/pageExtensions.js +2 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/pageExtensions.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/utils.d.ts +2 -0
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/utils.js +2 -0
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/utils.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/freestylePage.d.ts +2 -2
- package/dist/specification/src/sync/v4/generate/freestylePage.js +2 -2
- package/dist/specification/src/sync/v4/generate/generate.d.ts +13 -11
- package/dist/specification/src/sync/v4/generate/generate.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/generate.js +13 -11
- package/dist/specification/src/sync/v4/generate/generate.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/listReport.d.ts +10 -7
- package/dist/specification/src/sync/v4/generate/listReport.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/listReport.js +124 -78
- package/dist/specification/src/sync/v4/generate/listReport.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/objectPage.d.ts +1 -1
- package/dist/specification/src/sync/v4/generate/objectPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/objectPage.js +206 -154
- package/dist/specification/src/sync/v4/generate/objectPage.js.map +1 -1
- package/dist/specification/src/sync/v4/import/app/appProvider.d.ts +18 -4
- package/dist/specification/src/sync/v4/import/app/appProvider.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/import/app/appProvider.js +56 -24
- package/dist/specification/src/sync/v4/import/app/appProvider.js.map +1 -1
- package/dist/specification/src/sync/v4/import/fragment.d.ts +29 -4
- package/dist/specification/src/sync/v4/import/fragment.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/import/fragment.js +46 -7
- package/dist/specification/src/sync/v4/import/fragment.js.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/fpmCustomPage.d.ts +3 -2
- package/dist/specification/src/sync/v4/import/pages/fpmCustomPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/fpmCustomPage.js +7 -2
- package/dist/specification/src/sync/v4/import/pages/fpmCustomPage.js.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/listReport.d.ts +12 -10
- package/dist/specification/src/sync/v4/import/pages/listReport.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/listReport.js +70 -46
- package/dist/specification/src/sync/v4/import/pages/listReport.js.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/objectPage.d.ts +7 -6
- package/dist/specification/src/sync/v4/import/pages/objectPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/objectPage.js +49 -36
- package/dist/specification/src/sync/v4/import/pages/objectPage.js.map +1 -1
- package/dist/specification/src/sync/v4/import/utils.d.ts +4 -2
- package/dist/specification/src/sync/v4/import/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/import/utils.js +4 -2
- package/dist/specification/src/sync/v4/import/utils.js.map +1 -1
- package/dist/specification/src/sync/v4/sync-rules/controllerExtensions.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/sync-rules/controllerExtensions.js +5 -2
- package/dist/specification/src/sync/v4/sync-rules/controllerExtensions.js.map +1 -1
- package/dist/specification/src/sync/v4/utils/StableIdHelper.d.ts +12 -0
- package/dist/specification/src/sync/v4/utils/StableIdHelper.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/utils/StableIdHelper.js +18 -0
- package/dist/specification/src/sync/v4/utils/StableIdHelper.js.map +1 -1
- package/dist/specification/src/sync/v4/utils/macros.d.ts +4 -0
- package/dist/specification/src/sync/v4/utils/macros.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/utils/macros.js +17 -1
- package/dist/specification/src/sync/v4/utils/macros.js.map +1 -1
- package/dist/specification/src/sync/v4/utils/utils.d.ts +38 -20
- package/dist/specification/src/sync/v4/utils/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/utils/utils.js +99 -52
- package/dist/specification/src/sync/v4/utils/utils.js.map +1 -1
- package/dist/types/src/apiTypes.d.ts +13 -0
- package/dist/types/src/apiTypes.d.ts.map +1 -1
- package/dist/types/src/apiTypes.js +18 -1
- package/dist/types/src/apiTypes.js.map +1 -1
- package/dist/types/src/common/Application.d.ts +6 -0
- package/dist/types/src/common/Application.d.ts.map +1 -1
- package/dist/types/src/common/Application.js +4 -0
- package/dist/types/src/common/Application.js.map +1 -1
- package/dist/types/src/common/types.d.ts +51 -2
- package/dist/types/src/common/types.d.ts.map +1 -1
- package/dist/types/src/common/types.js +2 -1
- package/dist/types/src/common/types.js.map +1 -1
- package/dist/types/src/common/webapp/manifest/sapUi5.d.ts +3 -2
- package/dist/types/src/common/webapp/manifest/sapUi5.d.ts.map +1 -1
- package/dist/types/src/common/webapp/manifest/sapUi5.js +3 -2
- package/dist/types/src/common/webapp/manifest/sapUi5.js.map +1 -1
- package/dist/types/src/v2/application.d.ts +1 -1
- package/dist/types/src/v2/controls/Action.d.ts +12 -0
- package/dist/types/src/v2/controls/Action.d.ts.map +1 -1
- package/dist/types/src/v2/controls/AnalyticalListPageChart.d.ts +1 -0
- package/dist/types/src/v2/controls/AnalyticalListPageChart.d.ts.map +1 -1
- package/dist/types/src/v2/controls/AnalyticalListPageKPI.d.ts +1 -0
- package/dist/types/src/v2/controls/AnalyticalListPageKPI.d.ts.map +1 -1
- package/dist/types/src/v2/controls/Card.d.ts +13 -0
- package/dist/types/src/v2/controls/Card.d.ts.map +1 -1
- package/dist/types/src/v2/controls/Card.js.map +1 -1
- package/dist/types/src/v2/controls/Field.d.ts +1 -0
- package/dist/types/src/v2/controls/Field.d.ts.map +1 -1
- package/dist/types/src/v2/controls/FilterBar.d.ts +6 -0
- package/dist/types/src/v2/controls/FilterBar.d.ts.map +1 -1
- package/dist/types/src/v2/controls/FilterBar.js.map +1 -1
- package/dist/types/src/v2/controls/Header.d.ts +1 -0
- package/dist/types/src/v2/controls/Header.d.ts.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageChart.d.ts +1 -0
- package/dist/types/src/v2/controls/ObjectPageChart.d.ts.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageFooter.d.ts +2 -0
- package/dist/types/src/v2/controls/ObjectPageFooter.d.ts.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageForm.d.ts +1 -0
- package/dist/types/src/v2/controls/ObjectPageForm.d.ts.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageHeader.d.ts +1 -0
- package/dist/types/src/v2/controls/ObjectPageHeader.d.ts.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageHeaderSection.d.ts +3 -0
- package/dist/types/src/v2/controls/ObjectPageHeaderSection.d.ts.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageLayout.d.ts +1 -0
- package/dist/types/src/v2/controls/ObjectPageLayout.d.ts.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageSection.d.ts +13 -0
- package/dist/types/src/v2/controls/ObjectPageSection.d.ts.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageSection.js.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageTable.d.ts +6 -0
- package/dist/types/src/v2/controls/ObjectPageTable.d.ts.map +1 -1
- package/dist/types/src/v2/controls/ObjectPageToolBar.d.ts +2 -0
- package/dist/types/src/v2/controls/ObjectPageToolBar.d.ts.map +1 -1
- package/dist/types/src/v2/controls/Table.d.ts +28 -0
- package/dist/types/src/v2/controls/Table.d.ts.map +1 -1
- package/dist/types/src/v2/controls/Table.js.map +1 -1
- package/dist/types/src/v2/controls/ToolBar.d.ts +1 -0
- package/dist/types/src/v2/controls/ToolBar.d.ts.map +1 -1
- package/dist/types/src/v2/pages/AnalyticalListPageConfigV2.d.ts +1 -0
- package/dist/types/src/v2/pages/AnalyticalListPageConfigV2.d.ts.map +1 -1
- package/dist/types/src/v2/pages/OverviewPageConfigV2.d.ts +4 -0
- package/dist/types/src/v2/pages/OverviewPageConfigV2.d.ts.map +1 -1
- package/dist/types/src/v4/application.d.ts +1 -1
- package/dist/types/src/v4/controls/CustomAction.d.ts +10 -0
- package/dist/types/src/v4/controls/CustomAction.d.ts.map +1 -1
- package/dist/types/src/v4/controls/FilterBar.d.ts +11 -0
- package/dist/types/src/v4/controls/FilterBar.d.ts.map +1 -1
- package/dist/types/src/v4/controls/FilterBar.js.map +1 -1
- package/dist/types/src/v4/controls/Header.d.ts +1 -0
- package/dist/types/src/v4/controls/Header.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageFooter.d.ts +1 -0
- package/dist/types/src/v4/controls/ObjectPageFooter.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageForm.d.ts +1 -0
- package/dist/types/src/v4/controls/ObjectPageForm.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageHeader.d.ts +2 -0
- package/dist/types/src/v4/controls/ObjectPageHeader.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageHeaderSection.d.ts +6 -0
- package/dist/types/src/v4/controls/ObjectPageHeaderSection.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageLayout.d.ts +1 -0
- package/dist/types/src/v4/controls/ObjectPageLayout.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageSection.d.ts +17 -0
- package/dist/types/src/v4/controls/ObjectPageSection.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageSection.js.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageTable.d.ts +5 -0
- package/dist/types/src/v4/controls/ObjectPageTable.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageTable.js.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageToolBar.d.ts +4 -0
- package/dist/types/src/v4/controls/ObjectPageToolBar.d.ts.map +1 -1
- package/dist/types/src/v4/controls/Table.d.ts +15 -0
- package/dist/types/src/v4/controls/Table.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ToolBar.d.ts +9 -0
- package/dist/types/src/v4/controls/ToolBar.d.ts.map +1 -1
- package/dist/types/src/v4/page.d.ts +4 -0
- package/dist/types/src/v4/page.d.ts.map +1 -1
- package/dist/types/src/v4/webapp/manifest/ManifestSettings.d.ts +22 -0
- package/dist/types/src/v4/webapp/manifest/ManifestSettings.d.ts.map +1 -1
- package/dist/types/src/v4/webapp/manifest/sapUi5.d.ts +3 -0
- package/dist/types/src/v4/webapp/manifest/sapUi5.d.ts.map +1 -1
- package/dist/types/src/v4/webapp/manifest/sapUi5.js.map +1 -1
- package/dist/types/src/v4/webapp/manifest/sapUiPageV4.d.ts +1 -1
- package/dist/types/src/v4/webapp/manifest/sapUiPageV4.d.ts.map +1 -1
- package/dist/types/src/v4/webapp/manifest/sapUiPageV4.js +2 -2
- package/dist/types/src/v4/webapp/manifest/sapUiPageV4.js.map +1 -1
- package/package.json +7 -7
|
@@ -46,6 +46,7 @@ exports.getJSONPropertyByPath = getJSONPropertyByPath;
|
|
|
46
46
|
exports.removeNamespaces = removeNamespaces;
|
|
47
47
|
exports.replaceNamespaces = replaceNamespaces;
|
|
48
48
|
exports.getRefType = getRefType;
|
|
49
|
+
exports.compareTemplateNames = compareTemplateNames;
|
|
49
50
|
const ux_specification_types_1 = require("@sap/ux-specification-types");
|
|
50
51
|
const i18next_1 = __importDefault(require("i18next"));
|
|
51
52
|
const deepmerge_1 = __importDefault(require("deepmerge"));
|
|
@@ -64,6 +65,7 @@ const arrayIncludes = (arr, target) => target.every((v) => arr.includes(v));
|
|
|
64
65
|
exports.arrayIncludes = arrayIncludes;
|
|
65
66
|
/**
|
|
66
67
|
* Function returns annotation path for schema based on received params.
|
|
68
|
+
*
|
|
67
69
|
* @param entityTypeName - Entity type name.
|
|
68
70
|
* @param term - Annotation term.
|
|
69
71
|
* @param qualifier - Annotation qualifier.
|
|
@@ -81,8 +83,10 @@ const createAnnotationPath = (entityTypeName, term, qualifier) => {
|
|
|
81
83
|
};
|
|
82
84
|
exports.createAnnotationPath = createAnnotationPath;
|
|
83
85
|
/**
|
|
84
|
-
* Parses, merges, and converts a list of annotation files with aid of tools from annotation-vocabularies-tools
|
|
86
|
+
* Parses, merges, and converts a list of annotation files with aid of tools from annotation-vocabularies-tools.
|
|
87
|
+
*
|
|
85
88
|
* @param annotationFiles - The list of all annotation files, in JSON format
|
|
89
|
+
* @param logger - Logger instance used for logging errors or messages during processing
|
|
86
90
|
* @returns the complete service information
|
|
87
91
|
*/
|
|
88
92
|
function parseAndMergeAndConvert(annotationFiles, logger) {
|
|
@@ -112,10 +116,12 @@ function parseAndMergeAndConvert(annotationFiles, logger) {
|
|
|
112
116
|
const getAnnotationPropertyValue = (annotationProperty) => annotationProperty?.value || annotationProperty?.path;
|
|
113
117
|
exports.getAnnotationPropertyValue = getAnnotationPropertyValue;
|
|
114
118
|
/**
|
|
115
|
-
* Checks for Common.Label and overwrites the label from it if present
|
|
119
|
+
* Checks for Common.Label and overwrites the label from it if present.
|
|
120
|
+
*
|
|
116
121
|
* @param {PropertyAnnotations} annotations - property annotations
|
|
117
122
|
* @param {EntityType} entityType - entity type
|
|
118
123
|
* @param {string} label - label, to be actualized
|
|
124
|
+
* @returns label, derived from Common.Label or from property value
|
|
119
125
|
*/
|
|
120
126
|
function evaluateCommonLabel(annotations, entityType, label) {
|
|
121
127
|
if (annotations?.Common?.Label) {
|
|
@@ -138,7 +144,8 @@ function evaluateCommonLabel(annotations, entityType, label) {
|
|
|
138
144
|
return label;
|
|
139
145
|
}
|
|
140
146
|
/**
|
|
141
|
-
* Determines the label for a property path
|
|
147
|
+
* Determines the label for a property path.
|
|
148
|
+
*
|
|
142
149
|
* @param {PropertyPath} propertyPath - property path
|
|
143
150
|
* @param {EntityType} entityType - entity type
|
|
144
151
|
* @returns label, derived from Common.Label or from property value
|
|
@@ -151,9 +158,10 @@ function getLabelForPropertyPath(propertyPath, entityType) {
|
|
|
151
158
|
return label;
|
|
152
159
|
}
|
|
153
160
|
/**
|
|
154
|
-
* Determines the label for a LineItem record
|
|
155
|
-
*
|
|
156
|
-
* @param
|
|
161
|
+
* Determines the label for a LineItem record.
|
|
162
|
+
*
|
|
163
|
+
* @param field - Line item record
|
|
164
|
+
* @param entityType - entity type
|
|
157
165
|
* @returns label, derived from Common.Label or from property value
|
|
158
166
|
*/
|
|
159
167
|
function getLabelForDataField(field, entityType) {
|
|
@@ -183,7 +191,8 @@ function getLabelForDataField(field, entityType) {
|
|
|
183
191
|
return label;
|
|
184
192
|
}
|
|
185
193
|
/**
|
|
186
|
-
* Function to resolve the dataField label
|
|
194
|
+
* Function to resolve the dataField label.
|
|
195
|
+
*
|
|
187
196
|
* @param dataFieldLabel - Given dataField label; might be of type string, or an object in case of a path reference
|
|
188
197
|
* @param entityType - the entity type as part of the AVT ConvertedMetadata
|
|
189
198
|
* @returns undefined or the right string value
|
|
@@ -209,6 +218,14 @@ function getLabel(dataFieldLabel, entityType) {
|
|
|
209
218
|
return undefined;
|
|
210
219
|
}
|
|
211
220
|
}
|
|
221
|
+
/**
|
|
222
|
+
* Retrieves the title for a given data field.
|
|
223
|
+
*
|
|
224
|
+
* @param dataField - The data field object containing metadata.
|
|
225
|
+
* @param entityType - The entity type as part of the AVT ConvertedMetadata.
|
|
226
|
+
* @param dataFieldLabel - The label associated with the data field.
|
|
227
|
+
* @returns The title for the data field as a string.
|
|
228
|
+
*/
|
|
212
229
|
function getTitleForDataField(dataField, entityType, dataFieldLabel) {
|
|
213
230
|
const propertyCommonLabel = getLabelForDataField(dataField, entityType);
|
|
214
231
|
return (dataFieldLabel ||
|
|
@@ -216,9 +233,11 @@ function getTitleForDataField(dataField, entityType, dataFieldLabel) {
|
|
|
216
233
|
(dataField.Value.$target ? dataField.Value.$target.name : dataField.Value.value || dataField.Value.path));
|
|
217
234
|
}
|
|
218
235
|
/**
|
|
219
|
-
* Determines the description of a data field, e.g. for the column header
|
|
236
|
+
* Determines the description of a data field, e.g. for the column header.
|
|
237
|
+
*
|
|
220
238
|
* @param dataFieldAbstract - the given record of the line item annotation
|
|
221
239
|
* @param entityType - the entity type as part of the AVT ConvertedMetadata
|
|
240
|
+
* @returns the description of the data field
|
|
222
241
|
*/
|
|
223
242
|
function getDataFieldDescription(dataFieldAbstract, entityType) {
|
|
224
243
|
let title = '', propertyCommonLabel, dataField, actionName = '';
|
|
@@ -276,17 +295,21 @@ function getDataFieldDescription(dataFieldAbstract, entityType) {
|
|
|
276
295
|
}
|
|
277
296
|
}
|
|
278
297
|
/**
|
|
279
|
-
* Prepare string for reference use in schema
|
|
298
|
+
* Prepare string for reference use in schema.
|
|
299
|
+
*
|
|
280
300
|
* @param refInput string to be character checked and replaced
|
|
281
301
|
* @returns string with replaced characters
|
|
282
302
|
*/
|
|
283
303
|
//@typescript-eslint/no-wrapper-object-types turned off tor prevent conversion String > string; String is used by AVT
|
|
304
|
+
// eslint-disable-next-line @typescript-eslint/no-wrapper-object-types
|
|
284
305
|
function prepareRef(refInput) {
|
|
285
306
|
return refInput.replace('#', '::').replace(/\//g, ':2f');
|
|
286
307
|
}
|
|
287
308
|
/**
|
|
288
|
-
* Return the page type for a given V2 page in manifest
|
|
309
|
+
* Return the page type for a given V2 page in manifest.
|
|
310
|
+
*
|
|
289
311
|
* @param name - page component name
|
|
312
|
+
* @returns page type
|
|
290
313
|
*/
|
|
291
314
|
function getPageTypeV2(name) {
|
|
292
315
|
if (name) {
|
|
@@ -295,28 +318,34 @@ function getPageTypeV2(name) {
|
|
|
295
318
|
}
|
|
296
319
|
}
|
|
297
320
|
/**
|
|
298
|
-
* Return the page type for a given V4 page in manifest
|
|
299
|
-
*
|
|
321
|
+
* Return the page type for a given V4 page in manifest.
|
|
322
|
+
*
|
|
323
|
+
* @param v4Page - The V4 application page or routing target configuration
|
|
324
|
+
* @returns page type
|
|
300
325
|
*/
|
|
301
|
-
function getPageTypeV4(
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
return
|
|
326
|
+
function getPageTypeV4(v4Page) {
|
|
327
|
+
const pageType = 'name' in v4Page && typeof v4Page.name === 'string' ? convertTemplateNameToPageTypeV4(v4Page.name) : undefined;
|
|
328
|
+
if (pageType) {
|
|
329
|
+
return pageType;
|
|
305
330
|
}
|
|
306
|
-
|
|
307
|
-
return ux_specification_types_1.PageTypeV4.FPMCustomPage;
|
|
308
|
-
}
|
|
309
|
-
else if (v4App.viewId ||
|
|
310
|
-
v4App.viewName) {
|
|
331
|
+
if (('viewId' in v4Page && v4Page.viewId) || ('viewName' in v4Page && v4Page.viewName)) {
|
|
311
332
|
return ux_specification_types_1.PageTypeV4.CustomPage;
|
|
312
333
|
}
|
|
313
334
|
}
|
|
335
|
+
/**
|
|
336
|
+
* Retrieves the name of the target annotation based on the provided annotation object and a flag.
|
|
337
|
+
*
|
|
338
|
+
* @param targetAnnotation - The annotation object containing term and qualifier information.
|
|
339
|
+
* @param keyForRelatedFacetKeys - A flag indicating whether to construct the key for related facet keys without the '@' symbol.
|
|
340
|
+
* @returns The name of the target annotation as a string.
|
|
341
|
+
*/
|
|
314
342
|
function getTargetAnnotationName(targetAnnotation, keyForRelatedFacetKeys = false) {
|
|
315
343
|
const termWithQualifier = `${targetAnnotation.term}#${targetAnnotation.qualifier}`;
|
|
316
344
|
return `${!keyForRelatedFacetKeys ? '@' : ''}${targetAnnotation.qualifier ? termWithQualifier : targetAnnotation.term}`;
|
|
317
345
|
}
|
|
318
346
|
/**
|
|
319
|
-
* Finds the alias for a given namespace in the references' section of the converted service metadata
|
|
347
|
+
* Finds the alias for a given namespace in the references' section of the converted service metadata.
|
|
348
|
+
*
|
|
320
349
|
* @param {string} namespace - complete namespace, e.g. 'com.sap.vocabularies.UI.v1'
|
|
321
350
|
* @param {ConvertedMetadata} oDataServiceAVT - combined service metadata, as returned by annotation vocabularies tools
|
|
322
351
|
* @returns alias for the given namespace
|
|
@@ -343,6 +372,7 @@ function findAlias(namespace, oDataServiceAVT) {
|
|
|
343
372
|
}
|
|
344
373
|
/**
|
|
345
374
|
* Method returns annotation from passed meta path.
|
|
375
|
+
*
|
|
346
376
|
* @param metaPath - annotation meta path
|
|
347
377
|
* @returns annotation name
|
|
348
378
|
*/
|
|
@@ -350,7 +380,8 @@ function getAnnotationFromMetaPath(metaPath) {
|
|
|
350
380
|
return metaPath.substring(metaPath.lastIndexOf('.') + 1, metaPath.length);
|
|
351
381
|
}
|
|
352
382
|
/**
|
|
353
|
-
* Determines the target annotation
|
|
383
|
+
* Determines the target annotation.
|
|
384
|
+
*
|
|
354
385
|
* @param navigationParts - parts of the target annotation path
|
|
355
386
|
* @param entityType - entity type
|
|
356
387
|
* @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
|
|
@@ -363,10 +394,12 @@ function determineTargetAnnotation(navigationParts, entityType, oDataServiceAVT)
|
|
|
363
394
|
return entityType?.annotations?.[alias]?.[annotation];
|
|
364
395
|
}
|
|
365
396
|
/**
|
|
366
|
-
* Adjust key by considering navigation
|
|
397
|
+
* Adjust key by considering navigation.
|
|
398
|
+
*
|
|
367
399
|
* @param key - given key
|
|
368
|
-
* @param keyForRelatedFacetKeys - construct key for 'keyForRelatedFacetKeys' property(used to define custom sections) - we should not add '@' symbol there.
|
|
369
400
|
* @param navigationParts - parts of the target annotation path
|
|
401
|
+
* @param keyForRelatedFacetKeys - construct key for 'keyForRelatedFacetKeys' property(used to define custom sections) - we should not add '@' symbol there.
|
|
402
|
+
* @returns adjusted key
|
|
370
403
|
*/
|
|
371
404
|
function adjustKey(key, navigationParts, keyForRelatedFacetKeys) {
|
|
372
405
|
const uiClass = navigationParts[navigationParts.length - 1].split('#')[0];
|
|
@@ -380,6 +413,17 @@ function adjustKey(key, navigationParts, keyForRelatedFacetKeys) {
|
|
|
380
413
|
}
|
|
381
414
|
return key;
|
|
382
415
|
}
|
|
416
|
+
/**
|
|
417
|
+
* Resolves the key and entity type of a reference facet, adjusting the key based on navigation and annotations.
|
|
418
|
+
*
|
|
419
|
+
* @param oDataServiceAVT - The converted metadata of the OData service.
|
|
420
|
+
* @param key - The initial key for the facet.
|
|
421
|
+
* @param entityType - The entity type associated with the facet.
|
|
422
|
+
* @param propertyValue - The property value of the facet's target.
|
|
423
|
+
* @param oDataVersion - The version of OData (v2 or v4).
|
|
424
|
+
* @param keyForRelatedFacetKeys - A flag indicating whether to construct the key for related facet keys without the '@' symbol.
|
|
425
|
+
* @returns An object containing the adjusted key, entity type, a flag to stop processing, and the namespace.
|
|
426
|
+
*/
|
|
383
427
|
function getKeyAndEntityTypeOfReferenceFacet(oDataServiceAVT, key, entityType, propertyValue, oDataVersion = ux_specification_types_1.FioriElementsVersion.v2, keyForRelatedFacetKeys = false) {
|
|
384
428
|
let stopProcessing = false;
|
|
385
429
|
let namespace;
|
|
@@ -409,12 +453,14 @@ function getKeyAndEntityTypeOfReferenceFacet(oDataServiceAVT, key, entityType, p
|
|
|
409
453
|
}
|
|
410
454
|
/**
|
|
411
455
|
* Resolve page section(get key and label->description).
|
|
456
|
+
*
|
|
412
457
|
* @param facetDefinition - the actual annotation record
|
|
458
|
+
* @param sourceEntityType - The source entity type to be used for resolving facets
|
|
459
|
+
* @param oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
|
|
460
|
+
* @param logger - Logger class for logging messages
|
|
461
|
+
* @param oDataVersion - OData version
|
|
413
462
|
* @param keyForRelatedFacetKeys - construct key for 'keyForRelatedFacetKeys' property(used to define custom sections) - we should not add '@' symbol there.
|
|
414
|
-
* @
|
|
415
|
-
* @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
|
|
416
|
-
* @param {ExtensionLogger} logger - Logger class for logging messages
|
|
417
|
-
* @returns {FacetSection} - object comprising the relevant facet information
|
|
463
|
+
* @returns - object comprising the relevant facet information
|
|
418
464
|
*/
|
|
419
465
|
function getSectionFacet(facetDefinition, sourceEntityType, oDataServiceAVT, logger, oDataVersion = ux_specification_types_1.FioriElementsVersion.v2, keyForRelatedFacetKeys = false) {
|
|
420
466
|
//Take facet ID as fallback
|
|
@@ -455,7 +501,8 @@ function getSectionFacet(facetDefinition, sourceEntityType, oDataServiceAVT, log
|
|
|
455
501
|
}
|
|
456
502
|
}
|
|
457
503
|
/**
|
|
458
|
-
* Decodes encoded path element and returns it in form as used in manifest settings
|
|
504
|
+
* Decodes encoded path element and returns it in form as used in manifest settings.
|
|
505
|
+
*
|
|
459
506
|
* @param {string} pathElement - path of the property in the manifest
|
|
460
507
|
* @param {string} targetAnnotation - target annotation (optional)
|
|
461
508
|
* @param {string} targetAnnotationEncoded - target annotation in its encoded form, as used in manifest settings (optional)
|
|
@@ -474,6 +521,7 @@ function getDecodedPathElement(pathElement, targetAnnotation, targetAnnotationEn
|
|
|
474
521
|
/**
|
|
475
522
|
* Method prepares value as empty object or array based on passed path.
|
|
476
523
|
* For array path should end with '[]'.
|
|
524
|
+
*
|
|
477
525
|
* @param {string} path - path of the property in the manifest
|
|
478
526
|
* @returns prepared value based on passed path
|
|
479
527
|
*/
|
|
@@ -488,12 +536,13 @@ exports.prepareValueForPath = prepareValueForPath;
|
|
|
488
536
|
* Method find object by given path in format "sap.ui5/extends/extensions".
|
|
489
537
|
* An empty object is created if the path element does not exist yet.
|
|
490
538
|
* Exception: if an empty array is the next element of the 'path' definition, an empty array is created instead of an empty object.
|
|
539
|
+
*
|
|
491
540
|
* @param {object} manifest - manifest that is being modified during export
|
|
492
541
|
* @param {string} path - path of the property in the manifest
|
|
493
542
|
* @param {string} targetAnnotation - target annotation (optional)
|
|
494
543
|
* @param {string} targetAnnotationEncoded - target annotation in its encoded form, as used in manifest settings
|
|
495
544
|
* @param {boolean} value - specific value to apply for unexisting property for given path
|
|
496
|
-
* @param {boolean} [readOnly
|
|
545
|
+
* @param {boolean} [readOnly] - indicates if the function should create object/array if existing value not found by given path
|
|
497
546
|
* @returns returns section of the manifest based on path
|
|
498
547
|
*/
|
|
499
548
|
const resolveManifestPath = (manifest, path, targetAnnotation, targetAnnotationEncoded, value, readOnly = false) => {
|
|
@@ -531,11 +580,12 @@ const resolveManifestPath = (manifest, path, targetAnnotation, targetAnnotationE
|
|
|
531
580
|
* Finds the alias for a given namespace in the references' section of the converted service metadata.
|
|
532
581
|
* An empty object is created if the path element does not exist yet.
|
|
533
582
|
* Exception: if an empty array is the next element of the 'path' definition, an empty array is created instead of an empty object.
|
|
583
|
+
*
|
|
534
584
|
* @param {object} manifest - manifest that is being modified during export
|
|
535
585
|
* @param {string} path - path of the property in the manifest
|
|
536
586
|
* @param {string} targetAnnotation - target annotation (optional)
|
|
537
587
|
* @param {string} targetAnnotationEncoded - target annotation in its encoded form, as used in manifest settings
|
|
538
|
-
* @param {boolean} [readOnly
|
|
588
|
+
* @param {boolean} [readOnly] - indicates if the function should create object/array if existing value not found by given path
|
|
539
589
|
* @returns returns section of the manifest based on path, generates an empty object in case it does not exists
|
|
540
590
|
*/
|
|
541
591
|
const getManifestSectionByPathV4 = (manifest, path, targetAnnotation, targetAnnotationEncoded, readOnly = false) => {
|
|
@@ -544,6 +594,7 @@ const getManifestSectionByPathV4 = (manifest, path, targetAnnotation, targetAnno
|
|
|
544
594
|
exports.getManifestSectionByPathV4 = getManifestSectionByPathV4;
|
|
545
595
|
/**
|
|
546
596
|
* Method sets value for passed path in manifest.
|
|
597
|
+
*
|
|
547
598
|
* @param {object} manifest - manifest that is being modified during export
|
|
548
599
|
* @param {string} path - path of the property in the manifest
|
|
549
600
|
* @param {unknown} value - value to apply
|
|
@@ -554,6 +605,12 @@ const setManifestSectionByPathV4 = (manifest, path, value, targetAnnotation, tar
|
|
|
554
605
|
resolveManifestPath(manifest, path, targetAnnotation, targetAnnotationEncoded, value);
|
|
555
606
|
};
|
|
556
607
|
exports.setManifestSectionByPathV4 = setManifestSectionByPathV4;
|
|
608
|
+
/**
|
|
609
|
+
* Retrieves the schema key for a given line item record based on its type and properties.
|
|
610
|
+
*
|
|
611
|
+
* @param lineItemRecord - The line item record to process.
|
|
612
|
+
* @returns The schema key as a string, or undefined if no key is determined.
|
|
613
|
+
*/
|
|
557
614
|
function getSchemaKeyOfLineItemRecord(lineItemRecord) {
|
|
558
615
|
let schemaKey, target, value;
|
|
559
616
|
switch (lineItemRecord.$Type) {
|
|
@@ -602,7 +659,8 @@ function getSchemaKeyOfLineItemRecord(lineItemRecord) {
|
|
|
602
659
|
return schemaKey;
|
|
603
660
|
}
|
|
604
661
|
/**
|
|
605
|
-
* Determines if type of given annotation term is of UIAnnotationTerm
|
|
662
|
+
* Determines if type of given annotation term is of UIAnnotationTerm.
|
|
663
|
+
*
|
|
606
664
|
* @param {string} path path in manifest
|
|
607
665
|
* @param {string} alias for a given namespace
|
|
608
666
|
* @param {EntityType} entityType - the entity type
|
|
@@ -632,10 +690,10 @@ function getUIAnnotationTerm(path, alias, entityType) {
|
|
|
632
690
|
}
|
|
633
691
|
}
|
|
634
692
|
/**
|
|
635
|
-
* Determines if type of given annotation term is of CommunicationAnnotationTerm
|
|
693
|
+
* Determines if type of given annotation term is of CommunicationAnnotationTerm.
|
|
694
|
+
*
|
|
636
695
|
* @param {string} path path in manifest
|
|
637
696
|
* @param {string} alias for a given namespace
|
|
638
|
-
* @param {EntityType} entityType - the entity type
|
|
639
697
|
* @returns Communication annotation term type
|
|
640
698
|
*/
|
|
641
699
|
function getCommunicationAnnotationTerm(path, alias) {
|
|
@@ -650,7 +708,8 @@ function getCommunicationAnnotationTerm(path, alias) {
|
|
|
650
708
|
}
|
|
651
709
|
}
|
|
652
710
|
/**
|
|
653
|
-
* Determines the type of given annotation term
|
|
711
|
+
* Determines the type of given annotation term.
|
|
712
|
+
*
|
|
654
713
|
* @param {string} path path in manifest
|
|
655
714
|
* @param {string} alias for a given namespace
|
|
656
715
|
* @param {EntityType} entityType - the entity type
|
|
@@ -660,11 +719,13 @@ function getAnnotationTerm(path, alias, entityType) {
|
|
|
660
719
|
return getUIAnnotationTerm(path, alias, entityType) || getCommunicationAnnotationTerm(path, alias);
|
|
661
720
|
}
|
|
662
721
|
/**
|
|
663
|
-
* Evaluates the target annotation of a reference facet and actualizes the facets for the config
|
|
664
|
-
*
|
|
665
|
-
* @param
|
|
666
|
-
* @param
|
|
667
|
-
* @param
|
|
722
|
+
* Evaluates the target annotation of a reference facet and actualizes the facets for the config.
|
|
723
|
+
*
|
|
724
|
+
* @param section - The section object in the app schema to be updated with annotation information.
|
|
725
|
+
* @param annotationRecord - the actual annotation record
|
|
726
|
+
* @param facets - list of facets in config format, to be updated
|
|
727
|
+
* @param entityType - the entity type
|
|
728
|
+
* @param oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
|
|
668
729
|
*/
|
|
669
730
|
function evaluateTargetAnnotation(section, annotationRecord, facets, entityType, oDataServiceAVT) {
|
|
670
731
|
const alias = findAlias(ux_specification_types_1.UIVOCABULARY, oDataServiceAVT);
|
|
@@ -754,6 +815,7 @@ function evaluateTargetAnnotation(section, annotationRecord, facets, entityType,
|
|
|
754
815
|
}
|
|
755
816
|
/**
|
|
756
817
|
* Method returns schema annotation path for passed fullyQualifiedName.
|
|
818
|
+
*
|
|
757
819
|
* @param {EntityType} entityType entity type.
|
|
758
820
|
* @param {string} fullyQualifiedName fully qualifier name.
|
|
759
821
|
* @returns {TemplateType} Schema annotation path.
|
|
@@ -762,14 +824,15 @@ function getAnnotationPathUsingFullyQualifiedName(entityType, fullyQualifiedName
|
|
|
762
824
|
return `/${entityType.fullyQualifiedName}/${fullyQualifiedName.split(entityType.fullyQualifiedName)[1]}`;
|
|
763
825
|
}
|
|
764
826
|
/**
|
|
765
|
-
* Adds the information from facets to the config
|
|
766
|
-
*
|
|
767
|
-
* @param
|
|
768
|
-
* @param
|
|
769
|
-
* @param
|
|
770
|
-
* @param
|
|
771
|
-
* @param
|
|
772
|
-
* @param
|
|
827
|
+
* Adds the information from facets to the config.
|
|
828
|
+
*
|
|
829
|
+
* @param annotationRecord - the actual annotation record
|
|
830
|
+
* @param oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
|
|
831
|
+
* @param serviceName - name of the service of the app
|
|
832
|
+
* @param entityType - The entity type to be used for resolving facets
|
|
833
|
+
* @param facets - list of facets in config format, to be updated
|
|
834
|
+
* @param oDataVersion - OData version
|
|
835
|
+
* @param logger - Logger class for logging messages
|
|
773
836
|
*/
|
|
774
837
|
function addFacetToConfig(annotationRecord, oDataServiceAVT, serviceName, entityType, facets, oDataVersion = ux_specification_types_1.FioriElementsVersion.v2, logger) {
|
|
775
838
|
const section = getSectionFacet(annotationRecord, entityType, oDataServiceAVT, logger, oDataVersion, false);
|
|
@@ -804,11 +867,13 @@ function addFacetToConfig(annotationRecord, oDataServiceAVT, serviceName, entity
|
|
|
804
867
|
}
|
|
805
868
|
}
|
|
806
869
|
/**
|
|
807
|
-
* Retrieve header facet configurations that can be used to generate ObjectPage schemas
|
|
808
|
-
*
|
|
809
|
-
* @param
|
|
810
|
-
* @param
|
|
811
|
-
* @param
|
|
870
|
+
* Retrieve header facet configurations that can be used to generate ObjectPage schemas.
|
|
871
|
+
*
|
|
872
|
+
* @param entityType - The entity type to be used for resolving facets
|
|
873
|
+
* @param oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
|
|
874
|
+
* @param oDataVersion - OData version
|
|
875
|
+
* @param logger - Logger class for logging messages
|
|
876
|
+
* @returns - header facet configurations
|
|
812
877
|
*/
|
|
813
878
|
function getObjectPageHeaderFacets(entityType, oDataServiceAVT, oDataVersion = ux_specification_types_1.FioriElementsVersion.v2, logger) {
|
|
814
879
|
const facets = {};
|
|
@@ -828,11 +893,13 @@ function getObjectPageHeaderFacets(entityType, oDataServiceAVT, oDataVersion = u
|
|
|
828
893
|
return facets;
|
|
829
894
|
}
|
|
830
895
|
/**
|
|
831
|
-
* Retrieve facet configurations that can be used to generate ObjectPage schemas
|
|
832
|
-
*
|
|
833
|
-
* @param
|
|
896
|
+
* Retrieve facet configurations that can be used to generate ObjectPage schemas.
|
|
897
|
+
*
|
|
898
|
+
* @param entityType - The entity type to be used for resolving facets
|
|
899
|
+
* @param oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
|
|
834
900
|
* @param {FioriElementsVersion} oDataVersion - OData version
|
|
835
901
|
* @param {ExtensionLogger} logger - Logger class for logging messages
|
|
902
|
+
* @returns - facet configurations
|
|
836
903
|
*/
|
|
837
904
|
function getObjectPageFacets(entityType, oDataServiceAVT, oDataVersion = ux_specification_types_1.FioriElementsVersion.v2, logger) {
|
|
838
905
|
const facets = {};
|
|
@@ -852,7 +919,8 @@ function getObjectPageFacets(entityType, oDataServiceAVT, oDataVersion = ux_spec
|
|
|
852
919
|
return facets;
|
|
853
920
|
}
|
|
854
921
|
/**
|
|
855
|
-
* Returns the version of Fiori elements (v2/v4) from a given manifest
|
|
922
|
+
* Returns the version of Fiori elements (v2/v4) from a given manifest.
|
|
923
|
+
*
|
|
856
924
|
* @param manifest - the manifest.json file
|
|
857
925
|
* @returns FioriElementsVersion
|
|
858
926
|
*/
|
|
@@ -865,7 +933,10 @@ function getFEVersionFromManifest(manifest) {
|
|
|
865
933
|
const targets = manifest[ux_specification_types_1.ManifestSection.ui5]?.routing?.targets;
|
|
866
934
|
const libs = manifest[ux_specification_types_1.ManifestSection.ui5]?.dependencies?.libs;
|
|
867
935
|
if ((targets &&
|
|
868
|
-
Object.keys(targets).find((targetKey) =>
|
|
936
|
+
Object.keys(targets).find((targetKey) => {
|
|
937
|
+
const name = typeof targets[targetKey].name === 'string' ? targets[targetKey].name : '';
|
|
938
|
+
return exports.V4_TEMPLATES.indexOf(name) > -1 || convertTemplateNameToPageTypeV4(name);
|
|
939
|
+
})) ||
|
|
869
940
|
(libs && Object.keys(libs).find((lib) => exports.V4_LIBS.indexOf(lib) > -1))) {
|
|
870
941
|
return ux_specification_types_1.FioriElementsVersion.v4;
|
|
871
942
|
}
|
|
@@ -891,7 +962,8 @@ function getMainService(manifest) {
|
|
|
891
962
|
: undefined;
|
|
892
963
|
}
|
|
893
964
|
/**
|
|
894
|
-
* Returns the oData version of the service (if any) from a given manifest
|
|
965
|
+
* Returns the oData version of the service (if any) from a given manifest.
|
|
966
|
+
*
|
|
895
967
|
* @param manifest - the manifest.json file
|
|
896
968
|
* @returns the OData version
|
|
897
969
|
*/
|
|
@@ -904,10 +976,11 @@ function getODataVersionFromManifest(manifest) {
|
|
|
904
976
|
return dataSource?.settings?.odataVersion === '4.0' ? ux_specification_types_1.OdataVersion.v4 : ux_specification_types_1.OdataVersion.v2;
|
|
905
977
|
}
|
|
906
978
|
/**
|
|
907
|
-
* Determines the template type of a V2 app
|
|
979
|
+
* Determines the template type of a V2 app.
|
|
980
|
+
*
|
|
908
981
|
* @param manifest - the manifest.json file
|
|
909
982
|
* @param {ExtensionLogger} logger - Logger class for logging messages
|
|
910
|
-
* @returns
|
|
983
|
+
* @returns the template type
|
|
911
984
|
*/
|
|
912
985
|
function determineV2Template(manifest, logger) {
|
|
913
986
|
let templateType;
|
|
@@ -951,7 +1024,8 @@ function determineV2Template(manifest, logger) {
|
|
|
951
1024
|
return templateType;
|
|
952
1025
|
}
|
|
953
1026
|
/**
|
|
954
|
-
* Determines the template type of a single page
|
|
1027
|
+
* Determines the template type of a single page.
|
|
1028
|
+
*
|
|
955
1029
|
* @param v4Page - single page from routing targets
|
|
956
1030
|
* @returns {TemplateType | undefined} the template type
|
|
957
1031
|
*/
|
|
@@ -980,7 +1054,8 @@ function determineV4PageTemplateType(v4Page) {
|
|
|
980
1054
|
return templateType;
|
|
981
1055
|
}
|
|
982
1056
|
/**
|
|
983
|
-
* Determines the template type, based on the given manifest routing target entries of the app
|
|
1057
|
+
* Determines the template type, based on the given manifest routing target entries of the app.
|
|
1058
|
+
*
|
|
984
1059
|
* @param v4Pages - pages from routing targets
|
|
985
1060
|
* @returns {TemplateType | undefined} the template type
|
|
986
1061
|
*/
|
|
@@ -996,7 +1071,8 @@ function determineV4TemplateFromPages(v4Pages) {
|
|
|
996
1071
|
return templateType;
|
|
997
1072
|
}
|
|
998
1073
|
/**
|
|
999
|
-
* Determines the template type of a V4 app
|
|
1074
|
+
* Determines the template type of a V4 app.
|
|
1075
|
+
*
|
|
1000
1076
|
* @param manifest - the manifest.json file
|
|
1001
1077
|
* @param {ExtensionLogger} logger - Logger class for logging messages
|
|
1002
1078
|
* @returns {TemplateType} the template type
|
|
@@ -1031,7 +1107,8 @@ function determineV4Template(manifest, logger) {
|
|
|
1031
1107
|
return templateType;
|
|
1032
1108
|
}
|
|
1033
1109
|
/**
|
|
1034
|
-
* Determines the template type, based on the given manifest entries of the app
|
|
1110
|
+
* Determines the template type, based on the given manifest entries of the app.
|
|
1111
|
+
*
|
|
1035
1112
|
* @param manifest - the manifest.json file
|
|
1036
1113
|
* @param {FioriElementsVersion} fioriElementsVersion - OData or FE version
|
|
1037
1114
|
* @param {ExtensionLogger} logger - Logger class for logging messages
|
|
@@ -1051,7 +1128,8 @@ function getTemplateTypeFromManifest(manifest, fioriElementsVersion, logger) {
|
|
|
1051
1128
|
return templateType;
|
|
1052
1129
|
}
|
|
1053
1130
|
/**
|
|
1054
|
-
* Adds title to a section or header section in an app schema
|
|
1131
|
+
* Adds title to a section or header section in an app schema.
|
|
1132
|
+
*
|
|
1055
1133
|
* @param facet - intermediate facet structure comprising annotation information
|
|
1056
1134
|
* @param section - section in the app schema
|
|
1057
1135
|
* @param facetKey - key of the facet
|
|
@@ -1067,7 +1145,8 @@ function addSectionTitle(facet, section, facetKey) {
|
|
|
1067
1145
|
}
|
|
1068
1146
|
}
|
|
1069
1147
|
/**
|
|
1070
|
-
* Adds description to a section or header section in an app schema
|
|
1148
|
+
* Adds description to a section or header section in an app schema.
|
|
1149
|
+
*
|
|
1071
1150
|
* @param facet - intermediate facet structure comprising annotation information
|
|
1072
1151
|
* @param section - section in the app schema
|
|
1073
1152
|
* @param facetKey - key of the facet
|
|
@@ -1084,7 +1163,8 @@ function addSectionDescription(facet, section, facetKey) {
|
|
|
1084
1163
|
}
|
|
1085
1164
|
}
|
|
1086
1165
|
/**
|
|
1087
|
-
* Adds target title or description to a section or header section in an app schema
|
|
1166
|
+
* Adds target title or description to a section or header section in an app schema.
|
|
1167
|
+
*
|
|
1088
1168
|
* @param facet - intermediate facet structure comprising annotation information
|
|
1089
1169
|
* @param section - section in the app schema
|
|
1090
1170
|
* @param facetKey - key of the facet
|
|
@@ -1106,10 +1186,10 @@ function addTargetTitleAndSectionDescription(facet, section, facetKey) {
|
|
|
1106
1186
|
}
|
|
1107
1187
|
}
|
|
1108
1188
|
/**
|
|
1109
|
-
* Adds chart (S)PV header facet ID, in case chart has no title
|
|
1189
|
+
* Adds chart (S)PV header facet ID, in case chart has no title.
|
|
1190
|
+
*
|
|
1110
1191
|
* @param facet - intermediate facet structure comprising annotation information
|
|
1111
1192
|
* @param section - section in the app schema
|
|
1112
|
-
* @param facetKey - key of the facet
|
|
1113
1193
|
*/
|
|
1114
1194
|
function addChartFacetID(facet, section) {
|
|
1115
1195
|
if (facet?.ID && section.description?.startsWith('Chart#')) {
|
|
@@ -1118,7 +1198,10 @@ function addChartFacetID(facet, section) {
|
|
|
1118
1198
|
}
|
|
1119
1199
|
/**
|
|
1120
1200
|
* Creates a default object for a new section or subsection, and adds the ID as title if present.
|
|
1121
|
-
*
|
|
1201
|
+
*
|
|
1202
|
+
* @param appSchema - The application-specific JSON schema.
|
|
1203
|
+
* @param facet - Facet configuration, to be analyzed.
|
|
1204
|
+
* @param facetKey - The key of the facet.
|
|
1122
1205
|
* @returns the new section object
|
|
1123
1206
|
*/
|
|
1124
1207
|
function createDefaultSection(appSchema, facet, facetKey) {
|
|
@@ -1134,12 +1217,13 @@ function createDefaultSection(appSchema, facet, facetKey) {
|
|
|
1134
1217
|
}
|
|
1135
1218
|
/**
|
|
1136
1219
|
* Retrieve page section data(so far id/key and label/description).
|
|
1220
|
+
*
|
|
1137
1221
|
* @param {EntityType} entityType The actual entityType
|
|
1138
1222
|
* @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
|
|
1139
1223
|
* @param {ExtensionLogger} logger - Logger class for logging messages
|
|
1140
1224
|
* @param {FioriElementsVersion} oDataVersion - OData version
|
|
1141
|
-
* @param {boolean} [checkUnresolvableFacets
|
|
1142
|
-
* @returns
|
|
1225
|
+
* @param {boolean} [checkUnresolvableFacets] - Check and avoid facets and sections without ID and Target.
|
|
1226
|
+
* @returns - Array of facets or sections
|
|
1143
1227
|
*/
|
|
1144
1228
|
function getObjectPageFacetSection(entityType, oDataServiceAVT, logger, oDataVersion = ux_specification_types_1.FioriElementsVersion.v2, checkUnresolvableFacets = false) {
|
|
1145
1229
|
const alias = findAlias(ux_specification_types_1.UIVOCABULARY, oDataServiceAVT);
|
|
@@ -1162,7 +1246,8 @@ function getObjectPageFacetSection(entityType, oDataServiceAVT, logger, oDataVer
|
|
|
1162
1246
|
}
|
|
1163
1247
|
}
|
|
1164
1248
|
/**
|
|
1165
|
-
* Cleans empty sub-structures from the export result for manifest
|
|
1249
|
+
* Cleans empty sub-structures from the export result for manifest.
|
|
1250
|
+
*
|
|
1166
1251
|
* @param {object} manifest - manifest.json part of the export result
|
|
1167
1252
|
* @param {string} path - path in the manifest
|
|
1168
1253
|
* @param {boolean} deletionRequest - if set to true, any manifest setting specified by entityPath gets deleted even if it comprises any unknown property
|
|
@@ -1208,8 +1293,9 @@ const deleteEmptyStructure = (manifest, path, deletionRequest, entityPathArray,
|
|
|
1208
1293
|
exports.deleteEmptyStructure = deleteEmptyStructure;
|
|
1209
1294
|
/**
|
|
1210
1295
|
* Method which returns generic schema file name.
|
|
1296
|
+
*
|
|
1211
1297
|
* @param {SchemaType | PageTypeV2} schemaType Schema type or Page type.
|
|
1212
|
-
* @
|
|
1298
|
+
* @returns {string} File name of generic schema.
|
|
1213
1299
|
*/
|
|
1214
1300
|
const getGenericSchemaFileName = (schemaType) => {
|
|
1215
1301
|
if (schemaType === ux_specification_types_1.SchemaType.FreestylePage) {
|
|
@@ -1223,9 +1309,11 @@ const getGenericSchemaFileName = (schemaType) => {
|
|
|
1223
1309
|
};
|
|
1224
1310
|
/**
|
|
1225
1311
|
* Method which returns schema file name and path depending on passed schema or page type.
|
|
1312
|
+
*
|
|
1226
1313
|
* @param {SchemaType | PageTypeV2} schemaType Schema type or Page type.
|
|
1227
1314
|
* @param {string} [pageId] target page id from manifest.json
|
|
1228
|
-
* @
|
|
1315
|
+
* @param viewId - The view ID for custom pages (optional).
|
|
1316
|
+
* @returns {SchemaFilePath} File path info.
|
|
1229
1317
|
*/
|
|
1230
1318
|
const getSchemaFilePath = (schemaType, pageId, viewId) => {
|
|
1231
1319
|
const schemaFile = {
|
|
@@ -1275,6 +1363,7 @@ const getSchemaFilePath = (schemaType, pageId, viewId) => {
|
|
|
1275
1363
|
exports.getSchemaFilePath = getSchemaFilePath;
|
|
1276
1364
|
/**
|
|
1277
1365
|
* Method which generates id of page according to passed parameters
|
|
1366
|
+
*
|
|
1278
1367
|
* @param appVersion - Fiori Elements version - V2 or V4
|
|
1279
1368
|
* @param pageType - Page type
|
|
1280
1369
|
* @param entitySet - Entity Set
|
|
@@ -1282,6 +1371,15 @@ exports.getSchemaFilePath = getSchemaFilePath;
|
|
|
1282
1371
|
* @param pageName - Page name in manifest. Used if entitySet is empty
|
|
1283
1372
|
* @returns {string} Generated page id
|
|
1284
1373
|
*/
|
|
1374
|
+
/**
|
|
1375
|
+
* Generates a unique page ID based on the provided parameters.
|
|
1376
|
+
*
|
|
1377
|
+
* @param pageType - The type of the page (e.g., ListReport, ObjectPage, etc.).
|
|
1378
|
+
* @param entitySet - The entity set associated with the page.
|
|
1379
|
+
* @param viewId - The view ID for custom pages (optional).
|
|
1380
|
+
* @param pageName - The name of the page in the manifest (used if entitySet is empty).
|
|
1381
|
+
* @returns The generated page ID as a string.
|
|
1382
|
+
*/
|
|
1285
1383
|
function generatePageId(pageType, entitySet, viewId, pageName) {
|
|
1286
1384
|
if (pageType === ux_specification_types_1.PageTypeV2.CustomPage) {
|
|
1287
1385
|
const names = viewId && viewId.split('.');
|
|
@@ -1299,6 +1397,7 @@ function generatePageId(pageType, entitySet, viewId, pageName) {
|
|
|
1299
1397
|
}
|
|
1300
1398
|
/**
|
|
1301
1399
|
* Method finds matching objects against passed interface of 'additionalProperties' and returns array of matching object keys.
|
|
1400
|
+
*
|
|
1302
1401
|
* @param {Definition} appSchema - App-specific JSON schema.
|
|
1303
1402
|
* @param {Definition} additionalProperties - Allowed additional properties.
|
|
1304
1403
|
* @param {object} configObject -Container object to find matching childs.
|
|
@@ -1330,6 +1429,15 @@ function findMatchingKeysByAdditionalProperties(appSchema, additionalProperties,
|
|
|
1330
1429
|
}
|
|
1331
1430
|
return result;
|
|
1332
1431
|
}
|
|
1432
|
+
/**
|
|
1433
|
+
* Populates a given array with definitions from an application's schema that match certain conditions defined by the current configuration object and element reference.
|
|
1434
|
+
*
|
|
1435
|
+
* @param element - The element containing a reference ($ref) to a specific definition within the application schema.
|
|
1436
|
+
* @param appSchema - The application's schema object containing all definitions.
|
|
1437
|
+
* @param currentConfigObject - The current configuration object which is evaluated against the schema definitions.
|
|
1438
|
+
* @param definitionArray - The array to which matching definitions are added based on the evaluation.
|
|
1439
|
+
* This function does not return any value but modifies the definitionArray parameter by adding appropriate definitions.
|
|
1440
|
+
*/
|
|
1333
1441
|
function fillArrayFromAnyOfReference(element, appSchema, currentConfigObject, definitionArray) {
|
|
1334
1442
|
const $ref = element.$ref;
|
|
1335
1443
|
if (!$ref) {
|
|
@@ -1357,7 +1465,8 @@ function fillArrayFromAnyOfReference(element, appSchema, currentConfigObject, de
|
|
|
1357
1465
|
}
|
|
1358
1466
|
}
|
|
1359
1467
|
/**
|
|
1360
|
-
* Fills an array of next definitions from given references in the JSON schema
|
|
1468
|
+
* Fills an array of next definitions from given references in the JSON schema.
|
|
1469
|
+
*
|
|
1361
1470
|
* @param propertyDefinition - Definition of the current property in schema
|
|
1362
1471
|
* @param currentConfigObject - Current object in the config JSON. Evaluated to get the right value of a controlling property,
|
|
1363
1472
|
* for making the right choice in case of multiple options (anyOf)
|
|
@@ -1383,7 +1492,8 @@ function fillArrayFromPropertyDefinition(propertyDefinition, currentConfigObject
|
|
|
1383
1492
|
}
|
|
1384
1493
|
/**
|
|
1385
1494
|
* Determines the next definition to be handled, based on the definition array.
|
|
1386
|
-
* It also creates the Metadata instance for the next definition, to subsequently access metadata like the syncRule
|
|
1495
|
+
* It also creates the Metadata instance for the next definition, to subsequently access metadata like the syncRule.
|
|
1496
|
+
*
|
|
1387
1497
|
* @param definitionArray - Array of definitions, as determined by fillArrayFromNextDefinition
|
|
1388
1498
|
* @param appSchema - app-specific JSON schema
|
|
1389
1499
|
* @param title - default title
|
|
@@ -1435,7 +1545,8 @@ function determineNextDefinitionFromDefinitionArray(definitionArray, appSchema,
|
|
|
1435
1545
|
return nextDefinition;
|
|
1436
1546
|
}
|
|
1437
1547
|
/**
|
|
1438
|
-
* Recursive function to determine the next config part, next definition in the app schema and the title
|
|
1548
|
+
* Recursive function to determine the next config part, next definition in the app schema and the title.
|
|
1549
|
+
*
|
|
1439
1550
|
* @param appSchema - app-specific JSON schema
|
|
1440
1551
|
* @param title - default title
|
|
1441
1552
|
* @param currentConfigObject - current part of the configuration that gets traversed
|
|
@@ -1443,6 +1554,7 @@ function determineNextDefinitionFromDefinitionArray(definitionArray, appSchema,
|
|
|
1443
1554
|
* @param key - actual key
|
|
1444
1555
|
* @param {MetadataInstanceInterface} factory - factory for creating metadata instances
|
|
1445
1556
|
* @param pageType - page type
|
|
1557
|
+
* @returns {NextDefinition} - Next target definition to process
|
|
1446
1558
|
*/
|
|
1447
1559
|
function getNextTargetDefinition(appSchema, title, currentConfigObject, propertyDefinition, key, factory, pageType) {
|
|
1448
1560
|
let nextDefinition;
|
|
@@ -1458,12 +1570,12 @@ function getNextTargetDefinition(appSchema, title, currentConfigObject, property
|
|
|
1458
1570
|
return nextDefinition;
|
|
1459
1571
|
}
|
|
1460
1572
|
/**
|
|
1461
|
-
* Custom array merge function called by deepmerge's merge function
|
|
1573
|
+
* Custom array merge function called by deepmerge's merge function.
|
|
1462
1574
|
*
|
|
1463
1575
|
* @param {*} target Target array
|
|
1464
1576
|
* @param {*} source Source array
|
|
1465
1577
|
* @param {*} options options object provided by deepmerge's merge function
|
|
1466
|
-
* @returns
|
|
1578
|
+
* @returns {string[]} Combined array with unique elements from both target and source arrays.
|
|
1467
1579
|
*/
|
|
1468
1580
|
const arrayCombineMerge = (target, source, options) => {
|
|
1469
1581
|
const destination = target.slice();
|
|
@@ -1482,7 +1594,8 @@ const arrayCombineMerge = (target, source, options) => {
|
|
|
1482
1594
|
};
|
|
1483
1595
|
exports.arrayCombineMerge = arrayCombineMerge;
|
|
1484
1596
|
/**
|
|
1485
|
-
* Converts an enum into a CSV
|
|
1597
|
+
* Converts an enum into a CSV.
|
|
1598
|
+
*
|
|
1486
1599
|
* @param {object} manifestSection - manifestSection where the key exists
|
|
1487
1600
|
* @param {object} configPart - Property as mentioned in config file
|
|
1488
1601
|
* @param {string} key - Property to be exported to manifest
|
|
@@ -1494,7 +1607,8 @@ function convertEnumToCSV(manifestSection, configPart, key) {
|
|
|
1494
1607
|
manifestSection[key] = field.join();
|
|
1495
1608
|
}
|
|
1496
1609
|
/**
|
|
1497
|
-
* Converts an action ID from the internal format (schema, config) to the stable ID representation
|
|
1610
|
+
* Converts an action ID from the internal format (schema, config) to the stable ID representation.
|
|
1611
|
+
*
|
|
1498
1612
|
* @param actionId - the (unique) internal format of the action ID
|
|
1499
1613
|
* @returns the converted action ID
|
|
1500
1614
|
*/
|
|
@@ -1505,7 +1619,8 @@ function convertActionKeyToStableId(actionId) {
|
|
|
1505
1619
|
return (actionId.indexOf('??') > -1 ? actionId.split('??')[1] : actionId).replace(/@/g, '::');
|
|
1506
1620
|
}
|
|
1507
1621
|
/**
|
|
1508
|
-
* Method returns definition key for passed '$ref' property by removing 'definition' prefix
|
|
1622
|
+
* Method returns definition key for passed '$ref' property by removing 'definition' prefix.
|
|
1623
|
+
*
|
|
1509
1624
|
* @param {string} $ref Definition reference.
|
|
1510
1625
|
* @returns Definition key.
|
|
1511
1626
|
*/
|
|
@@ -1514,6 +1629,7 @@ function getDefinitionKey($ref) {
|
|
|
1514
1629
|
}
|
|
1515
1630
|
/**
|
|
1516
1631
|
* Method returns definition $ref' property for passed definition key.
|
|
1632
|
+
*
|
|
1517
1633
|
* @param {string} key Definition key.
|
|
1518
1634
|
* @returns Definition reference.
|
|
1519
1635
|
*/
|
|
@@ -1555,6 +1671,7 @@ function updatePropertyIndices(schema, order) {
|
|
|
1555
1671
|
}
|
|
1556
1672
|
/**
|
|
1557
1673
|
* Method to get value for passed path in passed object.
|
|
1674
|
+
*
|
|
1558
1675
|
* @param obj Object to check.
|
|
1559
1676
|
* @param paths Path for searching property/value.
|
|
1560
1677
|
* @returns Found value for passed path.
|
|
@@ -1576,8 +1693,9 @@ function getJSONPropertyByPath(obj, paths) {
|
|
|
1576
1693
|
return current;
|
|
1577
1694
|
}
|
|
1578
1695
|
/**
|
|
1579
|
-
* Method to remove namespaces
|
|
1580
|
-
*
|
|
1696
|
+
* Method to remove namespaces.
|
|
1697
|
+
*
|
|
1698
|
+
* @param sId - The string identifier to process and remove namespaces from.
|
|
1581
1699
|
* @returns {string} modified string without namespace
|
|
1582
1700
|
*/
|
|
1583
1701
|
function removeNamespaces(sId) {
|
|
@@ -1586,8 +1704,9 @@ function removeNamespaces(sId) {
|
|
|
1586
1704
|
return sId;
|
|
1587
1705
|
}
|
|
1588
1706
|
/**
|
|
1589
|
-
* Method to replace namespaces with short hand form
|
|
1590
|
-
*
|
|
1707
|
+
* Method to replace namespaces with short hand form.
|
|
1708
|
+
*
|
|
1709
|
+
* @param {string } sId - The string identifier to process and replace namespaces with shorthand forms.
|
|
1591
1710
|
* @returns {string} modified string with replaced namespaces
|
|
1592
1711
|
*/
|
|
1593
1712
|
function replaceNamespaces(sId) {
|
|
@@ -1607,4 +1726,35 @@ function getRefType(element) {
|
|
|
1607
1726
|
return reference.substring(exports.DEFINITION_LINK_PREFIX.length);
|
|
1608
1727
|
}
|
|
1609
1728
|
}
|
|
1729
|
+
/**
|
|
1730
|
+
* Converts a template name string from 'manifest.json' to a corresponding `PageTypeV4` enum value.
|
|
1731
|
+
*
|
|
1732
|
+
* @param {string} templateName - The name of the template to convert.
|
|
1733
|
+
* @returns {PageTypeV4 | undefined} The corresponding `PageTypeV4` enum value, or `undefined` if no match is found.
|
|
1734
|
+
*/
|
|
1735
|
+
function convertTemplateNameToPageTypeV4(templateName) {
|
|
1736
|
+
if (templateName === ux_specification_types_1.v4.FE_TEMPLATE_V4_CUSTOM_PAGE) {
|
|
1737
|
+
return ux_specification_types_1.PageTypeV4.FPMCustomPage;
|
|
1738
|
+
}
|
|
1739
|
+
if (templateName?.startsWith(`${ux_specification_types_1.v4.FE_NAMESPACE_V4}.`)) {
|
|
1740
|
+
const pageType = templateName.split('.').at(-1);
|
|
1741
|
+
if (pageType in ux_specification_types_1.PageTypeV4) {
|
|
1742
|
+
return ux_specification_types_1.PageTypeV4[pageType];
|
|
1743
|
+
}
|
|
1744
|
+
}
|
|
1745
|
+
}
|
|
1746
|
+
/**
|
|
1747
|
+
* Determines whether two template names match either directly or by resolving their corresponding page types.
|
|
1748
|
+
*
|
|
1749
|
+
* @param templateName1 The first template name to compare.
|
|
1750
|
+
* @param templateName2 The second template name to compare.
|
|
1751
|
+
* @returns Returns true if the template names match directly or their page types match; otherwise, false.
|
|
1752
|
+
*/
|
|
1753
|
+
function compareTemplateNames(templateName1, templateName2) {
|
|
1754
|
+
if (templateName1 === templateName2) {
|
|
1755
|
+
return true;
|
|
1756
|
+
}
|
|
1757
|
+
const pageType1 = convertTemplateNameToPageTypeV4(templateName1);
|
|
1758
|
+
return pageType1 ? pageType1 === convertTemplateNameToPageTypeV4(templateName2) : false;
|
|
1759
|
+
}
|
|
1610
1760
|
//# sourceMappingURL=utils.js.map
|