@sap/ux-specification 1.96.11 → 1.96.14

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 (54) hide show
  1. package/CHANGELOG.md +63 -6
  2. package/dist/documentation/v2/v2-AnalyticalListPage.html +1 -1
  3. package/dist/documentation/v2/v2-ApplicationV2.html +1 -1
  4. package/dist/documentation/v2/v2-ListReport.html +1 -1
  5. package/dist/documentation/v2/v2-ObjectPage.html +1 -1
  6. package/dist/documentation/v2/v2-OverviewPage.html +1 -1
  7. package/dist/documentation/v4/v4-ApplicationV4.html +1 -1
  8. package/dist/documentation/v4/v4-ListReport.html +1 -1
  9. package/dist/documentation/v4/v4-ObjectPage.html +1 -1
  10. package/dist/index-min.js +1 -1
  11. package/dist/schemas/v2/AnalyticalListPageConfig.json +10 -10
  12. package/dist/schemas/v2/ListReportConfig.json +15 -15
  13. package/dist/schemas/v2/ObjectPageConfig.json +204 -20
  14. package/dist/schemas/v4/ListReportConfig.json +3 -3
  15. package/dist/src/apiTypes.d.ts +3 -3
  16. package/dist/src/project.d.ts +1 -0
  17. package/dist/src/specification/v2/controls/Action.d.ts +6 -4
  18. package/dist/src/specification/v2/controls/Facets.d.ts +2 -1
  19. package/dist/src/specification/v2/controls/ObjectPageHeader.d.ts +3 -2
  20. package/dist/src/specification/v2/controls/ObjectPageSection.d.ts +44 -9
  21. package/dist/src/specification/v2/controls/ObjectPageTable.d.ts +5 -3
  22. package/dist/src/specification/v2/controls/Table.d.ts +7 -4
  23. package/dist/src/specification/v4/controls/Table.d.ts +2 -2
  24. package/dist/src/specification/v4/pages/ListReportConfig.d.ts +1 -1
  25. package/dist/src/sync/common/appProvider.d.ts +1 -1
  26. package/dist/src/sync/common/decoration/control.d.ts +1 -1
  27. package/dist/src/sync/common/decoration/decorators.d.ts +2 -2
  28. package/dist/src/sync/common/generate/objectPage.d.ts +8 -9
  29. package/dist/src/sync/common/generate/utils.d.ts +28 -10
  30. package/dist/src/sync/common/import/utils.d.ts +9 -2
  31. package/dist/src/sync/common/importProject.d.ts +2 -3
  32. package/dist/src/sync/common/types.d.ts +9 -2
  33. package/dist/src/sync/common/utils.d.ts +19 -17
  34. package/dist/src/sync/v2/application.d.ts +3 -3
  35. package/dist/src/sync/v2/export/controls/Action.d.ts +12 -10
  36. package/dist/src/sync/v2/export/controls/FormAction.d.ts +9 -7
  37. package/dist/src/sync/v2/export/controls/ObjectPageFooterAction.d.ts +6 -4
  38. package/dist/src/sync/v2/export/controls/ObjectPageHeader.d.ts +3 -2
  39. package/dist/src/sync/v2/export/controls/ObjectPageHeaderAction.d.ts +6 -4
  40. package/dist/src/sync/v2/export/controls/ObjectPageSectionsV2.d.ts +26 -14
  41. package/dist/src/sync/v2/export/controls/ObjectPageTable.d.ts +5 -3
  42. package/dist/src/sync/v2/export/controls/ObjectPageToolBarAction.d.ts +6 -4
  43. package/dist/src/sync/v2/export/controls/Table.d.ts +5 -3
  44. package/dist/src/sync/v2/export/controls/TableColumn.d.ts +12 -10
  45. package/dist/src/sync/v2/generate/listReport.d.ts +3 -4
  46. package/dist/src/sync/v2/generate/utils.d.ts +7 -6
  47. package/dist/src/sync/v2/types.d.ts +8 -3
  48. package/dist/src/sync/v4/export/controls/Table.d.ts +3 -1
  49. package/dist/src/sync/v4/export/pages/ListReport.d.ts +1 -1
  50. package/dist/src/sync/v4/generate/listReport.d.ts +2 -2
  51. package/dist/src/sync/v4/types.d.ts +1 -1
  52. package/dist/src/sync/v4/utils/utils.d.ts +12 -11
  53. package/dist/test/test-utils/utils.d.ts +1 -2
  54. package/package.json +8 -8
@@ -1,4 +1,6 @@
1
- /// <reference types="@sapui5/ts-types" />
1
+ /// <reference types="@sapui5/ts-types-esm" />
2
+ import type { ButtonType } from 'sap/m/library';
3
+ import type { URI } from 'sap/ui/core/library';
2
4
  /**
3
5
  * Actions
4
6
  * @isViewNode true
@@ -19,15 +21,15 @@ export interface Action {
19
21
  /**
20
22
  * Icon to be displayed as graphical element within the Button. Can be an image or icon from the icon font (https://sapui5.hana.ondemand.com/test-resources/sap/m/demokit/iconExplorer/webapp/index.html#/overview/SAP-icons), represented as RFC 3986 conformant URI.
21
23
  */
22
- icon?: sap.ui.core.URI;
24
+ icon?: URI;
23
25
  /**
24
26
  * Alternative icon for the active (depressed) state of the button. Can be an image or icon from the icon font (https://sapui5.hana.ondemand.com/test-resources/sap/m/demokit/iconExplorer/webapp/index.html#/overview/SAP-icons), represented as RFC 3986 conformant URI.
25
27
  */
