@openui5/ts-types 1.117.1 → 1.119.0

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.
@@ -1,4 +1,4 @@
1
- // For Library Version: 1.117.1
1
+ // For Library Version: 1.119.0
2
2
 
3
3
  declare namespace sap {
4
4
  interface IUI5DefineDependencyNames {
@@ -1,4 +1,4 @@
1
- // For Library Version: 1.117.1
1
+ // For Library Version: 1.119.0
2
2
 
3
3
  declare namespace sap {
4
4
  namespace ui {
@@ -5444,25 +5444,6 @@ declare namespace sap {
5444
5444
  */
5445
5445
  sSecondaryCalendarType: sap.ui.core.CalendarType
5446
5446
  ): this;
5447
- /**
5448
- * @deprecated (since 1.34.0) - replaced by `date` property
5449
- *
5450
- * Sets a new value for property {@link #getYear year}.
5451
- *
5452
- * The year is initial focused and selected The value must be between 0 and 9999
5453
- *
5454
- * When called with a value of `null` or `undefined`, the default value of the property will be restored.
5455
- *
5456
- * Default value is `2000`.
5457
- *
5458
- * @returns Reference to `this` in order to allow method chaining
5459
- */
5460
- setYear(
5461
- /**
5462
- * New value for property `year`
5463
- */
5464
- iYear?: int
5465
- ): this;
5466
5447
  /**
5467
5448
  * @since 1.30.0
5468
5449
  *
@@ -1,4 +1,4 @@
1
- // For Library Version: 1.117.1
1
+ // For Library Version: 1.119.0
2
2
 
3
3
  declare namespace sap {
4
4
  namespace ui {
@@ -1,4 +1,4 @@
1
- // For Library Version: 1.117.1
1
+ // For Library Version: 1.119.0
2
2
 
3
3
  declare namespace sap {
4
4
  namespace ui {
@@ -16,10 +16,20 @@ declare namespace sap {
16
16
  * UI5 library: sap.ui.webc.common
17
17
  */
18
18
  namespace common {
19
- interface $WebComponentSettings extends sap.ui.core.$ControlSettings {}
19
+ namespace WebComponent {
20
+ /**
21
+ * The structure of the "metadata" object which is passed when inheriting from sap.ui.core.Element using
22
+ * its static "extend" method. See {@link sap.ui.core.Element.extend} for details on its usage.
23
+ */
24
+ type MetadataOptions = sap.ui.core.webc.WebComponent.MetadataOptions;
25
+ }
26
+
27
+ interface $WebComponentSettings
28
+ extends sap.ui.core.webc.$WebComponentSettings {}
20
29
 
21
30
  /**
22
31
  * @since 1.92.0
32
+ * @deprecated (since 1.118.0) - Use sap.ui.core.webc.WebComponent instead!
23
33
  * @experimental (since 1.92.0) - The API might change. It is not intended for productive usage yet!
24
34
  *
25
35
  * Base Class for Web Components. Web Components are agnostic UI elements which can be integrated into the
@@ -27,27 +37,76 @@ declare namespace sap {
27
37
  * properties, the aggregations and the events. It also ensures to render the control and put the aggregated
28
38
  * controls in the dedicated slots of the Web Component.
29
39
  */
30
- class WebComponent extends sap.ui.core.Control {
40
+ class WebComponent extends sap.ui.core.webc.WebComponent {
31
41
  /**
32
42
  * Constructs and initializes a Web Component Wrapper with the given `sId` and settings.
33
- *
34
- * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated
35
- * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description
36
- * of the syntax of the settings object.
37
43
  */
38
- constructor();
44
+ constructor(
45
+ /**
46
+ * Object with initial settings for the new control
47
+ */
48
+ mSettings?: sap.ui.webc.common.$WebComponentSettings
49
+ );
50
+ /**
51
+ * Constructs and initializes a Web Component Wrapper with the given `sId` and settings.
52
+ */
53
+ constructor(
54
+ /**
55
+ * Optional ID for the new control; generated automatically if no non-empty ID is given Note: this can be
56
+ * omitted, no matter whether `mSettings` will be given or not!
57
+ */
58
+ sId?: string,
59
+ /**
60
+ * Object with initial settings for the new control
61
+ */
62
+ mSettings?: sap.ui.webc.common.$WebComponentSettings
63
+ );
39
64
 
40
65
  /**
41
- * Creates a new subclass of class sap.ui.webc.common.WebComponent with name `sClassName` and enriches it
42
- * with the information contained in `oClassInfo`.
66
+ * Defines a new subclass of WebComponent with the name `sClassName` and enriches it with the information
67
+ * contained in `oClassInfo`.
68
+ *
69
+ * `oClassInfo` can contain the same information that {@link sap.ui.base.ManagedObject.extend} already accepts,
70
+ * plus the `dnd` property in the metadata object literal to configure drag-and-drop behavior (see {@link sap.ui.core.webc.WebComponent.MetadataOptions MetadataOptions }
71
+ * for details). Objects describing aggregations can also have a `dnd` property when used for a class extending
72
+ * `WebComponent` (see {@link sap.ui.base.ManagedObject.MetadataOptions.AggregationDnD AggregationDnD}).
73
+ *
74
+ * Example:
75
+ * ```javascript
76
+ *
77
+ * WebComponent.extend('sap.mylib.MyElement', {
78
+ * metadata : {
79
+ * library : 'sap.mylib',
80
+ * tag : 'my-webcomponent',
81
+ * properties : {
82
+ * value : 'string',
83
+ * width : {
84
+ * type: 'sap.ui.core.CSSSize',
85
+ * mapping: 'style'
86
+ * }
87
+ * },
88
+ * defaultAggregation: "content",
89
+ * aggregations : {
90
+ * content : {
91
+ * type: 'sap.ui.core.Control',
92
+ * multiple : true
93
+ * },
94
+ * header : {
95
+ * type : 'sap.ui.core.Control',
96
+ * multiple : false,
97
+ * slot: 'header'
98
+ * }
99
+ * }
100
+ * }
101
+ * });
102
+ * ```
43
103
  *
44
- * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.Control.extend}.
45
104
  *
46
105
  * @returns Created class / constructor function
47
106
  */
48
107
  static extend<T extends Record<string, unknown>>(
49
108
  /**
50
- * Name of the class being created
109
+ * Name of the class to be created
51
110
  */
52
111
  sClassName: string,
53
112
  /**
@@ -55,8 +114,7 @@ declare namespace sap {
55
114
  */
56
115
  oClassInfo?: sap.ClassInfo<T, sap.ui.webc.common.WebComponent>,
57
116
  /**
58
- * Constructor function for the metadata object; if not given, it defaults to the metadata implementation
59
- * used by this class
117
+ * Constructor function for the metadata object. If not given, it defaults to `sap.ui.core.ElementMetadata`.
60
118
  */
61
119
  FNMetaImpl?: Function
62
120
  ): Function;
@@ -69,9 +127,11 @@ declare namespace sap {
69
127
  }
70
128
  /**
71
129
  * @since 1.92.0
130
+ * @deprecated (since 1.118.0) - Use sap.ui.core.webc.WebComponentMetadata instead!
72
131
  * @experimental (since 1.92.0) - The API might change. It is not intended for productive usage yet!
73
132
  */
74
- class WebComponentMetadata extends sap.ui.core.ElementMetadata {
133
+ class WebComponentMetadata extends sap.ui.core.webc
134
+ .WebComponentMetadata {
75
135
  /**
76
136
  * Creates a new metadata object for a WebComponent Wrapper subclass.
77
137
  */
@@ -85,24 +145,6 @@ declare namespace sap {
85
145
  */
86
146
  oClassInfo: object
87
147
  );
88
-
89
- /**
90
- * Returns the list of public getters, proxied by the Component Wrapper to the component itself
91
- */
92
- getGetters(): any[];
93
- /**
94
- * Returns the list of public methods, proxied by the Component Wrapper to the component itself
95
- */
96
- getMethods(): any[];
97
- /**
98
- * Retrieves the renderer for the described web component class. Note: this is always the default renderer
99
- * and Web Component wrappers should not define their own renderers.
100
- */
101
- getRenderer(): void;
102
- /**
103
- * Returns the tag, used to render the Component Wrapper
104
- */
105
- getTag(): string;
106
148
  }
107
149
  }
108
150
  }