26
- activeIcon?: sap.ui.core.URI;
28
+ activeIcon?: URI;
27
29
  /**
28
30
  * Defines the Button type.
29
31
  */
30
- type?: sap.m.ButtonType;
32
+ type?: ButtonType;
31
33
  }
32
34
  /**
33
35
  * Form Action
@@ -7,10 +7,11 @@ export declare type ObjectPageTableTypeV2 = ObjectPageResponsiveTable | ObjectPa
7
7
  export interface LineItemFacet {
8
8
  table: ObjectPageTableTypeV2;
9
9
  }
10
+ export declare type FormFacetType = boolean | number | string | object;
10
11
  /**
11
12
  * Form Facet
12
13
  * @isViewNode true
13
14
  */
14
15
  export interface FormFacet {
15
- [id: string]: boolean | number | string | object;
16
+ [id: string]: FormFacetType;
16
17
  }
@@ -1,5 +1,6 @@
1
- /// <reference types="@sapui5/ts-types" />
1
+ /// <reference types="@sapui5/ts-types-esm" />
2
2
  import type { HeaderAction } from '.';
3
+ import type AvatarShape from 'sap/m/AvatarShape';
3
4
  export interface GenericActions {
4
5
  [id: string]: HeaderAction;
5
6
  }
@@ -23,7 +24,7 @@ export interface ObjectPageHeader<ACT = GenericActions> {
23
24
  /**
24
25
  * With displayShape you can define the shape of the avatar.
25
26
  */
26
- displayShape?: sap.m.AvatarShape;
27
+ displayShape?: AvatarShape;
27
28
  /**
28
29
  * Set properties of actions on Object Page Header
29
30
  */
@@ -4,7 +4,7 @@ import type { ViewTypes, SAPUI5_FRAGMENT_CLASS, SAPUI5_VIEW_CLASS } from '../../
4
4
  * Section
5
5
  * @isViewNode true
6
6
  */
7
- export interface ObjectPageSection {
7
+ export interface ObjectPageSectionV2 {
8
8
  /**
9
9
  * Whether the section should be visible on the screen.
10
10
  */
@@ -14,39 +14,74 @@ export interface ObjectPageSection {
14
14
  * Form
15
15
  * @isViewNode true
16
16
  */
17
- export interface ObjectPageSectionFormV2 extends ObjectPageSection {
17
+ export interface ObjectPageSectionFormV2 extends ObjectPageSectionV2 {
18
18
  form?: ObjectPageForm;
19
19
  }
20
+ export declare type AnyObjectPageTableType = ObjectPageResponsiveTableWithMultiSelect | ObjectPageResponsiveTableWithInlineDelete | ObjectPageAnalyticalTable | ObjectPageGridTable | ObjectPageTreeTable;
20
21
  /**
21
22
  * Table
22
23
  * @isViewNode true
23
24
  */
24
- export interface ObjectPageSectionTableV2 extends ObjectPageSection {
25
- table?: ObjectPageResponsiveTableWithMultiSelect | ObjectPageResponsiveTableWithInlineDelete | ObjectPageAnalyticalTable | ObjectPageGridTable | ObjectPageTreeTable;
25
+ export interface ObjectPageSectionTableV2 extends ObjectPageSectionV2 {
26
+ table?: AnyObjectPageTableType;
26
27
  }
27
28
  /**
28
29
  * Chart
29
30
  * @isViewNode true
30
31
  */
31
- export interface ObjectPageSectionChartV2 extends ObjectPageSection {
32
+ export interface ObjectPageSectionChartV2 extends ObjectPageSectionV2 {
32
33
  chart?: ObjectPageChart;
33
34
  }
35
+ export interface ObjectPageSectionContactV2 extends ObjectPageSectionV2 {
36
+ /**
37
+ * Contact
38
+ * @isViewNode true
39
+ */
40
+ contact?: object;
41
+ }
42
+ export interface ObjectPageSectionAddressV2 extends ObjectPageSectionV2 {
43
+ /**
44
+ * Address
45
+ * @isViewNode true
46
+ */
47
+ address?: object;
48
+ }
49
+ export interface ObjectPageSubSectionContactV2 extends ObjectPageSectionV2 {
50
+ /**
51
+ * Contact
52
+ * @isViewNode true
53
+ */
54
+ contact?: object;
55
+ }
56
+ export interface ObjectPageSubSectionAddressV2 extends ObjectPageSectionV2 {
57
+ /**
58
+ * Address
59
+ * @isViewNode true
60
+ */
61
+ address?: object;
62
+ }
63
+ export declare type AnySubSectionType = ObjectPageSectionTableV2 | ObjectPageSectionChartV2 | ObjectPageSectionFormV2 | ObjectPageSubSectionContactV2 | ObjectPageSubSectionAddressV2;
64
+ export interface GenericSubSections {
65
+ [key: string]: AnySubSectionType;
66
+ }
34
67
  /**
35
68
  * Subsection
36
69
  * @isViewNode true
37
70
  */
38
- export interface ObjectPageSubSectionV2 extends ObjectPageSection {
39
- subsections?: object;
71
+ export interface ObjectPageSubSectionV2 extends ObjectPageSectionV2 {
72
+ subsections?: GenericSubSections;
40
73
  }
74
+ export declare type AnySectionType = ObjectPageSectionTableV2 | ObjectPageSectionChartV2 | ObjectPageSectionFormV2 | ObjectPageSectionContactV2 | ObjectPageSectionAddressV2 | ObjectPageSectionV2 | ObjectPageSubSectionV2;
41
75
  export interface GenericSections {
42
- [key: string]: ObjectPageSectionTableV2 | ObjectPageSectionChartV2 | ObjectPageSectionFormV2 | ObjectPageSubSectionV2;
76
+ [key: string]: AnySectionType;
43
77
  }
78
+ export declare type CustomSectionTypeV2 = ObjectPageCustomSectionView | ObjectPageCustomSectionFragment;
44
79
  /**
45
80
  * Custom Sections
46
81
  * @isViewNode true
47
82
  */
48
83
  export interface CustomSections {
49
- custom?: (ObjectPageCustomSectionView | ObjectPageCustomSectionFragment)[];
84
+ custom?: CustomSectionTypeV2[];
50
85
  }
51
86
  export interface ObjectPageCustomSectionBase {
52
87
  relatedFacet: string;
@@ -1,6 +1,8 @@
1
- /// <reference types="@sapui5/ts-types" />
1
+ /// <reference types="@sapui5/ts-types-esm" />
2
2
  import type { GenericColumns, TableTypeV2, QuickVariant } from './Table';
3
3
  import type { ObjectPageToolBar } from './ObjectPageToolBar';
4
+ import type { PopinLayout } from 'sap/m/library';
5
+ import type { smarttable } from 'sap/ui/comp/library';
4
6
  export interface QuickVariantSelectionOP {
5
7
  /**
6
8
  * To show the number of records available, set showCounts to true.
@@ -53,7 +55,7 @@ export interface ObjectPageCommonTableSettings<COLS = GenericColumns> {
53
55
  /**
54
56
  * Specifies the type of export to be used in the SmartTable control. UI5Client is the default option.
55
57
  */
56
- exportType?: sap.ui.comp.smarttable.ExportType;
58
+ exportType?: smarttable.ExportType;
57
59
  /**
58
60
  * Use createMode 'inline' to enable inline creation of table entries for draft enabled applications.
59
61
  */
@@ -90,7 +92,7 @@ export interface ObjectPageResponsiveTableCommonSettings extends ObjectPageCommo
90
92
  /**
91
93
  * popinLayout defines the layout in which the table pop-in rows shall be rendered.
92
94
  */
93
- popinLayout?: sap.m.PopinLayout;
95
+ popinLayout?: PopinLayout;
94
96
  /**
95
97
  * growingThreshold defines the number of items to be requested from the model for each grow. This property can only be used if the growing property is set to true.
96
98
  */
@@ -1,7 +1,10 @@
1
- /// <reference types="@sapui5/ts-types" />
1
+ /// <reference types="@sapui5/ts-types-esm" />
2
2
  import type { SAPUI5_FRAGMENT_CLASS } from '../../common/webapp/manifest/sapUi5';
3
3
  import type { ToolBar } from './ToolBar';
4
4
  import type { Action } from './Action';
5
+ import type { PopinLayout } from 'sap/m/library';
6
+ import type { smarttable } from 'sap/ui/comp/library';
7
+ import type { TextAlign } from 'sap/ui/core/library';
5
8
  /**
6
9
  * Column
7
10
  * @isViewNode true
@@ -14,7 +17,7 @@ export interface TableColumn {
14
17
  /**
15
18
  * The hAlign property defines the horizontal alignment of the column content.
16
19
  */
17
- hAlign?: sap.ui.core.TextAlign;
20
+ hAlign?: TextAlign;
18
21
  }
19
22
  /**
20
23
  * Column Action
@@ -219,7 +222,7 @@ export interface CommonTableSettings<COLS = GenericColumns> {
219
222
  /**
220
223
  * Specifies the type of export to be used in the SmartTable control. UI5Client is the default option.
221
224
  */
222
- exportType?: sap.ui.comp.smarttable.ExportType;
225
+ exportType?: smarttable.ExportType;
223
226
  /**
224
227
  * Set to false if the table does not occupy the entire space available in the container.
225
228
  */
@@ -267,7 +270,7 @@ export interface ResponsiveTableCommonSettings extends CommonTableSettings {
267
270
  /**
268
271
  * popinLayout defines the layout in which the table pop-in rows are rendered.
269
272
  */
270
- popinLayout?: sap.m.PopinLayout;
273
+ popinLayout?: PopinLayout;
271
274
  /**
272
275
  * createWithFilters adds a new create action that uses the filter settings as input.
273
276
  */
@@ -36,7 +36,7 @@ export interface TableCreationMode {
36
36
  */
37
37
  name?: TableCreationModeType;
38
38
  /**
39
- * In case of inline creation mode you can decide if the new row will be created at the end of the table, or direcly after the currently selected table. The default value is "true"
39
+ * In case of inline creation mode you can decide if the new row will be created at the end of the table, or directly after the currently selected table. The default value is "true"
40
40
  */
41
41
  createAtEnd?: boolean;
42
42
  }
@@ -50,7 +50,7 @@ export interface ViewTableCreationMode {
50
50
  */
51
51
  name?: TableCreationModeType;
52
52
  /**
53
- * In case of inline creation mode you can decide if the new row will be created at the end of the table, or direcly after the currently selected table. The default value is "true"
53
+ * In case of inline creation mode you can decide if the new row will be created at the end of the table, or directly after the currently selected table. The default value is "true"
54
54
  */
55
55
  createAtEnd?: boolean;
56
56
  }
@@ -13,7 +13,7 @@ export interface ListReportConfig extends PageConfig {
13
13
  */
14
14
  variantManagement?: VariantManagementTypeListReport;
15
15
  /**
16
- * Filter bar
16
+ * Filter Bar
17
17
  */
18
18
  filterBar?: FilterBar;
19
19
  /**
@@ -17,7 +17,7 @@ export declare abstract class AppProvider {
17
17
  * Create config files for app (app.json) and pages (pages/{name}.json).
18
18
  * This is basically a copy of createFiles optimized to be used in FTFS:
19
19
  * it always uses posix path notation with forward slash (/)
20
- * @param {ConverterOutput} oDataServiceAVT - Complete service information, as returned by annotation vocabularies tool
20
+ * @param {ConvertedMetadata} oDataServiceAVT - Complete service information, as returned by annotation vocabularies tool
21
21
  * @returns app and page files as separate objects
22
22
  */
23
23
  createConfigFiles(): {
@@ -35,7 +35,7 @@ export declare enum BindingValue {
35
35
  * @param controlType - controlType function of ecorators, not used here
36
36
  * @param title - title from JSON schema, comprising the facet ID
37
37
  */
38
- export declare const buildColumnControlId: (baseId: string, idBreadcrumbs: string[], breadcrumbs: string[], controlType: ControlTypeFunction, title: string) => string;
38
+ export declare const buildColumnControlId: (baseId: string, idBreadcrumbs: string[], breadcrumbs: string[], _controlType: ControlTypeFunction, title: string) => string;
39
39
  /**
40
40
  * Split up action breadcrumb and return different parts from it
41
41
  * @param breadcrumbs - array of breadcrumbs
@@ -2,11 +2,11 @@ import 'reflect-metadata';
2
2
  import type { SyncRule, PageLayoutInformation, ValidityInformation } from '../types';
3
3
  export declare const reflectMetadataKey: unique symbol;
4
4
  export declare const syncRule: (propSpec: SyncRule) => any;
5
- export declare function getReflectMetadata(target: any, propertyName: string): SyncRule;
5
+ export declare function getReflectMetadata(target: object, propertyName: string): SyncRule | undefined;
6
6
  export declare const pageLayoutInformation: (pageInfo: PageLayoutInformation) => (constructor: Function) => void;
7
7
  export declare const childId: (id: string) => any;
8
8
  export declare const getChildId: (target: any, propertyName: string) => string;
9
9
  export declare const getPageLayoutInformation: (target: any) => PageLayoutInformation;
10
10
  export declare const validityMetadataKey: unique symbol;
11
11
  export declare const validity: (propSpec: ValidityInformation) => any;
12
- export declare function getTextForDeprecated(key: string, validity?: ValidityInformation): string;
12
+ export declare function getTextForDeprecated(key: string, validityInformation?: ValidityInformation): string;
@@ -1,8 +1,7 @@
1
- import type { ConverterOutput, EntityType } from '@sap-ux/vocabularies-types';
1
+ import type { ConvertedMetadata, EntitySet, EntityType } from '@sap-ux/vocabularies-types';
2
2
  import { FioriElementsVersion } from '../../../specification/common';
3
3
  import type { FacetConfig } from '..';
4
4
  import { SectionType } from '..';
5
- import type { EntitySet } from '@sap-ux/annotation-converter';
6
5
  import type { Definition } from 'typescript-json-schema';
7
6
  /**
8
7
  * Adds definitions for forms in object page sections to the app schema
@@ -16,10 +15,10 @@ export declare function handleForm(sectionType: SectionType, section: FacetConfi
16
15
  /**
17
16
  * Replaces an alias in an annotation ID or reference, based on the AVT references' list
18
17
  * @param annotationIdentifier - annotation ID or reference
19
- * @param {ConverterOutput} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
18
+ * @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
20
19
  * @returns the converted string
21
20
  */
22
- export declare function replaceAlias(annotationIdentifier: string, oDataServiceAVT: ConverterOutput): string;
21
+ export declare function replaceAlias(annotationIdentifier: string, oDataServiceAVT: ConvertedMetadata): string;
23
22
  /**
24
23
  * Common routine to determine the name and the ID of a header action
25
24
  * @param action - action as given by AVT
@@ -35,16 +34,16 @@ export declare function getActionNameAndId(action: string, entityType: EntityTyp
35
34
  *
36
35
  * @param {object} appSchema Schema of the app
37
36
  * @param {EntityType} entityType - current entity type
38
- * @param {ConverterOutput} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
37
+ * @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
39
38
  */
40
- export declare function addFooterActions(appSchema: Definition, entityType: EntityType, oDataServiceAVT: ConverterOutput): void;
39
+ export declare function addFooterActions(appSchema: Definition, entityType: EntityType, oDataServiceAVT: ConvertedMetadata): void;
41
40
  /**
42
41
  * Add Object Page Header Action Buttons to app-specific schema
43
42
  * @param {object} appSchema Schema of the app
44
43
  * @param {EntityType} entityType - current entity type
45
- * @param {ConverterOutput} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
44
+ * @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
46
45
  */
47
- export declare function addHeaderActions(appSchema: Definition, entityType: EntityType, oDataServiceAVT: ConverterOutput, addHeaderActionCallBack: any): void;
46
+ export declare function addHeaderActions(appSchema: Definition, entityType: EntityType, oDataServiceAVT: ConvertedMetadata, addHeaderActionCallBack: any): void;
48
47
  /**
49
48
  * Adds common Object Page Header definitions to the app schema
50
49
  * @param appSchema - app-specific JSOn schema
@@ -57,4 +56,4 @@ export declare function addCommonHeaderSchema(appSchema: Definition, entityType:
57
56
  * @param serviceAVT - AVT converter output, comprising all annotation information
58
57
  * @returns the entity set as defined in AVT, if found
59
58
  */
60
- export declare function determineEntitySetOfFacet(facet: FacetConfig, serviceAVT: ConverterOutput): EntitySet | undefined;
59
+ export declare function determineEntitySetOfFacet(facet: FacetConfig, serviceAVT: ConvertedMetadata): EntitySet | undefined;
@@ -1,10 +1,10 @@
1
- import type { EntitySet, EntityType } from '@sap-ux/annotation-converter';
2
- import type { AnnotationTerm, ConverterOutput, LineItem } from '@sap-ux/vocabularies-types';
1
+ import type { AnnotationTerm, ConvertedMetadata, EntitySet, EntityType } from '@sap-ux/vocabularies-types';
2
+ import type { LineItem } from '@sap-ux/vocabularies-types/vocabularies/UI';
3
3
  import type { Definition } from 'typescript-json-schema';
4
- import type { FacetConfig, FacetSection } from '..';
4
+ import type { FacetConfig, FacetSection, SectionType } from '..';
5
5
  import type { SectionTypeV2 } from '../../v2/types';
6
6
  import type { PresentationVariantV4 } from '../../v4/types';
7
- import { UIAnnotationTerms } from '@sap-ux/vocabularies-types';
7
+ import { UIAnnotationTerms } from '@sap-ux/vocabularies-types/vocabularies/UI';
8
8
  import { DefinitionName } from '..';
9
9
  /**
10
10
  * Adds an enum filled with existing UI annotations of the given list (validAnnotations)
@@ -29,11 +29,11 @@ export declare function addEnumForSingleTabVariant(entityType: EntityType, appSc
29
29
  export declare function addEnumForMultiTabVariant(appSchema: Definition, definitionName: string, entitySet: EntitySet): void;
30
30
  /**
31
31
  * Adds the enum values for entitySet as part of the multiple view scenario
32
- * @param {ConverterOutput} oDataServiceAVT - combined service metadata, as returned by annotation vocabularies tools
32
+ * @param {ConvertedMetadata} oDataServiceAVT - combined service metadata, as returned by annotation vocabularies tools
33
33
  * @param appSchema - app specific JSOn schema
34
34
  * @param definitionName - name of the definition in the app schema
35
35
  */
36
- export declare function addEnumForVariantEntitySet(oDataServiceAVT: ConverterOutput, appSchema: Definition, definitionName: string): void;
36
+ export declare function addEnumForVariantEntitySet(oDataServiceAVT: ConvertedMetadata, appSchema: Definition, definitionName: string): void;
37
37
  /**
38
38
  * Adds an enum filled with existing UI annotations for annotationPath property in FilterBar
39
39
  * @param {EntityType} entityType
@@ -54,7 +54,7 @@ export declare function addDefinitionForRelatedFacetKeys(appSchema: Definition,
54
54
  * Functions used both by V2 and V4 to add the common definitions for a line item to the app schema
55
55
  * @param appSchema - the app specific schema that shall get enhanced
56
56
  * @param lineItemAnnotation - the UI.LineItem annotation, comprising all records
57
- * @param entityType - the entity type as part of the AVT ConverterOutput
57
+ * @param entityType - the entity type as part of the AVT ConvertedMetadata
58
58
  * @param lineItemId - line item ID, as comprise in stable ID
59
59
  * @param customColumnDefinitionName - (optional) definition name of custom column.
60
60
  * Passed in the V4 case, then additional properties of this type will be allowed.
@@ -116,19 +116,37 @@ export declare function getFacetKeyInSchema(facetKey: string): string;
116
116
  * @param facetKey - key of the facet, as used in annotation
117
117
  * @param {Definition} appSchema App schema in general
118
118
  * @param {boolean} useDefinitionAsKey If set to false, facet key will solely be used as key, else encapsulated within definition key `definition<facetKey>`
119
+ * @param subDefinitionName - sub definition, if different from the definition (e.g. subsection vs. section)
119
120
  * @returns {Definition} part of app schema that has been added and filled
120
121
  */
121
- export declare function parseSchemaDefinition(definition: DefinitionName | SectionTypeV2, facetKey: string, appSchema: Definition, useDefinitionAsKey?: boolean): Definition;
122
+ export declare function parseSchemaDefinition(definition: DefinitionName | SectionTypeV2, facetKey: string, appSchema: Definition, useDefinitionAsKey?: boolean, subDefinitionName?: DefinitionName): Definition;
122
123
  /**
123
124
  * Creates a definition link for a facet and definition name
124
- * @param definition name of definition, as used in schema
125
- * @param facetKey - key of the facet, as used in annotation
125
+ * @param {DefinitionName} definition - name of definition, as used in schema
126
+ * @param {string} facetKey - key of the facet, as used in annotation
126
127
  * @returns definition link of facet, as used in definition
127
128
  */
128
129
  export declare function getFacetDefinitionLink(definition: DefinitionName | SectionTypeV2, facetKey: string): string;
130
+ /**
131
+ * Creates and adds a reference link to a definition
132
+ * @param {Definition} schemaPart - part of schema to add $ref to
133
+ * @param {string} schemaRef - reference to be added
134
+ * @param {string} schemaKey - key to be encapsulated within reference as `schemaRef<schemaKey>`
135
+ * @returns reference link of facet, as used in definition
136
+ */
137
+ export declare function addDefinitionRef(schemaPart: Definition, schemaRef: string, schemaKey?: string): void;
129
138
  /**
130
139
  * Extracts annotationPath from facet or Chart/LineItem fullyQualifiedName
131
140
  * @param facet facet or Chart/LineItem
132
141
  * @returns {string} annotationPath
133
142
  */
134
143
  export declare function getFacetAnnotationPath(facet: FacetConfig | PresentationVariantV4 | object): string | undefined;
144
+ /**
145
+ * Adds definitions for Address and Contact items in object page sections to the app schema
146
+ * @param {FacetConfig} facet - current facet.
147
+ * @param {string} facetKey - facet key.
148
+ * @param {object} sections - schema of current sections definition.
149
+ * @param {object} appSchema - app specific schema that potentially gets enhanced.
150
+ * @param {SectionType} sectionPrefix - prefix to distinguish Section and HeaderSection
151
+ */
152
+ export declare function handleAddressContact(facet: FacetConfig, facetKey: string, sections: Definition, appSchema: Definition, sectionPrefix: SectionType, subSectionPrefix?: SectionType, versionPostfix?: string): void;
@@ -1,5 +1,6 @@
1
1
  import type { DeprecatedProperties, SyncRule } from '../';
2
2
  import type { ExtensionLogger } from '../../../apiTypes';
3
+ import type { Definition } from 'typescript-json-schema';
3
4
  /**
4
5
  * Transfers the value of a single manifest setting to the config
5
6
  * @param syncRule - Metadata rule
@@ -22,11 +23,11 @@ export declare function importProperty(syncRule: SyncRule, manifestSection: {},
22
23
  */
23
24
  export declare function checkDeprecatedProperties(deprecatedProperties: DeprecatedProperties | undefined, manifestSection: {}, path: string, logger?: ExtensionLogger): void;
24
25
  /**
25
- * get title of the section (Facet ID)
26
+ * Determines the title of a section representation in the app schema, main aspect is checking the facet ID
26
27
  * @param schemaSection - Section in manifest.json
27
28
  * @param jsonSchema - app specific schema
28
29
  */
29
- export declare function getSectionTitle(schemaSection: object, jsonSchema: object): string;
30
+ export declare function getSectionTitle(schemaSection: Definition, jsonSchema: Definition): string | undefined;
30
31
  /**
31
32
  * Method returns target by resolving custom column reference name.
32
33
  * For example - 'TableCustomColumns<dummyTarget>' is resolved as 'dummyTarget'.
@@ -34,3 +35,9 @@ export declare function getSectionTitle(schemaSection: object, jsonSchema: objec
34
35
  * @returns {string | undefined} Resolved target.
35
36
  */
36
37
  export declare function getTargetFromCustomColumnRef(ref: string): string | undefined;
38
+ /**
39
+ * Removes part of a given config, if empty
40
+ * @param {object} config - config part
41
+ * @param {string} structure - part of config to be removed
42
+ */
43
+ export declare function removeEmptyStructure(config: object, structure: string): void;
@@ -1,8 +1,7 @@
1
- import type { ConverterOutput } from '@sap-ux/vocabularies-types';
2
- import type { EntitySet } from '@sap-ux/vocabularies-types/dist/Converter';
1
+ import type { ConvertedMetadata, EntitySet } from '@sap-ux/vocabularies-types';
3
2
  import type { ImportProjectParameters } from '../../apiTypes';
4
3
  import type { File } from './types';
5
- export declare function getEntitySetByEntitySetName(entitySetName: string, oDataServiceAVT: ConverterOutput): EntitySet;
4
+ export declare function getEntitySetByEntitySetName(entitySetName: string, oDataServiceAVT: ConvertedMetadata): EntitySet;
6
5
  /**
7
6
  * Import the schema and config files for a given project
8
7
  * @param {ImportProjectParameters} importParameters - files of the project: manifest, flex changes, odata files
@@ -1,5 +1,6 @@
1
1
  import type { Manifest } from '../../specification/common/webapp/manifest';
2
- import type { AnnotationTerm, CollectionFacet, EntityType, ReferenceFacet, ReferenceURLFacet } from '@sap-ux/vocabularies-types';
2
+ import type { AnnotationTerm, EntityType } from '@sap-ux/vocabularies-types';
3
+ import type { CollectionFacet, ReferenceFacet, ReferenceURLFacet } from '@sap-ux/vocabularies-types/vocabularies/UI';
3
4
  import type { ManifestSettingsType } from '../../specification/common/types';
4
5
  export declare type anyFacetType = AnnotationTerm<CollectionFacet> | AnnotationTerm<ReferenceFacet> | AnnotationTerm<ReferenceURLFacet>;
5
6
  export declare enum ExportArtifacts {
@@ -36,6 +37,7 @@ export interface ExportResults {
36
37
  }
37
38
  export declare enum SectionType {
38
39
  Section = "Section",
40
+ SubSection = "SubSection",
39
41
  HeaderSection = "HeaderSection"
40
42
  }
41
43
  export declare enum ArtifactType {
@@ -181,6 +183,7 @@ export interface FacetConfig {
181
183
  entityType?: EntityType;
182
184
  annotationPath?: string;
183
185
  target?: object;
186
+ facets?: FacetConfigs;
184
187
  }
185
188
  export interface SubSectionConfig {
186
189
  base: FacetBase;
@@ -239,8 +242,10 @@ export declare enum DefinitionName {
239
242
  CustomColumns = "TableCustomColumns",
240
243
  CustomSections = "CustomSections",
241
244
  FieldPath = "FieldPath",
245
+ Field = "Field",
242
246
  Fields = "Fields",
243
247
  Fields4Dialog = "Fields4Dialog",
248
+ FilterBar = "FilterBar",
244
249
  Footer = "Footer",
245
250
  FooterActions = "FooterActions",
246
251
  Form = "Form",
@@ -299,7 +304,8 @@ export declare enum DefinitionName {
299
304
  ViewTableColumn = "ViewTableColumn",
300
305
  ViewCustomColumn = "ViewTableCustomColumn",
301
306
  ViewChartToolBar = "ViewChartToolBar",
302
- ViewToolBarAction = "ViewToolBarAction"
307
+ ViewToolBarAction = "ViewToolBarAction",
308
+ ViewPosition = "ViewPosition"
303
309
  }
304
310
  export declare enum PropertyName {
305
311
  actions = "actions",
@@ -315,6 +321,7 @@ export declare enum SchemaTag {
315
321
  annotationPath = "annotationPath",
316
322
  annotationType = "annotationType",
317
323
  artifactType = "artifactType",
324
+ controlType = "controlType",
318
325
  dataType = "dataType",
319
326
  fullyQualifiedName = "fullyQualifiedName",
320
327
  hidden = "hidden",
@@ -3,9 +3,11 @@ import type { ExtensionLogger } from '../../apiTypes';
3
3
  import type { FacetConfigs, FileData, FacetConfig, FacetSection, SchemaFilePath, anyFacetType } from './types';
4
4
  import type { Manifest } from '../../specification/common';
5
5
  import type { MetadataInstanceInterface } from './decoration/factory';
6
- import type { ConverterOutput, DataFieldAbstractTypes, EntityType, PropertyAnnotations, PropertyPath } from '@sap-ux/vocabularies-types';
6
+ import type { DataFieldAbstractTypes } from '@sap-ux/vocabularies-types/vocabularies/UI';
7
+ import type { ConvertedMetadata, EntityType, PropertyPath } from '@sap-ux/vocabularies-types';
7
8
  import { FioriElementsVersion, PageType, PageTypeV4 } from '../../specification/common';
8
9
  import { SchemaType } from '../../specification/schemaAccess';
10
+ import type { PropertyAnnotations } from '@sap-ux/vocabularies-types/vocabularies/Edm_Types';
9
11
  export declare enum TemplateType {
10
12
  ListReportObjectPageV2 = "ListReportObjectPageV2",
11
13
  ListReportObjectPageV4 = "ListReportObjectPageV4",
@@ -27,7 +29,7 @@ export declare const createAnnotationPath: (entityTypeName: string, term: string
27
29
  * @param annotationFiles - The list of all annotation files, in JSON format
28
30
  * @returns the complete service information
29
31
  */
30
- export declare function parseAndMergeAndConvert(annotationFiles: FileData[], logger: ExtensionLogger): ConverterOutput;
32
+ export declare function parseAndMergeAndConvert(annotationFiles: FileData[], logger: ExtensionLogger): ConvertedMetadata;
31
33
  export declare const getAnnotationPropertyValue: (annotationProperty: any) => string;
32
34
  /**
33
35
  * Checks for Common.Label and overwrites the label from it if present
@@ -53,7 +55,7 @@ export declare function getLabelForDataField(field: DataFieldAbstractTypes, enti
53
55
  /**
54
56
  * Determines the description of a data field, e.g. for the column header
55
57
  * @param dataFieldAbstract - the given record of the line item annotation
56
- * @param entityType - the entity type as part of the AVT ConverterOutput
58
+ * @param entityType - the entity type as part of the AVT ConvertedMetadata
57
59
  */
58
60
  export declare function getDataFieldDescription(dataFieldAbstract: DataFieldAbstractTypes, entityType: EntityType): string;
59
61
  /**
@@ -75,24 +77,24 @@ export declare function getPageTypeV4(name: string): PageTypeV4 | undefined;
75
77
  /**
76
78
  * Finds the alias for a given namespace in the references' section of the converted service metadata
77
79
  * @param {string} namespace - complete namespace, e.g. 'com.sap.vocabularies.UI.v1'
78
- * @param {ConverterOutput} oDataServiceAVT - combined service metadata, as returned by annotation vocabularies tools
80
+ * @param {ConvertedMetadata} oDataServiceAVT - combined service metadata, as returned by annotation vocabularies tools
79
81
  * @returns alias for the given namespace
80
82
  */
81
- export declare function findAlias(namespace: string, oDataServiceAVT: ConverterOutput): string;
83
+ export declare function findAlias(namespace: string, oDataServiceAVT: ConvertedMetadata): string;
82
84
  /**
83
85
  * Resolve page section(get key and label->description).
84
86
  * @param facetDefinition - the actual annotation record
85
87
  * @param keyForRelatedFacetKeys - construct key for 'keyForRelatedFacetKeys' property(used to define custom sections) - we should not add '@' symbol there.
86
88
  * @param {FioriElementsVersion} oDataVersion - OData version
87
- * @param {ConverterOutput} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
89
+ * @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
88
90
  * @param {ExtensionLogger} logger - Logger class for logging messages
89
91
  * @returns {FacetSection} - object comprising the relevant facet information
90
92
  */
91
- export declare function getSectionFacet(facetDefinition: anyFacetType, sourceEntityType: EntityType, oDataServiceAVT: ConverterOutput, logger?: ExtensionLogger, oDataVersion?: FioriElementsVersion, keyForRelatedFacetKeys?: boolean): FacetSection | undefined;
93
+ export declare function getSectionFacet(facetDefinition: anyFacetType, sourceEntityType: EntityType, oDataServiceAVT: ConvertedMetadata, logger?: ExtensionLogger, oDataVersion?: FioriElementsVersion, keyForRelatedFacetKeys?: boolean): FacetSection | undefined;
92
94
  /**
93
95
  * Finds the alias for a given namespace in the references' section of the converted service metadata.
94
96
  * An empty object is created if the path element does not exist yet.
95
- * Exception: if an empty array is the next element of the 'path' definition, an empty array is created instaed of an empty object.
97
+ * Exception: if an empty array is the next element of the 'path' definition, an empty array is created instead of an empty object.
96
98
  * @param {object} manifest - manifest that is being modified during export
97
99
  * @param {string} path - path of the property in the manifest
98
100
  * @param {string} targetAnnotation - target annotation (optional)
@@ -105,19 +107,19 @@ export declare function getSchemaKeyOfLineItemRecord(lineItemRecord: DataFieldAb
105
107
  /**
106
108
  * Retrieve header facet configurations that can be used to generate ObjectPage schemas
107
109
  * @param {QualifiedName} entityTypeName - the name of the actual entity type
108
- * @param {ConverterOutput} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
110
+ * @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
109
111
  * @param {FioriElementsVersion} oDataVersion - OData version
110
112
  * @param {ExtensionLogger} logger - Logger class for logging messages
111
113
  */
112
- export declare function getObjectPageHeaderFacets(entityType: EntityType, oDataServiceAVT: ConverterOutput, oDataVersion?: FioriElementsVersion, logger?: ExtensionLogger): FacetConfigs | undefined;
114
+ export declare function getObjectPageHeaderFacets(entityType: EntityType, oDataServiceAVT: ConvertedMetadata, oDataVersion?: FioriElementsVersion, logger?: ExtensionLogger): FacetConfigs | undefined;
113
115
  /**
114
116
  * Retrieve facet configurations that can be used to generate ObjectPage schemas
115
117
  * @param {QualifiedName} entityTypeName - the name of the actual entity type
116
- * @param {ConverterOutput} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
118
+ * @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
117
119
  * @param {FioriElementsVersion} oDataVersion - OData version
118
120
  * @param {ExtensionLogger} logger - Logger class for logging messages
119
121
  */
120
- export declare function getObjectPageFacets(entityType: EntityType, oDataServiceAVT: ConverterOutput, oDataVersion?: FioriElementsVersion, logger?: ExtensionLogger): FacetConfigs | undefined;
122
+ export declare function getObjectPageFacets(entityType: EntityType, oDataServiceAVT: ConvertedMetadata, oDataVersion?: FioriElementsVersion, logger?: ExtensionLogger): FacetConfigs | undefined;
121
123
  /**
122
124
  * Returns the version of Fiori elements (v2/v4) from a given manifest
123
125
  * @param manifest - the manifest.json file
@@ -158,23 +160,23 @@ export declare function addSectionTitleAndDescription(facet: FacetConfig, sectio
158
160
  * @param section - section in the app schema
159
161
  * @param facetKey - key of the facet
160
162
  */
161
- export declare function addTargetTitleAndSectionDescription(facet: FacetConfig, section: object, facetKey: string): void;
163
+ export declare function addTargetTitleAndSectionDescription(facet: FacetConfig, section: Definition, facetKey: string): void;
162
164
  /**
163
165
  * Creates a default object for a new section or subsection, and adds the ID as title if present.
164
166
  * @param facet Facet configuration, to be analyzed
165
167
  * @returns the new section object
166
168
  */
167
- export declare function createSectionWithoutProperties(facet: FacetConfig, facetKey: string): Definition;
169
+ export declare function createDefaultSection(appSchema: Definition, facet: FacetConfig, facetKey: string): Definition;
168
170
  /**
169
171
  * Retrieve page section data(so far id/key and label/description).
170
172
  * @param {EntityType} entityType The actual entityType
171
- * @param {ConverterOutput} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
173
+ * @param {ConvertedMetadata} oDataServiceAVT - complete service information, as returned by annotation vocabularies tool
172
174
  * @param {ExtensionLogger} logger - Logger class for logging messages
173
175
  * @param {FioriElementsVersion} oDataVersion - OData version
174
176
  * @param {boolean} [checkUnresolvableFacets=false] - Check and avoid facets and sections without ID and Target.
175
177
  * @returns {FacetSection[]} - Array of facets or sections
176
178
  */
177
- export declare function getObjectPageFacetSection(entityType: EntityType, oDataServiceAVT: ConverterOutput, logger?: ExtensionLogger, oDataVersion?: FioriElementsVersion, checkUnresolvableFacets?: boolean): FacetSection[];
179
+ export declare function getObjectPageFacetSection(entityType: EntityType, oDataServiceAVT: ConvertedMetadata, logger?: ExtensionLogger, oDataVersion?: FioriElementsVersion, checkUnresolvableFacets?: boolean): FacetSection[];
178
180
  /**
179
181
  * Cleans empty sub-structures from the export result for manifest
180
182
  * @param manifest - manifest.json part of the export result
@@ -206,7 +208,7 @@ export declare type NextDefinition = {
206
208
  };
207
209
  /**
208
210
  * Recursive function to determine the next config part, next definition in the app schema and the title
209
- * @param appSchema - app-spcific JSON schema
211
+ * @param appSchema - app-specific JSON schema
210
212
  * @param title - default title
211
213
  * @param currentConfigObject - current part of the configuration that gets traversed
212
214
  * @param propertyDefinition - definition of a given property in the app schema